Phaser API Documentation

  Version: 

Member of: Phaser.Math.Vector3

fromArray(array, [offset])

Description:

Sets the components of this Vector3 from the given array, based on the offset.

Vector3.x = array[offset] Vector3.y = array[offset + 1] Vector3.z = array[offset + 2]

Parameters:

name type arguments description
array Array.<number>

The array of values to get this Vector from.

offset number <optional>

The offset index into the array.

Returns:
Description:

This Vector3.

Since: 3.50.0
Source: src/math/Vector3.js (Line 291)