diff options
author | Howaner <franzi.moos@googlemail.com> | 2014-09-01 20:12:56 +0200 |
---|---|---|
committer | Howaner <franzi.moos@googlemail.com> | 2014-09-01 20:12:56 +0200 |
commit | 7c4cb9a3852e33d8bcc5f8283485e833c6eab93e (patch) | |
tree | a9f183b2ec527016f49da587e54641156db2a007 /src/Protocol/Protocol17x.cpp | |
parent | Fixed Bindings regeneration under MSVC. (diff) | |
download | cuberite-7c4cb9a3852e33d8bcc5f8283485e833c6eab93e.tar cuberite-7c4cb9a3852e33d8bcc5f8283485e833c6eab93e.tar.gz cuberite-7c4cb9a3852e33d8bcc5f8283485e833c6eab93e.tar.bz2 cuberite-7c4cb9a3852e33d8bcc5f8283485e833c6eab93e.tar.lz cuberite-7c4cb9a3852e33d8bcc5f8283485e833c6eab93e.tar.xz cuberite-7c4cb9a3852e33d8bcc5f8283485e833c6eab93e.tar.zst cuberite-7c4cb9a3852e33d8bcc5f8283485e833c6eab93e.zip |
Diffstat (limited to 'src/Protocol/Protocol17x.cpp')
-rw-r--r-- | src/Protocol/Protocol17x.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/Protocol/Protocol17x.cpp b/src/Protocol/Protocol17x.cpp index 1091b877f..ed9812377 100644 --- a/src/Protocol/Protocol17x.cpp +++ b/src/Protocol/Protocol17x.cpp @@ -1,3 +1,4 @@ + // Protocol17x.cpp /* @@ -3021,6 +3022,15 @@ void cProtocol172::cPacketizer::WriteMobMetadata(const cMonster & a_Mob) break; } } // switch (a_Mob.GetType()) + + // Custom name: + if (a_Mob.HasCustomName()) + { + WriteByte(0x8a); + WriteString(a_Mob.GetCustomName()); + WriteByte(0x0b); + WriteByte(a_Mob.IsCustomNameAlwaysVisible() ? 1 : 0); + } } |