#define I_AM_DEAD (1<<30) //unused entity flag bit
void runWhileEntity(ENTITY* inLight)
{
while(!is(inLight, I_AM_DEAD))
{
inLight.x += time_step;
my_temp[0] = inLight.x;
wait(1);
}
ent_remove(inLight);
beep();
beep();
beep();
}
void main()
{
set(deb_pan,SHOW);
level_load(NULL);
wait(3);
ENTITY* theEnt;
theEnt = ent_create(NULL,nullvector,NULL);
runWhileEntity(theEnt);
while(key_t == OFF) wait(1);
set(inLight, I_AM_DEAD);
}