updating danger map correctly

This commit is contained in:
Bluub
2021-06-18 14:58:07 +02:00
parent 81784bf0f8
commit 60697a5e2d
5 changed files with 56 additions and 119 deletions
@@ -25,14 +25,11 @@ namespace BBM
//! @brief Map to handle the informations
LuaMap _luamap;
//! @brief All blocks in the map
std::vector<MapInfo> _map;
//! @brief All players in the map
std::vector<MapInfo> _players;
//! @brief All bombs on the map
std::vector<std::tuple<Vector3f, int, std::chrono::nanoseconds>> _bombs;
//! @brief update danger map with a bomb
void updateDangerBomb(Vector3f pos, int radius, std::chrono::nanoseconds ringIn);
//! @brief Register the functions to the lua
void registerFunc(LuaG::State &state);
@@ -40,18 +37,6 @@ namespace BBM
//! @brief update the raw info of the map
void UpdateMapInfos(WAL::ViewEntity<PositionComponent, ControllableComponent, IAControllableComponent, BombHolderComponent> &entity);
//! @brief push danger info position
void pushInfoDangerPos(LuaG::State &state, int &index, float xpos, float ypos, int dangerLevel);
//! @brief push player info
void pushInfoPlayer(LuaG::State &state, MapInfo &player, BombHolderComponent &bombHolder);
//! @brief push raw map info
void pushInfoRaw(LuaG::State &state);
//! @brief push danger map info
void pushInfoDanger(LuaG::State &state);
//! @brief push info ennemies
void pushInfoEnemies(LuaG::State &state);