Add Linux support
- Add linux build system using MakeGen - Fix a swapchain validation error, likelydue to my linux system using a different vulkan version - Make DescriptorPool take in amount of descriptors it needs, instead of allocating a mass amount for every pool, causing loads of RAM/VRAM usage
This commit is contained in:
@@ -1,9 +1,11 @@
|
||||
#pragma once
|
||||
|
||||
#include "copium/ecs/ECSManager.h"
|
||||
#include "copium/ecs/Config.h"
|
||||
|
||||
namespace Copium
|
||||
{
|
||||
class ECSManager;
|
||||
|
||||
template <typename Component>
|
||||
class ComponentListener
|
||||
{
|
||||
|
||||
@@ -11,7 +11,6 @@
|
||||
#include <map>
|
||||
#include <typeindex>
|
||||
#include <unordered_set>
|
||||
#include <vector>
|
||||
|
||||
namespace Copium
|
||||
{
|
||||
@@ -36,7 +35,7 @@ namespace Copium
|
||||
template <typename SystemClass>
|
||||
void RemoveSystem()
|
||||
{
|
||||
systemPool->MoveSystemBefore(typeid(SystemClass));
|
||||
systemPool->RemoveSystem(typeid(SystemClass));
|
||||
}
|
||||
|
||||
void UpdateSystems();
|
||||
|
||||
@@ -4,6 +4,8 @@
|
||||
#include "copium/ecs/SystemBase.h"
|
||||
#include "copium/ecs/Entity.h"
|
||||
|
||||
#include <set>
|
||||
|
||||
namespace Copium
|
||||
{
|
||||
template <typename... Components>
|
||||
@@ -26,7 +28,6 @@ namespace Copium
|
||||
|
||||
// TODO: Not sure if this is the way entities should be validated
|
||||
std::set<EntityId> loggedEntities;
|
||||
template <typename... Components>
|
||||
bool ValidateEntity(Entity entity)
|
||||
{
|
||||
if (entity && entity.HasComponents<Components...>())
|
||||
|
||||
@@ -13,6 +13,8 @@ namespace Copium
|
||||
ECSManager* manager;
|
||||
|
||||
public:
|
||||
virtual ~SystemBase() = default;
|
||||
|
||||
virtual void Run() = 0;
|
||||
virtual void Run(const Signal& signal) = 0;
|
||||
};
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
#pragma once
|
||||
|
||||
#include <vector>
|
||||
#include <map>
|
||||
#include <typeindex>
|
||||
|
||||
namespace Copium
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
#include "copium/ecs/SystemPool.h"
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
namespace Copium
|
||||
{
|
||||
SystemPool::SystemPool(ECSManager* manager)
|
||||
|
||||
Reference in New Issue
Block a user