mirror of
https://github.com/zoriya/Bomberman.git
synced 2026-06-09 20:25:31 +00:00
reset map before update, not optimale but ok for now
This commit is contained in:
@@ -27,6 +27,9 @@ namespace BBM
|
|||||||
}
|
}
|
||||||
if (_cached)
|
if (_cached)
|
||||||
return;
|
return;
|
||||||
|
for (int i = 0; i < 17; i++)
|
||||||
|
for (int j = 0; j < 17; j++)
|
||||||
|
_luamap._map[i][j] = 0;
|
||||||
for (auto &[other, pos, _] : _wal.getScene()->view<PositionComponent, TagComponent<Breakable>>())
|
for (auto &[other, pos, _] : _wal.getScene()->view<PositionComponent, TagComponent<Breakable>>())
|
||||||
_luamap._map[pos.position.z][pos.position.x] = MapGenerator::BREAKABLE;
|
_luamap._map[pos.position.z][pos.position.x] = MapGenerator::BREAKABLE;
|
||||||
for (auto &[other, pos, _] : _wal.getScene()->view<PositionComponent, TagComponent<Unbreakable>>())
|
for (auto &[other, pos, _] : _wal.getScene()->view<PositionComponent, TagComponent<Unbreakable>>())
|
||||||
|
|||||||
Reference in New Issue
Block a user