summaryrefslogtreecommitdiffstats
path: root/src/ClientHandle.h
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2014-07-16 01:03:47 +0200
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2014-07-16 01:03:47 +0200
commit1f6854792cdd6792b27c4f9f3d7d857df9dd64bf (patch)
tree4a45fccb4c6dbf7794d8f5e9d4b0bd5c68a0ec0a /src/ClientHandle.h
parentPlayer properties are now retrieved (diff)
downloadcuberite-1f6854792cdd6792b27c4f9f3d7d857df9dd64bf.tar
cuberite-1f6854792cdd6792b27c4f9f3d7d857df9dd64bf.tar.gz
cuberite-1f6854792cdd6792b27c4f9f3d7d857df9dd64bf.tar.bz2
cuberite-1f6854792cdd6792b27c4f9f3d7d857df9dd64bf.tar.lz
cuberite-1f6854792cdd6792b27c4f9f3d7d857df9dd64bf.tar.xz
cuberite-1f6854792cdd6792b27c4f9f3d7d857df9dd64bf.tar.zst
cuberite-1f6854792cdd6792b27c4f9f3d7d857df9dd64bf.zip
Diffstat (limited to 'src/ClientHandle.h')
-rw-r--r--src/ClientHandle.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/ClientHandle.h b/src/ClientHandle.h
index 478da5b3c..7bd286a05 100644
--- a/src/ClientHandle.h
+++ b/src/ClientHandle.h
@@ -20,6 +20,7 @@
#include "Map.h"
#include "Enchantments.h"
#include "UI/SlotArea.h"
+#include "json/json.h"
@@ -68,7 +69,7 @@ public:
const AString & GetUUID(void) const { return m_UUID; } // tolua_export
void SetUUID(const AString & a_UUID) { m_UUID = a_UUID; }
- const AString & GetProperties(void) const { return m_Properties; }
+ const Json::Value & GetProperties(void) const { return m_Properties; }
/** Generates an UUID based on the username stored for this client, and stores it in the m_UUID member.
This is used for the offline (non-auth) mode, when there's no UUID source.
@@ -93,8 +94,10 @@ public:
static AString FormatChatPrefix(bool ShouldAppendChatPrefixes, AString a_ChatPrefixS, AString m_Color1, AString m_Color2);
- void Kick(const AString & a_Reason); // tolua_export
- void Authenticate(const AString & a_Name, const AString & a_UUID, const AString & a_Properties); // Called by cAuthenticator when the user passes authentication
+ void Kick(const AString & a_Reason); // tolua_export
+
+ /** Authenticates the specified user, called by cAuthenticator */
+ void Authenticate(const AString & a_Name, const AString & a_UUID, const Json::Value & a_Properties);
void StreamChunks(void);
@@ -282,7 +285,7 @@ private:
AString m_Username;
AString m_Password;
- AString m_Properties;
+ Json::Value m_Properties;
cCriticalSection m_CSChunkLists;
cChunkCoordsList m_LoadedChunks; // Chunks that the player belongs to