As 3dgs_snake already mentioned a simple way would be to use ent_next. You have to make a little adjustment though when you want to remove the entities:

Code:
you = ent_next(NULL);
while(you)
{
	ENTITY* you2 = you;
	you = ent_next(you);
	if(you2._type == type_ball) ptr_remove(you2);
}


A more sophisticated approach would be to create an array (or better: a list) yourself in which you save all ent_created balls.


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends