09.11.2014, 22:35
Hello i have made a moveing gate and its work fine with command but i want it to open auto when player inside one of this vehicles and it dosnt work
PHP код:
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if(oldstate == PLAYER_STATE_ONFOOT && newstate == PLAYER_STATE_DRIVER)
{
if(IsPlayerInRangeOfPoint(playerid,5.0,-1631.5386,681.5295,7.1901))
{
new Vehicle;
Vehicle = GetPlayerVehicleID(playerid);
if(Vehicle > 427 || 490 || 528 || 596 || 597 ||598 || 599)
{
MoveObject(SFcopDoor,-1631.5, 688.40002, 13.1,1,0, 0, 90);
}
}
else
{
MoveObject(SFcopDoor,-1631.5, 688.40002, 8.7,1,0, 0, 90);
}
}
return 1;
}