07.12.2013, 21:53
Gates
Hello, I was trying to make my /gate command to work with two gates but the 2nd one doesn't want to work. Please help me out. Frist one works perfect.pawn Код:
COMMAND:gate(playerid, params[])
{
if(PlayerInfo[playerid][pFaction] == 1)
{
if(IsPlayerInRangeOfPoint(playerid,7.0,1544.4863,-1627.2356,13.6044))
{
MoveObject(LSPDbar,1544.6999500,-1630.8000500,13.3000000, 0.0001, 0.0000000, 9.0000000, 90.0000000);
timer[playerid] = SetTimerEx("gateclose",10000,false,"i",playerid);
}
else if(IsPlayerInRangeOfPoint(playerid,7.0,1588.1267,-1637.9401,13.4202))
{
MoveObject(LSPDGate,1599.1999500,-1638.0999800,14.8001000, 0.0001); //object(airportgate) (1)
timer[playerid] = SetTimerEx("gateclose2",10000,false,"i",playerid);
}
}
return 1;
}
Thanks for advanced.
Kind Regards,
Death 1300.