From dada2bea27bbc0b5dec68e8089ce5b8c296baabd Mon Sep 17 00:00:00 2001 From: faketruth Date: Wed, 2 Nov 2011 20:19:57 +0000 Subject: Fixed some "Entity was not found in any chunk!" warnings Player's current world is saved in the player file. When a player joins the server, the player joins the last world he was in. It seems MCServer can finally run multiple worlds! It just needs functionality to switch between them git-svn-id: http://mc-server.googlecode.com/svn/trunk@46 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/cEntity.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'source/cEntity.h') diff --git a/source/cEntity.h b/source/cEntity.h index 509a5c1d5..c25c3e293 100644 --- a/source/cEntity.h +++ b/source/cEntity.h @@ -27,6 +27,7 @@ CLASS_DEF_ISA( classname, superclass ) \ CLASS_DEF_GETCLASS( classname ) +class cChunk; class cWorld; class cReferenceManager; class Vector3d; @@ -76,7 +77,8 @@ public: //tolua_export inline int GetUniqueID() { return m_UniqueID; } //tolua_export inline bool IsDestroyed() { return m_bDestroyed; } //tolua_export - void Destroy() { m_bDestroyed = true; } //tolua_export + void Destroy(); //tolua_export + void RemoveFromChunk( cChunk* a_Chunk ); // for internal use in cChunk virtual void Tick(float a_Dt) = 0; //tolua_export @@ -105,6 +107,7 @@ protected: bool m_bDirtyOrientation; bool m_bDestroyed; + bool m_bRemovedFromChunk; ENUM_ENTITY_TYPE m_EntityType; private: -- cgit v1.2.3