was hier falsch?
dcmd_setname(playerid,params[])
{
if(PlayerData[playerid][Level] >= 3)
{
new opfer,name,string[128],oname[MAX_PLAYER_NAME];
if(sscanf(params,"us",opfer,name)) return SendClientMessage(playerid,COLOR_RED,"USAGE: /setname [playerid] [new name]");
if (!IsPlayerConnected(opfer)) return SendClientMessage(playerid, COLOR_SYSTEM, "Invalid ID!");
if(name < 3 || name > MAX_PLAYER_NAME) return SendClientMessage(playerid,COLOR_RED,"Invalid Name Length!");
GetPlayerName(opfer,oname,sizeof(oname));
SetPlayerName(opfer,name);
format(string,sizeof(string),"[Server] %s will now be known as %s",oname,name);
SendClientMessageToAll(COLOR_RED,string);
return 1;
}
else return SendClientMessage(playerid,COLOR_RED,"Admins only!");
}
argument type mismatch (argument 2)
was stimmt an dem SetPlayerName(opfer,name); nicht?