summaryrefslogtreecommitdiffstats
path: root/src/WorldStorage/NBTChunkSerializer.cpp
diff options
context:
space:
mode:
author12xx12 <44411062+12xx12@users.noreply.github.com>2020-10-29 21:47:20 +0100
committerGitHub <noreply@github.com>2020-10-29 21:47:20 +0100
commit961d5eb420182add0b6cb4d92f260b885563389c (patch)
treec63fb7b3905d2ae59c539cca44845984128c27bb /src/WorldStorage/NBTChunkSerializer.cpp
parentRemove BLOCKENTITY_PROTODEF (diff)
downloadcuberite-961d5eb420182add0b6cb4d92f260b885563389c.tar
cuberite-961d5eb420182add0b6cb4d92f260b885563389c.tar.gz
cuberite-961d5eb420182add0b6cb4d92f260b885563389c.tar.bz2
cuberite-961d5eb420182add0b6cb4d92f260b885563389c.tar.lz
cuberite-961d5eb420182add0b6cb4d92f260b885563389c.tar.xz
cuberite-961d5eb420182add0b6cb4d92f260b885563389c.tar.zst
cuberite-961d5eb420182add0b6cb4d92f260b885563389c.zip
Diffstat (limited to '')
-rw-r--r--src/WorldStorage/NBTChunkSerializer.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/WorldStorage/NBTChunkSerializer.cpp b/src/WorldStorage/NBTChunkSerializer.cpp
index f78f7029f..d159f6e49 100644
--- a/src/WorldStorage/NBTChunkSerializer.cpp
+++ b/src/WorldStorage/NBTChunkSerializer.cpp
@@ -683,6 +683,16 @@ public:
{
mWriter.BeginCompound("");
AddBasicEntity(a_EnderCrystal, "EnderCrystal");
+ mWriter.AddByte("ShowBottom", a_EnderCrystal->ShowsBottom() ? 1 : 0);
+ if (a_EnderCrystal->DisplaysBeam())
+ {
+ mWriter.BeginCompound("BeamTarget");
+ const auto & BeamTarget = a_EnderCrystal->GetBeamTarget();
+ mWriter.AddInt("X", BeamTarget.x);
+ mWriter.AddInt("Y", BeamTarget.y);
+ mWriter.AddInt("Z", BeamTarget.z);
+ mWriter.EndCompound();
+ }
mWriter.EndCompound();
}