mirror of
https://github.com/zoriya/Bomberman.git
synced 2026-06-04 10:44:42 +00:00
almost done, just need to link the lobby to the parser
This commit is contained in:
@@ -74,13 +74,12 @@ namespace WAL
|
||||
|
||||
//! @brief A default constructor
|
||||
Scene() = default;
|
||||
//! @brief A scene is copy constructable
|
||||
Scene(const Scene &) = default;
|
||||
//! @brief A scene is not copy constructable
|
||||
Scene(const Scene &) = delete;
|
||||
//! @brief A default destructor
|
||||
~Scene() = default;
|
||||
//! @brief A scene is assignable
|
||||
Scene &operator=(const Scene &);
|
||||
Scene(Scene &&) = default;
|
||||
|
||||
friend Entity;
|
||||
};
|
||||
|
||||
@@ -61,14 +61,20 @@ namespace WAL
|
||||
std::optional<ViewEntity<Components...>> _entity;
|
||||
|
||||
public:
|
||||
ViewEntity<Components...> &operator*()
|
||||
using iterator_category = std::forward_iterator_tag;
|
||||
using difference_type = std::ptrdiff_t;
|
||||
using value_type = ViewEntity<Components...>;
|
||||
using pointer = value_type *;
|
||||
using reference = value_type &;
|
||||
|
||||
reference operator*()
|
||||
{
|
||||
if (!this->_entity)
|
||||
this->_entity.emplace(*this->_it);
|
||||
return *this->_entity;
|
||||
}
|
||||
|
||||
ViewEntity<Components...> *operator->()
|
||||
pointer operator->()
|
||||
{
|
||||
if (!this->_entity)
|
||||
this->_entity =(*this->_it);
|
||||
|
||||
Reference in New Issue
Block a user