Fix TNTListener not igniting other tnt
Dieser Commit ist enthalten in:
Ursprung
b63c388523
Commit
bb64d0021e
@ -8,7 +8,7 @@ import de.steamwar.bausystem.region.flags.Flag;
|
||||
import de.steamwar.bausystem.region.flags.flagvalues.TNTMode;
|
||||
import de.steamwar.bausystem.region.utils.RegionExtensionType;
|
||||
import de.steamwar.bausystem.region.utils.RegionType;
|
||||
import org.bukkit.block.data.type.TNT;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.event.EventHandler;
|
||||
import org.bukkit.event.Listener;
|
||||
import org.bukkit.event.entity.EntityExplodeEvent;
|
||||
@ -19,6 +19,9 @@ public class TNTListener implements Listener {
|
||||
@EventHandler
|
||||
public void onExplode(EntityExplodeEvent event) {
|
||||
event.blockList().removeIf(block -> {
|
||||
if (block.getType() == Material.TNT) {
|
||||
return false;
|
||||
}
|
||||
Region region = Region.getRegion(block.getLocation());
|
||||
TNTMode value = region.getPlain(Flag.TNT);
|
||||
if (value == TNTMode.ALLOW) {
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren