mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-04 10:11:29 +01:00
45 lines
1.5 KiB
Diff
45 lines
1.5 KiB
Diff
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||
|
From: Nik Gil <nikmanG@users.noreply.github.com>
|
||
|
Date: Mon, 1 Feb 2016 23:36:31 -0700
|
||
|
Subject: [PATCH] Made EntityDismountEvent Cancellable
|
||
|
|
||
|
|
||
|
diff --git a/src/main/java/org/spigotmc/event/entity/EntityDismountEvent.java b/src/main/java/org/spigotmc/event/entity/EntityDismountEvent.java
|
||
|
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||
|
--- a/src/main/java/org/spigotmc/event/entity/EntityDismountEvent.java
|
||
|
+++ b/src/main/java/org/spigotmc/event/entity/EntityDismountEvent.java
|
||
|
@@ -0,0 +0,0 @@ import org.bukkit.entity.Entity;
|
||
|
import org.bukkit.event.HandlerList;
|
||
|
import org.bukkit.event.entity.EntityEvent;
|
||
|
|
||
|
+// PaperSpigot start
|
||
|
+import org.bukkit.event.Cancellable;
|
||
|
+// PaperSpigot end
|
||
|
+
|
||
|
/**
|
||
|
* Called when an entity stops riding another entity.
|
||
|
*
|
||
|
*/
|
||
|
-public class EntityDismountEvent extends EntityEvent
|
||
|
+public class EntityDismountEvent extends EntityEvent implements Cancellable // PaperSpigot - implement Cancellable
|
||
|
{
|
||
|
|
||
|
private static final HandlerList handlers = new HandlerList();
|
||
|
@@ -0,0 +0,0 @@ public class EntityDismountEvent extends EntityEvent
|
||
|
{
|
||
|
return handlers;
|
||
|
}
|
||
|
+
|
||
|
+ // PaperSpigot start - implement Cancellable methods
|
||
|
+ @Override
|
||
|
+ public boolean isCancelled() {
|
||
|
+ return cancelled;
|
||
|
+ }
|
||
|
+
|
||
|
+ @Override
|
||
|
+ public void setCancelled(boolean cancelled) {
|
||
|
+ this.cancelled = cancelled;
|
||
|
+ }
|
||
|
+ // PaperSpigot end
|
||
|
}
|
||
|
--
|