mirror of
https://github.com/zoriya/Bomberman.git
synced 2026-05-23 23:07:54 +00:00
Merge branch 'gravity_component' of github.com:AnonymusRaccoon/Bomberman into gravity_component
This commit is contained in:
+3
-1
@@ -9,6 +9,7 @@
|
||||
#include <iostream>
|
||||
#include <Items/Bonus.hpp>
|
||||
#include <Component/Levitate/LevitateComponent.hpp>
|
||||
#include "Component/Movable/MovableComponent.hpp"
|
||||
#include <Component/Timer/TimerComponent.hpp>
|
||||
#include <Component/Tag/TagComponent.hpp>
|
||||
#include <Component/BumperTimer/BumperTimerComponent.hpp>
|
||||
@@ -81,6 +82,7 @@ namespace BBM
|
||||
wal.getScene()->scheduleNewEntity("Bonus")
|
||||
.addComponent<PositionComponent>(position)
|
||||
.addComponent<TagComponent<Blowable>>()
|
||||
.addComponent<MovableComponent>()
|
||||
.addComponent<HealthComponent>(1, [](WAL::Entity &entity, WAL::Wal &wal) {
|
||||
entity.scheduleDeletion();
|
||||
})
|
||||
@@ -193,7 +195,7 @@ namespace BBM
|
||||
for (int i = 0; i < width + 1; i++) {
|
||||
for (int j = 0; j < height + 1; j++) {
|
||||
if (map[std::make_tuple(i, 0, j)] != HOLE && map[std::make_tuple(i, -1, j)] != BUMPER)
|
||||
scene->addEntity("Unbreakable Wall")
|
||||
scene->addEntity("Floor")
|
||||
.addComponent<PositionComponent>(Vector3f(i, -1, j))
|
||||
.addComponent<Drawable3DComponent, RAY3D::Model>(floorObj, false,
|
||||
std::make_pair(MAP_DIFFUSE, floorPng));
|
||||
|
||||
Reference in New Issue
Block a user