{"action":"created","issue":{"url":"https://api.github.com/repos/alliedmodders/amxmodx/issues/185","labels_url":"https://api.github.com/repos/alliedmodders/amxmodx/issues/185/labels{/name}","comments_url":"https://api.github.com/repos/alliedmodders/amxmodx/issues/185/comments","events_url":"https://api.github.com/repos/alliedmodders/amxmodx/issues/185/events","html_url":"https://github.com/alliedmodders/amxmodx/pull/185","id":55828833,"number":185,"title":"Introduce new features for cvars","user":{"login":"Arkshine","id":360640,"avatar_url":"https://avatars.githubusercontent.com/u/360640?v=3","gravatar_id":"","url":"https://api.github.com/users/Arkshine","html_url":"https://github.com/Arkshine","followers_url":"https://api.github.com/users/Arkshine/followers","following_url":"https://api.github.com/users/Arkshine/following{/other_user}","gists_url":"https://api.github.com/users/Arkshine/gists{/gist_id}","starred_url":"https://api.github.com/users/Arkshine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Arkshine/subscriptions","organizations_url":"https://api.github.com/users/Arkshine/orgs","repos_url":"https://api.github.com/users/Arkshine/repos","events_url":"https://api.github.com/users/Arkshine/events{/privacy}","received_events_url":"https://api.github.com/users/Arkshine/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/alliedmodders/amxmodx/labels/enhancement","name":"enhancement","color":"207de5"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-01-28T22:56:48Z","updated_at":"2015-01-30T10:53:57Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/alliedmodders/amxmodx/pulls/185","html_url":"https://github.com/alliedmodders/amxmodx/pull/185","diff_url":"https://github.com/alliedmodders/amxmodx/pull/185.diff","patch_url":"https://github.com/alliedmodders/amxmodx/pull/185.patch"},"body":"New features are:\r\n\r\n<table>\r\n    <thead>\r\n        <tr>\r\n            <th> Description </th>\r\n            <th align=\"center\"> New natives </th>\r\n        </tr>\r\n    </thead>\r\n    <tbody>\r\n        <tr>\r\n            <td> Hooking a cvar change </td>\r\n            <td>  \r\n                <code>hook_cvar_change</code><br />\r\n                <code>enable_cvar_hook</code><br />\r\n                <code>disable_cvar_hook</code><br />\r\n            </td>\r\n        </tr>\r\n        <tr>\r\n            <td>Binding a cvar to a global variable (caching)</td>\r\n            <td>  \r\n                <code>bind_cvar_num</code><br />\r\n                <code>bind_cvar_float</code><br />\r\n                <code>bind_cvar_string</code><br />\r\n            </td>\r\n        </tr>\r\n        <tr>\r\n            <td>Creating cvar with more information (description and bounds)</td>\r\n            <td>  \r\n                <code>create_cvar</code>\r\n            </td>\r\n        </tr>\r\n        <tr>\r\n            <td>Defining a cvar bounds</td>\r\n            <td>  \r\n                <code>set_pcvar_bounds</code><br />\r\n                <code>get_pcvar_bounds</code><br />\r\n            </td>\r\n        </tr>\r\n        <tr>\r\n            <td>Adding boolean natives for convenience and readability</td>\r\n            <td>  \r\n                <code>set_pcvar_bool</code><br />\r\n                <code>get_pcvar_bool</code><br />\r\n            </td>\r\n        </tr>\r\n    </tbody>\r\n</table>\r\n\r\nTo reflect new additions:\r\n* `get_plugins_cvar` can retrieve cvar description\r\n* `amxx cvars` command has been extended to show more status (binded/hooked/bounded) and by providing an index from listing, it can show detailed information and from what plugins cvar is handled (useful for troubleshooting).\r\n\r\nWorth to be noted:\r\n* Cvars handled by AMXX are now cached and cache is now used by most of natives. It should give some welcomed performance boost.\r\n* The function hook used to catch cvar change is disabled by default and also at each map change. So it should be enabled only when necessary.\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/alliedmodders/amxmodx/issues/comments/72184513","html_url":"https://github.com/alliedmodders/amxmodx/pull/185#issuecomment-72184513","issue_url":"https://api.github.com/repos/alliedmodders/amxmodx/issues/185","id":72184513,"user":{"login":"Nextra","id":670853,"avatar_url":"https://avatars.githubusercontent.com/u/670853?v=3","gravatar_id":"","url":"https://api.github.com/users/Nextra","html_url":"https://github.com/Nextra","followers_url":"https://api.github.com/users/Nextra/followers","following_url":"https://api.github.com/users/Nextra/following{/other_user}","gists_url":"https://api.github.com/users/Nextra/gists{/gist_id}","starred_url":"https://api.github.com/users/Nextra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Nextra/subscriptions","organizations_url":"https://api.github.com/users/Nextra/orgs","repos_url":"https://api.github.com/users/Nextra/repos","events_url":"https://api.github.com/users/Nextra/events{/privacy}","received_events_url":"https://api.github.com/users/Nextra/received_events","type":"User","site_admin":false},"created_at":"2015-01-30T10:53:57Z","updated_at":"2015-01-30T10:53:57Z","body":":sheep:"}}