* Remove parson folder
* add submodule parson
* FIX amxx_json_object_set_value generate a crash if invalid value is passed
* restore parson folder status
Turned out both test servers still had an old "tfc_i386.so" file which took precedence over the newer "tfc.so" library, so both servers were misconfigured and that's why the offsets didn't work.
Fixes an index out of bounds error when refreshMenus() and subsequently findAdminsWithMenu() is called when there is 32 players in the server. Indexing the playersList array in the for loop condition causes it to try to index with a value of 32 on the very last condition check which is not valid for this array.
* Adminslot: Trim spaces
* Adminslot: Use semicolon everywhere
* Adminslot: Use brackets everywhere
* Adminslot: Hook cvars change and make sure max visible players is set right away
* Adminslot: Rename g_sv_visiblemaxplayers
* Adminslot: Move free slot calculation in its own function
* Adminslot: Use create_cvar and define appropriate bounds
* Adminslot: Use get_playersnum_ex with flag for clarity
* Adminslot: Move all the logic inside setVisibleSlots
Looks like the commit should have been split for clarity.
The initial purpose is to avoid code duplication and regroup checks.
The logic is the same with a little improvement to handle situations where a cvar is changed on-the-fly and sv_visiblemaxplayers needs to be reset.
Ultimately, the logic is the following:
- At player's connection:
-- Do nothing if amx_reservation == 0 and sv_visiblemaxplayers <= 0. If sv_visiblemaxplayers is set, we reset it directly.
-- Check if player needs to be kicked. If not, and amx_hideslots == 0, then do nothing.
-- Otherwise we update sv_visiblemaxplayers
- Others events:
-- Do nothing if either amx_reservation == 0 or amx_hideslots == 0, and if sv_visiblemaxplayers <= 0. If sv_visiblemaxplayers is set, we reset it directly.
-- Otherwise we update sv_visiblemaxplayers
* Adminslot: Rename variables and adjust constantness
* Adminslot: Add a description to the cvars
* Adjust CVAR_HIDESLOTS english sentence
* Add the Deutsch translations
* Add public vars for plugin data and small refactoring get_xvar_id native
* Add new command to display info about the plugin and add url to amxx plugins command
* Add optional args to register_plugin native (url, description)
* Add enum of args for register_plugin native
* Creating a variable inside an if statement (C++17)
* Displaying the URL of the plugin if it is present
* Getting an ID only with more than three arguments
* Creating a variable inside an if statement (C++17)
* Fix typo
* Revert "Creating a variable inside an if statement (C++17)"
This reverts commit 835e0bc6c413f11b1bbf964daea87b57f653f5d7.
* Revert "Creating a variable inside an if statement (C++17)"
This reverts commit b2c1e7c77576c02a00c8c3f103457000d3298ceb.
* Revert "Displaying the URL of the plugin if it is present"
This reverts commit 9e31230368449966d16635c696d97c04adadeaa9.
* Binary compatibility for previously compiled plugins
* Displaying the URL of the plugin if it is present
* Quotation marks replaced by square brackets and change arg name to id
* Fix getting url
* The 'atoi' function replaced to 'stoi'
* Add likely/unlikely defines for using built-in function provided by GCC
* Small fixes with auto and inconsistent var name
* Replace stoi to strtol function
* Removed explicit buffer id
* Revert "Add likely/unlikely defines for using built-in function provided by GCC"
This reverts commit 94cee479ed245b98195501466850d01a3f08fd13.
* Add url and description params to get_plugin function