9d5a5314a7
- Add queue systems when adding/removing components and systems - Add GlobalData to ECSManager, used to store data that is not specific to entities - Add View class, used to for loop all entities that contains the given Components - Rework how signaling works
25 lines
458 B
C++
25 lines
458 B
C++
#pragma once
|
|
|
|
#include <vector>
|
|
|
|
#include "copium/ecs/Config.h"
|
|
#include "copium/ecs/EntitySet.h"
|
|
|
|
namespace Copium
|
|
{
|
|
class ComponentPoolBase
|
|
{
|
|
protected:
|
|
EntitySet entities;
|
|
|
|
public:
|
|
virtual ~ComponentPoolBase() = default;
|
|
|
|
virtual size_t Size() = 0;
|
|
virtual bool Erase(EntityId entity) = 0;
|
|
virtual void CommitUpdates() = 0;
|
|
std::vector<EntityId>& GetEntities();
|
|
const std::vector<EntityId>& GetEntities() const;
|
|
};
|
|
}
|