Help With Gp2x Buttons Config

Previous topic - Next topic

phil

Here is what ive found

//This list is usefull to know when you are programming for gp2x
//key(203) = Stick to Left      (arrow key)pc
//key(205) = Stick to Right      (arrow key)pc
//key(200) = Stick to Up      (arrow key)pc
//key(208) = Stick to Down      (arrow key)pc
//key(29) = A Button         (control)pc
//key() = B Button      
//key() = X Button
//key() = Y Button   
//key() = Start Button   
//key() = Select Button      
//key() = L Button         
//key() = R Button      

Can anyone add any more PLZ???

Kitty Hello

See manual for KEY command.

Devlin

Alternatively, add this function to your code :)

Code (glbasic) Select
FUNCTION aliases:
//                   PC Key     : GP2X key
vk_space=57       // Space bar  : Joy click
vk_up=200         // Arrow Up   : Joy Up
vk_down=208       // Arrow Down : Joy Down
vk_left=203       // Arrow Left : Joy Left
vk_right=205      // Arrow Right: Joy Right
vk_a=30           // Letter 'A' : A Face button
vk_b=32           // Letter 'D' : B Face button
vk_x=31           // Letter 'S' : X Face button
vk_y=17           // Letter 'W' : Y Face button
vk_l=42           // Left Shift : Left Shoulder
vk_r=54           // Right Shift: Right Shoulder
vk_start=28       // Enter      : Start button
vk_select=15      // Tab        : Select button
vk_volup=201      // Page Down  : Volume Up
vk_voldown=209    // Page Up    : Volume Down
vk_escape=1       // Escape     : Volume Up&Down
vk_none=0         // No key     : No key

white   = RGB(255,255,255)
cyan    = RGB(0,255,255)
magenta = RGB(255,0,255)
ENDFUNCTION // KEYMAP
Don't forget to call it at the beginning of your code!

Kitty Hello


phil


DMusta1ne

I should not open a new Gp2x help topic, so I'll wrote my question here. I know that GlBasic has network funcions, my question is : this functions works on games compiled for Gp2x? what kind of networks? Thanks

Kitty Hello

I have not tested them. They worked on Linux last time I tested, but it seems there's a bug right now, so they don't even work on Windows at the moment.

DMusta1ne

Thanks again. I oly got to say that if this Sdk features 3d and network functions suitables for the gp2x, Glbasic will be a very reputed sdk. Keep on workin! ;)

Kitty Hello

Well, the GP2X will never be a great 3D game platform. Even if they ported Quake and Egoboo. The power is very limited for 3D. However for 2D games it's awesome, and for this GLBasic is a perfect choice if you want it fast and easy.

DMusta1ne

The only reason for me to start programmin in glbasic is the 3d features and the network funcitions, if those doesn't work properlly on gp2x, better keep on with Fenix, that is a good ide to programm 2d games, and its more familiar to me, and its gnu. I hope u dont take the post in the wrong way, i saw the demo games and glbasic is a great ide to program 3d games in pc, but is not a big deal 4 me if i can't port those games to gp2x. Thanks anyway ^^