IUIInterface
Interface for handling user interface related functions
Namespace: VNyanInterface
Events
colorThemeChanged
Triggers when the color theme is changed by the user
Methods
getCurrentThemeColor
Get the color for the specified component in the current VNyan Color Theme
getCurrentThemeColor(ThemeComponent)
| Parameter | Type | Description |
|---|---|---|
| — | ThemeComponent |
Returns: an HTML hex code for the provided ThemeComponent in the currently selected theme
registerPluginButton
Register plugin window button with callback
registerPluginButton(string buttonText, IButtonClickedHandler clickCallback)
| Parameter | Type | Description |
|---|---|---|
buttonText | string | Button text |
clickCallback | IButtonClickedHandler | Callback class |
instantiateUIPrefab
Instantiates prefab to VNyan's UI canvas
instantiateUIPrefab(object gameObject)
| Parameter | Type | Description |
|---|---|---|
gameObject | object | Prefab to instantiate |
Returns: Instantiated GameObject
openSaveFileDialog
Opens a save file dialog
openSaveFileDialog(string header, string[] extensions)
| Parameter | Type | Description |
|---|---|---|
header | string | Dialog header text |
extensions | string[] | File extensions to support (without the dot) |
Returns: Name of the file to save or null if dialog was closed
openLoadFileDialog
Opens a load file dialog
openLoadFileDialog(string header, string[] extensions)
| Parameter | Type | Description |
|---|---|---|
header | string | Dialog header text |
extensions | string[] | File extensions to support (without the dot) |
Returns: Name of the file to load or null if dialog was closed