diff options
author | bibo38 <bibo38@github.com> | 2016-01-11 17:55:32 +0100 |
---|---|---|
committer | bibo38 <bibo38@github.com> | 2016-01-11 17:55:32 +0100 |
commit | 657b0ed0070cc31e375e33ec752e4757e0c7a343 (patch) | |
tree | 1302f67bea0416a54c7d1077c84f53018acbbc11 /src/Protocol/Protocol18x.cpp | |
parent | Added "core.help" permission to Default rank. (diff) | |
download | cuberite-657b0ed0070cc31e375e33ec752e4757e0c7a343.tar cuberite-657b0ed0070cc31e375e33ec752e4757e0c7a343.tar.gz cuberite-657b0ed0070cc31e375e33ec752e4757e0c7a343.tar.bz2 cuberite-657b0ed0070cc31e375e33ec752e4757e0c7a343.tar.lz cuberite-657b0ed0070cc31e375e33ec752e4757e0c7a343.tar.xz cuberite-657b0ed0070cc31e375e33ec752e4757e0c7a343.tar.zst cuberite-657b0ed0070cc31e375e33ec752e4757e0c7a343.zip |
Diffstat (limited to 'src/Protocol/Protocol18x.cpp')
-rw-r--r-- | src/Protocol/Protocol18x.cpp | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/Protocol/Protocol18x.cpp b/src/Protocol/Protocol18x.cpp index d80e9d034..c80907ed8 100644 --- a/src/Protocol/Protocol18x.cpp +++ b/src/Protocol/Protocol18x.cpp @@ -3109,8 +3109,21 @@ void cProtocol180::WriteBlockEntity(cPacketizer & a_Pkt, const cBlockEntity & a_ Writer.AddInt("z", MobHeadEntity.GetPosZ()); Writer.AddByte("SkullType", MobHeadEntity.GetType() & 0xFF); Writer.AddByte("Rot", MobHeadEntity.GetRotation() & 0xFF); - Writer.AddString("ExtraType", MobHeadEntity.GetOwner().c_str()); Writer.AddString("id", "Skull"); // "Tile Entity ID" - MC wiki; vanilla server always seems to send this though + + // The new Block Entity format for a Mob Head. See: http://minecraft.gamepedia.com/Head#Block_entity + Writer.BeginCompound("Owner"); + Writer.AddString("Id", MobHeadEntity.GetOwnerUUID()); + Writer.AddString("Name", MobHeadEntity.GetOwnerName()); + Writer.BeginCompound("Properties"); + Writer.BeginList("textures", TAG_Compound); + Writer.BeginCompound(""); + Writer.AddString("Signature", MobHeadEntity.GetOwnerTextureSignature()); + Writer.AddString("Value", MobHeadEntity.GetOwnerTexture()); + Writer.EndCompound(); + Writer.EndList(); + Writer.EndCompound(); + Writer.EndCompound(); break; } |