nVault data switching
Hello,
I have a problem with nVault loading. Code: PHP Code:
It worked for 3 maps, then it stored as I said above. Registered events: PHP Code:
Anyone, any idea? |
Re: nVault array switching
PHP Code:
|
Re: nVault data switching
There's a possibility that the death(s) remain there from the previous player on that slot. nvault_get_array() only fills the array if the player has data stored. So the below sequence of events would cause a connecting player to have data from the previous player.
1. Player A on slot 1 had 4 deaths. They disconnect. 2. Player B connects on slot 1. They have no data stored in the vault so nvault_get_array() essentially does nothing. 3. Player B has Player A's data leftover in pdData array. I would clear out the pdData[ SLOT ] on disconnect. Code:
|
Re: nVault data switching
Quote:
I will test your way. You should apply this update at this tutorial: https://forums.alliedmods.net/showthread.php?t=307518 |
Re: nVault data switching
I just tested the nvault module, nvault_get() clears the string variable if no record exists., I think a correction to the nVault Array include would be better for consistency. This should be fine from a backwards compatibility perspective.
|
| All times are GMT -4. The time now is 17:14. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.