Header <InputActionValue.h>

#include "InputActionValue.h"
Module: EnhancedInput Source: Engine/Plugins/EnhancedInput/Source/EnhancedInput/Public/InputActionValue.h

Includes 1

<InputCoreTypes.h>

Contents

FInputActionValue
(ustruct struct)
Functions1 free functions
(namespace scope)

struct FInputActionValue

struct FInputActionValueUSTRUCTBlueprintType

Constructors 1

FInputActionValue
FInputActionValue() = default;
FInputActionValue(FKey KeyDefault) : Value(0.f), ValueType(GetValueTypeFromKey(KeyDefault));
explicit FInputActionValue(bool bInValue) : Value(bInValue ? 1.f : 0.f, 0.f, 0.f), ValueType(EInputActionValueType::Boolean);
FInputActionValue(Axis1D InValue) : Value(InValue, 0.f, 0.f), ValueType(EInputActionValueType::Axis1D);
FInputActionValue(Axis2D InValue) : Value(InValue, 0.f), ValueType(EInputActionValueType::Axis2D);
FInputActionValue(Axis3D InValue) : Value(InValue), ValueType(EInputActionValueType::Axis3D);
FInputActionValue(EInputActionValueType InValueType, Axis3D InValue) : Value(InValue), ValueType(InValueType);
Support all relevant default constructors (FInputActionValue isn't movable)

Member functions 9

Reset
void Reset();
Resets Value without affecting ValueType
Get
template<typename T> inline T Get() const;
TODO: Would prefer a value type checked version here but this is complicated by the ability to change action value types within the editor. TODO: Binding helpers to limit key types that can be bound? Stop players…
operator[]
float operator[](int32 Index) const;
Read only index based value accessor, doesn't care about type. Expect 0 when accessing unused components.
IsNonZero
bool IsNonZero(float Tolerance = KINDA_SMALL_NUMBER) const;
ConvertToType
FInputActionValue& ConvertToType(const FInputActionValue& Other);
In-place type conversion
GetValueType
EInputActionValueType GetValueType() const;
GetMagnitudeSq
float GetMagnitudeSq() const;
GetMagnitude
float GetMagnitude() const;
ToString
FString ToString() const;
Type sensitive debug stringify

Static functions 1

GetValueTypeFromKey
static EInputActionValueType GetValueTypeFromKey(FKey Key);

Functions

Free functions 1

Get
template<> inline bool FInputActionValue::Get() const;
template<> inline FInputActionValue::Axis1D FInputActionValue::Get() const;
template<> inline FInputActionValue::Axis2D FInputActionValue::Get() const;
template<> inline FInputActionValue::Axis3D FInputActionValue::Get() const;
Supported getter specializations