mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
[7908] Extract class data from creature_*_addon bytes0 fields, drop its, amd add unit_class field to creature_template.
Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
parent
39637858aa
commit
84464e5f3f
12 changed files with 65 additions and 16 deletions
|
|
@ -490,6 +490,12 @@ void ObjectMgr::LoadCreatureTemplates()
|
|||
continue;
|
||||
}
|
||||
|
||||
if(cInfo->unit_class != heroicInfo->unit_class)
|
||||
{
|
||||
sLog.outErrorDb("Creature (Entry: %u, class %u) has different `unit_class` in heroic mode (Entry: %u, class %u).",i, cInfo->unit_class, cInfo->HeroicEntry, heroicInfo->unit_class);
|
||||
continue;
|
||||
}
|
||||
|
||||
if(cInfo->npcflag != heroicInfo->npcflag)
|
||||
{
|
||||
sLog.outErrorDb("Creature (Entry: %u) has different `npcflag` in heroic mode (Entry: %u).",i,cInfo->HeroicEntry);
|
||||
|
|
@ -551,6 +557,9 @@ void ObjectMgr::LoadCreatureTemplates()
|
|||
if (!minfo)
|
||||
sLog.outErrorDb("Creature (Entry: %u) has non-existing modelId_H (%u)", cInfo->Entry, cInfo->DisplayID_H);
|
||||
|
||||
if (cInfo->unit_class && ((1 << (cInfo->unit_class-1)) & CLASSMASK_ALL_CREATURES) == 0)
|
||||
sLog.outErrorDb("Creature (Entry: %u) has invalid unit_class(%u) for creature_template", cInfo->Entry, cInfo->unit_class);
|
||||
|
||||
if(cInfo->dmgschool >= MAX_SPELL_SCHOOL)
|
||||
{
|
||||
sLog.outErrorDb("Creature (Entry: %u) has invalid spell school value (%u) in `dmgschool`",cInfo->Entry,cInfo->dmgschool);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue