mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-20 09:17:36 +01:00
Core/Datastores: hardcode the return value of DB2Manager::GetEmptyAnimStateID() to match the expected client value
This is a necessary change for classic clients as the AnimationdData storage does not have the retail data needed to match that expected size
This commit is contained in:
@@ -1760,7 +1760,8 @@ std::vector<DB2Manager::HotfixOptionalData> const* DB2Manager::GetHotfixOptional
|
||||
|
||||
uint32 DB2Manager::GetEmptyAnimStateID() const
|
||||
{
|
||||
return sAnimationDataStore.GetNumRows();
|
||||
//return sAnimationDataStore.GetNumRows();
|
||||
return 1772; // the Classic client expects the retail storage size so we have to hardcode the value
|
||||
}
|
||||
|
||||
void DB2Manager::InsertNewHotfix(uint32 tableHash, uint32 recordId)
|
||||
|
||||
@@ -609,9 +609,7 @@ bool Creature::UpdateEntry(uint32 entry, CreatureData const* data /*= nullptr*/,
|
||||
|
||||
ReplaceAllDynamicFlags(UNIT_DYNFLAG_NONE);
|
||||
|
||||
//SetUpdateFieldValue(m_values.ModifyValue(&Unit::m_unitData).ModifyValue(&UF::UnitData::StateAnimID), sDB2Manager.GetEmptyAnimStateID());
|
||||
constexpr uint32 stateAnimId = 1772; // the WotLK classic client expects the retail AnimationEntry db2 storage size so we have to hardcode it for the time being
|
||||
SetUpdateFieldValue(m_values.ModifyValue(&Unit::m_unitData).ModifyValue(&UF::UnitData::StateAnimID), stateAnimId);
|
||||
SetUpdateFieldValue(m_values.ModifyValue(&Unit::m_unitData).ModifyValue(&UF::UnitData::StateAnimID), sDB2Manager.GetEmptyAnimStateID());
|
||||
|
||||
SetCanDualWield(cInfo->flags_extra & CREATURE_FLAG_EXTRA_USE_OFFHAND_ATTACK);
|
||||
|
||||
|
||||
@@ -1052,9 +1052,7 @@ bool GameObject::Create(uint32 entry, Map* map, Position const& pos, QuaternionD
|
||||
SetGoState(goState);
|
||||
SetGoArtKit(artKit);
|
||||
|
||||
//SetUpdateFieldValue(m_values.ModifyValue(&GameObject::m_gameObjectData).ModifyValue(&UF::GameObjectData::SpawnTrackingStateAnimID), sDB2Manager.GetEmptyAnimStateID());
|
||||
constexpr uint32 spawnTrackingAnimId = 1772; // the WotLK classic client expects the retail AnimationEntry db2 storage size so we have to hardcode it for the time being
|
||||
SetUpdateFieldValue(m_values.ModifyValue(&GameObject::m_gameObjectData).ModifyValue(&UF::GameObjectData::SpawnTrackingStateAnimID), spawnTrackingAnimId);
|
||||
SetUpdateFieldValue(m_values.ModifyValue(&GameObject::m_gameObjectData).ModifyValue(&UF::GameObjectData::SpawnTrackingStateAnimID), sDB2Manager.GetEmptyAnimStateID());
|
||||
|
||||
switch (goInfo->type)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user