mirror of
https://github.com/zoriya/Bomberman.git
synced 2026-05-30 17:18:00 +00:00
update map infos function for all ia
This commit is contained in:
@@ -4,6 +4,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <vector>
|
||||
#include "Map/MapInfo.hpp"
|
||||
#include "System/System.hpp"
|
||||
|
||||
namespace BBM
|
||||
@@ -14,10 +16,25 @@ namespace BBM
|
||||
private:
|
||||
//! @brief Reference to wal to get Views
|
||||
WAL::Wal &_wal;
|
||||
|
||||
//! @brief Are the infos cached for current update
|
||||
bool _cached;
|
||||
|
||||
//! @brief All blocks in the map
|
||||
std::vector<MapInfo> _map;
|
||||
|
||||
//! @brief All players in the map
|
||||
std::vector<MapInfo> _players;
|
||||
|
||||
//! @brief
|
||||
void UpdateMapInfos(WAL::Entity entity);
|
||||
public:
|
||||
//! @inherit
|
||||
void onFixedUpdate(WAL::ViewEntity<PositionComponent, ControllableComponent, IAControllableComponent> &entity) override;
|
||||
|
||||
//! @inherit
|
||||
void onSelfUpdate() override;
|
||||
|
||||
//! @brief A default constructor
|
||||
IAControllableSystem(WAL::Wal &wal);
|
||||
//! @brief A keyboard system is copy constructable
|
||||
@@ -26,5 +43,7 @@ namespace BBM
|
||||
~IAControllableSystem() override = default;
|
||||
//! @brief A keyboard system is assignable.
|
||||
IAControllableSystem &operator=(const IAControllableSystem &) = default;
|
||||
|
||||
static bool isInExplosionRange(float x, float y, float z);
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user