Hallihallöchen liebe Breadfish-Community, Ich habe schon versucht mir soeinen zusammenzuscripten, finde den Fehler aber nicht.. Es kommen weder Errors noch sonstiges, aber InGame kommt "SERVER: Unknown Command".
ich suche etwas Hilfe für einen Befehl.
if(strcmp(cmd, "/friskweapons", true) == 0)
{
if(IsACop(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD1, "Benutzung: /checkwaffen [Spieler ID]");
return 1;
}
giveplayerid = ReturnUser(tmp);
if(giveplayerid != INVALID_PLAYER_ID)
{
if (ProxDetectorS(8.0, playerid, giveplayerid))
{
new bullets[12], weapons[12], weapname[12][50],
new coordsstring[256];
GetPlayerWeaponData(giveplayerid,1,weapons[0],bullets[0]); GetPlayerWeaponData(giveplayerid,2,weapons[1],bullets[1]);
GetPlayerWeaponData(giveplayerid,3,weapons[2],bullets[2]); GetPlayerWeaponData(giveplayerid,4,weapons[3],bullets[3]);
GetPlayerWeaponData(giveplayerid,5,weapons[4],bullets[4]); GetPlayerWeaponData(giveplayerid,6,weapons[5],bullets[5]);
GetPlayerWeaponData(giveplayerid,7,weapons[6],bullets[6]); GetPlayerWeaponData(giveplayerid,8,weapons[7],bullets[7]);
GetPlayerWeaponData(giveplayerid,9,weapons[8],bullets[8]); GetPlayerWeaponData(giveplayerid,10,weapons[9],bullets[9]);
GetPlayerWeaponData(giveplayerid,11,weapons[10],bullets[10]); GetPlayerWeaponData(giveplayerid,12,weapons[11],bullets[11]);
GetWeaponName(weapons[0],weapname[0],50); GetWeaponName(weapons[1],weapname[1],50); GetWeaponName(weapons[2],weapname[2],50);
GetWeaponName(weapons[3],weapname[3],50); GetWeaponName(weapons[4],weapname[4],50); GetWeaponName(weapons[5],weapname[5],50);
GetWeaponName(weapons[6],weapname[6],50); GetWeaponName(weapons[7],weapname[7],50); GetWeaponName(weapons[8],weapname[8],50);
GetWeaponName(weapons[9],weapname[9],50); GetWeaponName(weapons[10],weapname[10],50); GetWeaponName(weapons[11],weapname[11],50);
format(coordsstring,sizeof(coordsstring),"Waffen: %s[0] %s[%d] %s[%d] %s[%d] %s[%d] %s[%d]",weapname[0],weapname[1],bullets[1],weapname[2],bullets[2],weapname[3],bullets[3],weapname[4],bullets[4],weapname[5],bullets[5]);
SendClientMessage(playerid,COLOR_GRAD6,coordsstring);
format(coordsstring,sizeof(coordsstring),"Waffen: %s[%d] %s[%d] %s[%d] %s[0] %s[0] %s[0]",weapname[6],bullets[6],weapname[7],bullets[7],weapname[8],bullets[8],weapname[9],weapname[10],weapname[11]);
SendClientMessage(playerid,COLOR_GRAD6,coordsstring);
}
else
{
SendClientMessage(playerid,COLOR_GRAD6,"Der Spieler ist nicht in deiner Nähe!");
}
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, "Du bist kein Admin 1450!");
}
return 1;
}
Hat jemand eventuell eine Ahnung was ich hier falschgemacht habe?
Mit freundlichen Grüßen
[GP]Saitek | Timo