Push Focus
Push Focus¶
Moves focus to a specific element inside a user interface.
Properties¶
System¶
| Name | Explanation | Type |
|---|---|---|
| Element | The unique ID of the user interface element to focus on. | Variable or Value |
| Select All | Whether to select all items in the focused element. | Switch or Value |
| Select Random | Whether to randomly select an item in the focused element. | Switch or Value |
Examples¶
Push Focus to a Specific Element¶
This moves focus to the user interface element whose unique ID is stored in Global Variable 0.
{"Data":{"AreAllSelected":{"IsGlobalSwitch":false,"IsLocalSwitch":false,"IsValue":true,"Value":false,"SwitchIndex":0,"Metadata":null},"AreRandomSelected":{"IsGlobalSwitch":false,"IsLocalSwitch":false,"IsValue":true,"Value":false,"SwitchIndex":0,"Metadata":null},"ID":{"IsGlobalVariable":true,"IsLocalVariable":false,"IsValue":false,"Value":"","VariableIndex":0,"Metadata":null},"Metadata":null},"TypeName":"MAR.Game.Shared.Models.Scripts.Commands.UserInterface.PushFocusCommand"}
Push Focus and Select All Items¶
This moves focus to the element whose unique ID is stored in Global Variable 0 and selects all items in that element.
{"Data":{"AreAllSelected":{"IsGlobalSwitch":false,"IsLocalSwitch":false,"IsValue":true,"Value":true,"SwitchIndex":0,"Metadata":null},"AreRandomSelected":{"IsGlobalSwitch":false,"IsLocalSwitch":false,"IsValue":true,"Value":false,"SwitchIndex":0,"Metadata":null},"ID":{"IsGlobalVariable":true,"IsLocalVariable":false,"IsValue":false,"Value":"","VariableIndex":0,"Metadata":null},"Metadata":null},"TypeName":"MAR.Game.Shared.Models.Scripts.Commands.UserInterface.PushFocusCommand"}
Push Focus and Randomly Select an Item¶
This moves focus to the element whose unique ID is stored in Global Variable 0 and randomly selects an item.
{"Data":{"AreAllSelected":{"IsGlobalSwitch":false,"IsLocalSwitch":false,"IsValue":true,"Value":false,"SwitchIndex":0,"Metadata":null},"AreRandomSelected":{"IsGlobalSwitch":false,"IsLocalSwitch":false,"IsValue":true,"Value":true,"SwitchIndex":0,"Metadata":null},"ID":{"IsGlobalVariable":true,"IsLocalVariable":false,"IsValue":false,"Value":"","VariableIndex":0,"Metadata":null},"Metadata":null},"TypeName":"MAR.Game.Shared.Models.Scripts.Commands.UserInterface.PushFocusCommand"}