diff options
Diffstat (limited to 'src/components/prototypable.h')
| -rw-r--r-- | src/components/prototypable.h | 23 |
1 files changed, 23 insertions, 0 deletions
| diff --git a/src/components/prototypable.h b/src/components/prototypable.h new file mode 100644 index 0000000..c0dd972 --- /dev/null +++ b/src/components/prototypable.h | |||
| @@ -0,0 +1,23 @@ | |||
| 1 | #ifndef PROTOTYPABLE_H_817F2205 | ||
| 2 | #define PROTOTYPABLE_H_817F2205 | ||
| 3 | |||
| 4 | #include "component.h" | ||
| 5 | #include "entity_manager.h" | ||
| 6 | |||
| 7 | class PrototypableComponent : public Component { | ||
| 8 | public: | ||
| 9 | |||
| 10 | using id_type = EntityManager::id_type; | ||
| 11 | |||
| 12 | /** | ||
| 13 | * The index of the object in the map definition. | ||
| 14 | */ | ||
| 15 | size_t mapObjectIndex; | ||
| 16 | |||
| 17 | /** | ||
| 18 | * The name of the prototype that the object was spawned from. | ||
| 19 | */ | ||
| 20 | std::string prototypeId; | ||
| 21 | }; | ||
| 22 | |||
| 23 | #endif /* end of include guard: PROTOTYPABLE_H_817F2205 */ | ||
