02.05.2011, 12:06
So im making a gate to open it with keypad i follow one tutorial i have saved it but i dont know which was.. But not working can anyone help me whats wrong?? I go in game and go to the keypad click on "Enter or F" btw not opening
So here is:
OnPlayerKeyStateChange:
Added and keypad:
So here is:
pawn Код:
new swatv1;
pawn Код:
forward swatv1zatvori();
pawn Код:
public swatv1zatvori()
{
MoveDynamicObject(swatv1,2720.23461914,-2403.98461914,15.23432922, 2.00);
return 1;
}
pawn Код:
swatv1 = CreateDynamicObject(980,2720.23461914,-2403.98461914,15.23432922,0.00000000,0.00000000,270.00000000); //object(airportgate) (1)
pawn Код:
if(newkeys & 16)
{
if(IsPlayerInRangeOfPoint(playerid, 3.0, 2719.97509766,-2410.55859375,13.85989571))
{
if (PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pLeader] == 3)
{
MoveDynamicObject(swatv1,2720.23461914,-2403.98461914,9.48432922,2.0);
SetTimerEx("swatv1zatvori", 5000, false, "i", playerid);
ApplyAnimation(playerid, "HEIST9", "Use_SwipeCard", 10.0, 0, 0, 0, 0, 0);
}
}
}
Added and keypad:
pawn Код:
CreateDynamicObject(2922,2719.97509766,-2410.55859375,13.85989571,0.00000000,0.00000000,88.00000000); //Swat Door 1 Keypad