Skip to content
Snippets Groups Projects
Commit 5c2575b6 authored by DarkGod's avatar DarkGod
Browse files

New hands "glow" effect for Shadow Combat

parent ff843f5a
No related branches found
No related tags found
No related merge requests found
Pipeline #
......@@ -16,6 +16,7 @@
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
local Particles = require "engine.Particles"
newBirthDescriptor{
type = "class",
......@@ -109,6 +110,13 @@ newBirthDescriptor{
"#LIGHT_BLUE# * +3 Magic, +0 Willpower, +3 Cunning",
"#GOLD#Life per level:#LIGHT_BLUE# +0",
},
birth_example_particles = {
function(actor) if core.shader.active(4) then
local slow = rng.percent(50)
local h1x, h1y = actor:attachementSpot("hand1", true) if h1x then actor:addParticles(Particles.new("shader_shield", 1, {img="shadowhands_01", dir=180, a=0.7, size_factor=0.4, x=h1x, y=h1y-0.1}, {type="flamehands", time_factor=slow and 700 or 1000})) end
local h2x, h2y = actor:attachementSpot("hand2", true) if h2x then actor:addParticles(Particles.new("shader_shield", 1, {img="shadowhands_01", dir=180, a=0.7, size_factor=0.4, x=h2x, y=h2y-0.1}, {type="flamehands", time_factor=not slow and 700 or 1000})) end
end end,
},
power_source = {technique=true, arcane=true},
stats = { dex=3, mag=3, cun=3, },
talents_types = {
......
......@@ -24,7 +24,7 @@ local g = g or 1
local b = b or 1
local a = a or 1
return { blend_mode = blend and core.particles.BLEND_SHINY or nil, generator = function()
return { blend_mode = blend and core.particles.BLEND_SHINY or nil, system_rotation = dir or 0, system_rotationv = 0, generator = function()
return {
trail = 0,
life = 10,
......
game/modules/tome/data/gfx/particles_images/shadowhands_01.png

31.1 KiB

......@@ -30,7 +30,13 @@ newTalent{
getDamage = function(self, t) return 2 + self:combatTalentSpellDamage(t, 2, 50) end,
getManaCost = function(self, t) return 2 end,
activate = function(self, t)
return {}
local ret = {}
if core.shader.active(4) then
local slow = rng.percent(50)
local h1x, h1y = self:attachementSpot("hand1", true) if h1x then self:talentParticles(ret, {type="shader_shield", args={img="shadowhands_01", dir=180, a=0.7, size_factor=0.4, x=h1x, y=h1y-0.1}, shader={type="flamehands", time_factor=slow and 700 or 1000}}) end
local h2x, h2y = self:attachementSpot("hand2", true) if h2x then self:talentParticles(ret, {type="shader_shield", args={img="shadowhands_01", dir=180, a=0.7, size_factor=0.4, x=h2x, y=h2y-0.1}, shader={type="flamehands", time_factor=not slow and 700 or 1000}}) end
end
return ret
end,
deactivate = function(self, t, p)
return 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