28.10.2010, 00:18
It's weird, I usually have that problem with the cache files when the server gets closed incorrectly.
Anyway, this code might be a bit slow, but it isn't an issue since it's just called once when the server starts up:
Make a call to the DeleteDJSonCacheFiles(); function inside OnGameModeInit, before djson_GameModeInit().
Anyway, this code might be a bit slow, but it isn't an issue since it's just called once when the server starts up:
pawn Code:
stock DeleteDJSonCacheFiles()
{
new filename[24];
for(new i; i < 1000; i ++)
{
format(filename, sizeof(filename), "djson-db-cache.%d", i);
if(fexist(filename))
fremove(filename);
}
return 1;
}