diff options
author | r00ty-tc <r00ty-tc@users.noreply.github.com> | 2017-05-07 21:48:41 +0100 |
---|---|---|
committer | Treeston <treeston.mmoc@gmail.com> | 2017-07-31 21:21:04 +0200 |
commit | 59db2eeea0a35028779fd76372ae06cc98c8086f (patch) | |
tree | a9532989868948cb309cb8d76a2e76a017fa9246 /src/server/game/Maps/MapManager.h | |
parent | d24ce1739a799042d5a164794c09674227c8572c (diff) |
Dynamic Creature/Go spawning:
- True blizzlike creature spawn/respawn behavior - new creature = new object
- Toggleable spawn groups (with C++/SAI/command options to use them)
- Custom feature: dynamic spawn rate scaling. Accelerates respawn rate based on players in the zone.
- Backward compatibility mode (set via group and for summons)
to support creatures/gos that currently don't work well with this
(this should be removed once the exceptions are fixed)
Fixes and closes #2858
Tags #8661 as fixable.
Fixes and closes #13787
Fixes #15222.
Diffstat (limited to 'src/server/game/Maps/MapManager.h')
-rw-r--r-- | src/server/game/Maps/MapManager.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/server/game/Maps/MapManager.h b/src/server/game/Maps/MapManager.h index e628a7030ae..96147c7ded7 100644 --- a/src/server/game/Maps/MapManager.h +++ b/src/server/game/Maps/MapManager.h @@ -44,16 +44,22 @@ class TC_GAME_API MapManager Map const* m = const_cast<MapManager*>(this)->CreateBaseMap(mapid); return m->GetAreaId(x, y, z); } + uint32 GetAreaId(uint32 mapid, Position const& pos) const { return GetAreaId(mapid, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ()); } + uint32 GetAreaId(WorldLocation const& loc) const { return GetAreaId(loc.GetMapId(), loc); } uint32 GetZoneId(uint32 mapid, float x, float y, float z) const { Map const* m = const_cast<MapManager*>(this)->CreateBaseMap(mapid); return m->GetZoneId(x, y, z); } - void GetZoneAndAreaId(uint32& zoneid, uint32& areaid, uint32 mapid, float x, float y, float z) + uint32 GetZoneId(uint32 mapid, Position const& pos) const { return GetZoneId(mapid, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ()); } + uint32 GetZoneId(WorldLocation const& loc) const { return GetZoneId(loc.GetMapId(), loc); } + void GetZoneAndAreaId(uint32& zoneid, uint32& areaid, uint32 mapid, float x, float y, float z) const { Map const* m = const_cast<MapManager*>(this)->CreateBaseMap(mapid); m->GetZoneAndAreaId(zoneid, areaid, x, y, z); } + void GetZoneAndAreaId(uint32& zoneid, uint32& areaid, uint32 mapid, Position const& pos) const { GetZoneAndAreaId(zoneid, areaid, mapid, pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ()); } + void GetZoneAndAreaId(uint32& zoneid, uint32& areaid, WorldLocation const& loc) const { GetZoneAndAreaId(zoneid, areaid, loc.GetMapId(), loc); } void Initialize(void); void Update(uint32); |