mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-18 08:57:44 +01:00
Upstream has released updates that appear to apply and compile correctly Paper Changes: 9a129fa99 Add #getEligibleHumans to SkeletonHorseTrapEvent b5e23c7a6 Fix merging spawning values a932e8ad7 Turn off spigot verbose world by default 8ced89f65 Fix Delegation to vanilla chunk gen
60 lines
1.6 KiB
Diff
60 lines
1.6 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: William Blake Galbreath <Blake.Galbreath@GMail.com>
|
|
Date: Thu, 30 Jul 2020 18:15:04 -0500
|
|
Subject: [PATCH] DragonEggPlaceEvent
|
|
|
|
|
|
diff --git a/src/main/java/net/pl3x/purpur/event/block/DragonEggPlaceEvent.java b/src/main/java/net/pl3x/purpur/event/block/DragonEggPlaceEvent.java
|
|
new file mode 100644
|
|
index 000000000..bdabfd2b5
|
|
--- /dev/null
|
|
+++ b/src/main/java/net/pl3x/purpur/event/block/DragonEggPlaceEvent.java
|
|
@@ -0,0 +1,47 @@
|
|
+package net.pl3x.purpur.event.block;
|
|
+
|
|
+import org.bukkit.Location;
|
|
+import org.bukkit.event.Cancellable;
|
|
+import org.bukkit.event.Event;
|
|
+import org.bukkit.event.HandlerList;
|
|
+import org.jetbrains.annotations.NotNull;
|
|
+
|
|
+public class DragonEggPlaceEvent extends Event implements Cancellable {
|
|
+ private static final HandlerList handlers = new HandlerList();
|
|
+ private Location location;
|
|
+ private boolean cancelled;
|
|
+
|
|
+ public DragonEggPlaceEvent(@NotNull Location location) {
|
|
+ this.location = location;
|
|
+ }
|
|
+
|
|
+ @NotNull
|
|
+ public Location getLocation() {
|
|
+ return location;
|
|
+ }
|
|
+
|
|
+ public void setLocation(@NotNull Location location) {
|
|
+ this.location = location;
|
|
+ }
|
|
+
|
|
+ @Override
|
|
+ public boolean isCancelled() {
|
|
+ return cancelled;
|
|
+ }
|
|
+
|
|
+ @Override
|
|
+ public void setCancelled(boolean cancel) {
|
|
+ cancelled = cancel;
|
|
+ }
|
|
+
|
|
+ @Override
|
|
+ @NotNull
|
|
+ public HandlerList getHandlers() {
|
|
+ return handlers;
|
|
+ }
|
|
+
|
|
+ @NotNull
|
|
+ public static HandlerList getHandlerList() {
|
|
+ return handlers;
|
|
+ }
|
|
+}
|