Ark Server API (ASA) - Wiki
Loading...
Searching...
No Matches
FTwoVectors Struct Reference

#include <TwoVectors.h>

+ Collaboration diagram for FTwoVectors:

Public Member Functions

FORCEINLINE FTwoVectors ()
 
FORCEINLINE FTwoVectors (FVector In1, FVector In2)
 
FORCEINLINE FTwoVectors (EForceInit)
 
FORCEINLINE FTwoVectors operator+ (const FTwoVectors &V) const
 
FORCEINLINE FTwoVectors operator- (const FTwoVectors &V) const
 
FORCEINLINE FTwoVectors operator* (float Scale) const
 
FTwoVectors operator/ (float Scale) const
 
FORCEINLINE FTwoVectors operator* (const FTwoVectors &V) const
 
FORCEINLINE FTwoVectors operator/ (const FTwoVectors &V) const
 
bool operator== (const FTwoVectors &V) const
 
bool operator!= (const FTwoVectors &V) const
 
bool Equals (const FTwoVectors &V, float Tolerance=UE_KINDA_SMALL_NUMBER) const
 
FORCEINLINE FTwoVectors operator- () const
 
FORCEINLINE FTwoVectors operator+= (const FTwoVectors &V)
 
FORCEINLINE FTwoVectors operator-= (const FTwoVectors &V)
 
FORCEINLINE FTwoVectors operator*= (float Scale)
 
FTwoVectors operator/= (float V)
 
FTwoVectors operator*= (const FTwoVectors &V)
 
FTwoVectors operator/= (const FTwoVectors &V)
 
FVector::FRealoperator[] (int32 i)
 
FVector::FReal GetMax () const
 
FVector::FReal GetMin () const
 
FString ToString () const
 
bool Serialize (FArchive &Ar)
 

Public Attributes

FVector v1
 
FVector v2
 

Friends

FArchiveoperator<< (FArchive &Ar, FTwoVectors &TwoVectors)
 

Detailed Description

A pair of 3D vectors.

Definition at line 14 of file TwoVectors.h.

Constructor & Destructor Documentation

◆ FTwoVectors() [1/3]

FORCEINLINE FTwoVectors::FTwoVectors ( )

Default constructor.

Definition at line 243 of file TwoVectors.h.

◆ FTwoVectors() [2/3]

FORCEINLINE FTwoVectors::FTwoVectors ( FVector In1,
FVector In2 )

Creates and initializes a new instance with the specified vectors.

Parameters
In1The first Vector.
In2The second Vector.

Definition at line 249 of file TwoVectors.h.

◆ FTwoVectors() [3/3]

FORCEINLINE FTwoVectors::FTwoVectors ( EForceInit )
explicit

Constructor.

Parameters
EForceInitForce Init Enum

Definition at line 255 of file TwoVectors.h.

Member Function Documentation

◆ Equals()

FORCEINLINE bool FTwoVectors::Equals ( const FTwoVectors & V,
float Tolerance = UE_KINDA_SMALL_NUMBER ) const

Error-tolerant comparison.

Parameters
VThe other pair.
ToleranceError Tolerance.
Returns
true if two pairs are equal within specified tolerance, false otherwise..

Definition at line 329 of file TwoVectors.h.

◆ GetMax()

FORCEINLINE FVector::FReal FTwoVectors::GetMax ( ) const

Get the maximum value of all the vector coordinates.

Returns
The maximum value of all the vector coordinates.

Definition at line 399 of file TwoVectors.h.

◆ GetMin()

FORCEINLINE FVector::FReal FTwoVectors::GetMin ( ) const

Get the minimum value of all the vector coordinates.

Returns
The minimum value of all the vector coordinates.

Definition at line 408 of file TwoVectors.h.

◆ operator!=()

FORCEINLINE bool FTwoVectors::operator!= ( const FTwoVectors & V) const

Checks two pairs for inequality.

Parameters
VThe other pair.
Returns
true if the two pairs are different, false otherwise..

Definition at line 323 of file TwoVectors.h.

◆ operator*() [1/2]

FORCEINLINE FTwoVectors FTwoVectors::operator* ( const FTwoVectors & V) const

Gets result of multiplying two pairs of vectors.

Parameters
VThe pair to multiply with.
Returns
Result of multiplication.

Definition at line 299 of file TwoVectors.h.

◆ operator*() [2/2]

FORCEINLINE FTwoVectors FTwoVectors::operator* ( float Scale) const

Gets result of scaling pair of vectors.

Parameters
ScaleThe scaling factor.
Returns
Result of Scaling.

Definition at line 279 of file TwoVectors.h.

◆ operator*=() [1/2]

FORCEINLINE FTwoVectors FTwoVectors::operator*= ( const FTwoVectors & V)

Multiply the pair by another.

Parameters
Theother pair.
Returns
Copy of the pair after multiplication.

Definition at line 382 of file TwoVectors.h.

◆ operator*=() [2/2]

FORCEINLINE FTwoVectors FTwoVectors::operator*= ( float Scale)

Scale the pair.

Parameters
ScaleWhat to scale by.
Returns
Copy of the pair after scaling.

Definition at line 362 of file TwoVectors.h.

◆ operator+()

FORCEINLINE FTwoVectors FTwoVectors::operator+ ( const FTwoVectors & V) const

Gets result of addition of two pairs of vectors.

Parameters
VThe pair to add.
Returns
Result of addition.

Definition at line 261 of file TwoVectors.h.

◆ operator+=()

FORCEINLINE FTwoVectors FTwoVectors::operator+= ( const FTwoVectors & V)

Add a pair to this.

Parameters
Thepair to add.
Returns
Copy of the pair after addition.

Definition at line 344 of file TwoVectors.h.

◆ operator-() [1/2]

FORCEINLINE FTwoVectors FTwoVectors::operator- ( ) const

Get a negated copy of the pair.

Returns
A negated copy of the pair.

Definition at line 335 of file TwoVectors.h.

◆ operator-() [2/2]

FORCEINLINE FTwoVectors FTwoVectors::operator- ( const FTwoVectors & V) const

Gets result of subtraction of two pairs of vectors.

Parameters
VThe pair to subtract.
Returns
Result of subtraction.

Definition at line 270 of file TwoVectors.h.

◆ operator-=()

FORCEINLINE FTwoVectors FTwoVectors::operator-= ( const FTwoVectors & V)

Subtract a pair from this.

Parameters
Thepair to subtract.
Returns
Copy of the pair after subtraction.

Definition at line 353 of file TwoVectors.h.

◆ operator/() [1/2]

FORCEINLINE FTwoVectors FTwoVectors::operator/ ( const FTwoVectors & V) const

Gets result of division of two pairs of vectors.

Parameters
VThe pair to divide by.
Returns
Result of division.

Definition at line 308 of file TwoVectors.h.

◆ operator/() [2/2]

FORCEINLINE FTwoVectors FTwoVectors::operator/ ( float Scale) const

Gets result of dividing pair of vectors.

Parameters
ScaleWhat to divide by.
Returns
Result of division.

Definition at line 288 of file TwoVectors.h.

◆ operator/=() [1/2]

FORCEINLINE FTwoVectors FTwoVectors::operator/= ( const FTwoVectors & V)

Divide the pair by another.

Parameters
Theother pair.
Returns
Copy of the pair after multiplication.

Definition at line 390 of file TwoVectors.h.

◆ operator/=() [2/2]

FORCEINLINE FTwoVectors FTwoVectors::operator/= ( float V)

Divide the pair.

Parameters
Whatto divide by.
Returns
Copy of the pair after division.

Definition at line 371 of file TwoVectors.h.

◆ operator==()

FORCEINLINE bool FTwoVectors::operator== ( const FTwoVectors & V) const

Checks two pairs for equality.

Parameters
VThe other pair.
Returns
true if the two pairs are equal, false otherwise..

Definition at line 317 of file TwoVectors.h.

◆ operator[]()

FORCEINLINE FVector::FReal & FTwoVectors::operator[] ( int32 i)

Get a specific component from the pair.

Parameters
iThe index of the component, even indices are for the first vector, odd ones are for the second. Returns index 5 if out of range.
Returns
Reference to the specified component.

Definition at line 417 of file TwoVectors.h.

◆ Serialize()

bool FTwoVectors::Serialize ( FArchive & Ar)
inline

Definition at line 226 of file TwoVectors.h.

◆ ToString()

FORCEINLINE FString FTwoVectors::ToString ( ) const

Get a textual representation of this two-vector.

Returns
A string describing the two-vector.

Definition at line 434 of file TwoVectors.h.

Friends And Related Symbol Documentation

◆ operator<<

FArchive & operator<< ( FArchive & Ar,
FTwoVectors & TwoVectors )
friend

Serializes the two-vector.

Parameters
ArThe archive to serialize into.
TwoVectorsThe two-vector to serialize.
Returns
Reference to the Archive after serialization.

Definition at line 221 of file TwoVectors.h.

Member Data Documentation

◆ v1

FVector FTwoVectors::v1

Holds the first vector.

Definition at line 19 of file TwoVectors.h.

◆ v2

FVector FTwoVectors::v2

Holds the second vector.

Definition at line 22 of file TwoVectors.h.


The documentation for this struct was generated from the following file: