Skip to main content

ClearDirtySystem.ixx File

System template that clears dirty flags on active dirty-tracker components. More...

Included Headers

Namespaces Index

namespacehelios
namespaceengine
namespacecore
namespacesystems
namespacecomponents

Classes Index

classClearDirtySystem<TMemberHandle, TComponentSpecs>

Generic ECS system that resets dirty state for configured component types. More...

Description

System template that clears dirty flags on active dirty-tracker components.

File Listing

The file content with the documentation metadata removed is:

1
5module;
6
7export module helios.engine.core.systems.ClearDirtySystem;
8
9import helios.engine.runtime.world.tags.SystemRole;
10import helios.engine.runtime.world.UpdateContext;
11
12import helios.ecs.components;
13
14import helios.engine.core.concepts.IsDirtyTrackerLike;
15
16using namespace helios::ecs::components;
18using namespace helios::engine::core::concepts;
21
32 template<typename TMemberHandle, typename ... TComponentSpecs>
35
42 template<typename TComponentSpec>
43 void clearDirtyFor(UpdateContext& updateContext) {
44
45 using Component = typename TComponentSpec::template type<TMemberHandle>;
46
47 for (auto [entity, cmp, active] : updateContext.view<
51 cmp->clearDirty();
52 }
53 }
54
55
56
57 public:
58
63
71 }
72 };
73}

Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.9.8.