Raised This Month: $ Target: $400
 0% 

Reset nvault on next map


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Xalus
Veteran Member
Join Date: Dec 2009
Location: Belgium
Old 03-19-2011 , 17:40   Reset nvault on next map
Reply With Quote #1

Hello,

PHP Code:
public plugin_cfg() {
    
g_Vault nvault_open"WarningData" );
    
    if ( 
g_Vault == INVALID_HANDLE )
        
set_fail_state"Error opening nVault" );
    
    
nvault_pruneg_Vault get_systime() );

I try'd that,
but for some reason it don't get resetted.

Maybe, becuase players disconnect, it saves.
But plugin_cfg, loads on new map I touge so

I don't get the problem.

Can somoene help ?

Thanks.

Thanks to move.
__________________
Retired.

Last edited by Xalus; 03-19-2011 at 17:56.
Xalus is offline
wrecked_
Veteran Member
Join Date: Jan 2010
Location: New York (GMT-5)
Old 03-19-2011 , 18:03   Re: Reset nvault on next map
Reply With Quote #2

Are you using nvault_set() or nvault_pset()?

Two other methods:
  • delete_file()
  • Save each ID you save data under (I assume you're using Steam ID as the key for setting data) and then loop through the ID's on plugin_end() and use nvault_remove().
__________________
[ Paid Requests ]
DO NOT PM ME ABOUT BLOCKMAKER
NO PRIVATE SUPPORT
wrecked_ is offline
Xalus
Veteran Member
Join Date: Dec 2009
Location: Belgium
Old 03-20-2011 , 12:28   Re: Reset nvault on next map
Reply With Quote #3

If I wanna use Delete_file()

I need do: delete_file(g_Vault) or ("WarningData")

& I use nvault_set
__________________
Retired.
Xalus is offline
wrecked_
Veteran Member
Join Date: Jan 2010
Location: New York (GMT-5)
Old 03-20-2011 , 13:38   Re: Reset nvault on next map
Reply With Quote #4

The only argument in delete_file() is the file directory (string).
__________________
[ Paid Requests ]
DO NOT PM ME ABOUT BLOCKMAKER
NO PRIVATE SUPPORT
wrecked_ is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 03-20-2011 , 14:20   Re: Reset nvault on next map
Reply With Quote #5

If you don't want to save datas after map has changed, just use a Trie or a dynamic array or whatever the system.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Xalus
Veteran Member
Join Date: Dec 2009
Location: Belgium
Old 03-20-2011 , 17:24   Re: Reset nvault on next map
Reply With Quote #6

Thanks,
__________________
Retired.

Last edited by Xalus; 03-20-2011 at 17:40.
Xalus is offline
Reply



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 14:31.


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