[HILFE]Dialoge

Wichtiger Hinweis: Bitte ändert nicht manuell die Schriftfarbe auf schwarz sondern belasst es bei der Standardeinstellung. Somit tragt ihr dazu bei dass euer Text auch bei Verwendung unseren dunklen Forenstils noch lesbar ist!

Tipp: Ihr wollt längere Codeausschnitte oder Logfiles bereitstellen? Benutzt unseren eigenen PasteBin-Dienst Link
  • Hey irgendwas stimmt bei mir nicht aber ich finde den Fehler einfach nicht vieleicht kann mir hier einer helfen.
    Also zum Problem...ich habe einen /help Befehl mit Dialog erstellt er funktioniert eigentlich auch 1A nur wen ich auf das letzte Listitem klicke passiert garnichts obwohl es im Script reingeschrieben ist.
    Hier mal die Codes:
    Der Befehl
    if(strcmp(cmdtext, "/help", true)==0)
    {
    ShowPlayerDialog(playerid,msg,DIALOG_STYLE_LIST,"Die Befehle auf diesem Server","Account\nHandy\nAuto\nLeader\nFraktion\nBank","OK","Abbruch") ;
    return 1;
    }
    OnDialogResponse:
    if(dialogid == 222)
    {
    if(response)
    {
    if(listitem == 0)
    {
    SendClientMessage(playerid,COLOR_WHITE,"/animlist /rules /stats /changepass /levelup /upgrade");
    SendClientMessage(playerid,COLOR_WHITE,"/pay /charity /time /buy /kleidung(nur im BINCO) /resetupgrades(50k)");
    SendClientMessage(playerid,COLOR_WHITE,"/report /cancel /accept /eject /usedrugs /contract /admins /me");
    SendClientMessage(playerid,COLOR_WHITE,"/(s)chreien /inv");
    }
    if(listitem == 1)
    {
    SendClientMessage(playerid,COLOR_WHITE," /call /sms /togphone");
    }
    if(listitem == 2)
    {
    SendClientMessage(playerid,COLOR_WHITE," /carlock /carkey /carsell /carkeylock /givecarkey /parken /giveparkrights");
    SendClientMessage(playerid,COLOR_WHITE," /carkeylock");
    }
    if(listitem == 3)
    {
    SendClientMessage(playerid,COLOR_WHITE," /invite /uninvite /giverank");
    }
    if(listitem == 4)
    {
    if(PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 1)
    {
    SendClientMessage(playerid, COLOR_YELLOW2, ":: LSPD :: (/r)adio (/d)epartments (/m)egaphone (/su)spect /mdc /arrest /duty /wanted (/cu)ff (/ta)zer /undercover /backup(/bk)");
    SendClientMessage(playerid, COLOR_YELLOW2, ":: LSPD :: /frisk /friskinv /take /ticket (/gov)ernment /deliver /ram /swat /authorizeswat /deauthorizeswat /drag /copuntie");
    SendClientMessage(playerid, COLOR_YELLOW2, ":: LSPD :: /backupclear(/bkc) /roadblock(/rb) /roadunblock(/rrb) /roadunblockall(/rrball) /showbadge /tracelastcall(/tlc) /weplicense");


    }
    if(PlayerInfo[playerid][pLeader] == 2 || PlayerInfo[playerid][pMember] == 2)
    {
    SendClientMessage(playerid, COLOR_YELLOW2, ":: FBI :: (/r)adio (/d)epartments (/m)egaphone (/su)spect /mdc /arrest /duty /wanted (/cu)ff (/ta)zer /agent /showid /friskinv");
    SendClientMessage(playerid, COLOR_YELLOW2, ":: FBI :: /frisk /take /ticket (/gov)ernment /deliver /ram /drag /copuntie /authorizetactical /deauthorizetactical /tactical");


    }
    if(PlayerInfo[playerid][pLeader] == 3 || PlayerInfo[playerid][pMember] == 3)
    {
    SendClientMessage(playerid, COLOR_YELLOW2, ":: Military :: (/r)adio (/d)epartments (/m)egaphone (/su)spect /mdc /arrest /wanted (/cu)ff (/ta)zer");
    SendClientMessage(playerid, COLOR_YELLOW2, ":: Military :: /frisk /friskinv /take /ticket (/gov)ernment /deliver /ram /drag /copuntie");


    }
    if(PlayerInfo[playerid][pLeader] == 17 || PlayerInfo[playerid][pMember] == 17)
    {
    SendClientMessage(playerid, COLOR_YELLOW2, "::Oamt:: /oticket /oamt(Taste: 2 o. N-Pad +)/tazer");
    SendClientMessage(playerid, COLOR_YELLOW2, "::Mehr Befehle folgen!");


    }
    if(listitem == 5)
    {
    SendClientMessage(playerid,COLOR_WHITE," /abheben /einzahlen /stand(zeigt deinen Kontostand an)");
    }
    }
    }
    }
    return 1;
    }
    Und natürlich die definierung:
    #define msg 222
    Also bis jetzt habe ich noch keinen Fehler entdeckt woran es liegen könnte(Er will mir den Text von listitem 5 nicht anzeigen wen ich drauf klicke)
    Ich hoffe einer von euch erkennt den Fehler.
    Mfg
    [FoR]Hardcore

  • if(dialogid == 222)
    {
    if(response)
    {
    if(listitem == 0)
    {
    SendClientMessage(playerid,COLOR_WHITE,"/animlist /rules /stats /changepass /levelup /upgrade");
    SendClientMessage(playerid,COLOR_WHITE,"/pay /charity /time /buy /kleidung(nur im BINCO) /resetupgrades(50k)");
    SendClientMessage(playerid,COLOR_WHITE,"/report /cancel /accept /eject /usedrugs /contract /admins /me");
    SendClientMessage(playerid,COLOR_WHITE,"/(s)chreien /inv");
    }
    if(listitem == 1)
    {
    SendClientMessage(playerid,COLOR_WHITE," /call /sms /togphone");
    }
    if(listitem == 2)
    {
    SendClientMessage(playerid,COLOR_WHITE," /carlock /carkey /carsell /carkeylock /givecarkey /parken /giveparkrights");
    SendClientMessage(playerid,COLOR_WHITE," /carkeylock");
    }
    if(listitem == 3)
    {
    SendClientMessage(playerid,COLOR_WHITE," /invite /uninvite /giverank");
    }
    if(listitem == 4)
    {
    if(PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 1)
    {
    SendClientMessage(playerid, COLOR_YELLOW2, ":: LSPD :: (/r)adio (/d)epartments (/m)egaphone (/su)spect /mdc /arrest /duty /wanted (/cu)ff (/ta)zer /undercover /backup(/bk)");
    SendClientMessage(playerid, COLOR_YELLOW2, ":: LSPD :: /frisk /friskinv /take /ticket (/gov)ernment /deliver /ram /swat /authorizeswat /deauthorizeswat /drag /copuntie");
    SendClientMessage(playerid, COLOR_YELLOW2, ":: LSPD :: /backupclear(/bkc) /roadblock(/rb) /roadunblock(/rrb) /roadunblockall(/rrball) /showbadge /tracelastcall(/tlc) /weplicense");


    }
    if(PlayerInfo[playerid][pLeader] == 2 || PlayerInfo[playerid][pMember] == 2)
    {
    SendClientMessage(playerid, COLOR_YELLOW2, ":: FBI :: (/r)adio (/d)epartments (/m)egaphone (/su)spect /mdc /arrest /duty /wanted (/cu)ff (/ta)zer /agent /showid /friskinv");
    SendClientMessage(playerid, COLOR_YELLOW2, ":: FBI :: /frisk /take /ticket (/gov)ernment /deliver /ram /drag /copuntie /authorizetactical /deauthorizetactical /tactical");


    }
    if(PlayerInfo[playerid][pLeader] == 3 || PlayerInfo[playerid][pMember] == 3)
    {
    SendClientMessage(playerid, COLOR_YELLOW2, ":: Military :: (/r)adio (/d)epartments (/m)egaphone (/su)spect /mdc /arrest /wanted (/cu)ff (/ta)zer");
    SendClientMessage(playerid, COLOR_YELLOW2, ":: Military :: /frisk /friskinv /take /ticket (/gov)ernment /deliver /ram /drag /copuntie");


    }
    if(PlayerInfo[playerid][pLeader] == 17 || PlayerInfo[playerid][pMember] == 17)
    {
    SendClientMessage(playerid, COLOR_YELLOW2, "::Oamt:: /oticket /oamt(Taste: 2 o. N-Pad +)/tazer");
    SendClientMessage(playerid, COLOR_YELLOW2, "::Mehr Befehle folgen!");


    }
    }
    if(listitem == 5)
    {
    SendClientMessage(playerid,COLOR_WHITE," /abheben /einzahlen /stand(zeigt deinen Kontostand an)");
    }
    }
    }
    return 1;
    }

  • d hast in listitem 4 5 abgefrag einfach ein klamma fehler xO