From ef1f371dab95522343b27c5bed65ffe655666294 Mon Sep 17 00:00:00 2001 From: peterbell10 Date: Tue, 5 Sep 2017 15:11:35 +0100 Subject: Add cWorld::RemoveEntity and use in cEntity (#4003) * Add cWorld::RemoveEntity and use in cEntity * cEntity: Remove uneeded asserts from Destroy and DoMoveToWorld --- src/World.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/World.h') diff --git a/src/World.h b/src/World.h index cbaf9cb95..b1a5e8d79 100644 --- a/src/World.h +++ b/src/World.h @@ -301,6 +301,10 @@ public: Note: Only loaded chunks are considered. */ bool HasEntity(UInt32 a_UniqueID); + /** Removes the entity from the world. + Returns an owning reference to the found entity. */ + OwnedEntity RemoveEntity(cEntity & a_Entity); + /** Calls the callback for each entity in the entire world; returns true if all entities processed, false if the callback aborted by returning true */ bool ForEachEntity(cEntityCallback & a_Callback); // Exported in ManualBindings.cpp -- cgit v1.2.3