Raised This Month: $ Target: $400
 0% 

Save level based on class (XP Mod)


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
GXLZPGX
Veteran Member
Join Date: Sep 2009
Old 11-24-2010 , 14:03   Save level based on class (XP Mod)
Reply With Quote #1

I noticed in the XP mod tutorial by Flyeni6, it only saves their level.

PHP Code:
public SaveData(id

    
// get the players steam id. We need this because we are saving by steam id 
    
new AuthID[35get_user_authid(id,AuthID,34
    new 
vaultkey[64],vaultdata[256
    
// format wat is going to be in the animal mod vault file 
    
format(vaultkey,63,"%s-Mod",AuthID
    
format(vaultdata,255,"%i#%i#",PlayerXP[id],PlayerLevel[id]) 
    
// save the data 
    
nvault_set(g_vault,vaultkey,vaultdata
    return 
PLUGIN_CONTINUE 

So no matter what class they are, they're level will always be the same. How can I save seperate levels for each class?
__________________
Currently accepting payment US DOLLARS ONLY for custom plugins, contact me through PM.
GXLZPGX is offline
 


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 11:20.


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