From e80c5eac4041e6e6b2c1bbc8fe67278768098a7a Mon Sep 17 00:00:00 2001 From: madmaxoft Date: Mon, 19 Aug 2013 11:44:11 +0200 Subject: Added cPickup:GetAge() the the Lua API. --- source/Entities/Pickup.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'source/Entities') diff --git a/source/Entities/Pickup.h b/source/Entities/Pickup.h index 1f32c97b5..90292dcb8 100644 --- a/source/Entities/Pickup.h +++ b/source/Entities/Pickup.h @@ -37,16 +37,15 @@ public: virtual void Tick(float a_Dt, cChunk & a_Chunk) override; - short GetHealth(void) const { return m_Health; } - /// Returns the number of ticks that this entity has existed - short GetAge(void) const { return (short)(m_Timer / 50); } + int GetAge(void) const { return (int)(m_Timer / 50); } // tolua_export private: Vector3d m_ResultingSpeed; //Can be used to modify the resulting speed for the current tick ;) Vector3d m_WaterSpeed; + /// The number of ticks that the entity has existed / timer between collect and destroy; in msec float m_Timer; cItem m_Item; -- cgit v1.2.3