Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #define MAX_VOZILA 2000
- #define RESPAWN_TIME 2000
- YCMD:rac(playerid, params[], help)
- {
- #pragma unused help
- if(UlogovanProvera[playerid] == 0) return SCM(playerid,-1,"[SC:RPG] | "CRVENA"Moras se ulogovati da bi koristio ovu komandu!");
- if(PlayerInfo[playerid][pAdmin] < 6) return SCM(playerid, -1, ""CRVENA"[SC:RPG] "SIVA"Samo Vlasnik.");
- if(AdminDuty[playerid] == 0) return SCM(playerid,-1,""CRVENA"[SC:RPG] "SIVA"Morate biti na admin duznosti!");
- if(RespawnVozila == 1) return SCM(playerid, -1, ""CRVENA"[GRESKA] "BELA"Respawn je vec pokrenut!");
- new string[512]; RespawnVozila = 1;
- format(string,sizeof string, ""CRVENA"<<< "BELA"Admin %s je pokrenuo respawn privatnih vozila za 20 sec! "CRVENA">>>", GetName(playerid));
- SendClientMessageToAll(-1, string);
- SendClientMessageToAll(-1, ""CRVENA"<<< "BELA"Udjite u svoje vozilo ukoliko zelite da ga zadrzite! "CRVENA">>>");
- SetTimer("Respawn", 2000, false);
- return 1;
- }
- forward Respawn();
- public Respawn()
- {
- new bool:unwanted[MAX_VOZILA];
- for(new player=0; player<MAX_PLAYERS; player++)
- {
- if(IsPlayerInAnyVehicle(player)) { unwanted[GetPlayerVehicleID(player)]=true; }
- }
- for(new car = 1; car < MAX_VOZILA; car++)
- {
- if(!unwanted[car]) SetVehicleToRespawn(car);
- }
- RespawnVozila = 0; SCMTA(-1, ""SPLAVA"<<< "BELA"Vozila Respawnovana "SPLAVA">>>");
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment