mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 13:37:00 +00:00
Add Disables table based on the work of @Olion on Zero
Added `disables` table Mostly backported from TC. Changed table format (mapID in lower 16 bit, areaID in higer 16 bit of data field). Added CREATURE_SPAWN and GAMEOBJECT_SPAWN disable types.
This commit is contained in:
parent
f5bb0529c1
commit
a93afab540
16 changed files with 621 additions and 49 deletions
|
|
@ -78,6 +78,7 @@
|
|||
#include "LFGMgr.h"
|
||||
#include "revision.h"
|
||||
#include "Language.h"
|
||||
#include "DisableMgr.h"
|
||||
|
||||
#ifdef ENABLE_ELUNA
|
||||
#include "LuaEngine.h"
|
||||
|
|
@ -1032,6 +1033,13 @@ void World::SetInitialWorldSettings()
|
|||
///- Initialize config settings
|
||||
LoadConfigSettings();
|
||||
|
||||
///- Initialize VMapManager function pointers (to untangle game/collision circular deps)
|
||||
if (VMAP::VMapManager2* vmmgr2 = dynamic_cast<VMAP::VMapManager2*>(VMAP::VMapFactory::createOrGetVMapManager()))
|
||||
{
|
||||
//vmmgr2->GetLiquidFlagsPtr = &GetLiquidFlags;
|
||||
vmmgr2->IsVMAPDisabledForPtr = &DisableMgr::IsVMAPDisabledFor;
|
||||
}
|
||||
|
||||
///- Check the existence of the map files for all races start areas.
|
||||
if (!MapManager::ExistMapAndVMap(0, -6240.32f, 331.033f) || // Dwarf/ Gnome
|
||||
!MapManager::ExistMapAndVMap(0, -8949.95f, -132.493f) || // Human
|
||||
|
|
@ -1152,6 +1160,9 @@ void World::SetInitialWorldSettings()
|
|||
sLog.outString("Loading Item Random Enchantments Table...");
|
||||
LoadRandomEnchantmentsTable();
|
||||
|
||||
sLog.outString("Loading Disables..."); // must be before loading quests and items
|
||||
DisableMgr::LoadDisables();
|
||||
|
||||
sLog.outString("Loading Items..."); // must be after LoadRandomEnchantmentsTable and LoadPageTexts
|
||||
sObjectMgr.LoadItemPrototypes();
|
||||
|
||||
|
|
@ -1242,6 +1253,9 @@ void World::SetInitialWorldSettings()
|
|||
sLog.outString(">>> Quests Relations loaded");
|
||||
sLog.outString();
|
||||
|
||||
sLog.outString("Checking Quest Disables...");
|
||||
DisableMgr::CheckQuestDisables(); // must be after loading quests
|
||||
|
||||
sLog.outString("Loading Game Event Data..."); // must be after sPoolMgr.LoadFromDB and quests to properly load pool events and quests for events
|
||||
sLog.outString();
|
||||
sGameEventMgr.LoadFromDB();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue