[8182] Store and use Map* pointer in WorldObject instead map ids for speedup

Also some code logic cleanups.
Changes let make more cleanups in base map access and other places,
but this chnages not inlcuded in patch.

Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
Ambal 2009-07-15 01:30:13 +04:00 committed by VladimirMangos
parent fcb34b3928
commit 58209ee79a
25 changed files with 180 additions and 193 deletions

View file

@ -109,9 +109,9 @@ void GameObject::RemoveFromWorld()
bool GameObject::Create(uint32 guidlow, uint32 name_id, Map *map, uint32 phaseMask, float x, float y, float z, float ang, float rotation0, float rotation1, float rotation2, float rotation3, uint32 animprogress, GOState go_state)
{
ASSERT(map);
Relocate(x,y,z,ang);
SetMapId(map->GetId());
SetInstanceId(map->GetInstanceId());
SetMap(map);
SetPhaseMask(phaseMask,false);
if(!IsPositionValid())