Navigation
API > API/Plugins > API/Plugins/WorldConditions
World Condition Query is an expression of World Conditions whose state can be queried. The state of query and individual conditions can be cached, which allows to evaluate the conditions quickly. See FWorldConditionBase for more information about the conditions.
The World Condition Query is split it two parts: FWorldConditionQueryDefinition and FWorldConditionQueryState. Definition is the "const" part of the query and state contain runtime caching and runtime state of the condition. This allows the definition to be stored in an asset, and we can allocate just the per instance data when needed.
Conditions operate on context data which is defined in a UWorldConditionSchema. The schema describes what kind of structs and objects are available as input for the conditions, and what conditions can be used in specific use case.
The state is tightly coupled to the definition. The memory layout of the state is stored in the definition.
For convenience there is also FWorldConditionQuery which combines these two in one package. Struct used to store a world condition in editor or to apply hotfixes. Used internally. Note that the Operator and ExpressionDepth are stored here separately from the World Condition to make sure they are not reset if the Condition is empty.
| Name | FWorldConditionEditable |
| Type | struct |
| Header File | /Engine/Plugins/Runtime/WorldConditions/Source/WorldConditions/Public/WorldConditionQuery.h |
| Include Path | #include "WorldConditionQuery.h" |
Syntax
USTRUCT ()
struct FWorldConditionEditable
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
| WorldConditionQuery.h | |||
FWorldConditionEditable
(
const uint8 InExpressionDepth, |
WorldConditionQuery.h | ||
FWorldConditionEditable
(
const uint8 InExpressionDepth, |
WorldConditionQuery.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bInvert | bool | Controls whether the value of the expressions as calculated by IsTrue should be inverted. | WorldConditionQuery.h |
|
| Condition | FInstancedStruct | Instance of a world condition. | WorldConditionQuery.h |
|
| ExpressionDepth | uint8 | Expression depth controlling the parenthesis of the expression. | WorldConditionQuery.h |
|
| Operator | EWorldConditionOperator | Operator describing how the results of the condition is combined with other conditions. | WorldConditionQuery.h |
|
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void Reset() |
WorldConditionQuery.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
bool operator!=
(
const FWorldConditionEditable& Other |
WorldConditionQuery.h | ||
bool operator==
(
const FWorldConditionEditable& Other |
WorldConditionQuery.h |