PDA

View Full Version : [Issue] Fixing up Store and Trails, debug problem


CookieB
04-02-2016, 08:29
Hello,

I'm quite new to this so excuse my incompetency.

I'm hosting a private surf server for me and my friends using ckSurf, I want to use the store to give out some trails. Database works without problem, store loads trails.

Encountered a few bugs in the store plugin which resulted from the usage of 'SetPackPosition' which seemed to be based on old offset values which changed.

You can fix those bugs by just using ResetPack / ReadCell's instead of the SetPackPosition.

So after those bugs were gone I encountered "No attributes found" for the trails and wanted to debug the store, here is my real problem.

My debug messages won't show up in the server log, I used Store_Log ( can't remember the exact name, the definitions from store_logging.sp ) and I used Print Server.

None of both show up though, nothing in the logs, nothing in the console, can someone give me a tip what to use? I'm willing to share everything that I get to work but today I have to study for an exam and probably can't answer. ( I'm getting mad if things I program don't work )

Edit: Just adding, I am always compiling and overwriting the plugins of course.
Edit2: Just had to try edit addons/sourcemod/config/store/store_logging.cfg didn't help either.

heres an excerpt of frustration:
/**
* Query the database for items and categories, so that
* the store-backend module will have a cache of them.
*
* @noreturn
*/
ReloadItemCache()
{
Store_LogInfo("Reloading items now");
PrintToConsole(0,"test3");
PrintToServer("Test1");
Store_LogError("TESST, goddamit");
GetCategories(_, _, false);
GetItems(_, _, _, false);
}

public Action:Command_ReloadItems(client, args)
{
ReplyToCommand(client, "Reloading items..., client: %d", client);
PrintToConsole(0, "test1");
ReloadItemCache();

return Plugin_Handled;
}
Console input:
store_reloaditems

Console output:

Reloading items..., client: 0
test1


Regards, Cookie

CookieB
04-02-2016, 13:22
Okay so to show a quick POC first:

http://steamcommunity.com/sharedfiles/filedetails/?id=657987679

I managed to get it to work, the problem I had came up because Store Logging seems buggy. I commented out every occurance in my program flow.

The problem is the same as I stated first. You can simply find all spots you have to fix by using "ack SetPackPosition"

I will upload a working setup in a few but I really should study instead.

Edit: I added my modifications. I had to adjust a few things to make ckSurf work with the stuff. Just minor changes like uncommenting a definition and adjusting a parameter name in smjamson.

run "ack Modified" for my store modifications

store v 1.1 alpha, trails 1.1 alpha, sourcemod 1.7.3 ckSurf 1.18 beta

See you soon.