{"id":15978948,"url":"https://github.com/phrozenbyte/mtasa-debug","last_synced_at":"2025-04-04T18:14:54.430Z","repository":{"id":152900063,"uuid":"67257849","full_name":"PhrozenByte/mtasa-debug","owner":"PhrozenByte","description":"PhrozenByte Debug is a utility resource for Multi Theft Auto: San Andreas (MTA:SA), allowing resource developers to add \"quiet\" debug messages to their resources.","archived":false,"fork":false,"pushed_at":"2018-03-24T03:01:23.000Z","size":30,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-10T03:24:11.858Z","etag":null,"topics":["gnu-agpl","lua","mta","mtasa","multi-theft-auto","multiplayer","phrozenbyte-debug","scripting"],"latest_commit_sha":null,"homepage":"https://forum.mtasa.com/topic/88959-phrozenbyte-debug/","language":"Lua","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PhrozenByte.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-09-02T22:04:40.000Z","updated_at":"2018-03-24T03:01:21.000Z","dependencies_parsed_at":null,"dependency_job_id":"cab13145-ac53-4e5e-b5fe-cdfd528e3717","html_url":"https://github.com/PhrozenByte/mtasa-debug","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PhrozenByte%2Fmtasa-debug","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PhrozenByte%2Fmtasa-debug/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PhrozenByte%2Fmtasa-debug/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PhrozenByte%2Fmtasa-debug/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PhrozenByte","download_url":"https://codeload.github.com/PhrozenByte/mtasa-debug/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247226190,"owners_count":20904465,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["gnu-agpl","lua","mta","mtasa","multi-theft-auto","multiplayer","phrozenbyte-debug","scripting"],"created_at":"2024-10-07T23:40:27.065Z","updated_at":"2025-04-04T18:14:54.406Z","avatar_url":"https://github.com/PhrozenByte.png","language":"Lua","funding_links":[],"categories":[],"sub_categories":[],"readme":"PhrozenByte Debug 1.0\n=====================\n\nPhrozenByte Debug is a utility resource for Multi Theft Auto: San Andreas (MTA:SA), allowing resource developers to add \"quiet\" debug messages to their resources. MTA's built-in debug mechanism (`outputDebugString()` function) floods both the server console and log with debug messages - even in productive environments. This bears the danger that a server administrator misses important messages in his server log.\n\nThis utility resource hooks into MTA's built-in `/debugscript` command to detect whether a (authorized) player is currently debugging MTA. If this is the case, it passes all debug messages to MTA's `outputDebugString()` function; otherwise it discards them.\n\nFor this purpose PhrozenByte Debug exports the following server-side functions:\n\n* `int getDebugLevel()`\n* `bool log(int level, [ player fromPlayer = nil, ] string message, [ int red = 255, int green = 255, int blue = 255 ])`\n* `bool notice([ player fromPlayer = nil, ] string message, [ int red = 255, int green = 255, int blue = 255 ])`, `warn(…)` and `error(…)`\n\nPhrozenByte Debug furthermore exports the following client-side functions:\n\n* Client-side debugging:\n  * `int getDebugLevel()`\n  * `bool log(int level, string message, [ int red = 255, int green = 255, int blue = 255 ])`\n  * `bool notice(string message, [ int red = 255, int green = 255, int blue = 255 ])`, `warn(…)` and `error(…)`\n* Server-side debugging:\n  * `void requestServerDebugLevel([ element callbackElement = resourceRoot, ] callbackEventName)`\n  * `bool serverLog(int level, string message, [ int red = 255, int green = 255, int blue = 255 ])`\n  * `bool serverNotice(string message, [ int red = 255, int green = 255, int blue = 255 ])`, `serverWarn(…)` and `serverError(…)`\n* On-screen debugging:\n  * `int getOnScreenLogCount([ string column = nil ])`\n  * `int initOnScreenLog([ element sourceResource = nil, ] string message, [ int pauseUpdate = 0, mixed textAlign = \"center\", int red = 255, int green = 255, int blue = 255, int alpha = 255 ])`\n  * `void clearOnScreenLog(int logID)`\n  * `bool updateOnScreenLog(int logID, table data, [ string calcMode = nil ])`\n  * `bool simpleOnScreenLog(string message, table data, [ mixed textAlign = \"center\", int red = 255, int green = 255, int blue = 255, int alpha = 255 ])`\n\nLast but not least it exports the following shared functions:\n\n* `void dump(mixed variable, [ string name = nil, int level = 3 ])`\n* `string get(mixed variable)`\n\nWhen you're experiencing problems with PhrozenByte Debug, please don't hesitate to create a new [Issue](https://github.com/PhrozenByte/mtasa-debug/issues) on GitHub. If you're a developer, you can help make PhrozenByte Debug better by contributing code; simply open a new [PR](https://github.com/PhrozenByte/mtasa-debug/pulls) on GitHub. Contributing to PhrozenByte Debug is highly appreciated! \n\nLicense tl;dr\n-------------\n\nPhrozenByte Debug is free software, released under the terms of the GNU Affero General Public License version 3 (GNU AGPL).\n\nAccording to that you **can**...\n\n- modify the software and create derivatives\n- distribute the original or modified (derivative) works\n- use the software for both private and commercial purposes\n\nHowever, you **cannot**...\n\n- sublicense the software, i.e. any user has the right to run, modify and distribute the work\n- hold the software/license owner liable for damages (i.e. no warranty)\n\nNo matter what, you **must**...\n\n- retain the original copyright and include the full license text\n- state (non-trivial) changes made to the software and disclose your source code when distributing, publishing or serving a modified/derivative software\n\nPut briefly, the GNU AGPL is virtually the same as the GNU GPL: a free software license with copyleft. However, there's a **important difference**: Serving the software is considered as distribution (the so-called \"ASP loophole\")!\n\nThis means that if you modify the software, you **must** allow any player connected to your MTA server to retrieve the source code of your modified/derivative version of PhrozenByte Debug (e.g. by providing download links). To make things easier, we have included a `DOWNLOAD.md` file which is declared as client-side file in the `meta.xml`. If you modify the software, you can comply with the condition by changing the download URL in this file.\n\nTo cut a long story short: We recommend you to fork our GitHub repository and push all changes you've made to your fork ([Learn more](https://guides.github.com/activities/forking/)). Change the URL in the `DOWNLOAD.md` to your forked GitHub repository and you're ready to go. We would love to see if you open a PR to let your improvements flow back into the upstream project - this is called *Contributing* ([Learn more](https://guides.github.com/activities/contributing-to-open-source/)).\n\nPhrozenByte Debug furthermore adds the `/license` command returning the original copyright and declares the `LICENSE` file as client-side file in the `meta.xml`. This also serves the above license terms.\n\nFor the avoidance of doubt: Although the GNU AGPL is a copyleft license, you are *not* required to publish MTA resources (gamemodes, maps or any other kind of resource) using PhrozenByte Debug under the terms of the GNU AGPL. *Using* this resource does *not* \"infect\" your other resources, they do *not* become derivative works.\n\n\u003csmall\u003ePlease note that this is a human-readable summary of the [full license](LICENSE).\u003c/small\u003e\n\nCopyright\n---------\n\nCopyright (C) 2015-2018  Daniel Rudolf \u003chttp://www.daniel-rudolf.de/\u003e\n\nThis program is free software: you can redistribute it and/or modify it under the terms of the [GNU Affero General Public License](LICENSE) as published by the Free Software Foundation, version 3 of the License only.\n\nThis program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Affero General Public License for more details. You should have received a copy of the [GNU Affero General Public License](http://www.gnu.org/licenses/) along with this program.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphrozenbyte%2Fmtasa-debug","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphrozenbyte%2Fmtasa-debug","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphrozenbyte%2Fmtasa-debug/lists"}