Triggered when the user selects or deselects objects... |
function eventSelectionChanged(selected) { // do stuff } |
Parameter | Type | Mandatory | Description | Game version |
---|---|---|---|---|
selected | Array of | An array of selected game objects. Array will be empty if no objects are selected. | 3.2 |
Warzone does not process the event handler's return value.
The event is triggered after each selection change, but with a slight delay to avoid being triggered too many times.
Remember that a player might select objects one at a time, or in groups, or hold down shift to add or remove objects to or from the selection.
function eventSelectionChanged(selectedObjects) { selectedObjects.forEach(function get(gameObject) { // do stuff with selected game object } } |
AvailabilityRequires:
|
ContentsJump to: |
See alsoRelated articles:
|