set (my,INVISIBLE);
reset( my, INVISIBLE);
..
set (my, FLAG1);
reset (my, FLAG1);
if (is(my,FLAG1)) do_something
if (!is(my,FLAG1)) do_something
..
ENTITY* the_light;
ENTITY* the_ent;
action TheLight(){
the_light = me;
the_light.lightrange = 200;
..
}
action TheEnt(){
the_ent = me;
..
}
..
action / function(){
..
while (!the_ent) wait(1);
while (!the_light) wait(1);
var mytimevalue; //fex.
if (mytimevalue >= 100) {
reset (the_ent, VISIBLE);
reset (the_light, VISIBLE); //if visible model
the_light.lightrange = 0;
//reset(the_light, LIGHT);
..
}