Add chest to forbidden block disguises
This commit is contained in:
parent
43531461f9
commit
93eef36c58
@ -14,11 +14,19 @@ public class ParamInfoItemBlock extends ParamInfoItemStack {
|
|||||||
public ParamInfoItemBlock(Class paramClass, String name, String valueType, String description,
|
public ParamInfoItemBlock(Class paramClass, String name, String valueType, String description,
|
||||||
Material[] possibleValues) {
|
Material[] possibleValues) {
|
||||||
super(paramClass, name, valueType, description, Arrays.stream(possibleValues).filter(m -> {
|
super(paramClass, name, valueType, description, Arrays.stream(possibleValues).filter(m -> {
|
||||||
if (!m.isBlock())
|
switch (m) {
|
||||||
return false;
|
case CHEST:
|
||||||
|
case TRAPPED_CHEST:
|
||||||
|
return false;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
if (NmsVersion.v1_13.isSupported())
|
if (!m.isBlock()) {
|
||||||
|
return false;
|
||||||
|
} else if (NmsVersion.v1_13.isSupported()) {
|
||||||
return true;
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
switch (m) {
|
switch (m) {
|
||||||
case CAKE:
|
case CAKE:
|
||||||
|
Loading…
Reference in New Issue
Block a user