summaryrefslogtreecommitdiffstats
path: root/src/WorldStorage/NBTChunkSerializer.cpp
diff options
context:
space:
mode:
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();
}