move ecs related code to own folder
This commit is contained in:
@@ -2,7 +2,9 @@
|
||||
|
||||
#include <QVector2D>
|
||||
|
||||
#include "DespawnAtComponent.h"
|
||||
#include "EntityAdmin.h"
|
||||
#include "ScrapDataComponent.h"
|
||||
#include "ScrapSystem.h"
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
@@ -17,8 +19,8 @@ TEST_CASE("ScrapSystem: spawn returns a valid entity with correct scrap data", "
|
||||
const entt::entity e = ss.spawn(QVector2D(3.0f, 4.0f), 5, 100);
|
||||
|
||||
REQUIRE(admin.isValid(e));
|
||||
REQUIRE(admin.get<ScrapData>(e).amount == 5);
|
||||
REQUIRE(admin.get<DespawnAt>(e).tick == 100);
|
||||
REQUIRE(admin.get<ScrapDataComponent>(e).amount == 5);
|
||||
REQUIRE(admin.get<DespawnAtComponent>(e).tick == 100);
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user