UKismetMathLibrary::Not_PreBool
#include "Kismet/KismetMathLibrary.h"
Access: public
Specifiers: staticBlueprintPure
Description
Returns the logical NOT of a boolean value (true becomes false, false becomes true). In Blueprints this appears as the 'NOT Boolean' node with the compact title 'NOT'.
Caveats & Gotchas
- • In C++ the built-in '!' operator is simpler and more idiomatic than calling this function directly — this exists primarily to expose the NOT operation as a first-class Blueprint node.
- • The function is inlined in non-debug builds (UE_INL_API), so there is no call overhead in shipping code.
Signature
static UE_INL_API bool Not_PreBool(bool A); Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| A | bool | The boolean value to negate. | — |
Return Type
bool Example
Toggle a flag using NOT C++
bool bIsActive = true;
bool bIsInactive = UKismetMathLibrary::Not_PreBool(bIsActive); // false Tags
Version History
Introduced in: 4.0
| Version | Status | Notes |
|---|---|---|
| 5.6 | stable | — |
Feedback
Was this helpful?