Raised This Month: $ Target: $400
 0% 

SM Bank Mod: MySQL


Post New Thread Reply   
 
Thread Tools Display Modes
Solltex
Member
Join Date: Dec 2004
Old 03-25-2008 , 10:10   Re: SM Bank Mod: MySQL
Reply With Quote #131

here log, ( no error_log)
Code:
L 03/25/2008 - 17:31:01: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:02: [a_mysql_beta.smx] [MYSQLmanager] SELECT `money`, id FROM sm_users WHERE `plname` = 'Igniussss'
L 03/25/2008 - 17:31:03: [a_mysql_beta.smx] Insert: Em4S -- INSERT INTO sm_users(plname) VALUES ('Em4S')
L 03/25/2008 - 17:31:05: [a_mysql_beta.smx] Insert: Em4S -- INSERT INTO sm_users(plname) VALUES ('Em4S')
L 03/25/2008 - 17:31:05: [a_mysql_beta.smx] Insert: Igniussss -- INSERT INTO sm_users(plname) VALUES ('Igniussss')
L 03/25/2008 - 17:31:06: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:07: [a_mysql_beta.smx] Insert: Igniussss -- INSERT INTO sm_users(plname) VALUES ('Igniussss')
L 03/25/2008 - 17:31:08: [a_mysql_beta.smx] Insert: Em4S -- INSERT INTO sm_users(plname) VALUES ('Em4S')
L 03/25/2008 - 17:31:08: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:09: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:09: [a_mysql_beta.smx] Insert: (LT) vycka [killer] -- INSERT INTO sm_users(plname) VALUES ('(LT) vycka [killer]')
L 03/25/2008 - 17:31:10: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:10: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:11: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:12: [a_mysql_beta.smx] Insert: Igniussss -- INSERT INTO sm_users(plname) VALUES ('Igniussss')
L 03/25/2008 - 17:31:13: [a_mysql_beta.smx] Insert: Igniussss -- INSERT INTO sm_users(plname) VALUES ('Igniussss')
L 03/25/2008 - 17:31:13: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:14: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:14: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:15: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:15: [a_mysql_beta.smx] UPDATE `sm_users` SET `money`=0 WHERE `id`=0
L 03/25/2008 - 17:31:15: [a_mysql_beta.smx] UPDATE `sm_users` SET `money`=0 WHERE `id`=0
L 03/25/2008 - 17:31:15: [a_mysql_beta.smx] UPDATE `sm_users` SET `money`=0 WHERE `id`=0
L 03/25/2008 - 17:31:15: [a_mysql_beta.smx] UPDATE `sm_users` SET `money`=0 WHERE `id`=0
L 03/25/2008 - 17:31:15: [a_mysql_beta.smx] UPDATE `sm_users` SET `money`=0 WHERE `id`=0
L 03/25/2008 - 17:31:15: [a_mysql_beta.smx] UPDATE `sm_users` SET `money`=0 WHERE `id`=-256
L 03/25/2008 - 17:31:15: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:16: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:16: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:17: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:21: [a_mysql_beta.smx] [MYSQLmanager] SELECT `money`, id FROM sm_users WHERE `plname` = 'kaban'
L 03/25/2008 - 17:31:21: [a_mysql_beta.smx] Insert: kaban -- INSERT INTO sm_users(plname) VALUES ('kaban')
L 03/25/2008 - 17:31:21: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:27: [a_mysql_beta.smx] [MYSQLmanager] SELECT `money`, id FROM sm_users WHERE `plname` = 'BMW*Jaskaxxx'
L 03/25/2008 - 17:31:27: [a_mysql_beta.smx] Insert: BMW*Jaskaxxx -- INSERT INTO sm_users(plname) VALUES ('BMW*Jaskaxxx')
L 03/25/2008 - 17:31:28: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:29: [a_mysql_beta.smx] UPDATE `sm_users` SET `money`=0 WHERE `id`=0
L 03/25/2008 - 17:31:30: [a_mysql_beta.smx] [MYSQLmanager] SELECT `money`, id FROM sm_users WHERE `plname` = 'Igniussss'
L 03/25/2008 - 17:31:30: [a_mysql_beta.smx] Insert: Igniussss -- INSERT INTO sm_users(plname) VALUES ('Igniussss')
L 03/25/2008 - 17:31:31: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:31: [a_mysql_beta.smx] UPDATE `sm_users` SET `money`=0 WHERE `id`=0
L 03/25/2008 - 17:31:36: [a_mysql_beta.smx] [MYSQLmanager] SELECT `money`, id FROM sm_users WHERE `plname` = '_Juzikas_'
L 03/25/2008 - 17:31:36: [a_mysql_beta.smx] Insert: _Juzikas_ -- INSERT INTO sm_users(plname) VALUES ('_Juzikas_')
L 03/25/2008 - 17:31:36: [a_mysql_beta.smx] New user of InsertID: 0
L 03/25/2008 - 17:31:37: [a_mysql_beta.smx] UPDATE `sm_users` SET `money`=0 WHERE `id`=0
L 03/25/2008 - 17:31:37: [a_mysql_beta.smx] [MYSQLmanager] SELECT `money`, id FROM sm_users WHERE `plname` = 'kaban'
L 03/25/2008 - 17:31:37: [a_mysql_beta.smx] Insert: kaban -- INSERT INTO sm_users(plname) VALUES ('kaban')
L 03/25/2008 - 17:31:38: [a_mysql_beta.smx] New user of InsertID: 0
Solltex is offline
Nican
Veteran Member
Join Date: Jan 2006
Location: NY
Old 03-25-2008 , 10:20   Re: SM Bank Mod: MySQL
Reply With Quote #132

how stupid of me, i forgot to turn off debug...

Anyway, download this one, see if it works any better:
Attached Files
File Type: sp Get Plugin or Get Source (a_mysql_beta.sp - 491 views - 35.5 KB)
__________________
http://www.nican132.com
I require reputation!
Nican is offline
Send a message via ICQ to Nican Send a message via MSN to Nican
Solltex
Member
Join Date: Dec 2004
Old 03-25-2008 , 11:04   Re: SM Bank Mod: MySQL
Reply With Quote #133

log:
Code:
L 03/25/2008 - 22:52:48: [a_mysql_beta.smx] [MYSQLmanager] Found 4 colums in sm_users
L 03/25/2008 - 22:52:48: [a_mysql_beta.smx] [MYSQLmanager] ERROR: Could not create data integer table!
error_log:
Code:
L 03/25/2008 - 22:52:48: [SM] Native "SQL_FetchRow" reported: No current result set
L 03/25/2008 - 22:52:48: [SM] Displaying call stack trace for plugin "a_mysql_beta.smx":
L 03/25/2008 - 22:52:48: [SM]   [0]  Line 231, /home/groups/alliedmodders/forums/files/9/4/4/3/24910.attach::OnTableUpdated()
L 03/25/2008 - 22:52:49: [SM] Native "SetArrayString" reported: Invalid Handle 2440117 (error: 3)
L 03/25/2008 - 22:52:49: [SM] Displaying call stack trace for plugin "a_mysql_beta.smx":
L 03/25/2008 - 22:52:49: [SM]   [0]  Line 745, /home/groups/alliedmodders/forums/files/9/4/4/3/24910.attach::OnClientAuthorized()
L 03/25/2008 - 22:52:49: [SM] Native "SetArrayString" reported: Invalid Handle 2440117 (error: 3)
L 03/25/2008 - 22:52:49: [SM] Displaying call stack trace for plugin "a_mysql_beta.smx":
L 03/25/2008 - 22:52:49: [SM]   [0]  Line 745, /home/groups/alliedmodders/forums/files/9/4/4/3/24910.attach::OnClientAuthorized()
L 03/25/2008 - 22:52:49: [SM] Native "SetArrayString" reported: Invalid Handle 2440117 (error: 3)
L 03/25/2008 - 22:52:49: [SM] Displaying call stack trace for plugin "a_mysql_beta.smx":
L 03/25/2008 - 22:52:49: [SM]   [0]  Line 745, /home/groups/alliedmodders/forums/files/9/4/4/3/24910.attach::OnClientAuthorized()
L 03/25/2008 - 22:52:50: [SM] Native "SetArrayString" reported: Invalid Handle 2440117 (error: 3)
L 03/25/2008 - 22:52:50: [SM] Displaying call stack trace for plugin "a_mysql_beta.smx":
L 03/25/2008 - 22:52:56: [SM] Native "GetArrayCell" reported: Invalid index 0 (count: 0)
L 03/25/2008 - 22:52:56: [SM] Displaying call stack trace for plugin "a_mysql_beta.smx":
L 03/25/2008 - 22:52:56: [SM]   [0]  Line 706, /home/groups/alliedmodders/forums/files/9/4/4/3/24910.attach::IsColumnEnabled()
L 03/25/2008 - 22:52:56: [SM]   [1]  Line 911, /home/groups/alliedmodders/forums/files/9/4/4/3/24910.attach::UpdateClientInfo()
L 03/25/2008 - 22:52:56: [SM]   [2]  Line 882, /home/groups/alliedmodders/forums/files/9/4/4/3/24910.attach::OnClientDisconnect_Post()
L 03/25/2008 - 22:52:56: [SM] Native "SetArrayString" reported: Invalid Handle 2440117 (error: 1)
Solltex is offline
LocutusH
Senior Member
Join Date: Dec 2007
Location: Hungary
Old 04-23-2008 , 14:38   Re: SM Bank Mod: MySQL
Reply With Quote #134

Nican, a question: What should i alter in your code, to have the menu show round values again? For example, 1000, 2000, etc.. and not relative to the players money?

Thx.
__________________
LocutusH is offline
Nican
Veteran Member
Join Date: Jan 2006
Location: NY
Old 04-23-2008 , 14:44   Re: SM Bank Mod: MySQL
Reply With Quote #135

Go to line #14 and remove just the "//"
Go to line #7 and change the "7" to "5"

and then go to line #313 and replace the whole "AddMoneyItems" function with this:
PHP Code:
AddMoneyItems(Handle:menu2Money){
    new 
String:dummy[32], String:dummy2[32];
    new 
testint;
    
    for(new 
i=1iDWDCOUNTi++){
         
testint StringToIntMoneyCount[i] );
         if(
testint 0){
             
IntToMoneytestint dummy 32);
            
AddMenuItem(menu2MoneyCount[i], dummy);
        }
    }
    
    
    
AddMenuItem(menu2"all""All");

__________________
http://www.nican132.com
I require reputation!
Nican is offline
Send a message via ICQ to Nican Send a message via MSN to Nican
LocutusH
Senior Member
Join Date: Dec 2007
Location: Hungary
Old 04-23-2008 , 15:00   Re: SM Bank Mod: MySQL
Reply With Quote #136

Quote:
Originally Posted by Nican View Post
Go to line #14 and remove just the "//"
Go to line #7 and change the "7" to "5"

and then go to line #313 and replace the whole "AddMoneyItems" function with this:
PHP Code:
AddMoneyItems(Handle:menu2Money){
    new 
String:dummy[32], String:dummy2[32];
    new 
testint;
    
    for(new 
i=1iDWDCOUNTi++){
         
testint StringToIntMoneyCount[i] );
         if(
testint 0){
             
IntToMoneytestint dummy 32);
            
AddMenuItem(menu2MoneyCount[i], dummy);
        }
    }
    
    
    
AddMenuItem(menu2"all""All");


Thx for the fast answer

Do you mean these lines?

#define DWDCOUNT 5
static String:MoneyCount[ DWDCOUNT ][] = { "1000" , "2000" , "4000" , "8000", "16000"};
__________________
LocutusH is offline
Nican
Veteran Member
Join Date: Jan 2006
Location: NY
Old 04-23-2008 , 15:01   Re: SM Bank Mod: MySQL
Reply With Quote #137

yes

Change the value to 5, and remove the comment from MoneyCount.

One more thing change:
PHP Code:
for(new i=1iDWDCOUNTi++){ 
to
PHP Code:
for(new i=0iDWDCOUNTi++){ 
__________________
http://www.nican132.com
I require reputation!
Nican is offline
Send a message via ICQ to Nican Send a message via MSN to Nican
LocutusH
Senior Member
Join Date: Dec 2007
Location: Hungary
Old 04-23-2008 , 15:04   Re: SM Bank Mod: MySQL
Reply With Quote #138

And where does this line

AddMenuItem(menu2, "all", "All");

know, what "all" means? (how much money the player has) Where is the function for that menuitem?
__________________
LocutusH is offline
Nican
Veteran Member
Join Date: Jan 2006
Location: NY
Old 04-23-2008 , 15:06   Re: SM Bank Mod: MySQL
Reply With Quote #139

Quote:
Originally Posted by LocutusH View Post
what "all" means? (how much money the player has) Where is the function for that menuitem?


Huh?
__________________
http://www.nican132.com
I require reputation!
Nican is offline
Send a message via ICQ to Nican Send a message via MSN to Nican
LocutusH
Senior Member
Join Date: Dec 2007
Location: Hungary
Old 04-23-2008 , 15:06   Re: SM Bank Mod: MySQL
Reply With Quote #140

In your function above, you have this line

But in the original source, this line was commented out.

I just dont know how it works
__________________
LocutusH is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:05.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode