From 96cb823950019b46c75561820d7ede3bc79dcf18 Mon Sep 17 00:00:00 2001 From: DarkGod <darkgod@net-core.org> Date: Tue, 23 Sep 2014 14:47:33 +0200 Subject: [PATCH] new vim_on_melee --- game/modules/tome/class/Object.lua | 2 ++ game/modules/tome/class/interface/Combat.lua | 2 ++ 2 files changed, 4 insertions(+) diff --git a/game/modules/tome/class/Object.lua b/game/modules/tome/class/Object.lua index bf7806671b..487aedfce1 100644 --- a/game/modules/tome/class/Object.lua +++ b/game/modules/tome/class/Object.lua @@ -1280,6 +1280,8 @@ function _M:getTextualDesc(compare_with, use_actor) compare_fields(w, compare_with, field, "hate_regen_when_hit", "%+.2f", "Hate when hit: ") compare_fields(w, compare_with, field, "vim_regen_when_hit", "%+.2f", "Vim when hit: ") + compare_fields(w, compare_with, field, "vim_on_melee", "%+.2f", "Vim when hitting in melee: ") + compare_fields(w, compare_with, field, "mana_on_crit", "%+.2f", "Mana when firing critical spell: ") compare_fields(w, compare_with, field, "vim_on_crit", "%+.2f", "Vim when firing critical spell: ") compare_fields(w, compare_with, field, "spellsurge_on_crit", "%+d", "Spellpower on spell critical (stacks up to 3 times): ") diff --git a/game/modules/tome/class/interface/Combat.lua b/game/modules/tome/class/interface/Combat.lua index bd752a5739..87626d15fe 100644 --- a/game/modules/tome/class/interface/Combat.lua +++ b/game/modules/tome/class/interface/Combat.lua @@ -546,6 +546,8 @@ function _M:attackTargetWith(target, weapon, damtype, mult, force_dam) target:fireTalentCheck("callbackOnMeleeHit", self, dam) hitted = true + + if self:attr("vim_on_melee") then self:incVim(self:attr("vim_on_melee")) end else self:logCombat(target, "#Source# misses #Target#.") target:fireTalentCheck("callbackOnMeleeMiss", self, dam) -- GitLab