Help with djson..
#4

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:

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;
}
Make a call to the DeleteDJSonCacheFiles(); function inside OnGameModeInit, before djson_GameModeInit().
Reply


Messages In This Thread
Help with djson.. - by The_Moddler - 27.10.2010, 23:03
Re: Help with djson.. - by Zamaroht - 28.10.2010, 00:07
Re: Help with djson.. - by The_Moddler - 28.10.2010, 00:12
Re: Help with djson.. - by Zamaroht - 28.10.2010, 00:18
Re: Help with djson.. - by iggy1 - 28.10.2010, 00:20
Re: Help with djson.. - by The_Moddler - 28.10.2010, 16:35
Re: Help with djson.. - by The_Moddler - 30.10.2010, 22:37
Re: Help with djson.. - by Retardedwolf - 30.10.2010, 22:40
Re: Help with djson.. - by The_Moddler - 30.10.2010, 22:41
Re: Help with djson.. - by The_Moddler - 31.10.2010, 13:14

Forum Jump:


Users browsing this thread: 1 Guest(s)