SA-MP Forums Archive
[Help]Hold / Pressed key - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: [Help]Hold / Pressed key (/showthread.php?tid=332819)



[Help]Hold / Pressed key - Boban_Minic - 09.04.2012

I make it
Код:
if (PRESSED( KEY_WALK ))
    {
		drzanjetimer = SetTimerEx("Drzanje1",1000,1,"d",playerid);
	}
	else if (RELEASED( KEY_WALK ))
	{
		KillTimer(drzanjetimer);
	}
How I make this code with KEY_UP ?

I tried this :
Код:
if (PRESSED( KEY_UP ))
    {
		drzanjetimer = SetTimerEx("Drzanje1",1000,1,"d",playerid);
	}
	else if (RELEASED( KEY_UP ))
	{
		KillTimer(drzanjetimer);
	}
but not work... :S


Re: [Help]Hold / Pressed key - Shabi RoxX - 09.04.2012

I think this one:
pawn Код:
KEY_ANALOG_UP



Re: [Help]Hold / Pressed key - Boban_Minic - 09.04.2012

Quote:
Originally Posted by Shabi RoxX
Посмотреть сообщение
I think this one:
pawn Код:
KEY_ANALOG_UP
not work too... :/