2023-10-24 15:01:09 +02:00
|
|
|
#pragma once
|
2023-11-22 13:18:54 +01:00
|
|
|
#include "SystemBase.h"
|
2023-10-24 15:01:09 +02:00
|
|
|
#include "Component/Transform.h"
|
|
|
|
|
#include "Component/Mesh.h"
|
|
|
|
|
|
|
|
|
|
namespace Seele
|
|
|
|
|
{
|
|
|
|
|
namespace System
|
|
|
|
|
{
|
2023-11-22 13:18:54 +01:00
|
|
|
class MeshUpdater : public SystemBase
|
2023-10-24 15:01:09 +02:00
|
|
|
{
|
|
|
|
|
public:
|
2023-10-26 18:37:29 +02:00
|
|
|
MeshUpdater(PScene scene);
|
|
|
|
|
virtual ~MeshUpdater();
|
2023-11-22 13:18:54 +01:00
|
|
|
virtual void update() override;
|
2023-10-24 15:01:09 +02:00
|
|
|
private:
|
2023-11-22 13:18:54 +01:00
|
|
|
Array<entt::entity> meshEntities;
|
|
|
|
|
void on_construct(entt::registry& reg, entt::entity id);
|
|
|
|
|
void on_destroy(entt::registry& reg, entt::entity id);
|
2023-10-24 15:01:09 +02:00
|
|
|
};
|
|
|
|
|
} // namespace System
|
|
|
|
|
} // namespace Seele
|