Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if(strcmp(cmd, "/unprison", true) == 0)
- {
- if(IsPlayerConnected(playerid))
- {
- tmp = strtok(cmdtext, idx);
- if(!strlen(tmp))
- {
- SendClientMessage(playerid, COLOR_WHITE, "{FF8306}KORISTETE:{FFFFFF}/unprison [ID/Ime na Igrac] [minuti]");
- }
- new playa;
- playa = ReturnUser(tmp);
- tmp = strtok(cmdtext, idx);
- if (PlayerInfo[playerid][pAdmin] >= 3)
- {
- if(IsPlayerConnected(playa))
- {
- if(playa != INVALID_PLAYER_ID)
- {
- GetPlayerName(playa, giveplayer, sizeof(giveplayer));
- GetPlayerName(playerid, sendername, sizeof(sendername));
- new length = strlen(cmdtext);
- while ((idx < length) && (cmdtext[idx] <= ' '))
- {
- idx++;
- }
- new offset = idx;
- new result[128];
- while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
- {
- result[idx - offset] = cmdtext[idx];
- idx++;
- }
- result[idx - offset] = EOS;
- if(!strlen(result))
- {
- SendClientMessage(playerid, COLOR_WHITE, "{FF8306}KORISTETE:{FFFFFF}/unprison [ID/Ime na Igrac] [pricina].");
- return 1;
- }
- format(string, sizeof(string), "{6EF83C}INFO:{FFFFFF}Go izvadivte %s od Demir Hisar", giveplayer);
- SendClientMessage(playerid, WHITE, string);
- SafeResetPlayerWeapons(playa);
- WantedPoints[playa] = 0;
- PlayerInfo[playa][pJailed] = 0;
- PlayerInfo[playa][pJailTime] = 0;
- SetPlayerInterior(playa, 6);
- PlayerInfo[playa][pInt] = 6;
- SetPlayerWorldBounds(giveplayerid, 20000.0000,-20000.0000,20000.0000,-20000.0000);
- SetPlayerPos(giveplayerid, 246.8439,70.0776,1003.6406);
- format(string, sizeof(string), "{6EF83C}INFO:{FFFFFF}Izvadeni ste od Demir Hisar od Admin %s", sendername);
- SendClientMessage(playa, COLOR_WHITE, string);
- printf("%s",string);
- }
- }
- }
- else
- {
- SendClientMessage(playerid, WHITE, "{FF4040}GRESKA:{FFFFFF}Nemozete da ja koristite ovaa komanda.");
- }
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement