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

New visual effect for hexes

parent 1ebf3d9d
No related branches found
No related tags found
No related merge requests found
......@@ -23,6 +23,9 @@ local speed = speed or 0.023
local a = (a or 60) / 255
local basesize = 2 * radius * (engine.Map.tile_w + engine.Map.tile_h) / 2 + engine.Map.tile_w * 1.8 * (oversize or 1)
local appear = appear or 0
local r = (r or 255) / 255
local g = (g or 255) / 255
local b = (b or 255) / 255
local nb = 0
......@@ -41,9 +44,9 @@ return {
dir = 0, dirv = dirv, dira = 0,
vel = 0, velv = 0, vela = 0,
r = 1, rv = 0, ra = 0,
g = 1, gv = 0, ga = 0,
b = 1, bv = 0, ba = 0,
r = r, rv = 0, ra = 0,
g = g, gv = 0, ga = 0,
b = b, bv = 0, ba = 0,
a = a, av = 0, aa = 0,
}
else
......@@ -57,9 +60,9 @@ return {
dir = 0, dirv = dirv, dira = 0,
vel = 0, velv = 0, vela = 0,
r = 1, rv = 0, ra = 0,
g = 1, gv = 0, ga = 0,
b = 1, bv = 0, ba = 0,
r = r, rv = 0, ra = 0,
g = g, gv = 0, ga = 0,
b = b, bv = 0, ba = 0,
a = a, av = 0, aa = 0,
}
end
......
game/modules/tome/data/gfx/particles_images/blight_circle.png

248 KiB

game/modules/tome/data/gfx/shockbolt/trap/trap_glyph_explosion_02_64.png

10.2 KiB

......@@ -44,6 +44,8 @@ newTalent{
if not target or target == self then return end
target:setEffect(target.EFF_PACIFICATION_HEX, 20, {power=self:combatSpellpower(), chance=t.getchance(self,t), apply_power=self:combatSpellpower()})
end)
local _ _, _, _, x, y = self:canProject(tg, x, y)
game.level.map:particleEmitter(x, y, tg.radius, "circle", {oversize=0.7, a=90, limit_life=8, appear=8, speed=2, img="blight_circle", radius=self:getTalentRadius(t)})
game:playSoundNear(self, "talents/slime")
return true
end,
......@@ -78,6 +80,8 @@ newTalent{
if not target or target == self then return end
target:setEffect(target.EFF_BURNING_HEX, 20, {src=self, dam=self:spellCrit(self:combatTalentSpellDamage(t, 4, 90)), power=1 + t.getCDincrease(self, t), apply_power=self:combatSpellpower()})
end)
local _ _, _, _, x, y = self:canProject(tg, x, y)
game.level.map:particleEmitter(x, y, tg.radius, "circle", {oversize=0.7, g=100, b=100, a=90, limit_life=8, appear=8, speed=2, img="blight_circle", radius=self:getTalentRadius(t)})
game:playSoundNear(self, "talents/slime")
return true
end,
......@@ -114,6 +118,8 @@ newTalent{
if not target or target == self then return end
target:setEffect(target.EFF_EMPATHIC_HEX, 20, {power=t.recoil(self,t), apply_power=self:combatSpellpower()})
end)
local _ _, _, _, x, y = self:canProject(tg, x, y)
game.level.map:particleEmitter(x, y, tg.radius, "circle", {oversize=0.7, r=100, b=100, a=90, limit_life=8, appear=8, speed=2, img="blight_circle", radius=self:getTalentRadius(t)})
game:playSoundNear(self, "talents/slime")
return true
end,
......@@ -149,6 +155,8 @@ newTalent{
target:setEffect(target.EFF_DOMINATION_HEX, t.getDuration(self, t), {src=self, apply_power=self:combatSpellpower(), faction = self.faction})
end
end)
local _ _, _, _, x, y = self:canProject(tg, x, y)
game.level.map:particleEmitter(x, y, tg.radius, "circle", {oversize=0.7, g=100, r=100, a=90, limit_life=8, appear=8, speed=2, img="blight_circle", radius=self:getTalentRadius(t)})
game:playSoundNear(self, "talents/slime")
return true
end,
......
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