Tag,
hab hier ein kleines Problemchen mit nem Dialog;
Listitem 0 wird erfolgreich aufgerufen, 1 erscheint jedoch kein Dialog.
Keine Ahnung woran das liegt. Kann mir kurz wer helfen :D^^ ?
if (dialogid == DIALOG_PLAYERS && response)
{
PickedID[playerid] = Listitem[playerid][listitem];
ShowPlayerDialog(playerid, DIALOG_PLAYERS_OV, DIALOG_STYLE_LIST, "Informationen", "K/D Rate\nSchussgenauigkeit", "Weiter", "Abbruch");
}
if (dialogid == DIALOG_PLAYERS_OV && response)
{
if (listitem == 0)
{
new dialog[360];
format(dialog, sizeof(dialog), "\
{FFFFFF}Kill / Death Ratio von %s:\n\n\
{FFFFFF}Morde:\t\t\t{FF8800}%d\n\
{FFFFFF}Tode:\t\t\t{FF8800}%d\n\
{FFFFFF}K/D:\t\t\t{FF8800}%0.2f\n\n\
{FFFFFF}Morde (Anteil):\t{FF8800}%d%%\n\
{FFFFFF}Tode (Anteil):\t\t{FF8800}%d%%\n\n\
{FFFFFF}Gelandete Treffer:\t{FF8800}%d",
FullName(PickedID[playerid]),
GetPlayerKills(PickedID[playerid]),
GetPlayerDeaths(PickedID[playerid]),
((GetPlayerKills(PickedID[playerid]) * 1.0) / (GetPlayerDeaths(PickedID[playerid]) * 1.0)),
floatround((100.0 / (GetPlayerKills(PickedID[playerid]) + GetPlayerDeaths(PickedID[playerid]))) * GetPlayerKills(PickedID[playerid]) * 1.0),
floatround((100.0 / (GetPlayerKills(PickedID[playerid]) + GetPlayerDeaths(PickedID[playerid]))) * GetPlayerDeaths(PickedID[playerid])),
Player[playerid][landedhits]);
ShowPlayerDialog(playerid, DIALOG_PLAYERS_OV + 1, DIALOG_STYLE_MSGBOX, "K/D Ratio", dialog, "Ok", "Schließen");
}
else if (listitem == 1)
{
new dialog[360];
format(dialog, sizeof(dialog), "\
{FFFFFF}Genauigkeit von %s:\n\n\
{FFFFFF}Kopftreffer:\t\t{FF8800}%.1f%%\n\
{FFFFFF}Körpertreffer:\t\t{FF8800}%.1f%%\n\
{FFFFFF}Beintreffer:\t\t{FF8800}%.1f%%",
FullName(PickedID[playerid]),
Player[PickedID[playerid]][headhits] / ((Player[PickedID[playerid]][headhits] + Player[PickedID[playerid]][bodyhits] + Player[PickedID[playerid]][leghits]) / 100),
Player[PickedID[playerid]][bodyhits] / ((Player[PickedID[playerid]][headhits] + Player[PickedID[playerid]][bodyhits] + Player[PickedID[playerid]][leghits]) / 100),
Player[PickedID[playerid]][leghits] / ((Player[PickedID[playerid]][headhits] + Player[PickedID[playerid]][bodyhits] + Player[PickedID[playerid]][leghits]) / 100));
ShowPlayerDialog(playerid, DIALOG_PLAYERS_OV + 2, DIALOG_STYLE_MSGBOX, "Trefferquote", dialog, "Ok", "Schließen");
}
}