24.08.2009, 13:51
OK, I added forward CheckZone(); at the top of script under all defines, then I added
above OnGameModeInit() and I added SetTimer("CheckZone", 100, true); in OnGameModeInit() and I got when I enter server immediately it start to write You left Los Santos! The Police is looking for you!!! every second :S
Код:
public CheckZone() { for(new i = 0; i < MAX_PLAYERS; i ++) { if(IsPlayerConnected(i)) { if(!IsPlayerInZone(i, "Los Santos")) { new string[256]; WantedPoints[i]+=2; format(string, sizeof(string), "You left Los Santos! The Police is looking for you!!!"); SendClientMessage(i, COLOR_RED, string); } } } }