forked from SteamWar/SteamWar
Hotfix windcharges destroying blocks
This commit is contained in:
+2
@@ -21,6 +21,7 @@ package de.steamwar.bausystem.features.world;
|
||||
|
||||
import de.steamwar.linkage.Linked;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.entity.TNTPrimed;
|
||||
import org.bukkit.event.EventHandler;
|
||||
import org.bukkit.event.EventPriority;
|
||||
import org.bukkit.event.Listener;
|
||||
@@ -31,6 +32,7 @@ public class OtherTNTListener implements Listener {
|
||||
|
||||
@EventHandler(priority = EventPriority.MONITOR)
|
||||
public void onExplosion(EntityExplodeEvent e) {
|
||||
if (!(e instanceof TNTPrimed)) return;
|
||||
e.blockList().removeIf(block -> {
|
||||
if(block.getType() == Material.TNT) {
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user