05.01.2015, 15:56
Hi, i have this code:
And i have problem. It works only for ID 0. How can in fix that ?
Код:
#define SLOTY 50 forward FotoradarUpdate(); public FotoradarUpdate() { for(new i = 0;i<SLOTY;i++) { if(!IsPlayerConnected(i)) break; if(!IsPlayerInAnyVehicle(i)) break; for(new b = 0;b<MAX_FOTORADARY +1;b++) { if(IsPlayerInRangeOfPoint(i,FotoInfo[b][Range],FotoInfo[b][posX],FotoInfo[b][posY],FotoInfo[b][posZ])) { if(GetVehicleSpeed(GetPlayerVehicleID(i)) > FotoInfo[b][vMax]) { SendClientMessage(i, COLOR_RED, "Przekroczyłeś prędkość"); ShowPlayerFadeScreenToBlank(i, 15, 255, 255, 255, 200); } format(dstring,sizeof(dstring),"[INFO] Jesteś blisko radaru UID:"CWHITE" %d!",FotoInfo[b][UID]); SendClientMessage(i, COLOR_YELLOW, dstring); } } } return 1; }