mirror of
https://github.com/azerothcore/azerothcore-wotlk.git
synced 2025-12-06 02:30:26 -08:00
DB/World: move questItem* fields to *_questitems tables (#249)
This commit is contained in:
parent
084929c558
commit
81b195099b
10 changed files with 192 additions and 57 deletions
|
|
@ -0,0 +1,46 @@
|
|||
INSERT INTO version_db_world (`sql_rev`) VALUES ('1479653240477084000');
|
||||
|
||||
DROP TABLE IF EXISTS `creature_questitem`;
|
||||
CREATE TABLE `creature_questitem` (
|
||||
`CreatureEntry` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
`Idx` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
`ItemId` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
PRIMARY KEY (`CreatureEntry`,`Idx`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
|
||||
|
||||
DROP TABLE IF EXISTS `gameobject_questitem`;
|
||||
CREATE TABLE `gameobject_questitem` (
|
||||
`GameObjectEntry` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
`Idx` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
`ItemId` int(10) unsigned NOT NULL DEFAULT '0',
|
||||
PRIMARY KEY (`GameObjectEntry`,`Idx`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
|
||||
|
||||
INSERT INTO gameobject_questitem (`GameObjectEntry`, `Idx`, `ItemId`)
|
||||
(SELECT gameobject_template.entry, 0, gameobject_template.questItem1 FROM gameobject_template WHERE gameobject_template.questItem1 != 0);
|
||||
INSERT INTO gameobject_questitem (`GameObjectEntry`, `Idx`, `ItemId`)
|
||||
(SELECT gameobject_template.entry, 1, gameobject_template.questItem2 FROM gameobject_template WHERE gameobject_template.questItem2 != 0);
|
||||
INSERT INTO gameobject_questitem (`GameObjectEntry`, `Idx`, `ItemId`)
|
||||
(SELECT gameobject_template.entry, 2, gameobject_template.questItem3 FROM gameobject_template WHERE gameobject_template.questItem3 != 0);
|
||||
INSERT INTO gameobject_questitem (`GameObjectEntry`, `Idx`, `ItemId`)
|
||||
(SELECT gameobject_template.entry, 3, gameobject_template.questItem4 FROM gameobject_template WHERE gameobject_template.questItem4 != 0);
|
||||
INSERT INTO gameobject_questitem (`GameObjectEntry`, `Idx`, `ItemId`)
|
||||
(SELECT gameobject_template.entry, 4, gameobject_template.questItem5 FROM gameobject_template WHERE gameobject_template.questItem5 != 0);
|
||||
INSERT INTO gameobject_questitem (`GameObjectEntry`, `Idx`, `ItemId`)
|
||||
(SELECT gameobject_template.entry, 5, gameobject_template.questItem6 FROM gameobject_template WHERE gameobject_template.questItem6 != 0);
|
||||
|
||||
INSERT INTO creature_questitem (`CreatureEntry`, `Idx`, `ItemId`)
|
||||
(SELECT creature_template.entry, 0, creature_template.questItem1 FROM creature_template WHERE creature_template.questItem1 != 0);
|
||||
INSERT INTO creature_questitem (`CreatureEntry`, `Idx`, `ItemId`)
|
||||
(SELECT creature_template.entry, 1, creature_template.questItem2 FROM creature_template WHERE creature_template.questItem2 != 0);
|
||||
INSERT INTO creature_questitem (`CreatureEntry`, `Idx`, `ItemId`)
|
||||
(SELECT creature_template.entry, 2, creature_template.questItem3 FROM creature_template WHERE creature_template.questItem3 != 0);
|
||||
INSERT INTO creature_questitem (`CreatureEntry`, `Idx`, `ItemId`)
|
||||
(SELECT creature_template.entry, 3, creature_template.questItem4 FROM creature_template WHERE creature_template.questItem4 != 0);
|
||||
INSERT INTO creature_questitem (`CreatureEntry`, `Idx`, `ItemId`)
|
||||
(SELECT creature_template.entry, 4, creature_template.questItem5 FROM creature_template WHERE creature_template.questItem5 != 0);
|
||||
INSERT INTO creature_questitem (`CreatureEntry`, `Idx`, `ItemId`)
|
||||
(SELECT creature_template.entry, 5, creature_template.questItem6 FROM creature_template WHERE creature_template.questItem6 != 0);
|
||||
|
||||
ALTER TABLE `creature_template` DROP `questItem1`, DROP `questItem2`, DROP `questItem3`, DROP `questItem4`, DROP `questItem5`, DROP `questItem6`;
|
||||
ALTER TABLE `gameobject_template` DROP `questItem1`, DROP `questItem2`, DROP `questItem3`, DROP `questItem4`, DROP `questItem5`, DROP `questItem6`;
|
||||
|
|
@ -66,7 +66,7 @@ void WorldDatabaseConnection::DoPrepareStatements()
|
|||
PrepareStatement(WORLD_SEL_WAYPOINT_SCRIPT_ID_BY_GUID, "SELECT id FROM waypoint_scripts WHERE guid = ?", CONNECTION_SYNCH);
|
||||
PrepareStatement(WORLD_DEL_CREATURE, "DELETE FROM creature WHERE guid = ?", CONNECTION_ASYNC);
|
||||
PrepareStatement(WORLD_SEL_COMMANDS, "SELECT name, security, help FROM command", CONNECTION_SYNCH);
|
||||
PrepareStatement(WORLD_SEL_CREATURE_TEMPLATE, "SELECT difficulty_entry_1, difficulty_entry_2, difficulty_entry_3, KillCredit1, KillCredit2, modelid1, modelid2, modelid3, modelid4, name, subname, IconName, gossip_menu_id, minlevel, maxlevel, exp, faction, npcflag, speed_walk, speed_run, scale, rank, mindmg, maxdmg, dmgschool, attackpower, dmg_multiplier, baseattacktime, rangeattacktime, unit_class, unit_flags, unit_flags2, dynamicflags, family, trainer_type, trainer_spell, trainer_class, trainer_race, minrangedmg, maxrangedmg, rangedattackpower, type, type_flags, lootid, pickpocketloot, skinloot, resistance1, resistance2, resistance3, resistance4, resistance5, resistance6, spell1, spell2, spell3, spell4, spell5, spell6, spell7, spell8, PetSpellDataId, VehicleId, mingold, maxgold, AIName, MovementType, InhabitType, HoverHeight, Health_mod, Mana_mod, Armor_mod, RacialLeader, questItem1, questItem2, questItem3, questItem4, questItem5, questItem6, movementId, RegenHealth, mechanic_immune_mask, flags_extra, ScriptName FROM creature_template WHERE entry = ?", CONNECTION_SYNCH);
|
||||
PrepareStatement(WORLD_SEL_CREATURE_TEMPLATE, "SELECT difficulty_entry_1, difficulty_entry_2, difficulty_entry_3, KillCredit1, KillCredit2, modelid1, modelid2, modelid3, modelid4, name, subname, IconName, gossip_menu_id, minlevel, maxlevel, exp, faction, npcflag, speed_walk, speed_run, scale, rank, mindmg, maxdmg, dmgschool, attackpower, dmg_multiplier, baseattacktime, rangeattacktime, unit_class, unit_flags, unit_flags2, dynamicflags, family, trainer_type, trainer_spell, trainer_class, trainer_race, minrangedmg, maxrangedmg, rangedattackpower, type, type_flags, lootid, pickpocketloot, skinloot, resistance1, resistance2, resistance3, resistance4, resistance5, resistance6, spell1, spell2, spell3, spell4, spell5, spell6, spell7, spell8, PetSpellDataId, VehicleId, mingold, maxgold, AIName, MovementType, InhabitType, HoverHeight, Health_mod, Mana_mod, Armor_mod, RacialLeader, movementId, RegenHealth, mechanic_immune_mask, flags_extra, ScriptName FROM creature_template WHERE entry = ?", CONNECTION_SYNCH);
|
||||
PrepareStatement(WORLD_SEL_WAYPOINT_SCRIPT_BY_ID, "SELECT guid, delay, command, datalong, datalong2, dataint, x, y, z, o FROM waypoint_scripts WHERE id = ?", CONNECTION_SYNCH);
|
||||
PrepareStatement(WORLD_SEL_ITEM_TEMPLATE_BY_NAME, "SELECT entry FROM item_template WHERE name = ?", CONNECTION_SYNCH);
|
||||
PrepareStatement(WORLD_SEL_CREATURE_BY_ID, "SELECT guid FROM creature WHERE id = ?", CONNECTION_SYNCH);
|
||||
|
|
|
|||
|
|
@ -119,8 +119,6 @@ void CreatureTemplate::InitializeQueryData()
|
|||
queryData << float(ModHealth); // dmg/hp modifier
|
||||
queryData << float(ModMana); // dmg/mana modifier
|
||||
queryData << uint8(RacialLeader);
|
||||
for (uint32 i = 0; i < MAX_CREATURE_QUEST_ITEMS; ++i)
|
||||
queryData << uint32(questItems[i]); // itemId[6], quest drop
|
||||
queryData << uint32(movementId); // CreatureMovementInfo.dbc
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -129,7 +129,6 @@ struct CreatureTemplate
|
|||
float ModMana;
|
||||
float ModArmor;
|
||||
bool RacialLeader;
|
||||
uint32 questItems[MAX_CREATURE_QUEST_ITEMS];
|
||||
uint32 movementId;
|
||||
bool RegenHealth;
|
||||
uint32 MechanicImmuneMask;
|
||||
|
|
@ -164,6 +163,9 @@ struct CreatureTemplate
|
|||
void InitializeQueryData();
|
||||
};
|
||||
|
||||
typedef std::vector<uint32> CreatureQuestItemList;
|
||||
typedef std::unordered_map<uint32, CreatureQuestItemList> CreatureQuestItemMap;
|
||||
|
||||
// Benchmarked: Faster than std::map (insert/find)
|
||||
typedef UNORDERED_MAP<uint32, CreatureTemplate> CreatureTemplateContainer;
|
||||
|
||||
|
|
|
|||
|
|
@ -35,7 +35,6 @@ struct GameObjectTemplate
|
|||
uint32 faction;
|
||||
uint32 flags;
|
||||
float size;
|
||||
uint32 questItems[MAX_GAMEOBJECT_QUEST_ITEMS];
|
||||
union // different GO types have different data field
|
||||
{
|
||||
//0 GAMEOBJECT_TYPE_DOOR
|
||||
|
|
@ -611,6 +610,9 @@ struct GameObjectData
|
|||
bool dbData;
|
||||
};
|
||||
|
||||
typedef std::vector<uint32> GameObjectQuestItemList;
|
||||
typedef std::unordered_map<uint32, GameObjectQuestItemList> GameObjectQuestItemMap;
|
||||
|
||||
// For containers: [GO_NOT_READY]->GO_READY (close)->GO_ACTIVATED (open) ->GO_JUST_DEACTIVATED->GO_READY -> ...
|
||||
// For bobber: GO_NOT_READY ->GO_READY (close)->GO_ACTIVATED (open) ->GO_JUST_DEACTIVATED-><deleted>
|
||||
// For door(closed):[GO_NOT_READY]->GO_READY (close)->GO_ACTIVATED (open) ->GO_JUST_DEACTIVATED->GO_READY(close) -> ...
|
||||
|
|
|
|||
|
|
@ -406,9 +406,7 @@ void ObjectMgr::LoadCreatureTemplates()
|
|||
// 55 56 57 58 59 60 61 62 63 64 65 66 67
|
||||
"spell2, spell3, spell4, spell5, spell6, spell7, spell8, PetSpellDataId, VehicleId, mingold, maxgold, AIName, MovementType, "
|
||||
// 68 69 70 71 72 73 74 75 76 77 78
|
||||
"InhabitType, HoverHeight, Health_mod, Mana_mod, Armor_mod, RacialLeader, questItem1, questItem2, questItem3, questItem4, questItem5, "
|
||||
// 79 80 81 83 84
|
||||
" questItem6, movementId, RegenHealth, mechanic_immune_mask, flags_extra, ScriptName "
|
||||
"InhabitType, HoverHeight, Health_mod, Mana_mod, Armor_mod, RacialLeader, movementId, RegenHealth, mechanic_immune_mask, flags_extra, ScriptName "
|
||||
"FROM creature_template;");
|
||||
|
||||
if (!result)
|
||||
|
|
@ -496,15 +494,11 @@ void ObjectMgr::LoadCreatureTemplates()
|
|||
creatureTemplate.ModMana = fields[70].GetFloat();
|
||||
creatureTemplate.ModArmor = fields[71].GetFloat();
|
||||
creatureTemplate.RacialLeader = fields[72].GetBool();
|
||||
|
||||
for (uint8 i = 0; i < MAX_CREATURE_QUEST_ITEMS; ++i)
|
||||
creatureTemplate.questItems[i] = fields[73 + i].GetUInt32();
|
||||
|
||||
creatureTemplate.movementId = fields[79].GetUInt32();
|
||||
creatureTemplate.RegenHealth = fields[80].GetBool();
|
||||
creatureTemplate.MechanicImmuneMask = fields[81].GetUInt32();
|
||||
creatureTemplate.flags_extra = fields[82].GetUInt32();
|
||||
creatureTemplate.ScriptID = GetScriptId(fields[83].GetCString());
|
||||
creatureTemplate.movementId = fields[73].GetUInt32();
|
||||
creatureTemplate.RegenHealth = fields[74].GetBool();
|
||||
creatureTemplate.MechanicImmuneMask = fields[75].GetUInt32();
|
||||
creatureTemplate.flags_extra = fields[76].GetUInt32();
|
||||
creatureTemplate.ScriptID = GetScriptId(fields[77].GetCString());
|
||||
|
||||
++count;
|
||||
}
|
||||
|
|
@ -6533,11 +6527,11 @@ void ObjectMgr::LoadGameObjectTemplate()
|
|||
{
|
||||
uint32 oldMSTime = getMSTime();
|
||||
|
||||
// 0 1 2 3 4 5 6 7 8 9 10 11 12
|
||||
QueryResult result = WorldDatabase.Query("SELECT entry, type, displayId, name, IconName, castBarCaption, unk1, faction, flags, size, questItem1, questItem2, questItem3, "
|
||||
// 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
||||
"questItem4, questItem5, questItem6, Data0, Data1, Data2, Data3, Data4, Data5, Data6, Data7, Data8, Data9, Data10, Data11, Data12, "
|
||||
// 29 30 31 32 33 34 35 36 37 38 39 40 41
|
||||
// 0 1 2 3 4 5 6 7 8 9
|
||||
QueryResult result = WorldDatabase.Query("SELECT entry, type, displayId, name, IconName, castBarCaption, unk1, faction, flags, size, "
|
||||
// 10 11 12 13 14 15 16 17 18 19 20 21 22
|
||||
"Data0, Data1, Data2, Data3, Data4, Data5, Data6, Data7, Data8, Data9, Data10, Data11, Data12, "
|
||||
// 23 24 25 26 27 28 29 30 31 32 33 34 35
|
||||
"Data13, Data14, Data15, Data16, Data17, Data18, Data19, Data20, Data21, Data22, Data23, AIName, ScriptName "
|
||||
"FROM gameobject_template");
|
||||
|
||||
|
|
@ -6569,14 +6563,11 @@ void ObjectMgr::LoadGameObjectTemplate()
|
|||
got.flags = fields[8].GetUInt32();
|
||||
got.size = fields[9].GetFloat();
|
||||
|
||||
for (uint8 i = 0; i < MAX_GAMEOBJECT_QUEST_ITEMS; ++i)
|
||||
got.questItems[i] = fields[10 + i].GetUInt32();
|
||||
|
||||
for (uint8 i = 0; i < MAX_GAMEOBJECT_DATA; ++i)
|
||||
got.raw.data[i] = fields[16 + i].GetInt32(); // data1 and data6 can be -1
|
||||
got.raw.data[i] = fields[10 + i].GetInt32(); // data1 and data6 can be -1
|
||||
|
||||
got.AIName = fields[40].GetString();
|
||||
got.ScriptId = GetScriptId(fields[41].GetCString());
|
||||
got.AIName = fields[34].GetString();
|
||||
got.ScriptId = GetScriptId(fields[35].GetCString());
|
||||
got.IsForQuests = false;
|
||||
|
||||
// Checks
|
||||
|
|
@ -9253,3 +9244,63 @@ PlayerInfo const* ObjectMgr::GetPlayerInfo(uint32 race, uint32 class_) const
|
|||
return NULL;
|
||||
return info;
|
||||
}
|
||||
|
||||
void ObjectMgr::LoadGameObjectQuestItems()
|
||||
{
|
||||
uint32 oldMSTime = getMSTime();
|
||||
|
||||
// 0 1
|
||||
QueryResult result = WorldDatabase.Query("SELECT GameObjectEntry, ItemId FROM gameobject_questitem ORDER BY Idx ASC");
|
||||
|
||||
if (!result)
|
||||
{
|
||||
sLog->outString(">> Loaded 0 gameobject quest items. DB table `gameobject_questitem` is empty.");
|
||||
return;
|
||||
}
|
||||
|
||||
uint32 count = 0;
|
||||
do
|
||||
{
|
||||
Field* fields = result->Fetch();
|
||||
|
||||
uint32 entry = fields[0].GetUInt32();
|
||||
uint32 item = fields[1].GetUInt32();
|
||||
|
||||
_gameObjectQuestItemStore[entry].push_back(item);
|
||||
|
||||
++count;
|
||||
}
|
||||
while (result->NextRow());
|
||||
|
||||
sLog->outString(">> Loaded %u gameobject quest items in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
|
||||
}
|
||||
|
||||
void ObjectMgr::LoadCreatureQuestItems()
|
||||
{
|
||||
uint32 oldMSTime = getMSTime();
|
||||
|
||||
// 0 1
|
||||
QueryResult result = WorldDatabase.Query("SELECT CreatureEntry, ItemId FROM creature_questitem ORDER BY Idx ASC");
|
||||
|
||||
if (!result)
|
||||
{
|
||||
sLog->outString(">> Loaded 0 creature quest items. DB table `creature_questitem` is empty.");
|
||||
return;
|
||||
}
|
||||
|
||||
uint32 count = 0;
|
||||
do
|
||||
{
|
||||
Field* fields = result->Fetch();
|
||||
|
||||
uint32 entry = fields[0].GetUInt32();
|
||||
uint32 item = fields[1].GetUInt32();
|
||||
|
||||
_creatureQuestItemStore[entry].push_back(item);
|
||||
|
||||
++count;
|
||||
}
|
||||
while (result->NextRow());
|
||||
|
||||
sLog->outString("server.loading", ">> Loaded %u creature quest items in %u ms", count, GetMSTimeDiffToNow(oldMSTime));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -754,6 +754,24 @@ class ObjectMgr
|
|||
void GetTaxiPath(uint32 source, uint32 destination, uint32 &path, uint32 &cost);
|
||||
uint32 GetTaxiMountDisplayId(uint32 id, TeamId teamId, bool allowed_alt_team = false);
|
||||
|
||||
GameObjectQuestItemList const* GetGameObjectQuestItemList(uint32 id) const
|
||||
{
|
||||
GameObjectQuestItemMap::const_iterator itr = _gameObjectQuestItemStore.find(id);
|
||||
if (itr != _gameObjectQuestItemStore.end())
|
||||
return &itr->second;
|
||||
return NULL;
|
||||
}
|
||||
GameObjectQuestItemMap const* GetGameObjectQuestItemMap() const { return &_gameObjectQuestItemStore; }
|
||||
|
||||
CreatureQuestItemList const* GetCreatureQuestItemList(uint32 id) const
|
||||
{
|
||||
CreatureQuestItemMap::const_iterator itr = _creatureQuestItemStore.find(id);
|
||||
if (itr != _creatureQuestItemStore.end())
|
||||
return &itr->second;
|
||||
return NULL;
|
||||
}
|
||||
CreatureQuestItemMap const* GetCreatureQuestItemMap() const { return &_creatureQuestItemStore; }
|
||||
|
||||
Quest const* GetQuestTemplate(uint32 quest_id) const
|
||||
{
|
||||
return quest_id < _questTemplatesFast.size() ? _questTemplatesFast[quest_id] : NULL;
|
||||
|
|
@ -934,6 +952,8 @@ class ObjectMgr
|
|||
void LoadCreatureTemplates();
|
||||
void LoadCreatureTemplateAddons();
|
||||
void CheckCreatureTemplate(CreatureTemplate const* cInfo);
|
||||
void LoadGameObjectQuestItems();
|
||||
void LoadCreatureQuestItems();
|
||||
void LoadTempSummons();
|
||||
void LoadCreatures();
|
||||
void LoadLinkedRespawn();
|
||||
|
|
@ -1377,6 +1397,8 @@ class ObjectMgr
|
|||
CreatureAddonContainer _creatureAddonStore;
|
||||
CreatureAddonContainer _creatureTemplateAddonStore;
|
||||
GameObjectAddonContainer _gameObjectAddonStore;
|
||||
GameObjectQuestItemMap _gameObjectQuestItemStore;
|
||||
CreatureQuestItemMap _creatureQuestItemStore;
|
||||
EquipmentInfoContainer _equipmentInfoStore;
|
||||
LinkedRespawnContainer _linkedRespawnStore;
|
||||
CreatureLocaleContainer _creatureLocaleStore;
|
||||
|
|
|
|||
|
|
@ -121,8 +121,15 @@ void WorldSession::HandleCreatureQueryOpcode(WorldPacket & recvData)
|
|||
data << float(ci->ModHealth); // dmg/hp modifier
|
||||
data << float(ci->ModMana); // dmg/mana modifier
|
||||
data << uint8(ci->RacialLeader);
|
||||
for (uint32 i = 0; i < MAX_CREATURE_QUEST_ITEMS; ++i)
|
||||
data << uint32(ci->questItems[i]); // itemId[6], quest drop
|
||||
|
||||
CreatureQuestItemList const* items = sObjectMgr->GetCreatureQuestItemList(entry);
|
||||
if (items)
|
||||
for (size_t i = 0; i < MAX_CREATURE_QUEST_ITEMS; ++i)
|
||||
data << (i < items->size() ? uint32((*items)[i]) : uint32(0));
|
||||
else
|
||||
for (size_t i = 0; i < MAX_CREATURE_QUEST_ITEMS; ++i)
|
||||
data << uint32(0);
|
||||
|
||||
data << uint32(ci->movementId); // CreatureMovementInfo.dbc
|
||||
SendPacket(&data);
|
||||
}
|
||||
|
|
@ -176,8 +183,15 @@ void WorldSession::HandleGameObjectQueryOpcode(WorldPacket & recvData)
|
|||
data << info->unk1; // 2.0.3, string
|
||||
data.append(info->raw.data, MAX_GAMEOBJECT_DATA);
|
||||
data << float(info->size); // go size
|
||||
for (uint32 i = 0; i < MAX_GAMEOBJECT_QUEST_ITEMS; ++i)
|
||||
data << uint32(info->questItems[i]); // itemId[6], quest drop
|
||||
|
||||
GameObjectQuestItemList const* items = sObjectMgr->GetGameObjectQuestItemList(entry);
|
||||
if (items)
|
||||
for (size_t i = 0; i < MAX_GAMEOBJECT_QUEST_ITEMS; ++i)
|
||||
data << (i < items->size() ? uint32((*items)[i]) : uint32(0));
|
||||
else
|
||||
for (size_t i = 0; i < MAX_GAMEOBJECT_QUEST_ITEMS; ++i)
|
||||
data << uint32(0);
|
||||
|
||||
SendPacket(&data);
|
||||
;//sLog->outDebug(LOG_FILTER_NETWORKIO, "WORLD: Sent SMSG_GAMEOBJECT_QUERY_RESPONSE");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1490,6 +1490,12 @@ void World::SetInitialWorldSettings()
|
|||
sLog->outString("Loading GameObject Addon Data...");
|
||||
sObjectMgr->LoadGameObjectAddons(); // must be after LoadGameObjectTemplate() and LoadGameobjects()
|
||||
|
||||
sLog->outString("Loading GameObject Quest Items...");
|
||||
sObjectMgr->LoadGameObjectQuestItems();
|
||||
|
||||
sLog->outString("Loading Creature Quest Items...");
|
||||
sObjectMgr->LoadCreatureQuestItems();
|
||||
|
||||
sLog->outString("Loading Creature Linked Respawn...");
|
||||
sObjectMgr->LoadLinkedRespawn(); // must be after LoadCreatures(), LoadGameObjects()
|
||||
|
||||
|
|
|
|||
|
|
@ -493,17 +493,11 @@ public:
|
|||
cInfo->ModMana = fields[69].GetFloat();
|
||||
cInfo->ModArmor = fields[70].GetFloat();
|
||||
cInfo->RacialLeader = fields[71].GetBool();
|
||||
cInfo->questItems[0] = fields[72].GetUInt32();
|
||||
cInfo->questItems[1] = fields[73].GetUInt32();
|
||||
cInfo->questItems[2] = fields[74].GetUInt32();
|
||||
cInfo->questItems[3] = fields[75].GetUInt32();
|
||||
cInfo->questItems[4] = fields[76].GetUInt32();
|
||||
cInfo->questItems[5] = fields[77].GetUInt32();
|
||||
cInfo->movementId = fields[78].GetUInt32();
|
||||
cInfo->RegenHealth = fields[79].GetBool();
|
||||
cInfo->MechanicImmuneMask = fields[80].GetUInt32();
|
||||
cInfo->flags_extra = fields[81].GetUInt32();
|
||||
cInfo->ScriptID = sObjectMgr->GetScriptId(fields[82].GetCString());
|
||||
cInfo->movementId = fields[72].GetUInt32();
|
||||
cInfo->RegenHealth = fields[73].GetBool();
|
||||
cInfo->MechanicImmuneMask = fields[74].GetUInt32();
|
||||
cInfo->flags_extra = fields[75].GetUInt32();
|
||||
cInfo->ScriptID = sObjectMgr->GetScriptId(fields[76].GetCString());
|
||||
|
||||
sObjectMgr->CheckCreatureTemplate(cInfo);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue