diff --git a/CHANGELOG.md b/CHANGELOG.md index 00f3902d6..212b14650 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -42,7 +42,7 @@ Unless otherwise specified, any version comparison below is the comparison of se - Plugins are able to create their own world generator implementation now. In previous versions a ClassCastException would be thrown when initializing the dimension. - Explosion now calculates entity exposure correctly. In previous version any non-air block will block the explosion ray. -- Explosion damage now scales with game difficulty, and a bug was fixed that cause the damage two times bigger than the correct damage. +- Explosion damage now scales with game difficulty. - Fixed a rare NPE exception that may occur if player disconnect when joining the server. ### Removed diff --git a/api/src/main/java/org/allaymc/api/world/Explosion.java b/api/src/main/java/org/allaymc/api/world/Explosion.java index 297938ac6..97c78a575 100644 --- a/api/src/main/java/org/allaymc/api/world/Explosion.java +++ b/api/src/main/java/org/allaymc/api/world/Explosion.java @@ -222,8 +222,7 @@ public void explode(Dimension dimension, float x, float y, float z) { case NORMAL -> 7.0f; case HARD -> 10.5f; }; - var power = size / 2.0f; - var damage = (float) Math.floor((impact * impact + impact) * m * power + 1.0f); + var damage = (impact * impact + impact) * m * size / 2.0f + 1.0f; if (entity == null) { damageComponent.attack(DamageContainer.blockExplosion(damage)); } else {