Point2
Struct in Nostalgia / Inherits from: System.ValueType
Implements interfaces: System.IEquatable<Point2>
Obsolete : use UnityEngine.Vector2Int
Description
Classes for handling two-dimensional integer coordinates.
Constructors
Description | |
---|---|
Point2 | Initializes a new instance of the Point2 class. |
Fields
Field Name | Description |
---|---|
x | The x coordinate. |
y | The y coordinate. |
Properties
Property Name | Description |
---|---|
magnitude | Returns the length of this Point2. |
sqrMagnitude | Returns the squared length of this Point2. |
Methods
Method Name | Description |
---|---|
Equals | Determine if the Point2s are equal. |
GetHashCode | Get the hash code. |
IsInsideRect | It is inside a rectangle |
ToString | Convert to a string. |
Static Fields
Field Name | Description |
---|---|
zero | Get Point2 of (0,0). |
Operators
Operator Name | Description |
---|---|
operator - | Subtraction of Point2 each other. |
operator - | Inversion of the sign. |
operator != | Returns true if Point2s different. |
operator * | Multiplication of Point2. |
operator / | Division of Point2. |
operator + | Addition of Point2 each other. |
operator == | Returns true if the Point2s are equal. |
Point2 | Performs an implicit conversion from Vector2 to Point2. |
Vector2 | Performs an implicit conversion from Point2 to Vector2. |
Vector2Int | Performs an implicit conversion from Point2 to Vector2Int. |