diff options
author | Tiger Wang <ziwei.tiger@hotmail.co.uk> | 2014-11-04 22:53:37 +0100 |
---|---|---|
committer | Tiger Wang <ziwei.tiger@hotmail.co.uk> | 2014-11-04 22:53:37 +0100 |
commit | 3d00e52d42edc69eb777c90c6e6f479a5a473598 (patch) | |
tree | 9ed2245653c77b7de86678c345254fe70342126e /src/Entities/Pickup.h | |
parent | More player speed/position overrides (diff) | |
download | cuberite-3d00e52d42edc69eb777c90c6e6f479a5a473598.tar cuberite-3d00e52d42edc69eb777c90c6e6f479a5a473598.tar.gz cuberite-3d00e52d42edc69eb777c90c6e6f479a5a473598.tar.bz2 cuberite-3d00e52d42edc69eb777c90c6e6f479a5a473598.tar.lz cuberite-3d00e52d42edc69eb777c90c6e6f479a5a473598.tar.xz cuberite-3d00e52d42edc69eb777c90c6e6f479a5a473598.tar.zst cuberite-3d00e52d42edc69eb777c90c6e6f479a5a473598.zip |
Diffstat (limited to 'src/Entities/Pickup.h')
-rw-r--r-- | src/Entities/Pickup.h | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/src/Entities/Pickup.h b/src/Entities/Pickup.h index 4d5250819..4fa430767 100644 --- a/src/Entities/Pickup.h +++ b/src/Entities/Pickup.h @@ -25,7 +25,7 @@ public: CLASS_PROTODEF(cPickup) - cPickup(double a_PosX, double a_PosY, double a_PosZ, const cItem & a_Item, bool IsPlayerCreated, float a_SpeedX = 0.f, float a_SpeedY = 0.f, float a_SpeedZ = 0.f); + cPickup(CreateEntityInfo a_Info, const cItem & a_Item, bool IsPlayerCreated); cItem & GetItem(void) {return m_Item; } // tolua_export const cItem & GetItem(void) const {return m_Item; } @@ -36,12 +36,6 @@ public: virtual void Tick(float a_Dt, cChunk & a_Chunk) override; - /** Returns the number of ticks that this entity has existed */ - int GetAge(void) const { return (int)(m_Timer / 50); } // tolua_export - - /** Set the number of ticks that this entity has existed */ - void SetAge(int a_Age) { m_Timer = (float)(a_Age * 50); } // tolua_export - /** Returns true if the pickup has already been collected */ bool IsCollected(void) const { return m_bCollected; } // tolua_export @@ -50,8 +44,7 @@ public: private: - /** The number of ticks that the entity has existed / timer between collect and destroy; in msec */ - float m_Timer; + int m_DestroyTimer; cItem m_Item; |