23.05.2013, 06:23
hey guys - got this inside ondialogresponse :
basically either on displaying the msgbox dialog or hitting the close button the server crashes. Code compiles great! Any idea why server is crashing?
pawn Код:
if(dialogid == TSYS_DIALOG_BANK_MENU) {
if(!response) return SendClientMessage(playerid, TSYS_COLOR_BRIGHTRED, "Input Cancelled by user!");
switch(listitem) {
case 0:{
format(string1,sizeof(string1),"%s's Bank Statement.",TSYSPlayerInfo[playerid][name]);
format(string2,sizeof(string2),"Branch Info: %s \nClient Name: %s \nAccount Number: #%d \nAccount Balance: $%d",TSYSBankInfo[bankid][name],TSYSPlayerInfo[playerid][name],TSYSPlayerInfo[playerid][acc],TSYSPlayerInfo[playerid][bank]);
ShowPlayerDialog(playerid, TSYS_DIALOG_BANK_STATEMENT, DIALOG_STYLE_MSGBOX, string1, string2, "Close", "");
}
case 1:{
ShowPlayerDialog(playerid, TSYS_DIALOG_BANK_WITHDRAW, DIALOG_STYLE_INPUT, "RPG Bank System: ", "Please enter the amount you wish to withdraw from your bank account.", "Submit", "Cancel");
}
case 2:{
ShowPlayerDialog(playerid, TSYS_DIALOG_BANK_DEPOSIT, DIALOG_STYLE_INPUT, "RPG Bank System: ", "Please enter the amount you wish to deposit into your bank account.", "Submit", "Cancel");
}
}
}

