Commit 692a8257eb179800602e4d9456aa79676722b0f7

Authored by DarkGod
1 parent a75e0ce3

Swapped talents that used callbackOnActBase for life threshold checks to callbac…

…kOnAct so tha they account for faster players
@@ -2036,6 +2036,7 @@ function _M:setupCommands() @@ -2036,6 +2036,7 @@ function _M:setupCommands()
2036 end end, 2036 end end,
2037 [{"_g","ctrl"}] = function() if config.settings.cheat then 2037 [{"_g","ctrl"}] = function() if config.settings.cheat then
2038 game.player:takeHit(100, game.player) 2038 game.player:takeHit(100, game.player)
  2039 + game.player:useEnergy()
2039 -- DamageType:get(DamageType.ACID).projector(game.player, game.player.x, game.player.y, DamageType.ACID, 100) 2040 -- DamageType:get(DamageType.ACID).projector(game.player, game.player.x, game.player.y, DamageType.ACID, 100)
2040 do return end 2041 do return end
2041 game.player:setEffect("EFF_STUNNED", 1, {apply_power=200}) 2042 game.player:setEffect("EFF_STUNNED", 1, {apply_power=200})
@@ -130,7 +130,7 @@ newTalent{ @@ -130,7 +130,7 @@ newTalent{
130 tactical = { BUFF = 2 }, 130 tactical = { BUFF = 2 },
131 getImmune = function(self, t) return math.floor(self:combatTalentLimit(t, 100, 20, 50)) end, 131 getImmune = function(self, t) return math.floor(self:combatTalentLimit(t, 100, 20, 50)) end,
132 getSaves = function(self, t) return math.floor(self:combatTalentScale(t, 10, 55)) end, 132 getSaves = function(self, t) return math.floor(self:combatTalentScale(t, 10, 55)) end,
133 - callbackOnActBase = checkLifeThreshold(1, function(self, t) 133 + callbackOnAct = checkLifeThreshold(1, function(self, t)
134 if self:getTalentLevel(t) < 5 then return end 134 if self:getTalentLevel(t) < 5 then return end
135 self:setEffect(self.EFF_GOLDEN_AGE_OF_NECROMANCY, 1, {}) 135 self:setEffect(self.EFF_GOLDEN_AGE_OF_NECROMANCY, 1, {})
136 return true 136 return true
@@ -187,6 +187,7 @@ newTalent{ @@ -187,6 +187,7 @@ newTalent{
187 getDamageIncrease = function(self, t) return self:combatTalentScale(t, 2.5, 10) end, 187 getDamageIncrease = function(self, t) return self:combatTalentScale(t, 2.5, 10) end,
188 getResistPenalty = function(self, t) return self:combatTalentLimit(t, 100, 17, 50, true) end, 188 getResistPenalty = function(self, t) return self:combatTalentLimit(t, 100, 17, 50, true) end,
189 getVampiric = function(self, t) return math.floor(self:combatTalentLimit(t, 60, 3, 8)) end, 189 getVampiric = function(self, t) return math.floor(self:combatTalentLimit(t, 60, 3, 8)) end,
  190 + callbackPriorities={callbackOnActBase = 100}, -- trigger after most others
190 callbackOnActBase = function(self, t) 191 callbackOnActBase = function(self, t)
191 local p = self:isTalentActive(t.id) if not p then return end 192 local p = self:isTalentActive(t.id) if not p then return end
192 if p.cur_value > 0 then self:heal(p.cur_value, self) end 193 if p.cur_value > 0 then self:heal(p.cur_value, self) end
@@ -49,7 +49,7 @@ newTalent{ @@ -49,7 +49,7 @@ newTalent{
49 ret.waste_counter = 0 49 ret.waste_counter = 0
50 end 50 end
51 end, 51 end,
52 - callbackOnActBase = checkLifeThreshold(1, function(self, t) 52 + callbackOnAct = checkLifeThreshold(1, function(self, t)
53 local p = self:isTalentActive(t.id) 53 local p = self:isTalentActive(t.id)
54 if not p then return end 54 if not p then return end
55 55
@@ -63,7 +63,8 @@ newTalent{ @@ -63,7 +63,8 @@ newTalent{
63 p.crit_id = nil 63 p.crit_id = nil
64 end 64 end
65 end 65 end
66 - end, function(self, t) 66 + end),
  67 + callbackOnActBase = function(self, t)
67 local p = self:isTalentActive(t.id) 68 local p = self:isTalentActive(t.id)
68 if not p then return end 69 if not p then return end
69 70
@@ -83,7 +84,7 @@ newTalent{ @@ -83,7 +84,7 @@ newTalent{
83 self:incSoul(-soul) 84 self:incSoul(-soul)
84 end 85 end
85 end 86 end
86 - end), 87 + end,
87 callbackOnCombat = function(self, t, state) 88 callbackOnCombat = function(self, t, state)
88 local p = self:isTalentActive(t.id) 89 local p = self:isTalentActive(t.id)
89 if not p then return end 90 if not p then return end
@@ -35,7 +35,7 @@ newTalent{ @@ -35,7 +35,7 @@ newTalent{
35 callbackOnStatChange = function(self, t, stat, v) 35 callbackOnStatChange = function(self, t, stat, v)
36 if stat == self.STAT_CON then self:updateTalentPassives(t) end 36 if stat == self.STAT_CON then self:updateTalentPassives(t) end
37 end, 37 end,
38 - callbackOnActBase = checkLifeThreshold(1, function(self, t) 38 + callbackOnAct = checkLifeThreshold(1, function(self, t)
39 self:updateTalentPassives(t) 39 self:updateTalentPassives(t)
40 end), 40 end),
41 passives = function(self, t, p) 41 passives = function(self, t, p)
@@ -66,7 +66,7 @@ newTalent{ @@ -66,7 +66,7 @@ newTalent{
66 radius = function(self, t) return self:combatTalentLimit(t, 10, 2, 6) end, 66 radius = function(self, t) return self:combatTalentLimit(t, 10, 2, 6) end,
67 getCD = function(self, t) return math.ceil(self:combatTalentLimit(t, 12, 2, 8)) end, 67 getCD = function(self, t) return math.ceil(self:combatTalentLimit(t, 12, 2, 8)) end,
68 getDamage = function(self, t) return self:combatTalentSpellDamage(t, 30, 260) end, 68 getDamage = function(self, t) return self:combatTalentSpellDamage(t, 30, 260) end,
69 - callbackOnActBase = checkLifeThreshold(1, function(self, t) 69 + callbackOnAct = checkLifeThreshold(1, function(self, t)
70 local list = {} 70 local list = {}
71 for tid, c in pairs(self.talents_cd) do 71 for tid, c in pairs(self.talents_cd) do
72 local t = self:getTalentFromId(tid) 72 local t = self:getTalentFromId(tid)