Olympe Engine
2.0
2D Game Engine with ECS Architecture
Loading...
Searching...
No Matches
Source
TaskSystem
AtomicTasks
System
Task_GetDeltaTime.h
Go to the documentation of this file.
1
/**
2
* @file Task_GetDeltaTime.h
3
* @brief Atomic task that writes the current delta-time into the LocalBlackboard.
4
* @author Olympe Engine
5
* @date 2026-03-08
6
*
7
* @details
8
* Task_GetDeltaTime captures ctx.DeltaTime and stores it under the key
9
* "local:DeltaTime" in the entity's LocalBlackboard. Useful for tasks that
10
* need to read dt from the blackboard rather than from the context directly.
11
*
12
* No required parameters.
13
*
14
* Returns:
15
* Success always.
16
* Failure if ctx.LocalBB is null.
17
*
18
* C++14 compliant - no C++17/20 features.
19
*/
20
21
#pragma once
22
23
#include "../../IAtomicTask.h"
24
25
namespace
Olympe
{
26
27
/**
28
* @class Task_GetDeltaTime
29
* @brief Writes ctx.DeltaTime to "local:DeltaTime" in the LocalBlackboard.
30
*/
31
class
Task_GetDeltaTime
:
public
IAtomicTask
{
32
public
:
33
Task_GetDeltaTime
();
34
35
TaskStatus
ExecuteWithContext
(
const
AtomicTaskContext
&
ctx
,
36
const
ParameterMap
&
params
)
override
;
37
38
TaskStatus
Execute
(
const
ParameterMap
&
params
)
override
;
39
40
void
Abort
()
override
;
41
};
42
43
}
// 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_GetDeltaTime
Writes ctx.DeltaTime to "local:DeltaTime" in the LocalBlackboard.
Definition
Task_GetDeltaTime.h:31
Olympe::Task_GetDeltaTime::Abort
void Abort() override
Aborts the task, releasing any in-progress state.
Definition
Task_GetDeltaTime.cpp:19
Olympe::Task_GetDeltaTime::Execute
TaskStatus Execute(const ParameterMap ¶ms) override
Executes the atomic task for one frame.
Definition
Task_GetDeltaTime.cpp:24
Olympe::Task_GetDeltaTime::Task_GetDeltaTime
Task_GetDeltaTime()
Definition
Task_GetDeltaTime.cpp:17
Olympe::Task_GetDeltaTime::ExecuteWithContext
TaskStatus ExecuteWithContext(const AtomicTaskContext &ctx, const ParameterMap ¶ms) override
Executes the atomic task for one frame with full runtime context.
Definition
Task_GetDeltaTime.cpp:29
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