From 7cc544d715ce5c445e70917650a094d73b85c191 Mon Sep 17 00:00:00 2001 From: Aikar Date: Tue, 19 Dec 2017 16:25:38 -0500 Subject: [PATCH] Add World#createExplosion(Location, float, boolean, boolean) API don't know why this API was missing --- ...Explosion-Location-float-boolean-boo.patch | 35 +++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 Spigot-API-Patches/Add-World-createExplosion-Location-float-boolean-boo.patch diff --git a/Spigot-API-Patches/Add-World-createExplosion-Location-float-boolean-boo.patch b/Spigot-API-Patches/Add-World-createExplosion-Location-float-boolean-boo.patch new file mode 100644 index 0000000000..eafa71f366 --- /dev/null +++ b/Spigot-API-Patches/Add-World-createExplosion-Location-float-boolean-boo.patch @@ -0,0 +1,35 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Aikar +Date: Tue, 19 Dec 2017 16:24:42 -0500 +Subject: [PATCH] Add World#createExplosion(Location, float, boolean, boolean) + API + + +diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java +index 0bc47dd6..7687f882 100644 +--- a/src/main/java/org/bukkit/World.java ++++ b/src/main/java/org/bukkit/World.java +@@ -0,0 +0,0 @@ public interface World extends PluginMessageRecipient, Metadatable { + */ + public boolean createExplosion(Location loc, float power, boolean setFire); + ++ // Paper start ++ /** ++ * Creates explosion at given coordinates with given power and optionally ++ * setting blocks on fire or breaking blocks. ++ * ++ * @param loc Location to blow up ++ * @param power The power of explosion, where 4F is TNT ++ * @param setFire Whether or not to set blocks on fire ++ * @param breakBlocks Whether or not to have blocks be destroyed ++ * @return false if explosion was canceled, otherwise true ++ */ ++ public default boolean createExplosion(Location loc, float power, boolean setFire, boolean breakBlocks) { ++ return createExplosion(loc.getX(), loc.getY(), loc.getZ(), power, setFire, breakBlocks); ++ } ++ // Paper end ++ + /** + * Gets the {@link Environment} type of this world + * +-- \ No newline at end of file