Guten Abend Breadfish ich mache es kurz also..
Wie kann ich den Befehl
new specplayerid;
if(strcmp(cmd, "/tv", true) == 0)
{
if(specten[playerid]==0)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, WEIß, "/tv [playerid]");
return 1;
}
specplayerid = strval(tmp);
if(!IsPlayerConnected(specplayerid))
{
SendClientMessage(playerid, GRAU,"** Dieser Spieler ist nicht aktiv!");
return 1;
}
TogglePlayerSpectating(playerid, 1);
PlayerSpectatePlayer(playerid, specplayerid);
SetPlayerInterior(playerid,GetPlayerInterior(specplayerid));
gSpectateID[playerid] = specplayerid;
gSpectateType[playerid] = ADMIN_SPEC_TYPE_PLAYER;
specten[playerid]=1;
}
else
{
TogglePlayerSpectating(playerid, 0);
gSpectateID[playerid] = INVALID_PLAYER_ID;
gSpectateType[playerid] = ADMIN_SPEC_TYPE_NONE;
SendClientMessage(playerid,GRAU,"** TV aus!");
specten[playerid]=0;
}
return 1;
}
Nur für Admins ab Rang 1 machen´? Also für pAdmin1