diff options
author | Riley Park <[email protected]> | 2024-05-15 17:06:59 -0700 |
---|---|---|
committer | GitHub <[email protected]> | 2024-05-15 17:06:59 -0700 |
commit | f17519338bc589c045e0b32bfc37e048b23544d5 (patch) | |
tree | e50182ec698b4a9de8f366f485ee089b1901bbd9 /patches/server/0405-Add-moon-phase-API.patch | |
parent | 3fc93581bb876e8149b2ca423375a98f5ca12d27 (diff) | |
download | Paper-f17519338bc589c045e0b32bfc37e048b23544d5.tar.gz Paper-f17519338bc589c045e0b32bfc37e048b23544d5.zip |
Expose server build information (#10729)
* Expose server build information
* squash patches
* final tweaks
---------
Co-authored-by: Jake Potrebic <[email protected]>
Co-authored-by: masmc05 <[email protected]>
Diffstat (limited to 'patches/server/0405-Add-moon-phase-API.patch')
-rw-r--r-- | patches/server/0405-Add-moon-phase-API.patch | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/patches/server/0405-Add-moon-phase-API.patch b/patches/server/0405-Add-moon-phase-API.patch new file mode 100644 index 0000000000..bcc15c76d0 --- /dev/null +++ b/patches/server/0405-Add-moon-phase-API.patch @@ -0,0 +1,22 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: BillyGalbreath <[email protected]> +Date: Sun, 23 Aug 2020 16:32:11 +0200 +Subject: [PATCH] Add moon phase API + + +diff --git a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +index 089b8351168d7b4f55e75b3cfd4c2b72e829bd1c..9801f78f1d44fd5a72fbdb319681b683e8fb85c4 100644 +--- a/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java ++++ b/src/main/java/org/bukkit/craftbukkit/CraftRegionAccessor.java +@@ -505,4 +505,11 @@ public abstract class CraftRegionAccessor implements RegionAccessor { + + throw new IllegalArgumentException("Cannot spawn an entity for " + clazz.getName()); + } ++ ++ // Paper start ++ @Override ++ public io.papermc.paper.world.MoonPhase getMoonPhase() { ++ return io.papermc.paper.world.MoonPhase.getPhase(this.getHandle().dayTime() / 24000L); ++ } ++ // Paper end + } |