Skip to content
Snippets Groups Projects
Commit 9d555201 authored by Hachem_Muche's avatar Hachem_Muche
Browse files

Further Throwing Knives Fix.

parent 1dd8c985
No related branches found
No related tags found
1 merge request!388Heal Scaling Update
......@@ -108,7 +108,8 @@ newTalent{
},
on_learn = function(self, t)
venomous_throw_check(self)
self:setEffect(self.EFF_THROWING_KNIVES, 1, {stacks=0, max_stacks=t.getNb(self, t)})
local max = t.getNb(self, t)
self:setEffect(self.EFF_THROWING_KNIVES, 1, {stacks=game.party:hasMember(self) and 0 or max, max_stacks=max})
end,
on_unlearn = function(self, t)
venomous_throw_check(self)
......@@ -133,7 +134,7 @@ newTalent{
if eff and eff.stacks > 0 then return true end
end,
callbackOnActBase = function(self, t)
if self.resting then
if self.resting or not self.player and not table.get(self, "ai_target","actor") then -- bit kludgy, npc's don't rest
local reload = self:callTalent(self.T_THROWING_KNIVES, "getReload")
local max = self:callTalent(self.T_THROWING_KNIVES, "getNb")
self:setEffect(self.EFF_THROWING_KNIVES, 1, {stacks=reload, max_stacks=max })
......
......@@ -3085,7 +3085,7 @@ newEffect{
on_merge = function(self, old_eff, new_eff)
old_eff.dur = new_eff.dur
old_eff.max_stacks = new_eff.max_stacks
old_eff.stacks = util.bound(old_eff.stacks + new_eff.stacks, 1, new_eff.max_stacks)
old_eff.stacks = util.bound(old_eff.stacks + new_eff.stacks, 0, new_eff.max_stacks)
return old_eff
end,
activate = function(self, eff)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment