make it compile

This commit is contained in:
granny
2024-04-29 19:21:50 -07:00
parent 7a08bb73c9
commit 69403e54d0
2 changed files with 9 additions and 8 deletions

View File

@@ -6,10 +6,10 @@ Subject: [PATCH] Add PreExplodeEvents
diff --git a/src/main/java/org/purpurmc/purpur/event/PreBlockExplodeEvent.java b/src/main/java/org/purpurmc/purpur/event/PreBlockExplodeEvent.java
new file mode 100644
index 0000000000000000000000000000000000000000..32602b398ede24a35ed8a996faa2b23455615a7b
index 0000000000000000000000000000000000000000..8ea97ddceedb7c719e8a50a0dd8f3f0919ca1647
--- /dev/null
+++ b/src/main/java/org/purpurmc/purpur/event/PreBlockExplodeEvent.java
@@ -0,0 +1,54 @@
@@ -0,0 +1,53 @@
+package org.purpurmc.purpur.event;
+
+import org.bukkit.block.Block;
@@ -18,7 +18,6 @@ index 0000000000000000000000000000000000000000..32602b398ede24a35ed8a996faa2b234
+import org.bukkit.event.HandlerList;
+import org.bukkit.event.block.BlockExplodeEvent;
+import org.jetbrains.annotations.NotNull;
+import org.jetbrains.annotations.Nullable;
+import java.util.Collections;
+
+/**
@@ -29,8 +28,8 @@ index 0000000000000000000000000000000000000000..32602b398ede24a35ed8a996faa2b234
+ private boolean cancelled;
+ private final float yield;
+
+ public PreBlockExplodeEvent(@NotNull final Block what, final float yield, @Nullable BlockState explodedBlockState) {
+ super(what, Collections.emptyList(), yield, explodedBlockState);
+ public PreBlockExplodeEvent(@NotNull final Block what, final float yield, @NotNull BlockState explodedBlockState) {
+ super(what, explodedBlockState, Collections.emptyList(), yield);
+ this.yield = yield;
+ this.cancelled = false;
+ }