warscript 0.0.1-dev.524fae9 → 0.0.1-dev.5354486

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. package/decl/native.d.ts +1 -0
  2. package/engine/ability-type-extended-tooltip.d.ts +8 -0
  3. package/engine/ability-type-extended-tooltip.lua +44 -0
  4. package/engine/behaviour/ability/emulate-impact.d.ts +14 -0
  5. package/engine/behaviour/ability/emulate-impact.lua +74 -1
  6. package/engine/behaviour/ability/instant-impact.d.ts +12 -1
  7. package/engine/behaviour/ability/instant-impact.lua +17 -2
  8. package/engine/behaviour/ability.d.ts +6 -0
  9. package/engine/behaviour/ability.lua +64 -8
  10. package/engine/buff.d.ts +53 -44
  11. package/engine/buff.lua +254 -227
  12. package/engine/internal/object-data/returned-melee-damage-factor.lua +21 -0
  13. package/engine/internal/unit/ability.lua +19 -15
  14. package/engine/internal/unit/bonus.d.ts +3 -0
  15. package/engine/internal/unit/bonus.lua +11 -0
  16. package/engine/internal/unit+ability.lua +10 -0
  17. package/engine/internal/unit.lua +3 -0
  18. package/engine/object-data/entry/ability-type/barrage.d.ts +12 -0
  19. package/engine/object-data/entry/ability-type/barrage.lua +52 -0
  20. package/engine/object-data/entry/ability-type/blank-configurable.d.ts +0 -3
  21. package/engine/object-data/entry/ability-type/blank-configurable.lua +2 -32
  22. package/engine/object-data/entry/ability-type/blank-passive-with-cooldown.d.ts +23 -0
  23. package/engine/object-data/entry/ability-type/blank-passive-with-cooldown.lua +112 -0
  24. package/engine/object-data/entry/ability-type/channel.d.ts +2 -2
  25. package/engine/object-data/entry/ability-type/channel.lua +3 -3
  26. package/engine/object-data/entry/ability-type/exhume-corpses.d.ts +14 -0
  27. package/engine/object-data/entry/ability-type/exhume-corpses.lua +40 -0
  28. package/engine/object-data/entry/ability-type.d.ts +8 -2
  29. package/engine/object-data/entry/ability-type.lua +42 -3
  30. package/engine/object-data/entry/buff-type/applicable.lua +10 -3
  31. package/engine/object-data/entry/unit-type.d.ts +10 -0
  32. package/engine/object-data/entry/unit-type.lua +34 -20
  33. package/engine/random.lua +1 -1
  34. package/engine/standard/fields/ability.d.ts +2 -2
  35. package/engine/standard/fields/ability.lua +2 -2
  36. package/package.json +2 -2
  37. package/utility/arrays.d.ts +6 -1
  38. package/utility/arrays.lua +5 -0
  39. package/engine/internal/unit/pseudo-passive-abilities.lua +0 -11
  40. /package/engine/internal/{unit/pseudo-passive-abilities.d.ts → object-data/returned-melee-damage-factor.d.ts} +0 -0
package/engine/buff.lua CHANGED
@@ -14,6 +14,7 @@ local Unit = ____unit.Unit
14
14
  local ____applicable = require("engine.object-data.entry.buff-type.applicable")
15
15
  local internalApplyBuff = ____applicable.internalApplyBuff
16
16
  local removeBuff = ____applicable.removeBuff
17
+ local removeBuffApplicator = ____applicable.removeBuffApplicator
17
18
  local ____ability = require("engine.internal.ability")
18
19
  local Ability = ____ability.Ability
19
20
  local UnitAbility = ____ability.UnitAbility
@@ -58,6 +59,9 @@ local ____ability = require("engine.behaviour.ability")
58
59
  local AbilityBehavior = ____ability.AbilityBehavior
59
60
  local ____records = require("utility.records")
60
61
  local sortedKeysUnnested = ____records.sortedKeysUnnested
62
+ local ____sound = require("core.types.sound")
63
+ local Sound3D = ____sound.Sound3D
64
+ local SoundSettings = ____sound.SoundSettings
61
65
  local getUnitAbility = BlzGetUnitAbility
62
66
  local stringValueByBuffTypeIdByFieldId = postcompile(function()
63
67
  local stringValueByBuffTypeIdByFieldId = {}
@@ -112,6 +116,7 @@ local buffParametersKeys = {
112
116
  missProbability = true,
113
117
  damageFactor = true,
114
118
  receivedDamageFactor = true,
119
+ returnedMeleeDamageFactor = true,
115
120
  receivedMagicDamageFactor = true,
116
121
  durationIncreaseOnAutoAttack = true,
117
122
  maximumDuration = true,
@@ -131,6 +136,7 @@ local buffParametersKeys = {
131
136
  maximumDamageAbsorbed = true,
132
137
  destroysOnMaximumDamageAbsorbed = true,
133
138
  uniqueGroup = true,
139
+ destructionSoundPresetId = true,
134
140
  damageOnExpiration = true,
135
141
  healingOnExpiration = true,
136
142
  killsOnExpiration = true,
@@ -206,6 +212,7 @@ local buffNumberParameters = {
206
212
  "maxManaIncrease",
207
213
  "damageFactor",
208
214
  "receivedDamageFactor",
215
+ "returnedMeleeDamageFactor",
209
216
  "maximumAutoAttackCount",
210
217
  "maximumDamageDealtEventCount",
211
218
  "maximumDamageReceivedEventCount",
@@ -258,17 +265,17 @@ local function expireBuff(buff)
258
265
  return
259
266
  end
260
267
  buff[100] = 2
261
- local remainingDamageOverDuration = buff[113] or 0
262
- local remainingHealingOverDuration = buff[113] or 0
268
+ local remainingDamageOverDuration = buff[114] or 0
269
+ local remainingHealingOverDuration = buff[114] or 0
263
270
  if remainingDamageOverDuration ~= 0 or remainingHealingOverDuration ~= 0 then
264
271
  buff:flashSpecialEffect()
265
272
  if remainingDamageOverDuration ~= 0 then
266
273
  (buff[102] or buff[101]):damageTarget(buff[101], remainingDamageOverDuration)
267
- buff[113] = nil
274
+ buff[114] = nil
268
275
  end
269
276
  if remainingHealingOverDuration ~= 0 then
270
277
  (buff[102] or buff[101]):healTarget(buff[101], remainingHealingOverDuration)
271
- buff[118] = nil
278
+ buff[119] = nil
272
279
  end
273
280
  end
274
281
  Timer:run(destroyBuff, buff)
@@ -276,8 +283,8 @@ local function expireBuff(buff)
276
283
  end
277
284
  local function buffDamageIntervalInitialTimerCallback(buff)
278
285
  buffDamageIntervalTimerCallback(buff)
279
- local timer = buff[114]
280
- local damageInterval = buff[112]
286
+ local timer = buff[115]
287
+ local damageInterval = buff[113]
281
288
  if timer ~= nil and damageInterval ~= nil and damageInterval > 0 then
282
289
  timer:start(damageInterval, true, buffDamageIntervalTimerCallback, buff)
283
290
  end
@@ -285,43 +292,43 @@ end
285
292
  buffDamageIntervalTimerCallback = function(buff)
286
293
  buff:flashSpecialEffect()
287
294
  local source = buff[102] or buff[101]
288
- local remainingDamageOverDuration = buff[113] or 0
295
+ local remainingDamageOverDuration = buff[114] or 0
289
296
  if remainingDamageOverDuration ~= 0 then
290
- local damageInterval = buff[112] or 0
297
+ local damageInterval = buff[113] or 0
291
298
  if damageInterval ~= 0 then
292
299
  local damage = remainingDamageOverDuration / (1 + buff.remainingDuration / damageInterval)
293
300
  source:damageTarget(buff[101], damage)
294
- buff[113] = remainingDamageOverDuration - damage
301
+ buff[114] = remainingDamageOverDuration - damage
295
302
  end
296
303
  end
297
- local damagePerInterval = buff[111] or 0
304
+ local damagePerInterval = buff[112] or 0
298
305
  if remainingDamageOverDuration == 0 or damagePerInterval ~= 0 then
299
306
  source:damageTarget(buff[101], damagePerInterval)
300
307
  end
301
308
  end
302
309
  local function buffHealingIntervalInitialTimerCallback(buff)
303
310
  buffHealingIntervalTimerCallback(buff)
304
- local timer = buff[119]
305
- local healingInterval = buff[117]
311
+ local timer = buff[120]
312
+ local healingInterval = buff[118]
306
313
  if timer ~= nil and healingInterval ~= nil and healingInterval > 0 then
307
314
  timer:start(healingInterval, true, buffHealingIntervalTimerCallback, buff)
308
315
  end
309
316
  end
310
317
  buffHealingIntervalTimerCallback = function(buff)
311
- if buff[117] ~= buff[112] then
318
+ if buff[118] ~= buff[113] then
312
319
  buff:flashSpecialEffect()
313
320
  end
314
321
  local source = buff[102] or buff[101]
315
- local remainingHealingOverDuration = buff[118] or 0
322
+ local remainingHealingOverDuration = buff[119] or 0
316
323
  if remainingHealingOverDuration ~= 0 then
317
- local healingInterval = buff[117] or 0
324
+ local healingInterval = buff[118] or 0
318
325
  if healingInterval ~= 0 then
319
326
  local healing = remainingHealingOverDuration / (1 + buff.remainingDuration / healingInterval)
320
327
  source:healTarget(buff[101], healing)
321
- buff[118] = remainingHealingOverDuration - healing
328
+ buff[119] = remainingHealingOverDuration - healing
322
329
  end
323
330
  end
324
- local healingPerInterval = buff[116] or 0
331
+ local healingPerInterval = buff[117] or 0
325
332
  if remainingHealingOverDuration == 0 or healingPerInterval ~= 0 then
326
333
  source:healTarget(buff[101], healingPerInterval)
327
334
  end
@@ -401,7 +408,7 @@ function Buff.prototype.____constructor(self, _unit, typeIdOrTypeIds, polarityOr
401
408
  local missProbability = parameters and parameters.missProbability or defaultParameters.missProbability
402
409
  if missProbability ~= nil then
403
410
  missProbability = resolveNumberValue(ability, level, missProbability)
404
- self[146] = missProbability
411
+ self[147] = missProbability
405
412
  end
406
413
  local buffByTypeId = buffByTypeIdByUnit[_unit]
407
414
  if buffByTypeId == nil then
@@ -446,17 +453,18 @@ function Buff.prototype.____constructor(self, _unit, typeIdOrTypeIds, polarityOr
446
453
  self[102] = source
447
454
  self[103] = duration or 0
448
455
  self[104] = uniqueGroup
449
- self[105] = BlzGetAbilityStringLevelField(self.handle, ABILITY_SLF_EFFECT, 0)
450
- self[106] = BlzGetAbilityStringLevelField(self.handle, ABILITY_SLF_SPECIAL, 0)
456
+ self[105] = parameters and parameters.destructionSoundPresetId or defaultParameters and defaultParameters.destructionSoundPresetId
457
+ self[106] = BlzGetAbilityStringLevelField(self.handle, ABILITY_SLF_EFFECT, 0)
458
+ self[107] = BlzGetAbilityStringLevelField(self.handle, ABILITY_SLF_SPECIAL, 0)
451
459
  if parameters ~= nil or (next(defaultParameters)) ~= nil then
452
460
  for ____, buffBooleanParameter in ipairs(buffBooleanParameters) do
453
- local ____ability_24 = ability
454
- local ____level_25 = level
455
- local ____temp_23 = parameters and parameters[buffBooleanParameter]
456
- if ____temp_23 == nil then
457
- ____temp_23 = defaultParameters[buffBooleanParameter]
461
+ local ____ability_28 = ability
462
+ local ____level_29 = level
463
+ local ____temp_27 = parameters and parameters[buffBooleanParameter]
464
+ if ____temp_27 == nil then
465
+ ____temp_27 = defaultParameters[buffBooleanParameter]
458
466
  end
459
- if resolveBooleanValue(____ability_24, ____level_25, ____temp_23) then
467
+ if resolveBooleanValue(____ability_28, ____level_29, ____temp_27) then
460
468
  self[buffBooleanParameter] = true
461
469
  end
462
470
  end
@@ -472,11 +480,11 @@ function Buff.prototype.____constructor(self, _unit, typeIdOrTypeIds, polarityOr
472
480
  end
473
481
  local maximumDuration = parameters and parameters.maximumDuration or defaultParameters.maximumDuration
474
482
  if maximumDuration ~= nil then
475
- self[108] = resolveNumberValue(ability, level, maximumDuration)
483
+ self[109] = resolveNumberValue(ability, level, maximumDuration)
476
484
  end
477
485
  local maximumRemainingDuration = parameters and parameters.maximumRemainingDuration or defaultParameters.maximumRemainingDuration
478
486
  if maximumRemainingDuration ~= nil then
479
- self[109] = resolveNumberValue(ability, level, maximumRemainingDuration)
487
+ self[110] = resolveNumberValue(ability, level, maximumRemainingDuration)
480
488
  end
481
489
  local parametersAbilityTypeIds = parameters and parameters.abilityTypeIds or defaultParameters.abilityTypeIds
482
490
  if parametersAbilityTypeIds ~= nil then
@@ -539,7 +547,7 @@ function Buff.prototype.____constructor(self, _unit, typeIdOrTypeIds, polarityOr
539
547
  end
540
548
  function Buff.prototype.onAbilityGained(self, ability)
541
549
  if __TS__InstanceOf(ability, UnitAbility) then
542
- local abilityCooldownModifier = self[148]
550
+ local abilityCooldownModifier = self[149]
543
551
  if abilityCooldownModifier then
544
552
  COOLDOWN_ABILITY_FLOAT_LEVEL_FIELD:applyModifier(ability, abilityCooldownModifier)
545
553
  end
@@ -547,7 +555,7 @@ function Buff.prototype.onAbilityGained(self, ability)
547
555
  end
548
556
  function Buff.prototype.onAbilityLost(self, ability)
549
557
  if __TS__InstanceOf(ability, UnitAbility) then
550
- local abilityCooldownModifier = self[148]
558
+ local abilityCooldownModifier = self[149]
551
559
  if abilityCooldownModifier then
552
560
  COOLDOWN_ABILITY_FLOAT_LEVEL_FIELD:removeModifier(ability, abilityCooldownModifier)
553
561
  end
@@ -555,7 +563,7 @@ function Buff.prototype.onAbilityLost(self, ability)
555
563
  end
556
564
  function Buff.prototype.flashEffect(self, widgetOrXOrParametersOrDuration, yOrParametersOrDuration, parametersOrDuration)
557
565
  self:flash(
558
- self[105],
566
+ self[106],
559
567
  stringValueByBuffTypeIdByFieldId[fourCC("feft")][self.typeId] or "origin",
560
568
  widgetOrXOrParametersOrDuration,
561
569
  yOrParametersOrDuration,
@@ -564,7 +572,7 @@ function Buff.prototype.flashEffect(self, widgetOrXOrParametersOrDuration, yOrPa
564
572
  end
565
573
  function Buff.prototype.flashSpecialEffect(self, widgetOrXOrParametersOrDuration, yOrParametersOrDuration, parametersOrDuration)
566
574
  self:flash(
567
- self[106],
575
+ self[107],
568
576
  stringValueByBuffTypeIdByFieldId[fourCC("fspt")][self.typeId] or "origin",
569
577
  widgetOrXOrParametersOrDuration,
570
578
  yOrParametersOrDuration,
@@ -576,19 +584,19 @@ function Buff.prototype.flash(self, modelPath, attachmentPoint, widgetOrXOrParam
576
584
  Effect:flash(modelPath, widgetOrXOrParametersOrDuration, yOrParametersOrDuration, parametersOrDuration)
577
585
  else
578
586
  local isWidgetProvided = __TS__InstanceOf(widgetOrXOrParametersOrDuration, Unit) or __TS__InstanceOf(widgetOrXOrParametersOrDuration, Item) or __TS__InstanceOf(widgetOrXOrParametersOrDuration, Destructable)
579
- local ____Effect_40 = Effect
580
- local ____Effect_flash_41 = Effect.flash
581
- local ____array_39 = __TS__SparseArrayNew(modelPath, isWidgetProvided and widgetOrXOrParametersOrDuration or self._unit, attachmentPoint)
582
- local ____isWidgetProvided_38
587
+ local ____Effect_44 = Effect
588
+ local ____Effect_flash_45 = Effect.flash
589
+ local ____array_43 = __TS__SparseArrayNew(modelPath, isWidgetProvided and widgetOrXOrParametersOrDuration or self._unit, attachmentPoint)
590
+ local ____isWidgetProvided_42
583
591
  if isWidgetProvided then
584
- ____isWidgetProvided_38 = yOrParametersOrDuration
592
+ ____isWidgetProvided_42 = yOrParametersOrDuration
585
593
  else
586
- ____isWidgetProvided_38 = widgetOrXOrParametersOrDuration
594
+ ____isWidgetProvided_42 = widgetOrXOrParametersOrDuration
587
595
  end
588
- __TS__SparseArrayPush(____array_39, ____isWidgetProvided_38)
589
- ____Effect_flash_41(
590
- ____Effect_40,
591
- __TS__SparseArraySpread(____array_39)
596
+ __TS__SparseArrayPush(____array_43, ____isWidgetProvided_42)
597
+ ____Effect_flash_45(
598
+ ____Effect_44,
599
+ __TS__SparseArraySpread(____array_43)
592
600
  )
593
601
  end
594
602
  end
@@ -615,19 +623,25 @@ function Buff.prototype.onDestroy(self)
615
623
  check(self[100] ~= 0, "Cannot destroy a buff that has not finished creating yet.")
616
624
  self[100] = 2
617
625
  local unit = self._unit
626
+ local destructionSoundPresetId = self[105]
627
+ if destructionSoundPresetId ~= nil then
628
+ Sound3D:playFromLabel(destructionSoundPresetId, SoundSettings.Ability, unit)
629
+ end
618
630
  if getUnitAbility(unit.handle, self.typeId) == self.handle then
619
631
  removeBuff(unit.handle, self.typeId)
632
+ else
633
+ removeBuffApplicator(unit.handle, self.typeId)
620
634
  end
621
635
  buffByTypeIdByUnit[unit][self.typeId] = nil
622
- local healingIntervalTimer = self[119]
636
+ local healingIntervalTimer = self[120]
623
637
  if healingIntervalTimer ~= nil then
624
638
  healingIntervalTimer:destroy()
625
- self[119] = nil
639
+ self[120] = nil
626
640
  end
627
- local damageIntervalTimer = self[114]
641
+ local damageIntervalTimer = self[115]
628
642
  if damageIntervalTimer ~= nil then
629
643
  damageIntervalTimer:destroy()
630
- self[114] = nil
644
+ self[115] = nil
631
645
  end
632
646
  if self._timer ~= nil then
633
647
  self._timer:destroy()
@@ -637,25 +651,25 @@ function Buff.prototype.onDestroy(self)
637
651
  behavior:destroy()
638
652
  end
639
653
  end
640
- local previousAbilityCooldownModifier = self[148]
654
+ local previousAbilityCooldownModifier = self[149]
641
655
  if previousAbilityCooldownModifier then
642
656
  for ____, ability in ipairs(self._unit.abilities) do
643
657
  COOLDOWN_ABILITY_FLOAT_LEVEL_FIELD:removeModifier(ability, previousAbilityCooldownModifier)
644
658
  end
645
659
  end
646
- if self[143] then
660
+ if self[144] then
647
661
  unit:decrementInvulnerabilityCounter()
648
662
  end
649
- if self[142] then
663
+ if self[143] then
650
664
  unit:decrementDisableAutoAttackCounter()
651
665
  end
652
- if self[140] then
653
- if self[141] then
666
+ if self[141] then
667
+ if self[142] then
654
668
  unit:decrementForceStunCounter()
655
669
  end
656
670
  unit:decrementStunCounter()
657
671
  end
658
- if self[139] then
672
+ if self[140] then
659
673
  unit:decrementGhostCounter()
660
674
  end
661
675
  if self._abilityTypeIds ~= nil then
@@ -692,8 +706,8 @@ function Buff.apply(self, ...)
692
706
  end
693
707
  end
694
708
  function Buff.getByTypeId(self, unit, typeId)
695
- local ____opt_42 = buffByTypeIdByUnit[unit]
696
- local buff = ____opt_42 and ____opt_42[typeId]
709
+ local ____opt_46 = buffByTypeIdByUnit[unit]
710
+ local buff = ____opt_46 and ____opt_46[typeId]
697
711
  if __TS__InstanceOf(buff, self) then
698
712
  return buff
699
713
  end
@@ -703,40 +717,40 @@ function Buff.prototype.onDispel(self, source)
703
717
  end
704
718
  function Buff.prototype.onExpiration(self)
705
719
  local unit = self.unit
706
- if self[120] ~= nil then
707
- (self[102] or unit):damageTarget(unit, self[120] or 0)
708
- end
709
720
  if self[121] ~= nil then
710
- (self[102] or unit):healTarget(unit, self[120] or 0)
721
+ (self[102] or unit):damageTarget(unit, self[121] or 0)
711
722
  end
712
- if self[145] then
723
+ if self[122] ~= nil then
724
+ (self[102] or unit):healTarget(unit, self[121] or 0)
725
+ end
726
+ if self[146] then
713
727
  unit:explode()
714
- elseif self[144] then
728
+ elseif self[145] then
715
729
  unit:kill()
716
730
  end
717
731
  end
718
732
  function Buff.prototype.onDeath(self, source)
719
733
  local unit = self.unit
720
- if self[122] ~= nil then
734
+ if self[123] ~= nil then
721
735
  damageArea(
722
736
  self[102] or unit,
723
- self[122],
737
+ self[123],
724
738
  unit.x,
725
739
  unit.y,
740
+ self[125] or 0,
726
741
  self[124] or 0,
727
- self[123] or 0,
742
+ self[127] or 0,
728
743
  self[126] or 0,
729
- self[125] or 0,
730
- self[128] or 0,
731
- self[127] or 0
744
+ self[129] or 0,
745
+ self[128] or 0
732
746
  )
733
747
  end
734
748
  end
735
749
  function Buff.prototype.onDamageDealt(self, target, event)
736
750
  if event.isAttack then
737
- if self[107] ~= nil then
738
- local durationIncrease = self[107]
739
- local maximumDuration = self[108] or 0
751
+ if self[108] ~= nil then
752
+ local durationIncrease = self[108]
753
+ local maximumDuration = self[109] or 0
740
754
  if maximumDuration > 0 then
741
755
  durationIncrease = min(
742
756
  durationIncrease,
@@ -744,43 +758,43 @@ function Buff.prototype.onDamageDealt(self, target, event)
744
758
  )
745
759
  end
746
760
  local remainingDuration = self.remainingDuration + durationIncrease
747
- local maximumRemainingDuration = self[109] or 0
761
+ local maximumRemainingDuration = self[110] or 0
748
762
  if maximumRemainingDuration > 0 then
749
763
  remainingDuration = min(remainingDuration, maximumRemainingDuration)
750
764
  end
751
765
  self.remainingDuration = remainingDuration
752
766
  end
753
- local autoAttackCount = (self[129] or 0) + 1
754
- self[129] = autoAttackCount
755
- if autoAttackCount == self[130] then
767
+ local autoAttackCount = (self[130] or 0) + 1
768
+ self[130] = autoAttackCount
769
+ if autoAttackCount == self[131] then
756
770
  self:destroy()
757
771
  end
758
772
  end
759
773
  if event.originalAmount ~= 0 then
760
- local damageDealtEventCount = (self[131] or 0) + 1
761
- self[131] = damageDealtEventCount
762
- if damageDealtEventCount == self[132] then
774
+ local damageDealtEventCount = (self[132] or 0) + 1
775
+ self[132] = damageDealtEventCount
776
+ if damageDealtEventCount == self[133] then
763
777
  self:destroy()
764
778
  end
765
779
  end
766
780
  end
767
781
  function Buff.prototype.onDamageReceived(self, source, event)
768
782
  if event.originalAmount ~= 0 then
769
- local absorbedDamage = min(event.amount * (self[135] or 1), (self[136] or 0) - (self[137] or 0))
783
+ local absorbedDamage = min(event.amount * (self[136] or 1), (self[137] or 0) - (self[138] or 0))
770
784
  if absorbedDamage > 0 then
771
785
  event.amount = event.amount - absorbedDamage
772
- self[137] = (self[137] or 0) + absorbedDamage
773
- local ____self__138_44 = self[138]
774
- if ____self__138_44 == nil then
775
- ____self__138_44 = true
786
+ self[138] = (self[138] or 0) + absorbedDamage
787
+ local ____self__139_48 = self[139]
788
+ if ____self__139_48 == nil then
789
+ ____self__139_48 = true
776
790
  end
777
- if ____self__138_44 and self[137] >= (self[136] or 0) then
791
+ if ____self__139_48 and self[138] >= (self[137] or 0) then
778
792
  self:destroy()
779
793
  end
780
794
  end
781
- local damageReceivedEventCount = (self[133] or 0) + 1
782
- self[133] = damageReceivedEventCount
783
- if damageReceivedEventCount == self[134] then
795
+ local damageReceivedEventCount = (self[134] or 0) + 1
796
+ self[134] = damageReceivedEventCount
797
+ if damageReceivedEventCount == self[135] then
784
798
  self:destroy()
785
799
  end
786
800
  end
@@ -807,13 +821,13 @@ __TS__SetDescriptor(
807
821
  "remainingDamageOverDuration",
808
822
  {
809
823
  get = function(self)
810
- return self[113] or 0
824
+ return self[114] or 0
811
825
  end,
812
826
  set = function(self, remainingDamageOverDuration)
813
- local remainingDamageOverDurationDelta = remainingDamageOverDuration - (self[113] or 0)
814
- self[113] = remainingDamageOverDuration ~= 0 and remainingDamageOverDuration or nil
815
- local damageOverDuration = (self[110] or 0) + remainingDamageOverDurationDelta
816
- self[110] = damageOverDuration ~= 0 and damageOverDuration or nil
827
+ local remainingDamageOverDurationDelta = remainingDamageOverDuration - (self[114] or 0)
828
+ self[114] = remainingDamageOverDuration ~= 0 and remainingDamageOverDuration or nil
829
+ local damageOverDuration = (self[111] or 0) + remainingDamageOverDurationDelta
830
+ self[111] = damageOverDuration ~= 0 and damageOverDuration or nil
817
831
  end
818
832
  },
819
833
  true
@@ -823,13 +837,13 @@ __TS__SetDescriptor(
823
837
  "damageOverDuration",
824
838
  {
825
839
  get = function(self)
826
- return self[110] or 0
840
+ return self[111] or 0
827
841
  end,
828
842
  set = function(self, damageOverDuration)
829
- local damageOverDurationDelta = damageOverDuration - (self[110] or 0)
830
- self[110] = damageOverDuration ~= 0 and damageOverDuration or nil
831
- local remainingDamageOverDuration = (self[113] or 0) + damageOverDurationDelta
832
- self[113] = remainingDamageOverDuration ~= 0 and remainingDamageOverDuration or nil
843
+ local damageOverDurationDelta = damageOverDuration - (self[111] or 0)
844
+ self[111] = damageOverDuration ~= 0 and damageOverDuration or nil
845
+ local remainingDamageOverDuration = (self[114] or 0) + damageOverDurationDelta
846
+ self[114] = remainingDamageOverDuration ~= 0 and remainingDamageOverDuration or nil
833
847
  end
834
848
  },
835
849
  true
@@ -839,10 +853,10 @@ __TS__SetDescriptor(
839
853
  "damagePerInterval",
840
854
  {
841
855
  get = function(self)
842
- return self[111] or 0
856
+ return self[112] or 0
843
857
  end,
844
858
  set = function(self, damagePerInterval)
845
- self[111] = damagePerInterval ~= 0 and damagePerInterval or nil
859
+ self[112] = damagePerInterval ~= 0 and damagePerInterval or nil
846
860
  end
847
861
  },
848
862
  true
@@ -852,25 +866,25 @@ __TS__SetDescriptor(
852
866
  "damageInterval",
853
867
  {
854
868
  get = function(self)
855
- return self[112] or 0
869
+ return self[113] or 0
856
870
  end,
857
871
  set = function(self, damageInterval)
858
872
  if damageInterval <= 0 then
859
- self[112] = damageInterval ~= 0 and damageInterval or nil
860
- local timer = self[114]
873
+ self[113] = damageInterval ~= 0 and damageInterval or nil
874
+ local timer = self[115]
861
875
  if timer ~= nil then
862
876
  timer:destroy()
863
- self[114] = nil
877
+ self[115] = nil
864
878
  end
865
879
  return
866
880
  end
867
- self[112] = damageInterval
868
- local ____opt_45 = self._timer
869
- local elapsed = ____opt_45 and ____opt_45.elapsed or 0
870
- local timer = self[114]
881
+ self[113] = damageInterval
882
+ local ____opt_49 = self._timer
883
+ local elapsed = ____opt_49 and ____opt_49.elapsed or 0
884
+ local timer = self[115]
871
885
  if timer == nil then
872
886
  timer = Timer:create()
873
- self[114] = timer
887
+ self[115] = timer
874
888
  end
875
889
  local initialDelay = damageInterval - (elapsed >= damageInterval and math.fmod(elapsed, damageInterval) or elapsed)
876
890
  if initialDelay == damageInterval then
@@ -887,13 +901,13 @@ __TS__SetDescriptor(
887
901
  "remainingHealingOverDuration",
888
902
  {
889
903
  get = function(self)
890
- return self[118] or 0
904
+ return self[119] or 0
891
905
  end,
892
906
  set = function(self, remainingHealingOverDuration)
893
- local remainingHealingOverDurationDelta = remainingHealingOverDuration - (self[118] or 0)
894
- self[113] = remainingHealingOverDuration ~= 0 and remainingHealingOverDuration or nil
895
- local healingOverDuration = (self[115] or 0) + remainingHealingOverDurationDelta
896
- self[115] = healingOverDuration ~= 0 and healingOverDuration or nil
907
+ local remainingHealingOverDurationDelta = remainingHealingOverDuration - (self[119] or 0)
908
+ self[114] = remainingHealingOverDuration ~= 0 and remainingHealingOverDuration or nil
909
+ local healingOverDuration = (self[116] or 0) + remainingHealingOverDurationDelta
910
+ self[116] = healingOverDuration ~= 0 and healingOverDuration or nil
897
911
  end
898
912
  },
899
913
  true
@@ -903,13 +917,13 @@ __TS__SetDescriptor(
903
917
  "healingOverDuration",
904
918
  {
905
919
  get = function(self)
906
- return self[115] or 0
920
+ return self[116] or 0
907
921
  end,
908
922
  set = function(self, healingOverDuration)
909
- local healingOverDurationDelta = healingOverDuration - (self[115] or 0)
910
- self[115] = healingOverDuration ~= 0 and healingOverDuration or nil
911
- local remainingHealingOverDuration = (self[118] or 0) + healingOverDurationDelta
912
- self[118] = remainingHealingOverDuration ~= 0 and remainingHealingOverDuration or nil
923
+ local healingOverDurationDelta = healingOverDuration - (self[116] or 0)
924
+ self[116] = healingOverDuration ~= 0 and healingOverDuration or nil
925
+ local remainingHealingOverDuration = (self[119] or 0) + healingOverDurationDelta
926
+ self[119] = remainingHealingOverDuration ~= 0 and remainingHealingOverDuration or nil
913
927
  end
914
928
  },
915
929
  true
@@ -919,10 +933,10 @@ __TS__SetDescriptor(
919
933
  "healingPerInterval",
920
934
  {
921
935
  get = function(self)
922
- return self[116] or 0
936
+ return self[117] or 0
923
937
  end,
924
938
  set = function(self, healingPerInterval)
925
- self[116] = healingPerInterval ~= 0 and healingPerInterval or nil
939
+ self[117] = healingPerInterval ~= 0 and healingPerInterval or nil
926
940
  end
927
941
  },
928
942
  true
@@ -932,25 +946,25 @@ __TS__SetDescriptor(
932
946
  "healingInterval",
933
947
  {
934
948
  get = function(self)
935
- return self[117] or 0
949
+ return self[118] or 0
936
950
  end,
937
951
  set = function(self, healingInterval)
938
952
  if healingInterval <= 0 then
939
- self[117] = healingInterval ~= 0 and healingInterval or nil
940
- local timer = self[119]
953
+ self[118] = healingInterval ~= 0 and healingInterval or nil
954
+ local timer = self[120]
941
955
  if timer ~= nil then
942
956
  timer:destroy()
943
- self[119] = nil
957
+ self[120] = nil
944
958
  end
945
959
  return
946
960
  end
947
- self[117] = healingInterval
948
- local ____opt_47 = self._timer
949
- local elapsed = ____opt_47 and ____opt_47.elapsed or 0
950
- local timer = self[119]
961
+ self[118] = healingInterval
962
+ local ____opt_51 = self._timer
963
+ local elapsed = ____opt_51 and ____opt_51.elapsed or 0
964
+ local timer = self[120]
951
965
  if timer == nil then
952
966
  timer = Timer:create()
953
- self[119] = timer
967
+ self[120] = timer
954
968
  end
955
969
  local initialDelay = healingInterval - (elapsed >= healingInterval and math.fmod(elapsed, healingInterval) or elapsed)
956
970
  if initialDelay == healingInterval then
@@ -967,10 +981,10 @@ __TS__SetDescriptor(
967
981
  "damageOnExpiration",
968
982
  {
969
983
  get = function(self)
970
- return self[120] or 0
984
+ return self[121] or 0
971
985
  end,
972
986
  set = function(self, damageOnExpiration)
973
- self[120] = damageOnExpiration ~= 0 and damageOnExpiration or nil
987
+ self[121] = damageOnExpiration ~= 0 and damageOnExpiration or nil
974
988
  end
975
989
  },
976
990
  true
@@ -980,10 +994,10 @@ __TS__SetDescriptor(
980
994
  "healingOnExpiration",
981
995
  {
982
996
  get = function(self)
983
- return self[121] or 0
997
+ return self[122] or 0
984
998
  end,
985
999
  set = function(self, healingOnExpiration)
986
- self[121] = healingOnExpiration ~= 0 and healingOnExpiration or nil
1000
+ self[122] = healingOnExpiration ~= 0 and healingOnExpiration or nil
987
1001
  end
988
1002
  },
989
1003
  true
@@ -1014,6 +1028,19 @@ __TS__SetDescriptor(
1014
1028
  },
1015
1029
  true
1016
1030
  )
1031
+ __TS__SetDescriptor(
1032
+ Buff.prototype,
1033
+ "returnedMeleeDamageFactor",
1034
+ {
1035
+ get = function(self)
1036
+ return self:getUnitBonus(UnitBonusType.RETURNED_MELEE_DAMAGE_FACTOR)
1037
+ end,
1038
+ set = function(self, returnedMeleeDamageFactor)
1039
+ self:addOrUpdateOrRemoveUnitBonus(UnitBonusType.RETURNED_MELEE_DAMAGE_FACTOR, returnedMeleeDamageFactor)
1040
+ end
1041
+ },
1042
+ true
1043
+ )
1017
1044
  __TS__SetDescriptor(
1018
1045
  Buff.prototype,
1019
1046
  "armorIncrease",
@@ -1058,19 +1085,19 @@ __TS__SetDescriptor(
1058
1085
  "turnsIntoGhost",
1059
1086
  {
1060
1087
  get = function(self)
1061
- local ____self__139_49 = self[139]
1062
- if ____self__139_49 == nil then
1063
- ____self__139_49 = false
1088
+ local ____self__140_53 = self[140]
1089
+ if ____self__140_53 == nil then
1090
+ ____self__140_53 = false
1064
1091
  end
1065
- return ____self__139_49
1092
+ return ____self__140_53
1066
1093
  end,
1067
1094
  set = function(self, turnsIntoGhost)
1068
- if not turnsIntoGhost and self[139] then
1095
+ if not turnsIntoGhost and self[140] then
1069
1096
  self.object:decrementGhostCounter()
1070
- self[139] = nil
1071
- elseif turnsIntoGhost and not self[139] then
1097
+ self[140] = nil
1098
+ elseif turnsIntoGhost and not self[140] then
1072
1099
  self.object:incrementGhostCounter()
1073
- self[139] = true
1100
+ self[140] = true
1074
1101
  end
1075
1102
  end
1076
1103
  },
@@ -1081,25 +1108,25 @@ __TS__SetDescriptor(
1081
1108
  "stuns",
1082
1109
  {
1083
1110
  get = function(self)
1084
- local ____self__140_50 = self[140]
1085
- if ____self__140_50 == nil then
1086
- ____self__140_50 = false
1111
+ local ____self__141_54 = self[141]
1112
+ if ____self__141_54 == nil then
1113
+ ____self__141_54 = false
1087
1114
  end
1088
- return ____self__140_50
1115
+ return ____self__141_54
1089
1116
  end,
1090
1117
  set = function(self, stuns)
1091
- if not stuns and self[140] then
1092
- if self[141] then
1118
+ if not stuns and self[141] then
1119
+ if self[142] then
1093
1120
  self.object:decrementForceStunCounter()
1094
1121
  end
1095
1122
  self.object:decrementStunCounter()
1096
- self[140] = nil
1097
- elseif stuns and not self[140] then
1098
- if self[141] then
1123
+ self[141] = nil
1124
+ elseif stuns and not self[141] then
1125
+ if self[142] then
1099
1126
  self.object:incrementForceStunCounter()
1100
1127
  end
1101
1128
  self.object:incrementStunCounter()
1102
- self[140] = true
1129
+ self[141] = true
1103
1130
  end
1104
1131
  end
1105
1132
  },
@@ -1110,23 +1137,23 @@ __TS__SetDescriptor(
1110
1137
  "ignoresStunImmunity",
1111
1138
  {
1112
1139
  get = function(self)
1113
- local ____self__141_51 = self[141]
1114
- if ____self__141_51 == nil then
1115
- ____self__141_51 = false
1140
+ local ____self__142_55 = self[142]
1141
+ if ____self__142_55 == nil then
1142
+ ____self__142_55 = false
1116
1143
  end
1117
- return ____self__141_51
1144
+ return ____self__142_55
1118
1145
  end,
1119
1146
  set = function(self, ignoresStunImmunity)
1120
- if not ignoresStunImmunity and self[141] then
1121
- if self[140] then
1147
+ if not ignoresStunImmunity and self[142] then
1148
+ if self[141] then
1122
1149
  self.object:decrementForceStunCounter()
1123
1150
  end
1124
- self[141] = nil
1125
- elseif ignoresStunImmunity and not self[141] then
1126
- if self[140] then
1151
+ self[142] = nil
1152
+ elseif ignoresStunImmunity and not self[142] then
1153
+ if self[141] then
1127
1154
  self.object:incrementForceStunCounter()
1128
1155
  end
1129
- self[141] = true
1156
+ self[142] = true
1130
1157
  end
1131
1158
  end
1132
1159
  },
@@ -1137,19 +1164,19 @@ __TS__SetDescriptor(
1137
1164
  "disablesAutoAttack",
1138
1165
  {
1139
1166
  get = function(self)
1140
- local ____self__142_52 = self[142]
1141
- if ____self__142_52 == nil then
1142
- ____self__142_52 = false
1167
+ local ____self__143_56 = self[143]
1168
+ if ____self__143_56 == nil then
1169
+ ____self__143_56 = false
1143
1170
  end
1144
- return ____self__142_52
1171
+ return ____self__143_56
1145
1172
  end,
1146
1173
  set = function(self, disablesAutoAttack)
1147
- if not disablesAutoAttack and self[142] then
1174
+ if not disablesAutoAttack and self[143] then
1148
1175
  self.object:decrementDisableAutoAttackCounter()
1149
- self[142] = nil
1150
- elseif disablesAutoAttack and not self[142] then
1176
+ self[143] = nil
1177
+ elseif disablesAutoAttack and not self[143] then
1151
1178
  self.object:incrementDisableAutoAttackCounter()
1152
- self[142] = true
1179
+ self[143] = true
1153
1180
  end
1154
1181
  end
1155
1182
  },
@@ -1160,19 +1187,19 @@ __TS__SetDescriptor(
1160
1187
  "providesInvulnerability",
1161
1188
  {
1162
1189
  get = function(self)
1163
- local ____self__143_53 = self[143]
1164
- if ____self__143_53 == nil then
1165
- ____self__143_53 = false
1190
+ local ____self__144_57 = self[144]
1191
+ if ____self__144_57 == nil then
1192
+ ____self__144_57 = false
1166
1193
  end
1167
- return ____self__143_53
1194
+ return ____self__144_57
1168
1195
  end,
1169
1196
  set = function(self, providesInvulnerability)
1170
- if not providesInvulnerability and self[143] then
1197
+ if not providesInvulnerability and self[144] then
1171
1198
  self.object:decrementInvulnerabilityCounter()
1172
- self[143] = nil
1173
- elseif providesInvulnerability and not self[143] then
1199
+ self[144] = nil
1200
+ elseif providesInvulnerability and not self[144] then
1174
1201
  self.object:incrementInvulnerabilityCounter()
1175
- self[143] = true
1202
+ self[144] = true
1176
1203
  end
1177
1204
  end
1178
1205
  },
@@ -1183,17 +1210,17 @@ __TS__SetDescriptor(
1183
1210
  "killsOnExpiration",
1184
1211
  {
1185
1212
  get = function(self)
1186
- local ____self__144_54 = self[144]
1187
- if ____self__144_54 == nil then
1188
- ____self__144_54 = false
1213
+ local ____self__145_58 = self[145]
1214
+ if ____self__145_58 == nil then
1215
+ ____self__145_58 = false
1189
1216
  end
1190
- return ____self__144_54
1217
+ return ____self__145_58
1191
1218
  end,
1192
1219
  set = function(self, killsOnExpiration)
1193
- if not killsOnExpiration and self[144] then
1194
- self[144] = nil
1195
- elseif killsOnExpiration and not self[144] then
1196
- self[144] = true
1220
+ if not killsOnExpiration and self[145] then
1221
+ self[145] = nil
1222
+ elseif killsOnExpiration and not self[145] then
1223
+ self[145] = true
1197
1224
  end
1198
1225
  end
1199
1226
  },
@@ -1204,17 +1231,17 @@ __TS__SetDescriptor(
1204
1231
  "explodesOnExpiration",
1205
1232
  {
1206
1233
  get = function(self)
1207
- local ____self__145_55 = self[145]
1208
- if ____self__145_55 == nil then
1209
- ____self__145_55 = false
1234
+ local ____self__146_59 = self[146]
1235
+ if ____self__146_59 == nil then
1236
+ ____self__146_59 = false
1210
1237
  end
1211
- return ____self__145_55
1238
+ return ____self__146_59
1212
1239
  end,
1213
1240
  set = function(self, killsOnExpiration)
1214
- if not killsOnExpiration and self[145] then
1215
- self[145] = nil
1216
- elseif killsOnExpiration and not self[145] then
1217
- self[145] = true
1241
+ if not killsOnExpiration and self[146] then
1242
+ self[146] = nil
1243
+ elseif killsOnExpiration and not self[146] then
1244
+ self[146] = true
1218
1245
  end
1219
1246
  end
1220
1247
  },
@@ -1225,13 +1252,13 @@ __TS__SetDescriptor(
1225
1252
  "maximumDamageDealtEventCount",
1226
1253
  {
1227
1254
  get = function(self)
1228
- return self[132] or 0
1255
+ return self[133] or 0
1229
1256
  end,
1230
1257
  set = function(self, maximumDamageDealtEventCount)
1231
1258
  if maximumDamageDealtEventCount == 0 then
1232
- self[132] = nil
1259
+ self[133] = nil
1233
1260
  else
1234
- self[132] = maximumDamageDealtEventCount
1261
+ self[133] = maximumDamageDealtEventCount
1235
1262
  end
1236
1263
  end
1237
1264
  },
@@ -1242,13 +1269,13 @@ __TS__SetDescriptor(
1242
1269
  "maximumDamageReceivedEventCount",
1243
1270
  {
1244
1271
  get = function(self)
1245
- return self[134] or 0
1272
+ return self[135] or 0
1246
1273
  end,
1247
1274
  set = function(self, maximumDamageReceivedEventCount)
1248
1275
  if maximumDamageReceivedEventCount == 0 then
1249
- self[134] = nil
1276
+ self[135] = nil
1250
1277
  else
1251
- self[134] = maximumDamageReceivedEventCount
1278
+ self[135] = maximumDamageReceivedEventCount
1252
1279
  end
1253
1280
  end
1254
1281
  },
@@ -1259,13 +1286,13 @@ __TS__SetDescriptor(
1259
1286
  "maximumAutoAttackCount",
1260
1287
  {
1261
1288
  get = function(self)
1262
- return self[130] or 0
1289
+ return self[131] or 0
1263
1290
  end,
1264
1291
  set = function(self, maximumAutoAttackCount)
1265
1292
  if maximumAutoAttackCount == 0 then
1266
- self[130] = nil
1293
+ self[131] = nil
1267
1294
  else
1268
- self[130] = maximumAutoAttackCount
1295
+ self[131] = maximumAutoAttackCount
1269
1296
  end
1270
1297
  end
1271
1298
  },
@@ -1276,10 +1303,10 @@ __TS__SetDescriptor(
1276
1303
  "durationIncreaseOnAutoAttack",
1277
1304
  {
1278
1305
  get = function(self)
1279
- return self[107] or 0
1306
+ return self[108] or 0
1280
1307
  end,
1281
1308
  set = function(self, durationIncreaseOnAutoAttack)
1282
- self[107] = durationIncreaseOnAutoAttack
1309
+ self[108] = durationIncreaseOnAutoAttack
1283
1310
  end
1284
1311
  },
1285
1312
  true
@@ -1363,13 +1390,13 @@ __TS__SetDescriptor(
1363
1390
  "remainingDuration",
1364
1391
  {
1365
1392
  get = function(self)
1366
- local ____opt_56 = self._timer
1367
- return ____opt_56 and ____opt_56.remaining or 0
1393
+ local ____opt_60 = self._timer
1394
+ return ____opt_60 and ____opt_60.remaining or 0
1368
1395
  end,
1369
1396
  set = function(self, remainingDuration)
1370
- local ____remainingDuration_60 = remainingDuration
1371
- local ____opt_58 = self._timer
1372
- local remainingDurationDelta = ____remainingDuration_60 - (____opt_58 and ____opt_58.remaining or 0)
1397
+ local ____remainingDuration_64 = remainingDuration
1398
+ local ____opt_62 = self._timer
1399
+ local remainingDurationDelta = ____remainingDuration_64 - (____opt_62 and ____opt_62.remaining or 0)
1373
1400
  if remainingDurationDelta ~= 0 then
1374
1401
  self[103] = self[103] + remainingDurationDelta
1375
1402
  if remainingDuration <= 0 then
@@ -1384,7 +1411,7 @@ __TS__SetDescriptor(
1384
1411
  remainingDuration,
1385
1412
  self._spellStealPriority,
1386
1413
  self._learnLevelMinimum,
1387
- self[146]
1414
+ self[147]
1388
1415
  ) then
1389
1416
  local timer = self._timer
1390
1417
  if timer == nil then
@@ -1404,13 +1431,13 @@ __TS__SetDescriptor(
1404
1431
  "absorbedDamageFactor",
1405
1432
  {
1406
1433
  get = function(self)
1407
- return self[135] or 1
1434
+ return self[136] or 1
1408
1435
  end,
1409
1436
  set = function(self, absorbedDamageFactor)
1410
1437
  if absorbedDamageFactor == 1 then
1411
- self[135] = nil
1438
+ self[136] = nil
1412
1439
  else
1413
- self[135] = absorbedDamageFactor
1440
+ self[136] = absorbedDamageFactor
1414
1441
  end
1415
1442
  end
1416
1443
  },
@@ -1421,13 +1448,13 @@ __TS__SetDescriptor(
1421
1448
  "maximumDamageAbsorbed",
1422
1449
  {
1423
1450
  get = function(self)
1424
- return self[136] or 0
1451
+ return self[137] or 0
1425
1452
  end,
1426
1453
  set = function(self, maximumDamageAbsorbed)
1427
1454
  if maximumDamageAbsorbed == 0 then
1428
- self[136] = nil
1455
+ self[137] = nil
1429
1456
  else
1430
- self[136] = maximumDamageAbsorbed
1457
+ self[137] = maximumDamageAbsorbed
1431
1458
  end
1432
1459
  end
1433
1460
  },
@@ -1437,7 +1464,7 @@ __TS__SetDescriptor(
1437
1464
  Buff.prototype,
1438
1465
  "damageAbsorbed",
1439
1466
  {get = function(self)
1440
- return self[137] or 0
1467
+ return self[138] or 0
1441
1468
  end},
1442
1469
  true
1443
1470
  )
@@ -1446,20 +1473,20 @@ __TS__SetDescriptor(
1446
1473
  "destroysOnMaximumDamageAbsorbed",
1447
1474
  {
1448
1475
  get = function(self)
1449
- local ____self__138_61 = self[138]
1450
- if ____self__138_61 == nil then
1451
- ____self__138_61 = true
1476
+ local ____self__139_65 = self[139]
1477
+ if ____self__139_65 == nil then
1478
+ ____self__139_65 = true
1452
1479
  end
1453
- return ____self__138_61
1480
+ return ____self__139_65
1454
1481
  end,
1455
1482
  set = function(self, destroysOnMaximumDamageAbsorbed)
1456
- local ____destroysOnMaximumDamageAbsorbed_62
1483
+ local ____destroysOnMaximumDamageAbsorbed_66
1457
1484
  if destroysOnMaximumDamageAbsorbed then
1458
- ____destroysOnMaximumDamageAbsorbed_62 = nil
1485
+ ____destroysOnMaximumDamageAbsorbed_66 = nil
1459
1486
  else
1460
- ____destroysOnMaximumDamageAbsorbed_62 = false
1487
+ ____destroysOnMaximumDamageAbsorbed_66 = false
1461
1488
  end
1462
- self[138] = ____destroysOnMaximumDamageAbsorbed_62
1489
+ self[139] = ____destroysOnMaximumDamageAbsorbed_66
1463
1490
  end
1464
1491
  },
1465
1492
  true
@@ -1469,10 +1496,10 @@ __TS__SetDescriptor(
1469
1496
  "abilityCooldownFactor",
1470
1497
  {
1471
1498
  get = function(self)
1472
- return self[147] or 1
1499
+ return self[148] or 1
1473
1500
  end,
1474
1501
  set = function(self, abilityCooldownFactor)
1475
- local previousAbilityCooldownModifier = self[148]
1502
+ local previousAbilityCooldownModifier = self[149]
1476
1503
  if previousAbilityCooldownModifier then
1477
1504
  for ____, ability in ipairs(self._unit.abilities) do
1478
1505
  COOLDOWN_ABILITY_FLOAT_LEVEL_FIELD:removeModifier(ability, previousAbilityCooldownModifier)
@@ -1484,8 +1511,8 @@ __TS__SetDescriptor(
1484
1511
  for ____, ability in ipairs(self._unit.abilities) do
1485
1512
  COOLDOWN_ABILITY_FLOAT_LEVEL_FIELD:applyModifier(ability, modifier)
1486
1513
  end
1487
- self[148] = modifier
1488
- self[147] = abilityCooldownFactor
1514
+ self[149] = modifier
1515
+ self[148] = abilityCooldownFactor
1489
1516
  end
1490
1517
  },
1491
1518
  true