Hi,
I’m trying to use a modified version of the light/dark smoke cloud to hide a object in my game. Basically, I need the cloud to appear and quickly cover the 18x18 block. It should fade out pretty quickly, with the block being removed once completely covered.
I’ve managed to get something like this, but configuring the cloud is tricky. The explanations of the properties of particles don’t help either, eg: “Scale-in speed: The scale in speed” is not a helpful piece of documentation.
Here’s my cloud - could someone explain how to modify it so that it appears quickly, animates and disappears almost as quickly as it appeared, all within 1 second, please?
Many thanks,
Matt.
[lua] Particles.CreateParticleType (“HeavySmokeBright”,
{
imagePath = “smoke_heavy_bright.png”,
– imageWidth = 64,
– imageHeight = 64,
weight = 0,
directionVariation = 45,
– velocityVariation = 25,
rotationVariation = 360,
rotationChange = 30,
useEmitterRotation = false,
alphaStart = 0.0,
fadeInSpeed = 1.5,
fadeOutSpeed = -1.5,
fadeOutDelay = 500,
– scaleStart = 0.1,
scaleVariation = 0.1,
scaleInSpeed = 0.1,
emissionShape = 0,
emissionRadius = 10,
killOutsideScreen = true ,
lifeTime = 1000
} )
Particles.CreateParticleType (“HeavySmokeDark”,
{
imagePath = “smoke_heavy_dark.png”,
– imageWidth = 64,
– imageHeight = 64,
weight = 0,
directionVariation = 45,
– velocityVariation = 25,
rotationVariation = 360,
rotationChange = 30,
useEmitterRotation = false,
alphaStart = 0.0,
fadeInSpeed = 1.5,
fadeOutSpeed = -1.5,
fadeOutDelay = 500,
– scaleStart = 0.1,
scaleVariation = 0.1,
scaleInSpeed = 0.1,
emissionShape = 0,
emissionRadius = 10,
killOutsideScreen = true ,
lifeTime = 1000
} )
local emitname = system.getTimer()…x…y
Particles.CreateEmitter(emitname, x, y, 0, false, false, true)
Particles.AttachParticleType(emitname, “HeavySmokeBright”, 3, 500,0)
Particles.AttachParticleType(emitname, “HeavySmokeDark” , 3, 500,0)
Particles.StartEmitter( emitname )[/lua] [import]uid: 8271 topic_id: 6904 reply_id: 306904[/import]