From 8ab52a6293889d27fc9b9bde95e839a25b7805fe Mon Sep 17 00:00:00 2001 From: dg <dg@51575b47-30f0-44d4-a5cc-537603b46e54> Date: Tue, 24 Apr 2012 09:28:57 +0000 Subject: [PATCH] reduce boss talents git-svn-id: http://svn.net-core.org/repos/t-engine4@5048 51575b47-30f0-44d4-a5cc-537603b46e54 --- game/engines/default/engine/interface/ActorTalents.lua | 2 +- game/modules/tome/class/Game.lua | 4 +--- game/modules/tome/class/GameState.lua | 4 ++-- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/game/engines/default/engine/interface/ActorTalents.lua b/game/engines/default/engine/interface/ActorTalents.lua index da891732ed..c1ea896cdc 100644 --- a/game/engines/default/engine/interface/ActorTalents.lua +++ b/game/engines/default/engine/interface/ActorTalents.lua @@ -293,7 +293,7 @@ function _M:learnTalent(t_id, force, nb) self.talents[t_id] = (self.talents[t_id] or 0) + (nb or 1) - if t.on_learn then t.on_learn(self, t) end + if t.on_learn then for i = 1, (nb or 1) do t.on_learn(self, t) end end self.changed = true return true diff --git a/game/modules/tome/class/Game.lua b/game/modules/tome/class/Game.lua index 9d20384653..1ebbdac986 100644 --- a/game/modules/tome/class/Game.lua +++ b/game/modules/tome/class/Game.lua @@ -1115,9 +1115,7 @@ function _M:setupCommands() end end end end, [{"_g","ctrl"}] = function() if config.settings.cheat then - local o = self.state:generateRandart(false) - o:identify(true) - self.zone:addEntity(self.level, o, "object", game.player.x, game.player.y) + self.state:debugRandomZone() end end, [{"_f","ctrl"}] = function() if config.settings.cheat then self.player.quests["love-melinda"] = nil diff --git a/game/modules/tome/class/GameState.lua b/game/modules/tome/class/GameState.lua index 6d9f3b64bd..d5889e7b23 100644 --- a/game/modules/tome/class/GameState.lua +++ b/game/modules/tome/class/GameState.lua @@ -1545,7 +1545,7 @@ function _M:createRandomBoss(base, data) for tid, v in pairs(class.talents or {}) do local t = b:getTalentFromId(tid) if not t.no_npc_use and (not t.random_boss_rarity or rng.chance(t.random_boss_rarity)) then - local max = (t.points == 1) and 1 or math.ceil(t.points * 1.6) + local max = (t.points == 1) and 1 or math.ceil(t.points * 1.2) local step = max / 50 tres[1][tid] = v + math.ceil(step * data.level) end @@ -1563,7 +1563,7 @@ function _M:createRandomBoss(base, data) local t = b:getTalentFromId(tid) if t then print(" * talent", tid) - local max = (t.points == 1) and 1 or math.ceil(t.points * 1.4) + local max = (t.points == 1) and 1 or math.ceil(t.points * 1.2) local step = max / 50 b.learn_tids[tid] = math.ceil(step * data.level) end -- GitLab