Here's working Lite-C example:
Code:
 

//// Particle movement handling ///////
function vec_randomize (var* vec, var range)
{
   vec[0] = random(0.5) - 0.25;
   vec[1] = random(0.5) - 0.25;
   vec[2] = random(1) - 0.25;
   vec_normalize(vec,random(range));
}

//// particle alpha handling ////////
function part_alphafade(PARTICLE *p)
{
   p.alpha -= 1*time_step;
   if (p.alpha <= 0) p.lifespan = 0;
}

///// particle creating /////////
function effect_smokes(PARTICLE *p)
{
   p.red = 100;
   p.blue = 100;
   p.green = 100;
   var temp[3];
   vec_randomize(temp,3);
   vec_add (p.vel_x, temp);
   p.alpha = 50 + random(25);
   p.size = 30;
   p.bmap = rauch2_farbe6;
   p.flags |= (MOVE);
   p.event = part_alphafade; // change to a shorter, faster function
}
//// particle using  /////////
action destroyed_tank()
{
  while(1)
  {
	effect(effect_smokes,50,my.x,normal);
	wait(20);
  }
}




Study code, manual, and you'll learn to use it, modify, and create lots of effect wink

Jaxas


The smaller the bug, the harder it is to kill.
_________________________________________
Forklift DEMO (3dgs)