Hi,
I'm maintaining a ban vault... It's a short one, since all bans contained in it are only temporary.
I'm running down problems...
You see, I don't need to put a value in the key. So the key can be empty. In fact only timestamp and the key name are what matters.
I use nvault_touch() to set the empty key and update the timestamp to make it the an unban timestamp (i.e. time() + banlength_in_seconds). The advantage is that I can then prune the vault to remove exprired bans... based on timestamps.
However, the vault crashes miserably...
Give it a look too...
Code:
#include <amxmodx>
#include <nvault>
public plugin_init()
{
new pvault = nvault_open("testvault");
nvault_touch(pvault, "STEAM_0:0:56423", time() + 3600); // Will create an empty key
nvault_close(pvault);
}
Now, add it to plugins.ini, load your hlds install. Once AMXX plugins are all loaded, type "exit" in the server console. Repeat once and you will get a nice crash...
Do I miss something?
Cordially,
Misery