Skip to content
Snippets Groups Projects
Commit d008b5e9 authored by Otowa Kotori's avatar Otowa Kotori
Browse files

timed_effects

parent 4cd9f882
No related branches found
No related tags found
No related merge requests found
......@@ -24,6 +24,7 @@ local Chat = require "engine.Chat"
local Map = require "engine.Map"
local Level = require "engine.Level"
--I18N-TODO Need some clean up
local function floorEffect(t)
t.name = t.name or t.desc
t.name = t.name:upper():gsub("[ ']", "_")
......@@ -40,7 +41,7 @@ end
floorEffect{
desc = "Icy Floor", image = "talents/ice_storm.png",
long_desc = "The target is walking on an icy floor. Increasing movement speed by 20%, providing +20% cold damage piercing and -30% stun immunity.",
long_desc = _t"The target is walking on an icy floor. Increasing movement speed by 20%, providing +20% cold damage piercing and -30% stun immunity.",
activate = function(self, eff)
self:effectTemporaryValue(eff, "resists_pen", {[DamageType.COLD] = 20})
self:effectTemporaryValue(eff, "movement_speed", 0.2)
......@@ -50,7 +51,7 @@ floorEffect{
floorEffect{
desc = "Font of Life", image = "talents/grand_arrival.png",
long_desc = function(self, eff) return ("The target is near a font of life, granting %+0.2f life regeneration, %+0.2f equilibrium regeneration, %+0.2f stamina regeneration and %+0.2f psi regeneration. (Only living creatures benefit.)"):format(eff.power, eff.equilibrium, eff.stamina, eff.psi) end,
long_desc = function(self, eff) return ("The target is near a font of life, granting %+0.2f life regeneration, %+0.2f equilibrium regeneration, %+0.2f stamina regeneration and %+0.2f psi regeneration. (Only living creatures benefit.)"):tformat(eff.power, eff.equilibrium, eff.stamina, eff.psi) end,
parameters = {power=1, equilibrium=0, stamina=0, psi=0},
activate = function(self, eff)
if not self:checkClassification("living") then eff.power = 0 return end
......@@ -67,7 +68,7 @@ floorEffect{
floorEffect{
desc = "Spellblaze Scar", image = "talents/blood_boil.png",
long_desc = "The target is near a spellblaze scar, granting +25% spell critical chance, +10% fire and blight damage but critical spells will drain arcane forces.",
long_desc = _t"The target is near a spellblaze scar, granting +25% spell critical chance, +10% fire and blight damage but critical spells will drain arcane forces.",
activate = function(self, eff)
self:effectTemporaryValue(eff, "combat_spellcrit", 25)
self:effectTemporaryValue(eff, "inc_damage", {[DamageType.FIRE]=10,[DamageType.BLIGHT]=10})
......@@ -81,7 +82,7 @@ floorEffect{
floorEffect{
desc = "Blighted Soil", image = "talents/blightzone.png",
long_desc = "The target is walking on blighted soil, reducing diseases resistance by 60% and giving all attacks a 40% chance to infect the target with a random disease (can only happen once per turn).",
long_desc = _t"The target is walking on blighted soil, reducing diseases resistance by 60% and giving all attacks a 40% chance to infect the target with a random disease (can only happen once per turn).",
activate = function(self, eff)
self:effectTemporaryValue(eff, "disease_immune", -0.6)
self:effectTemporaryValue(eff, "blighted_soil", 40)
......@@ -90,14 +91,14 @@ floorEffect{
floorEffect{
desc = "Glimmerstone", image = "effects/dazed.png", name = "DAZING_DAMAGE",
long_desc = "The target is affected by a glimmerstone, its next attack will try to daze.",
long_desc = _t"The target is affected by a glimmerstone, its next attack will try to daze.",
activate = function(self, eff)
end,
}
floorEffect{
desc = "Protective Aura", image = "talents/barrier.png",
long_desc = function(self, eff) return ("The target is near a protective aura, granting +%d armour and +%d physical save."):format(eff.armor, eff.power) end,
long_desc = function(self, eff) return ("The target is near a protective aura, granting +%d armour and +%d physical save."):tformat(eff.armor, eff.power) end,
parameters = {power=1, armor=1},
activate = function(self, eff)
local power = 3 + game.zone:level_adjust_level(game.level, game.zone, "object") / 2
......@@ -110,7 +111,7 @@ floorEffect{
floorEffect{
desc = "Antimagic Bush", image = "talents/fungal_growth.png",
long_desc = function(self, eff) return ("The target is near an antimagic bush, granting +20%% nature damage, +20%% nature resistance penetration and -%d spellpower."):format(eff.power) end,
long_desc = function(self, eff) return ("The target is near an antimagic bush, granting +20%% nature damage, +20%% nature resistance penetration and -%d spellpower."):tformat(eff.power) end,
activate = function(self, eff)
eff.power = 10 + game.zone:level_adjust_level(game.level, game.zone, "object") / 1.5
self:effectTemporaryValue(eff, "combat_spellpower", -eff.power)
......@@ -121,7 +122,7 @@ floorEffect{
floorEffect{
desc = "Necrotic Air", image = "talents/repression.png",
long_desc = "The target is in a zone of necrotic air, granting -40% healing mod. Undead creatures also get +15% to all resistances.",
long_desc = _t"The target is in a zone of necrotic air, granting -40% healing mod. Undead creatures also get +15% to all resistances.",
activate = function(self, eff)
self:effectTemporaryValue(eff, "healing_factor", -0.4)
if self:attr("undead") then self:effectTemporaryValue(eff, "resists", {all=15}) end
......@@ -130,7 +131,7 @@ floorEffect{
floorEffect{
desc = "Whistling Vortex", image = "talents/shadow_blast.png",
long_desc = function(self, eff) return ("The target is in a whistling vortex, granting +%d ranged defense, -%d ranged accuracy and incoming projectiles are 30%% slower."):format(eff.power, eff.power) end,
long_desc = function(self, eff) return ("The target is in a whistling vortex, granting +%d ranged defense, -%d ranged accuracy and incoming projectiles are 30%% slower."):tformat(eff.power, eff.power) end,
activate = function(self, eff)
eff.power = 10 + game.zone:level_adjust_level(game.level, game.zone, "object") / 2
self:effectTemporaryValue(eff, "combat_def_ranged", eff.power)
......@@ -141,7 +142,7 @@ floorEffect{
floorEffect{
desc = "Fell Aura", image = "talents/shadow_mages.png",
long_desc = "The target is surrounded by a fell aura, granting 40% critical damage bonus but -20% to all resistances.",
long_desc = _t"The target is surrounded by a fell aura, granting 40% critical damage bonus but -20% to all resistances.",
activate = function(self, eff)
self:effectTemporaryValue(eff, "combat_critical_power", 40)
self:effectTemporaryValue(eff, "resists", {all=-20})
......@@ -150,7 +151,7 @@ floorEffect{
floorEffect{
desc = "Slimey Pool", image = "talents/acidic_skin.png",
long_desc = "The target is walking on slime. Decreasing movement speed by 20% and dealing 20 slime damage to any creatures attacking it.",
long_desc = _t"The target is walking on slime. Decreasing movement speed by 20% and dealing 20 slime damage to any creatures attacking it.",
activate = function(self, eff)
self:effectTemporaryValue(eff, "on_melee_hit", {[DamageType.SLIME] = 20})
self:effectTemporaryValue(eff, "movement_speed", -0.2)
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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