Iron Walker Q

Looking in the data file, trigger amount is set to 5.5, not 5.0

Does this mean default speed Rook will always have the 1000 armor bonus?

1,462 views 4 replies
Reply #1 Top

Hrmm... answered my own question... it says 5, but you see the effect icon on Rook.

It triggers at any speed below 5.5 (rook's default speed is 5.4)

So the new question is, why does the description retrieve a value of 5, when the trigger is clearly set to 5.5?

Reply #2 Top

Yes.

I've got a fix for this that sets the speed requirement to < 5.4 from <= 5.5.  This could be included in the Uberfix, if there's demand for it.

The UI says 5, because it's using math.floor instead of string.format('%.1f') or whatever the 1 decimal floating point display string is.  This is fixed as well in the code I've got.

Reply #3 Top

If you just want a quick fix for this, paste this into a non-overridden Boot_Items.lua hook:

Code: c++
  1. Items.Item_Boot_070.GetTriggerAmount = function(self) return string.format('%.1f', Ability['Item_Boot_070'].TriggerAmount) end
  2. Ability.Item_Boot_070.TriggerAmount = 5.4
  3. Ability.Item_Boot_070.OnAuraPulse = function(self, unit, params)
  4.     if unit.Sync.MovementSpeed &gt;= self.TriggerAmount then
  5.         if Buff.HasBuff(unit, 'Item_Boot_070_Armor') then
  6.             Buff.RemoveBuff(unit, 'Item_Boot_070_Armor')
  7.         end
  8.     else
  9.         Buff.ApplyBuff(unit, 'Item_Boot_070_Armor', unit)
  10.     end
  11. end

 

Thanks for reminding me of this.  I had this code sitting in a test mod, but had forgot that it should probably be added to the Uberfix.  Gonna add it as an issue on the google code site.

Reply #4 Top

Optional percent-based fix that triggers below 90% of base speed (4.9, 5.4 and 5.7 depending on the demigod):

Code: c++
  1. Items.Item_Boot_070.GetTriggerAmount = function(self) return math.floor(Ability['Item_Boot_070'].TriggerPercent * 100) end
  2. Items.Item_Boot_070.Tooltip.ChanceOnHit = 'Whenever Movement Speed is reduced below [GetTriggerAmount]% of base, Armor is increased by [GetArmorBonus].'
  3. Ability.Item_Boot_070.TriggerPercent = 0.9
  4. Ability.Item_Boot_070.OnAuraPulse = function(self, unit, params)
  5.     if unit.Sync.MovementSpeed &gt;= unit:GetBlueprint().Physics.Speed * self.TriggerPercent then
  6.         if Buff.HasBuff(unit, 'Item_Boot_070_Armor') then
  7.             Buff.RemoveBuff(unit, 'Item_Boot_070_Armor')
  8.         end
  9.     else
  10.         Buff.ApplyBuff(unit, 'Item_Boot_070_Armor', unit)
  11.     end
  12. end