Removes a level, view, or sky entity.
ENTITY* - Pointer to the entity to be
must not be used anymore, otherwise a crash will be the result. All my and you pointers to that entity are set to NULL in all functions. ent_remove also terminates all other functions that use the removed entity for the my pointer, including all functions called by the entity, unless A7.76 proc_mode is set to PROC_GLOBAL for a particular function.
After an entity is removed, its file content is still stored in a cache for faster creation of entitities of this type. The cache is emptied when the level is changed.
If this is not desired for some reason, keep the file in the cache by defining an invisible view entity with the same file.
Entities can also be removed by the ptr_remove function.
ent_remove(me); // The 'me' entity is removed