RealDocs

UKismetStringLibrary::Conv_StringToVector3f

function Engine Blueprint Since unknown
#include "Kismet/KismetStringLibrary.h"
Access: public Specifiers: staticBlueprintPure

Description

Parses a string in the 'X= Y= Z=' format back into a single-precision FVector3f, reporting whether parsing succeeded via OutIsValid.

Caveats & Gotchas

  • FVector3f is single-precision — this exists for interoperability with float-based APIs (e.g. some physics and rendering code) rather than general Blueprint math, which typically uses the double-precision FVector overload instead.
  • Like Conv_StringToVector, OutIsValid comes from FVector3f::InitFromString and doesn't guarantee OutConvertedVector is zeroed on failure.

Signature

static void Conv_StringToVector3f(const FString& InString, FVector3f& OutConvertedVector, bool& OutIsValid)

Parameters

Name Type Description Default
InString const FString& The string to parse, expected in the 'X= Y= Z=' format.
OutConvertedVector FVector3f& The parsed single-precision vector value; only meaningful when OutIsValid is true.
OutIsValid bool& True if InString was successfully parsed into a vector.

Return Type

void

Example

Parse a float vector for a physics API C++
FString VectorText = TEXT("X=1.000 Y=0.000 Z=0.000");
FVector3f Direction;
bool bIsValid = false;
UKismetStringLibrary::Conv_StringToVector3f(VectorText, Direction, bIsValid);

Version History

Introduced in: unknown

Version Status Notes
5.6 stable

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.