21.10.2009, 23:44
Well i have this on a timer, It's supposed to open the gates only for those who are in dmzone area 4, But the gates do not move, I have no compile errors, Just the gates don't move, Heres my code:
Do you have any ideas?
Код:
public GroveGates(playerid) { if(DMZone[playerid] == 4) { for(new i = 0; i < GetMaxPlayers(); i++) { if(!IsPlayerConnected(i)) continue; if(IsPlayerInRangeOfPoint(i, 10.0, 2435.674561, -1656.416626, 13.420712) && OpenGate[i] == 0) { MoveObject(ggate, 2435.674561, -1656.416626, 13.420712, 3.0); OpenGate[i] = 1; } else if(!IsPlayerInRangeOfPoint(i, 15.0, 2435.674561, -1656.416626, 13.420712) && OpenGate[i] == 1) { MoveObject(ggate, 2435.637695, -1651.433228, 13.333119, 3.0); OpenGate[i] = 0; } } } }