-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added Map Tier Functionality for Global KZ Maps #7
base: map-names-tiers
Are you sure you want to change the base?
Added Map Tier Functionality for Global KZ Maps #7
Conversation
Requires SteamWorks and SMJansson include to compile and their extension files to function. Default value for Max Tier changed to 7 Generalized Chat Prefixes Added missing includes for compiling.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See my notes for requested changes, also:
- Please remove additional includes that are not shipped with MCE - we do not want to be responsible for keeping includes up to date. These would go great as Compilation Requirements linked in a Readme file (steamworks, colors, emitsoundany, smjansson)
- I generally try to stay away from 3rd party extension requirements due to them being an absolute pain to recompile when they break after major game/SM updates. Because global API plugins use it I won't require it for now, but if you could utilize the sm-json library which takes care of json responses rather than SMJansson that would be a huge plus: https://github.com/clugg/sm-json
Thank you!
@@ -134,6 +143,10 @@ public void OnLibraryAdded(const char[] szName) | |||
{ | |||
g_bKzTimer = true; | |||
} | |||
if (StrEqual (szName, "gokz-core")) | |||
{ | |||
g_bKzTimer = true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
GOKZ should be on its own boolean - returning that KZTimer exists breaks GOKZ usability with other parts of this plugin.
@@ -150,6 +163,10 @@ public void OnLibraryRemoved(const char[] szName) | |||
{ | |||
g_bKzTimer = false; | |||
} | |||
if (StrEqual (szName, "gokz-core")) | |||
{ | |||
g_bKzTimer = false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto with above
A replacement for the double Library check to account for both GOKZ/KZTimer. However I haven't tested this on a LAN server where people usually ignore the GlobalAPI error (usually due to missing SMJansson/Steamworks extensiosn). I'm hoping that since the plugin failed to load it's library won't be registered hence the bool value for KzGlobal will be false. Minor changes: - Proper usage of ChatPrefix Convar - Commented the "_" line in universal.txt - Renaming the rockthevote_extended config file, enforcing a naming scheme - Removed 3rd party includes - Added guide for compiling.
Apologies for disappearing, now that I have alot of free time I'd like to continue working on this. Instead of checking for KZTimer and GOKZ libraries, we'll check for GlobalAPI's library. However I'm unsure whether GlobalAPI's library will still be registered if the plugin fails to load (most common reason for failure would be missing SMJansson/Steamworks). I'm thinking if the plugin fails to load due to missing dependencies, some of its function such as RegPluginLibrary won't be executed. Please correct me if I'm wrong. As for integrating sm-json, I'll try to look up examples of its used and hopefully get it working in MCE. |
Requires SteamWorks and SMJansson include to compile and their extension files to function.
Default value for Max Tier changed to 7
Generalized Chat Prefixes
Added missing includes for compiling.