From 9848f5ae67f780ddb8045e71214d86aacb2e5a38 Mon Sep 17 00:00:00 2001 From: DarkGod <darkgod@net-core.org> Date: Thu, 12 Feb 2015 01:25:41 +0100 Subject: [PATCH] rune of reflection worsk with grisly constitution --- .../tome/data/general/objects/boss-artifacts.lua | 4 ++++ game/modules/tome/data/talents/misc/inscriptions.lua | 12 +++++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/game/modules/tome/data/general/objects/boss-artifacts.lua b/game/modules/tome/data/general/objects/boss-artifacts.lua index 3964bc3abb..d8f9b89f5b 100644 --- a/game/modules/tome/data/general/objects/boss-artifacts.lua +++ b/game/modules/tome/data/general/objects/boss-artifacts.lua @@ -157,6 +157,10 @@ newEntity{ base = "BASE_RUNE", define_as = "RUNE_REFLECT", inscription_kind = "protect", inscription_data = { cooldown = 15, + dur = 5, + power = 100, + use_stat_mod = 5, + use_stat = "mag", }, inscription_talent = "RUNE:_REFLECTION_SHIELD", } diff --git a/game/modules/tome/data/talents/misc/inscriptions.lua b/game/modules/tome/data/talents/misc/inscriptions.lua index 221251b9ca..35d35c917d 100644 --- a/game/modules/tome/data/talents/misc/inscriptions.lua +++ b/game/modules/tome/data/talents/misc/inscriptions.lua @@ -510,17 +510,23 @@ newInscription{ end, action = function(self, t) local data = self:getInscriptionData(t.short_name) - self:setEffect(self.EFF_DAMAGE_SHIELD, 5, {power=100+5*self:getMag(), reflect=100}) + local power = 100+5*self:getMag() + if data.power and data.inc_stat then power = data.power + data.inc_stat end + self:setEffect(self.EFF_DAMAGE_SHIELD, data.dur or 5, {power=power, reflect=100}) return true end, info = function(self, t) local data = self:getInscriptionData(t.short_name) + local power = 100+5*self:getMag() + if data.power and data.inc_stat then power = data.power + data.inc_stat end return ([[Activate the rune to create a protective shield absorbing and reflecting at most %d damage for %d turns. -The effect will scale with your magic stat.]]):format(100+5*self:getMag(), 5) +The effect will scale with your magic stat.]]):format(power, data.dur or 5) end, short_info = function(self, t) local data = self:getInscriptionData(t.short_name) - return ([[absorb and reflect %d for %d turns]]):format(100+5*self:getMag(), 5) + local power = 100+5*self:getMag() + if data.power and data.inc_stat then power = data.power + data.inc_stat end + return ([[absorb and reflect %d for %d turns]]):format(power, data.dur or 5) end, } -- GitLab