|
Re: can someone pls help me converter this to lice-c..
[Re: ZeroEight]
#251071
02/11/09 14:07
02/11/09 14:07
|
Joined: Aug 2008
Posts: 2,838 take me down to the paradise c...
Cowabanga
Expert
|
Expert
Joined: Aug 2008
Posts: 2,838
take me down to the paradise c...
|
Don't use that "up" ! This should work: BMAP* rainBmap = "drop.tga";
var rainAnzahlPartikel = 12; //number of particles used for this effect
#define lifespan skill70
#define bmap skill71
#define vel_x skill72
#define vel_y skill73
#define vel_z skill74
#define size skill75
#define gravity skill76
function rain_spec_fun()
{
my.alpha -= 0 * time_step;
if(my.alpha < 0) { my.alpha = 0; my.lifespan = 0; }
my.skill_b += 0.03;
my.skill_c = 6 - my.skill_b;
if(my.skill_c < 0) { my.lifespan = 0; }
}
function rainspezial()
{
my.blue = 128 ;
my.green = 128 ;
my.red = 128 ;
my.skill_c = 0; my.skill_b = 0;
my.bmap = rainBmap; //the effect bitmap
my.vel_x = random( 0 ) - 0 ;
my.vel_y = random( 0 ) - 0 ;
my.vel_z = -40 ;
my.size = 14 ;
my.alpha = 100 ;
my.x += random(1000)-500;
my.y += random(1000)-500;
my.z += random(100)-50;
my.gravity = 10 ;
reset(my, STREAK);
reset(my, BRIGHT);
reset(my, BEAM);
set(my, MOVE);
set(my, TRANSLUCENT);
my.event = rain_spec_fun;
}
function rain()
{
while(1)
{
rainAnzahlPartikel = 12;
var mypos[3];
VECTOR temp;
vec_set(mypos,camera.x);
temp.x = cos(camera.pan);
temp.y = sin(camera.pan);
temp.z = 600*cos(camera.tilt);
mypos.x = mypos.x + temp.z*temp.x;
mypos.y = mypos.y + temp.z*temp.y;
mypos.z = mypos.z + 600*sin(camera.tilt);
mypos.Z = camera.z + 800;
effect(rainspezial,max(1,int(rainAnzahlPartikel*time_step)),mypos,nullvector);
wait(1);
}
}
action rain_action()
{
set(my, INVISIBLE);
set(my, PASSABLE);
rain();
}
|
|
|
|