Supported Parameter Types/Component
From ReflexCLI
(Redirected from Supported Parameter Types/MonoBehaviour)
Contents
GameObjects and Components
Unity Engine GameObject
and all Component
types can be used as parameters for console commands. This includes Transform
and MonoBehaviour
types, so any of your scripts derived from Monobehaviours can be used in the console.
Referencing objects in the scene
The console takes a GameObject name as the identifier for the object and then attempts to find a matching object in the scene.
- As spaces are used to separate parameters in the console, GameObject names that contain spaces are replaced with underscores.
- By default both active and inactive GameObjects will be addressable. The behaviour can be changed globally in Settings.
Limitations
As of version 1.1.0, the console cannot handle
- Multiple GameObjects with the same name.
- GameObjects that have multiple of the same components on them (as they have the same name).
Object Active State
Currently the Console attempts to find all objects of type in all open scenes, regardless of whether they have are active or not. At v1.0.0 this can sometimes give false negatives (if the root game object is disabled, for instance) and may not be desirable. In future releases this behaviour will be refined and configurable in the settings.