UKismetMathLibrary::FMax
#include "Kismet/KismetMathLibrary.h"
Access: public
Specifiers: staticBlueprintPureUFUNCTION
Description
Returns the larger of two floating-point values. Blueprint equivalent of FMath::Max for floats.
Caveats & Gotchas
- • If either input is NaN the result is implementation-defined — sanitize inputs when operating on values derived from user data or physics simulation.
- • In C++ prefer FMath::Max directly; this wrapper exists to expose the operation as a Blueprint Pure node.
Signature
static UE_INL_API double FMax(double A, double B); Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| A | double | First value. | — |
| B | double | Second value. | — |
Return Type
double Example
Ensure minimum speed C++
float CurrentSpeed = MovementComponent->Velocity.Size();
float EffectiveSpeed = UKismetMathLibrary::FMax(CurrentSpeed, MinSpeed); Tags
Version History
Introduced in: 4.0
| Version | Status | Notes |
|---|---|---|
| 5.6 | stable | — |
Feedback
Was this helpful?