🔢Vec2
Last updated
Last updated
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Create a new Vec2.
Vec2
Create a new Vec2(0,0).
string
Overload for operator +
Overload for operator -
Overload for operator /
number
Returns the length of the vector.
number
, number
Returns x, y of this vector.
number
Returns x of this vector. The same as Vec2.x.
number
Returns y of this vector. The same as Vec2.y.
number
): nil
Sets x. The same as Vec2.x = value.
number
): nil
Sets y. The same as Vec2.y = value.
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
x
number
y
number
x
number
y
number
other
Vec2
|number
other
Vec2
|number
other
Vec2
|number
value
number
value
number