Dieser Commit ist enthalten in:
Ursprung
5a32b90499
Commit
d9d383679f
@ -189,13 +189,6 @@ public class Detonator {
|
||||
}
|
||||
|
||||
static Detoblock getBlock(Block block) {
|
||||
if (block.getType() == Material.STONE_BUTTON) {
|
||||
return Detoblock.STONE_BUTTON;
|
||||
}
|
||||
if (block.getType() == Material.HEAVY_WEIGHTED_PRESSURE_PLATE || block.getType() == Material.LIGHT_WEIGHTED_PRESSURE_PLATE) {
|
||||
return Detoblock.WEIGHTED_PRESSURE_PLATE;
|
||||
}
|
||||
|
||||
switch (block.getType()) {
|
||||
case LEVER:
|
||||
return Detoblock.SWITCH;
|
||||
@ -205,16 +198,19 @@ public class Detonator {
|
||||
return Detoblock.NOTEBLOCK;
|
||||
case DAYLIGHT_DETECTOR:
|
||||
return Detoblock.DAYLIGHTSENSOR;
|
||||
case HEAVY_WEIGHTED_PRESSURE_PLATE:
|
||||
case LIGHT_WEIGHTED_PRESSURE_PLATE:
|
||||
return Detoblock.WEIGHTED_PRESSURE_PLATE;
|
||||
default:
|
||||
if (block.getBlockData() instanceof Powerable) {
|
||||
if (block.getType().name().contains("STONE_BUTTON")) {
|
||||
return Detoblock.STONE_BUTTON;
|
||||
} else if (block.getType().name().contains("BUTTON")) {
|
||||
return Detoblock.WOOD_BUTTON;
|
||||
} else if (block.getType().name().contains("PRESSURE_PLATE")) {
|
||||
return Detoblock.PRESSURE_PLATE;
|
||||
} else if (block.getBlockData() instanceof Powerable) {
|
||||
return Detoblock.POWERABLE;
|
||||
} else {
|
||||
if (block.getType().name().contains("BUTTON")) {
|
||||
return Detoblock.WOOD_BUTTON;
|
||||
}
|
||||
if (block.getType().name().contains("PRESSURE_PLATE")) {
|
||||
return Detoblock.PRESSURE_PLATE;
|
||||
}
|
||||
return Detoblock.INVALID;
|
||||
}
|
||||
}
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren