Hi!
You could use the ent_next() instruction to access all your level entities.
I modified the example from the manual.
function remove_ents()
{
you = ent_next (NULL); // retrieve first entity
while (you != NULL) // repeat until there are no more entities
{
if(you.skill1 == 5) //just an example
{
ent_remove(you); // remove entity
}
you = ent_next (you); // get next entity
}
}
on_x = remove_ents;
If you use this code and press the x-key, all entities that have skill1 set to 5 should be removed. I hope it works! Iīm no great coder, and didnīt test anything ...