14.07.2011, 12:45
it sounds like your dialog ids are being messed up, here's how i do it so they don't get muddled up
I have a stock called ResetDialogs which resets a set of pvars such like this:
then when i want to show them a dialog I'll use
then when they respond to a dialog, after i have figured out which dialog it is I reset the dialogids with ResetDialogs(playerid)
don't forget to also reset the dialogs when the player joins the server
I have a stock called ResetDialogs which resets a set of pvars such like this:
pawn Код:
ResetDialogs(playerid)
{
SetPVarInt(playerid,"dialog1",-1); since no dialog created would be id -1
}
pawn Код:
new DID;
ShowPlayerDialog(playerid,DID,ect...
SetPVarInt(playerid,"dialog1",DID);
pawn Код:
if(dialogid == GetPVarInt(playerid,"dialog1"))
{
ResetDialogs(playerid);