Core/Grids: Ported cmangos/mangos-wotlk@ea99457
(cherry picked from commit 9299e9b)
This commit is contained in:
1 parent
0762d35b71
commit
1a5c0f5c3b
54 files changed
+227
-399
No files matched your search
@@ -2689,27 +2689,6 @@ char const* Map::GetMapName() const
|
||||
return i_mapEntry ? i_mapEntry->name : "UNNAMEDMAP\x0";
|
||||
}
|
||||
|
||||
void Map::UpdateObjectVisibility(WorldObject* obj, Cell cell, CellCoord cellpair)
|
||||
{
|
||||
cell.SetNoCreate();
|
||||
Trinity::VisibleChangesNotifier notifier(*obj);
|
||||
TypeContainerVisitor<Trinity::VisibleChangesNotifier, WorldTypeMapContainer > player_notifier(notifier);
|
||||
cell.Visit(cellpair, player_notifier, *this, *obj, obj->GetVisibilityRange());
|
||||
}
|
||||
|
||||
void Map::UpdateObjectsVisibilityFor(Player* player, Cell cell, CellCoord cellpair)
|
||||
{
|
||||
Trinity::VisibleNotifier notifier(*player);
|
||||
|
||||
cell.SetNoCreate();
|
||||
TypeContainerVisitor<Trinity::VisibleNotifier, WorldTypeMapContainer > world_notifier(notifier);
|
||||
TypeContainerVisitor<Trinity::VisibleNotifier, GridTypeMapContainer > grid_notifier(notifier);
|
||||
cell.Visit(cellpair, world_notifier, *this, *player->m_seer, player->GetSightRange());
|
||||
cell.Visit(cellpair, grid_notifier, *this, *player->m_seer, player->GetSightRange());
|
||||
// send data
|
||||
notifier.SendToSelf();
|
||||
}
|
||||
|
||||
void Map::SendInitSelf(Player* player)
|
||||
{
|
||||
TC_LOG_DEBUG("maps", "Creating player data for himself %u", player->GetGUID().GetCounter());
|
||||
|
||||
Reference in new issue
Block a user