Search:

Type: Posts; User: jtay

Search: Search took 0.01 seconds.

  1. Replies
    8
    Views
    1,371

    Thanks for all the help everyone. I'll definitely...

    Thanks for all the help everyone. I'll definitely try out your code, Salem, when I get home today.

    I guess I heard a lot of answers that I more or less expected to hear. I realize that allocating...
  2. Replies
    8
    Views
    1,371

    Weird realloc issue

    Hey everyone. Been a while since I posted last. I decided to brush up on my C programming skills and try to code a little program for me and my friends to use for a role playing game that we play....
  3. Replies
    7
    Views
    3,943

    This "fake the garbage" line that you made is...

    This "fake the garbage" line that you made is actually solving the problem, so I've got the code working now. I think my problem had to do with me not initializing the memory after I reallocated it;...
  4. Replies
    7
    Views
    3,943

    The code is right up there in the first post. I...

    The code is right up there in the first post. I just stuck a bunch of "printf" statements right after it to see what was going on. The columns in that data correspond directly to how I described...
  5. Replies
    7
    Views
    3,943

    I appreciate your responses and will definitely...

    I appreciate your responses and will definitely be implementing some of them after I fix my problem. I had the program print out the array after it was done running, and this is what I got:


    1 4...
  6. Replies
    7
    Views
    3,943

    Allocate space for 2d array

    I'm having problems allocating space for a 2d array. Since I don't know precisely where the problem is, I've posted the exact content of the function I'm working with as well as the file that it...
  7. Replies
    6
    Views
    2,465

    Thanks for that! It took me a little while to...

    Thanks for that! It took me a little while to figure out how to put the typedef in my header file, but my code is working now. I still only understand maybe 70% how this works, but I expect I'll...
  8. Replies
    6
    Views
    2,465

    Okay, I'm starting to understand how this works. ...

    Okay, I'm starting to understand how this works. So since my_function is a pointer to long, array_var can only be subscripted once. How would I go about making this so I can subscript it twice? ...
  9. Replies
    6
    Views
    2,465

    I've fiddled with the code a bit more, but I...

    I've fiddled with the code a bit more, but I still can't find what I need to change to get this to work. I don't see how my_function is returning a pointer to an array, since it's declared as long...
  10. Replies
    6
    Views
    2,465

    Passing arrays between functions

    Hello everyone, I'm an amateur C programmer working on what every amateur programmer wants to do: make a game. In my case a text adventure, though it's not very far along yet. Anyways, I'm having...
Results 1 to 10 of 10