Where To Go Now


Just ejecting the card is a nono, as it will confuse linux, and it will use its cached copy of the files on it instead. Tell linux to unmount the card, then eject it. Use the terminal connection, make sure there is nothing using the card anymore (including your terminal connection stuff!!), and use the 'umount' (spelled that way!) command. See a linux-for-noobs tutorial to learn more about this, and what arguments to use with the command..
P.
Ah that makes sense. I have never really used linux before, hence the n00b mistakes, but it seems simple enough. It definitely makes more sense from a technical standpoint.

Thanks for the link timbobsteve...

Gah, stupid java assessment to do now. :(
 
I also need to work out how to get it so that it continues to move when I hold the stick down, I shall check the sterm source as you said earlier, but it will probably just confuse me.
 
To get constant movement you have to detect input and perform actions in two seperate parts.

The easiest way is to create a boolean array for each key/button map and then fill them on events for example (only psuedo code):

Code:
bool keystates[323]

while GAME
{
      if BUTTON_DOWN
      {
            if BUTTON_EVENT.TYPE == X_BUTTON
                   keystates[X_BUTTON] == TRUE;

            if BUTTON_EVENT.TYPE == Y_BUTTON
                   keystates[Y_BUTTON] == TRUE;
       }
      if BUTTON_UP
      {
            if BUTTON_EVENT.TYPE == X_BUTTON
                   keystates[X_BUTTON] == FALSE;

            if BUTTON_EVENT.TYPE == Y_BUTTON
                   keystates[Y_BUTTON] == FALSE;
       }
}

This way you can just test the state of each keystate boolean and perform actions accordingly. It may not be the way everyone else does it... but its the way I am familiar with.

I think there may be an SDL function that will fill a boolean 'state' array for you... but I am not sure.

Good luck. PM me if you need more help... I can try and find some old code that uses it.

NOTE: this is not the gospel... I am a n00b C++/SDL coder too.

edit: fixed some code errors
 
Ahhh. I get it now, thanks so much. It's funny how stuff that is really quite easy can seem really hard when you don't know.
 
Yeh I used to be the same... I hang out alot on www.gamedev.net forums and read alot there.. even if it isn't directly to do with SDL or C++ the code always shows you new things. Alot of good stuff on those forums... +Articles too.

Good luck with the programming
 
timbobsteve posted on Feb 26 2006 at 03:51 AM said:
Yeh I used to be the same... I hang out alot on www.gamedev.net forums and read alot there.. even if it isn't directly to do with SDL or C++ the code always shows you new things. Alot of good stuff on those forums... +Articles too.

Good luck with the programming
Wow, thanks so much for that, there are some really nice short tutorials which just teach you the facts.
 
Last edited by a moderator:
Back
Top