diff options
| author | Shauren <none@none> | 2010-09-02 10:40:32 +0200 |
|---|---|---|
| committer | Shauren <none@none> | 2010-09-02 10:40:32 +0200 |
| commit | 0f9fe8dbeb3990175cfac07a3b7349c9d8e668b7 (patch) | |
| tree | d18a6f125f64682fb0623f3dbae2e4ac38948f11 /src/server/game/Globals/ObjectMgr.cpp | |
| parent | 320cd16f209c95480c3dacf8d2a17466d551019f (diff) | |
Core/Players: Don't set instanceId to 0 when player is on transport during loading, there CAN be transports inside instances
Core/Scripts: Added waypoint id to OnRelocate transport hook
Core/Scripts: Make use of ZoneScript::GetGameObjectEntry at gameobject creation (makes it possible to override gameobject entries in instances)
Core/Transports: Call InstanceScript::EventInform for transport events
Core/Transports: Use guid from db for transports, not just its entry - adds partial support for instancing them (still cannot use transports table for it, but can spawn manually now)
Scripts/Icecrown Citadel: Fixed crash in Deathbringer Saurfang when event is started by more than one person (can't do this anymore)
Closes isssue #3749.
--HG--
branch : trunk
Diffstat (limited to 'src/server/game/Globals/ObjectMgr.cpp')
| -rw-r--r-- | src/server/game/Globals/ObjectMgr.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/server/game/Globals/ObjectMgr.cpp b/src/server/game/Globals/ObjectMgr.cpp index eee64145ada..44a6b110759 100644 --- a/src/server/game/Globals/ObjectMgr.cpp +++ b/src/server/game/Globals/ObjectMgr.cpp @@ -261,6 +261,7 @@ ObjectMgr::ObjectMgr() m_hiCorpseGuid = 1; m_hiPetNumber = 1; m_hiGroupGuid = 1; + m_hiMoTransGuid = 1; m_ItemTextId = 1; m_mailid = 1; m_equipmentSetGuid = 1; @@ -6119,6 +6120,10 @@ void ObjectMgr::SetHighestGuids() if (result) m_hiGoGuid = (*result)[0].GetUInt32()+1; + result = WorldDatabase.Query("SELECT MAX(guid) FROM transports"); + if (result) + m_hiMoTransGuid = (*result)[0].GetUInt32()+1; + result = CharacterDatabase.Query("SELECT MAX(id) FROM auctionhouse"); if (result) m_auctionid = (*result)[0].GetUInt32()+1; @@ -6265,6 +6270,13 @@ uint32 ObjectMgr::GenerateLowGuid(HighGuid guidhigh) World::StopNow(ERROR_EXIT_CODE); } return m_hiGroupGuid++; + case HIGHGUID_MO_TRANSPORT: + if (m_hiMoTransGuid >= 0xFFFFFFFE) + { + sLog.outError("MO Transport guid overflow!! Can't continue, shutting down server. "); + World::StopNow(ERROR_EXIT_CODE); + } + return m_hiMoTransGuid++; default: ASSERT(0); } |
