PDA

View Full Version : Can someone tell me what is wrong with this?


luckie12
09/05/2014, 05:28 PM
Hi everybody!
I have a problem in a FS that i made a year ago, it worked then but now the Dialog shows up but wont show the selected items. my script:


public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/Help", cmdtext, true, 10) == 0)
{
SendClientMessage(playerid, 55, COLOR_GREEN_EMBED "Loading helplist...");
ShowPlayerDialog(playerid, 1, DIALOG_STYLE_LIST, "What is it you need help with?", "Rules\nTarget of server\nIDK", "Select", "Cancel");

return 1;
}
return 0;
}




public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(response)
{
switch(dialogid)
{
case 1:
{
switch(listitem)
{
case 0:
{
ShowPlayerDialog(playerid, 2, DIALOG_STYLE_MSGBOX, "Server Rules", "1)No Swearing! Results kick/ban\n2)No Truck blocking! Results kick!", "Ok", "Cancel");
}
case 1:
{
ShowPlayerDialog(playerid, 3, DIALOG_STYLE_MSGBOX, "Target of server", "The target of this server is to deliver the items\nto the red markers @ a fabric/store!", "Ok", "Cancel");
}
case 2:
{
if(GetPlayerMoney(playerid) < 3) return SendClientMessage(playerid, 0xFFFFFF, "You don't have enough cash.");
GivePlayerMoney(playerid, -3);
SetPlayerSpecialAction(playerid, SPECIAL_ACTION_DRINK_WINE);
}
}
}
}
}
return 1;
}


Does someone sees the problem?
Thanks -Luckie12

luckie12
09/05/2014, 07:40 PM
Still not working :/

Eth
09/05/2014, 07:51 PM
change the dialog id to something else.