Designer Plugins
Plugins for Disguise Designer software.
Plugins for Disguise Designer software.
A two-dimensional vector with x and y components.
Category: Utility
Base class: _BlipValue
Maximum component of the vector.
The minimum component of the vector.
The x component of the vector.
UserName: X
The y component of the vector.
UserName: Y
Copy constructor for Vec2
A serialisable tuple of the Int2 parameters
The absolute value of the vector.
Returns A new vector containing the component-wise absolute value of this vector.
The angle of the vector, measured counter-clockwise from the positive x-axis.
Returns The angle of the vector in normalised coordinates.
The aspect ratio of the vector, defined as the ratio of the x component to the y component.
Returns The aspect ratio of the vector.
The dot product of two vectors.
Parameters:
Returns The dot product of this vector and the other vector.
The length of the vector in 2D space.
Returns The length of the vector.
Normalises the vector to have a length of 1.
Returns The normalised vector.
Restricts the vector to be within a minimum and maximum range.
Parameters:
Returns A new vector with components restricted to the minimum and maximum range.
Rotates the vector by a degrees anticlockwise.
Parameters:
Returns A new vector rotated by the specified angle.
Rounds the components of this vector down to the nearest integer multiple of a given factor.
Parameters:
Returns A new vector with rounded components.
Component-wise maximum of two vectors.
Parameters:
Returns A new vector containing the component-wise maximum of this and the other vector.
Component-wise minimum of two vectors.
Parameters:
Returns A new vector containing the component-wise minimum of this and the other vector.
Adds two vectors.
Parameters:
Returns The component-wise sum of this and the input vector.
Divides the vector by a scalar value.
Parameters:
Returns A new vector that is the result of dividing the components of this vector by the given scalar value.
Tests for equality between two vectors.
Parameters:
Returns True if both components of the vectors are equal, false otherwise.
Get an item from the Vec2 by index.
Parameters:
Returns The x element if the index is 0, the y element if the index is 1
The length of the Vec2
Returns Always returns 2
Multiplies the vector by a scalar value.
Parameters:
Returns A new vector that is the result of multiplying the components of this vector by the given scalar value.
Tests for inequality between two vectors.
Parameters:
Returns True if either of the components of the vectors are not equal, false otherwise.
The negative of the Vec2
Returns The Vec2 with its x and y components negated
Divide another vector by this vector
Parameters:
Returns The element-wise division other/self
String representation of the Vec2
Multiplies the vector by a scalar value.
Parameters:
Returns A new vector that is the result of multiplying the components of this vector by the given scalar value.
String representation of the Vec2
Subtracts another vector from this vector.
Parameters:
Returns The resulting vector after component-wise subtraction.