From 1651fcd9807f1033a5fc76e60cb17922e687a7b1 Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Tue, 28 Aug 2012 21:59:49 +0000 Subject: Moved all packet-serializing code into cProtocol125; half the packet classes aren't needed anymore. git-svn-id: http://mc-server.googlecode.com/svn/trunk@800 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/cEntity.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'source/cEntity.h') diff --git a/source/cEntity.h b/source/cEntity.h index 50955f9ce..a34b7518f 100644 --- a/source/cEntity.h +++ b/source/cEntity.h @@ -121,6 +121,13 @@ public: virtual void SpawnOn(cClientHandle & a_Client) {ASSERT(!"SpawnOn() unimplemented!"); } // tolua_export void WrapRotation(); + + // Metadata flags; descendants may override the defaults: + virtual bool IsOnFire (void) const {return (m_BurnPeriod > 0); } + virtual bool IsCrouched (void) const {return false; } + virtual bool IsRiding (void) const {return false; } + virtual bool IsSprinting(void) const {return false; } + virtual bool IsRclking (void) const {return false; } protected: virtual void Destroyed() {} // Called after the entity has been destroyed @@ -154,6 +161,9 @@ protected: eEntityType m_EntityType; cWorld* m_World; + + float m_FireDamageInterval; + float m_BurnPeriod; }; //tolua_export typedef std::list cEntityList; -- cgit v1.2.3