summaryrefslogtreecommitdiffstats
path: root/src/Protocol
diff options
context:
space:
mode:
authorHowaner <franzi.moos@googlemail.com>2014-08-03 22:15:26 +0200
committerHowaner <franzi.moos@googlemail.com>2014-08-03 22:15:26 +0200
commit977a9948b9ed52d0dd8c4695ecfca981b06bb212 (patch)
tree22b0b7d1ae3f9965da7478f312886cdc5beb2a9b /src/Protocol
parentWolf uses UUID for owner. (diff)
downloadcuberite-977a9948b9ed52d0dd8c4695ecfca981b06bb212.tar
cuberite-977a9948b9ed52d0dd8c4695ecfca981b06bb212.tar.gz
cuberite-977a9948b9ed52d0dd8c4695ecfca981b06bb212.tar.bz2
cuberite-977a9948b9ed52d0dd8c4695ecfca981b06bb212.tar.lz
cuberite-977a9948b9ed52d0dd8c4695ecfca981b06bb212.tar.xz
cuberite-977a9948b9ed52d0dd8c4695ecfca981b06bb212.tar.zst
cuberite-977a9948b9ed52d0dd8c4695ecfca981b06bb212.zip
Diffstat (limited to '')
-rw-r--r--src/Protocol/Protocol17x.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/Protocol/Protocol17x.cpp b/src/Protocol/Protocol17x.cpp
index f419c01a7..d6f4b96dc 100644
--- a/src/Protocol/Protocol17x.cpp
+++ b/src/Protocol/Protocol17x.cpp
@@ -3032,15 +3032,14 @@ void cProtocol176::SendPlayerSpawn(const cPlayer & a_Player)
Pkt.WriteString(cMojangAPI::MakeUUIDDashed(a_Player.GetClientHandle()->GetUUID()));
Pkt.WriteString(a_Player.GetName());
- const Json::Value & Properties = m_Client->GetProperties();
- const Json::Value::const_iterator End = Properties.end();
+ const Json::Value & Properties = a_Player.GetClientHandle()->GetProperties();
Pkt.WriteVarInt(Properties.size());
- for (Json::Value::iterator itr = Properties.begin(); itr != End; ++itr)
+ for (Json::Value::iterator itr = Properties.begin(); itr != Properties.end(); ++itr)
{
- Pkt.WriteString(((Json::Value)*itr).get("name", "").toStyledString());
- Pkt.WriteString(((Json::Value)*itr).get("value", "").toStyledString());
- Pkt.WriteString(((Json::Value)*itr).get("signature", "").toStyledString());
+ Pkt.WriteString(((Json::Value)*itr).get("name", "").asString());
+ Pkt.WriteString(((Json::Value)*itr).get("value", "").asString());
+ Pkt.WriteString(((Json::Value)*itr).get("signature", "").asString());
}
Pkt.WriteFPInt(a_Player.GetPosX());