summaryrefslogtreecommitdiffstats
path: root/src/Entities/Player.h
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2015-07-21 22:25:37 +0200
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2015-08-20 17:26:42 +0200
commitde2cce9b79ab60427daa86dcd1da99db7d7ea161 (patch)
treed50a88d41bf43f0d46481782d50ab8623d287471 /src/Entities/Player.h
parentMerge pull request #2391 from SamJBarney/CropGrowthFix (diff)
downloadcuberite-de2cce9b79ab60427daa86dcd1da99db7d7ea161.tar
cuberite-de2cce9b79ab60427daa86dcd1da99db7d7ea161.tar.gz
cuberite-de2cce9b79ab60427daa86dcd1da99db7d7ea161.tar.bz2
cuberite-de2cce9b79ab60427daa86dcd1da99db7d7ea161.tar.lz
cuberite-de2cce9b79ab60427daa86dcd1da99db7d7ea161.tar.xz
cuberite-de2cce9b79ab60427daa86dcd1da99db7d7ea161.tar.zst
cuberite-de2cce9b79ab60427daa86dcd1da99db7d7ea161.zip
Diffstat (limited to '')
-rw-r--r--src/Entities/Player.h15
1 files changed, 4 insertions, 11 deletions
diff --git a/src/Entities/Player.h b/src/Entities/Player.h
index 0fee6ef8a..8656f7336 100644
--- a/src/Entities/Player.h
+++ b/src/Entities/Player.h
@@ -117,8 +117,8 @@ public:
/** Returns true if the player is currently charging the bow */
bool IsChargingBow(void) const { return m_IsChargingBow; }
- void SetTouchGround( bool a_bTouchGround);
- inline void SetStance( const double a_Stance) { m_Stance = a_Stance; }
+ void SetTouchGround(bool a_bTouchGround);
+ inline void SetStance(const double a_Stance) { m_Stance = a_Stance; }
double GetEyeHeight(void) const; // tolua_export
Vector3d GetEyePosition(void) const; // tolua_export
virtual bool IsOnGround(void) const override { return m_bTouchGround; }
@@ -208,9 +208,6 @@ public:
@deprecated Use SetSpeed instead. */
void ForceSetSpeed(const Vector3d & a_Speed); // tolua_export
- /** Tries to move to a new position, with attachment-related checks (y == -999) */
- void MoveTo(const Vector3d & a_NewPos); // tolua_export
-
cWindow * GetWindow(void) { return m_CurrentWindow; } // tolua_export
const cWindow * GetWindow(void) const { return m_CurrentWindow; }
@@ -454,7 +451,7 @@ public:
// tolua_end
/** Update movement-related statistics. */
- void UpdateMovementStats(const Vector3d & a_DeltaPos);
+ void UpdateMovementStats(const Vector3d & a_DeltaPos, bool a_PreviousIsOnGround);
// tolua_begin
@@ -553,8 +550,7 @@ protected:
/** A "buffer" which adds up hunger before it is substracted from m_FoodSaturationLevel or m_FoodLevel. Each action adds a little */
double m_FoodExhaustionLevel;
- float m_LastJumpHeight;
- float m_LastGroundHeight;
+ double m_LastGroundHeight;
bool m_bTouchGround;
double m_Stance;
@@ -667,9 +663,6 @@ protected:
/** Tosses a list of items. */
void TossItems(const cItems & a_Items);
- /** Adds food exhaustion based on the difference between Pos and LastPos, sprinting status and swimming (in water block) */
- void ApplyFoodExhaustionFromMovement();
-
/** Returns the filename for the player data based on the UUID given.
This can be used both for online and offline UUIDs. */
AString GetUUIDFileName(const AString & a_UUID);