# RemoveObject

Objects
Existence
5.1 OC
void
bool eject_contents If `true`, the object's contents is exited before deletion of the object. Otherwise, the contents will be deleted as well.
Removes the calling object.
When removing an object, numerous internal references to the object are cleared and any pointer to the object will become invalid. If you have stored a pointer to this object (e.g. in thread local script) you must no longer use this pointer after deletion of the object. If an object removes itself by script it should not execute any more script commands following the removal. The deleting function should immediately end with return.
If the object is a valid crew member at the time of removal, the associated info object in the crew list will not be marked as 'killed', meaning a subsequent call to MakeCrewMember() might reuse the same crew info. To properly kill a clonk until the end of a round use Kill().
Explode
CreateObject
Kill
Sven2
2002-08