| Inspector fields |
| document | An imported .envy.json or .envy (an EnvyDocument asset). Reloads while the game runs in the editor |
| documentJson · documentPath | Or a TextAsset, or a file path (absolute, or under StreamingAssets) |
| startScreen | Screen to show first. Defaults to the first screen |
| scaleMode | Fit scales the design resolution into the panel and stretches to its aspect |
| autoplay · useSampleData | Play autoplay animations; start with the document's sample data |
| hotReload | Reload the document when Envy saves over it, in the editor |
| locale | Locale for translated text, like "de", or "pseudo" |
| cancelClosesOverlay | Cancel (Esc, gamepad B) closes the top overlay |
| fonts | Family and weight to a font asset or a TTF/OTF Font, for fonts the document does not embed |
| panelSettings · sortingOrder | The panel EnvyUI draws in; empty draws 1:1 over the scene |
| Methods |
| Goto(screen, transition) | Show a screen by name or id |
| Push(screen, transition) · Pop() · Cancel() | Open a screen over the current one, close the top one |
| GetStack() · GetScreenNames() | The open screens, every screen |
| SetData(path, value) | Set one data path, for example "player.hp" |
| MergeData(patch) · GetData(path) | Deep-merge a dictionary, read a value |
| Play(anim) · Stop(anim) · IsPlaying(anim) | Run the document's animations |
| SetLocale(locale) · GetLocales() | Switch language at runtime |
| GetElement(nameOrId) | The VisualElement built for a layer |
| FocusFirstButton() · Press(button) | Start keyboard and gamepad navigation; press a button from code |
| LoadDocument(asset) · LoadFile(path) · LoadJson(text) | Load another document |
| Events |
| UiEvent(evt, payload) · onUiEvent | A button emitted an event (a C# event, and a UnityEvent for the Inspector) |
| ScreenChanged(name) · onScreenChanged | Goto, Push or Pop ran |
| DataChanged(data) | A button set or toggled data |
| DocumentReloaded | The document changed on disk and was reloaded |