diff --git a/game/engines/default/engine/Object.lua b/game/engines/default/engine/Object.lua index f65d674e26a470e2e37d5e81862c69a0419f79e4..429d0ebf097fee90bdb8fa1803952ba8aa0fd87c 100644 --- a/game/engines/default/engine/Object.lua +++ b/game/engines/default/engine/Object.lua @@ -203,8 +203,13 @@ function _M:getRequirementDesc(who) end if req.talent then for _, tid in ipairs(req.talent) do - local c = who:knowTalent(tid) and {"color", 0x00,0xff,0x00} or {"color", 0xff,0x00,0x00} - str:add(c, "- ", ("Talent %s\n"):format(who:getTalentFromId(tid).name), {"color", "LAST"}, true) + if type(tid) == "table" then + local c = (who:getTalentLevelRaw(tid[1]) >= tid[2]) and {"color", 0x00,0xff,0x00} or {"color", 0xff,0x00,0x00} + str:add(c, "- ", ("Talent %s (level %d)\n"):format(who:getTalentFromId(tid[1]).name, tid[2]), {"color", "LAST"}, true) + else + local c = who:knowTalent(tid) and {"color", 0x00,0xff,0x00} or {"color", 0xff,0x00,0x00} + str:add(c, "- ", ("Talent %s\n"):format(who:getTalentFromId(tid).name), {"color", "LAST"}, true) + end end end return str diff --git a/game/engines/default/engine/interface/ActorInventory.lua b/game/engines/default/engine/interface/ActorInventory.lua index 01f6a4415283af58013b3c28ca994dc6b3f287a7..8f1eefa90e58bae7e8dddf8c86964632479c5e63 100644 --- a/game/engines/default/engine/interface/ActorInventory.lua +++ b/game/engines/default/engine/interface/ActorInventory.lua @@ -280,7 +280,11 @@ function _M:canWearObject(o, try_slot) end if req.talent then for _, tid in ipairs(req.talent) do - if not self:knowTalent(tid) then return nil, "missing dependency" end + if type(tid) == "table" then + if self:getTalentLevelRaw(tid[1]) < tid[2] then return nil, "missing dependency" end + else + if not self:knowTalent(tid) then return nil, "missing dependency" end + end end end end diff --git a/game/modules/tome/class/interface/Combat.lua b/game/modules/tome/class/interface/Combat.lua index 1d49fa5d9bb49ff8aa7dd2c362f4c2e759ee958d..e4a85363cc1d66e71ea328e00540a3d9a4a3de7f 100644 --- a/game/modules/tome/class/interface/Combat.lua +++ b/game/modules/tome/class/interface/Combat.lua @@ -494,11 +494,8 @@ end --- Gets the armor function _M:combatArmor() local add = 0 - if self:hasHeavyArmor() and self:knowTalent(self.T_HEAVY_ARMOUR_TRAINING) then - add = add + self:getTalentLevel(self.T_HEAVY_ARMOUR_TRAINING) * 1.4 - end - if self:hasMassiveArmor() and self:knowTalent(self.T_MASSIVE_ARMOUR_TRAINING) then - add = add + self:getTalentLevel(self.T_MASSIVE_ARMOUR_TRAINING) * 1.6 + if self:hasHeavyArmor() and self:knowTalent(self.T_ARMOUR_TRAINING) then + add = add + self:getTalentLevel(self.T_ARMOUR_TRAINING) * 1.4 end if self:knowTalent(self.T_PHYSICAL_CONDITIONING) then local t = self:getTalentFromId(self.T_PHYSICAL_CONDITIONING) @@ -712,11 +709,8 @@ function _M:physicalCrit(dam, weapon, target) if target:knowTalent(target.T_PROBABILITY_WEAVING) and target:isTalentActive(target.T_PROBABILITY_WEAVING) then chance = chance - target:getTalentLevel(target.T_PROBABILITY_WEAVING) end - if target:hasHeavyArmor() and target:knowTalent(target.T_HEAVY_ARMOUR_TRAINING) then - chance = chance - target:getTalentLevel(target.T_HEAVY_ARMOUR_TRAINING) * 1.9 - end - if target:hasMassiveArmor() and target:knowTalent(target.T_MASSIVE_ARMOUR_TRAINING) then - chance = chance - target:getTalentLevel(target.T_MASSIVE_ARMOUR_TRAINING) * 1.5 + if target:hasHeavyArmor() and target:knowTalent(target.T_ARMOUR_TRAINING) then + chance = chance - target:getTalentLevel(target.T_ARMOUR_TRAINING) * 1.9 end chance = util.bound(chance, 0, 100) @@ -940,7 +934,7 @@ end function _M:hasHeavyArmor() if not self:getInven("BODY") then return end local armor = self:getInven("BODY")[1] - if not armor or armor.subtype ~= "heavy" then + if not armor or (armor.subtype ~= "heavy" and armor.subtype ~= "massive") then return nil end return armor diff --git a/game/modules/tome/data/birth/classes/divine.lua b/game/modules/tome/data/birth/classes/divine.lua index 591999936064cd4e024516d9a580f0bd4756fbfc..4d47361ad97358a7e83460199d63c04b5f7a57cf 100644 --- a/game/modules/tome/data/birth/classes/divine.lua +++ b/game/modules/tome/data/birth/classes/divine.lua @@ -69,7 +69,7 @@ newBirthDescriptor{ [ActorTalents.T_SEARING_LIGHT] = 1, [ActorTalents.T_WEAPON_OF_LIGHT] = 1, [ActorTalents.T_CHANT_OF_FORTITUDE] = 1, - [ActorTalents.T_HEAVY_ARMOUR_TRAINING] = 1, + [ActorTalents.T_ARMOUR_TRAINING] = 3, }, copy = { max_life = 110, diff --git a/game/modules/tome/data/birth/classes/tutorial.lua b/game/modules/tome/data/birth/classes/tutorial.lua index 6fc70f833ae96a347855f38a37493378534851ad..4d0c8b9dedee74099fe9cd68fa0888ba345aafb4 100644 --- a/game/modules/tome/data/birth/classes/tutorial.lua +++ b/game/modules/tome/data/birth/classes/tutorial.lua @@ -56,7 +56,7 @@ newBirthDescriptor{ }, talents = { [ActorTalents.T_WEAPON_COMBAT] = 2, - [ActorTalents.T_HEAVY_ARMOUR_TRAINING] = 2, + [ActorTalents.T_ARMOUR_TRAINING] = 3, [ActorTalents.T_WEAPONS_MASTERY] = 2, }, copy = { diff --git a/game/modules/tome/data/birth/classes/warrior.lua b/game/modules/tome/data/birth/classes/warrior.lua index d69ef14cc1cb32dfa8fd449f0ce3e552a571070b..969eba23947d2b0d3226262e71f63a3b1c410b08 100644 --- a/game/modules/tome/data/birth/classes/warrior.lua +++ b/game/modules/tome/data/birth/classes/warrior.lua @@ -70,7 +70,7 @@ newBirthDescriptor{ [ActorTalents.T_SHIELD_PUMMEL] = 1, [ActorTalents.T_SHIELD_WALL] = 1, [ActorTalents.T_WEAPON_COMBAT] = 1, - [ActorTalents.T_HEAVY_ARMOUR_TRAINING] = 1, + [ActorTalents.T_ARMOUR_TRAINING] = 3, }, copy = { resolvers.equip{ id=true, @@ -115,7 +115,7 @@ newBirthDescriptor{ [ActorTalents.T_DEATH_DANCE] = 1, [ActorTalents.T_STUNNING_BLOW] = 1, [ActorTalents.T_WEAPON_COMBAT] = 1, - [ActorTalents.T_HEAVY_ARMOUR_TRAINING] = 1, + [ActorTalents.T_ARMOUR_TRAINING] = 2, }, copy = { resolvers.equip{ id=true, @@ -210,8 +210,8 @@ newBirthDescriptor{ [ActorTalents.T_UPPERCUT] = 1, [ActorTalents.T_DOUBLE_STRIKE] = 1, [ActorTalents.T_WEAPON_COMBAT] = 1, - [ActorTalents.T_HEAVY_ARMOUR_TRAINING] = 1, - + [ActorTalents.T_ARMOUR_TRAINING] = 1, + -- base monk attack [ActorTalents.T_EMPTY_HAND] = 1, }, diff --git a/game/modules/tome/data/general/npcs/construct.lua b/game/modules/tome/data/general/npcs/construct.lua index 4a8c95b405f7f4393bc6ef1491e8d060bb1ee6ea..5057f2a3ad649e408833ecf8696ba1b6feffc989 100644 --- a/game/modules/tome/data/general/npcs/construct.lua +++ b/game/modules/tome/data/general/npcs/construct.lua @@ -49,8 +49,7 @@ newEntity{ stats = { str=20, mag=16, con=22 }, resolvers.talents{ [Talents.T_STAMINA_POOL]=1, [Talents.T_MANA_POOL]=1, - [Talents.T_HEAVY_ARMOUR_TRAINING]={base=1, every=5, max=10}, - [Talents.T_MASSIVE_ARMOUR_TRAINING]={base=1, every=5, max=10}, + [Talents.T_ARMOUR_TRAINING]={base=4, every=5, max=10}, }, } diff --git a/game/modules/tome/data/general/npcs/elven-caster.lua b/game/modules/tome/data/general/npcs/elven-caster.lua index d8873c3c18941cf305ad5037345f362a932693d6..980b682a332c3fc6b6b555999ddfe14bd4f6a7ef 100644 --- a/game/modules/tome/data/general/npcs/elven-caster.lua +++ b/game/modules/tome/data/general/npcs/elven-caster.lua @@ -43,7 +43,7 @@ newEntity{ silence_immune = 0.5, resolvers.racial(), - resolvers.talents{ [Talents.T_HEAVY_ARMOUR_TRAINING]=1, }, + resolvers.talents{ [Talents.T_ARMOUR_TRAINING]=1, }, autolevel = "caster", ai = "dumb_talented_simple", ai_state = { ai_move="move_dmap", talent_in=1, }, diff --git a/game/modules/tome/data/general/npcs/elven-warrior.lua b/game/modules/tome/data/general/npcs/elven-warrior.lua index 0ab8bbefb5e893e2c49410c470495122ac331217..e8464a8b911a84998fdb48a98585259d23bc3803 100644 --- a/game/modules/tome/data/general/npcs/elven-warrior.lua +++ b/game/modules/tome/data/general/npcs/elven-warrior.lua @@ -42,7 +42,7 @@ newEntity{ open_door = true, resolvers.racial(), - resolvers.talents{ [Talents.T_HEAVY_ARMOUR_TRAINING]=1, [Talents.T_WEAPON_COMBAT]={base=1, every=5, max=10}, [Talents.T_WEAPONS_MASTERY]={base=1, every=5, max=10} }, + resolvers.talents{ [Talents.T_ARMOUR_TRAINING]=5, [Talents.T_WEAPON_COMBAT]={base=1, every=5, max=10}, [Talents.T_WEAPONS_MASTERY]={base=1, every=5, max=10} }, autolevel = "warrior", ai = "dumb_talented_simple", ai_state = { ai_move="move_dmap", talent_in=3, }, diff --git a/game/modules/tome/data/general/npcs/minor-demon.lua b/game/modules/tome/data/general/npcs/minor-demon.lua index 80d9ad72fdd3c9686d7f71112d56fd01739d676f..dbd8648b5f15f3008c7f33bd1630dd7bd4127ff3 100644 --- a/game/modules/tome/data/general/npcs/minor-demon.lua +++ b/game/modules/tome/data/general/npcs/minor-demon.lua @@ -103,7 +103,7 @@ newEntity{ base = "BASE_NPC_DEMON", body = { INVEN = 10, MAINHAND=1, OFFHAND=1, BODY=1 }, resolvers.talents{ - [Talents.T_HEAVY_ARMOUR_TRAINING]={base=1, every=6, max=5}, + [Talents.T_ARMOUR_TRAINING]={base=3, every=6, max=7}, [Talents.T_SHIELD_PUMMEL]={base=2, every=6, max=5}, [Talents.T_RIPOSTE]={base=3, every=6, max=6}, [Talents.T_OVERPOWER]={base=1, every=6, max=5}, diff --git a/game/modules/tome/data/general/npcs/orc-grushnak.lua b/game/modules/tome/data/general/npcs/orc-grushnak.lua index 3b342a45513029fae55ff6820d5ee5a8ab0d405a..a1fbd89c74e02803d303cee54178d9b3aa212527 100644 --- a/game/modules/tome/data/general/npcs/orc-grushnak.lua +++ b/game/modules/tome/data/general/npcs/orc-grushnak.lua @@ -68,7 +68,7 @@ newEntity{ base = "BASE_NPC_ORC_GRUSHNAK", combat_armor = 0, combat_def = 5, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]={base=1, every=5, max=5}, + [Talents.T_ARMOUR_TRAINING]={base=4, every=5, max=5}, [Talents.T_WEAPON_COMBAT]={base=4, every=5, max=8}, [Talents.T_WEAPONS_MASTERY]={base=4, every=5, max=8}, [Talents.T_RUSH]={base=3, every=9, max=5}, @@ -96,7 +96,7 @@ newEntity{ base = "BASE_NPC_ORC_GRUSHNAK", ai_tactic = resolvers.tactic"melee", resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]={base=5, every=5, max=8}, + [Talents.T_ARMOUR_TRAINING]={base=5, every=5, max=8}, [Talents.T_WEAPON_COMBAT]={base=8, every=5, max=12}, [Talents.T_WEAPONS_MASTERY]={base=6, every=5, max=12}, [Talents.T_RUSH]={base=3, every=7, max=6}, @@ -122,7 +122,7 @@ newEntity{ base = "BASE_NPC_ORC_GRUSHNAK", combat_armor = 0, combat_def = 5, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]={base=1, every=5, max=5}, + [Talents.T_ARMOUR_TRAINING]={base=4, every=5, max=5}, [Talents.T_WEAPON_COMBAT]={base=4, every=5, max=8}, [Talents.T_WEAPONS_MASTERY]={base=4, every=5, max=8}, [Talents.T_RUSH]={base=3, every=7, max=6}, @@ -148,7 +148,7 @@ newEntity{ base = "BASE_NPC_ORC_GRUSHNAK", ai_tactic = resolvers.tactic"melee", resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]={base=5, every=5, max=8}, + [Talents.T_ARMOUR_TRAINING]={base=5, every=5, max=8}, [Talents.T_WEAPON_COMBAT]={base=8, every=5, max=12}, [Talents.T_WEAPONS_MASTERY]={base=6, every=5, max=12}, [Talents.T_RUSH]={base=3, every=7, max=6}, diff --git a/game/modules/tome/data/general/npcs/skeleton.lua b/game/modules/tome/data/general/npcs/skeleton.lua index 04cdaae0c9ca6b29b976e348df4963fddf59e0b9..3bb4665f3c8ffb5adef8dee081d41ed1b91f604a 100644 --- a/game/modules/tome/data/general/npcs/skeleton.lua +++ b/game/modules/tome/data/general/npcs/skeleton.lua @@ -137,7 +137,7 @@ newEntity{ base = "BASE_NPC_SKELETON", resolvers.talents{ [Talents.T_WEAPON_COMBAT]={base=1, every=7, max=10}, [Talents.T_WEAPONS_MASTERY]={base=1, every=7, max=10}, - [Talents.T_HEAVY_ARMOUR_TRAINING]={base=1, every=7, max=5}, + [Talents.T_ARMOUR_TRAINING]={base=4, every=7, max=8}, [Talents.T_SHIELD_PUMMEL]={base=1, every=7, max=5}, [Talents.T_RIPOSTE]={base=3, every=7, max=7}, [Talents.T_OVERPOWER]={base=1, every=7, max=5}, diff --git a/game/modules/tome/data/general/npcs/sunwall-town.lua b/game/modules/tome/data/general/npcs/sunwall-town.lua index 3c5d828ac48c5e19d37026b3222a5bcd7f5257b8..3d0861cbb7f113fef9b8a54204ba2071aa3bf996 100644 --- a/game/modules/tome/data/general/npcs/sunwall-town.lua +++ b/game/modules/tome/data/general/npcs/sunwall-town.lua @@ -83,7 +83,7 @@ newEntity{ base = "BASE_NPC_SUNWALL_TOWN", {type="armor", subtype="massive", autoreq=true}, }, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=1, + [Talents.T_ARMOUR_TRAINING]=4, [Talents.T_CHANT_OF_FORTITUDE]=2, [Talents.T_SEARING_LIGHT]=2, }, diff --git a/game/modules/tome/data/general/npcs/ziguranth.lua b/game/modules/tome/data/general/npcs/ziguranth.lua index a1e8642a39e2b100c6c1172cd4740e092ba936a4..dc9d98a548814f8661a17a7f03b5048f2146ab51 100644 --- a/game/modules/tome/data/general/npcs/ziguranth.lua +++ b/game/modules/tome/data/general/npcs/ziguranth.lua @@ -42,7 +42,7 @@ newEntity{ resolvers.racial(), - resolvers.talents{ [Talents.T_HEAVY_ARMOUR_TRAINING]=1, }, + resolvers.talents{ [Talents.T_ARMOUR_TRAINING]=4, }, resolvers.inscriptions(1, "infusion"), autolevel = "warrior", diff --git a/game/modules/tome/data/general/objects/gauntlets.lua b/game/modules/tome/data/general/objects/gauntlets.lua index f1f10acadf02090ce85df3d13877f23f552af96c..35660830410cbbd536fff41a3717582b33f71ded 100644 --- a/game/modules/tome/data/general/objects/gauntlets.lua +++ b/game/modules/tome/data/general/objects/gauntlets.lua @@ -26,7 +26,7 @@ newEntity{ add_name = " (#ARMOR#)", display = "[", color=colors.SLATE, image = resolvers.image_material("hgloves", "metal"), - require = { talent = { Talents.T_HEAVY_ARMOUR_TRAINING }, }, + require = { talent = { Talents.T_ARMOUR_TRAINING }, }, encumber = 1.5, rarity = 9, metallic = true, diff --git a/game/modules/tome/data/general/objects/heavy-armors.lua b/game/modules/tome/data/general/objects/heavy-armors.lua index dde88045be449811374b7c059569e61aefa7f62a..01ef7830fca0c9bce4e4e233b335a96b17a105ed 100644 --- a/game/modules/tome/data/general/objects/heavy-armors.lua +++ b/game/modules/tome/data/general/objects/heavy-armors.lua @@ -25,7 +25,7 @@ newEntity{ type = "armor", subtype="heavy", image = resolvers.image_material("mail", "metal"), add_name = " (#ARMOR#)", display = "[", color=colors.SLATE, - require = { talent = { Talents.T_HEAVY_ARMOUR_TRAINING }, }, + require = { talent = { {Talents.T_ARMOUR_TRAINING,2} }, }, encumber = 14, rarity = 5, metallic = true, diff --git a/game/modules/tome/data/general/objects/heavy-boots.lua b/game/modules/tome/data/general/objects/heavy-boots.lua index 042c55bc721917fd7c351ee89ac43f38ac909baa..912d72daff3430883acdc327441dd43bff27f598 100644 --- a/game/modules/tome/data/general/objects/heavy-boots.lua +++ b/game/modules/tome/data/general/objects/heavy-boots.lua @@ -25,7 +25,7 @@ newEntity{ type = "armor", subtype="feet", image = resolvers.image_material("hboots", "metal"), add_name = " (#ARMOR#)", display = "]", color=colors.SLATE, - require = { talent = { Talents.T_HEAVY_ARMOUR_TRAINING }, }, + require = { talent = { Talents.T_ARMOUR_TRAINING }, }, encumber = 3, rarity = 7, metallic = true, diff --git a/game/modules/tome/data/general/objects/helms.lua b/game/modules/tome/data/general/objects/helms.lua index 2d6db8cace17d4ed6f505fe9e6b77ac8d2617668..2fbd6272a7199218d74d87acc21a842c17b45deb 100644 --- a/game/modules/tome/data/general/objects/helms.lua +++ b/game/modules/tome/data/general/objects/helms.lua @@ -25,7 +25,7 @@ newEntity{ type = "armor", subtype="head", add_name = " (#ARMOR#)", display = "]", color=colors.SLATE, image = resolvers.image_material("helm", "metal"), - require = { talent = { Talents.T_HEAVY_ARMOUR_TRAINING }, }, + require = { talent = { Talents.T_ARMOUR_TRAINING }, }, encumber = 3, rarity = 7, metallic = true, diff --git a/game/modules/tome/data/general/objects/massive-armors.lua b/game/modules/tome/data/general/objects/massive-armors.lua index 9ad36e5db6e133dc4222a9e7619fc5a45e23926a..8d940c585db4dabb4dd8ac82ec03fe4d88e43632 100644 --- a/game/modules/tome/data/general/objects/massive-armors.lua +++ b/game/modules/tome/data/general/objects/massive-armors.lua @@ -25,7 +25,7 @@ newEntity{ type = "armor", subtype="massive", add_name = " (#ARMOR#)", display = "[", color=colors.SLATE, image = resolvers.image_material("plate", "metal"), - require = { talent = { Talents.T_MASSIVE_ARMOUR_TRAINING }, }, + require = { talent = { {Talents.T_ARMOUR_TRAINING,4} }, }, encumber = 17, rarity = 5, metallic = true, diff --git a/game/modules/tome/data/general/objects/shields.lua b/game/modules/tome/data/general/objects/shields.lua index 9113a1eb822bdba409cf6675107cc325e5b2ff97..db5dcad1ce832ca576ffc3b1c815504a512cbc2c 100644 --- a/game/modules/tome/data/general/objects/shields.lua +++ b/game/modules/tome/data/general/objects/shields.lua @@ -17,6 +17,8 @@ -- Nicolas Casalini "DarkGod" -- darkgod@te4.org +local Talents = require "engine.interface.ActorTalents" + newEntity{ define_as = "BASE_SHIELD", slot = "OFFHAND", @@ -27,6 +29,7 @@ newEntity{ encumber = 7, metallic = true, desc = [[Handheld deflection devices]], + require = { talent = { {Talents.T_ARMOUR_TRAINING,3} }, }, randart_able = { attack=20, physical=10, spell=10, def=50, misc=10 }, egos = "/data/general/objects/egos/shield.lua", egos_chance = { prefix=resolvers.mbonus(40, 5), suffix=resolvers.mbonus(40, 5) }, } diff --git a/game/modules/tome/data/general/objects/world-artifacts.lua b/game/modules/tome/data/general/objects/world-artifacts.lua index c8a76ee2af7c164685d8be27a0b79a4e72aac354..42ba635dbaddfde7816713df9a51d12df4485684 100644 --- a/game/modules/tome/data/general/objects/world-artifacts.lua +++ b/game/modules/tome/data/general/objects/world-artifacts.lua @@ -1051,7 +1051,7 @@ newEntity{ base = "BASE_HELM", name = "Dragon-helm of Kroltar", unided_name = "dragon-helm", desc = [[A visored steel helm, embossed and embellished with gold, that bears as its crest the head of Kroltar, the greatest of the fire drakes.]], - require = { talent = { Talents.T_MASSIVE_ARMOUR_TRAINING }, stat = { str=35 }, }, + require = { talent = { {Talents.T_ARMOUR_TRAINING,4} }, stat = { str=35 }, }, level_range = {37, 45}, rarity = 280, cost = 400, diff --git a/game/modules/tome/data/talents/spells/golemancy.lua b/game/modules/tome/data/talents/spells/golemancy.lua index 202e0b2ea3f40b2d4adab56ea8a2af2d5eabcc1a..7ca1146015f643d0360ce176e6a654e5e2aae724 100644 --- a/game/modules/tome/data/talents/spells/golemancy.lua +++ b/game/modules/tome/data/talents/spells/golemancy.lua @@ -42,8 +42,7 @@ local function makeGolem() size_category = 4, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=1, - [Talents.T_HEAVY_ARMOUR_TRAINING]=1, + [Talents.T_ARMOUR_TRAINING]=4, [Talents.T_WEAPON_COMBAT]=2, [Talents.T_MANA_POOL]=1, [Talents.T_STAMINA_POOL]=1, @@ -253,20 +252,17 @@ newTalent{ points = 5, on_learn = function(self, t) self.alchemy_golem:learnTalent(Talents.T_HEALTH, true) - self.alchemy_golem:learnTalent(Talents.T_HEAVY_ARMOUR_TRAINING, true) - self.alchemy_golem:learnTalent(Talents.T_MASSIVE_ARMOUR_TRAINING, true) + self.alchemy_golem:learnTalent(Talents.T_ARMOUR_TRAINING, true) end, on_unlearn = function(self, t) self.alchemy_golem:unlearnTalent(Talents.T_HEALTH, true) - self.alchemy_golem:unlearnTalent(Talents.T_HEAVY_ARMOUR_TRAINING, true) - self.alchemy_golem:unlearnTalent(Talents.T_MASSIVE_ARMOUR_TRAINING, true) + self.alchemy_golem:unlearnTalent(Talents.T_ARMOUR_TRAINING, true) end, info = function(self, t) local health = self:getTalentFromId(Talents.T_HEALTH).getHealth(self, t) - local heavyarmor = self:getTalentFromId(Talents.T_HEAVY_ARMOUR_TRAINING).getArmor(self, t) - local massivearmor = self:getTalentFromId(Talents.T_MASSIVE_ARMOUR_TRAINING).getArmor(self, t) - return ([[Improves your golem armour training and health. Increases armor by %d when wearing heavy armor or by %d when wearing massive armor also increases health by %d.]]): - format(heavyarmor, massivearmor, health) + local heavyarmor = self:getTalentFromId(Talents.T_ARMOUR_TRAINING).getArmor(self, t) + return ([[Improves your golem armour training and health. Increases armor by %d when wearing armor also increases health by %d.]]): + format(heavyarmor, health) end, } diff --git a/game/modules/tome/data/talents/techniques/combat-training.lua b/game/modules/tome/data/talents/techniques/combat-training.lua index 6f2845d995716e3559673b185034428f22aa8eea..737e3db2c6621f077025d99d0ee238f8cfe99450 100644 --- a/game/modules/tome/data/talents/techniques/combat-training.lua +++ b/game/modules/tome/data/talents/techniques/combat-training.lua @@ -17,38 +17,6 @@ -- Nicolas Casalini "DarkGod" -- darkgod@te4.org -newTalent{ - name = "Heavy Armour Training", - type = {"technique/combat-training", 1}, - mode = "passive", - points = 5, - require = { stat = { str=18 }, }, - getArmor = function(self, t) return self:getTalentLevel(t) * 1.4 end, - getCriticalChanceReduction = function(self, t) return self:getTalentLevel(t) * 1.9 end, - info = function(self, t) - local armor = t.getArmor(self, t) - local criticalreduction = t.getCriticalChanceReduction(self, t) - return ([[Teaches the usage of heavy mail armours. Increases armour value by %d and reduces chance to be critically hit by %d%% when wearing a heavy mail armour.]]): - format(armor, criticalreduction) - end, -} - -newTalent{ - name = "Massive Armour Training", - type = {"technique/combat-training", 2}, - mode = "passive", - points = 5, - require = { stat = { str=22 }, talent = { Talents.T_HEAVY_ARMOUR_TRAINING }, }, - getArmor = function(self, t) return self:getTalentLevel(t) * 1.6 end, - getCriticalChanceReduction = function(self, t) return self:getTalentLevel(t) * 1.5 end, - info = function(self, t) - local armor = t.getArmor(self, t) - local criticalreduction = t.getCriticalChanceReduction(self, t) - return ([[Teaches the usage of massive plate armours. Increases armour value by %d and reduces chance to be critically hit by %d%% when wearing a massive plate armour.]]): - format(armor, criticalreduction) - end, -} - newTalent{ name = "Health", type = {"technique/combat-training", 1}, @@ -69,6 +37,26 @@ newTalent{ end, } +newTalent{ + name = "Armour Training", + type = {"technique/combat-training", 1}, + mode = "passive", + points = 10, + require = { stat = { str=function(level) return 18 + level - 1 end }, }, + getArmor = function(self, t) return self:getTalentLevel(t) * 1.4 end, + getCriticalChanceReduction = function(self, t) return self:getTalentLevel(t) * 1.9 end, + info = function(self, t) + local armor = t.getArmor(self, t) + local criticalreduction = t.getCriticalChanceReduction(self, t) + return ([[Teaches the usage of armours. Increases armour value by %d and reduces chance to be critically hit by %d%% when wearing a heavy mail armour or a massive plate armour. + At level 1 it allows you to wear gauntlets, helms and heavy boots. + At level 2 it allows you to wear heavy mail armour. + At level 3 it allows you to wear shields. + At level 4 it allows you to wear massive plate armour.]]): + format(armor, criticalreduction) + end, +} + newTalent{ name = "Combat Accuracy", short_name = "WEAPON_COMBAT", type = {"technique/combat-training", 1}, diff --git a/game/modules/tome/data/zones/arena-unlock/npcs.lua b/game/modules/tome/data/zones/arena-unlock/npcs.lua index 54ad3f95fc7100c24edeb00cc620b76286ffc9fb..6f531987dfac203e471c0ae8a52a5ef0cdfb3afd 100644 --- a/game/modules/tome/data/zones/arena-unlock/npcs.lua +++ b/game/modules/tome/data/zones/arena-unlock/npcs.lua @@ -53,7 +53,7 @@ newEntity{ name = "gladiator", [Talents.T_SHIELD_PUMMEL]=2, [Talents.T_RUSH]=4, [Talents.T_REPULSION]=2, - [Talents.T_HEAVY_ARMOUR_TRAINING] = 1, + [Talents.T_ARMOUR_TRAINING] = 3, [Talents.T_WEAPON_COMBAT] = 1, }, on_die = function (self) @@ -151,7 +151,7 @@ newEntity{ name = "arcane blade", [Talents.T_ARCANE_COMBAT]=2, [Talents.T_ARCANE_FEED]=2, [Talents.T_FLAME]=1, - [Talents.T_HEAVY_ARMOUR_TRAINING] = 2, + [Talents.T_ARMOUR_TRAINING] = 2, [Talents.T_WEAPON_COMBAT] = 2, }, on_added = function (self) diff --git a/game/modules/tome/data/zones/arena/npcs.lua b/game/modules/tome/data/zones/arena/npcs.lua index 3dad93dc842332f371a61a09f6b02fc03a43836d..d7bd6dc60f1d2eb8f70f32aaa24c923352b7c504 100644 --- a/game/modules/tome/data/zones/arena/npcs.lua +++ b/game/modules/tome/data/zones/arena/npcs.lua @@ -48,7 +48,7 @@ newEntity{ define_as = "BASE_NPC_ARENA1", fear_immune = 0.1, ai = "tactical", ai_state = { ai_move = "move_dmap", talent_in = 1 }, stats = { str = 10, dex = 10, mag = 10, con = 10 }, - resolvers.talents{ [Talents.T_HEAVY_ARMOUR_TRAINING] = 2, }, + resolvers.talents{ [Talents.T_ARMOUR_TRAINING] = 4, }, resolvers.equip{ {type="armor", subtype="feet", autoreq=true}, }, @@ -485,7 +485,7 @@ newEntity{ name = "Valfren Loren", [Talents.T_BRUTALITY] = 3, [Talents.T_INSTINCTS] = 4, [Talents.T_RECKLESS_CHARGE] = 5, - [Talents.T_MASSIVE_ARMOUR_TRAINING] = 5, + [Talents.T_ARMOUR_TRAINING] = 5, [Talents.T_WEAPON_COMBAT] = 2, }, resolvers.sustains_at_birth(), @@ -1017,7 +1017,7 @@ newEntity{ name = "sun paladin", [Talents.T_CRUSADE]=3, [Talents.T_SHIELD_OF_LIGHT]=1, [Talents.T_BRANDISH]=1, - [Talents.T_MASSIVE_ARMOUR_TRAINING]=2, + [Talents.T_ARMOUR_TRAINING]=2, [Talents.T_WEAPON_COMBAT]=2, }, } @@ -1057,7 +1057,7 @@ newEntity{ name = "star crusader", [Talents.T_CRUSADE]=3, [Talents.T_BRANDISH]=1, [Talents.T_RETRIBUTION]=1, - [Talents.T_MASSIVE_ARMOUR_TRAINING]=1, + [Talents.T_ARMOUR_TRAINING]=1, [Talents.T_WEAPON_COMBAT]=2, [Talents.T_WEAPONS_MASTERY]=2, }, diff --git a/game/modules/tome/data/zones/charred-scar/npcs.lua b/game/modules/tome/data/zones/charred-scar/npcs.lua index cbff4a4bf8bb14ae235022907c4b45ad4a399c13..8b84193ce93c6b1d13ce74fad20acb8021e4dbeb 100644 --- a/game/modules/tome/data/zones/charred-scar/npcs.lua +++ b/game/modules/tome/data/zones/charred-scar/npcs.lua @@ -60,7 +60,7 @@ newEntity{ base = "BASE_NPC_SUNWALL_DEFENDER", define_as = "SUN_PALADIN_DEFENDER {type="armor", subtype="massive", autoreq=true}, }, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=5, + [Talents.T_ARMOUR_TRAINING]=5, [Talents.T_CHANT_OF_FORTRESS]=5, [Talents.T_SEARING_LIGHT]=4, [Talents.T_MARTYRDOM]=4, @@ -90,7 +90,7 @@ newEntity{ base = "BASE_NPC_SUNWALL_DEFENDER", define_as = "SUN_PALADIN_DEFENDER {type="armor", subtype="massive", autoreq=true}, }, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=5, + [Talents.T_ARMOUR_TRAINING]=5, [Talents.T_CHANT_OF_FORTRESS]=5, [Talents.T_SEARING_LIGHT]=5, [Talents.T_MARTYRDOM]=5, diff --git a/game/modules/tome/data/zones/daikara/npcs.lua b/game/modules/tome/data/zones/daikara/npcs.lua index 2e557416fa1fc6d5eab0f9d9d91049df85768542..0f92d4caef44127332d2acb92ccd1f618268b350 100644 --- a/game/modules/tome/data/zones/daikara/npcs.lua +++ b/game/modules/tome/data/zones/daikara/npcs.lua @@ -115,8 +115,7 @@ newEntity{ base="BASE_NPC_ORC_GRUSHNAK", define_as = "MASSOK", resolvers.talents{ [Talents.T_WEAPON_COMBAT]=7, - [Talents.T_HEAVY_ARMOUR_TRAINING]=7, - [Talents.T_MASSIVE_ARMOUR_TRAINING]=7, + [Talents.T_ARMOUR_TRAINING]=7, [Talents.T_WEAPONS_MASTERY]=7, [Talents.T_RUSH]=9, [Talents.T_BATTLE_CALL]=5, diff --git a/game/modules/tome/data/zones/dreadfell/npcs.lua b/game/modules/tome/data/zones/dreadfell/npcs.lua index abd465a49573b4765bf276b11fbffbf1c9959e71..d1e468b5efaaef14b9e988fd902a598d1e3cb1f7 100644 --- a/game/modules/tome/data/zones/dreadfell/npcs.lua +++ b/game/modules/tome/data/zones/dreadfell/npcs.lua @@ -71,7 +71,7 @@ newEntity{ define_as = "THE_MASTER", resolvers.talents{ [Talents.T_SUMMON]=1, - [Talents.T_HEAVY_ARMOUR_TRAINING]={base=1, every=5, max=5}, + [Talents.T_ARMOUR_TRAINING]={base=3, every=5, max=10}, [Talents.T_CONGEAL_TIME]={base=2, every=5, max=5}, [Talents.T_MANATHRUST]={base=4, every=5, max=8}, diff --git a/game/modules/tome/data/zones/eruan/npcs.lua b/game/modules/tome/data/zones/eruan/npcs.lua index b08dd617d225b59a5345cd3fb3e52a2d4cf6c2a2..db47937d57a6d27fcbad3219717d84d5f7bb7dc5 100644 --- a/game/modules/tome/data/zones/eruan/npcs.lua +++ b/game/modules/tome/data/zones/eruan/npcs.lua @@ -56,7 +56,7 @@ newEntity{ define_as = "SUN_PALADIN_GUREN", {type="armor", subtype="massive", autoreq=true}, }, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=5, + [Talents.T_ARMOUR_TRAINING]=5, [Talents.T_CHANT_OF_LIGHT]=5, [Talents.T_SEARING_LIGHT]=5, [Talents.T_MARTYRDOM]=5, diff --git a/game/modules/tome/data/zones/gorbat-pride/npcs.lua b/game/modules/tome/data/zones/gorbat-pride/npcs.lua index cc9bf6fadc288c0ba59dfa59ab1ea039af6a8f92..502cab7fd903a502fd685551934d6111a2e7e23c 100644 --- a/game/modules/tome/data/zones/gorbat-pride/npcs.lua +++ b/game/modules/tome/data/zones/gorbat-pride/npcs.lua @@ -84,7 +84,7 @@ newEntity{ base="BASE_NPC_ORC_GORBAT", define_as = "GORBAT", [Talents.T_WEAPON_COMBAT]={base=7, every=4, max=10}, [Talents.T_WEAPONS_MASTERY]={base=6, every=4, max=10}, - [Talents.T_MASSIVE_ARMOUR_TRAINING]=5, + [Talents.T_ARMOUR_TRAINING]=5, }, resolvers.sustains_at_birth(), diff --git a/game/modules/tome/data/zones/grushnak-pride/npcs.lua b/game/modules/tome/data/zones/grushnak-pride/npcs.lua index c5c8e2e16aca0b02c64b15f3b166c3f891f8660d..6f603dffd84e0f39cffe13d25405f561f8d4bce1 100644 --- a/game/modules/tome/data/zones/grushnak-pride/npcs.lua +++ b/game/modules/tome/data/zones/grushnak-pride/npcs.lua @@ -70,7 +70,7 @@ newEntity{ base="BASE_NPC_ORC_GRUSHNAK", define_as = "GRUSHNAK", resolvers.talents{ [Talents.T_WEAPON_COMBAT]={base=10, every=6, max=13}, - [Talents.T_MASSIVE_ARMOUR_TRAINING]={base=10, every=6, max=13}, + [Talents.T_ARMOUR_TRAINING]={base=10, every=6, max=13}, [Talents.T_WEAPONS_MASTERY]={base=10, every=6, max=13}, [Talents.T_RUSH]={base=5, every=6, max=7}, [Talents.T_BATTLE_CALL]={base=5, every=6, max=7}, diff --git a/game/modules/tome/data/zones/high-peak/npcs.lua b/game/modules/tome/data/zones/high-peak/npcs.lua index f9807e797cc03b8ea7ea0f05ae0120f153942e30..dc6bf61edec6240d44ff3de99e58593fea7888e6 100644 --- a/game/modules/tome/data/zones/high-peak/npcs.lua +++ b/game/modules/tome/data/zones/high-peak/npcs.lua @@ -189,7 +189,7 @@ newEntity{ [Talents.T_WEAPON_COMBAT]=10, [Talents.T_WEAPONS_MASTERY]={base=7, every=6}, - [Talents.T_MASSIVE_ARMOUR_TRAINING]={base=7, every=6}, + [Talents.T_ARMOUR_TRAINING]={base=7, every=6}, }, resolvers.sustains_at_birth(), @@ -250,7 +250,7 @@ newEntity{ define_as = "FALLEN_SUN_PALADIN_AERYN", positive_regen = 25, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=7, + [Talents.T_ARMOUR_TRAINING]=7, [Talents.T_WEAPON_COMBAT]=10, [Talents.T_WEAPONS_MASTERY]=10, [Talents.T_RUSH]=3, @@ -314,7 +314,7 @@ newEntity{ define_as = "HIGH_SUN_PALADIN_AERYN", positive_regen = 25, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=5, + [Talents.T_ARMOUR_TRAINING]=5, [Talents.T_WEAPON_COMBAT]=10, [Talents.T_WEAPONS_MASTERY]=10, [Talents.T_RUSH]=8, diff --git a/game/modules/tome/data/zones/maze/npcs.lua b/game/modules/tome/data/zones/maze/npcs.lua index 3b59dc960c4e498fa288b5203b1f26d11246014e..609c2b1106692b2bfce079f5370fcad33901d770 100644 --- a/game/modules/tome/data/zones/maze/npcs.lua +++ b/game/modules/tome/data/zones/maze/npcs.lua @@ -56,7 +56,7 @@ newEntity{ define_as = "MINOTAUR_MAZE", resolvers.drops{chance=100, nb=5, {tome_drops="boss"} }, resolvers.talents{ - [Talents.T_HEAVY_ARMOUR_TRAINING]={base=1, every=6, max=5}, + [Talents.T_ARMOUR_TRAINING]={base=2, every=6, max=5}, [Talents.T_STAMINA_POOL]={base=1, every=6, max=5}, [Talents.T_WARSHOUT]={base=1, every=6, max=5}, [Talents.T_STUNNING_BLOW]={base=1, every=6, max=5}, diff --git a/game/modules/tome/data/zones/reknor-escape/npcs.lua b/game/modules/tome/data/zones/reknor-escape/npcs.lua index c9169ddf3a4117fe6c5baf55047da64697b7d872..89f499ac3942366c0af41bdc6bc341c1c5f9519e 100644 --- a/game/modules/tome/data/zones/reknor-escape/npcs.lua +++ b/game/modules/tome/data/zones/reknor-escape/npcs.lua @@ -92,7 +92,7 @@ newEntity{ define_as = "NORGAN", resolvers.talents{ [Talents.T_DWARF_RESILIENCE]=1, - [Talents.T_HEAVY_ARMOUR_TRAINING]=1, + [Talents.T_ARMOUR_TRAINING]=2, [Talents.T_STUNNING_BLOW]=2, [Talents.T_WEAPON_COMBAT]=2, [Talents.T_WEAPONS_MASTERY]=2, diff --git a/game/modules/tome/data/zones/reknor/npcs.lua b/game/modules/tome/data/zones/reknor/npcs.lua index 74d2c3ff588a131903078ab90bc6db3aa93856e3..56959481f735ba8774e4755284525d95e257161a 100644 --- a/game/modules/tome/data/zones/reknor/npcs.lua +++ b/game/modules/tome/data/zones/reknor/npcs.lua @@ -56,8 +56,7 @@ newEntity{ define_as = "GOLBUG", see_invisible = 5, resolvers.talents{ - [Talents.T_HEAVY_ARMOUR_TRAINING]={base=1, every=6, max=5}, - [Talents.T_MASSIVE_ARMOUR_TRAINING]={base=3, every=6, max=5}, + [Talents.T_ARMOUR_TRAINING]={base=4, every=6, max=8}, [Talents.T_WEAPON_COMBAT]={base=6, every=5, max=10}, [Talents.T_WEAPONS_MASTERY]={base=6, every=5, max=10}, [Talents.T_SHIELD_PUMMEL]={base=4, every=5, max=6}, diff --git a/game/modules/tome/data/zones/ring-of-blood/npcs.lua b/game/modules/tome/data/zones/ring-of-blood/npcs.lua index 2d10eedbf40e21266a3fb781b2258ed076b6d9f6..3f4fe68cf092fb766fbeea08c6cf7a2dbbafd29c 100644 --- a/game/modules/tome/data/zones/ring-of-blood/npcs.lua +++ b/game/modules/tome/data/zones/ring-of-blood/npcs.lua @@ -154,7 +154,7 @@ newEntity{ open_door = true, resolvers.racial(), - resolvers.talents{ [Talents.T_HEAVY_ARMOUR_TRAINING]=1, [Talents.T_WEAPON_COMBAT]={base=1, every=5, max=10}, [Talents.T_WEAPONS_MASTERY]={base=1, every=5, max=10} }, + resolvers.talents{ [Talents.T_ARMOUR_TRAINING]=3, [Talents.T_WEAPON_COMBAT]={base=1, every=5, max=10}, [Talents.T_WEAPONS_MASTERY]={base=1, every=5, max=10} }, autolevel = "warrior", ai = "dumb_talented_simple", ai_state = { ai_move="move_dmap", talent_in=3, }, diff --git a/game/modules/tome/data/zones/tannen-tower/npcs.lua b/game/modules/tome/data/zones/tannen-tower/npcs.lua index b63a4b35abc29a0a2f96399826f88167ac5515bc..faf2ae04f3dc764060d9d3065f606cb4465cdf30 100644 --- a/game/modules/tome/data/zones/tannen-tower/npcs.lua +++ b/game/modules/tome/data/zones/tannen-tower/npcs.lua @@ -114,8 +114,7 @@ It is so huge that it blocks sight beyond it.]], move_others=true, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=5, - [Talents.T_HEAVY_ARMOUR_TRAINING]=5, + [Talents.T_ARMOUR_TRAINING]=8, [Talents.T_WEAPON_COMBAT]=7, [Talents.T_POISON_BREATH]=6, [Talents.T_WEAPONS_MASTERY]=11, diff --git a/game/modules/tome/data/zones/town-gates-of-morning/npcs.lua b/game/modules/tome/data/zones/town-gates-of-morning/npcs.lua index a9a2a604306e2fc49e1f2cef3ea69c5a97cc9c2c..48ede3f2a0b5d29a1471ab7865b66c49fc44b46b 100644 --- a/game/modules/tome/data/zones/town-gates-of-morning/npcs.lua +++ b/game/modules/tome/data/zones/town-gates-of-morning/npcs.lua @@ -57,7 +57,7 @@ newEntity{ define_as = "HIGH_SUN_PALADIN_AERYN", {type="armor", subtype="massive", autoreq=true}, }, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=5, + [Talents.T_ARMOUR_TRAINING]=5, [Talents.T_CHANT_OF_LIGHT]=5, [Talents.T_SEARING_LIGHT]=5, [Talents.T_MARTYRDOM]=5, diff --git a/game/modules/tome/data/zones/town-zigur/npcs.lua b/game/modules/tome/data/zones/town-zigur/npcs.lua index ce9ab6af7d1a509f734bb0f2df988db4b1a0e660..6f05661a5e31f9022869f924332686ee3d5263b8 100644 --- a/game/modules/tome/data/zones/town-zigur/npcs.lua +++ b/game/modules/tome/data/zones/town-zigur/npcs.lua @@ -86,7 +86,7 @@ newEntity{ base = "BASE_NPC_ZIGURANTH", define_as = "PROTECTOR_MYSSIL", combat_armor = 5, combat_def = 10, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=3, + [Talents.T_ARMOUR_TRAINING]=5, [Talents.T_WEAPON_COMBAT]=4, [Talents.T_WEAPONS_MASTERY]=4, [Talents.T_RESOLVE]=5, diff --git a/game/modules/tome/data/zones/trollmire/npcs.lua b/game/modules/tome/data/zones/trollmire/npcs.lua index e07cac91b102348b929786bc784f3de321bd18f8..08d643d84c2c125b9920a51b298a4f4ddc65a041 100644 --- a/game/modules/tome/data/zones/trollmire/npcs.lua +++ b/game/modules/tome/data/zones/trollmire/npcs.lua @@ -99,7 +99,7 @@ newEntity{ define_as = "ALUIN", resolvers.drops{chance=100, nb=3, {tome_drops="boss"} }, resolvers.talents{ - [Talents.T_MASSIVE_ARMOUR_TRAINING]=5, + [Talents.T_ARMOUR_TRAINING]=5, [Talents.T_WEAPON_COMBAT]={base=5, every=5, max=10}, [Talents.T_WEAPONS_MASTERY]={base=5, every=5, max=10}, [Talents.T_RUSH]={base=4, every=7, max=6}, diff --git a/game/modules/tome/data/zones/unremarkable-cave/npcs.lua b/game/modules/tome/data/zones/unremarkable-cave/npcs.lua index 5c5fa943539b882016aa4ec03d0ac2b3c6300f30..fc5192210126c5bd9c908ae2236c225becfdecd7 100644 --- a/game/modules/tome/data/zones/unremarkable-cave/npcs.lua +++ b/game/modules/tome/data/zones/unremarkable-cave/npcs.lua @@ -111,7 +111,7 @@ newEntity{ define_as = "CORRUPTOR", resolvers.drops{chance=100, nb=3, {tome_drops="boss"} }, resolvers.talents{ - [Talents.T_HEAVY_ARMOUR_TRAINING]=3, + [Talents.T_ARMOUR_TRAINING]=3, [Talents.T_MOONLIGHT_RAY]=4, [Talents.T_STARFALL]=5, [Talents.T_SHADOW_BLAST]=3,