mirror of https://github.com/axmolengine/axmol.git
24 lines
590 B
Markdown
24 lines
590 B
Markdown
|
# Inspector
|
||
|
|
||
|
(Experimental)
|
||
|
|
||
|
- Visualize node tree in real time
|
||
|
- Edit node properties
|
||
|
|
||
|
## Usage
|
||
|
|
||
|
call `openForScene(ax::Scene*)` in your `onEnter` overload and `close` in your `onExit` overload. Dont forget to call Scene methods.
|
||
|
```cpp
|
||
|
#include "Inspector/Inspector.h"
|
||
|
|
||
|
class MyScene : public ax::Scene {
|
||
|
virtual void onEnter() override {
|
||
|
ax::Scene::onEnter();
|
||
|
ax::extension::Inspector::getInstance()->openForScene(this);
|
||
|
}
|
||
|
virtual void onExit() override {
|
||
|
ax::extension::Inspector::getInstance()->close();
|
||
|
ax::Scene::onExit();
|
||
|
}
|
||
|
};
|
||
|
```
|