Saving ip's into nvault
Hello there,
i've tryed to save ip's into nvault but it wont work at all. Can someone help me? Loaddata: PHP Code:
PHP Code:
|
Re: Saving ip's into nvault
You need to initialize a person into the vault before you can save, or get their data. Check out my code from a plugin i use nvault for.
PHP Code:
This code is run at client_putinserver also....don't use parse and replace all to seperate your data use strtok, it'll save you some native calls. Code:
strtok(vaultdata, kills, charsmax(kills), deaths, charsmax(deaths), '#', 1) |
Re: Saving ip's into nvault
Well, what did i wrong with my version? it works for authid.
|
Re: Saving ip's into nvault
Quote:
But it could be (forgive techno-babble) that IP addresses are not static. (They can change whenever required by your ISP) and you may be connecting with a different IP. Or you could be running through a proxy which will mask your IP, or even some DNS servers and firewalls will mask IPs if you have them set to operate as such. Long story short....IPs can be quite unreliable especially in situations like this. SteamIDs will never change. Unless the user gets a different account. |
Re: Saving ip's into nvault
Quote:
EDIT: FYI the returns in your functions are not required. |
Re: Saving ip's into nvault
Then why doesnt it save ?:O
|
Re: Saving ip's into nvault
Did you not read any of the above posts? Save by Steam ID. There's no reason to use IP.
You should also provide the full code because the error may be elsewhere. |
Re: Saving ip's into nvault
PHP Code:
|
Re: Saving ip's into nvault
if you load ip-PointMod and save ip-KDRATIO as the keys you're not going to get consistent results. Just in case you didn't know that....
Also, not functionally different, but use formatex, its faster. And, again, use strtok instead of replace and parse. It'll be faster. and.... Code:
ColorChat(0, GREY, "%s ^4%s ^1has a ratio of: ^4%.2f", Prefix, name, Ratio);PHP Code:
P.S. There is no point in adding a "KDRATIO" or "PointMod" to your key. If you need a difference, just use different vaults. It'll make it better organized and each vault smaller. (i don't know if vaultkeys are sorted or hashed, but if they're sorted....that will in turn make it faster. If they are hashed....well done developers. |
Re: Saving ip's into nvault
Quote:
Quote:
@Santaaa hopefully you've learnt and next time will show the correct the code, not write examples on the spot, hence giving helpers the wrong information. And I'll say it once again, your going to have many problems on your server if you continue to save by IP. |
| All times are GMT -4. The time now is 15:13. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.