Scans the array for elements with the given property. If found, the property is set to the value
.
For example: SetAll('visible', true)
would set all elements that have a visible
property to false
.
Optionally you can specify a start and end index. For example if the array had 100 elements,
and you set startIndex
to 0 and endIndex
to 50, it would update only the first 50 elements.
name | type | arguments | description |
---|---|---|---|
array | array |
The array to search. |
|
property | string |
The property to test for on each array element. |
|
value | * |
The value to set the property to. |
|
startIndex | number | <optional> |
An optional start index to search from. |
endIndex | number | <optional> |
An optional end index to search to. |
The input array.