else if (areatype[areaid][0] == AREA_TYPE_BANK)
{
if (pbank[playerid][1] == areatype[areaid][1]) {
bcps[pbank[playerid][0]][pbank[playerid][1]] = 1;
for (new i = 0; i < PLAYERS; i++) {
if (IsPlayerConnected2(i)) {
if (pbank[i][0] == pbank[playerid][0] && pbank[i][1] == pbank[playerid][1] && i != playerid) {
pbank[i][1] = -1;
for (new c = 0; c < sizeof(bankChecks); c++) {
if (bcps[pbank[playerid][0]][c] == 0) {
pbank[i][1] = c;
SetPlayerCheckpoint(i, bankChecks[pbank[i][1]][0], bankChecks[pbank[i][1]][1], bankChecks[pbank[i][1]][2]-1.0, 1.0);
gPlayerCheckpointStatus[i] = CP_BANK;
break;
}
}
if (pbank[i][1] == -1) {
DisablePlayerCheckpoint(i);
gPlayerCheckpointStatus[i] = 0;
}
}
}
}
ShowPlayerDialog2(playerid, DIALOG_BANK_REGISTER, DIALOG_STYLE_MSGBOX, "Bank Register", "Would you like to register bank account?", "Register", "Cancel");
ShowPlayerDialog2(playerid, DIALOG_BANK, DIALOG_STYLE_LIST, "San Andreas State Bank", "Deposit\nWithdraw\nBalance\nSend Money\nCollect Interest", "Select", "Close");
}
}
try this out
https://sampforum.blast.hk/showthread.php?tid=606450 |
bankreg=1
then it save it in player account
//myscript is on dini
//dont give me Y_ini or MySql
If you mean after the player clicks "Register" button, and then save the variable, show us your OnDialogResponse.
Or maybe you meant after the player register the account, the next time he enters the bank it won't ask him again to register? |