Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <a_samp>
- #include <DOF2>
- #include <zcmd>
- #define DIALOG_DEPOSITAR 7777
- #define DIALOG_SACAR 8888
- #define DIALOG_SALDO 9999
- #define DIALOG_IDTRANSFERIR 1010
- #define DIALOG_TRANSFERIR 1111
- #define DIALOG_LOGIN 1212
- #define DIALOG_REGISTRO 1313
- enum PlayerInfo{Saldo};
- new pInfo[MAX_PLAYERS][PlayerInfo];
- new Arquivo[50], Senha[20], String[128], Quantia, ID;
- new Text:BANCOBG[15], Text:MAIN[22], PlayerText:PSALDO[5][MAX_PLAYERS];
- public OnFilterScriptInit()
- {
- print("\n-----------------------------------------------_");
- print(" Simples sistema de banco em TextDraws e dialogs v2 ");
- print(" By : 1sBedxx ");
- print("-------------------------------------------------\n");
- BANCOBG[0] = TextDrawCreate(401.375000, 186.416656, "usebox");
- TextDrawLetterSize(BANCOBG[0], 0.000000, 16.211114);
- TextDrawTextSize(BANCOBG[0], 234.875000, 0.000000);
- TextDrawAlignment(BANCOBG[0], 1);
- TextDrawColor(BANCOBG[0], 0);
- TextDrawUseBox(BANCOBG[0], true);
- TextDrawBoxColor(BANCOBG[0], 102);
- TextDrawSetShadow(BANCOBG[0], 0);
- TextDrawSetOutline(BANCOBG[0], 0);
- TextDrawFont(BANCOBG[0], 0);
- BANCOBG[1] = TextDrawCreate(239.375000, 186.083343, "LD_SPAC:white");
- TextDrawLetterSize(BANCOBG[1], 0.000000, 0.000000);
- TextDrawTextSize(BANCOBG[1], 158.125000, 146.999969);
- TextDrawAlignment(BANCOBG[1], 1);
- TextDrawColor(BANCOBG[1], 286331374);
- TextDrawSetShadow(BANCOBG[1], 0);
- TextDrawSetOutline(BANCOBG[1], 0);
- TextDrawBackgroundColor(BANCOBG[1], 572662510);
- TextDrawFont(BANCOBG[1], 4);
- BANCOBG[13] = TextDrawCreate(393.875000, 195.166580, "usebox");
- TextDrawLetterSize(BANCOBG[13], 0.000000, 13.553705);
- TextDrawTextSize(BANCOBG[13], 242.375000, 0.000000);
- TextDrawAlignment(BANCOBG[13], 1);
- TextDrawColor(BANCOBG[13], 0);
- TextDrawUseBox(BANCOBG[13], true);
- TextDrawBoxColor(BANCOBG[13], 102);
- TextDrawSetShadow(BANCOBG[13], 0);
- TextDrawSetOutline(BANCOBG[13], 0);
- TextDrawFont(BANCOBG[13], 0);
- BANCOBG[2] = TextDrawCreate(392.000000, 196.333343, "usebox");
- TextDrawLetterSize(BANCOBG[2], 0.000000, 2.470367);
- TextDrawTextSize(BANCOBG[2], 243.625000, 0.000000);
- TextDrawAlignment(BANCOBG[2], 1);
- TextDrawColor(BANCOBG[2], 0);
- TextDrawUseBox(BANCOBG[2], true);
- TextDrawBoxColor(BANCOBG[2], 102);
- TextDrawSetShadow(BANCOBG[2], 0);
- TextDrawSetOutline(BANCOBG[2], 0);
- TextDrawFont(BANCOBG[2], 0);
- BANCOBG[3] = TextDrawCreate(392.625000, 196.333343, "usebox");
- TextDrawLetterSize(BANCOBG[3], 0.000000, 3.507406);
- TextDrawTextSize(BANCOBG[3], 243.625000, 0.000000);
- TextDrawAlignment(BANCOBG[3], 1);
- TextDrawColor(BANCOBG[3], 0);
- TextDrawUseBox(BANCOBG[3], true);
- TextDrawBoxColor(BANCOBG[3], 102);
- TextDrawSetShadow(BANCOBG[3], 0);
- TextDrawSetOutline(BANCOBG[3], 0);
- TextDrawFont(BANCOBG[3], 0);
- BANCOBG[4] = TextDrawCreate(392.625000, 232.500000, "usebox");
- TextDrawLetterSize(BANCOBG[4], 0.000000, 9.275923);
- TextDrawTextSize(BANCOBG[4], 243.625000, 0.000000);
- TextDrawAlignment(BANCOBG[4], 1);
- TextDrawColor(BANCOBG[4], 0);
- TextDrawUseBox(BANCOBG[4], true);
- TextDrawBoxColor(BANCOBG[4], 102);
- TextDrawSetShadow(BANCOBG[4], 0);
- TextDrawSetOutline(BANCOBG[4], 0);
- TextDrawFont(BANCOBG[4], 0);
- BANCOBG[5] = TextDrawCreate(261.875000, 237.999984, "LD_SPAC:white");
- TextDrawLetterSize(BANCOBG[5], 0.000000, 0.000000);
- TextDrawTextSize(BANCOBG[5], 112.500000, 24.499984);
- TextDrawAlignment(BANCOBG[5], 1);
- TextDrawColor(BANCOBG[5], 572662510);
- TextDrawSetShadow(BANCOBG[5], 0);
- TextDrawSetOutline(BANCOBG[5], 0);
- TextDrawFont(BANCOBG[5], 4);
- BANCOBG[6] = TextDrawCreate(383.250000, 238.916671, "usebox");
- TextDrawLetterSize(BANCOBG[6], 0.000000, 2.988890);
- TextDrawTextSize(BANCOBG[6], 258.000000, 0.000000);
- TextDrawAlignment(BANCOBG[6], 1);
- TextDrawColor(BANCOBG[6], 0);
- TextDrawUseBox(BANCOBG[6], true);
- TextDrawBoxColor(BANCOBG[6], 102);
- TextDrawSetShadow(BANCOBG[6], 0);
- TextDrawSetOutline(BANCOBG[6], 0);
- TextDrawFont(BANCOBG[6], 0);
- BANCOBG[7] = TextDrawCreate(263.125000, 281.750274, "LD_SPAC:white");
- TextDrawLetterSize(BANCOBG[7], 0.000000, 0.000000);
- TextDrawTextSize(BANCOBG[7], 111.875000, 23.916671);
- TextDrawAlignment(BANCOBG[7], 1);
- TextDrawColor(BANCOBG[7], 572662510);
- TextDrawSetShadow(BANCOBG[7], 0);
- TextDrawSetOutline(BANCOBG[7], 0);
- TextDrawFont(BANCOBG[7], 4);
- BANCOBG[8] = TextDrawCreate(383.875000, 282.083190, "usebox");
- TextDrawLetterSize(BANCOBG[8], 0.000000, 2.988890);
- TextDrawTextSize(BANCOBG[8], 259.250000, 0.000000);
- TextDrawAlignment(BANCOBG[8], 1);
- TextDrawColor(BANCOBG[8], 0);
- TextDrawUseBox(BANCOBG[8], true);
- TextDrawBoxColor(BANCOBG[8], 102);
- TextDrawSetShadow(BANCOBG[8], 0);
- TextDrawSetOutline(BANCOBG[8], 0);
- TextDrawFont(BANCOBG[8], 0);
- BANCOBG[9] = TextDrawCreate(285.000000, 198.333358, "~r~BANCO");
- TextDrawLetterSize(BANCOBG[9], 0.477500, 1.979168);
- TextDrawAlignment(BANCOBG[9], 1);
- TextDrawColor(BANCOBG[9], -1);
- TextDrawSetShadow(BANCOBG[9], 0);
- TextDrawSetOutline(BANCOBG[9], 1);
- TextDrawBackgroundColor(BANCOBG[9], 51);
- TextDrawFont(BANCOBG[9], 2);
- TextDrawSetProportional(BANCOBG[9], 1);
- BANCOBG[10] = TextDrawCreate(286.250000, 242.666793, "~r~LOGAR");
- TextDrawLetterSize(BANCOBG[10], 0.446874, 1.559166);
- TextDrawAlignment(BANCOBG[10], 1);
- TextDrawColor(BANCOBG[10], -1);
- TextDrawSetShadow(BANCOBG[10], 0);
- TextDrawSetOutline(BANCOBG[10], 1);
- TextDrawBackgroundColor(BANCOBG[10], 51);
- TextDrawFont(BANCOBG[10], 2);
- TextDrawSetProportional(BANCOBG[10], 1);
- TextDrawSetSelectable(BANCOBG[10], true);
- TextDrawTextSize(BANCOBG[10], 342, 10.000000);
- BANCOBG[11] = TextDrawCreate(275.000000, 286.416625, "~r~REGISTRAR");
- TextDrawLetterSize(BANCOBG[11], 0.374998, 1.389997);
- TextDrawAlignment(BANCOBG[11], 1);
- TextDrawColor(BANCOBG[11], -1);
- TextDrawSetShadow(BANCOBG[11], 0);
- TextDrawSetOutline(BANCOBG[11], 1);
- TextDrawBackgroundColor(BANCOBG[11], 51);
- TextDrawFont(BANCOBG[11], 2);
- TextDrawSetProportional(BANCOBG[11], 1);
- TextDrawSetSelectable(BANCOBG[11], true);
- TextDrawTextSize(BANCOBG[11], 385, 10.000000);
- BANCOBG[12] = TextDrawCreate(246.250000, 220.500000, "LD_SPAC:white");
- TextDrawLetterSize(BANCOBG[12], 0.000000, 0.000000);
- TextDrawTextSize(BANCOBG[12], 144.375000, 1.750000);
- TextDrawAlignment(BANCOBG[12], 1);
- TextDrawColor(BANCOBG[12], 286331374);
- TextDrawSetShadow(BANCOBG[12], 0);
- TextDrawSetOutline(BANCOBG[12], 0);
- TextDrawBackgroundColor(BANCOBG[12], 125);
- TextDrawFont(BANCOBG[12], 4);
- BANCOBG[14] = TextDrawCreate(386.875000, 181.416687, "~r~x");
- TextDrawLetterSize(BANCOBG[14], 0.449999, 1.600000);
- TextDrawAlignment(BANCOBG[14], 1);
- TextDrawColor(BANCOBG[14], -1);
- TextDrawSetShadow(BANCOBG[14], 0);
- TextDrawSetOutline(BANCOBG[14], 1);
- TextDrawBackgroundColor(BANCOBG[14], 51);
- TextDrawFont(BANCOBG[14], 1);
- TextDrawSetProportional(BANCOBG[14], 1);
- TextDrawSetSelectable(BANCOBG[14], true);
- TextDrawTextSize(BANCOBG[14], 486, 10.000000);
- MAIN[0] = TextDrawCreate(495.125000, 160.750000, "usebox");
- TextDrawLetterSize(MAIN[0], 0.000000, 23.211111);
- TextDrawTextSize(MAIN[0], 141.750000, 0.000000);
- TextDrawAlignment(MAIN[0], 1);
- TextDrawColor(MAIN[0], 0);
- TextDrawUseBox(MAIN[0], true);
- TextDrawBoxColor(MAIN[0], 102);
- TextDrawSetShadow(MAIN[0], 0);
- TextDrawSetOutline(MAIN[0], 0);
- TextDrawFont(MAIN[0], 0);
- MAIN[1] = TextDrawCreate(147.500000, 162.750000, "LD_SPAC:white");
- TextDrawLetterSize(MAIN[1], 0.000000, 0.000000);
- TextDrawTextSize(MAIN[1], 341.875000, 204.750000);
- TextDrawAlignment(MAIN[1], 1);
- TextDrawColor(MAIN[1], 572662527);
- TextDrawSetShadow(MAIN[1], 0);
- TextDrawSetOutline(MAIN[1], 0);
- TextDrawFont(MAIN[1], 4);
- MAIN[2] = TextDrawCreate(481.375000, 174.750000, "usebox");
- TextDrawLetterSize(MAIN[2], 0.000000, 3.442593);
- TextDrawTextSize(MAIN[2], 154.875000, 0.000000);
- TextDrawAlignment(MAIN[2], 1);
- TextDrawColor(MAIN[2], 0);
- TextDrawUseBox(MAIN[2], true);
- TextDrawBoxColor(MAIN[2], 102);
- TextDrawSetShadow(MAIN[2], 0);
- TextDrawSetOutline(MAIN[2], 0);
- TextDrawFont(MAIN[2], 0);
- MAIN[3] = TextDrawCreate(482.000000, 174.750000, "usebox");
- TextDrawLetterSize(MAIN[3], 0.000000, 4.479628);
- TextDrawTextSize(MAIN[3], 154.875000, 0.000000);
- TextDrawAlignment(MAIN[3], 1);
- TextDrawColor(MAIN[3], 0);
- TextDrawUseBox(MAIN[3], true);
- TextDrawBoxColor(MAIN[3], 102);
- TextDrawSetShadow(MAIN[3], 0);
- TextDrawSetOutline(MAIN[3], 0);
- TextDrawFont(MAIN[3], 0);
- MAIN[4] = TextDrawCreate(291.250000, 185.500030, "~r~BANCO");
- TextDrawLetterSize(MAIN[4], 0.449999, 1.600000);
- TextDrawAlignment(MAIN[4], 1);
- TextDrawColor(MAIN[4], -1);
- TextDrawSetShadow(MAIN[4], 0);
- TextDrawSetOutline(MAIN[4], 1);
- TextDrawBackgroundColor(MAIN[4], 51);
- TextDrawFont(MAIN[4], 2);
- TextDrawSetProportional(MAIN[4], 1);
- MAIN[5] = TextDrawCreate(254.375000, 208.833358, "~r~ESCOLHA UMA ACAO ABAIXO");
- TextDrawLetterSize(MAIN[5], 0.236874, 0.689999);
- TextDrawAlignment(MAIN[5], 1);
- TextDrawColor(MAIN[5], -1);
- TextDrawSetShadow(MAIN[5], 0);
- TextDrawSetOutline(MAIN[5], 1);
- TextDrawBackgroundColor(MAIN[5], 51);
- TextDrawFont(MAIN[5], 2);
- TextDrawSetProportional(MAIN[5], 1);
- MAIN[6] = TextDrawCreate(482.000000, 225.499984, "usebox");
- TextDrawLetterSize(MAIN[6], 0.000000, 14.785184);
- TextDrawTextSize(MAIN[6], 154.875000, 0.000000);
- TextDrawAlignment(MAIN[6], 1);
- TextDrawColor(MAIN[6], 0);
- TextDrawUseBox(MAIN[6], true);
- TextDrawBoxColor(MAIN[6], 102);
- TextDrawSetShadow(MAIN[6], 0);
- TextDrawSetOutline(MAIN[6], 0);
- TextDrawFont(MAIN[6], 0);
- MAIN[7] = TextDrawCreate(477.000000, 231.333328, "usebox");
- TextDrawLetterSize(MAIN[7], 0.000000, 13.359262);
- TextDrawTextSize(MAIN[7], 160.500000, 0.000000);
- TextDrawAlignment(MAIN[7], 1);
- TextDrawColor(MAIN[7], 0);
- TextDrawUseBox(MAIN[7], true);
- TextDrawBoxColor(MAIN[7], 102);
- TextDrawSetShadow(MAIN[7], 0);
- TextDrawSetOutline(MAIN[7], 0);
- TextDrawFont(MAIN[7], 0);
- MAIN[8] = TextDrawCreate(470.750000, 237.750000, "usebox");
- TextDrawLetterSize(MAIN[8], 0.000000, 11.738889);
- TextDrawTextSize(MAIN[8], 167.375000, 0.000000);
- TextDrawAlignment(MAIN[8], 1);
- TextDrawColor(MAIN[8], 0);
- TextDrawUseBox(MAIN[8], true);
- TextDrawBoxColor(MAIN[8], 102);
- TextDrawSetShadow(MAIN[8], 0);
- TextDrawSetOutline(MAIN[8], 0);
- TextDrawFont(MAIN[8], 0);
- MAIN[9] = TextDrawCreate(173.125000, 239.750000, "LD_SPAC:white");
- TextDrawLetterSize(MAIN[9], 0.000000, 0.000000);
- TextDrawTextSize(MAIN[9], 291.875000, 102.083312);
- TextDrawAlignment(MAIN[9], 1);
- TextDrawColor(MAIN[9], 572662527);
- TextDrawSetShadow(MAIN[9], 0);
- TextDrawSetOutline(MAIN[9], 0);
- TextDrawFont(MAIN[9], 4);
- MAIN[10] = TextDrawCreate(447.000000, 256.999969, "usebox");
- TextDrawLetterSize(MAIN[10], 0.000000, 7.461111);
- TextDrawTextSize(MAIN[10], 189.250000, 0.000000);
- TextDrawAlignment(MAIN[10], 1);
- TextDrawColor(MAIN[10], 0);
- TextDrawUseBox(MAIN[10], true);
- TextDrawBoxColor(MAIN[10], 102);
- TextDrawSetShadow(MAIN[10], 0);
- TextDrawSetOutline(MAIN[10], 0);
- TextDrawFont(MAIN[10], 0);
- MAIN[11] = TextDrawCreate(195.625000, 259.000000, "LD_SPAC:white");
- TextDrawLetterSize(MAIN[11], 0.000000, 0.000000);
- TextDrawTextSize(MAIN[11], 245.625000, 63.583312);
- TextDrawAlignment(MAIN[11], 1);
- TextDrawColor(MAIN[11], 572662527);
- TextDrawUseBox(MAIN[11], true);
- TextDrawBoxColor(MAIN[11], 102);
- TextDrawSetShadow(MAIN[11], 0);
- TextDrawSetOutline(MAIN[11], 0);
- TextDrawFont(MAIN[11], 4);
- MAIN[12] = TextDrawCreate(443.250000, 289.083343, "usebox");
- TextDrawLetterSize(MAIN[12], 0.000000, 0.266666);
- TextDrawTextSize(MAIN[12], 193.000000, 0.000000);
- TextDrawAlignment(MAIN[12], 1);
- TextDrawColor(MAIN[12], 0);
- TextDrawUseBox(MAIN[12], true);
- TextDrawBoxColor(MAIN[12], 102);
- TextDrawSetShadow(MAIN[12], 0);
- TextDrawSetOutline(MAIN[12], 0);
- TextDrawFont(MAIN[12], 0);
- MAIN[13] = TextDrawCreate(327.000000, 261.083312, "usebox");
- TextDrawLetterSize(MAIN[13], 0.000000, 6.553708);
- TextDrawTextSize(MAIN[13], 313.625000, 0.000000);
- TextDrawAlignment(MAIN[13], 1);
- TextDrawColor(MAIN[13], 0);
- TextDrawUseBox(MAIN[13], true);
- TextDrawBoxColor(MAIN[13], 102);
- TextDrawSetShadow(MAIN[13], 0);
- TextDrawSetOutline(MAIN[13], 0);
- TextDrawFont(MAIN[13], 0);
- MAIN[14] = TextDrawCreate(203.125000, 266.583251, "~r~DEPOSITAR");
- TextDrawLetterSize(MAIN[14], 0.449999, 1.600000);
- TextDrawAlignment(MAIN[14], 1);
- TextDrawColor(MAIN[14], -1);
- TextDrawSetShadow(MAIN[14], 0);
- TextDrawSetOutline(MAIN[14], 1);
- TextDrawBackgroundColor(MAIN[14], 51);
- TextDrawFont(MAIN[14], 2);
- TextDrawSetProportional(MAIN[14], 1);
- TextDrawSetSelectable(MAIN[14], true);
- TextDrawTextSize(MAIN[14], 306, 10.000000);
- MAIN[15] = TextDrawCreate(351.250000, 266.000000, "~r~SACAR");
- TextDrawLetterSize(MAIN[15], 0.449999, 1.600000);
- TextDrawAlignment(MAIN[15], 1);
- TextDrawColor(MAIN[15], -1);
- TextDrawSetShadow(MAIN[15], 0);
- TextDrawSetOutline(MAIN[15], 1);
- TextDrawBackgroundColor(MAIN[15], 51);
- TextDrawFont(MAIN[15], 2);
- TextDrawSetProportional(MAIN[15], 1);
- TextDrawSetSelectable(MAIN[15], true);
- TextDrawTextSize(MAIN[15], 452, 10.000000);
- MAIN[16] = TextDrawCreate(223.125000, 302.166656, "~r~SALDO");
- TextDrawLetterSize(MAIN[16], 0.449999, 1.600000);
- TextDrawAlignment(MAIN[16], 1);
- TextDrawColor(MAIN[16], -1);
- TextDrawSetShadow(MAIN[16], 0);
- TextDrawSetOutline(MAIN[16], 1);
- TextDrawBackgroundColor(MAIN[16], 51);
- TextDrawFont(MAIN[16], 2);
- TextDrawSetProportional(MAIN[16], 1);
- TextDrawSetSelectable(MAIN[16], true);
- TextDrawTextSize(MAIN[16], 326, 10.000000);
- MAIN[17] = TextDrawCreate(331.875000, 301.583312, "~r~TRANSFERIR");
- TextDrawLetterSize(MAIN[17], 0.404374, 1.518332);
- TextDrawAlignment(MAIN[17], 1);
- TextDrawColor(MAIN[17], -1);
- TextDrawSetShadow(MAIN[17], 0);
- TextDrawSetOutline(MAIN[17], 1);
- TextDrawBackgroundColor(MAIN[17], 51);
- TextDrawFont(MAIN[17], 2);
- TextDrawSetProportional(MAIN[17], 1);
- TextDrawSetSelectable(MAIN[17], true);
- TextDrawTextSize(MAIN[17], 432, 10.000000);
- MAIN[18] = TextDrawCreate(474.375000, 164.499954, "~r~x");
- TextDrawLetterSize(MAIN[18], 0.449999, 1.600000);
- TextDrawAlignment(MAIN[18], 1);
- TextDrawColor(MAIN[18], -1);
- TextDrawSetShadow(MAIN[18], 0);
- TextDrawSetOutline(MAIN[18], 1);
- TextDrawBackgroundColor(MAIN[18], 51);
- TextDrawFont(MAIN[18], 1);
- TextDrawSetProportional(MAIN[18], 1);
- TextDrawSetSelectable(MAIN[18], true);
- TextDrawTextSize(MAIN[18], 578, 10.000000);
- MAIN[19] = TextDrawCreate(157.500000, 172.666656, "LD_SPAC:white");
- TextDrawLetterSize(MAIN[19], 0.000000, 0.000000);
- TextDrawTextSize(MAIN[19], 315.000000, 0.583343);
- TextDrawAlignment(MAIN[19], 1);
- TextDrawColor(MAIN[19], -16777046);
- TextDrawSetShadow(MAIN[19], 0);
- TextDrawSetOutline(MAIN[19], 0);
- TextDrawFont(MAIN[19], 4);
- MAIN[20] = TextDrawCreate(157.500000, 224.000000, "LD_SPAC:white");
- TextDrawLetterSize(MAIN[20], 0.000000, 0.000000);
- TextDrawTextSize(MAIN[20], 322.500000, 0.583328);
- TextDrawAlignment(MAIN[20], 1);
- TextDrawColor(MAIN[20], -16777046);
- TextDrawSetShadow(MAIN[20], 0);
- TextDrawSetOutline(MAIN[20], 0);
- TextDrawFont(MAIN[20], 4);
- MAIN[21] = TextDrawCreate(157.500000, 360.500000, "LD_SPAC:white");
- TextDrawLetterSize(MAIN[21], 0.000000, 0.000000);
- TextDrawTextSize(MAIN[21], 322.500000, 0.583312);
- TextDrawAlignment(MAIN[21], 1);
- TextDrawColor(MAIN[21], -16777046);
- TextDrawSetShadow(MAIN[21], 0);
- TextDrawSetOutline(MAIN[21], 0);
- TextDrawFont(MAIN[21], 4);
- //Create3DTextLabel("Banco\n/banco ou 'F'", 0x9955DEEE, 2308.6851, -13.2479, 26.7422, 10,0);
- //CreatePickup(1274, 1, 2308.6851, -13.2479, 26.7422, -1);
- Create3DTextLabel("Banco\n/banco ou 'F'", 0x9955DEEE, 2316.5586,-7.2823,26.7422, 10,0);
- Create3DTextLabel("Banco\n/banco ou 'F'", 0x9955DEEE, 2316.5962,-9.9491,26.7422, 10,0);
- Create3DTextLabel("Banco\n/banco ou 'F'", 0x9955DEEE, 2316.6160,-12.5703,26.7422, 10,0);
- CreatePickup(1274, 1, 2316.5586,-7.2823,26.7422, -1);
- CreatePickup(1274, 1, 2316.5962,-9.9491,26.7422, -1);
- CreatePickup(1274, 1, 2316.6160,-12.5703,26.7422, -1);
- return 1;
- }
- public OnFilterScriptExit()
- {
- DOF2_Exit();
- return 1;
- }
- public OnPlayerConnect(playerid)
- {
- PSALDO[0][playerid] = CreatePlayerTextDraw(playerid, 410.750000, 236.583328, "usebox");
- PlayerTextDrawLetterSize(playerid, PSALDO[0][playerid], 0.000000, 4.155553);
- PlayerTextDrawTextSize(playerid, PSALDO[0][playerid], 219.250000, 0.000000);
- PlayerTextDrawAlignment(playerid, PSALDO[0][playerid], 1);
- PlayerTextDrawColor(playerid, PSALDO[0][playerid], 0);
- PlayerTextDrawUseBox(playerid, PSALDO[0][playerid], true);
- PlayerTextDrawBoxColor(playerid, PSALDO[0][playerid], 102);
- PlayerTextDrawSetShadow(playerid, PSALDO[0][playerid], 0);
- PlayerTextDrawSetOutline(playerid, PSALDO[0][playerid], 0);
- PlayerTextDrawFont(playerid, PSALDO[0][playerid], 0);
- PSALDO[1][playerid] = CreatePlayerTextDraw(playerid, 223.750000, 236.833328, "LD_SPAC:white");
- PlayerTextDrawLetterSize(playerid, PSALDO[1][playerid], 0.000000, 0.000000);
- PlayerTextDrawTextSize(playerid, PSALDO[1][playerid], 183.125000, 36.749984);
- PlayerTextDrawAlignment(playerid, PSALDO[1][playerid], 1);
- PlayerTextDrawColor(playerid, PSALDO[1][playerid], 286331306);
- PlayerTextDrawSetShadow(playerid, PSALDO[1][playerid], 0);
- PlayerTextDrawSetOutline(playerid, PSALDO[1][playerid], 0);
- PlayerTextDrawFont(playerid, PSALDO[1][playerid], 4);
- PSALDO[2][playerid] = CreatePlayerTextDraw(playerid, 231.250000, 242.666702, "~r~Ola¡ Sr.Hanshioisa seu~n~saldo atual e de");
- PlayerTextDrawLetterSize(playerid, PSALDO[2][playerid], 0.215624, 0.864999);
- PlayerTextDrawAlignment(playerid, PSALDO[2][playerid], 1);
- PlayerTextDrawColor(playerid, PSALDO[2][playerid], -1);
- PlayerTextDrawSetShadow(playerid, PSALDO[2][playerid], 0);
- PlayerTextDrawSetOutline(playerid, PSALDO[2][playerid], 1);
- PlayerTextDrawBackgroundColor(playerid, PSALDO[2][playerid], 51);
- PlayerTextDrawFont(playerid, PSALDO[2][playerid], 2);
- PlayerTextDrawSetProportional(playerid, PSALDO[2][playerid], 1);
- PSALDO[3][playerid] = CreatePlayerTextDraw(playerid, 230.625000, 259.583343, "~g~$0");
- PlayerTextDrawLetterSize(playerid, PSALDO[3][playerid], 0.315624, 0.929166);
- PlayerTextDrawAlignment(playerid, PSALDO[3][playerid], 1);
- PlayerTextDrawColor(playerid, PSALDO[3][playerid], -1);
- PlayerTextDrawSetShadow(playerid, PSALDO[3][playerid], 0);
- PlayerTextDrawSetOutline(playerid, PSALDO[3][playerid], 1);
- PlayerTextDrawBackgroundColor(playerid, PSALDO[3][playerid], 51);
- PlayerTextDrawFont(playerid, PSALDO[3][playerid], 2);
- PlayerTextDrawSetProportional(playerid, PSALDO[3][playerid], 1);
- PSALDO[4][playerid] = CreatePlayerTextDraw(playerid, 392.500000, 237.416671, "~r~x");
- PlayerTextDrawLetterSize(playerid, PSALDO[4][playerid], 0.449999, 1.600000);
- PlayerTextDrawAlignment(playerid, PSALDO[4][playerid], 1);
- PlayerTextDrawColor(playerid, PSALDO[4][playerid], -1);
- PlayerTextDrawSetShadow(playerid, PSALDO[4][playerid], 0);
- PlayerTextDrawSetOutline(playerid, PSALDO[4][playerid], 1);
- PlayerTextDrawBackgroundColor(playerid, PSALDO[4][playerid], 51);
- PlayerTextDrawFont(playerid, PSALDO[4][playerid], 1);
- PlayerTextDrawSetProportional(playerid, PSALDO[4][playerid], 1);
- PlayerTextDrawSetSelectable(playerid, PSALDO[4][playerid], true);
- CarregarDados(playerid);
- return 1;
- }
- forward Mostrarsaldo(playerid);
- public Mostrarsaldo(playerid)
- {
- Fecharbanco(playerid);
- PlayerTextDrawShow(playerid, PSALDO[0][playerid]);
- PlayerTextDrawShow(playerid, PSALDO[1][playerid]);
- format(String, sizeof(String), "Ola Sr. %s seu~n~saldo atual e de", Playername(playerid));
- PlayerTextDrawSetString(playerid, PSALDO[2][playerid], String);
- PlayerTextDrawShow(playerid, PSALDO[2][playerid]);
- format(Arquivo, 50, "Banco/Contas/%s.ini", Playername(playerid));
- pInfo[playerid][Saldo] = DOF2_GetInt(Arquivo, "Saldo");
- format(String, sizeof(String), " -> $%d", pInfo[playerid][Saldo]);
- PlayerTextDrawSetString(playerid, PSALDO[3][playerid], String);
- PlayerTextDrawShow(playerid, PSALDO[3][playerid]);
- PlayerTextDrawShow(playerid, PSALDO[4][playerid]);
- SelectTextDraw(playerid, 0xFF0000AA);
- return 1;
- }
- forward Fecharsaldo(playerid);
- public Fecharsaldo(playerid)
- {
- PlayerTextDrawHide(playerid, PSALDO[0][playerid]);
- PlayerTextDrawHide(playerid, PSALDO[1][playerid]);
- PlayerTextDrawHide(playerid, PSALDO[2][playerid]);
- PlayerTextDrawHide(playerid, PSALDO[3][playerid]);
- PlayerTextDrawHide(playerid, PSALDO[4][playerid]);
- Mostrarbanco(playerid);
- return 1;
- }
- public OnPlayerDisconnect(playerid, reason)
- {
- return 1;
- }
- CMD:banco(playerid, params[])
- {
- if(IsPlayerInRangeOfPoint(playerid, 1.0, 2316.5586,-7.2823,26.7422) || IsPlayerInRangeOfPoint(playerid, 1.0, 2316.5962,-9.9491,26.7422) || IsPlayerInRangeOfPoint(playerid, 1.0, 2316.6160,-12.5703,26.7422))
- {
- TextDrawShowForPlayer(playerid, BANCOBG[0]);
- TextDrawShowForPlayer(playerid, BANCOBG[1]);
- TextDrawShowForPlayer(playerid, BANCOBG[2]);
- TextDrawShowForPlayer(playerid, BANCOBG[3]);
- TextDrawShowForPlayer(playerid, BANCOBG[4]);
- TextDrawShowForPlayer(playerid, BANCOBG[5]);
- TextDrawShowForPlayer(playerid, BANCOBG[6]);
- TextDrawShowForPlayer(playerid, BANCOBG[7]);
- TextDrawShowForPlayer(playerid, BANCOBG[8]);
- TextDrawShowForPlayer(playerid, BANCOBG[9]);
- TextDrawShowForPlayer(playerid, BANCOBG[10]);
- TextDrawShowForPlayer(playerid, BANCOBG[11]);
- TextDrawShowForPlayer(playerid, BANCOBG[12]);
- TextDrawShowForPlayer(playerid, BANCOBG[13]);
- TextDrawShowForPlayer(playerid, BANCOBG[14]);
- SelectTextDraw(playerid, 0xFF0000AA);
- return 1;
- }
- return 1;
- }
- CMD:irb(playerid, params[])
- {
- SetPlayerPos(playerid, 2306.9338, -16.0632, 26.7496);
- SetPlayerInterior(playerid, 0);
- return 1;
- }
- public OnPlayerClickTextDraw(playerid, Text: clickedid)
- {
- if(clickedid == BANCOBG[10])
- {
- format(Arquivo, sizeof(Arquivo), "Banco/Contas/%s.ini", Playername(playerid));
- if (!DOF2_FileExists(Arquivo)) return SendClientMessage(playerid, 0xFF0000AA, "Erro : Você não possui uma conta, se registre para acessar nossos serviços.");
- if (DOF2_FileExists(Arquivo))
- {
- format(String, sizeof(String), "Olá Sr. %s digite sua senha para logar-se.", Playername(playerid));
- ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT, "BANCO", String, "Entrar", "Sair");
- }
- return 1;
- }
- else if(clickedid == BANCOBG[11])
- {
- format(Arquivo, sizeof(Arquivo), "Banco/Contas/%s.ini", Playername(playerid));
- if (DOF2_FileExists(Arquivo))
- {
- SendClientMessage(playerid, 0xFF0000AA, "Erro : Você já possui uma conta, logue-se para acessar nossos serviços.");
- }
- else
- {
- format(String, sizeof(String), "Olá Sr. %s, registre-se agora e desfrute de nossos serviços.", Playername(playerid));
- ShowPlayerDialog(playerid, DIALOG_REGISTRO, DIALOG_STYLE_INPUT, "BANCO", String, "Registrar", "Sair");
- }
- return 1;
- }
- else if(clickedid == BANCOBG[14])
- {
- TextDrawHideForPlayer(playerid, BANCOBG[0]);
- TextDrawHideForPlayer(playerid, BANCOBG[1]);
- TextDrawHideForPlayer(playerid, BANCOBG[2]);
- TextDrawHideForPlayer(playerid, BANCOBG[3]);
- TextDrawHideForPlayer(playerid, BANCOBG[4]);
- TextDrawHideForPlayer(playerid, BANCOBG[5]);
- TextDrawHideForPlayer(playerid, BANCOBG[6]);
- TextDrawHideForPlayer(playerid, BANCOBG[7]);
- TextDrawHideForPlayer(playerid, BANCOBG[8]);
- TextDrawHideForPlayer(playerid, BANCOBG[9]);
- TextDrawHideForPlayer(playerid, BANCOBG[10]);
- TextDrawHideForPlayer(playerid, BANCOBG[11]);
- TextDrawHideForPlayer(playerid, BANCOBG[12]);
- TextDrawHideForPlayer(playerid, BANCOBG[13]);
- TextDrawHideForPlayer(playerid, BANCOBG[14]);
- CancelSelectTextDraw(playerid);
- return 1;
- }
- if(clickedid == MAIN[14]) return ShowPlayerDialog(playerid, DIALOG_DEPOSITAR, DIALOG_STYLE_INPUT, "Depositar", "Insira a quantiade que deseja depositar.", "Depositar", "Cancelar");
- if(clickedid == MAIN[15]) return ShowPlayerDialog(playerid, DIALOG_SACAR, DIALOG_STYLE_INPUT, "Sacar", "Insira a quantiade que deseja sacar.", "Sacar", "Cancelar");
- if(clickedid == MAIN[16]) return Mostrarsaldo(playerid);
- if(clickedid == MAIN[17]) return ShowPlayerDialog(playerid, DIALOG_IDTRANSFERIR, DIALOG_STYLE_INPUT, "Transferir", "ID do player que você deseja fazer a transferência bancária :", "Proximo", "Cancelar");
- if(clickedid == MAIN[18]) return Fecharbanco(playerid);
- return 1;
- }
- public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
- {
- if(playertextid == PSALDO[4][playerid]) return Fecharsaldo(playerid);
- return 1;
- }
- public OnPlayerText(playerid, text[])
- {
- return 1;
- }
- public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
- {
- if ((newkeys==KEY_SECONDARY_ATTACK))
- {
- cmd_banco(playerid, "/banco");
- }
- return 1;
- }
- public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
- {
- switch(dialogid)
- {
- case DIALOG_REGISTRO:
- {
- if (!response) return 1;
- if (response)
- {
- format(Arquivo, 50, "Banco/Contas/%s.ini", Playername(playerid));
- DOF2_CreateFile(Arquivo);
- DOF2_SetString(Arquivo, "Senha", inputtext);
- DOF2_SaveFile();
- new len = strlen(inputtext);
- if (len < 5 || len > 20) return ShowPlayerDialog(playerid, DIALOG_REGISTRO, DIALOG_STYLE_INPUT, "BANCO", "Senha deve conter no minimo 5 caracteres.", "Entrar", "Sair");
- SendClientMessage(playerid, 0xFF0000A, "Conta criada com sucesso.");
- }
- }
- case DIALOG_LOGIN:
- {
- if (!response) return 1;
- if (response)
- {
- format(Arquivo, 50, "Banco/Contas/%s.ini", Playername(playerid));
- format(Senha, 20, "%s", strval(inputtext));
- if (strcmp(inputtext, DOF2_GetString(Arquivo, "Senha"), true) == 0)
- {
- if (!strlen(inputtext))
- {
- ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT, "BANCO", "Senha errada, digite a senha correta para logar-se.", "Entrar", "Sair");
- return SendClientMessage(playerid, 0xFF0000AA, "Senha incorreta, digite novamente!!!");
- }
- SendClientMessage(playerid, 0xFF0000A, "Logado com sucesso."); // logou
- // esconder o registro/login se a senha for correta
- TextDrawHideForPlayer(playerid, BANCOBG[0]);
- TextDrawHideForPlayer(playerid, BANCOBG[1]);
- TextDrawHideForPlayer(playerid, BANCOBG[2]);
- TextDrawHideForPlayer(playerid, BANCOBG[3]);
- TextDrawHideForPlayer(playerid, BANCOBG[4]);
- TextDrawHideForPlayer(playerid, BANCOBG[5]);
- TextDrawHideForPlayer(playerid, BANCOBG[6]);
- TextDrawHideForPlayer(playerid, BANCOBG[7]);
- TextDrawHideForPlayer(playerid, BANCOBG[8]);
- TextDrawHideForPlayer(playerid, BANCOBG[9]);
- TextDrawHideForPlayer(playerid, BANCOBG[10]);
- TextDrawHideForPlayer(playerid, BANCOBG[11]);
- TextDrawHideForPlayer(playerid, BANCOBG[12]);
- TextDrawHideForPlayer(playerid, BANCOBG[13]);
- TextDrawHideForPlayer(playerid, BANCOBG[14]);
- CancelSelectTextDraw(playerid);
- // mostrar o banco se a senha for correta
- Mostrarbanco(playerid);
- }
- else
- {
- ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT, "BANCO", "Senha errada, insira a senha correta.", "Entrar", "Sair");
- SendClientMessage(playerid, 0xFF0000AA, "Senha incorreta, digite novamente!!!");
- }
- }
- }
- case DIALOG_DEPOSITAR:
- {
- if(response)
- {
- Quantia = strval(inputtext);
- if(Quantia > GetPlayerMoney(playerid)) return SendClientMessage(playerid, 0xFF0000AA, "• Você não pode depositar mais do que tem.");
- if(Quantia == 0) return SendClientMessage(playerid, 0xFF0000AA, "• Você não depositou nada.");
- GivePlayerMoney(playerid, -Quantia);
- pInfo[playerid][Saldo] = pInfo[playerid][Saldo] +Quantia;
- format(String, sizeof(String), "• Voçe depositou $%d", Quantia);
- SendClientMessage(playerid, 0xFF0000A, String);
- format(String, sizeof(String), "• Seu novo saldo bancário é de $%d ", pInfo[playerid][Saldo]);
- SendClientMessage(playerid, 0xFF0000A, String);
- SalvarDados(playerid);
- }
- }
- case DIALOG_SACAR:
- {
- if(response)
- {
- Quantia = strval(inputtext);
- if(Quantia > pInfo[playerid][Saldo]) return SendClientMessage(playerid, 0xFF0000AA, "• Você não pode sacar mais do que tem em sua conta bancaria.");
- if(Quantia == 0) return SendClientMessage(playerid, 0xFF0000AA, "• Você não sacou nada.");
- GivePlayerMoney(playerid, Quantia);
- pInfo[playerid][Saldo] = pInfo[playerid][Saldo] -Quantia;
- format(String, sizeof(String), "• Você sacou $%d", Quantia);
- SendClientMessage(playerid, 0xFF0000AA, String);
- format(String, sizeof(String), "• Seu novo saldo bancário é de $%d ", pInfo[playerid][Saldo]);
- SendClientMessage(playerid, 0xFF0000A, String);
- SalvarDados(playerid);
- }
- }
- case DIALOG_IDTRANSFERIR:
- {
- if(response)
- {
- ID = strval(inputtext);
- if(!IsNumeric(inputtext)) return SendClientMessage(playerid, 0xFF0000AA, "• Digite um ID valido.");
- if(!IsPlayerConnected(ID)) return SendClientMessage(playerid, 0xFF0000AA, "• Jogador offline.");
- ShowPlayerDialog(playerid, DIALOG_TRANSFERIR, DIALOG_STYLE_INPUT, "Transferir", "Quantidade que você deseja transferir :", "Transferir", "Cancelar");
- }
- return 1;
- }
- case DIALOG_TRANSFERIR:
- {
- if(response)
- {
- Quantia = strval(inputtext);
- if(Quantia > pInfo[playerid][Saldo]) return SendClientMessage(playerid, 0xFF0000AA, "• Você não tem todo esse dinheiro em sua conta bancaria.");
- if(Quantia == 0) return SendClientMessage(playerid, 0xFF0000AA, "• Você não pode transferir $ 0 !!");
- pInfo[playerid][Saldo] = pInfo[playerid][Saldo] -Quantia, pInfo[ID][Saldo] = pInfo[ID][Saldo] +Quantia;
- format(String, sizeof(String), "• Você transferiu $ %d para o player %s.", Quantia, Playername(ID));
- SendClientMessage(playerid, 0xFF0000A, String);
- format(String, sizeof(String), "• Seu novo saldo bancário é de $%d.", pInfo[playerid][Saldo]);
- SendClientMessage(playerid, 0xFF0000A, String);
- format(String, sizeof(String), "• Você recebeu uma transferencia bancaria de $ %d do player %s.", Quantia, Playername(playerid));
- SendClientMessage(ID, 0xFF0000A, String);
- SalvarDados(playerid);
- }
- }
- }
- return 1;
- }
- forward Mostrarbanco(playerid);
- public Mostrarbanco(playerid)
- {
- TextDrawShowForPlayer(playerid, MAIN[0]);
- TextDrawShowForPlayer(playerid, MAIN[1]);
- TextDrawShowForPlayer(playerid, MAIN[2]);
- TextDrawShowForPlayer(playerid, MAIN[3]);
- TextDrawShowForPlayer(playerid, MAIN[4]);
- TextDrawShowForPlayer(playerid, MAIN[5]);
- TextDrawShowForPlayer(playerid, MAIN[6]);
- TextDrawShowForPlayer(playerid, MAIN[7]);
- TextDrawShowForPlayer(playerid, MAIN[8]);
- TextDrawShowForPlayer(playerid, MAIN[9]);
- TextDrawShowForPlayer(playerid, MAIN[10]);
- TextDrawShowForPlayer(playerid, MAIN[11]);
- TextDrawShowForPlayer(playerid, MAIN[12]);
- TextDrawShowForPlayer(playerid, MAIN[13]);
- TextDrawShowForPlayer(playerid, MAIN[14]);
- TextDrawShowForPlayer(playerid, MAIN[15]);
- TextDrawShowForPlayer(playerid, MAIN[16]);
- TextDrawShowForPlayer(playerid, MAIN[17]);
- TextDrawShowForPlayer(playerid, MAIN[18]);
- TextDrawShowForPlayer(playerid, MAIN[19]);
- TextDrawShowForPlayer(playerid, MAIN[20]);
- TextDrawShowForPlayer(playerid, MAIN[21]);
- SelectTextDraw(playerid, 0xFF0000AA);
- return 1;
- }
- forward Fecharbanco(playerid);
- public Fecharbanco(playerid)
- {
- TextDrawHideForPlayer(playerid, MAIN[0]);
- TextDrawHideForPlayer(playerid, MAIN[1]);
- TextDrawHideForPlayer(playerid, MAIN[2]);
- TextDrawHideForPlayer(playerid, MAIN[3]);
- TextDrawHideForPlayer(playerid, MAIN[4]);
- TextDrawHideForPlayer(playerid, MAIN[5]);
- TextDrawHideForPlayer(playerid, MAIN[6]);
- TextDrawHideForPlayer(playerid, MAIN[7]);
- TextDrawHideForPlayer(playerid, MAIN[8]);
- TextDrawHideForPlayer(playerid, MAIN[9]);
- TextDrawHideForPlayer(playerid, MAIN[10]);
- TextDrawHideForPlayer(playerid, MAIN[11]);
- TextDrawHideForPlayer(playerid, MAIN[12]);
- TextDrawHideForPlayer(playerid, MAIN[13]);
- TextDrawHideForPlayer(playerid, MAIN[14]);
- TextDrawHideForPlayer(playerid, MAIN[15]);
- TextDrawHideForPlayer(playerid, MAIN[16]);
- TextDrawHideForPlayer(playerid, MAIN[17]);
- TextDrawHideForPlayer(playerid, MAIN[18]);
- TextDrawHideForPlayer(playerid, MAIN[19]);
- TextDrawHideForPlayer(playerid, MAIN[20]);
- TextDrawHideForPlayer(playerid, MAIN[21]);
- CancelSelectTextDraw(playerid);
- return 1;
- }
- stock Playername(playerid)
- {
- new Name[MAX_PLAYER_NAME];
- GetPlayerName(playerid, Name, MAX_PLAYER_NAME);
- return Name;
- }
- SalvarDados(playerid)
- {
- format(Arquivo, 40, "Banco/Contas/%s.ini", Playername(playerid));
- if(!DOF2_FileExists(Arquivo)) DOF2_CreateFile(Arquivo);
- DOF2_SetInt(Arquivo, "Saldo", pInfo[playerid][Saldo]);
- return DOF2_SaveFile();
- }
- CarregarDados(playerid)
- {
- format(Arquivo, 40, "Banco/Contas/%s.ini", Playername(playerid));
- pInfo[playerid][Saldo] = DOF2_GetInt(Arquivo, "Saldo");
- return 1;
- }
- IsNumeric(const string[])
- {
- for (new i = 0, j = strlen(string); i < j; i++)
- {
- if (string[i] > '9' || string[i] < '0') return 0;
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement