[10118] Check gameobject scale at loading (strict DB error filter)

This let avoid check scale value at it
This commit is contained in:
VladimirMangos 2010-06-29 10:55:19 +04:00
parent 969986a596
commit cd0bbabf9a
3 changed files with 9 additions and 4 deletions

View file

@ -6000,6 +6000,14 @@ void ObjectMgr::LoadGameobjectInfo()
if (!goInfo)
continue;
if (goInfo->size <= 0.0f) // prevent use too small scales
{
ERROR_DB_STRICT_LOG("Gameobject (Entry: %u GoType: %u) have too small size=%f",
goInfo->id, goInfo->type, goInfo->size);
const_cast<GameObjectInfo*>(goInfo)->size = DEFAULT_OBJECT_SCALE;
}
// some GO types have unused go template, check goInfo->displayId at GO spawn data loading or ignore
switch(goInfo->type)