Core/PacketIO: 9.1.5 updatefields and SMSG_UPDATE_OBJECT structure
Port From (https://github.com/TrinityCore/TrinityCore/commit/5c8a058120dcf2c3ff8592886cb842ca889e0411)
This commit is contained in:
@@ -2309,7 +2309,7 @@ namespace Game.Entities
|
||||
stmt.AddValue(index++, GetMaxHealth());
|
||||
|
||||
for (byte i = 0; i < (int)PowerType.MaxPerClass; ++i)
|
||||
stmt.AddValue(index++, GetMaxPower((PowerType)i));
|
||||
stmt.AddValue(index++, m_unitData.MaxPower[i]);
|
||||
|
||||
for (byte i = 0; i < (int)Stats.Max; ++i)
|
||||
stmt.AddValue(index++, GetStat((Stats)i));
|
||||
@@ -2317,14 +2317,14 @@ namespace Game.Entities
|
||||
for (int i = 0; i < (int)SpellSchools.Max; ++i)
|
||||
stmt.AddValue(index++, GetResistance((SpellSchools)i));
|
||||
|
||||
stmt.AddValue(index++, (float)m_activePlayerData.BlockPercentage);
|
||||
stmt.AddValue(index++, (float)m_activePlayerData.DodgePercentage);
|
||||
stmt.AddValue(index++, (float)m_activePlayerData.ParryPercentage);
|
||||
stmt.AddValue(index++, (float)m_activePlayerData.CritPercentage);
|
||||
stmt.AddValue(index++, (float)m_activePlayerData.RangedCritPercentage);
|
||||
stmt.AddValue(index++, (float)m_activePlayerData.SpellCritPercentage);
|
||||
stmt.AddValue(index++, (int)m_unitData.AttackPower);
|
||||
stmt.AddValue(index++, (int)m_unitData.RangedAttackPower);
|
||||
stmt.AddValue(index++, m_activePlayerData.BlockPercentage);
|
||||
stmt.AddValue(index++, m_activePlayerData.DodgePercentage);
|
||||
stmt.AddValue(index++, m_activePlayerData.ParryPercentage);
|
||||
stmt.AddValue(index++, m_activePlayerData.CritPercentage);
|
||||
stmt.AddValue(index++, m_activePlayerData.RangedCritPercentage);
|
||||
stmt.AddValue(index++, m_activePlayerData.SpellCritPercentage);
|
||||
stmt.AddValue(index++, m_unitData.AttackPower);
|
||||
stmt.AddValue(index++, m_unitData.RangedAttackPower);
|
||||
stmt.AddValue(index++, GetBaseSpellPowerBonus());
|
||||
stmt.AddValue(index, m_activePlayerData.CombatRatings[(int)CombatRating.ResiliencePlayerDamage]);
|
||||
|
||||
|
||||
@@ -7436,9 +7436,6 @@ namespace Game.Entities
|
||||
public void AddTrackCreatureFlag(uint flags) { SetUpdateFieldFlagValue(m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.TrackCreatureMask), flags); }
|
||||
public void RemoveTrackCreatureFlag(uint flags) { RemoveUpdateFieldFlagValue(m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.TrackCreatureMask), flags); }
|
||||
|
||||
public void AddTrackResourceFlag(uint index, uint flags) { SetUpdateFieldFlagValue(ref m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.TrackResourceMask, (int)index), flags); }
|
||||
public void RemoveTrackResourceFlag(uint index, uint flags) { RemoveUpdateFieldFlagValue(ref m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.TrackResourceMask, (int)index), flags); }
|
||||
|
||||
public void SetVersatilityBonus(float value) { SetUpdateFieldStatValue(m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.VersatilityBonus), value); }
|
||||
|
||||
public void ApplyModOverrideSpellPowerByAPPercent(float mod, bool apply) { ApplyModUpdateFieldValue(m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.OverrideSpellPowerByAPPercent), mod, apply); }
|
||||
|
||||
Reference in New Issue
Block a user