improvements to particles and animation can now have variable speed

This commit is contained in:
lustlion
2022-03-09 06:04:36 +01:00
parent e8242f6564
commit d3796a0204
6 changed files with 38 additions and 23 deletions

View File

@@ -78,10 +78,13 @@ function Fairy:doLogic()
local particle_data = {
animation = animation.particle.simple,
animation_speed = 1,
sprite_tint = hex2rgb("#fed100"),
sprite_alpha_fade = true,
direction = angle-math.rad(180+math.random(60)-30),
speed = 0.8*(distance/50),
speed_increase = -0.01,
time = 0.75
}
Particle:new(self.pos.x,self.pos.y,particle_data)
end