Hallo habe folgendes problem
ich möchte das man /prison id grund wie kann ich das ändern?und bzw /unprison erstellen?
if(strcmp(cmd, "/prison",true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pAdmin] < 2)
{
SendClientMessage(playerid, COLOR_GREY, " Du bist kein Admin !");
return 1;
}
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutze: /prison [playerid]");
return 1;
}
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
if(giveplayerid != INVALID_PLAYER_ID)
{
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "* Du hast %s nach Fort DeMorgan teleportiert.", giveplayer);
SendClientMessage(playerid, COLOR_LIGHTRED, string);
format(string, sizeof(string), "* Du wurdest von Admin %s zur Toilette des Todes teleportiert.", sendername);
SendClientMessage(giveplayerid, COLOR_LIGHTRED, string);
GameTextForPlayer(giveplayerid, "~w~Willkommen in ~n~~r~der Toilette des Todes", 5000, 3);
WantedPoints[giveplayerid] = 0;
WantedLevel[giveplayerid] = 0;
SetPlayerWantedLevel(giveplayerid,0);
PlayerInfo[giveplayerid][pJailed] = 2;
PlayerInfo[giveplayerid][pJailTime] = 3600;
ResetPlayerWeapons(playerid);
SetPlayerInterior(playerid,18);
SetPlayerPos(giveplayerid, -221.059051,1408.984008,27.773437);
}
}
else
{
SendClientMessage(playerid, COLOR_GREY, " Der Spieler ist nicht da!");
return 1;
}
}
return 1;
}
LG Sunny