Skip to content
Snippets Groups Projects
Commit d87cbddc authored by dg's avatar dg
Browse files

Weapon Folding damage reduced and armor penetration removed

Weapon Folding now reduces paradox by a small amount when a weapon hits
Temporal Warden Archery and Dual-Weapon mastery levels reduced
Turn Back the Clock damage reduced
Temporal Fugue and Swap confusion power reduced
Precognition no longer kills the player if he dies during a vision
Moment of Prescience rewritten
Spin Fate no longer increases defense, maximum bonus reduced
Energy Absorption power level reduced
Diminsional Step range reduced
Wormhole exit location is a bit less accurate
Quantum Feed and Strength of Purpose no longer grant saving throws and
have a stamina cost to sustain (in addition to paradox)
Rethread's cooldown reduced
Clarified a few Wilder tooltips


git-svn-id: http://svn.net-core.org/repos/t-engine4@4787 51575b47-30f0-44d4-a5cc-537603b46e54
parent 3bcb3056
No related branches found
No related tags found
No related merge requests found
Showing
with 107 additions and 127 deletions
...@@ -176,6 +176,7 @@ local function archery_projectile(tx, ty, tg, self) ...@@ -176,6 +176,7 @@ local function archery_projectile(tx, ty, tg, self)
local t = self:getTalentFromId(self.T_WEAPON_FOLDING) local t = self:getTalentFromId(self.T_WEAPON_FOLDING)
local dam = t.getDamage(self, t) local dam = t.getDamage(self, t)
DamageType:get(DamageType.TEMPORAL).projector(self, target.x, target.y, DamageType.TEMPORAL, dam) DamageType:get(DamageType.TEMPORAL).projector(self, target.x, target.y, DamageType.TEMPORAL, dam)
self:incParadox(- t.getParadoxReduction(self, t))
end end
-- Conduit (Psi) -- Conduit (Psi)
......
...@@ -411,6 +411,7 @@ function _M:attackTargetWith(target, weapon, damtype, mult, force_dam) ...@@ -411,6 +411,7 @@ function _M:attackTargetWith(target, weapon, damtype, mult, force_dam)
local t = self:getTalentFromId(self.T_WEAPON_FOLDING) local t = self:getTalentFromId(self.T_WEAPON_FOLDING)
local dam = t.getDamage(self, t) local dam = t.getDamage(self, t)
DamageType:get(DamageType.TEMPORAL).projector(self, target.x, target.y, DamageType.TEMPORAL, dam) DamageType:get(DamageType.TEMPORAL).projector(self, target.x, target.y, DamageType.TEMPORAL, dam)
self:incParadox(- t.getParadoxReduction(self, t))
end end
-- Ruin -- Ruin
...@@ -741,10 +742,6 @@ end ...@@ -741,10 +742,6 @@ end
function _M:combatAPR(weapon) function _M:combatAPR(weapon)
weapon = weapon or self.combat or {} weapon = weapon or self.combat or {}
local addapr = 0 local addapr = 0
if self:knowTalent(Talents.T_WEAPON_FOLDING) and self:isTalentActive(self.T_WEAPON_FOLDING) then
local t = self:getTalentFromId(self.T_WEAPON_FOLDING)
addapr = t.getArmorPen(self, t)
end
return self.combat_apr + (weapon.apr or 0) + addapr return self.combat_apr + (weapon.apr or 0) + addapr
end end
......
...@@ -102,11 +102,11 @@ newBirthDescriptor{ ...@@ -102,11 +102,11 @@ newBirthDescriptor{
}, },
stats = { str=2, wil=2, dex=3, mag=2}, stats = { str=2, wil=2, dex=3, mag=2},
talents_types = { talents_types = {
["technique/archery-bow"]={true, 0.1}, ["technique/archery-bow"]={true, 0},
["technique/archery-utility"]={false, 0.1}, ["technique/archery-utility"]={false, 0},
["technique/dualweapon-attack"]={true, 0.1}, ["technique/dualweapon-attack"]={true, 0},
["technique/dualweapon-training"]={false, 0.1}, ["technique/dualweapon-training"]={false, 0},
["technique/combat-training"]={true, 0.2}, ["technique/combat-training"]={true, 0.1},
["cunning/survival"]={false, 0}, ["cunning/survival"]={false, 0},
["chronomancy/chronomancy"]={true, 0.1}, ["chronomancy/chronomancy"]={true, 0.1},
["chronomancy/speed-control"]={true, 0.1}, ["chronomancy/speed-control"]={true, 0.1},
......
...@@ -29,7 +29,7 @@ newTalent{ ...@@ -29,7 +29,7 @@ newTalent{
reflectable = true, reflectable = true,
requires_target = true, requires_target = true,
proj_speed = 5, proj_speed = 5,
getDamage = function(self, t) return self:combatTalentSpellDamage(t, 20, 200)*getParadoxModifier(self, pm) end, getDamage = function(self, t) return self:combatTalentSpellDamage(t, 15, 150)*getParadoxModifier(self, pm) end,
getDamageStat = function(self, t) return 2 + math.ceil(t.getDamage(self, t) / 15) end, getDamageStat = function(self, t) return 2 + math.ceil(t.getDamage(self, t) / 15) end,
action = function(self, t) action = function(self, t)
local tg = {type="bolt", range=self:getTalentRange(t), talent=t, display={particle="temporal_bolt"}} local tg = {type="bolt", range=self:getTalentRange(t), talent=t, display={particle="temporal_bolt"}}
...@@ -69,7 +69,7 @@ newTalent{ ...@@ -69,7 +69,7 @@ newTalent{
require = chrono_req2, require = chrono_req2,
points = 5, points = 5,
paradox = 15, paradox = 15,
cooldown = 12, cooldown = 14,
tactical = { ATTACKAREA = 2, DISABLE= 2 }, tactical = { ATTACKAREA = 2, DISABLE= 2 },
range = 0, range = 0,
radius = function(self, t) radius = function(self, t)
...@@ -81,7 +81,7 @@ newTalent{ ...@@ -81,7 +81,7 @@ newTalent{
return {type="cone", range=self:getTalentRange(t), radius=self:getTalentRadius(t), selffire=false, talent=t} return {type="cone", range=self:getTalentRange(t), radius=self:getTalentRadius(t), selffire=false, talent=t}
end, end,
getConfuseDuration = function(self, t) return math.floor((self:getTalentLevel(t) + 2) * getParadoxModifier(self, pm)) end, getConfuseDuration = function(self, t) return math.floor((self:getTalentLevel(t) + 2) * getParadoxModifier(self, pm)) end,
getConfuseEfficency = function(self, t) return (50 + self:getTalentLevelRaw(t) * 10) * getParadoxModifier(self, pm) end, getConfuseEfficency = function(self, t) return 30 + (self:getTalentLevelRaw(t) * 10) end,
action = function(self, t) action = function(self, t)
local tg = self:getTalentTarget(t) local tg = self:getTalentTarget(t)
local x, y = self:getTarget(tg) local x, y = self:getTarget(tg)
...@@ -99,7 +99,7 @@ newTalent{ ...@@ -99,7 +99,7 @@ newTalent{
local duration = t.getConfuseDuration(self, t) local duration = t.getConfuseDuration(self, t)
local radius = self:getTalentRadius(t) local radius = self:getTalentRadius(t)
return ([[Reverts the minds of all creatures in a %d radius cone to an infantile state, in effect confusing them for %d turns. return ([[Reverts the minds of all creatures in a %d radius cone to an infantile state, in effect confusing them for %d turns.
The duration and power of the confusion effect will scale with your Paradox.]]): The duration will scale with your Paradox.]]):
format(radius, duration) format(radius, duration)
end, end,
} }
......
...@@ -65,7 +65,7 @@ newTalent{ ...@@ -65,7 +65,7 @@ newTalent{
require = temporal_req1, require = temporal_req1,
points = 5, points = 5,
paradox = 5, paradox = 5,
cooldown = 10, cooldown = 1,
no_npc_use = true, no_npc_use = true,
getDuration = function(self, t) return 4 + math.ceil((self:getTalentLevel(t) * 2)) end, getDuration = function(self, t) return 4 + math.ceil((self:getTalentLevel(t) * 2)) end,
action = function(self, t) action = function(self, t)
...@@ -78,53 +78,16 @@ newTalent{ ...@@ -78,53 +78,16 @@ newTalent{
end, end,
info = function(self, t) info = function(self, t)
local duration = t.getDuration(self, t) local duration = t.getDuration(self, t)
return ([[You peer into the future, allowing you to explore your surroundings for %d turns. When precognition expires you'll return to the point in time you first cast the spell. Note that visions of your own death will still be fatal. return ([[You peer into the future, allowing you to explore your surroundings for %d turns. When precognition expires you'll return to the point in time you first cast the spell. Dying with precognition active will end the spell prematurely.
This spell splits the timeline. Attempting to use another spell that also splits the timeline while this effect is active will be unsuccessful.]]):format(duration) This spell splits the timeline. Attempting to use another spell that also splits the timeline while this effect is active will be unsuccessful.]]):format(duration)
end, end,
} }
newTalent{
name = "Spin Fate",
type = {"chronomancy/chronomancy", 2},
require = temporal_req2,
mode = "passive",
points = 5,
getDuration = function(self, t) return 1 + math.ceil(self:getTalentLevel(t)) end,
getSaveBonus = function(self, t) return self:getTalentLevel(t) end,
do_spin_fate = function(self, t, type)
local save_bonus = t.getSaveBonus(self, t)
if self:hasEffect(self.EFF_PRECOGNITION) then
save_bonus = save_bonus * 2
end
if not self:hasEffect(self.EFF_SPIN_FATE) then
game:playSoundNear(self, "talents/spell_generic")
end
local mental_save, physical_save, spell_save, defense_bonus = 0
if type == "mental" then mental_save = save_bonus end
if type == "physical" then physical_save = save_bonus end
if type == "spell" then spell_save = save_bonus end
if type == "defense" then defense_bonus = save_bonus end
print("Spin Fate", type, mental_save, physical_save, spell_save, defense_bonus)
self:setEffect(self.EFF_SPIN_FATE, t.getDuration(self, t), {max_bonus = t.getSaveBonus(self, t) * 10, defense = defense_bonus, mental = mental_save, physical = physical_save, spell = spell_save})
return true
end,
info = function(self, t)
local save = t.getSaveBonus(self, t)
local duration = t.getDuration(self, t)
return ([[You've learned to make minor corrections in how future events unfold. Each time an attacker makes a check against your defense or saves the respective value is increased by %d (stacking up to a maximum increase of %d for each value).
The effect will last %d turns but the duration will refresh everytime it's reapplied.
The defense or saving throw increase is doubled while Precognition is active (but the cap remains the same).]]):
format(save, save * 10, duration)
end,
}
newTalent{ newTalent{
name = "Foresight", name = "Foresight",
type = {"chronomancy/chronomancy",3}, type = {"chronomancy/chronomancy",2},
mode = "passive", mode = "passive",
require = temporal_req3, require = temporal_req2,
points = 5, points = 5,
getRadius = function(self, t) return 3 + math.floor(self:getTalentLevel(t) * 2) end, getRadius = function(self, t) return 3 + math.floor(self:getTalentLevel(t) * 2) end,
do_precog_foresight = function(self, t) do_precog_foresight = function(self, t)
...@@ -138,57 +101,80 @@ newTalent{ ...@@ -138,57 +101,80 @@ newTalent{
end, end,
info = function(self, t) info = function(self, t)
local radius = t.getRadius(self, t) local radius = t.getRadius(self, t)
return ([[When the duration of your Precognition expires (or is cancelled with Moment of Prescience) you'll be given a vision of your surroundings, sensing terrain, enemies, objects, and traps in a %d radius.]]): return ([[When the duration of your Precognition expires you'll be given a vision of your surroundings, sensing terrain, enemies, objects, and traps in a %d radius.]]):
format(radius) format(radius)
end, end,
} }
newTalent{ newTalent{
name = "Moment of Prescience", name = "Moment of Prescience",
type = {"chronomancy/chronomancy", 4}, type = {"chronomancy/chronomancy", 3},
require = temporal_req4, require = temporal_req3,
points = 5, points = 5,
paradox = 10, paradox = 10,
cooldown = 24, cooldown = 18,
getDuration = function(self, t) return 2 + math.floor(self:getTalentLevel(t)) end, getDuration = function(self, t) return math.ceil(self:getTalentLevel(t) * 2) end,
getPercentage = function(self, t) return self:getTalentLevel(t) * 10 end,
getDetection = function(self, t) return self:getTalentLevel(t) * 5 end, getDetection = function(self, t) return self:getTalentLevel(t) * 5 end,
on_pre_use = function(self, t, silent) if not self:hasEffect(self.EFF_PRECOGNITION) then if not silent then game.logPlayer(self, "Precognition must be active to use this talent.") end return false end return true end, getDefense = function(self, t) return self:getTalentLevel(t) * 4 end,
tactical = { BUFF = 4 }, tactical = { BUFF = 4 },
no_energy = true, no_energy = true,
no_npc_use = true, no_npc_use = true,
action = function(self, t) action = function(self, t)
game:playSoundNear(self, "talents/spell_generic") local defense_power = t.getDefense(self, t)
-- clear the chronoworlds and the timed effect local detect_power = t.getDetection(self, t)
if game._chronoworlds then game._chronoworlds = nil end
game.player.tmp[self.EFF_PRECOGNITION] = nil
-- check for Spin Fate -- check for Spin Fate
local eff = self:hasEffect(self.EFF_SPIN_FATE) local eff = self:hasEffect(self.EFF_SPIN_FATE)
local mental_power, physical_power, spell_power, accuracy = 0
local percentage = t.getPercentage(self, t)/100
if eff then if eff then
mental_power = (eff.cur_mental or eff.mental) * percentage local bonus = math.max(0, (eff.cur_mental or eff.mental), (eff.cur_physical or eff.physical), (eff.cur_spell or eff.spell))/2
physical_power = (eff.cur_physical or eff.physical) * percentage defense_power = defense_power + bonus
spell_power = (eff.cur_spell or eff.spell) * percentage detect_power = detect_power + bonus
accuracy_power = (eff.cur_defense or eff.defense) * percentage
end end
self:setEffect(self.EFF_PRESCIENCE, t.getDuration(self, t), {detect=t.getDetection(self, t), mental=mental_power, physical=physical_power, spell=spell_power, accuracy=accuracy_power}) self:setEffect(self.EFF_PRESCIENCE, t.getDuration(self, t), {detect=detect_power, defense=defense_power})
if self:knowTalent(self.T_FORESIGHT) then
local t = self:getTalentFromId(self.T_FORESIGHT)
t.do_precog_foresight(self, t)
end
return true return true
end, end,
info = function(self, t) info = function(self, t)
local detect = t.getDetection(self, t) local detect = t.getDetection(self, t)
local defense = t.getDefense(self, t)
local duration = t.getDuration(self, t) local duration = t.getDuration(self, t)
local percent = t.getPercentage(self, t) return ([[You pull your awareness fully into the moment, increasing your stealth detection and see invisibility by %d and your defense by %d for %d turns.
return ([[While under the affects of Precognition you may use Moment of Prescience to cancel it, walking the timeline exactly as you did before to reach the present. If you have Spin Fate going when you cast this spell you'll gain a bonus to these values equal to 50%% of your highest active spin.
Doing so will pull your awareness fully into the moment, increasing your stealth detection and see invisibility by %d for %d turns.
If you have Spin Fate going when you cast this spell you'll gain %d%% of your spin as accuracy, attack power, spell power, or mind power as appropriate.
This spell takes no time to cast.]]): This spell takes no time to cast.]]):
format(detect, duration, percent) format(detect, defense, duration)
end,
}
newTalent{
name = "Spin Fate",
type = {"chronomancy/chronomancy", 4},
require = temporal_req4,
mode = "passive",
points = 5,
getDuration = function(self, t) return 1 + math.ceil(self:getTalentLevel(t)) end,
getSaveBonus = function(self, t) return self:getTalentLevel(t) end,
do_spin_fate = function(self, t, type)
local save_bonus = t.getSaveBonus(self, t)
local mental_save, physical_save, spell_save = 0
if type == "mental" then mental_save = save_bonus end
if type == "physical" then physical_save = save_bonus end
if type == "spell" then spell_save = save_bonus end
print("Spin Fate", type, mental_save, physical_save, spell_save)
if type ~= "defense" then
if not self:hasEffect(self.EFF_SPIN_FATE) then
game:playSoundNear(self, "talents/spell_generic")
end
self:setEffect(self.EFF_SPIN_FATE, t.getDuration(self, t), {max_bonus = t.getSaveBonus(self, t) * 5, mental = mental_save, physical = physical_save, spell = spell_save})
end
return true
end,
info = function(self, t)
local save = t.getSaveBonus(self, t)
local duration = t.getDuration(self, t)
return ([[You've learned to make minor corrections in how future events unfold. Each time an attacker makes a check against one of your saving throws the respective value is increased by %d (stacking up to a maximum increase of %d for each value).
The effect will last %d turns but the duration will refresh everytime it's reapplied.]]):
format(save, save * 5, duration)
end, end,
} }
\ No newline at end of file
...@@ -94,8 +94,8 @@ newTalent{ ...@@ -94,8 +94,8 @@ newTalent{
direct_hit = true, direct_hit = true,
requires_target = true, requires_target = true,
range = 6, range = 6,
getTalentCount = function(self, t) return 2 + math.floor(self:getTalentLevel(t) * getParadoxModifier(self, pm)/2) end, getTalentCount = function(self, t) return 1 + math.floor(self:getTalentLevel(t) * getParadoxModifier(self, pm)/2) end,
getCooldown = function(self, t) return math.ceil(self:getTalentLevel(t)) end, getCooldown = function(self, t) return 1 + math.ceil(self:getTalentLevel(t)/3) end,
action = function(self, t) action = function(self, t)
local tg = {type="hit", range=self:getTalentRange(t)} local tg = {type="hit", range=self:getTalentRange(t)}
local tx, ty = self:getTarget(tg) local tx, ty = self:getTarget(tg)
......
...@@ -26,8 +26,8 @@ newTalent{ ...@@ -26,8 +26,8 @@ newTalent{
cooldown = 10, cooldown = 10,
tactical = { BUFF = 2 }, tactical = { BUFF = 2 },
points = 5, points = 5,
getDamage = function(self, t) return (2 * self:getTalentLevel(t)) + self:combatTalentSpellDamage(t, 10, 70) end, getDamage = function(self, t) return self:combatTalentSpellDamage(t, 15, 40) end,
getArmorPen = function(self, t) return (1 * self:getTalentLevel(t)) + self:combatTalentSpellDamage(t, 5, 15) end, getParadoxReduction = function(self, t) return self:getTalentLevel(t) end,
activate = function(self, t) activate = function(self, t)
return {} return {}
end, end,
...@@ -36,9 +36,9 @@ newTalent{ ...@@ -36,9 +36,9 @@ newTalent{
end, end,
info = function(self, t) info = function(self, t)
local damage = t.getDamage(self, t) local damage = t.getDamage(self, t)
local ap = t.getArmorPen(self, t) local paradox_reduction = t.getParadoxReduction(self, t)
return ([[Folds a single dimension of your weapons (or ammo), allowing them to penetrate %d armor and adding %0.2f temporal damage to your strikes. return ([[Folds a single dimension of your weapons (or ammo), adding %0.2f temporal damage to your strikes and reducing your Paradox by %0.1f every time you land an attack.
The armor penetration and damage will increase with your Spellpower.]]):format(ap, damDesc(self, DamageType.TEMPORAL, damage)) The damage will increase with your Spellpower.]]):format(damDesc(self, DamageType.TEMPORAL, damage), paradox_reduction)
end, end,
} }
...@@ -56,7 +56,7 @@ newTalent{ ...@@ -56,7 +56,7 @@ newTalent{
return 4 + math.floor(self:getTalentLevel(t)) return 4 + math.floor(self:getTalentLevel(t))
end, end,
getConfuseDuration = function(self, t) return math.floor((self:getTalentLevel(t) + 2) * getParadoxModifier(self, pm)) end, getConfuseDuration = function(self, t) return math.floor((self:getTalentLevel(t) + 2) * getParadoxModifier(self, pm)) end,
getConfuseEfficency = function(self, t) return (50 + self:getTalentLevelRaw(t) * 10) end, getConfuseEfficency = function(self, t) return (30 + self:getTalentLevelRaw(t) * 10) end,
action = function(self, t) action = function(self, t)
local tg = {type="hit", range=self:getTalentRange(t)} local tg = {type="hit", range=self:getTalentRange(t)}
local tx, ty, target = self:getTarget(tg) local tx, ty, target = self:getTarget(tg)
......
...@@ -26,7 +26,7 @@ newTalent{ ...@@ -26,7 +26,7 @@ newTalent{
cooldown = 10, cooldown = 10,
tactical = { CLOSEIN = 2, ESCAPE = 2 }, tactical = { CLOSEIN = 2, ESCAPE = 2 },
range = function(self, t) range = function(self, t)
return 4 + math.floor(self:getTalentLevel(t)) return 2 + math.floor(self:getTalentLevel(t))
end, end,
requires_target = true, requires_target = true,
target = function(self, t) target = function(self, t)
...@@ -148,7 +148,7 @@ newTalent{ ...@@ -148,7 +148,7 @@ newTalent{
return 10 + math.floor(self:getTalentLevel(t)/2) return 10 + math.floor(self:getTalentLevel(t)/2)
end, end,
radius = function(self, t) radius = function(self, t)
return math.floor(7 - self:getTalentLevel(t)) return 7 - math.floor(self:getTalentLevel(t))
end, end,
requires_target = true, requires_target = true,
getDuration = function (self, t) return 5 + math.floor(self:getTalentLevel(t)*getParadoxModifier(self, pm)) end, getDuration = function (self, t) return 5 + math.floor(self:getTalentLevel(t)*getParadoxModifier(self, pm)) end,
......
...@@ -23,6 +23,7 @@ newTalent{ ...@@ -23,6 +23,7 @@ newTalent{
require = temporal_req1, require = temporal_req1,
mode = "sustained", mode = "sustained",
points = 5, points = 5,
sustain_stamina = 50,
sustain_paradox = 100, sustain_paradox = 100,
cooldown = 18, cooldown = 18,
tactical = { BUFF = 2 }, tactical = { BUFF = 2 },
...@@ -31,19 +32,17 @@ newTalent{ ...@@ -31,19 +32,17 @@ newTalent{
game:playSoundNear(self, "talents/arcane") game:playSoundNear(self, "talents/arcane")
return { return {
stats = self:addTemporaryValue("inc_stats", {[self.STAT_STR] = t.getPower(self, t)}), stats = self:addTemporaryValue("inc_stats", {[self.STAT_STR] = t.getPower(self, t)}),
phys = self:addTemporaryValue("combat_physresist", t.getPower(self, t)),
particle = self:addParticles(Particles.new("temporal_focus", 1)), particle = self:addParticles(Particles.new("temporal_focus", 1)),
} }
end, end,
deactivate = function(self, t, p) deactivate = function(self, t, p)
self:removeParticles(p.particle) self:removeParticles(p.particle)
self:removeTemporaryValue("inc_stats", p.stats) self:removeTemporaryValue("inc_stats", p.stats)
self:removeTemporaryValue("combat_physresist", p.phys)
return true return true
end, end,
info = function(self, t) info = function(self, t)
local power = t.getPower(self, t) local power = t.getPower(self, t)
return ([[You've learned to boost your strength through your control of the spacetime continuum. Increases your strength and your physical saves by %d. return ([[You've learned to boost your strength through your control of the spacetime continuum. Increases your strength by %d.
The effect will scale with your Willpower stat.]]):format(power) The effect will scale with your Willpower stat.]]):format(power)
end end
} }
...@@ -74,6 +73,7 @@ newTalent{ ...@@ -74,6 +73,7 @@ newTalent{
require = temporal_req3, require = temporal_req3,
mode = "sustained", mode = "sustained",
points = 5, points = 5,
sustain_stamina = 50,
sustain_paradox = 100, sustain_paradox = 100,
cooldown = 18, cooldown = 18,
tactical = { BUFF = 2 }, tactical = { BUFF = 2 },
...@@ -82,19 +82,17 @@ newTalent{ ...@@ -82,19 +82,17 @@ newTalent{
game:playSoundNear(self, "talents/arcane") game:playSoundNear(self, "talents/arcane")
return { return {
stats = self:addTemporaryValue("inc_stats", {[self.STAT_MAG] = t.getPower(self, t)}), stats = self:addTemporaryValue("inc_stats", {[self.STAT_MAG] = t.getPower(self, t)}),
spell = self:addTemporaryValue("combat_spellresist", t.getPower(self, t)),
particle = self:addParticles(Particles.new("arcane_power", 1)), particle = self:addParticles(Particles.new("arcane_power", 1)),
} }
end, end,
deactivate = function(self, t, p) deactivate = function(self, t, p)
self:removeTemporaryValue("inc_stats", p.stats) self:removeTemporaryValue("inc_stats", p.stats)
self:removeTemporaryValue("combat_spellresist", p.spell)
self:removeParticles(p.particle) self:removeParticles(p.particle)
return true return true
end, end,
info = function(self, t) info = function(self, t)
local power = t.getPower(self, t) local power = t.getPower(self, t)
return ([[You've learned to boost your magic through your control over the spacetime continuum. Increases your magic and your spell saves by %d. return ([[You've learned to boost your magic through your control over the spacetime continuum. Increases your magic by %d.
The effect will scale with your Willpower stat.]]):format(power) The effect will scale with your Willpower stat.]]):format(power)
end end
} }
......
...@@ -47,7 +47,7 @@ newTalent{ ...@@ -47,7 +47,7 @@ newTalent{
require = chrono_req_high2, require = chrono_req_high2,
points = 5, points = 5,
paradox = 5, paradox = 5,
cooldown = 6, cooldown = 4,
tactical = { ATTACK = {TEMPORAL = 2} }, tactical = { ATTACK = {TEMPORAL = 2} },
range = 10, range = 10,
direct_hit = true, direct_hit = true,
......
...@@ -39,7 +39,7 @@ newTalent{ ...@@ -39,7 +39,7 @@ newTalent{
return ([[You stand in the way of magical damage. That which does not kill you makes you stronger. return ([[You stand in the way of magical damage. That which does not kill you makes you stronger.
Each time you are hit by a magical damage you get a %d%% resistance to this elemental for 7 turns. Each time you are hit by a magical damage you get a %d%% resistance to this elemental for 7 turns.
If antimagic shield is not active you also absorb part of the impact and use it to fuel your own powers, decreasing your equilibrium by %d and increasing your stamina by %d. If antimagic shield is not active you also absorb part of the impact and use it to fuel your own powers, decreasing your equilibrium by %d and increasing your stamina by %d.
The effects will increase with your Willpower stat.]]): The effects will increase with your Mindpower.]]):
format( format(
self:combatTalentMindDamage(t, 10, 40), self:combatTalentMindDamage(t, 10, 40),
1 + self:combatTalentMindDamage(t, 10, 5), 1 + self:combatTalentMindDamage(t, 10, 5),
...@@ -113,7 +113,7 @@ newTalent{ ...@@ -113,7 +113,7 @@ newTalent{
info = function(self, t) info = function(self, t)
return ([[Surround yourself with a shield that will absorb at most %d magical or elemental damage per attack. return ([[Surround yourself with a shield that will absorb at most %d magical or elemental damage per attack.
Each time damage is absorbed your equilibrium increases by 1 for every 30 points of damage and a check is made, if it fails the shield will crumble. Each time damage is absorbed your equilibrium increases by 1 for every 30 points of damage and a check is made, if it fails the shield will crumble.
Damage shield can absorb will increase with your Willpower stat.]]): Damage shield can absorb will increase with your Mindpower.]]):
format(self:combatTalentMindDamage(t, 20, 80)) format(self:combatTalentMindDamage(t, 20, 80))
end, end,
} }
...@@ -166,7 +166,7 @@ newTalent{ ...@@ -166,7 +166,7 @@ newTalent{
return ([[Drain %d mana, %d vim, %d positive and negative energies from your target, triggering a chain reaction that explodes in a burst of arcane damage. return ([[Drain %d mana, %d vim, %d positive and negative energies from your target, triggering a chain reaction that explodes in a burst of arcane damage.
The damage done is 130%% of the mana drained, 260%% of the vim drained, 520%% of the positive or negative energy drained, whichever is higher. The damage done is 130%% of the mana drained, 260%% of the vim drained, 520%% of the positive or negative energy drained, whichever is higher.
The effect will increase with your Willpower stat.]]): The effect will increase with your Mindpower.]]):
format(mana, vim, positive, negative) format(mana, vim, positive, negative)
end, end,
} }
...@@ -74,7 +74,8 @@ newTalent{ ...@@ -74,7 +74,8 @@ newTalent{
end, end,
info = function(self, t) info = function(self, t)
return ([[Your skin forms icy scales, damaging all that hit you for %0.2f cold damage and increasing your armor by %d. return ([[Your skin forms icy scales, damaging all that hit you for %0.2f cold damage and increasing your armor by %d.
Each point in cold drake talents also increases your cold resistance by 1%%.]]):format(damDesc(self, DamageType.COLD, t.getDamage(self, t)), t.getArmor(self, t)) Each point in cold drake talents also increases your cold resistance by 1%%.
The damage and defense will scale with your Willpower stat.]]):format(damDesc(self, DamageType.COLD, t.getDamage(self, t)), t.getArmor(self, t))
end, end,
} }
......
...@@ -92,7 +92,7 @@ newTalent{ ...@@ -92,7 +92,7 @@ newTalent{
local percent = t.getPercent(self, t) local percent = t.getPercent(self, t)
return ([[Generate an electrical field around you in a radius of 1. Any creature caught inside will lose %d%% of its current life (effect decreased for higher creature ranks). return ([[Generate an electrical field around you in a radius of 1. Any creature caught inside will lose %d%% of its current life (effect decreased for higher creature ranks).
This effect can not kill creatures. This effect can not kill creatures.
Life loss will increase with the Willpower stat. Life loss will increase with your Mindpower.
Each point in storm drake talents also increases your lightning resistance by 1%%.]]):format(percent) Each point in storm drake talents also increases your lightning resistance by 1%%.]]):format(percent)
end, end,
} }
...@@ -163,7 +163,7 @@ newTalent{ ...@@ -163,7 +163,7 @@ newTalent{
Any foe caught in its path take %0.2f lightning damage. Any foe caught in its path take %0.2f lightning damage.
When it reaches its target it explodes in a radius of 1 for %0.2f lightning damage, %0.2f physical damage. All affected creatures will be knocked back and the targeted creature will be stunned for 4 turns. When it reaches its target it explodes in a radius of 1 for %0.2f lightning damage, %0.2f physical damage. All affected creatures will be knocked back and the targeted creature will be stunned for 4 turns.
The tornado will last for %d turns or until it reaches its target. The tornado will last for %d turns or until it reaches its target.
Damage will increase with your Willpower. Damage will increase with your Mindpower.
Each point in storm drake talents also increases your lightning resistance by 1%%.]]):format( Each point in storm drake talents also increases your lightning resistance by 1%%.]]):format(
damDesc(self, DamageType.LIGHTNING, self:combatTalentMindDamage(t, 10, 110)), damDesc(self, DamageType.LIGHTNING, self:combatTalentMindDamage(t, 10, 110)),
damDesc(self, DamageType.LIGHTNING, self:combatTalentMindDamage(t, 15, 190)), damDesc(self, DamageType.LIGHTNING, self:combatTalentMindDamage(t, 15, 190)),
......
...@@ -1017,29 +1017,22 @@ newEffect{ ...@@ -1017,29 +1017,22 @@ newEffect{
newEffect{ newEffect{
name = "PRESCIENCE", image = "talents/premonition.png", name = "PRESCIENCE", image = "talents/premonition.png",
desc = "Prescience", desc = "Prescience",
long_desc = function(self, eff) return ("The target's awareness is fully in the present, increasing stealth detection and see invisibility by %d, accuracy by %d, attack power by %d, spell power by %d, and mindpower by %d.") long_desc = function(self, eff) return ("The target's awareness is fully in the present, increasing stealth detection and see invisibility by %d and defense by %d."):format(eff.detect, eff.defense) end,
:format(eff.detect, eff.accuracy, eff.physical, eff.spell, eff.mental) end,
type = "magical", type = "magical",
subtype = { sense=true, temporal=true }, subtype = { sense=true, temporal=true },
status = "beneficial", status = "beneficial",
parameters = { detect = 10, mental=1, physical=1, spell=1, accuracy=1 }, parameters = { detect = 10, defense=1},
on_gain = function(self, err) return "#Target# has found the present moment!", "+Prescience" end, on_gain = function(self, err) return "#Target# has found the present moment!", "+Prescience" end,
on_lose = function(self, err) return "#Target#'s awareness returns to normal.", "-Prescience" end, on_lose = function(self, err) return "#Target#'s awareness returns to normal.", "-Prescience" end,
activate = function(self, eff) activate = function(self, eff)
eff.atkid = self:addTemporaryValue("combat_atk", eff.accuracy) eff.defid = self:addTemporaryValue("combat_def", eff.defense)
eff.physid = self:addTemporaryValue("combat_dam", eff.physical)
eff.spellid = self:addTemporaryValue("combat_spellpower", eff.spell)
eff.mentid = self:addTemporaryValue("combat_mindpower", eff.mental)
eff.invis = self:addTemporaryValue("see_invisible", eff.detect) eff.invis = self:addTemporaryValue("see_invisible", eff.detect)
eff.stealth = self:addTemporaryValue("see_stealth", eff.detect) eff.stealth = self:addTemporaryValue("see_stealth", eff.detect)
end, end,
deactivate = function(self, eff) deactivate = function(self, eff)
self:removeTemporaryValue("see_invisible", eff.invis) self:removeTemporaryValue("see_invisible", eff.invis)
self:removeTemporaryValue("see_stealth", eff.stealth) self:removeTemporaryValue("see_stealth", eff.stealth)
self:removeTemporaryValue("combat_atk", eff.atkid) self:removeTemporaryValue("combat_def", eff.defid)
self:removeTemporaryValue("combat_dam", eff.physid)
self:removeTemporaryValue("combat_spellpower", eff.spellid)
self:removeTemporaryValue("combat_mindpower", eff.mentid)
end, end,
} }
...@@ -1375,12 +1368,12 @@ newEffect{ ...@@ -1375,12 +1368,12 @@ newEffect{
newEffect{ newEffect{
name = "SPIN_FATE", image = "talents/spin_fate.png", name = "SPIN_FATE", image = "talents/spin_fate.png",
desc = "Spin Fate", desc = "Spin Fate",
long_desc = function(self, eff) return ("The target's defense has been increased by %d, physical save by %d, spell saves by %d, and mental saves by %d."): long_desc = function(self, eff) return ("The target's physical save has been increased by %d, spell saves by %d, and mental saves by %d."):
format(eff.cur_defense or eff.defense, eff.cur_physical or eff.physical, eff.cur_spell or eff.spell, eff.cur_mental or eff.mental) end, format(eff.cur_physical or eff.physical, eff.cur_spell or eff.spell, eff.cur_mental or eff.mental) end,
type = "magical", type = "magical",
subtype = { temporal=true }, subtype = { temporal=true },
status = "beneficial", status = "beneficial",
parameters = { physical=0, mental=0, spell=0, defense=0, max = 10}, parameters = { physical=0, mental=0, spell=0, max = 10},
on_gain = function(self, err) return "#Target# takes fate by the hand.", "+Spin Fate" end, on_gain = function(self, err) return "#Target# takes fate by the hand.", "+Spin Fate" end,
on_lose = function(self, err) return "#Target#'s fate is no longer being spun.", "-Spin Fate" end, on_lose = function(self, err) return "#Target#'s fate is no longer being spun.", "-Spin Fate" end,
on_merge = function(self, old_eff, new_eff) on_merge = function(self, old_eff, new_eff)
...@@ -1388,18 +1381,15 @@ newEffect{ ...@@ -1388,18 +1381,15 @@ newEffect{
self:removeTemporaryValue("combat_physresist", old_eff.physid) self:removeTemporaryValue("combat_physresist", old_eff.physid)
self:removeTemporaryValue("combat_spellresist", old_eff.spellid) self:removeTemporaryValue("combat_spellresist", old_eff.spellid)
self:removeTemporaryValue("combat_mentalresist", old_eff.mentalid) self:removeTemporaryValue("combat_mentalresist", old_eff.mentalid)
self:removeTemporaryValue("combat_def", old_eff.defenseid)
-- combine the old and new values -- combine the old and new values
old_eff.cur_physical = math.min(new_eff.max_bonus, old_eff.cur_physical + new_eff.physical) old_eff.cur_physical = math.min(new_eff.max_bonus, old_eff.cur_physical + new_eff.physical)
old_eff.cur_spell = math.min(new_eff.max_bonus, old_eff.cur_spell + new_eff.spell) old_eff.cur_spell = math.min(new_eff.max_bonus, old_eff.cur_spell + new_eff.spell)
old_eff.cur_mental = math.min(new_eff.max_bonus, old_eff.cur_mental + new_eff.mental) old_eff.cur_mental = math.min(new_eff.max_bonus, old_eff.cur_mental + new_eff.mental)
old_eff.cur_defense = math.min(new_eff.max_bonus, old_eff.cur_defense + new_eff.defense)
-- and apply the current values -- and apply the current values
old_eff.physid = self:addTemporaryValue("combat_physresist", old_eff.cur_physical) old_eff.physid = self:addTemporaryValue("combat_physresist", old_eff.cur_physical)
old_eff.spellid = self:addTemporaryValue("combat_spellresist", old_eff.cur_spell) old_eff.spellid = self:addTemporaryValue("combat_spellresist", old_eff.cur_spell)
old_eff.mentalid = self:addTemporaryValue("combat_mentalresist", old_eff.cur_mental) old_eff.mentalid = self:addTemporaryValue("combat_mentalresist", old_eff.cur_mental)
old_eff.defenseid = self:addTemporaryValue("combat_def", old_eff.cur_defense)
old_eff.dur = new_eff.dur old_eff.dur = new_eff.dur
return old_eff return old_eff
end, end,
...@@ -1408,19 +1398,16 @@ newEffect{ ...@@ -1408,19 +1398,16 @@ newEffect{
eff.cur_physical = eff.physical eff.cur_physical = eff.physical
eff.cur_spell = eff.spell eff.cur_spell = eff.spell
eff.cur_mental = eff.mental eff.cur_mental = eff.mental
eff.cur_defense = eff.defense
-- apply current values -- apply current values
eff.physid = self:addTemporaryValue("combat_physresist", eff.physical) eff.physid = self:addTemporaryValue("combat_physresist", eff.physical)
eff.spellid = self:addTemporaryValue("combat_spellresist", eff.spell) eff.spellid = self:addTemporaryValue("combat_spellresist", eff.spell)
eff.mentalid = self:addTemporaryValue("combat_mentalresist", eff.mental) eff.mentalid = self:addTemporaryValue("combat_mentalresist", eff.mental)
eff.defenseid = self:addTemporaryValue("combat_def", eff.defense)
eff.particle = self:addParticles(Particles.new("arcane_power", 1)) eff.particle = self:addParticles(Particles.new("arcane_power", 1))
end, end,
deactivate = function(self, eff) deactivate = function(self, eff)
self:removeTemporaryValue("combat_physresist", eff.physid) self:removeTemporaryValue("combat_physresist", eff.physid)
self:removeTemporaryValue("combat_spellresist", eff.spellid) self:removeTemporaryValue("combat_spellresist", eff.spellid)
self:removeTemporaryValue("combat_mentalresist", eff.mentalid) self:removeTemporaryValue("combat_mentalresist", eff.mentalid)
self:removeTemporaryValue("combat_def", eff.defenseid)
self:removeParticles(eff.particle) self:removeParticles(eff.particle)
end, end,
} }
......
...@@ -338,6 +338,8 @@ newEffect{ ...@@ -338,6 +338,8 @@ newEffect{
local t = game.player:getTalentFromId(game.player.T_FORESIGHT) local t = game.player:getTalentFromId(game.player.T_FORESIGHT)
t.do_precog_foresight(self, t) t.do_precog_foresight(self, t)
end end
game.player.energy.value = game.energy_to_act
game.paused = true
end) end)
end, end,
} }
......
...@@ -202,6 +202,9 @@ function _M:use(item) ...@@ -202,6 +202,9 @@ function _M:use(item)
self:cleanActor(self.actor) self:cleanActor(self.actor)
self:resurrectBasic(self.actor) self:resurrectBasic(self.actor)
self:restoreResources(self.actor) self:restoreResources(self.actor)
elseif act == "precognition" then
self:resurrectBasic(self.actor)
self.actor:removeEffect(self.actor.EFF_PRECOGNITION)
elseif act == "blood_life" then elseif act == "blood_life" then
self.actor.blood_life = false self.actor.blood_life = false
game.logPlayer(self.actor, "#LIGHT_RED#The Blood of Life rushes through your dead body. You come back to life!") game.logPlayer(self.actor, "#LIGHT_RED#The Blood of Life rushes through your dead body. You come back to life!")
...@@ -244,7 +247,7 @@ end ...@@ -244,7 +247,7 @@ end
function _M:generateList() function _M:generateList()
local list = {} local list = {}
local allow_res = true local allow_res = true
-- Pause the game -- Pause the game
game:onTickEnd(function() game:onTickEnd(function()
game.paused = true game.paused = true
...@@ -259,6 +262,11 @@ function _M:generateList() ...@@ -259,6 +262,11 @@ function _M:generateList()
if config.settings.cheat then list[#list+1] = {name="Resurrect by cheating", action="cheat"} end if config.settings.cheat then list[#list+1] = {name="Resurrect by cheating", action="cheat"} end
if not self.actor.no_resurrect and allow_res then if not self.actor.no_resurrect and allow_res then
if self.actor:hasEffect(self.actor.EFF_PRECOGNITION) then
self:use{action="precognition"}
self.dont_show = true
return
end
if self.actor:isTalentActive(self.actor.T_LICHFORM) then if self.actor:isTalentActive(self.actor.T_LICHFORM) then
self:use{action="lichform"} self:use{action="lichform"}
self.dont_show = true self.dont_show = true
......
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