Difference between revisions of "AMX Mod X 1.9 Release Notes"
m (Fixed PR reference) |
m (Grammar check.) |
||
Line 7: | Line 7: | ||
:✓ This release does have new configuration files. | :✓ This release does have new configuration files. | ||
:✓ This release does have configuration changes. | :✓ This release does have configuration changes. | ||
− | :✓ This release does | + | :✓ This release does include plugin changes. |
:✓ This release does have translations changes. | :✓ This release does have translations changes. | ||
:✓ This release does not break compatibility. | :✓ This release does not break compatibility. | ||
Line 36: | Line 36: | ||
* Stability and performance improvements | * Stability and performance improvements | ||
* Official support for ReHLDS and ReGameDLL | * Official support for ReHLDS and ReGameDLL | ||
− | * | + | * Greatly improved UTF-8 support across the project |
* Significant improvements to modules and official plugins | * Significant improvements to modules and official plugins | ||
* (Almost) completely revised and completed documentation | * (Almost) completely revised and completed documentation | ||
Line 216: | Line 216: | ||
{{color|dimgrey|'''Admin Chat'''}} | {{color|dimgrey|'''Admin Chat'''}} | ||
− | * Cooldown on {{tt|say_team @]}} to | + | * Cooldown on {{tt|say_team @]}} to avoid overflow on admins |
{{color|dimgrey|'''Admin Help'''}} | {{color|dimgrey|'''Admin Help'''}} | ||
Line 239: | Line 239: | ||
* No more hardcoded multilingual messages | * No more hardcoded multilingual messages | ||
* Admin activity is displayed on config loading/saving | * Admin activity is displayed on config loading/saving | ||
− | * Opened | + | * Opened menu is refereshed if the command is used to save/load/set |
* Menu/command items are now grouped per class | * Menu/command items are now grouped per class | ||
Line 261: | Line 261: | ||
There are too many additions to list them here in details. For complete API changes and additions, see [[AMX_Mod_X_1.9_API_Changes]]. <br /> | There are too many additions to list them here in details. For complete API changes and additions, see [[AMX_Mod_X_1.9_API_Changes]]. <br /> | ||
− | It is strongly recommended to check out the changes, a lot of information | + | It is strongly recommended to check out the changes, a lot of information is contained there. |
Essentially: | Essentially: | ||
* Documentation has been updated in many ways. | * Documentation has been updated in many ways. | ||
* Compiler got a bunch of fixes and minor improvements/features. | * Compiler got a bunch of fixes and minor improvements/features. | ||
− | * | + | * The API has been updated with various fixes and improvements. |
* New module | * New module | ||
* New core APIs | * New core APIs | ||
Line 285: | Line 285: | ||
* Added basic ReHLDS and ReGameDLL support ({{pr|amxx|417}}, {{pr|amxx|423}}, {{pr|amxx|425}}, {{pr|amxx|427}}, {{pr|amxx|446}}, {{pr|amxx|450}}, {{pr|amxx|483}}) | * Added basic ReHLDS and ReGameDLL support ({{pr|amxx|417}}, {{pr|amxx|423}}, {{pr|amxx|425}}, {{pr|amxx|427}}, {{pr|amxx|446}}, {{pr|amxx|450}}, {{pr|amxx|483}}) | ||
* Removed pre-compiled zlib from the tree ({{pr|amxx|117}}, {{pr|amxx|118}}) | * Removed pre-compiled zlib from the tree ({{pr|amxx|117}}, {{pr|amxx|118}}) | ||
− | * Unified zlib linkage by compiling it as static library and linking it to concerned projects ({{pr|amxx|195}}) | + | * Unified zlib linkage by compiling it as a static library and linking it to concerned projects ({{pr|amxx|195}}) |
{{color|dimgrey|'''Others'''}} | {{color|dimgrey|'''Others'''}} | ||
Line 307: | Line 307: | ||
{{color|dimgrey|'''Menu'''}} | {{color|dimgrey|'''Menu'''}} | ||
* Updated mods list supporting colored menus: DMC, TFC and Valve ({{pr|amxx|143}}) | * Updated mods list supporting colored menus: DMC, TFC and Valve ({{pr|amxx|143}}) | ||
− | * Fixed unexpected behaviors when a game menu is overlapped with custom one ({{bz|3199}}) | + | * Fixed unexpected behaviors when a game menu is overlapped with a custom one ({{bz|3199}}) |
* Fixed a crash with overlapping newmenu ({{pr|amxx|462}}) | * Fixed a crash with overlapping newmenu ({{pr|amxx|462}}) | ||
Line 331: | Line 331: | ||
{{margin|10px|}} | {{margin|10px|}} | ||
* Fixed incorrect message error on plugin which uses a deprecated file format ({{pr|amxx|275}}) | * Fixed incorrect message error on plugin which uses a deprecated file format ({{pr|amxx|275}}) | ||
− | * Fixed spectator team index not being set in specific | + | * Fixed spectator team index not being set in specific situations (Counter-strike only) ({{pr|amxx|15}}) |
* Fixed an unicode issue with {{tt|amx_SetStringOld}} ({{pr|amxx|22}}, {{pr|amxx|23}}) | * Fixed an unicode issue with {{tt|amx_SetStringOld}} ({{pr|amxx|22}}, {{pr|amxx|23}}) | ||
* Fixed log not written earlier at the first server start ({{pr|amxx|265}}) | * Fixed log not written earlier at the first server start ({{pr|amxx|265}}) | ||
Line 342: | Line 342: | ||
* Added Chinese language ({{pr|amxx|75}}) | * Added Chinese language ({{pr|amxx|75}}) | ||
{{margin|10px|}} | {{margin|10px|}} | ||
− | * Updated Macedonian & Bulgarian translations ({{pr|amxx| | + | * Updated Macedonian & Bulgarian translations ({{pr|amxx|477}}) |
− | * Updated Hungarian translations ({{pr|amxx| | + | * Updated Hungarian translations ({{pr|amxx|474}}, {{pr|amxx|494}}) |
{{margin|10px|}} | {{margin|10px|}} | ||
* Fixed incorrect keys in several multilingual files ({{pr|amxx|27}}) | * Fixed incorrect keys in several multilingual files ({{pr|amxx|27}}) | ||
Line 363: | Line 363: | ||
{{color|dimgrey|'''Admin Base'''}} | {{color|dimgrey|'''Admin Base'''}} | ||
− | * Directly | + | * Directly kick players rather than use a loopback command ({{bz|5946}}) |
− | * Assigned | + | * Assigned {{tt|FCVAR_PROTECTED}} directly in {{tt|register_cvar}} instead of after startup ({{pr|amxx|87}}) |
− | * Replaced {{tt|console_print}} | + | * Replaced {{tt|console_print}} with {{tt|engclient_print}} to support connecting players ({{pr|amxx|251}}, {{bz|6372}}) |
{{margin|10px|}} | {{margin|10px|}} | ||
− | * Fixed issue | + | * Fixed an issue when not including a port when an admin is added by IP address ({{bz|5978}}) |
{{color|dimgrey|'''Admin Chat'''}} | {{color|dimgrey|'''Admin Chat'''}} | ||
Line 413: | Line 413: | ||
{{color|dimgrey|'''NextMap'''}} | {{color|dimgrey|'''NextMap'''}} | ||
− | * Fixed last map not properly | + | * Fixed last map not properly saving resulting mapcycle reset at mapchange ({{bz|5817}}) |
− | * Fixed an | + | * Fixed an in-game issue where {{tt|mp_chattime}} cvar doesn't exist ({{bz|5922}}) |
{{color|dimgrey|'''Nextmap Chooser'''}} | {{color|dimgrey|'''Nextmap Chooser'''}} | ||
Line 531: | Line 531: | ||
{{color|dimgrey|'''CellTrie'''}} | {{color|dimgrey|'''CellTrie'''}} | ||
* Added {{tt|TrieGetSize}} and {{tt|TrieSnapshot*}} natives ({{pr|amxx|8}}) | * Added {{tt|TrieGetSize}} and {{tt|TrieSnapshot*}} natives ({{pr|amxx|8}}) | ||
− | * Added new {{tt|replace}} parameters for {{tt|TrieSet*}} natives to make operation fail if key already set ({{pr|amxx|8}}) | + | * Added new {{tt|replace}} parameters for {{tt|TrieSet*}} natives to make the operation fail if key already set ({{pr|amxx|8}}) |
* Added new {{tt|size}} parameter for {{tt|TrieGetString}} and {{tt|TrieGetArray}} to return the number of bytes written in the buffer ({{pr|amxx|8}}) | * Added new {{tt|size}} parameter for {{tt|TrieGetString}} and {{tt|TrieGetArray}} to return the number of bytes written in the buffer ({{pr|amxx|8}}) | ||
Line 545: | Line 545: | ||
* Allowed the following natives to be used on connecting players: {{tt|find_player}}, {{tt|get_players}} and {{tt|engclient_print}} (console only) ({{bz|6229}}, {{pr|amxx|126}}) | * Allowed the following natives to be used on connecting players: {{tt|find_player}}, {{tt|get_players}} and {{tt|engclient_print}} (console only) ({{bz|6229}}, {{pr|amxx|126}}) | ||
{{margin|10px|}} | {{margin|10px|}} | ||
− | * Fixed {{tt|user_slap}} unexpected behavior using large negative damage ({{bz|4975}}) | + | * Fixed {{tt|user_slap}} unexpected behavior when using large negative damage ({{bz|4975}}) |
* Fixed missing new line on client console message which is not truncated server-side if its length exceeds buffer size ({{bz|3140}}) | * Fixed missing new line on client console message which is not truncated server-side if its length exceeds buffer size ({{bz|3140}}) | ||
Line 552: | Line 552: | ||
{{margin|10px|}} | {{margin|10px|}} | ||
* Added {{tt|amxclient_cmd}} native ({{bz|5887}}, {{pr|amxx|438}}) | * Added {{tt|amxclient_cmd}} native ({{bz|5887}}, {{pr|amxx|438}}) | ||
− | * Added {{tt|read_argv_int}} and {{tt|read_argv_float}} to return directly | + | * Added {{tt|read_argv_int}} and {{tt|read_argv_float}} to return the value directly as integer or float ({{pr|amxx|366}}, {{pr|amxx|383}}) |
* Added a param to {{tt|register_*cmd}} and {{tt|get_*cmd}} to specify {{tt|info}} is a multilingual key in order to encourage command translation ({{pr|amxx|349}}, {{pr|amxx|434}}) | * Added a param to {{tt|register_*cmd}} and {{tt|get_*cmd}} to specify {{tt|info}} is a multilingual key in order to encourage command translation ({{pr|amxx|349}}, {{pr|amxx|434}}) | ||
{{margin|10px|}} | {{margin|10px|}} | ||
Line 573: | Line 573: | ||
{{color|dimgrey|'''Menu'''}} | {{color|dimgrey|'''Menu'''}} | ||
− | * Added menu | + | * Added menu timeout functionality to Newmenu API ({{pr|amxx|21}}) TODO: link to script changes? |
* Added {{tt|MEXIT_FORCE}} to force a proper exit button on unpaginated menus ({{pr|amxx|20}}) | * Added {{tt|MEXIT_FORCE}} to force a proper exit button on unpaginated menus ({{pr|amxx|20}}) | ||
− | * Added {{tt|MPROP_SHOWPAGE}} whether to show the page number in menu title ({{pr|amxx|473}}) | + | * Added {{tt|MPROP_SHOWPAGE}} to set whether or not to show the page number in menu title ({{pr|amxx|473}}) |
− | * Added{{tt| menu_addblank2}} and {{tt|menu_addtext2}} to fix unexpected behavior with the original ones when {{tt|slot}} param is set to 1 ({{bz|3096}}) | + | * Added {{tt| menu_addblank2}} and {{tt|menu_addtext2}} to fix unexpected behavior with the original ones when {{tt|slot}} param is set to 1 ({{bz|3096}}) |
* Added menu pagination callback ({{pr|amxx|420}}) | * Added menu pagination callback ({{pr|amxx|420}}) | ||
* Add default values for {{tt|menu_item_getinfo}}'s arguments ({{pr|amxx|511}}) | * Add default values for {{tt|menu_item_getinfo}}'s arguments ({{pr|amxx|511}}) | ||
Line 633: | Line 633: | ||
* Fixed UTF-8 character parsing due to improper casting ({{pr|amxx|401}}) | * Fixed UTF-8 character parsing due to improper casting ({{pr|amxx|401}}) | ||
* Fixed {{tt|strncmp}} case sensitivity ({{pr|amxx|314}}) | * Fixed {{tt|strncmp}} case sensitivity ({{pr|amxx|314}}) | ||
− | * Fixed a {{tt|floatround}} overflow on large | + | * Fixed a {{tt|floatround}} overflow on large numbers resulting in a negative number when optimization is enabled ({{pr|amxx|376}}) |
{{color|brown|'''Others'''}} | {{color|brown|'''Others'''}} | ||
Line 647: | Line 647: | ||
* Improved {{tt|power}} native on large number ({{pr|amxx|385}}) | * Improved {{tt|power}} native on large number ({{pr|amxx|385}}) | ||
{{margin|10px|}} | {{margin|10px|}} | ||
− | * Fixed | + | * Fixed definite time drift on repeating tasks ({{bz|3302}}) |
− | * Fixed potential issue in {{tt|get_plugin}} ({{pr|amxx|277}}) | + | * Fixed a potential issue in {{tt|get_plugin}} ({{pr|amxx|277}}) |
− | * Fixed crash when dynamic native is executed with the max number of params ({{pr|amxx|291}}) | + | * Fixed a crash when a dynamic native is executed with the max number of params ({{pr|amxx|291}}) |
=== Compiler === | === Compiler === | ||
Line 671: | Line 671: | ||
* Used in-memory buffers for reading files, and handling newline better ({{pr|amxx|116}}) | * Used in-memory buffers for reading files, and handling newline better ({{pr|amxx|116}}) | ||
* Used hash table for global name lookups ({{pr|amxx|116}}) | * Used hash table for global name lookups ({{pr|amxx|116}}) | ||
− | * Disabled the estimated usage calculation because doesn’t work well and | + | * Disabled the estimated usage calculation because it doesn’t work well and is not that useful ({{pr|amxx|137}}) |
* Removed scpack ({{pr|amxx|221}}, {{pr|amxx|226}}) | * Removed scpack ({{pr|amxx|221}}, {{pr|amxx|226}}) | ||
* Prevented declaring arrays that the compiler is too buggy to handle ({{pr|amxx|248}}) | * Prevented declaring arrays that the compiler is too buggy to handle ({{pr|amxx|248}}) | ||
Line 677: | Line 677: | ||
* Fixed returning strings from variadic functions ({{pr|amxx|121}}, {{pr|amxx|399}}) | * Fixed returning strings from variadic functions ({{pr|amxx|121}}, {{pr|amxx|399}}) | ||
* Fixed issue with multidimensional array variable release ({{pr|amxx|116}}) | * Fixed issue with multidimensional array variable release ({{pr|amxx|116}}) | ||
− | * Fixed | + | * Fixed memory corruption when parsing natives ({{pr|amxx|116}}) |
* Fixed improper handling of constant chained relational operators, i.e: {{TT|<nowiki>0 < 1 <= 2</nowiki>}} ({{pr|amxx|116}}) | * Fixed improper handling of constant chained relational operators, i.e: {{TT|<nowiki>0 < 1 <= 2</nowiki>}} ({{pr|amxx|116}}) | ||
* Fixed bogus assert about name lengths ({{pr|amxx|116}}) | * Fixed bogus assert about name lengths ({{pr|amxx|116}}) | ||
Line 683: | Line 683: | ||
* Fixed return omission with else-after-return ({{pr|amxx|116}}) | * Fixed return omission with else-after-return ({{pr|amxx|116}}) | ||
* Fixed crash when using {{TT|tagof(tagname:)}} ({{pr|amxx|116}}) | * Fixed crash when using {{TT|tagof(tagname:)}} ({{pr|amxx|116}}) | ||
− | * Fixed the {{TT|@}} character | + | * Fixed the {{TT|@}} character not being allowed in macro definitions ({{pr|amxx|116}}) |
* Fixed {{TT|<nowiki>#elseif</nowiki>}} handling not working as expected ({{pr|amxx|116}}) | * Fixed {{TT|<nowiki>#elseif</nowiki>}} handling not working as expected ({{pr|amxx|116}}) | ||
* Fixed {{TT|enum}} field size was not taken into account when implicitly passed to a function ({{pr|amxx|116}}) | * Fixed {{TT|enum}} field size was not taken into account when implicitly passed to a function ({{pr|amxx|116}}) | ||
* Fixed trailing commas in array literals changing the result of {{TT|sizeof}} ({{pr|amxx|163}}) | * Fixed trailing commas in array literals changing the result of {{TT|sizeof}} ({{pr|amxx|163}}) | ||
− | * Fixed regression with member tag of {{TT|enum}} not being checked on assignment ({{pr|amxx|164}}) | + | * Fixed regression with member tag of {{TT|enum}} is not being checked on assignment ({{pr|amxx|164}}) |
* Fixed {{TT|tagof}} operator used as a default value for function arguments ({{pr|amxx|191}}) | * Fixed {{TT|tagof}} operator used as a default value for function arguments ({{pr|amxx|191}}) | ||
* Fixed issue where native functions returning an array would not compile ({{pr|amxx|351}}) | * Fixed issue where native functions returning an array would not compile ({{pr|amxx|351}}) | ||
Line 698: | Line 698: | ||
==== CStrike ==== | ==== CStrike ==== | ||
− | * Added {{tt|CS_OnBuy}} forward, called right before item | + | * Added {{tt|CS_OnBuy}} forward, called right before an item is received ({{pr|amxx|25}}, {{pr|amxx|68}}, {{pr|amxx|124}}, {{pr|amxx|183}}, {{pr|amxx|263}}, {{pr|amxx|315}}, {{pr|amxx|340}}, {{pr|amxx|334}}) |
− | * Added {{tt|CS_OnBuyAttempt}} forward called right after command is issued ({{pr|amxx|68}}, {{pr|amxx|263}}, {{pr|amxx|334}}) | + | * Added {{tt|CS_OnBuyAttempt}} forward, called right after a command is issued ({{pr|amxx|68}}, {{pr|amxx|263}}, {{pr|amxx|334}}) |
* Added {{tt|cs_create_entity}} native ({{pr|amxx|189}}, {{pr|amxx|193}}) | * Added {{tt|cs_create_entity}} native ({{pr|amxx|189}}, {{pr|amxx|193}}) | ||
* Added {{tt|cs_find_ent_by_class}} native ({{pr|amxx|189}}, {{pr|amxx|193}}) | * Added {{tt|cs_find_ent_by_class}} native ({{pr|amxx|189}}, {{pr|amxx|193}}) | ||
Line 710: | Line 710: | ||
* Added {{tt|cs_get_item_alias}} ({{pr|amxx|342}}) | * Added {{tt|cs_get_item_alias}} ({{pr|amxx|342}}) | ||
* Added {{tt|cs_get_weapon_info}} native which gives various information about a weapon (only) ({{pr|amxx|278}}, {{pr|amxx|356}}) | * Added {{tt|cs_get_weapon_info}} native which gives various information about a weapon (only) ({{pr|amxx|278}}, {{pr|amxx|356}}) | ||
− | * Added a param to {{tt|cs_set_user_deaths}} native to choose whether scoreboard should be updated ({{pr|amxx|255}}) | + | * Added a param to {{tt|cs_set_user_deaths}} native to choose whether the scoreboard should be updated ({{pr|amxx|255}}) |
* Added support for {{tt|monster_scientist}} entity (alias of {{tt|hostage_entity}}) to hostage natives ({{pr|amxx|255}}) | * Added support for {{tt|monster_scientist}} entity (alias of {{tt|hostage_entity}}) to hostage natives ({{pr|amxx|255}}) | ||
* Added a {{tt|count}} param to {{tt|cs_get/set_armoury_type}} to get/set the number of weapons inside an armoury ({{pr|amxx|255}}) | * Added a {{tt|count}} param to {{tt|cs_get/set_armoury_type}} to get/set the number of weapons inside an armoury ({{pr|amxx|255}}) | ||
− | * Added a {{tt|update_index}} param in {{tt|cs_set_user_model}} to choose whether | + | * Added a {{tt|update_index}} param in {{tt|cs_set_user_model}} to choose whether the model index should be updated ({{pr|amxx|255}}, {{pr|amxx|300}}, {{pr|amxx|370}}) |
* Added a {{tt|CS_NORESET}} constant for use with {{tt|cs_set_user_team}} for skipping the model reset ({{pr|amxx|287}}, {{pr|amxx|400}}) | * Added a {{tt|CS_NORESET}} constant for use with {{tt|cs_set_user_team}} for skipping the model reset ({{pr|amxx|287}}, {{pr|amxx|400}}) | ||
− | * Added a new value for {{tt|draw_animation}} | + | * Added a new value for {{tt|draw_animation}} in {{tt|cs_set_weapon_silen}} which follows game behavior ({{pr|amxx|255}}) |
* Added the associated {{tt|TRAIN_*}} constants from HLSDK for use with {{tt|cs_get_user_driving}} ({{pr|amxx|255}}) | * Added the associated {{tt|TRAIN_*}} constants from HLSDK for use with {{tt|cs_get_user_driving}} ({{pr|amxx|255}}) | ||
{{margin|10px|}} | {{margin|10px|}} | ||
− | * Moved all hardcoded | + | * Moved all hardcoded data to its own gamedata files ({{pr|amxx|255}}, {{pr|amxx|352}}, {{pr|amxx|356}}) |
* Done some cleanup for the sake of consistency and readability ({{pr|amxx|255}}) | * Done some cleanup for the sake of consistency and readability ({{pr|amxx|255}}) | ||
* Added some known constants from CS, a {{tt|cstrike_const.inc}} has been created for the occasion ({{pr|amxx|278}}) | * Added some known constants from CS, a {{tt|cstrike_const.inc}} has been created for the occasion ({{pr|amxx|278}}) | ||
Line 724: | Line 724: | ||
* Improved {{tt|cs_set_no_knives}} internal code by hooking {{tt|pfnCreateNamedEntity}} only when necessary ({{pr|amxx|255}}) | * Improved {{tt|cs_set_no_knives}} internal code by hooking {{tt|pfnCreateNamedEntity}} only when necessary ({{pr|amxx|255}}) | ||
* Made {{tt|cs_get_user_armor}} {{tt|armortype}} param optional ({{pr|amxx|255}}) | * Made {{tt|cs_get_user_armor}} {{tt|armortype}} param optional ({{pr|amxx|255}}) | ||
− | * Improved {{tt|cs_set_user_zoom}} by using an event-based approach rather than enforcing on frame | + | * Improved {{tt|cs_set_user_zoom}} by using an event-based approach rather than enforcing on-frame basis when {{tt|mode}} is 0 ({{pr|amxx|255}}) |
{{margin|10px|}} | {{margin|10px|}} | ||
* Fixed {{tt|cs_user_spawn}} to properly respawn players ({{bz|3752}}) | * Fixed {{tt|cs_user_spawn}} to properly respawn players ({{bz|3752}}) | ||
* Fixed {{tt|cs_set_user_team}} not telling core spectator team change ({{pr|amxx|13}}) | * Fixed {{tt|cs_set_user_team}} not telling core spectator team change ({{pr|amxx|13}}) | ||
− | * Fixed {{tt|cs_get_hostage_id}} error check: | + | * Fixed {{tt|cs_get_hostage_id}} error check: a hostage can't be a player ({{pr|amxx|255}}) |
* Fixed {{tt|cs_set_user_[model/team]}} and {{tt|cs_reset_user_[model/team]}} overflow issue by staggering user's info updates across multiple frames ({{pr|amxx|255}}) | * Fixed {{tt|cs_set_user_[model/team]}} and {{tt|cs_reset_user_[model/team]}} overflow issue by staggering user's info updates across multiple frames ({{pr|amxx|255}}) | ||
* Fixed missing meta return in {{tt|ServerActivate}} ({{pr|amxx|308}}) | * Fixed missing meta return in {{tt|ServerActivate}} ({{pr|amxx|308}}) | ||
Line 762: | Line 762: | ||
* Moved {{tt|precache_event}} to core ({{pr|amxx|250}}, {{pr|amxx|490}}) | * Moved {{tt|precache_event}} to core ({{pr|amxx|250}}, {{pr|amxx|490}}) | ||
* Removed inconsistent error path from {{tt|entity_get_int}} ({{pr|amxx|250}}) | * Removed inconsistent error path from {{tt|entity_get_int}} ({{pr|amxx|250}}) | ||
− | * Added error path for {{tt|remove_entity}} and unsafe entity ids | + | * Added error path for {{tt|remove_entity}} and unsafe entity ids ({{pr|amxx|250}}) |
− | * Added a bunch of missing entity | + | * Added a bunch of missing entity checks ({{pr|amxx|250}}, {{pr|amxx|345}}, {{pr|amxx|346}}, {{pr|amxx|355}}) |
− | * Used UTF-8 functions where {{tt|KeyValueData}} is touched | + | * Used UTF-8 functions where {{tt|KeyValueData}} is touched ({{pr|amxx|250}}) |
* Allowed {{tt|find_ent_by_owner}} native to work in {{tt|client_disconnect}} forward ({{pr|amxx|152}}) | * Allowed {{tt|find_ent_by_owner}} native to work in {{tt|client_disconnect}} forward ({{pr|amxx|152}}) | ||
{{margin|10px|}} | {{margin|10px|}} | ||
− | * Fixed a crash using {{tt|get/set_usercmd}} ({{bz|5744}}) | + | * Fixed a crash when using {{tt|get/set_usercmd}} ({{bz|5744}}) |
* Fixed {{tt|set_view}} altering {{tt|pev}} properties instead of {{tt|entity_state}} for rendering players ({{bz|5382}}) | * Fixed {{tt|set_view}} altering {{tt|pev}} properties instead of {{tt|entity_state}} for rendering players ({{bz|5382}}) | ||
* Fixed incorrect behavior of impulse forwards ({{bz|3243}}) | * Fixed incorrect behavior of impulse forwards ({{bz|3243}}) | ||
* Fixed {{tt|pfn_spawn}} metamod return to follow engine behavior ({{bz|5807}}) | * Fixed {{tt|pfn_spawn}} metamod return to follow engine behavior ({{bz|5807}}) | ||
− | * Fixed {{tt|set_ent_rendering}} not working on non- | + | * Fixed {{tt|set_ent_rendering}} not working on non-player entities ({{pr|amxx|71}}) |
* Fixed {{tt|get_info_keybuffer}} not being able to retrieve local key buffer ({{pr|amxx|250}}) | * Fixed {{tt|get_info_keybuffer}} not being able to retrieve local key buffer ({{pr|amxx|250}}) | ||
− | * Fixed an entity check logic error | + | * Fixed an entity check logic error ({{pr|amxx|250}}, {{pr|amxx|259}}) |
− | * Fixed {{tt|is_visible}} native not working on | + | * Fixed {{tt|is_visible}} native not working on players ({{pr|amxx|392}}) |
− | * Fixed a {{tt|set_lights}} buffer issue which was resulting an incorrect light ({{pr|amxx|464}}, {{pr|amxx|508}}) | + | * Fixed a {{tt|set_lights}} buffer issue which was resulting in an incorrect light ({{pr|amxx|464}}, {{pr|amxx|508}}) |
==== Fakemeta ==== | ==== Fakemeta ==== | ||
Line 799: | Line 799: | ||
** {{tt|find_gamerules_info}} | ** {{tt|find_gamerules_info}} | ||
{{margin|10px|}} | {{margin|10px|}} | ||
− | * Allowed {{tt|get/set_pdata_cbase}} usage at map end whereas player's private | + | * Allowed {{tt|get/set_pdata_cbase}} usage at map end whereas player's private data is still valid ({{bz|5787}}) |
− | * Improved handling of {{tt|KeyValueData}} and | + | * Improved handling of {{tt|KeyValueData}} and made it compatible with Hamsandwich ({{pr|amxx|240}}) |
* Allowed null invoker to be passed in {{tt|EngFunc_PlayBackEvent}} ({{pr|amxx|358}}, {{bz|6467}}) | * Allowed null invoker to be passed in {{tt|EngFunc_PlayBackEvent}} ({{pr|amxx|358}}, {{bz|6467}}) | ||
{{margin|10px|}} | {{margin|10px|}} | ||
Line 810: | Line 810: | ||
==== GeoIP ==== | ==== GeoIP ==== | ||
− | * Module uses the latest MaxMind GeoIP2 API ({{pr|amxx|99}}, {{pr|amxx|104}}, {{pr|amxx|132}}) | + | * Module now uses the latest MaxMind GeoIP2 API ({{pr|amxx|99}}, {{pr|amxx|104}}, {{pr|amxx|132}}) |
* Added new (UTF-8 safe) {{tt|geoip_*}} natives to retrieve the city, region, continent and more ({{pr|amxx|99}}, {{pr|amxx|198}}, {{pr|amxx|200}}) | * Added new (UTF-8 safe) {{tt|geoip_*}} natives to retrieve the city, region, continent and more ({{pr|amxx|99}}, {{pr|amxx|198}}, {{pr|amxx|200}}) | ||
* Added a {{tt|geoip}} command mainly for debugging purposes (version, dump an ip data) ({{pr|amxx|99}}) | * Added a {{tt|geoip}} command mainly for debugging purposes (version, dump an ip data) ({{pr|amxx|99}}) | ||
Line 824: | Line 824: | ||
* Added several functions which required different handlers | * Added several functions which required different handlers | ||
* Added a lot of missing virtual functions for all mods | * Added a lot of missing virtual functions for all mods | ||
− | * Added natives to deal with {{tt|ItemInfo}} structure | + | * Added natives to deal with the {{tt|ItemInfo}} structure |
− | * Added support for | + | * Added support for bots without {{tt|player}} classname ({{bz|6111}}, {{bz|6323}}, {{pr|amxx|153}}, {{pr|amxx|228}}) |
* Added {{tt|SetParamEntity2}} native to fix entity param not changing in post hook ({{pr|amxx|395}}, {{pr|amxx|463}}) | * Added {{tt|SetParamEntity2}} native to fix entity param not changing in post hook ({{pr|amxx|395}}, {{pr|amxx|463}}) | ||
{{margin|10px|}} | {{margin|10px|}} | ||
Line 853: | Line 853: | ||
==== NVault ==== | ==== NVault ==== | ||
− | * Fixed a potential crash at map change if empty key or value | + | * Fixed a potential crash at map change if an empty key or value is saved ({{pr|amxx|112}}, {{pr|amxx|130}}) |
* Fixed potential formatting issue with {{tt|nvault_[p]set}} ({{pr|amxx|187}}) | * Fixed potential formatting issue with {{tt|nvault_[p]set}} ({{pr|amxx|187}}) | ||
Line 863: | Line 863: | ||
{{margin|10px|}} | {{margin|10px|}} | ||
− | * Added {{tt|regex_compile_ex}}, mainly to allow | + | * Added {{tt|regex_compile_ex}}, mainly to allow direct use of {{tt|PCRE_*}} flags ({{pr|amxx|69}}) |
* Added {{tt|regex_match_all_c}} and {{tt|regex_match_all}} to retrieve all matches ({{pr|amxx|69}}) | * Added {{tt|regex_match_all_c}} and {{tt|regex_match_all}} to retrieve all matches ({{pr|amxx|69}}) | ||
* Added {{tt|regex_replace}} to search and replace ({{pr|amxx|69}}) | * Added {{tt|regex_replace}} to search and replace ({{pr|amxx|69}}) | ||
Line 883: | Line 883: | ||
* Added a new {{tt|_flags}} parameter to allow non-blocking mode and return libc error ({{pr|amxx|301}}) | * Added a new {{tt|_flags}} parameter to allow non-blocking mode and return libc error ({{pr|amxx|301}}) | ||
− | * Added {{tt|socket_is_writable}} native to check whether a socket is ready | + | * Added {{tt|socket_is_writable}} native to check whether a socket is ready to write ({{pr|amxx|301}}) |
* Added {{tt|socket_is_readable}} as an alias to {{tt|socket_change}} ({{pr|amxx|301}}) | * Added {{tt|socket_is_readable}} as an alias to {{tt|socket_change}} ({{pr|amxx|301}}) | ||
{{margin|10px|}} | {{margin|10px|}} | ||
Line 900: | Line 900: | ||
* Fixed {{tt|tfcstats_rankbots}} not working as expected when disabled ({{bz|3192}}) | * Fixed {{tt|tfcstats_rankbots}} not working as expected when disabled ({{bz|3192}}) | ||
* Fixed {{tt|tfcstats_pause}} imcomplete implementation ({{bz|5836}}) | * Fixed {{tt|tfcstats_pause}} imcomplete implementation ({{bz|5836}}) | ||
− | * Fixed {{tt|tfc_setbammo}} not working under | + | * Fixed {{tt|tfc_setbammo}} not working under Linux ({{bz|5845}}) |
* Fixed {{tt|TFC_PC_CIVILIAN}} value ({{bz|6042}}) | * Fixed {{tt|TFC_PC_CIVILIAN}} value ({{bz|6042}}) | ||
* Fixed crash when Infection weapon is used ({{pr|amxx|232}}, {{bz|6333}}) | * Fixed crash when Infection weapon is used ({{pr|amxx|232}}, {{bz|6333}}) |
Revision as of 13:05, 31 August 2018
AMX Mod X 1.9 is a major update, containing many features, fixes, and improvements under the hood.
- ✓ All old plugins and modules will continue to work.
- ✓ This release does have new configuration files.
- ✓ This release does have configuration changes.
- ✓ This release does include plugin changes.
- ✓ This release does have translations changes.
- ✓ This release does not break compatibility.
⇅
.
Contents
Major Highlights
GitHub
A friendly reminder of the previous announcement on the AMX Mod X website, all development is now done on GitHub.
You can now check out the latest changes on https://github.com/alliedmodders/amxmodx.
Any help is welcomed and encouraged. To contribute, there are two ways:
- To report a bug or request a feature, you can create an issue here: https://github.com/alliedmodders/amxmodx/issues
- To directly contribute to the AMX Mod X repository, you can create a Pull Request by following this guide: https://wiki.alliedmods.net/Git_Tutorial.
- You can see the current PRs here as well: https://github.com/alliedmodders/amxmodx/pulls.
- → Don't hesitate to give your thoughts or to review, anyone can participate!
General
The improvements for AMX Mod X 1.9 span the whole project:
- Stability and performance improvements
- Official support for ReHLDS and ReGameDLL
- Greatly improved UTF-8 support across the project
- Significant improvements to modules and official plugins
- (Almost) completely revised and completed documentation
- Tons of new functionalities for plugin developers and admins
Compatibility
For AMX Mod X plugins and modules, this release is fully backward compatible. Anything else is a bug.
However, a lot of legacy AMX Mod (no X) code has been removed, so we no longer guarantee backward compatibility for AMX Mod plugins.
AMX Mod X contains a host of new features for developers, so plugins and modules compiled against AMX Mod X 1.9 will not run on an earlier version.
If we are made aware of compatibility issues, we will list the known issues below while a fix is developed.
Known Issues:
- None
Upgrading
Upgrading follows the standard procedure, however, there are some specific steps that require additional attention.
General
- Ensure your game server is completely stopped as you cannot properly update some files while they are still in use.
- Replace all binaries:
- Replace languages files:
- Any
.txt
files in/amxmodx/data/lang
folder
- Any
- Replace
hamdata.ini
in/amxmodx/configs
folder - If you do scripting locally:
New files
- Copy
GeoLite2-Country.mmdb
to the/amxmodx/data
folder (optionally, delete the oldGeoIP.dat
file) - Copy the whole
gamedata
directory to the/amxmodx/data
folder
Config changes
File | Changes |
---|---|
amxx.cfg
|
⇅ New cvars// Server language in ISO 639-1 format // Please see data/lang/languages.txt file for a list of supported languages // // Default value: en amx_language "en" // If you set this to 0, clients will not see a message about amx_langmenu when they join the server // // Default value: 1 amx_language_display_msg 1 // Max temporary ban time (admins with ADMIN_BAN_TEMP access can't ban more than this time) // time in minutes, 60 is 1 hour, 120 is 2 hours, 1440 is 1 day, and 10080 is 1 week // Default value: 4320 aka 3 days amx_tempban_maxtime 4320 // Time to wait (in seconds) before displaying a message about amx_help to a client once joined the server // // Default value: 15 amx_help_display_msg_time 15 // If you set this to 0, clients will not see a message about amx_help when they join the server // // Default value: 1 amx_help_display_msg 1 // Amount of commands per amx_help page // // Default value: 10 amx_help_amount_per_page 10 Note:
amx_help_display_msg replaces the DISPLAY_MSG define in admin_help.sma . Note: amx_help_amount_per_page replaces the HELPAMOUNT define in admin_help.sma .Slay is now in the last position. "0" slap damage to the default values was wrongly left out. // Slay is automaticall inserted as the last option // Default values: 0 1 5 amx_plmenu_slapdmg 0 1 5 Missing values: // Show admins activity // 0 - disabled // 1 - show without admin name // 2 - show with name // 3 - show name only to admins, hide name from normal users // 4 - show name only to admins, show nothing to normal users // 5 - hide name only to admins, show nothing to normal users // // Default value: 2 amx_show_activity 2 |
core.ini
|
⇅ One missing and one new option.; Admin commnand flag manager ; 0 - enabled ; 1 - disabled disableflagman 0 ; MySQL default timeout mysql_timeout 60 |
sql.cfg
|
⇅ New cvaramx_sql_timeout "60" |
users.ini
|
⇅ New flag & documentation adjusted; d - amx_ban and amx_unban commands (permanent and temporary bans) ; v - amx_ban and amx_unban commands (temporary bans only, about amx_unban, only self performed ban during map gonna be allowed) |
Overview for Admins
Gamedata
The AMX Mod X team has made an effort to avoid hard-coding game-specific data into AMXX core and modules. New gamedata files have been created which are located in the amxmodx/data/gamedata/
directory.
These files are now mandatory.
Game data files shipped with AMX Mod X can and will be updated at any time, therefore it is strongly discouraged to edit them manually.
To make custom gamedata changes, please use the custom
folder under the gamedata
directory. All files under this directory are parsed (in an undefined order) after the main files are loaded. They will never be overwritten.
GeoIP
The GeoIP.dat
file is now replaced by GeoLite2-Country.mmdb
file.
As usual, a more detailed city version exists but is not provided in the default distribution. Plugins can require this version to operate.
Both (Country: ~2 MB, City: ~30 MB) can be downloaded from the official page: https://dev.maxmind.com/geoip/geoip2/geolite2/ (MaxMind DB binary).
Plugins
Most plugins received large amounts of code improvements, modernizing and optimizing them using the latest AMXX core features. This also includes a few security fixes.
However, this does not (yet) translate into major user-facing features. We tried to improve internal tools before focusing on that.
The features in this release are:
General
- A new access level flag
v
for temporary bans - UTF-8 support in some MOTD
Admin Commands
- A new
amx_extendmap
command to extend the time limit of the current map. Usage:<time in minutes>
- A new
amx_xvar_int
andamx_xvar_float
command
Admin Chat
- Cooldown on
say_team @]
to avoid overflow on admins
Admin Help
- A new
amx_searchcmd
command to display information about a command. Usage:<match> <entry no.> [no. of entries to display (server only)]
- The hardcoded defines are replaced with
amx_help_display_msg
,amx_help_display_msg_time
andamx_help_amount_per_page
cvars
CS Misc. Stats
- A new
/msounds
client command to enable/disable sounds - A new option to disable showing last man's health
Players Menu
- A new Silent Transfer option
- A new
amx_language_display_msg
cvar for previously hardcodedDISPLAY_MSG
- Slay is now the last option in the Slay/Slap Menu
Restrict Weapons
- The
MAPSETTINGS
define is replaced byamx_restrmapsettings
cvar - No more hardcoded multilingual messages
- Admin activity is displayed on config loading/saving
- Opened menu is refereshed if the command is used to save/load/set
- Menu/command items are now grouped per class
Stats X
- Some translations are now player-specific.
Teleport Menu
- Possibility of being stuck should be reduced.
Translations
Along with fixes, improvements, and completion of existing translations, two new languages are provided:
- Russian
- Chinese
Overview for Developers
General
There are too many additions to list them here in details. For complete API changes and additions, see AMX_Mod_X_1.9_API_Changes.
It is strongly recommended to check out the changes, a lot of information is contained there.
Essentially:
- Documentation has been updated in many ways.
- Compiler got a bunch of fixes and minor improvements/features.
- The API has been updated with various fixes and improvements.
- New module
- New core APIs
- Existing core APIs additions
- Existing module APIs additions
Changelog
Internal
Compilation
- Ported buildscripts to new AMBuild2 platform, https://github.com/alliedmodders/ambuild
- Removed MakeFile (PR 262)
- Fixed GCC 4.8, Clang 3.9+ compilation (amb273061, PR 458)
Library
- Now using new AlliedModders Template Library (AMTL) in many places, https://github.com/alliedmodders/amtl (PR 138, PR 260, PR 270, PR 296, PR 422, PR 436)
- Added basic ReHLDS and ReGameDLL support (PR 417, PR 423, PR 425, PR 427, PR 446, PR 450, PR 483)
- Removed pre-compiled zlib from the tree (PR 117, PR 118)
- Unified zlib linkage by compiling it as a static library and linking it to concerned projects (PR 195)
Others
- Added license files for GPL2+/GPL3+, updated headers and
amxx gpl
command (PR 102, PR 103) - Deduplicated a number of files used by modules by moving them to the public directory (PR 112)
- Enabled C++11 support (PR 162)
- Updated versioning system and added missing module RC file (PR 165)
- Improved SELinux compatibility (PR 328)
- Updated Visual Studio projects files (PR 109, PR 247)
- Added Visual Studio 2015+ support (PR 179, PR 333, PR 397)
Core
Config
Command
- Made registered server commands case-insensitive (bug 5625)
- Extended
amxx list
command to search with criteria (PR 377)
Menu
- Updated mods list supporting colored menus: DMC, TFC and Valve (PR 143)
- Fixed unexpected behaviors when a game menu is overlapped with a custom one (bug 3199)
- Fixed a crash with overlapping newmenu (PR 462)
Module API
- Fixed
OnPluginsUnloaded
not being called for reloadable modules (PR 485)
Multilingual
- Improved method to check whether a multilingual file has been processed (PR 213)
- Fixed dictionary text files parser failing on BOM marking (bug 5858)
- Fixed missing status reset on successful language key retrieval (bug 5994)
Native
- Increased
get_amxstring
buffer size up to 16k (bug 5901)
- Fixed crash when dynamic native is executed with the max number of params (PR 291)
Others
- Added plugin version to debug trace information (bug 3649)
- Removed KTrie dependency to Hash map (PR 8, PR 406)
- Removed AMX Mod compatibility (PR 31, PR 461)
- Removed useless natives: hcsardhnexsnu, is_user_hacking, is_rukia_a_hag, and amxx_setpl_curweap (PR 461)
- Fixed incorrect message error on plugin which uses a deprecated file format (PR 275)
- Fixed spectator team index not being set in specific situations (Counter-strike only) (PR 15)
- Fixed an unicode issue with
amx_SetStringOld
(PR 22, PR 23) - Fixed log not written earlier at the first server start (PR 265)
- Fixed a memory leak when registering a forward fails due to missing callback (PR 465)
User
Translation
- Added Chinese language (PR 75)
- Updated Macedonian & Bulgarian translations (PR 477)
- Updated Hungarian translations (PR 474, PR 494)
- Fixed incorrect keys in several multilingual files (PR 27)
- Fixed missing translations for the following languages: de, cz, ro and sr (PR 27)
- Fixed various translations (PR 67)
Plugin
General
- Added a new access level flag
v
for temporary bans (bug 3218, PR 440) - Added UTF-8 support in some MOTD (bug 5825, PR 135)
- Removed AMX Mod compatibility (PR 28)
- Removed leet speak translation (PR 83)
- Removed some
client_cmd
usage (PR 88) - Applied general optimizations (bug 5822, bug 5833, bug 5818, PR 9, PR 17, PR 78, PR 82, PR 88, PR 89, PR 90, PR 136, PR 139, PR 141, PR 190, PR 194, PR 214, PR 216, PR 227, PR 241, PR 256, PR 362, PR 424)
Admin Base
- Directly kick players rather than use a loopback command (bug 5946)
- Assigned
FCVAR_PROTECTED
directly inregister_cvar
instead of after startup (PR 87) - Replaced
console_print
withengclient_print
to support connecting players (PR 251, bug 6372)
- Fixed an issue when not including a port when an admin is added by IP address (bug 5978)
Admin Chat
- Implemented cooldown on
say_team @]
to prevent admin's client get overflowed if executed a couple of times (bug 5815)
- Fixed broken admin chat access consistency (bug 5822)
Admin Commands
- Added
amx_extendmap
command (bug 3068) - Added
amx_xvar
command (bug 5896) - Added check for empty string in
amx_chat
command (bug 6017)
- Trimmed target in
amx_ban
to prevent bypassing checks (PR 86) - Removed slowhack in
amx_nick
command (bug 5832) - Sanitized
servercfgfile
andlservercfgfile
values (bug 6578
- Fixed Template:Amx slap unexpected behavior using large negative damage (bug 4975)
- Fixed a permission scalability bug in the following commands: (bug 6578, PR 441)
amx_addban
amx_exec
amx_cvar
Admin Help
- Added
amx_searchcmd
command (PR 415, PR 456) - Replaced hardcoded defines with
amx_help_display_msg
,amx_help_display_msg_time
andamx_help_amount_per_page
cvars (PR 84, PR 415)
CS Misc. Stats
- Added
/msounds
client command to enable/disable sounds (bug 5846) - Added an option to disable showing last man's health (bug 5847, PR 122)
- Fixed missing stats sounds, sounds precaching and few bugs (bug 5810)
Map Menu Plugin
- Fixed possible buffer overflows (PR 91)
Multi-Lingula System
- Moved
amx_language
cvar to core (PR 82)
NextMap
- Fixed last map not properly saving resulting mapcycle reset at mapchange (bug 5817)
- Fixed an in-game issue where
mp_chattime
cvar doesn't exist (bug 5922)
Nextmap Chooser
- Fixed possible buffer overflows (PR 91)
Players Menu
- Added Silent Transfer Option (PR 113, PR 161)
- Added
amx_language_display_msg
cvar for previously hardcodedDISPLAY_MSG
(PR 82)
- Moved slay as last option instead of first in Slay/Slap Menu (bug 5861)
- Removed vault usage,
amx_setlang
and server language from the menu in favor ofamx_language
(PR 82) - Used server language as fallback if client's "lang" key is not defined (PR 106)
Plugin Menu
- Fixed unreachable code warning (PR 131)
Restrict Weapons
- Overhauled the plugin (PR 347)
- Applied general optimization and small QoL changes
- Moved
MAPSETTINGS
define to cvaramx_restrmapsettings
- Made hardcoded messages multilingual
- Displayed admin activity on config loading/saving
- Refreshed opened menus if the command is used to save/load/set
- Grouped visually menu/command items per class
Stats X
- Moved formatting from
LANG_SERVER
to player-specific translations where possible (PR 9)
TimeLeft
- Fixed possible out of bound error (bug 5818)
Teleport Menu
- Improved precision to reduce the possibility of being stuck after teleportation (PR 17)
Developer
General
New Modules
- Introduced a JSON module (PR 379)
Engine
- Fixed some natives relying on a known engine bug related to last player's edict being invalid (bug 6429, PR 297, PR 299, PR 306)
emit_sound
Last player wasn't hearing the sound. e/message_begin
,dod_weaponlist
Was leading to a crash because engine doesn't like MSG_ONE_*
with null entity.TFC_[Clear/Set]Model
Was leading to a crash because of null edict. set_tr/2
Was not working when used with TR_pHit
pev
Was returning 0 used with pev_edict
pev_valid
Was returning 0.
Miscellaneous
- Added
DMG_GRENADE
constant (CS Only) (bug 6030) - Added missing
SVC_
messages (PR 223)SVC_RESOURCELOCATION
SVC_SENDCVARVALUE
SVC_SENDCVARVALUE2
- Added new xs stocks (PR 426)
xs_vec_len_2d
xs_vec_distance
xs_vec_distance_2d
xs_vec_add_scaled
xs_vec_sub_scaled
- Added
STATSX_*
,DODX_*
andMAX_BODYHITS
constants for client statistics (PR 509)
- Allowed
arrayset
to accept any type (PR 516) - Allowed
ExecuteForward
without need to create variable for returned value (PR 382) - Enforced
any:
tag in several natives header for convenience (PR 166, PR 222, PR 499) - Moved string constants and stocks in their own
string_const.inc
andstring_stocks.inc
includes PR 407
Core
New APIs
- Introduced Automatic Config File API (PR 266, PR 289, PR 496)
- Introduced DataPacks API (bug 5885, PR 231, PR 261, PR 419)
- Introduced Game Config Parser API (PR 254)
- Introduced Hasher API (PR 206, PR 384)
- Introduced Stack structures API (PR 94)
- Introduced TextParser API (PR 101, PR 272, PR 344, bug 6228, bug 6476)
- Introduced Trie Iterator API (PR 413)
Cellarray
- Added
ArraySortEx
/SortADTArray
natives and newSort_Random
sort method (bug 5494, PR 279) - Added the following new CellArray natives:
ArrayClone
,ArrayResize
,ArrayFindString
andArrayFindValue
(bug 6104, PR 107, PR 408) - Added
size
parameter toArrayGetArray
,ArraySetArray
andArrayPushArray
to control the number of elements to use (PR 76, PR 111) - Added
block
parameter toArrayGetCell
andArraySetCell
to specify which block (PR 76, PR 111) - Added
achar
parameter toArrayGetCell
andArraySetCell
value as a byte (PR 76, PR 111)
- Fixed an overflow issue with
ArrayInsertBefore
andArrayInsertAfter
(bug 4330) - Fixed
ArrayDestroy
erroring on invalid handle (PR 210)
CellTrie
- Added
TrieGetSize
andTrieSnapshot*
natives (PR 8) - Added new
replace
parameters forTrieSet*
natives to make the operation fail if key already set (PR 8) - Added new
size
parameter forTrieGetString
andTrieGetArray
to return the number of bytes written in the buffer (PR 8)
Client
- Added
client_disconnected
forward to fix player not being internally disconnected in some situation (PR 264, PR 304, PR 334) - Added
client_remove
forward (post version ofclient_disconnected
PR 414 - Added
client_connectex
forward to allow to reject player’s attempt to join (PR 322) - Added
flag
parameter touser_silentkill
(PR 323) - Added
find_player_ex
native, a wrapper offind_player
using flags as strings (PR 389) - Added
get_players_ex
stock, a wrapper ofget_players
using flags as strings (PR 389) - Extended
client_authorized
to pass steam ID (PR 322) - Set
set_user_rendering
default color/amount to 0 to follow game behavior (bug 5772) - Allowed the following natives to be used on connecting players:
find_player
,get_players
andengclient_print
(console only) (bug 6229, PR 126)
- Fixed
user_slap
unexpected behavior when using large negative damage (bug 4975) - Fixed missing new line on client console message which is not truncated server-side if its length exceeds buffer size (bug 3140)
Cvar/Command
- Introduced several natives for cvars management (PR 185, PR 202, PR 203, PR 211, PR 230, PR 318, PR 337, PR 453)
- Added
amxclient_cmd
native (bug 5887, PR 438) - Added
read_argv_int
andread_argv_float
to return the value directly as integer or float (PR 366, PR 383) - Added a param to
register_*cmd
andget_*cmd
to specifyinfo
is a multilingual key in order to encourage command translation (PR 349, PR 434)
- Fixed a
engclient_cmd
buffer issue (PR 438)
Event
- Added new
register_event
flags to filter humans and bots (bug 5768) - Added
register_event_ex
native, a wrapper ofregister_event
using flags as strings (PR 389) - Added
enable/disable_event
natives (bug 6360, PR 267) - Added
enable/disable_logevent
natives (PR 326)
- Fixed reentrancy issue when a generated message is sent during
register_event
forward (bug 3664)
File
- Added support for Valve FS to natives that use file handles (PR 217, PR 235, PR 467)
- Added
SetFilePermissions
native - Added
FileReadInt8
,FileReadUint8
,FileReadInt16
,FileReadUint16
andFileReadInt32
natives - Added
FileWriteInt8
,FileWriteInt16
andFileWriteInt32
natives - Added
GetFileTime
native returning a file timestamp as a unix timestamp (bug 4543)
Menu
- Added menu timeout functionality to Newmenu API (PR 21) TODO: link to script changes?
- Added
MEXIT_FORCE
to force a proper exit button on unpaginated menus (PR 20) - Added
MPROP_SHOWPAGE
to set whether or not to show the page number in menu title (PR 473) - Added
menu_addblank2
andmenu_addtext2
to fix unexpected behavior with the original ones whenslot
param is set to 1 (bug 3096) - Added menu pagination callback (PR 420)
- Add default values for
menu_item_getinfo
's arguments (PR 511)
- Fixed recursion issues with
show_menu
and newmenus (PR 140, PR 335) - Fixed a potential underflow bug which can occur when a non-paginated menu has no items in it (PR 20)
- Fixed a potential menu handle leak when
show_menu
is used after a newmenu was opened (PR 21) - Fixed
MPROP_NOCOLORS
menu property not working (PR 283) - Fixed missing format param on error in
next_hudchannel
native (PR 391) - Fixed a menu recursion issue (PR 471)
Message
- Added
e/write_/coord/angle/_f
ande/message_begin_f
natives (bug 5829) - Added
client_print_color
native (Counter-Strike only) (bug 5823, PR 338, PR 504) - Added
set/show_dhudmessage
which uses a different kind of message HUD (hint) (bug 5979) - Added
client_printex
stock (bug 5828, PR 10) - Added
MSG_INIT
support inmessage_begin
native (bug 6254, PR 151) - Added
elog_message
native (PR 451)
- Set
set_hudmessage
default channel to -1 to reflect auto-channeling support (bug 5771)
String
- Added
strtol
native (bug 3233) - Added
strtof
native (bug 5909) - Added
strtok2
which fixes a trim issue withstrtok
(bug 3993) - Added new string-related stocks (bug 6110, PR 327)
- Added new string-related natives (bug 6110)
- Added
fmt
native to format and return a string inline (PR 350) - Added support for binary format
%b
(bug 6110) - Added special format specifiers
%n
and%N
(PR 93) - Added support for
%l
format specifier (bug 6361, PR 229, PR 313, PR 320, PR 331, PR 343) - Added
SetGlobalTransTarget
to globally set the player’s language, for use with%l
format specifier (PR 229) - Added text formatting ability to
set_fail_state
(bug 5800) - Added some UTF-8 compatible natives (PR 407)
mb_strotolower
mb_strtoupper
mb_ucfirst
mb_strtotitle
is_string_category
- Made formatting-capable function UTF-8 safe (including precision with %s e.g. %.12s) (bug 6110)
- Made a bunch of stocks/natives UTF-8 safe (bug 6110, PR 159)
- Improved UTF-8 support in some natives (PR 407, PR 459)
containi
strfind
(with ignorecase set)strcmp
(with ignorecase set)strncmp
(with ignorecase set)equali
replace_string
(with ignorecase set)replace_stringex
(with ignorecase set)get_players
(with name and ignorecase flags set)find_player
(with name and ignorecase flags set)
- Fixed UTF-8 character parsing due to improper casting (PR 401)
- Fixed
strncmp
case sensitivity (PR 314) - Fixed a
floatround
overflow on large numbers resulting in a negative number when optimization is enabled (PR 376)
Others
- Added
Get/SetModelCollisionBox
andGet/Set/ModelBoundingBox
(bug 3527) - Added
has_map_ent_class
native (bug 5814) - Added
engine_changelevel
(PR 104, PR 184, PR 503) - Added
FP_VAL_BYREF
to pass values by reference in forwards (PR 369) - Added
RequestFrame
native (PR 412) - Added
set_task_ex
stock, a wrapper ofset_task
using flags as strings (PR 389)
- Hidden blank line in abort native with
AMX_ERR_NONE
(bug 6233, PR 125) - Improved
power
native on large number (PR 385)
- Fixed definite time drift on repeating tasks (bug 3302)
- Fixed a potential issue in
get_plugin
(PR 277) - Fixed a crash when a dynamic native is executed with the max number of params (PR 291)
Compiler
- Added support for Emscripten to the compiler (PR 115)
- Added the following globals (PR 116)
__BINARY_PATH__
__BINARY_FILE__
__LINE__
- Added
#pragma deprecated
(PR 116, PR 307) - Added a flag
-E
to consider all warnings as errors (PR 137) - Added string literal concatenation and stringizing operator (PR 173)
- Added ability to directly reference another address in a default argument (for arrays only) (PR 248)
- Removed AMX Mod compatibility (PR 31)
- Increased variable and functions maximum name length from
31
to63
characters (bug 5924) - Increased input line length from
511
to4095
characters (PR 116) - Ignored
#pragma tabsize
with non-positive argument (PR 116) - Improved
sizeof
return on array without specifying the dimensions (PR 116, PR 158) - Improved the reported line number accuracy on warning 203/4 (symbol never used) (PR 116)
- Used in-memory buffers for reading files, and handling newline better (PR 116)
- Used hash table for global name lookups (PR 116)
- Disabled the estimated usage calculation because it doesn’t work well and is not that useful (PR 137)
- Removed scpack (PR 221, PR 226)
- Prevented declaring arrays that the compiler is too buggy to handle (PR 248)
- Fixed returning strings from variadic functions (PR 121, PR 399)
- Fixed issue with multidimensional array variable release (PR 116)
- Fixed memory corruption when parsing natives (PR 116)
- Fixed improper handling of constant chained relational operators, i.e:
0 < 1 <= 2
(PR 116) - Fixed bogus assert about name lengths (PR 116)
- Fixed asserting when returning a string literal (PR 116)
- Fixed return omission with else-after-return (PR 116)
- Fixed crash when using
tagof(tagname:)
(PR 116) - Fixed the
@
character not being allowed in macro definitions (PR 116) - Fixed
#elseif
handling not working as expected (PR 116) - Fixed
enum
field size was not taken into account when implicitly passed to a function (PR 116) - Fixed trailing commas in array literals changing the result of
sizeof
(PR 163) - Fixed regression with member tag of
enum
is not being checked on assignment (PR 164) - Fixed
tagof
operator used as a default value for function arguments (PR 191) - Fixed issue where native functions returning an array would not compile (PR 351)
- Fixed compilation error for GCC 6 (PR 372)
- Fixed compilation for Clang 3.5+ (PR 177, PR 361)
- Fixed inc/dec operators not returning an iEXPRESSION (PR 429)
Modules
CStrike
- Added
CS_OnBuy
forward, called right before an item is received (PR 25, PR 68, PR 124, PR 183, PR 263, PR 315, PR 340, PR 334) - Added
CS_OnBuyAttempt
forward, called right after a command is issued (PR 68, PR 263, PR 334) - Added
cs_create_entity
native (PR 189, PR 193) - Added
cs_find_ent_by_class
native (PR 189, PR 193) - Added
cs_find_ent_by_owner
(PR 278) - Added
cs_set_ent_class native
(PR 332) - Added
cs_get_user_weapon_entity
andcs_get_user_weapon
natives (PR 330, PR 353) - Added
cs_get_weapon_class
andcs_is_valid_itemid
stocks for convenience (PR 278) - Added
cs_get_item_id
native to get aCSI_
value from a given alias,weapon_
oritem_
(PR 278, PR 342) - Added
cs_get_translated_item_alias
native to get an item name (classname) from a given alias (PR 278, PR 356) - Added
cs_get_item_alias
(PR 342) - Added
cs_get_weapon_info
native which gives various information about a weapon (only) (PR 278, PR 356) - Added a param to
cs_set_user_deaths
native to choose whether the scoreboard should be updated (PR 255) - Added support for
monster_scientist
entity (alias ofhostage_entity
) to hostage natives (PR 255) - Added a
count
param tocs_get/set_armoury_type
to get/set the number of weapons inside an armoury (PR 255) - Added a
update_index
param incs_set_user_model
to choose whether the model index should be updated (PR 255, PR 300, PR 370) - Added a
CS_NORESET
constant for use withcs_set_user_team
for skipping the model reset (PR 287, PR 400) - Added a new value for
draw_animation
incs_set_weapon_silen
which follows game behavior (PR 255) - Added the associated
TRAIN_*
constants from HLSDK for use withcs_get_user_driving
(PR 255)
- Moved all hardcoded data to its own gamedata files (PR 255, PR 352, PR 356)
- Done some cleanup for the sake of consistency and readability (PR 255)
- Added some known constants from CS, a
cstrike_const.inc
has been created for the occasion (PR 278) - Cached
GET_USER_MSG_ID
calls (PR 255) - Improved
cs_set_no_knives
internal code by hookingpfnCreateNamedEntity
only when necessary (PR 255) - Made
cs_get_user_armor
armortype
param optional (PR 255) - Improved
cs_set_user_zoom
by using an event-based approach rather than enforcing on-frame basis whenmode
is 0 (PR 255)
- Fixed
cs_user_spawn
to properly respawn players (bug 3752) - Fixed
cs_set_user_team
not telling core spectator team change (PR 13) - Fixed
cs_get_hostage_id
error check: a hostage can't be a player (PR 255) - Fixed
cs_set_user_[model/team]
andcs_reset_user_[model/team]
overflow issue by staggering user's info updates across multiple frames (PR 255) - Fixed missing meta return in
ServerActivate
(PR 308)
CSX
- Modified
csstats_rank
value to matchamxx.cfg
default value (PR 170)
- Fixed
client_death/damage
forwards passing alive victims onClientKill
(bug 5812) - Fixed
client_death
forward called onkill
command if sent by a spectator (PR 404)
DoDX
- Fixed grenade_throw incorrect calling behavior and wrong returned weapon IDs (bug 5785)
- Fixed a potential crash (PR 277)
DoDFun
- Fixed a potential issue (PR 277)
Engine
- Added
client_cmdStart
forward (bug 5779) - Added
set_ent_rendering
native (bug 5773) - Added
entity_intersects
native (bug 6172, PR 70, PR 367) - Added
unregister_touch/think/impulse
(PR 250) - Added safe
get_global_edict2
andentity_get_edict2
(PR 250, PR 367) - Added a destination parameter to
trace_hull
to make it useful usingNULL_VECTOR
(PR 250)
- Improved
set_lights
internal working, only hook server frame whenpfnLightStyle
has been called (PR 250) - Moved
precache_event
to core (PR 250, PR 490) - Removed inconsistent error path from
entity_get_int
(PR 250) - Added error path for
remove_entity
and unsafe entity ids (PR 250) - Added a bunch of missing entity checks (PR 250, PR 345, PR 346, PR 355)
- Used UTF-8 functions where
KeyValueData
is touched (PR 250) - Allowed
find_ent_by_owner
native to work inclient_disconnect
forward (PR 152)
- Fixed a crash when using
get/set_usercmd
(bug 5744) - Fixed
set_view
alteringpev
properties instead ofentity_state
for rendering players (bug 5382) - Fixed incorrect behavior of impulse forwards (bug 3243)
- Fixed
pfn_spawn
metamod return to follow engine behavior (bug 5807) - Fixed
set_ent_rendering
not working on non-player entities (PR 71) - Fixed
get_info_keybuffer
not being able to retrieve local key buffer (PR 250) - Fixed an entity check logic error (PR 250, PR 259)
- Fixed
is_visible
native not working on players (PR 392) - Fixed a
set_lights
buffer issue which was resulting in an incorrect light (PR 464, PR 508)
Fakemeta
- Added
create_kvd
andfree_kvd
allowing creation of new KVD structures that can be used with Hamsandwich. - Added new
get
/set_pdata_*
natives for the following types:bool
,byte
,short
,vector
,ehandle
andent
(bug 5770) - Introduced new natives to read/write on entity's private data based off class/member name using gamedata files (PR 284)
get
/set_ent_data
get
/set_ent_data_float
get
/set_ent_data_vector
get
/set_ent_data_entity
get
/set_ent_data_string
get_ent_data_size
find_ent_data_info
get_field_basetype
- Introduced natives to read/write on the gamerules object (PR 298, PR 309, PR 316)
get
/set_gamerules_int
get
/set_gamerulesa_float
get
/set_gamerules_vector
get
/set_gamerules_entity
get
/set_gamerules_string
get_gamerules_size
find_gamerules_info
- Allowed
get/set_pdata_cbase
usage at map end whereas player's private data is still valid (bug 5787) - Improved handling of
KeyValueData
and made it compatible with Hamsandwich (PR 240) - Allowed null invoker to be passed in
EngFunc_PlayBackEvent
(PR 358, bug 6467)
- Fixed
pev_blending
not working with set_pev (bug 5758) - Fixed broken
EngFunc_ChangeLevel
(PR 244) - Fixed a bug with recursive pre hooks (PR 341)
- Fixed memory leak in
unregister_forward
(PR 388)
GeoIP
- Module now uses the latest MaxMind GeoIP2 API (PR 99, PR 104, PR 132)
- Added new (UTF-8 safe)
geoip_*
natives to retrieve the city, region, continent and more (PR 99, PR 198, PR 200) - Added a
geoip
command mainly for debugging purposes (version, dump an ip data) (PR 99) - Marked
geoip_country
as deprecated in favor of the newgeoip_country_ex
native (PR 99)
Hamsandwich
- Added support for the following mods:
- Deathmatch Classic
- Adrenaline Gamer
- Opposing Forces
- Sven Coop v5.13 (todo: update to v5.14)
- Added several functions which required different handlers
- Added a lot of missing virtual functions for all mods
- Added natives to deal with the
ItemInfo
structure - Added support for bots without
player
classname (bug 6111, bug 6323, PR 153, PR 228) - Added
SetParamEntity2
native to fix entity param not changing in post hook (PR 395, PR 463)
- Updated offsets for all mods (PR 354)
- Aligned stack on 16 byte boundary in hamsandwich trampolines (PR 24)
- Fixed crash for functions returning a vector
- Fixed crash when
Ham_TakeHealth
is called - Fixed various typos
- Fixed misaligned offsets in
hamdata.ini
- Fixed vtable patching on Linux for newer GCC binaries
- Fixed resource leak when reading
hamdata.ini
(PR 274) - Fixed
ham hooks
command not displaying all current hooks of a plugin (PR 276) - Fixed
HAM_OVERRIDE
in post hooks (bug 6443, PR 317) - Fixed a buffer issue in
RegisterHam
(PR 495)
MySQL
- Added
SQL_SetCharset
native to (re)set character set (bug 5999) - Added MySQL Reconnect feature (PR 154)
- Bumped MySQL version to 5.5 (PR 466, PR 468)
- Established a default timeout for MySQL connectivity (PR 188)
- Improved module threading to be more responsive (PR 207)
NVault
- Fixed a potential crash at map change if an empty key or value is saved (PR 112, PR 130)
- Fixed potential formatting issue with
nvault_[p]set
(PR 187)
NS
RegEx
- Added
regex_compile_ex
, mainly to allow direct use ofPCRE_*
flags (PR 69) - Added
regex_match_all_c
andregex_match_all
to retrieve all matches (PR 69) - Added
regex_replace
to search and replace (PR 69) - Added
regex_match_simple
stock (PR 69, PR 156)
- Updated PCRE to
v8.35
with UTF-8 support (PR 69) - Updated
regex_subtr
to increase static buffer size same as core and to make it UTF-8 safe (PR 69)
SQLite
- Updated library version from
3.3.13
to3.8.8.2
(PR 148)
- Fixed missing queuetime
FP_CELL
parameter inSQL_ThreadQuery
callback (PR 205) - Fixed missing buffer size check to {tt|QuoteString}} implementation (PR 411)
Socket
- Added a new
_flags
parameter to allow non-blocking mode and return libc error (PR 301) - Added
socket_is_writable
native to check whether a socket is ready to write (PR 301) - Added
socket_is_readable
as an alias tosocket_change
(PR 301)
- Updated WinSock version from
1.1
to2.2
(PR 301) - Properly checked for WinSock initialization on
OnAmxxAttach
/Detach
(PR 301) - Ignored natives registration if WinSock can't be started (PR 301)
- Made
socket_open
IP version agnostic (both IPv4 and IPv6 are supported) (PR 301) - Made
socket_close
to return a value on success/failure (PR 301)
NVault
- Fixed server crash when nvault is writing to journal file without write permission (bug 3231)