Cogs.Core
LocationComponent.h
1#pragma once
2
3#include "Components/Core/DynamicComponent.h"
4
5#include "Resources/Resources.h"
6
7namespace Cogs
8{
9 namespace Core
10 {
11 namespace EchoSounder
12 {
13 struct DataSetSystem;
14
16 {
17 static void registerType();
18
19 void initialize(Context * context);
20
21 void update();
22
23 int64_t time = 0;
24 bool updateTransform = true; // Should component manipulate transform, or only find index?
25
26 int index = 0; // Maintained by this component.
27
28 private:
29 Context* context = nullptr;
30 DataSetSystem* dataSystem = nullptr;
31 uint32_t configGen = 0;
32 uint32_t dataGen = 0;
33 };
34
35 }
36 }
37}
38
39template<> inline Cogs::StringView getName<Cogs::Core::EchoSounder::LocationComponent>() { return "EchoLocationComponent"; }
A Context instance contains all the services, systems and runtime components needed to use Cogs.
Definition: Context.h:83
Base class for components implementing dynamic behavior.
Provides a weakly referenced view over the contents of a string.
Definition: StringView.h:24
Contains all Cogs related functionality.
Definition: FieldSetter.h:23