first pr fixes from reviews

This commit is contained in:
Clément Le Bihan
2021-06-02 18:14:44 +02:00
parent e45942d532
commit 3790b2a8cd
6 changed files with 20 additions and 16 deletions
+5 -5
View File
@@ -60,8 +60,8 @@ namespace BBM
RAY::Window &window = RAY::Window::getInstance(600, 400, "Bomberman", FLAG_WINDOW_RESIZABLE);
wal.addSystem<Renderer3DSystem<RAY3D::Model>>();
wal.addSystem<AnimationsSystem>();
wal.addSystem<Renderer3DSystem<RAY3D::Cube>>();
wal.addSystem<AnimationsSystem>();
wal.addSystem<Render2DScreenSystem>(window)
.addSystem<Renderer2DSystem<RAY2D::Rectangle>>();
@@ -76,12 +76,12 @@ namespace BBM
.addComponent<Drawable3DComponent<RAY3D::Model>>("assets/player/player.iqm", std::make_pair(MAP_DIFFUSE, "assets/player/blue.png"))
.addComponent<ControllableComponent>()
.addComponent<KeyboardComponent>()
.addComponent<AnimationsComponent>(RAY::ModelAnimations("assets/player/player.iqm"), 3)
.addComponent<AnimationsComponent>(RAY::ModelAnimations("assets/player/player.iqm"), 1)
.addComponent<CollisionComponent>(2)
.addComponent<MovableComponent>();
scene->addEntity("cube")
.addComponent<PositionComponent>(-5, 0, -5)
.addComponent<Drawable3DComponent<RAY3D::Cube>>(Vector3f(-5, 0, -5), Vector3f(3, 3, 3), RED)
.addComponent<PositionComponent>(5, 0, 5)
.addComponent<Drawable3DComponent<RAY3D::Cube>>(Vector3f(5, 0, 5), Vector3f(3, 3, 3), RED)
.addComponent<ControllableComponent>()
.addComponent<KeyboardComponent>()
.addComponent<CollisionComponent>([](WAL::Entity &, const WAL::Entity &){},
@@ -96,7 +96,7 @@ namespace BBM
.addComponent<PositionComponent>(8, 20, 7)
.addComponent<CameraComponent>(Vector3f(8, 0, 8));
std::srand(std::time(NULL));
MapGenerator::loadMap(16, 16, MapGenerator::createMap(16, 16), scene);
//MapGenerator::loadMap(16, 16, MapGenerator::createMap(16, 16), scene);
return scene;
}