ToME: the Tales of Maj'Eyal

Everything about ToME
It is currently Tue Oct 23, 2018 6:01 am

All times are UTC




Post new topic Reply to topic  [ 8 posts ] 
Author Message
PostPosted: Thu Apr 06, 2017 8:47 am 
Offline
Archmage

Joined: Tue Nov 09, 2010 7:43 pm
Posts: 355
In the process of making the steam-tech mage that uses dangerous clouds of steam to deadly effect, uses a new steam staff that grants spellpower and steampower (uses a new converted gem type thats similar to alchemy gems).
here is the current birth file:
Code:
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009 - 2017 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program.  If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org

local Particles = require "engine.Particles"


newBirthDescriptor{
   type = "subclass",
   name = "Smog Devil",
   desc = {
      "A stealthy tinker that has fused dark corrupt magic with steamtech and uses a new weapon, the steam-staff.",
      "Their most important stats are: Magic and Cunning",
      "#GOLD#Stat modifiers:",
      "#LIGHT_BLUE# * +0 Strength, +0 Dexterity, +1 Constitution",
      "#LIGHT_BLUE# * +4 Magic, +0 Willpower, +4 Cunning",
      "#GOLD#Life per level:#LIGHT_BLUE# 0",
   },
   locked = function(birther) return profile.mod.allow_build.orcs_tinker_eyal and profile.mod.allow_build.corrupter end,
   locked_desc = "Unlock tinkers for the main game with users of corrupt magics unlocked for use",
   power_source = {steam=true, arcane=true},
   random_rarity = 10,
--   not_on_random_boss = ("no" == config.settings.tome.enable_on_rares_and_adventurers),
   stats = { cun=4, mag=4, con=1, },
   talents_types = {
      ["steamtech/smog-devil-veil"]={true, 0.3},
      ["steamtech/steamstave-training"]={true, 0.3},
      ["steamtech/corrupted-steam"]={true, 0.3},
      ["steamtech/steam-staff-combat"]={true, 0.3},
      ["steamtech/corrupted-nature"]={true, 0.3},
      ["steamtech/poison"]={false, 0.1},
      ["corruption/vim"]={false, 0.2},
      ["corruption/doom-covenant"]={false, 0.2},
      ---Generics
      ["steamtech/chemistry"]={true, 0.2},
      ["steamtech/physics"]={true, 0.2},
      ["steamtech/smog-devil"]={true, 0.3}, ---Class Generics
      ["steamtech/engineering"]={true, 0.2},
      ["cunning/survival"]={true, 0.0}, --so player can optionally get ability to see in stealth
      ["technique/combat-training"]={true, 0.3},
   },
   talents = {
   ---given free
      [ActorTalents.T_SMITH] = 1,
      [ActorTalents.T_THERAPEUTICS] = 1,
      [ActorTalents.T_STEAM_STAFF_BLAST] = 1, --given for free since its mastery would grant it freely on placing point in it
   ---
      
      [ActorTalents.T_ARCANA_SIPHON] = 1,
      [ActorTalents.T_ORB_OF_STEAM] = 1,
      [ActorTalents.T_ARMOUR_TRAINING] = 1,
      [ActorTalents.T_WEAPON_COMBAT] = 1,
      [ActorTalents.T_STEAMSTAFF_MASTERY] = 1,--instead of getting generic mastery talent it has class mastery like other steamtech masteries
   },
   copy = {
      max_life = 100, --has dangerous magic and does melee
      resolvers.equip{ id=true,
         {type="weapon", subtype="steam-staff", name="iron steam-staff", base_list="mod.class.Object:/data-smog-devil/general/objects/steam-staves.lua", autoreq=true, ego_chance=-1000},
--         {type="ammo", subtype="shot", name="pouch of iron shots", autoreq=true, ego_chance=-1000}, -- or alchemy gems? -- will make them start with class specific convert gems later
         {type="armor", subtype="head", name="rough leather hat", autoreq=true, ego_chance=-1000, ego_chance=-1000},
         {type="armor", subtype="heavy", name="iron", autoreq=true, ego_chance=-1000, ego_chance=-1000},
         {type="armor", subtype="cloak", name="kruk cloak", base_list="mod.class.Object:/data-orcs/general/objects/special-misc.lua", autoreq=true, ego_chance=-1000, ego_chance=-1000},
      },
      resolvers.attachtinkerbirth{ id=true,
         {defined="TINKER_FOCUS_LEN1"},
      },
      resolvers.learn_schematic"FOCUS_LEN",
      resolvers.generic(function(e)
         e.auto_shoot_talent = e.T_STEAM_STAFF_BLAST
      end),
   },
   copy_add = {
      life_rating = 0, --has ranged but also engages in melee from time to time
      vim_rating = 4, -- does not get the tree that grants sustain that gives extract vim 4 more vim per level then the average corruptor but no sustain that grants the extra vim at level 50 total extra with this as a corruptor with points in willful tormentor
   },
   party_copy = {
      known_tinkers = {
         PAIN_SUPPRESSOR_SALVE = true,
         IRON_GRIP = true,
      }
   },
}
      known_tinkers = {
         PAIN_SUPPRESSOR_SALVE = true,
         IRON_GRIP = true,
      }
   },
}




Last edited by Hellcommander on Wed Apr 12, 2017 1:46 am, edited 7 times in total.

Top
 Profile  
 
PostPosted: Thu Apr 06, 2017 8:49 am 
Offline
Archmage

Joined: Tue Nov 09, 2010 7:43 pm
Posts: 355
here is the current notes my ideas for the class (some of the talents are made (functional but still needs other stuff added in) but still much to be done):
Code:
class has stats of 4 magic, 4 cun and 1 con

use acid and fire as main damage types
Steam-staff-mastery
1st Steam-staff-mastery-talent(no points can be removed once placed):Mastery for the steamstave that grants the ability to convert metalic items to gems at raw (any gem effect that restores resource like mana will be switched to another effect since these gems are not alchemist gems just similar) and convert artifect staves (won't work on short staves when i code it :P) to a version that is a steam stave (consumes the stave so it won't show up again)
2nd bullet enchantment like effect with pierce buff or better you make them bouce
3rd buff that lasts for x that gives life steal to your stave bullets
4th 25 steam Fire a beam of steam from your steam staff that does x of weapon damage and creates line of sight blocking steam that blocks line of sight for anyone not wearing a focus lense type tinker and forcing the user into stealthmod with a bonus stealth (that lasts for x) of x

corrupted-steam (these are steamtech and arcane source talents) these scale with both spellpower and steampower
1st Orb_of_Steam Fires Compressed ball of steam (dealing damage based on the type that the steamstave is set to and does effects based on refined gem equipped) that pierces through all targets and grants a small amount of vim per target hit (uses steam and requires steamstaff) has range of 8 - 10 cost of 8 steam? cooldown of 3 - 4? (steamtech talent not effected by silence)
2nd creates a poisonous steam (inflicts damage of 90% acid, 10% nature?) that interfers with line of sight (line of sight (part prevented if have lense tinker on?)): range 8 - 10, radius 3 - 5 with intial radius of 1 that moves to its full radius costs vim (of which?) and steam 20? duration 6 - 8 turns? cooldown 15?
3rd drains life (arcane damage?) and grants vim for all in that are in the steam clouds generated by its skills (does not require steam staff uses steampower, ) heals health based on damage) cooldown of 20? cost of uses a little vim (5 vim? does damage based on spellpower and steam cost of 4? damage scales with spellpower and vim
4th turn steam from skills to explosion that does fire (inflicts burns) and acid (inflicts blind and armor pierce) damage and maybe interact with what type that the steamstave is set to (requires steam stave) uses steam and vim

Steam-Staff-Combat? skill tree that uses the steam staff in combat (most if not all are steam based attacks and such (can not be affected by silence)
1st rush attack that uses steam to deal damage based on weapon damage and inflicts secondary damage that is based on ammo equipped (uses steam (10?) and deals extra damage based on the equipped ammo) creates a harmless smokescreen after the hit the blocks line of sight of anyone without a lense equiped or some other form of protection to the eyes
2 fire a steam beam that uses your equipped ammo to deal effects based the equipped ammos damage that weakens in effect with each enemy hit
3 escape skill that uses steam (of which?) to allow you to increase you movement speed by x for x duration at the cost of steam and allows you to move past targets in the way?
4 fires 3 - 5 bombs that explode and have effects based on the ammo equipped (requires steam-staff and gem ammo) (intial hit based on weapon damage (with steampower) with explosions scale based on steampower

corrupted-nature (arcaneacid/arcane/with small amount in nature based damage (35% arcane, 10% nature, 55% acid) tree the uses corrupted arcane resource damage skills (this damage type can inflict silence and extra equilibrium loss on crit)
1 Arcana Siphon make one of the talents grant vim/and health 6 cooldown by draining arcane resources of targets (dealing damage damage based off of resources drained combined with corrupted nature damage) and ofseting there equilibrium :P
2 Summon Arcane Ooze Horror requires 10% of hp to summon and 5 vim (hp of horror scales to 200% - 250%? of the hp cost) arcane horror (will make custom summoning type for this will use the users onhit effects of weapon(s)? :P) slime (if its attacks hit the player it will heal them for x instead of damaging them or inflicting harm of any sort) that has steampower that player has summon that can silence targets and deal its corrupted nature/acid arcane damage (gets bonuses from blighted summoning and skill?) give it skill tree of based of mitosis tree thats been changed when it takes x damage it creates a lesser copy of itself that it can reabsorb with its skills 2nd absorb one of its clones to heal steam vim and health 3rd
3 Corrupted Smog Manipulation sustain (does not break stealth) that uses steam and vim that allows you to ignore acid and arcane, grants disarm resistance of x passively, (bonus stealth mod based on your steampower?) and ignoring x of your spelldamage like spellshaping.
4 Corrupted Nature Storm tornado like storm spell 3 radius ? 25 turn cooldown? uses steam and spellpower requires a (does not break stealth when used, requires a steam-stave to be worn to use, grants bonus crit multiplier when it is used in stealth) that drains equilibrium :P, arcane resources of targets, and deals blinding acid and moving to the target point at x speed

Smog Devil generic tree
1st  grants passively bonus steampower based on your spellpower and grants you the ability to convert gems to refined arcane gems (with support for newgems gems) at the cost of 5 steam and 1 vim that is based on your raw level of the talent (can't take points out) and allows you to convert metalic items to gems as per alchemist skill (converting a unique will have chance to give you a random gem unique of that tier?)
2nd sustain (costs 5 vim that is a arcane effect) that gives bonus spellpower based on the % of steam in the steam resource, passively grant the user bonus health and grant bonus armor to light armor
3rd steam sustain that grants bonus armor and stuff if you are wearing light armor and passively grant infravision/see stealth bonus
4th convert life% to vim (long 45 turn to 30 turn cooldown) with a short damage debuff penalty (for both debuff and life cost) gets weaker the higher the level of the skill not usable at 20% life level or less

poison tree is locked at 1.1 mastery if you have got the poisonous unlock

smog-and-steam-veil
1 Smog Devil Stealth (sustained 1 steam a turn) Stealth that scales with steampower
2 Smog Devil's Shadowstrike same as current shadowstrike with slightly less damage multiplier but 1 more duration to its secondary effect
3rd Cloak of Shadows and Steam passive with a active abilty-- passive part:stealth bonus while in its the class's (with the steam cloud from the other steam class working to activate it)  gas/steam clouds, immunity to damage from your own poison clouds (not from ignited clouds though), life regen based on your steampower when in stealth with extra bonus while in a steam cloud(etc), and increased spell speed while in a steam/gas cloud. On activation:Steam vent trap (trap power based on spellpower) that spreads steam from a nearby wall?
4th Dance of Shadows and Steam clone of Shadow Dance that uses 30 steam instead of 30 stamina and the classes stealth tree


use steam_stave_range = Talents.main_env.archery_range if i need the weapons range for a talent




Last edited by Hellcommander on Wed Apr 12, 2017 1:38 am, edited 10 times in total.

Top
 Profile  
 
PostPosted: Thu Apr 06, 2017 9:29 am 
Offline
Archmage

Joined: Tue Nov 09, 2010 7:43 pm
Posts: 355
current Smog-devil-misc-talents.lua:
Code:
newTalent{
   name = "Steam Staff Blast", shortname= "steam_staff_blast", --mostly renamed shoot atm that costs steam to use so that i can have the steam stave as a melee and ranged weapon
   type = {"steamtech/smog_devil_misc_talents", 1},
   no_energy = "fake",
   speed = 'archery',
   hide = true,
   innate = true,
   steam = 2,
   points = 1,
   stamina = function(self, t)
      if not self:isTalentActive("T_SKIRMISHER_BOMBARDMENT") or not wardenPreUse(self, t, false, "sling") then return nil end

      local b = self:getTalentFromId("T_SKIRMISHER_BOMBARDMENT")
      return b.shot_stamina(self, b)
   end,
   range = archery_range,
   message = "@Source@ shoots!",
   requires_target = true,
   tactical = { ATTACK = { weapon = 1 } },
   on_pre_use = function(self, t, silent) return wardenPreUse(self, t, silent) end, --need to add a on_preuse to check if you have a subtype of STEAM_STAVE later on
   no_unlearn_last = true,
   archery_onreach = function(self, t, x, y, tg, target)
      if not target then return end
      if self:knowTalent(self.T_FIRST_BLOOD) then
         local perc = (target.life / target.max_life)
         if perc >= 0.9 then
            self.turn_procs.first_blood_shoot = target.life
         end
      end
      if target:hasEffect(target.EFF_PIN_DOWN) then self.turn_procs.auto_phys_crit = true end
   end,
   archery_onmiss = function(self, talent, target, x, y)
      if target:hasEffect(target.EFF_PIN_DOWN) then self.turn_procs.auto_phys_crit = nil end
      if self.mark_steady then self.mark_steady = nil end
   end,
   archery_onhit = function(self, t, target, x, y)
      if self:knowTalent(self.T_MASTER_MARKSMAN) then
         local chance = 15 + (self.mark_steady or 0)
         if self:isTalentActive(self.T_AIM) then   
            chance = chance + self:callTalent(self.T_AIM, "getMarkChance")
         end
         if self:hasEffect(self.EFF_TRUESHOT) then chance = chance * 2 end
         if target:hasEffect(target.EFF_PIN_DOWN) then
            local eff = target:hasEffect(target.EFF_PIN_DOWN)
            chance = 100
            self.turn_procs.auto_phys_crit = nil
            target:removeEffect(target.EFF_PIN_DOWN)
         end
         if self.turn_procs.first_blood_shoot then chance = chance + 50 end
         if rng.percent(chance) then target:setEffect(target.EFF_MARKED, 5, {src=self}) end
      end
      if self.turn_procs.first_blood_shoot then
         local life_diff = self.turn_procs.first_blood_shoot - target.life
         local scale = self:callTalent(self.T_FIRST_BLOOD, "getBleed")
         if life_diff > 0 and target:canBe('cut') and scale then
            target:setEffect(target.EFF_CUT, 5, {power=life_diff * scale / 5, src=self, apply_power=self:combatPhysicalpower(), no_ct_effect=true})
         end
      end
      if self.mark_steady then self.mark_steady = nil end
      if self:knowTalent(self.T_FIRST_BLOOD) then self:incStamina(self:callTalent(self.T_FIRST_BLOOD, "getStamina")) end
   end,
   action = function(self, t)
      local swap = not self:attr("disarmed") and (self:attr("warden_swap") and doWardenWeaponSwap(self, t, "bow"))
   
      -- Most of the time use the normal shoot.
      if not wardenPreUse(self, t, true, "sling") or not self:isTalentActive("T_SKIRMISHER_BOMBARDMENT") then
         local targets = self:archeryAcquireTargets(nil, {one_shot=true})
         if not targets then if swap then doWardenWeaponSwap(self, t, "blade") end return end
         if self:knowTalent(self.T_STEADY_SHOT) and not self:isTalentCoolingDown(self.T_STEADY_SHOT) then
            self:archeryShoot(targets, t, nil, {mult=self:callTalent(self.T_STEADY_SHOT, "getDamage")} )
            self.mark_steady = self:callTalent(self.T_STEADY_SHOT, "getBonusMark")
            self:startTalentCooldown(self.T_STEADY_SHOT)
         else
            self:archeryShoot(targets, t, nil) -- use_psi_archery set by Archery:archeryShoot
         end
         return true
      end
      
      -- perform Bombardment if possible
      local weapon, ammo, offweapon, pf_weapon = self:hasArcheryWeapon("sling")
      if not weapon and not pf_weapon then return nil end

      local bombardment = self:getTalentFromId("T_SKIRMISHER_BOMBARDMENT")
      local shots = bombardment.bullet_count(self, bombardment)
      local mult = bombardment.damage_multiplier(self, bombardment)

      -- Do targeting.
      local old_target_forced = game.target.forced
      local tg = {type = "bolt", range = archery_range(self),   talent = t}
      local x, y, target = self:getTarget(tg)
      if not x or not y then return end
      game.target.forced = {x, y, target}

      -- Fire all shots, limited by stamina
      local count = 0
      local stam = t.stamina(self, t)*self.resources_def[self.RS_STAMINA].cost_factor(self, t)
      for i = 1, shots do
         local targets = self:archeryAcquireTargets(nil, {no_energy=true, one_shot=true, type="sling"})
         if not targets then break end
         
         if count > 0 then
            if self:getStamina() < stam*2 then break end
            
            self:incStamina(-stam)
         end
         count = i
         self:archeryShoot(targets, t, nil, {mult=mult, type="sling"})
      end
      if count > 0 then
         local speed = self:combatSpeed(weapon or pf_weapon)
         self:useEnergy(game.energy_to_act * (speed or 1))
      end
      game.target.forced = old_target_forced

      return count > 0
   end,
   info = function(self, t)
      return ([[Shot with your steam-staff!]])
   end,
}


Last edited by Hellcommander on Sat Apr 08, 2017 4:04 am, edited 1 time in total.

Top
 Profile  
 
PostPosted: Fri Apr 07, 2017 12:49 am 
Offline
Higher

Joined: Tue Dec 18, 2012 3:54 am
Posts: 74
You can put code inside of [code][/code] blocks to format it properly, FYI.


Top
 Profile  
 
PostPosted: Sat Apr 08, 2017 4:05 am 
Offline
Archmage

Joined: Tue Nov 09, 2010 7:43 pm
Posts: 355
ok added it to code block


Top
 Profile  
 
PostPosted: Sun Apr 09, 2017 7:52 am 
Offline
Archmage

Joined: Tue Nov 09, 2010 7:43 pm
Posts: 355
Here is the current Smog and Steam Veil skill tree (steamtech stealth):
Code:
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009 - 2017 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program.  If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org

-- Compute the total detection ability of enemies to see through stealth
-- Each foe loses 10% detection power per tile beyond range 1
-- returns detect, closest = total detection power, distance to closest enemy
-- if estimate is true, only counts the detection power of seen actors
local function Smog_Devil_stealthDetection(self, radius, estimate)
   if not self.x then return nil end
   local dist = 0
   local closest, detect = math.huge, 0
   for i, act in ipairs(self.fov.actors_dist) do
      dist = core.fov.distance(self.x, self.y, act.x, act.y)
      if dist > radius then break end
      if act ~= self and act:reactionToward(self) < 0 and not act:attr("blind") and (not act.fov or not act.fov.actors or act.fov.actors[self]) and (not estimate or self:canSee(act)) then
         detect = detect + act:combatSeeStealth() * (1.1 - dist/10) -- detection strength reduced 10% per tile
         if dist < closest then closest = dist end
      end
   end
   return detect, closest
end
Talents.Smog_Devil_stealthDetection = Smog_Devil_stealthDetection

-- radius of detection for stealth talents
local function Smog_Devil_stealthRadius(self, t, fake)
   local base = math.ceil(self:combatTalentLimit(t, 0, 8.9, 4.6)) -- Limit to range >= 1
   local sooth = self:callTalent(self.T_SOOTHING_DARKNESS, "getRadius", fake)
   local final = math.max(0, base - sooth)
   if fake then return base, final
   else return final
   end
end

-- make its stealth scale with spellpower and steampower
newTalent{
   short_name = 'smog_devil_stealth',--this needs to get bonuses from steampower and not get as much from cunning
   name = "Smog Devil Stealth",
   type = {"steamtech/smog-and-steam-veil", 1},
   require = cuns_req1,
   drain_steam = 0.5,
   mode = "sustained", no_sustain_autoreset = true,
   points = 5,
   cooldown = 10,
   allow_autocast = true,
   no_energy = true,
   tactical = { BUFF = 3 },
   no_break_stealth = true,
   getStealthPower = function(self, t) return math.max(0, self:combatScale(self:getCun(10, true) * self:getTalentLevel(t), 15, 1, 64, 50, 0.25)) end, --TL 5, cun 100 = 64
   getRadius = Smog_Devil_stealthRadius,
   on_pre_use = function(self, t, silent, fake)
      local armor = self:getInven("BODY") and self:getInven("BODY")[1]
      if armor and (armor.subtype == "heavy" or armor.subtype == "massive") then
         if not silent then game.logPlayer(self, "You cannot be stealthy with such heavy armour on!") end
         return nil
      end
      if self:isTalentActive(t.id) then return true end
      
      -- Check nearby actors detection ability
      if not self.x or not self.y or not game.level then return end
      if not rng.percent(self.hide_chance or 0) then
         if Smog_Devil_stealthDetection(self, t.getRadius(self, t)) > 0 then
            if not silent then game.logPlayer(self, "You are being observed too closely to enter Stealth!") end
            return nil
         end
      end
      return true
   end,
   sustain_lists = "break_with_stealth",
   activate = function(self, t)
      if self:knowTalent(self.T_SOOTHING_DARKNESS) then
         local life = self:callTalent(self.T_SOOTHING_DARKNESS, "getLife")
         local dur = self:callTalent(self.T_SOOTHING_DARKNESS, "getDuration")
         self:setEffect(self.EFF_SMOG_DEVIL_CLOAK_OF_SHADOWS_AND_STEAM", dur, {life=life})
      end
      local res = {
         stealth = self:addTemporaryValue("stealth", t.getStealthPower(self, t)),
         lite = self:addTemporaryValue("lite", -1000),
         infra = self:addTemporaryValue("infravision", 1),
      }
      self:resetCanSeeCacheOf()
      if self.updateMainShader then self:updateMainShader() end
      return res
   end,
   deactivate = function(self, t, p)
      self:removeTemporaryValue("stealth", p.stealth)
      self:removeTemporaryValue("infravision", p.infra)
      self:removeTemporaryValue("lite", p.lite)
      if self:knowTalent(self.T_TERRORIZE) then
         local t = self:getTalentFromId(self.T_TERRORIZE)
         t.terrorize(self,t)
      end

      if self:knowTalent(self.T_SMOG_DEVIL_SHADOWSTRIKE) then
         local power = self:callTalent(self.T_SMOG_DEVIL_SHADOWSTRIKE, "getMultiplier") * 100
         local dur = self:callTalent(self.T_SMOG_DEVIL_SHADOWSTRIKE, "getDuration")
         
         self:setEffect(self.EFF_SHADOWSTRIKE, dur, {power=power})
      end

      if self:knowTalent(self.T_SMOG_DEVIL_CLOAK_OF_SHADOWS_AND_STEAM) then
         local life = self:callTalent(self.T_SMOG_DEVIL_CLOAK_OF_SHADOWS_AND_STEAM, "getLife") * 5
         local dur = self:callTalent(self.T_SMOG_DEVIL_CLOAK_OF_SHADOWS_AND_STEAM, "getDuration")
         self:setEffect(self.EFF_SMOG_DEVIL_CLOAK_OF_SHADOWS_AND_STEAM, dur, {life=life})
      end

      local sd = self:hasEffect(self.EFF_SHADOW_DANCE)
      if sd then
         sd.no_cancel_stealth = true
         self:removeEffect(sd.effect_id)
      end
      self:resetCanSeeCacheOf()
      if self.updateMainShader then self:updateMainShader() end
      return true
   end,
   callbackOnActBase = function(self, t)
      if self:knowTalent(self.T_SMOG_DEVIL_CLOAK_OF_SHADOWS_AND_STEAM) then
         local life = self:callTalent(self.T_SMOG_DEVIL_CLOAK_OF_SHADOWS_AND_STEAM, "getLife")
         local dur = self:callTalent(self.T_SMOG_DEVIL_CLOAK_OF_SHADOWS_AND_STEAM, "getDuration")
         self:setEffect(self.EFF_SMOG_DEVIL_CLOAK_OF_SHADOWS_AND_STEAM, dur, {life=life})
      end
   end,
   info = function(self, t)
      local stealthpower = t.getStealthPower(self, t) + (self:attr("inc_stealth") or 0)
      local radius, rad_dark = t.getRadius(self, t, true)
      xs = rad_dark ~= radius and (" (range %d in an unlit grid)"):format(rad_dark) or ""
      return ([[Enters stealth mode (power %d, based on Cunning and steampower), making you harder to detect.
      If successful (re-checked each turn), enemies will not know exactly where you are, or may not notice you at all.
      Stealth reduces your light radius to 0, and will not work with heavy or massive armours.
      You cannot enter stealth if there are foes in sight within range %d%s.
      Any non-instant, non-movement action will break stealth if not otherwise specified.]]):
      format(stealthpower, radius, xs)
   end,
}
---smog devils shadow strike is a version that has less mult but slightly longer duration of 2nd effect
newTalent{
   short_name = 'smog_devil_shadowstrike',
   name = "Smog Devil's Shadowstrike",
   type = {"steamtech/smog-and-steam-veil", 2},
   require = cuns_req2,--change to scaling requirements based on Smog Devil class
   mode = "passive",
   points = 5,
   getMultiplier = function(self, t) return self:combatTalentScale(t, 0.15, 0.40, 0.1) end, --scale this slightly lower
   getDuration = function(self,t) if self:getTalentLevel(t) >= 4 then return 5 else return 4 end end,
   passives = function(self, t, p) -- attribute that increases crit multiplier vs targets that cannot see us
      self:talentTemporaryValue(p, "unseen_critical_power", t.getMultiplier(self, t))
   end,
   info = function(self, t)
      local multiplier = t.getMultiplier(self, t)*100
      local dur = t.getDuration(self, t)
      return ([[You know how to make the most out of being unseen.
      When striking from stealth, your attacks are automatically critical if the target does not notice you just before you land it.  (Spell and mind attacks critically strike even if the target notices you.)
      Your critical multiplier against targets that cannot see you is increased by up to %d%%. (You must be able to see your target and the bonus is reduced from its full value at range 5 to 0 at range 10.)
      Also, after exiting stealth for any reason, the critical multiplier persists for %d turns (with no range limitation).]]):format(multiplier, dur)
   end,
}

newTalent{
   short_name = 'smog_devil_cloak_of_shadows_and_steam', --give a other effect that stacks to while in steam and smog from Smog Devil's attacks (not from explosions though) that will decrease a stack while outside of these map effects/attacks, while you have at least 1 stack of fog veil(or whatever i name the stack effect) the steam the drained steam from the stealth will be refunded in the form of steam regen, gains a bonus to stealth based on how many stacks of fog veil the user has (scales with steampower)
   name = "Cloak of Shadows and Steam",--steam / gas based replacement for soothing Darkness
   type = {"steamtech/smog-and-steam-veil", 3},
   require = cuns_req3,
   points = 5,
   mode = "passive",
   getLife = function(self, t) return self:combatStatScale("cun", 0.5, 5, 0.75) + self:combatTalentScale(t, 0.5, 5, 0.75) end,
   getRadius = function(self, t, fake)
      if not fake and game.level.map.lites(self.x, self.y) then return 0 end
      return math.floor(self:combatTalentLimit(t, 10, 2, 5))
   end,
   getDuration = function(self,t) if self:getTalentLevel(t) >= 3 then return 4 else return 3 end end,
   info = function(self, t)
      return ([[You have a special affinity for darkness and shadows.
      When standing in an unlit grid, the minimum range to your foes for activating stealth or for maintaining it after a Shadow Dance is reduced by %d.
      While stealthed, your life regeneration is increased by %0.1f (based on your Cunning) and your stamina regeneration is increased by %0.1f.  The regeneration effects persist for %d turns after exiting stealth, with 5 times the normal life regeneration rate.]]):
      format(t.getRadius(self, t, true), t.getLife(self,t), t.getBonusSteamregen(self,t), t.getDuration(self, t))
   end,
}

newTalent{
   short_name = 'smog_devil_dance_of_shadows_and_steam',
   name = "Dance of Shadows and Steam",--this is pretty much just renamed shadow dance with skills it uses being different and steam cost instead of stamina cost (will also be able to reduce range requirement of unlit grid based on if user has full stack of fog veil)
   type = {"steamtech/smog-and-steam-veil", 4},
   require = cuns_req4,
   no_energy = true,
   no_break_stealth = true,
   points = 5,
   steam = 30,
   cooldown = function(self, t) return self:combatTalentLimit(t, 10, 30, 15) end,
   tactical = { DEFEND = 2, ESCAPE = 2 },
   getRadius = Smog_Devil_stealthRadius,
   getDuration = function(self, t) return math.floor(self:combatTalentLimit(t, 7, 2, 5)) end,
   action = function(self, t)
      if not self:isTalentActive(self.T_SMOG_DEVIL_STEALTH) then
         self:forceUseTalent(self.T_SMOG_DEVIL_STEALTH, {ignore_energy=true, ignore_cd=true, no_talent_fail=true, silent=true})
         for act, param in pairs(self.fov.actors) do
            if act ~= self and act.ai_target and act.ai_target.actor == self then act:setTarget() end
         end
      end
      self:alterTalentCoolingdown(self.T_SMOG_DEVIL_STEALTH, -20)
      self:setEffect(self.EFF_SHADOW_DANCE, t.getDuration(self,t), {src=self, rad=t.getRadius(self,t)})
      
      return true
   end,
   info = function(self, t)
      local radius, rad_dark = t.getRadius(self, t, true)
      xs = rad_dark ~= radius and (" (range %d in an unlit grid)"):format(rad_dark) or ""
      return ([[Your mastery of stealth allows you to vanish from sight at any time.
      You automatically enter stealth mode, reset its cooldown, and cause it to not break from unstealthy actions for %d turns.  If you were not already stealthed, all enemies in a direct line of sight completely lose track of you.
      When your Shadow Dance ends, you must make a stealth check against targets in radius %d%s or be revealed.]]):
      format(t.getDuration(self, t), radius, xs)
   end,
}


Top
 Profile  
 
PostPosted: Wed Aug 16, 2017 4:14 am 
Offline
Archmage

Joined: Tue Nov 09, 2010 7:43 pm
Posts: 355
Ok bumping this so when i get around to finishing this that it won't be locked.


Top
 Profile  
 
PostPosted: Fri May 11, 2018 12:05 am 
Offline
Archmage

Joined: Tue Nov 09, 2010 7:43 pm
Posts: 355
Think I'll wait on working on this more til the addon limit bug is fixed.(I also have issues to fix on my main computer atm)


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group