Save level based on class (XP Mod)
I noticed in the XP mod tutorial by Flyeni6, it only saves their level.
PHP Code:
|
Re: Save level based on class (XP Mod)
Combine SteamID and the class name, then use that for the nvault key.
|
Re: Save level based on class (XP Mod)
Quote:
Another thing is, there are two classes, and the first class (warriors), get two types of stats, strength and dexterity, and the second class (assassins) has agility and transparency. How would I save those seperately as well? |
Re: Save level based on class (XP Mod)
SteamID + class name + stat name = stat value
|
Re: Save level based on class (XP Mod)
Quote:
PHP Code:
|
Re: Save level based on class (XP Mod)
Well if you're one of those people that likes to have multiple values in an nvault entry then that method is fine.
I personally like using 1 value per key so I can just use nvault_get() to return the integer. |
Re: Save level based on class (XP Mod)
Quote:
|
Re: Save level based on class (XP Mod)
Here's an example of how I would've done the code in your first post.
PHP Code:
PHP Code:
|
Re: Save level based on class (XP Mod)
Quote:
|
Re: Save level based on class (XP Mod)
Quote:
All you have to do is add the class name to the level key (and the xp key if you have xp per class). |
| All times are GMT -4. The time now is 11:20. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.