Equals
Compares two vectors to each other and evaluates if they are equal.
Read time 1 minuteLast updated 4 days ago
Definition
- Type: Method
- Namespace: UnityEngine
- Assembly: UnityEngine.CoreModule
Equals(Object)
Compares two vectors to each other and evaluates if they are equal.
public override readonly bool Equals(object other)
Parameters
The object to compare against this vector.
Returns
Type | Description |
|---|---|
| bool | |
Remarks
Due to floating point inaccuracies, this might return false for vectors which are essentially (but not exactly) equal. Use the == operator to test two vectors for approximate equality.
Equals(Vector4)
Compares two vectors to each other and evaluates if they are equal.
public readonly bool Equals(Vector4 other)
Parameters
The vector to compare against this vector.
Returns
Type | Description |
|---|---|
| bool | |
Remarks
Due to floating point inaccuracies, this might return false for vectors which are essentially (but not exactly) equal. Use the == operator to test two vectors for approximate equality.
Equals(Vector4)
Compares two vectors to each other and evaluates if they are equal.
public readonly bool Equals(in Vector4 other)
Parameters
The vector to compare against this vector.
Returns
Type | Description |
|---|---|
| bool | |
Remarks
Due to floating point inaccuracies, this might return false for vectors which are essentially (but not exactly) equal. Use the == operator to test two vectors for approximate equality.