|
1 | | -# O2 Console |
| 1 | +# o2 InGame Console |
2 | 2 |
|
3 | | -**O2 Console** is an in-game, attribute-driven debug console for Unity that allows developers to define and execute commands easily. Built using the **Reflection API**, it dynamically discovers scene objects and registers command methods at runtime, making it incredibly flexible. With its real-time command execution and robust exception handling, O2 Console provides a powerful way to interact with and debug your game, enhancing your development experience. |
| 3 | +**o2 Console** is an in-game, attribute-driven debug console for Unity that allows developers to define and execute commands easily. Built using the **Reflection API**, it dynamically discovers scene objects and registers command methods at runtime, making it incredibly flexible. With its real-time command execution and robust exception handling, O2 Console provides a powerful way to interact with and debug your game, enhancing your development experience. |
4 | 4 |
|
5 | 5 | --- |
6 | 6 |
|
7 | 7 | ## Features |
8 | 8 |
|
9 | 9 | - **Command Attribute System**: Mark methods as console commands using `[ConsoleCommand("Command Key")]`, and O2 Console automatically registers them. |
10 | | -- **Reflection-Based Command Registration**: O2 Console scans and registers commands from methods, properties, and fields (both public and private) at runtime. |
| 10 | +- **Reflection-Based Command Registration**: O2 Console scans and registers commands from methods, properties, and fields (both public and private) during scene initialization. |
| 11 | +- **Supports Single Parameter Methods**: Currently, O2 Console supports methods with up to one parameter. Support for multiple parameters may be added in the future. |
11 | 12 | - **Dynamic Command Execution**: Execute commands in-game directly through the console interface. |
12 | 13 | - **Static and Instance Methods**: Supports executing both static and instance methods. |
13 | | -- **Real-Time Object Discovery**: Automatically detects and interacts with scene objects during gameplay. |
14 | | -- **Supports Parameter Passing**: Command methods can accept parameters, and the console automatically converts inputs to match method signatures. |
15 | | -- **Exception Handling**: Automatically catches and logs exceptions from commands and the console, without crashing or pausing the game. |
16 | | -- **Built-in Commands**: Includes commands like `/Clear` to clear console logs, with additional built-in functionality to interact with the game. |
| 14 | +- **Scene Discovery on Initialization**: O2 Console scans and interacts with objects present at scene load. For objects created during runtime, manual subscription to the console is required. |
| 15 | +- **Supports Parameter Passing**: Command methods can accept one parameter, and the console automatically converts the input to match the method signature. |
| 16 | +- **Exception Handling**: Automatically catches and logs exceptions from commands. |
| 17 | +- **Built-in Commands**: Includes commands like `/Clear` to clear console logs, with additional built-in functionality to interact with the game and the engine. |
| 18 | + |
17 | 19 |
|
18 | 20 | --- |
19 | 21 | ## Ready-to-use user interface |
|
0 commit comments