Wie mach ich das man wieder zurück zum hauptmenü gehen kann,
das Zurück button existiert ist aber ohne eine funktion eingebunden.
ShowPlayerDialog(playerid,DIALOG_JUMPS,DIALOG_STYLE_LIST,"Jumps","Nichts","OK","Zurück");
MFG Martinez
Wie mach ich das man wieder zurück zum hauptmenü gehen kann,
das Zurück button existiert ist aber ohne eine funktion eingebunden.
ShowPlayerDialog(playerid,DIALOG_JUMPS,DIALOG_STYLE_LIST,"Jumps","Nichts","OK","Zurück");
MFG Martinez
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if (dialogid == deine_id)
{
if (!response) return ShowPlayerDialog(playerid, die_id_des_vorherigen_dialogs, ...);
// hier was halt passiert wenn man nicht auf abbrechen drückt.
return 1;
}
}
Button geht immer noch nicht.
Soll ich darauf jetzt mit "Dann mach es anders, dann klappt es einwandfrei!" antworten?
Wenn du uns den Code nicht zeigst, können wir nur raten und das macht keinen Spaß.
if(dialogid==DIALOG_MENUTELE)
{
/* if(response)
{*/
if(listitem == 0)
{
if (!response) return ShowPlayerDialog(playerid,DIALOG_MENUTELE,DIALOG_STYLE_LIST,"*Teleports*","Jumps\nFun\nStunt\nDrifts\nDrags\nFahrzeuge & etc\nOrte\nMinispiele\nSpezial\nBasejumping","Ok","Abbruch");
ShowPlayerDialog(playerid,DIALOG_JUMPS,DIALOG_STYLE_LIST,"Jumps","Nichts","OK","Zurück");
}
else if(listitem == 1)
{
if (!response) return ShowPlayerDialog(playerid,DIALOG_MENUTELE,DIALOG_STYLE_LIST,"*Teleports*","Jumps\nFun\nStunt\nDrifts\nDrags\nFahrzeuge & etc\nOrte\nMinispiele\nSpezial\nBasejumping","Ok","Abbruch");
ShowPlayerDialog(playerid,DIALOG_FUN,DIALOG_STYLE_LIST,"Fun","Nichts","OK","Zurück");
}
else if(listitem == 2)
{
if (!response) return ShowPlayerDialog(playerid,DIALOG_MENUTELE,DIALOG_STYLE_LIST,"*Teleports*","Jumps\nFun\nStunt\nDrifts\nDrags\nFahrzeuge & etc\nOrte\nMinispiele\nSpezial\nBasejumping","Ok","Abbruch");
ShowPlayerDialog(playerid,DIALOG_STUNT,DIALOG_STYLE_LIST,"Stunts","/stunt - Stunt Airport","OK","Zurück");
}
else if(listitem == 3)
{
if (!response) return ShowPlayerDialog(playerid,DIALOG_MENUTELE,DIALOG_STYLE_LIST,"*Teleports*","Jumps\nFun\nStunt\nDrifts\nDrags\nFahrzeuge & etc\nOrte\nMinispiele\nSpezial\nBasejumping","Ok","Abbruch");
ShowPlayerDialog(playerid,DIALOG_DRIFT,DIALOG_STYLE_LIST,"Drifts","/drift","OK","Zurück");
}
else if(listitem == 4)
{
if (!response) return ShowPlayerDialog(playerid,DIALOG_MENUTELE,DIALOG_STYLE_LIST,"*Teleports*","Jumps\nFun\nStunt\nDrifts\nDrags\nFahrzeuge & etc\nOrte\nMinispiele\nSpezial\nBasejumping","Ok","Abbruch");
ShowPlayerDialog(playerid,DIALOG_DRAG,DIALOG_STYLE_LIST,"Drags","Nichts","OK","Zurück");
}
else if(listitem == 5)
{
if (!response) return ShowPlayerDialog(playerid,DIALOG_MENUTELE,DIALOG_STYLE_LIST,"*Teleports*","Jumps\nFun\nStunt\nDrifts\nDrags\nFahrzeuge & etc\nOrte\nMinispiele\nSpezial\nBasejumping","Ok","Abbruch");
ShowPlayerDialog(playerid,DIALOG_VEHICLE,DIALOG_STYLE_LIST,"Fahrzeuge & etc","/arch - Wheels Arch Angels\n/wang\n/low\n/trans\n/trans2","OK","Zurück");
}
else if(listitem == 6)
{
if (!response) return ShowPlayerDialog(playerid,DIALOG_MENUTELE,DIALOG_STYLE_LIST,"*Teleports*","Jumps\nFun\nStunt\nDrifts\nDrags\nFahrzeuge & etc\nOrte\nMinispiele\nSpezial\nBasejumping","Ok","Abbruch");
ShowPlayerDialog(playerid,DIALOG_ORTE,DIALOG_STYLE_LIST,"Orte","/ls - Los Santos LSPD\n/sf - San Firro Bahnhof","OK","Zurück");
}
else if(listitem == 7)
{
if (!response) return ShowPlayerDialog(playerid,DIALOG_MENUTELE,DIALOG_STYLE_LIST,"*Teleports*","Jumps\nFun\nStunt\nDrifts\nDrags\nFahrzeuge & etc\nOrte\nMinispiele\nSpezial\nBasejumping","Ok","Abbruch");
ShowPlayerDialog(playerid,DIALOG_MINISPIELE,DIALOG_STYLE_LIST,"Minispiele","/strauma","OK","Zurück");
}
else if(listitem == 8)
{
if (!response) return ShowPlayerDialog(playerid,DIALOG_MENUTELE,DIALOG_STYLE_LIST,"*Teleports*","Jumps\nFun\nStunt\nDrifts\nDrags\nFahrzeuge & etc\nOrte\nMinispiele\nSpezial\nBasejumping","Ok","Abbruch");
ShowPlayerDialog(playerid,DIALOG_SPEZIAL,DIALOG_STYLE_LIST,"Spezial","/strauma","OK","Zurück");
}
else if(listitem == 9)
{
if (!response) return ShowPlayerDialog(playerid,DIALOG_MENUTELE,DIALOG_STYLE_LIST,"*Teleports*","Jumps\nFun\nStunt\nDrifts\nDrags\nFahrzeuge & etc\nOrte\nMinispiele\nSpezial\nBasejumping","Ok","Abbruch");
ShowPlayerDialog(playerid,DIALOG_BASEJUMPING,DIALOG_STYLE_LIST,"Basejumping","/strauma","OK","Zurück");
//}
}
}
else if(dialogid == DIALOG_JUMPS)
{
if(response)
{
if(listitem == 0)
{
SendClientMessage(playerid,0xFF0000FF,"Dieses Teleport existiert nicht");
}
/* else if(listitem == 2)
{
}*/
}
}
else if(dialogid == DIALOG_FUN)
{
if(response)
{
if(listitem == 0)
{
SendClientMessage(playerid,0xFF0000FF,"Dieses Teleport existiert nicht");
}
}
}
else if(dialogid == DIALOG_STUNT)
{
if(response)
{
if(listitem == 0)
{
new name[115];
new pVehicle = GetPlayerVehicleID(playerid);
GetPlayerName(playerid,name,sizeof(name));
SetVehiclePos(pVehicle,375.8990,2536.6965,16.5639);
SetPlayerPos(playerid,375.8990,2536.6965,16.5639);
PutPlayerInVehicle(playerid,pVehicle,0);
format(name,sizeof(name),">>>> TELEPORT <<<< %s hat sich nach /stunt teleportiert. (Stunt Airport)",name);
SendClientMessageToAll(0x00A3FFFF,name);
}
}
}
else if(dialogid == DIALOG_DRIFT)
{
if(response)
{
if(listitem == 0)
{
new name[115];
new pVehicle = GetPlayerVehicleID(playerid);
GetPlayerName(playerid,name,sizeof(name));
SetVehiclePos(pVehicle,2326.8416,1393.2986,42.8203);
SetPlayerPos(playerid,2326.8416,1393.2986,42.8203);
PutPlayerInVehicle(playerid,pVehicle,0);
format(name,sizeof(name),">>>> TELEPORT <<<< %s hat sich nach /drift teleportiert. (LV Parkhaus Drift)",name);
SendClientMessageToAll(0x00A3FFFF,name);
}
}
}
else if(dialogid == DIALOG_DRAG)
{
if(response)
{
if(listitem == 0)
{
SendClientMessage(playerid,0xFF0000FF,"Dieses Teleport existiert nicht");
}
}
}
else if(dialogid == DIALOG_VEHICLE)
{
if(response)
{
if(listitem == 0)
{
new name[115];
new pVehicle = GetPlayerVehicleID(playerid);
GetPlayerName(playerid,name,sizeof(name));
SetVehiclePos(pVehicle,-2706.4104,217.1112,4);
SetPlayerPos(playerid,-2706.4104,217.1112,4);
PutPlayerInVehicle(playerid,pVehicle,0);
format(name,sizeof(name),">>>> TELEPORT <<<< %s hat sich nach /arch teleportiert. (Wheel Arch Angels)",name);
SendClientMessageToAll(0x00A3FFFF,name);
}
}
}
else if(dialogid == DIALOG_ORTE)
{
if(response)
{
if(listitem == 0)
{
new name[115];
new pVehicle = GetPlayerVehicleID(playerid);
GetPlayerName(playerid,name,sizeof(name));
SetVehiclePos(pVehicle,1481.1954,-1740.2444,13);
SetPlayerPos(playerid,1481.1954,-1740.2444,13);
PutPlayerInVehicle(playerid,pVehicle,0);
format(name,sizeof(name),">>>> TELEPORT <<<< %s hat sich nach /ls teleportiert. (Los Santos)",name);
SendClientMessageToAll(0x00A3FFFF,name);
}
else if(listitem == 1)
{
new name[115];
new pVehicle = GetPlayerVehicleID(playerid);
GetPlayerName(playerid,name,sizeof(name));
SetVehiclePos(pVehicle,-1992.3933,145.0940,27.2577);
SetPlayerPos(playerid,-1992.3933,145.0940,27.2577);
PutPlayerInVehicle(playerid,pVehicle,0);
format(name,sizeof(name),">>>> TELEPORT <<<< %s hat sich nach /sf teleportiert. (Los Santos)",name);
SendClientMessageToAll(0x00A3FFFF,name);
}
}
}
else if (dialogid == DIALOG_JUMPS)
{
if (!response) return ShowPlayerDialog(playerid, DIE_ID_DES_VORHERIGEN_DIALOGS, ...);
if (listitem == 0) return SendClientMessage(playerid, 0xFF0000FF, "Dieses Teleport existiert nicht");
if (listitem == 1) return SendClientMessage(playerid, ..., ...);
}
wie mach ich das if (listitem == 0) return
mit
new name[115];
new pVehicle = GetPlayerVehicleID(playerid);
GetPlayerName(playerid,name,sizeof(name));
SetVehiclePos(pVehicle,-2706.4104,217.1112,4);
SetPlayerPos(playerid,-2706.4104,217.1112,4);
PutPlayerInVehicle(playerid,pVehicle,0);
format(name,sizeof(name),">>>> TELEPORT <<<< %s hat sich nach /arch teleportiert. (Wheel Arch Angels)",name);
SendClientMessageToAll(0x00A3FFFF,name);
if (listitem == 0) {
new name[115];
new pVehicle = GetPlayerVehicleID(playerid);
GetPlayerName(playerid,name,sizeof(name));
SetVehiclePos(pVehicle,-2706.4104,217.1112,4);
SetPlayerPos(playerid,-2706.4104,217.1112,4);
PutPlayerInVehicle(playerid,pVehicle,0);
format(name,sizeof(name),">>>> TELEPORT <<<< %s hat sich nach /arch teleportiert. (Wheel Arch Angels)",name);
SendClientMessageToAll(0x00A3FFFF,name);
}
Ok jetzt geht alles, Danke