Hallo liebe Community,
Ich hab probiert /Wanted als Dialog zufassen aber dann kommt Pawno Library Compiler Funktioniert nicht mehr!....
mein Code
oben im Script :
new wanted = GetPlayerWantedLevel(targetid);
Dilaog :
if (strcmp("/wanted",cmdtext, true, 10) == 0)
{
ShowPlayerDialog(playerid,Wanted,DIALOG_STYLE_LIST,"Gesuchte Personen","Spieler : %s | Wantedlevel : %d","Okay","Abbrechen",SpielerName(playerid),GetPlayerWantedLevel(playerid));
return 1;
}
if(dialogid == Wanted)
{
if(response == 0) { SCM(playerid,Rot,"Du hast das Wantedsystem geschlossen"); return 1; }
if(response == 1)
{
if(listitem == 0)
{
for(new i=0; i < MAX_PLAYERS; i++)
{
new x;
string = "";
if(IsPlayerConnected(i))
{
if(GetPlayerWantedLevel(i) > 0)
{
GetPlayerName(i, giveplayer, sizeof(giveplayer));
format(string, sizeof(string), "%s%s: %d", string,giveplayer,GetPlayerWantedLevel(i));
x++;
if(x > 3) {
SCM(playerid, COLOR_YELLOW, string);
x = 0;
format(string, sizeof(string), "");
} else {
format(string, sizeof(string), "%s, ", string);
// "/wantedJefferson[4], Lytadsa[31]
}
}
}
}
if(x <= 3 && x > 0)
{
string[strlen(string)-2] = '.';
SCM(playerid, COLOR_YELLOW, string);
}
}
}
}