XetaQuake Posted May 8, 2008 Posted May 8, 2008 Lol XetaQuake easily becomes somebody's fan ^^ It saves money to SQLite database which is included with MTA. It's not MySQL where you have to connect first. SQLite does not require any connection (as it's on the server itself). The database file is called 'registry.db' which is located in server's directory, you can open/edit it using SQLite Database Browser. Ah thanks, nice that the MTA team have includes a SQLite database I think i found a bug too its possibly that the script still don´t save money? And every time i restart the server it says "Creating new DB table bank_accounts". Have anybody else this bug, and @50p is that the bug you found too? // Connect to Server - Open Website // ° Youtube - Twitter °
XetaQuake Posted May 8, 2008 Posted May 8, 2008 Lol XetaQuake easily becomes somebody's fan ^^ It saves money to SQLite database which is included with MTA. It's not MySQL where you have to connect first. SQLite does not require any connection (as it's on the server itself). The database file is called 'registry.db' which is located in server's directory, you can open/edit it using SQLite Database Browser. Ah thanks, nice that the MTA team have includes a SQLite database I think i found a bug too its possibly that the script still don´t save money? And every time i restart the server it says "Creating new DB table bank_accounts". Have anybody else this bug, and @50p is that the bug you found too? // Connect to Server - Open Website // ° Youtube - Twitter °
50p Posted May 8, 2008 Author Posted May 8, 2008 Yes, but now it is fixed. It didn't save money because account in SQL was not created. Now it has been fixed and it's recommended to re-download the script. As said before, it saves money only for logged in players, so if you deposit some money not being logged in you'll lose the money when you log in or when you leave server. When you log in you'll be able to save the $. Also, it uses your registered account's name not your nickname, so you can have different nickname but the money still will be saved onto your account. The message "Creating new DB table bank_accounts" will always be shown because that's the way executeSQLCreateTable is made, but no worries it does not overwrite previously created table. It doesn't do anything when the table already exists. - MTA Script Editor - Ask your scripting questions properly, please. - 50p's public resources - Meta.xml - what is it for? How is it possible LOL
50p Posted May 8, 2008 Author Posted May 8, 2008 Yes, but now it is fixed. It didn't save money because account in SQL was not created. Now it has been fixed and it's recommended to re-download the script. As said before, it saves money only for logged in players, so if you deposit some money not being logged in you'll lose the money when you log in or when you leave server. When you log in you'll be able to save the $. Also, it uses your registered account's name not your nickname, so you can have different nickname but the money still will be saved onto your account. The message "Creating new DB table bank_accounts" will always be shown because that's the way executeSQLCreateTable is made, but no worries it does not overwrite previously created table. It doesn't do anything when the table already exists. - MTA Script Editor - Ask your scripting questions properly, please. - 50p's public resources - Meta.xml - what is it for? How is it possible LOL
XetaQuake Posted May 8, 2008 Posted May 8, 2008 i thank you so much! its works great now, and no errors, infos or warnings in debugscript thanks 50p, you created the first working and public bank script for MTA // Connect to Server - Open Website // ° Youtube - Twitter °
XetaQuake Posted May 8, 2008 Posted May 8, 2008 i thank you so much! its works great now, and no errors, infos or warnings in debugscript thanks 50p, you created the first working and public bank script for MTA // Connect to Server - Open Website // ° Youtube - Twitter °
[TTH]BiZkiT Posted May 9, 2008 Posted May 9, 2008 Jup works fine now thnx a lot ------------------------------------------------------------ lıllılı.ıllı.ılılıılıı.lllııılılıllılı.ıllı.ılılıılıı.lllııılı. Now Playing [TTH Clan Publik] 1:55 ———♡——— 3:50 ◁◁ ▐ ▌ ▷▷ ------------------------------------------------------------ Proud Founder/Leader
[TTH]BiZkiT Posted May 9, 2008 Posted May 9, 2008 Jup works fine now thnx a lot ------------------------------------------------------------ lıllılı.ıllı.ılılıılıı.lllııılılıllılı.ıllı.ılılıılıı.lllııılı. Now Playing [TTH Clan Publik] 1:55 ———♡——— 3:50 ◁◁ ▐ ▌ ▷▷ ------------------------------------------------------------ Proud Founder/Leader
[TTH]BiZkiT Posted May 10, 2008 Posted May 10, 2008 _______________________________I think I found a bug, but I won't tell you what it is as I want to see how long it will take you to find it, lol. I found it i think (You are not able to do) /deposit (amount) while in marker /withdraw (amount) does work ok Only problem (im not good scripter) how to fix it? ------------------------------------------------------------ lıllılı.ıllı.ılılıılıı.lllııılılıllılı.ıllı.ılılıılıı.lllııılı. Now Playing [TTH Clan Publik] 1:55 ———♡——— 3:50 ◁◁ ▐ ▌ ▷▷ ------------------------------------------------------------ Proud Founder/Leader
[TTH]BiZkiT Posted May 10, 2008 Posted May 10, 2008 _______________________________I think I found a bug, but I won't tell you what it is as I want to see how long it will take you to find it, lol. I found it i think (You are not able to do) /deposit (amount) while in marker /withdraw (amount) does work ok Only problem (im not good scripter) how to fix it? ------------------------------------------------------------ lıllılı.ıllı.ılılıılıı.lllııılılıllılı.ıllı.ılılıılıı.lllııılı. Now Playing [TTH Clan Publik] 1:55 ———♡——— 3:50 ◁◁ ▐ ▌ ▷▷ ------------------------------------------------------------ Proud Founder/Leader
50p Posted May 10, 2008 Author Posted May 10, 2008 (edited) Ok, thanks for the report. I appreciate it. The problem is that I check if user is registered and use player_mta_account which is nil. To fix it yourself: remove lines 122, 123 and the 'end' which closes the if statement (which should be at line 126 after 2 lines removed). Or re-download the script. Edited May 10, 2008 by Guest - MTA Script Editor - Ask your scripting questions properly, please. - 50p's public resources - Meta.xml - what is it for? How is it possible LOL
50p Posted May 10, 2008 Author Posted May 10, 2008 (edited) Ok, thanks for the report. I appreciate it. The problem is that I check if user is registered and use player_mta_account which is nil. To fix it yourself: remove lines 122, 123 and the 'end' which closes the if statement (which should be at line 126 after 2 lines removed). Or re-download the script. Edited May 10, 2008 by Guest - MTA Script Editor - Ask your scripting questions properly, please. - 50p's public resources - Meta.xml - what is it for? How is it possible LOL
XetaQuake Posted May 10, 2008 Posted May 10, 2008 today i found a bug too: when you a login in, you get the info how many money you have, right? every player can see it! thats not good because then the players see how many money you have // Connect to Server - Open Website // ° Youtube - Twitter °
XetaQuake Posted May 10, 2008 Posted May 10, 2008 today i found a bug too: when you a login in, you get the info how many money you have, right? every player can see it! thats not good because then the players see how many money you have // Connect to Server - Open Website // ° Youtube - Twitter °
50p Posted May 10, 2008 Author Posted May 10, 2008 today i found a bug too: when you a login in, you get the info how many money you have, right? every player can see it!thats not good because then the players see how many money you have I wish I've read this message before I uploaded v1.2. Ok, fixed. Re-download or replace line 96: outputChatBox( "Bank balance: $ " .. tostring( playersAccount[ source ].balance ) ) with this: outputChatBox( "Bank balance: $ " .. tostring( playersAccount[ source ].balance ), source, 255, 255, 0 ) - MTA Script Editor - Ask your scripting questions properly, please. - 50p's public resources - Meta.xml - what is it for? How is it possible LOL
50p Posted May 10, 2008 Author Posted May 10, 2008 today i found a bug too: when you a login in, you get the info how many money you have, right? every player can see it!thats not good because then the players see how many money you have I wish I've read this message before I uploaded v1.2. Ok, fixed. Re-download or replace line 96: outputChatBox( "Bank balance: $ " .. tostring( playersAccount[ source ].balance ) ) with this: outputChatBox( "Bank balance: $ " .. tostring( playersAccount[ source ].balance ), source, 255, 255, 0 ) - MTA Script Editor - Ask your scripting questions properly, please. - 50p's public resources - Meta.xml - what is it for? How is it possible LOL
XetaQuake Posted May 10, 2008 Posted May 10, 2008 thanks 50p, now its perfect // Connect to Server - Open Website // ° Youtube - Twitter °
XetaQuake Posted May 10, 2008 Posted May 10, 2008 thanks 50p, now its perfect // Connect to Server - Open Website // ° Youtube - Twitter °
50p Posted May 11, 2008 Author Posted May 11, 2008 Update (v1.3)! For more info go to the download page or the first post! EDIT: Update (v1.3.1)! There was a problem with depositing negative amount of money. It's recommended to re-download if you don't want your players to be rich! - MTA Script Editor - Ask your scripting questions properly, please. - 50p's public resources - Meta.xml - what is it for? How is it possible LOL
50p Posted May 11, 2008 Author Posted May 11, 2008 Update (v1.3)! For more info go to the download page or the first post! EDIT: Update (v1.3.1)! There was a problem with depositing negative amount of money. It's recommended to re-download if you don't want your players to be rich! - MTA Script Editor - Ask your scripting questions properly, please. - 50p's public resources - Meta.xml - what is it for? How is it possible LOL
Guest Posted May 25, 2008 Posted May 25, 2008 ok here is my problem. after starting the bank system needs restarting after each player join the error comes up attempt to compair boolean. but once the bank is restarted it functions for all players currently on the server and a new player joins and I get the same thing all over again. any clues?
Guest Posted May 25, 2008 Posted May 25, 2008 ok here is my problem. after starting the bank system needs restarting after each player join the error comes up attempt to compair boolean. but once the bank is restarted it functions for all players currently on the server and a new player joins and I get the same thing all over again. any clues?
50p Posted May 25, 2008 Author Posted May 25, 2008 Can you please give me the error and the line that happens? It will help a lot. - MTA Script Editor - Ask your scripting questions properly, please. - 50p's public resources - Meta.xml - what is it for? How is it possible LOL
50p Posted May 25, 2008 Author Posted May 25, 2008 Can you please give me the error and the line that happens? It will help a lot. - MTA Script Editor - Ask your scripting questions properly, please. - 50p's public resources - Meta.xml - what is it for? How is it possible LOL
Guest Posted May 27, 2008 Posted May 27, 2008 Can you please give me the error and the line that happens? It will help a lot. bank.script.server.lua:85: atempt to index field '?' (a nil value) this error is when login occurs bank.script.server.lua:51: attempt to index field '?' (a nil value) on logout.
Recommended Posts