Core/CreatureAI: Disable TotemAI from database
Disable TotemAI set in creature_template, triggering an assert when spawning the creature
This commit is contained in:
1 parent
c214b701b9
commit
2507d601b7
1 file changed
+6
@@ -845,6 +845,12 @@ void ObjectMgr::CheckCreatureTemplate(CreatureTemplate const* cInfo)
|
||||
ok = true;
|
||||
}
|
||||
|
||||
if (cInfo->AIName == "TotemAI")
|
||||
{
|
||||
TC_LOG_ERROR("sql.sql", "Creature (Entry: %u) has not-allowed `AIName` '%s' set, removing", cInfo->Entry, cInfo->AIName.c_str());
|
||||
const_cast<CreatureTemplate*>(cInfo)->AIName.clear();
|
||||
}
|
||||
|
||||
if (!cInfo->AIName.empty() && !sCreatureAIRegistry->HasItem(cInfo->AIName))
|
||||
{
|
||||
TC_LOG_ERROR("sql.sql", "Creature (Entry: %u) has non-registered `AIName` '%s' set, removing", cInfo->Entry, cInfo->AIName.c_str());
|
||||
|
||||
Reference in new issue
Block a user