2 registered members (NnamueN, 1 invisible),
1,489
guests, and 6
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
Re: can i make a 3second burning effect??
[Re: tasha19]
#360718
02/26/11 13:43
02/26/11 13:43
|
Joined: Apr 2008
Posts: 650
Sajeth
User
|
User
Joined: Apr 2008
Posts: 650
|
yeah there are plenty ways to do so
Teleschrott-Fan.
|
|
|
Re: can i make a 3second burning effect??
[Re: Superku]
#360746
02/26/11 18:15
02/26/11 18:15
|
Joined: Dec 2010
Posts: 13
tasha19
OP
Newbie
|
OP
Newbie
Joined: Dec 2010
Posts: 13
|
/////////////////BURN // function Base_Effect_base_event(PARTICLE* p) { p.vel_x = p.skill_x*p.skill_d/50; p.vel_y = p.skill_y*p.skill_d/50; p.vel_z = p.skill_z*p.skill_d/50; p.skill_d = (p.skill_d + time_step*(var)1.000)%100; }
function Base_Effect_base(PARTICLE* p) { p.size = 2; p.alpha = 100.000; p.red = 128; p.green = 128; p.blue = 128; p.skill_c = 0.5; p.vel_x = random(2.000)+(-1.000); p.vel_y = random(2.000)+(-1.000); p.vel_z = (3.000); p.lifespan = 10; p.gravity = 0.000; p.bmap = fire3_map; p.flags = BRIGHT | TRANSLUCENT | MOVE; p.skill_x = p.vel_x; p.skill_y = p.vel_y; p.skill_z = p.vel_z; p.event = Base_Effect_base_event; }
/////////////////////////////////emitter actions/////////////////////////////////
action Base_Effect_emitter() { var eff_frac; eff_frac = 0; wait(1); while(my) { parted_temp_vec.x = 0.000; parted_temp_vec.y = 0.000; parted_temp_vec.z = 0.000; vec_add(parted_temp_vec,my.x); eff_frac += 0.100*time_step*0.001; if(eff_frac >= 1){ effect(Base_Effect_base,integer(eff_frac),parted_temp_vec,nullvector); eff_frac -= integer(eff_frac); } wait(1); } } /////////////////////////////////creation/////////////////////////////////
function fire_create(VECTOR* position) { if(!position)position = nullvector; wait(3); you = ent_create(NULL,position,Base_Effect_emitter); if(you) { vec_add(you.x,vector(-128.786,-19.160,0.000)); vec_set(you.pan,vector(0.000,0.000,0.000)); vec_set(you.scale_x,vector(1.000,1.000,1.000)); set(you,PASSABLE); set(you,INVISIBLE); } } ///////////////////////////////////////////////// function PUTOUTOFNOWHERE(ENTITY* oonwPIECE){ //put the piece out of no where once eliminated Base_Effect_emitter();//this is the action of the burning effect wait(1); //i want to stop the burning effect just right here oonwPIECE.z = 10; oonwPIECE.flags |= TRANSLUCENT; oonwPIECE.alpha = 0; oonwPIECE = NULL; wait(1); }
|
|
|
Re: can i make a 3second burning effect??
[Re: tasha19]
#360747
02/26/11 18:21
02/26/11 18:21
|
Joined: Aug 2007
Posts: 1,922 Schweiz
Widi
Serious User
|
Serious User
Joined: Aug 2007
Posts: 1,922
Schweiz
|
function fire_create(VECTOR* position)
{
if(!position)position = nullvector;
wait(3);
you = ent_create(NULL,position,Base_Effect_emitter);
if(you)
{
vec_add(you.x,vector(-128.786,-19.160,0.000));
vec_set(you.pan,vector(0.000,0.000,0.000));
vec_set(you.scale_x,vector(1.000,1.000,1.000));
set(you,PASSABLE);
set(you,INVISIBLE);
}
wait(-3); // wait 3 seconds
ptr_remove(me); // ...and remove the emitter
}
Last edited by Widi; 02/26/11 18:22.
|
|
|
|