summaryrefslogtreecommitdiffstats
path: root/src/Entities/Player.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/Entities/Player.h')
-rw-r--r--src/Entities/Player.h15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/Entities/Player.h b/src/Entities/Player.h
index 3dae58dc1..4b8c01dc4 100644
--- a/src/Entities/Player.h
+++ b/src/Entities/Player.h
@@ -122,7 +122,7 @@ public:
double GetEyeHeight(void) const; // tolua_export
Vector3d GetEyePosition(void) const; // tolua_export
virtual bool IsOnGround(void) const override { return m_bTouchGround; }
- inline double GetStance(void) const { return GetPosY() + 1.62; } // tolua_export // TODO: Proper stance when crouching etc.
+ inline double GetStance(void) const { return m_Stance; } // tolua_export
inline cInventory & GetInventory(void) { return m_Inventory; } // tolua_export
inline const cInventory & GetInventory(void) const { return m_Inventory; }
@@ -254,7 +254,10 @@ public:
static bool PermissionMatches(const AStringVector & a_Permission, const AStringVector & a_Template); // Exported in ManualBindings with AString params
/** Returns all the permissions that the player has assigned to them. */
- const AStringVector & GetPermissions(void) { return m_Permissions; } // Exported in ManualBindings.cpp
+ const AStringVector & GetPermissions(void) const { return m_Permissions; } // Exported in ManualBindings.cpp
+
+ /** Returns all the restrictions that the player has assigned to them. */
+ const AStringVector & GetRestrictions(void) const { return m_Restrictions; } // Exported in ManualBindings.cpp
// tolua_begin
@@ -500,10 +503,18 @@ protected:
/** All the permissions that this player has, based on their rank. */
AStringVector m_Permissions;
+ /** All the restrictions that this player has, based on their rank. */
+ AStringVector m_Restrictions;
+
/** All the permissions that this player has, based on their rank, split into individual dot-delimited parts.
This is used mainly by the HasPermission() function to optimize the lookup. */
AStringVectorVector m_SplitPermissions;
+ /** All the restrictions that this player has, based on their rank, split into individual dot-delimited parts.
+ This is used mainly by the HasPermission() function to optimize the lookup. */
+ AStringVectorVector m_SplitRestrictions;
+
+
// Message visuals:
AString m_MsgPrefix, m_MsgSuffix;
AString m_MsgNameColorCode;