Hi guys,
I can't give the passable flag to an 'dead' entity (e.g. a just killed enemy). What I'm doing wrong? Thanks for taking the time!
// state 4: death animation ////////////////////////////////////
if(my.STATE == 4)
{
c_trace(my.x,vector(my.x,my.y,my.z-1000),IGNORE_ME | IGNORE_PASSABLE);
my.z = hit.z - vFeet.z;
set(my,PASSABLE);
my.ANIMATION += 3*time_step;
ent_animate(me,"death",my.ANIMATION,0); // animate the entity
if (my.ANIMATION > 70)
return;
}
ps: I'm certain that the code runs, only the 'set(my,PASSABLE);' doesn't work.
-edit; the manual says this (which doesn't work with with me):
PASSABLE
If the PASSABLE flag of an entity is set, its collision detection is switched off. Other entities can move straight through it, collision events are not triggered. Setting this flag for as many entities as possible increases the frame rate.
Type:
flag
Example:
my.PASSABLE = ON;set(my,PASSABLE);