Olympe Engine
2.0
2D Game Engine with ECS Architecture
Loading...
Searching...
No Matches
Source
TaskSystem
AtomicTasks
Blackboard
Task_Compare.h
Go to the documentation of this file.
1
/**
2
* @file Task_Compare.h
3
* @brief Atomic task that compares two values and returns Success or Failure.
4
* @author Olympe Engine
5
* @date 2026-02-23
6
*
7
* @details
8
* Task_Compare evaluates a comparison between "LHS" and "RHS" parameters
9
* using the "Operator" parameter and returns Success if the comparison is
10
* true, Failure otherwise.
11
*
12
* Parameters (ParameterMap):
13
* "LHS" (Int|Float|String) - left-hand side value (required)
14
* "RHS" (Int|Float|String) - right-hand side value (required, same type)
15
* "Operator" (String) - one of: "==", "!=", "<", ">", "<=", ">="
16
* (required; "<","<=",">",">=" numeric only)
17
*
18
* Returns:
19
* Success if the comparison is true.
20
* Failure if the comparison is false, or if parameters are invalid.
21
*
22
* C++14 compliant - no C++17/20 features.
23
*/
24
25
#pragma once
26
27
#include "../../IAtomicTask.h"
28
29
namespace
Olympe
{
30
31
/**
32
* @class Task_Compare
33
* @brief Atomic task that returns Success if a comparison holds, Failure otherwise.
34
*/
35
class
Task_Compare
:
public
IAtomicTask
{
36
public
:
37
Task_Compare
();
38
39
TaskStatus
ExecuteWithContext
(
const
AtomicTaskContext
&
ctx
,
40
const
ParameterMap
&
params
)
override
;
41
42
TaskStatus
Execute
(
const
ParameterMap
&
params
)
override
;
43
44
void
Abort
()
override
;
45
};
46
47
}
// namespace Olympe
GetComponentTypeID_Static
ComponentTypeID GetComponentTypeID_Static()
Definition
ECS_Entity.h:56
Olympe::IAtomicTask
Abstract interface for a single atomic unit of work.
Definition
IAtomicTask.h:63
Olympe::IAtomicTask::ParameterMap
std::unordered_map< std::string, TaskValue > ParameterMap
Convenience alias for the parameter map passed to Execute().
Definition
IAtomicTask.h:67
Olympe::Task_Compare
Atomic task that returns Success if a comparison holds, Failure otherwise.
Definition
Task_Compare.h:35
Olympe::Task_Compare::Task_Compare
Task_Compare()
Definition
Task_Compare.cpp:19
Olympe::Task_Compare::Execute
TaskStatus Execute(const ParameterMap ¶ms) override
Executes the atomic task for one frame.
Definition
Task_Compare.cpp:26
Olympe::Task_Compare::Abort
void Abort() override
Aborts the task, releasing any in-progress state.
Definition
Task_Compare.cpp:21
Olympe::Task_Compare::ExecuteWithContext
TaskStatus ExecuteWithContext(const AtomicTaskContext &ctx, const ParameterMap ¶ms) override
Executes the atomic task for one frame with full runtime context.
Definition
Task_Compare.cpp:33
Olympe
< Provides AssetID and INVALID_ASSET_ID
Definition
BTEditorCommand.cpp:16
Olympe::TaskStatus
TaskStatus
Result code returned by IAtomicTask::Execute().
Definition
IAtomicTask.h:38
Olympe::AtomicTaskContext
Lightweight context bundle passed to IAtomicTask::ExecuteWithContext().
Definition
AtomicTaskContext.h:36
Generated on Mon Apr 13 2026 08:15:20 for Olympe Engine by
1.9.8