From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Ben Kerllenevich Date: Thu, 29 Apr 2021 14:39:07 -0400 Subject: [PATCH] Config for wither explosion radius diff --git a/src/main/java/net/minecraft/world/entity/projectile/EntityWitherSkull.java b/src/main/java/net/minecraft/world/entity/projectile/EntityWitherSkull.java index 616b5267d1d94b2be37ec48983b45e4478502fb5..052cffb156e4e6f31df3935fd8312eb37e3b7019 100644 --- a/src/main/java/net/minecraft/world/entity/projectile/EntityWitherSkull.java +++ b/src/main/java/net/minecraft/world/entity/projectile/EntityWitherSkull.java @@ -98,7 +98,7 @@ public class EntityWitherSkull extends EntityFireball { // CraftBukkit start // this.world.createExplosion(this, this.locX(), this.locY(), this.locZ(), 1.0F, false, explosion_effect); - ExplosionPrimeEvent event = new ExplosionPrimeEvent(this.getBukkitEntity(), 1.0F, false); + ExplosionPrimeEvent event = new ExplosionPrimeEvent(this.getBukkitEntity(), world.purpurConfig.witherExplosionRadius, false); // Purpur this.world.getServer().getPluginManager().callEvent(event); if (!event.isCancelled()) { diff --git a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java index 78e39c9424c296bf07f89d63ce42b02b96c2cd35..69d6ced8e583a3a0625ced9d444caca21fa80723 100644 --- a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java +++ b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java @@ -1901,6 +1901,7 @@ public class PurpurWorldConfig { public int witherHealthRegenDelay = 20; public double witherMaxHealth = 300.0D; public boolean witherCanRideVehicles = false; + public float witherExplosionRadius = 1.0F; private void witherSettings() { witherRidable = getBoolean("mobs.wither.ridable", witherRidable); witherRidableInWater = getBoolean("mobs.wither.ridable-in-water", witherRidableInWater); @@ -1919,6 +1920,7 @@ public class PurpurWorldConfig { } witherMaxHealth = getDouble("mobs.wither.attributes.max_health", witherMaxHealth); witherCanRideVehicles = getBoolean("mobs.wither.can-ride-vehicles", witherCanRideVehicles); + witherExplosionRadius = (float) getDouble("mobs.wither.explosion-radius", witherExplosionRadius); } public boolean witherSkeletonRidable = false;