[SOLVED]OnPlayerStateKeyChange Help Needed - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [SOLVED]OnPlayerStateKeyChange Help Needed (
/showthread.php?tid=66585)
[SOLVED]OnPlayerStateKeyChange Help Needed -
riding-bmx - 23.02.2009
Ok, so this is what i have:
pawn Код:
if(newkeys == KEY_SECONDARY_ATTACK)
{
if(PlayerToPoint(2, playerid, 245.1057,71.9354,1003.6406) && IsACop(playerid))
{
ApplyAnimation(playerid,"HEIST9","Use_SwipeCard",4.1,0,1,0,0,0);
SetTimer("GateClosedesk", 5000, 0);
SendClientMessage(playerid, COLOR_YELLOW,"The LSPD Gate will AutoClose in 5 Seconds");
MoveObject(lspdvault,246.3735,72.6083,1000.6406,10);
}
}
It compiles fine but when i got to use it IG nothing happends
Can someone please help?
Re: OnPlayerStateChange Help Needed -
Mikep - 23.02.2009
newkeys & KEY_WHATEVER
Re: OnPlayerStateChange Help Needed -
riding-bmx - 23.02.2009
Still doesn't work
Re: OnPlayerStateChange Help Needed -
riding-bmx - 23.02.2009
*Bump*
I really need this to work
Re: OnPlayerStateChange Help Needed -
smallo - 23.02.2009
you are pressing the enter key or the f key aren't you?
Re: OnPlayerStateChange Help Needed -
ғαιιοцт - 23.02.2009
are you using
Код:
OnPlayerKeyStateChange
or
because the title of this topic is 'OnPlayerStateChange Help Needed'
Re: OnPlayerStateChange Help Needed -
riding-bmx - 23.02.2009
Quote:
Originally Posted by °ғαιιοцт°
are you using
Код:
OnPlayerKeyStateChange
or
because the title of this topic is 'OnPlayerStateChange Help Needed'
|
OnPlayerKeyStateChange
Title was a typo
Re: OnPlayerStateChange Help Needed -
riding-bmx - 23.02.2009
Quote:
Originally Posted by [DRuG
Smallo ]
you are pressing the enter key or the f key aren't you?
|
Yes i am
Re: OnPlayerStateKeyChange Help Needed -
ғαιιοцт - 23.02.2009
give the lines above
Код:
if(newkeys == KEY_SECONDARY_ATTACK)
Re: OnPlayerStateKeyChange Help Needed -
riding-bmx - 23.02.2009
pawn Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(!gPlayerUsingLoopingAnim[playerid]) return;
//SendClientInt(playerid, RED, "ID: %d", newkeys);
if(IsKeyJustDown(KEY_HANDBRAKE,newkeys,oldkeys))
{
StopLoopingAnim(playerid);
TextDrawHideForPlayer(playerid,txtAnimHelper);
animation[playerid] = 0;
}