#include <GridNotifiers.hpp>
◆ GridUnitMovementNotifier()
GridUnitMovementNotifier::GridUnitMovementNotifier |
( |
const std::shared_ptr< Horizon::Zone::Unit > & |
unit, |
|
|
bool |
new_entry = false |
|
) |
| |
|
inlineexplicit |
105 { }
bool _new_entry
Definition: GridNotifiers.hpp:101
std::weak_ptr< Horizon::Zone::Unit > _unit
Definition: GridNotifiers.hpp:100
◆ notify()
212{
214
216 return;
217
218 std::shared_ptr<Horizon::Zone::Unit> src_unit =
_unit.lock();
219
220 if (src_unit == nullptr)
221 return;
222
224 if (iter->source() == nullptr)
225 continue;
226
227 std::shared_ptr<Player> tpl = iter->source()->template downcast<Player>();
228
229 if (src_unit->guid() == tpl->guid())
230 continue;
231
232 if (tpl->get_session() == nullptr || tpl->get_session()->clif() == nullptr)
233 continue;
234
236 tpl->realize_unit_movement_entry((int32_t)
get_sys_time(), src_unit);
237 else
238 tpl->realize_unit_movement((int32_t)
get_sys_time(), src_unit);
239 }
240}
int64_t get_sys_time()
Definition: Utility.cpp:68
Forward declaration of GridRefManager, the class that manages GridReference.
Definition: GridRefManager.hpp:41
iterator begin()
Definition: GridRefManager.hpp:54
uint32_t get_size() const
returns the number of Elements in the list (not including the head and tail Elements or the first and...
Definition: Head.hpp:69
Definition: GameLogicProcess.hpp:43
References _new_entry, _unit, GridRefManager< OBJECT >::begin(), Horizon::Structures::LinkedList::Head::get_size(), and get_sys_time().
◆ Visit() [1/10]
◆ Visit() [2/10]
◆ Visit() [3/10]
◆ Visit() [4/10]
◆ Visit() [5/10]
◆ Visit() [6/10]
template<class NOT_INTERESTED >
void GridUnitMovementNotifier::Visit |
( |
GridRefManager< NOT_INTERESTED > & |
| ) |
|
|
inline |
◆ Visit() [7/10]
◆ Visit() [8/10]
◆ Visit() [9/10]
◆ Visit() [10/10]
◆ _new_entry
bool GridUnitMovementNotifier::_new_entry { false } |
◆ _unit
The documentation for this struct was generated from the following files: