Aslo what is the function for closing the app ? And can i get the result if PS button is pressed?
| Friends: Coding 'n Cracking - Nymphaea - PS3 Forum - darkforestgroup - daxhordes.org - Tgames - coldbird - gopsp.it - pspstation.org - prometheus - hgoel.info - MakeSmartTV - ps vita |

FrEdDy wrote:sceKernelDelayThread(int milliseconds)
sceKernelExitGame to exit your application. I don't understand your other question though.
kmanev07 wrote:FrEdDy wrote:sceKernelDelayThread(int milliseconds)
sceKernelExitGame to exit your application. I don't understand your other question though.
thanks works perfect
int held=0; //declared outside of rendering loop
if( (pad.Buttons & PSP_CTRL_CROSS) && !held){
//do whatever just once
held=1;
}
else if
( !(pad.Buttons & PSP_CTRL_CROSS) )held=0;
snailface wrote:kmanev07 wrote:FrEdDy wrote:sceKernelDelayThread(int milliseconds)
sceKernelExitGame to exit your application. I don't understand your other question though.
thanks works perfect
Only problem with that delay function is that if you do it in a rendering loop, you will stop the program every time you press the button.
It would be a good idea to get in the habit of doing something like this:
- Code: Select all
int held=0; //declared outside of rendering loop
if( (pad.Buttons & PSP_CTRL_CROSS) && !held){
//do whatever just once
held=1;
}
else if
( !(pad.Buttons & PSP_CTRL_CROSS) )held=0;
That will only allow just one button press to get through each time it is held down for whatever amount of time.

Users browsing this forum: No registered users and 2 guests