|
SHVDN
v3
An ASI plugin for Grand Theft Auto V, which allows running scripts written in any .NET language in-game. Developed by crosire https://github.com/crosire/scripthookvdotnet/
|
Public Member Functions | |
| Vector3 (float x, float y, float z) | |
| Initializes a new instance of the Vector3 class. More... | |
| float | Length () |
| Calculates the length of the vector. More... | |
| float | LengthSquared () |
| Calculates the squared length of the vector. More... | |
| void | Normalize () |
| Converts the vector into a unit vector. More... | |
| float | DistanceTo (Vector3 position) |
| Calculates the distance between two vectors. More... | |
| float | DistanceToSquared (Vector3 position) |
| Calculates the squared distance between two vectors. More... | |
| float | DistanceTo2D (Vector3 position) |
| Calculates the distance between two vectors, ignoring the Z-component. More... | |
| float | DistanceToSquared2D (Vector3 position) |
| Calculates the squared distance between two vectors, ignoring the Z-component. More... | |
| float | ToHeading () |
| Converts a vector to a heading. More... | |
| Vector3 | Around (float distance) |
| Creates a random vector inside the circle around this position. More... | |
| Vector3 | Round (int decimalPlaces=2) |
| Rounds each float inside the vector to a select amount of decimal places (2 by default). More... | |
| float[] | ToArray () |
| Converts the matrix to an array of floats. More... | |
| override string | ToString () |
| Converts the value of the object to its equivalent string representation. More... | |
| string | ToString (string format) |
| Converts the value of the object to its equivalent string representation. More... | |
| override int | GetHashCode () |
| Returns the hash code for this instance. More... | |
| override bool | Equals (object obj) |
| Returns a value that indicates whether the current instance is equal to a specified object. More... | |
| bool | Equals (Vector3 other) |
| Returns a value that indicates whether the current instance is equal to the specified object. More... | |
Static Public Member Functions | |
| static float | Distance (Vector3 position1, Vector3 position2) |
| Calculates the distance between two vectors. More... | |
| static float | DistanceSquared (Vector3 position1, Vector3 position2) |
| Calculates the squared distance between two vectors. More... | |
| static float | Distance2D (Vector3 position1, Vector3 position2) |
| Calculates the distance between two vectors, ignoring the Z-component. More... | |
| static float | DistanceSquared2D (Vector3 position1, Vector3 position2) |
| Calculates the squared distance between two vectors, ignoring the Z-component. More... | |
| static float | Angle (Vector3 from, Vector3 to) |
| Returns the angle in degrees between from and to. The angle returned is always the acute angle between the two vectors. More... | |
| static float | SignedAngle (Vector3 from, Vector3 to, Vector3 planeNormal) |
| Returns the signed angle in degrees between from and to. More... | |
| static Vector3 | RandomXY () |
| Returns a new normalized vector with random X and Y components. More... | |
| static Vector3 | RandomXYZ () |
| Returns a new normalized vector with random X, Y and Z components. More... | |
| static Vector3 | Add (Vector3 left, Vector3 right) |
| Adds two vectors. More... | |
| static Vector3 | Subtract (Vector3 left, Vector3 right) |
| Subtracts two vectors. More... | |
| static Vector3 | Multiply (Vector3 value, float scale) |
| Scales a vector by the given value. More... | |
| static Vector3 | Multiply (Vector3 left, Vector3 right) |
| Multiply a vector with another by performing component-wise multiplication. More... | |
| static Vector3 | Divide (Vector3 value, float scale) |
| Scales a vector by the given value. More... | |
| static Vector3 | Negate (Vector3 value) |
| Reverses the direction of a given vector. More... | |
| static Vector3 | Clamp (Vector3 value, Vector3 min, Vector3 max) |
| Restricts a value to be within a specified range. More... | |
| static Vector3 | Lerp (Vector3 start, Vector3 end, float amount) |
| Performs a linear interpolation between two vectors. More... | |
| static Vector3 | Normalize (Vector3 vector) |
| Converts the vector into a unit vector. More... | |
| static float | Dot (Vector3 left, Vector3 right) |
| Calculates the dot product of two vectors. More... | |
| static Vector3 | Cross (Vector3 left, Vector3 right) |
| Calculates the cross product of two vectors. More... | |
| static Vector3 | Project (Vector3 vector, Vector3 onNormal) |
| Projects a vector onto another vector. More... | |
| static Vector3 | ProjectOnPlane (Vector3 vector, Vector3 planeNormal) |
| Projects a vector onto a plane defined by a normal orthogonal to the plane. More... | |
| static Vector3 | Reflect (Vector3 vector, Vector3 normal) |
| Returns the reflection of a vector off a surface that has the specified normal. More... | |
| static Vector3 | Minimize (Vector3 left, Vector3 right) |
| Returns a vector containing the smallest components of the specified vectors. More... | |
| static Vector3 | Maximize (Vector3 left, Vector3 right) |
| Returns a vector containing the largest components of the specified vectors. More... | |
| static Vector3 | operator+ (Vector3 left, Vector3 right) |
| Adds two vectors. More... | |
| static Vector3 | operator- (Vector3 left, Vector3 right) |
| Subtracts two vectors. More... | |
| static Vector3 | operator- (Vector3 vector) |
| Reverses the direction of a given vector. More... | |
| static Vector3 | operator* (Vector3 vector, float scale) |
| Scales a vector by the given value. More... | |
| static Vector3 | operator* (float scale, Vector3 vector) |
| Scales a vector by the given value. More... | |
| static Vector3 | operator/ (Vector3 vector, float scale) |
| Scales a vector by the given value. More... | |
| static bool | operator== (Vector3 left, Vector3 right) |
| Tests for equality between two objects. More... | |
| static bool | operator!= (Vector3 left, Vector3 right) |
| Tests for inequality between two objects. More... | |
| static implicit | operator Vector2 (Vector3 vector) |
| Converts a Vector3 to a Vector2 implicitly. More... | |
Public Attributes | |
| float | X |
| Gets or sets the X component of the vector. More... | |
| float | Y |
| Gets or sets the Y component of the vector. More... | |
| float | Z |
| Gets or sets the Z component of the vector. More... | |
| float | _padding |
| Vector3 | Normalized => Normalize(new Vector3(X, Y, Z)) |
| Returns this vector with a magnitude of 1. More... | |
Static Public Attributes | |
| static Vector3 | Zero => new Vector3(0.0f, 0.0f, 0.0f) |
| Returns a null vector. (0,0,0) More... | |
| static Vector3 | UnitX => new Vector3(1.0f, 0.0f, 0.0f) |
| The X unit Vector3 (1, 0, 0). More... | |
| static Vector3 | UnitY => new Vector3(0.0f, 1.0f, 0.0f) |
| The Y unit Vector3 (0, 1, 0). More... | |
| static Vector3 | UnitZ => new Vector3(0.0f, 0.0f, 1.0f) |
| The Z unit Vector3 (0, 0, 1). More... | |
| static Vector3 | WorldUp => new Vector3(0.0f, 0.0f, 1.0f) |
| Returns the world Up vector. (0,0,1) More... | |
| static Vector3 | WorldDown => new Vector3(0.0f, 0.0f, -1.0f) |
| Returns the world Down vector. (0,0,-1) More... | |
| static Vector3 | WorldNorth => new Vector3(0.0f, 1.0f, 0.0f) |
| Returns the world North vector. (0,1,0) More... | |
| static Vector3 | WorldSouth => new Vector3(0.0f, -1.0f, 0.0f) |
| Returns the world South vector. (0,-1,0) More... | |
| static Vector3 | WorldEast => new Vector3(1.0f, 0.0f, 0.0f) |
| Returns the world East vector. (1,0,0) More... | |
| static Vector3 | WorldWest => new Vector3(-1.0f, 0.0f, 0.0f) |
| Returns the world West vector. (-1,0,0) More... | |
| static Vector3 | RelativeRight => new Vector3(1.0f, 0.0f, 0.0f) |
| Returns the relative Right vector. (1,0,0) More... | |
| static Vector3 | RelativeLeft => new Vector3(-1.0f, 0.0f, 0.0f) |
| Returns the relative Left vector. (-1,0,0) More... | |
| static Vector3 | RelativeFront => new Vector3(0.0f, 1.0f, 0.0f) |
| Returns the relative Front vector. (0,1,0) More... | |
| static Vector3 | RelativeBack => new Vector3(0.0f, -1.0f, 0.0f) |
| Returns the relative Back vector. (0,-1,0) More... | |
| static Vector3 | RelativeTop => new Vector3(0.0f, 0.0f, 1.0f) |
| Returns the relative Top vector. (0,0,1) More... | |
| static Vector3 | RelativeBottom => new Vector3(0.0f, 0.0f, -1.0f) |
| Returns the relative Bottom vector as used. (0,0,-1) More... | |
Properties | |
| float | this[int index] [get, set] |
| Gets or sets the component at the specified index. More... | |
| GTA.Math.Vector3.Vector3 | ( | float | x, |
| float | y, | ||
| float | z | ||
| ) |
Initializes a new instance of the Vector3 class.
| x | Initial value for the X component of the vector. |
| y | Initial value for the Y component of the vector. |
| z | Initial value for the Z component of the vector. |
Adds two vectors.
| left | The first vector to add. |
| right | The second vector to add. |
Returns the angle in degrees between from and to. The angle returned is always the acute angle between the two vectors.
| Vector3 GTA.Math.Vector3.Around | ( | float | distance | ) |
Creates a random vector inside the circle around this position.
Restricts a value to be within a specified range.
| value | The value to clamp. |
| min | The minimum value. |
| max | The maximum value. |
Calculates the cross product of two vectors.
| left | First source vector. |
| right | Second source vector. |
Calculates the distance between two vectors.
| position1 | The first vector to calculate the distance to the second vector. |
| position2 | The second vector to calculate the distance to the first vector. |
Calculates the distance between two vectors, ignoring the Z-component.
| position1 | The first vector to calculate the distance to the second vector. |
| position2 | The second vector to calculate the distance to the first vector. |
Calculates the squared distance between two vectors.
| position1 | The first vector to calculate the squared distance to the second vector. |
| position2 | The second vector to calculate the squared distance to the first vector. |
Calculates the squared distance between two vectors, ignoring the Z-component.
| position1 | The first vector to calculate the squared distance to the second vector. |
| position2 | The second vector to calculate the squared distance to the first vector. |
| float GTA.Math.Vector3.DistanceTo | ( | Vector3 | position | ) |
Calculates the distance between two vectors.
| position | The second vector to calculate the distance to. |
| float GTA.Math.Vector3.DistanceTo2D | ( | Vector3 | position | ) |
Calculates the distance between two vectors, ignoring the Z-component.
| position | The second vector to calculate the distance to. |
| float GTA.Math.Vector3.DistanceToSquared | ( | Vector3 | position | ) |
Calculates the squared distance between two vectors.
| position | The second vector to calculate the distance to. |
| float GTA.Math.Vector3.DistanceToSquared2D | ( | Vector3 | position | ) |
Calculates the squared distance between two vectors, ignoring the Z-component.
| position | The second vector to calculate the squared distance to. |
Scales a vector by the given value.
| value | The vector to scale. |
| scale | The amount by which to scale the vector. |
Calculates the dot product of two vectors.
| left | First source vector. |
| right | Second source vector. |
| override bool GTA.Math.Vector3.Equals | ( | object | obj | ) |
Returns a value that indicates whether the current instance is equal to a specified object.
| obj | Object to make the comparison with. |
true if the current instance is equal to the specified object; false otherwise.| bool GTA.Math.Vector3.Equals | ( | Vector3 | other | ) |
Returns a value that indicates whether the current instance is equal to the specified object.
| other | Object to make the comparison with. |
true if the current instance is equal to the specified object; false otherwise.| override int GTA.Math.Vector3.GetHashCode | ( | ) |
Returns the hash code for this instance.
| float GTA.Math.Vector3.Length | ( | ) |
Calculates the length of the vector.
| float GTA.Math.Vector3.LengthSquared | ( | ) |
Calculates the squared length of the vector.
Performs a linear interpolation between two vectors.
| start | Start vector. |
| end | End vector. |
| amount | Value between 0 and 1 indicating the weight of end . |
This method performs the linear interpolation based on the following formula.
Passing amount a value of 0 will cause start to be returned; a value of 1 will cause end to be returned.
Returns a vector containing the largest components of the specified vectors.
| left | The first source vector. |
| right | The second source vector. |
Returns a vector containing the smallest components of the specified vectors.
| left | The first source vector. |
| right | The second source vector. |
Multiply a vector with another by performing component-wise multiplication.
| left | The first vector to multiply. |
| right | The second vector to multiply. |
Scales a vector by the given value.
| value | The vector to scale. |
| scale | The amount by which to scale the vector. |
Reverses the direction of a given vector.
| value | The vector to negate. |
| void GTA.Math.Vector3.Normalize | ( | ) |
Converts the vector into a unit vector.
Converts the vector into a unit vector.
| vector | The vector to normalize. |
Tests for inequality between two objects.
| left | The first value to compare. |
| right | The second value to compare. |
true if left has a different value than right ; otherwise, false.Scales a vector by the given value.
| vector | The vector to scale. |
| scale | The amount by which to scale the vector. |
Scales a vector by the given value.
| vector | The vector to scale. |
| scale | The amount by which to scale the vector. |
Adds two vectors.
| left | The first vector to add. |
| right | The second vector to add. |
Subtracts two vectors.
| left | The first vector to subtract. |
| right | The second vector to subtract. |
Reverses the direction of a given vector.
| vector | The vector to negate. |
Scales a vector by the given value.
| vector | The vector to scale. |
| scale | The amount by which to scale the vector. |
Tests for equality between two objects.
| left | The first value to compare. |
| right | The second value to compare. |
true if left has the same value as right ; otherwise, false.Projects a vector onto another vector.
| vector | The vector to project. |
| onNormal | Vector to project onto, does not assume it is normalized. |
Projects a vector onto a plane defined by a normal orthogonal to the plane.
| vector | The vector to project. |
| planeNormal | Normal of the plane, does not assume it is normalized. |
|
static |
Returns a new normalized vector with random X and Y components.
|
static |
Returns a new normalized vector with random X, Y and Z components.
Returns the reflection of a vector off a surface that has the specified normal.
| vector | The vector to project onto the plane. |
| normal | Normal of the surface. |
Reflect only gives the direction of a reflection off a surface, it does not determine whether the original vector was close enough to the surface to hit it.
| Vector3 GTA.Math.Vector3.Round | ( | int | decimalPlaces = 2 | ) |
Rounds each float inside the vector to a select amount of decimal places (2 by default).
| decimalPlaces | Number of decimal places to round to |
Returns the signed angle in degrees between from and to.
Subtracts two vectors.
| left | The first vector to subtract. |
| right | The second vector to subtract. |
| float [] GTA.Math.Vector3.ToArray | ( | ) |
Converts the matrix to an array of floats.
| float GTA.Math.Vector3.ToHeading | ( | ) |
Converts a vector to a heading.
| override string GTA.Math.Vector3.ToString | ( | ) |
Converts the value of the object to its equivalent string representation.
| string GTA.Math.Vector3.ToString | ( | string | format | ) |
Converts the value of the object to its equivalent string representation.
| format | The number format. |
| float GTA.Math.Vector3._padding |
Returns this vector with a magnitude of 1.
Returns the relative Back vector. (0,-1,0)
Returns the relative Bottom vector as used. (0,0,-1)
Returns the relative Front vector. (0,1,0)
Returns the relative Left vector. (-1,0,0)
Returns the relative Right vector. (1,0,0)
Returns the relative Top vector. (0,0,1)
The X unit Vector3 (1, 0, 0).
The Y unit Vector3 (0, 1, 0).
The Z unit Vector3 (0, 0, 1).
Returns the world Down vector. (0,0,-1)
Returns the world East vector. (1,0,0)
Returns the world North vector. (0,1,0)
Returns the world South vector. (0,-1,0)
Returns the world Up vector. (0,0,1)
Returns the world West vector. (-1,0,0)
| float GTA.Math.Vector3.X |
Gets or sets the X component of the vector.
The X component of the vector.
| float GTA.Math.Vector3.Y |
Gets or sets the Y component of the vector.
The Y component of the vector.
| float GTA.Math.Vector3.Z |
Gets or sets the Z component of the vector.
The Z component of the vector.
Returns a null vector. (0,0,0)
|
getset |
Gets or sets the component at the specified index.
The value of the X, Y or Z component, depending on the index.
| index | The index of the component to access. Use 0 for the X component, 1 for the Y component and 2 for the Z component. |
| System.ArgumentOutOfRangeException | Thrown when the index is out of the range [0, 2]. |