From d7ee2245e89ce9e71f0172d5a0edf605060bcf2a Mon Sep 17 00:00:00 2001 From: Howaner Date: Sat, 30 Aug 2014 12:44:54 +0200 Subject: Added SetWalkSpeed() to cMonster. --- src/Mobs/Monster.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/Mobs/Monster.h') diff --git a/src/Mobs/Monster.h b/src/Mobs/Monster.h index cdbd26c09..6db8435e2 100644 --- a/src/Mobs/Monster.h +++ b/src/Mobs/Monster.h @@ -138,6 +138,9 @@ public: /// Sets whether the mob burns in daylight. Only evaluated at next burn-decision tick void SetBurnsInDaylight(bool a_BurnsInDaylight) { m_BurnsInDaylight = a_BurnsInDaylight; } + double GetWalkSpeed(void) const { return m_WalkSpeed; } // tolua_export + void SetWalkSpeed(double a_WalkSpeed) { m_WalkSpeed = a_WalkSpeed; } // tolua_export + // Overridables to handle ageable mobs virtual bool IsBaby (void) const { return false; } virtual bool IsTame (void) const { return false; } @@ -248,6 +251,8 @@ protected: void HandleDaylightBurning(cChunk & a_Chunk); bool m_BurnsInDaylight; + double m_WalkSpeed; + /** Adds a random number of a_Item between a_Min and a_Max to itemdrops a_Drops*/ void AddRandomDropItem(cItems & a_Drops, unsigned int a_Min, unsigned int a_Max, short a_Item, short a_ItemHealth = 0); -- cgit v1.2.3 From 38e824dbcfa66ee63670f6e8aa708e7a4aa58f5e Mon Sep 17 00:00:00 2001 From: Howaner Date: Tue, 2 Sep 2014 20:10:41 +0200 Subject: Renamed SetWalkSpeed() to SetRelativeWalkSpeed() --- src/Mobs/Monster.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/Mobs/Monster.h') diff --git a/src/Mobs/Monster.h b/src/Mobs/Monster.h index 6db8435e2..ca3c04c23 100644 --- a/src/Mobs/Monster.h +++ b/src/Mobs/Monster.h @@ -138,8 +138,8 @@ public: /// Sets whether the mob burns in daylight. Only evaluated at next burn-decision tick void SetBurnsInDaylight(bool a_BurnsInDaylight) { m_BurnsInDaylight = a_BurnsInDaylight; } - double GetWalkSpeed(void) const { return m_WalkSpeed; } // tolua_export - void SetWalkSpeed(double a_WalkSpeed) { m_WalkSpeed = a_WalkSpeed; } // tolua_export + double GetRelativeWalkSpeed(void) const { return m_RelativeWalkSpeed; } // tolua_export + void SetRelativeWalkSpeed(double a_WalkSpeed) { m_RelativeWalkSpeed = a_WalkSpeed; } // tolua_export // Overridables to handle ageable mobs virtual bool IsBaby (void) const { return false; } @@ -251,7 +251,7 @@ protected: void HandleDaylightBurning(cChunk & a_Chunk); bool m_BurnsInDaylight; - double m_WalkSpeed; + double m_RelativeWalkSpeed; /** Adds a random number of a_Item between a_Min and a_Max to itemdrops a_Drops*/ void AddRandomDropItem(cItems & a_Drops, unsigned int a_Min, unsigned int a_Max, short a_Item, short a_ItemHealth = 0); -- cgit v1.2.3