30.04.2012, 12:13
PHP код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
{
switch(1) // Dialog for shop
{
case 1:
{
if(!response)
{
SendClientMessage(playerid, 0xFF0000FF, "You didn't wanted to buy anything.");
return 1; // ...
}
switch(listitem)
{
case 0: // Items
{
GivePlayerMoney(playerid,-10);
}
case 1:
{
GivePlayerMoney(playerid,-5);
}
case 2:
{
GivePlayerMoney(playerid,-25);
}
case 3:
{
GivePlayerMoney(playerid,-33);
}
case 4:
{
GivePlayerMoney(playerid,-22);
}
case 5:
{
GivePlayerMoney(playerid,-6);
}
case 6:
{
GivePlayerMoney(playerid,-21);
}
case 7:
{
GivePlayerMoney(playerid,-12);
}
case 8:
{
GivePlayerMoney(playerid,-42);
}
// Add the rest of your listitems for dialog 1 here
}
}
// Add the rest of your dialogs here
}
return 0; // If you put return 1 here the callback will not continue to be called in other scripts (filterscripts, etc.).
}
return 1;
}
Line 341 : warning 225: unreachable code
What should I do?