Hallo,
Wenn ich InGame /Swatduty mache
Ändert sich mein Name nicht?
Woran kann das liegen?
Ich habe keinen Fehler gefunden
COMMAND:swatduty(playerid,params[])
{
#pragma unused params
if(IsPlayerInFrac(playerid,22))
{
if(SWATDuty[playerid] == 0)
{
SendClientMessage(playerid,WEISS,"Du bist nun SWAT Duty");
SetPlayerColor(playerid,COLOR_WHITE);
SWATDuty[playerid] = 1;
SetPlayerSkin(playerid,285);
SwatName = SpielerName(playerid);
switch(PlayerInfo[playerid][pSwatName])
{
case 0: { SendClientMessage(playerid,ROT,"Du hast noch keinen Decknamen. Ein Leader muss dir einen geben."); SWATDuty[playerid] = 0; SetPlayerSkin(playerid, 282);}
case 1: { SetPlayerName(playerid,"Alpha"); }
case 2: { SetPlayerName(playerid,"Beta"); }
case 3: { SetPlayerName(playerid,"Gamma"); }
case 4: { SetPlayerName(playerid,"Omega"); }
case 5: { SetPlayerName(playerid,"Delta"); }
case 6: { SetPlayerName(playerid,"Epsilon"); }
case 7: { SetPlayerName(playerid,"Zeta"); }
case 8: { SetPlayerName(playerid,"Eta"); }
case 9: { SetPlayerName(playerid,"Theta"); }
case 10: { SetPlayerName(playerid,"Iota"); }
case 11: { SetPlayerName(playerid,"Kappa"); }
case 12: { SetPlayerName(playerid,"Lambda"); }
case 13: { SetPlayerName(playerid,"Omikron"); }
case 14: { SetPlayerName(playerid,"Rho"); }
case 15: { SetPlayerName(playerid,"Sigma"); }
case 16: { SetPlayerName(playerid,"Tau"); }
case 17: { SetPlayerName(playerid,"Ypsilon"); }
case 18: { SetPlayerName(playerid,"Psi"); }
case 19: { SetPlayerName(playerid,"Omega"); }
}
PlayerUpdate(playerid);
}
else
{
SendClientMessage(playerid,WEISS,"Du bist nun nicht mehr SWAT Duty");
SetPlayerColor(playerid,COLOR_WHITE);
SetPlayerSkin(playerid, 282);
SWATDuty[playerid] = 0;
SetPlayerName(playerid,SwatName);
}
}
else
{
SendClientMessage(playerid,WEISS,"Du bist kein SWAT Mitglied");
}
return 1;
}
COMMAND:deckname(playerid,params[])
{
new pID,DeckNamen;
if(PlayerInfo[playerid][pLeader] == 22)
{
if(sscanf(params,"us",pID,DeckNamen))
{
SendClientMessage(playerid,ROT,"Befehl: /Deckname [Spieler] [Deckname]");
SendClientMessage(playerid,ROT,"1.Alpha");
SendClientMessage(playerid,ROT,"2.Beta");
SendClientMessage(playerid,ROT,"3.Gamma");
SendClientMessage(playerid,ROT,"4.Omega");
SendClientMessage(playerid,ROT,"5.Delta");
SendClientMessage(playerid,ROT,"6.Epsilon");
SendClientMessage(playerid,ROT,"7.Zeta");
SendClientMessage(playerid,ROT,"8.Eta");
SendClientMessage(playerid,ROT,"9.Theta");
SendClientMessage(playerid,ROT,"10.Iota");
SendClientMessage(playerid,ROT,"11.Kappa");
SendClientMessage(playerid,ROT,"12.Lambda");
SendClientMessage(playerid,ROT,"13.Omikron");
SendClientMessage(playerid,ROT,"14.Rho");
SendClientMessage(playerid,ROT,"15.Sigma");
SendClientMessage(playerid,ROT,"16.Tau");
SendClientMessage(playerid,ROT,"17.Ypsilon");
SendClientMessage(playerid,ROT,"18.Psi");
SendClientMessage(playerid,ROT,"19.Omega");
}
PlayerInfo[pID][pSwatName] = DeckNamen;
PlayerUpdate(playerid);
}
else
{
SendClientMessage(playerid,ROT,"Du bist kein SWAT Leader");
}
}
Danke im Vorraus