From c95c85ed97706151a445d196931a0a59d1f9b023 Mon Sep 17 00:00:00 2001
From: dg <dg@51575b47-30f0-44d4-a5cc-537603b46e54>
Date: Sat, 3 Sep 2011 10:32:05 +0000
Subject: [PATCH] Limited max projectile speed reduction on talents providing
 it Derth post-attack chat now accounts for being an antimagic char

git-svn-id: http://svn.net-core.org/repos/t-engine4@4313 51575b47-30f0-44d4-a5cc-537603b46e54
---
 game/modules/tome/class/Game.lua                          | 1 +
 game/modules/tome/data/chats/derth-attack-over.lua        | 8 ++++++++
 game/modules/tome/data/talents/chronomancy/energy.lua     | 2 +-
 game/modules/tome/data/talents/spells/meta.lua            | 2 +-
 game/modules/tome/data/talents/spells/nightfall.lua       | 2 +-
 .../tome/data/talents/techniques/field-control.lua        | 4 ++--
 6 files changed, 14 insertions(+), 5 deletions(-)

diff --git a/game/modules/tome/class/Game.lua b/game/modules/tome/class/Game.lua
index 9e2a405a01..b432b965b2 100644
--- a/game/modules/tome/class/Game.lua
+++ b/game/modules/tome/class/Game.lua
@@ -1677,6 +1677,7 @@ function _M:countBirthUnlocks()
 		mage_cryomancer = true,
 		mage_necromancer = true,
 
+		rogue_marauder = true,
 		rogue_poisons = true,
 
 		divine_anorithil = true,
diff --git a/game/modules/tome/data/chats/derth-attack-over.lua b/game/modules/tome/data/chats/derth-attack-over.lua
index a8a689fe63..b51b4b7262 100644
--- a/game/modules/tome/data/chats/derth-attack-over.lua
+++ b/game/modules/tome/data/chats/derth-attack-over.lua
@@ -38,8 +38,16 @@ newChat{ id="quest2",
 I have heard of rumours of a reclusive town of wise and powerful men somewhere in the mountains. Maybe they could help? If they even exist...
 There are also those Zigur-something people that claim to fight magic. Why are they not here?!]],
 	answers = {
+		{"You mean the Ziguranth. That would be me.", cond=function(npc, player) return player:isQuestStatus("antimagic", engine.Quest.DONE) end, jump="zigur"},
 		{"I will not let you down.", action=function(npc, player) player:hasQuest("lightning-overload"):done_derth() end},
 	}
 }
 
+newChat{ id="zigur",
+	text = [[Well then please do something about this evil magic!]],
+	answers = {
+		{"I will!", action=function(npc, player) player:hasQuest("lightning-overload"):done_derth() end},
+	}
+}
+
 return "welcome"
diff --git a/game/modules/tome/data/talents/chronomancy/energy.lua b/game/modules/tome/data/talents/chronomancy/energy.lua
index e17113e196..2d3f7e609e 100644
--- a/game/modules/tome/data/talents/chronomancy/energy.lua
+++ b/game/modules/tome/data/talents/chronomancy/energy.lua
@@ -61,7 +61,7 @@ newTalent{
 	sustain_paradox = 75,
 	cooldown = 10,
 	tactical = { BUFF = 2 },
-	getPower = function(self, t) return 10 + (self:combatTalentSpellDamage(t, 10, 50)) end,
+	getPower = function(self, t) return math.min(90, 10 + (self:combatTalentSpellDamage(t, 10, 50))) end,
 	activate = function(self, t)
 		game:playSoundNear(self, "talents/heal")
 		return {
diff --git a/game/modules/tome/data/talents/spells/meta.lua b/game/modules/tome/data/talents/spells/meta.lua
index fd2670dc04..1a511e6d1f 100644
--- a/game/modules/tome/data/talents/spells/meta.lua
+++ b/game/modules/tome/data/talents/spells/meta.lua
@@ -151,7 +151,7 @@ newTalent{
 	info = function(self, t)
 		local talentcount = t.getTalentCount(self, t)
 		local maxlevel = t.getMaxLevel(self, t)
-		return ([[Your mastery of the arcane flows allow you to reset the cooldown of %d of your spells of level %d or less.]]):
+		return ([[Your mastery of the arcane flows allow you to reset the cooldown of %d of your spells of tier %d or less.]]):
 		format(talentcount, maxlevel)
 	end,
 }
diff --git a/game/modules/tome/data/talents/spells/nightfall.lua b/game/modules/tome/data/talents/spells/nightfall.lua
index 227935a45e..9415854bf3 100644
--- a/game/modules/tome/data/talents/spells/nightfall.lua
+++ b/game/modules/tome/data/talents/spells/nightfall.lua
@@ -39,7 +39,7 @@ newTalent{
 	direct_hit = function(self, t) if self:getTalentLevel(t) >= 3 then return true else return false end end,
 	target = function(self, t)
 		local tg = {type="bolt", range=self:getTalentRange(t), friendlyfire=isFF(self), talent=t, display={particle="bolt_dark", trail="darktrail"}}
-		if self:getTalentLevel(t) >= 5 then tg.type = "beam" end
+		if self:getTalentLevel(t) >= 3 then tg.type = "beam" end
 		return tg
 	end,
 	getDamage = function(self, t) return self:combatTalentSpellDamage(t, 25, 230) end,
diff --git a/game/modules/tome/data/talents/techniques/field-control.lua b/game/modules/tome/data/talents/techniques/field-control.lua
index 34b9bb89c5..9cc78c4660 100644
--- a/game/modules/tome/data/talents/techniques/field-control.lua
+++ b/game/modules/tome/data/talents/techniques/field-control.lua
@@ -115,7 +115,7 @@ newTalent{
 	tactical = { BUFF = 2 },
 	activate = function(self, t)
 		return {
-			slow_projectiles = self:addTemporaryValue("slow_projectiles", 15 + self:getDex(10, true) * self:getTalentLevel(t)),
+			slow_projectiles = self:addTemporaryValue("slow_projectiles", math.min(90, 15 + self:getDex(10, true) * self:getTalentLevel(t))),
 		}
 	end,
 
@@ -125,6 +125,6 @@ newTalent{
 	end,
 	info = function(self, t)
 		return ([[Your great dexterity allows you to see incoming projectiles (spells, arrows, ...), slowing them down by %d%%.]]):
-		format(15 + self:getDex(10, true) * self:getTalentLevel(t))
+		format(math.min(90, 15 + self:getDex(10, true) * self:getTalentLevel(t)))
 	end,
 }
-- 
GitLab