Can you extend this code with your cam code?

Code:
///////////////////////////////
// Particle trail example
// (c) jcl / oP group 2009
// Gamestudio/A7 Commercial+ only
// Low versions don't support BEAM
///////////////////////////////
#include <acknex.h>
#include <default.c>

function p_alphafade(PARTICLE *p)
{
    p.alpha -= p.skill_a*time_step;
    if (p.alpha <= 0) p.lifespan = 0;
}

function p_trace(PARTICLE *p)
{
   set(p,TRANSLUCENT|BEAM);
   p.alpha = 100;
   p.size = 2;
   p.skill_a = 3; // fade factor
   p.event = p_alphafade;
}

action satellite()
{
   var dist = 0,radius = 10,sign = 1;
   VECTOR last_pos;
   while(1) 
   {
      vec_set(last_pos,my.x);
      dist += 30*time_step;
      radius += sign*random(2)*time_step;
      if (radius > 100) sign = -1;
      else if (radius < 10) sign = 1;
      my.x = radius*sin(dist);
      my.y = radius*cos(dist);
      effect(p_trace,1,my.x,vec_sub(last_pos,my.x));
      wait(1);
   }
}

function main()
{
  vec_set(screen_size,vector(800,300,0));
  vec_set(sky_color,vector(50,1,1)); // dark blue
  d3d_antialias = 4;
  video_window(NULL,NULL,0,"Particle trail demo");
  
  level_load(NULL); // necessary for 3D particles
  vec_set(camera.x,vector(-150,0,20));
  vec_set(camera.pan,vector(0,-10,0));
  vec_set(mat_model.ambient_blue,sky_color);  

  ent_create(SPHERE_MDL,vector(0,0,0),NULL);
  ent_create(NULL,vector(0,0,0),satellite);  
}




Regards, Robert

Quote
Everything should be made as simple as possible, but not one bit simpler.
by Albert Einstein

PhysX Preview of Cloth, Fluid and Soft Body

A8.47.1P