Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- new UBolnicu[MAX_PLAYERS];
- new Float:RandomKreveti[][4] = //KOORDINATE KREVETA
- {
- {0, 0, 0, 0},
- {0, 0, 0, 0},
- {0, 0, 0, 0},
- {0, 0, 0, 0},
- {0, 0, 0, 0},
- {0, 0, 0, 0}
- };
- forward IzasoIzBolnice(playerid);
- public IzasoIzBolnice(playerid)
- {
- TogglePlayerControllable(playerid,1);
- SetPlayerPos(playerid,1178.6914,-1323.6317,14.1326);
- SCM(playerid,GRAD2,"Uspjesno ste se izljecili i izasli iz bolnice!");
- return 1;
- }
- public OnPlayerSpawn(playerid)
- {
- if(UBolnicu[playerid] == 1 && PlayerInfo[playerid][pZatvor] == 0)//NAJBOLJE DODATI PRI KRAJU TOG PUBLICA
- {
- SCM(playerid,GRAD2,"Lijecite se,pricekajte malo da izadjete iz bolnice!");
- new rand = random(sizeof(RandomKreveti));
- SetPlayerPos(playerid, RandomKreveti[rand][0], RandomKreveti[rand][1], RandomKreveti[rand][2]);
- SetPlayerFacingAngle(playerid,RandomKreveti[rand][3]);
- SetPlayerInterior(playerid, 0);
- TogglePlayerControllable(playerid, 0);
- SetTimerEx("IzasoIzBolnice",Min(2), false, "i", playerid);
- UBolnicu[playerid] = 0;
- }
- return 1;
- }
- public OnPlayerDeath(playerid, killerid, reason)
- {
- UBolnicu[playerid] = 1;
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment