Quaternion.this[int]

Switch to Manual
public float this[int];

Description

Access the x, y, z, w components using [0], [1], [2], [3] respectively.

using UnityEngine;

public class Example : MonoBehaviour { void Start() { Quaternion p = new Quaternion(); p[3] = 0.5f; // the same as p.w = 0.5 } }

Did you find this page useful? Please give it a rating: