Raised This Month: $ Target: $400
 0% 

Data resets on mapchange.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
h0ppetau
Junior Member
Join Date: May 2012
Old 05-14-2012 , 08:11   Data resets on mapchange.
Reply With Quote #1

Hi guys,

I'm running a plugin called MoneyMod by Funfel, and on mapchange it resets all players items and money.

I would like to use the best way to save this kind of data. I have a running MySQL server, but maybe this kind of data is best stored in files?


Is there anyone out there able to locate the problem, and do you know a better solution? I dont know very much about scripting, so all help would be appreciated.
Attached Files
File Type: sma Get Plugin or Get Source (moneymod.sma - 564 views - 93.8 KB)

Last edited by h0ppetau; 05-14-2012 at 12:05. Reason: Attached .sma file instead of the whole code.
h0ppetau is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 05-14-2012 , 09:39   Re: Data resets on mapchange.
Reply With Quote #2

Attach the .sma file instead of posting the code.
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
h0ppetau
Junior Member
Join Date: May 2012
Old 05-15-2012 , 03:58   Re: Data resets on mapchange.
Reply With Quote #3

Quote:
Originally Posted by Exolent[jNr] View Post
Attach the .sma file instead of posting the code.
Sorry about that. I've fixed it now.



Anyways, if anyone encounters the same problem;

I fixed it by adding:

PHP Code:
new g_Vault;
new 
vaultkey[63], vaultdata[63]; 
public func_save:
PHP Code:
nvault_set(g_Vault,vaultkey,vaultdata); 
public func_load:
PHP Code:
nvault_get(g_Vault,vaultkey,vaultdata,63); 

Last edited by h0ppetau; 05-16-2012 at 05:29.
h0ppetau is offline
Reply


Thread Tools
Display Modes

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 00:19.


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