mirror of
https://github.com/songoda/SongodaCore.git
synced 2024-11-27 12:35:12 +01:00
Fixed an issue with specific versions.
This commit is contained in:
parent
0fd9a8c11f
commit
7e4e50fe1b
@ -1574,7 +1574,7 @@ public enum CompatibleMaterial {
|
||||
public void applyToBlock(Block block) {
|
||||
if (block == null) return;
|
||||
block.setType(material);
|
||||
if (data != -1 && ServerVersion.isServerVersionAtOrBelow(ServerVersion.V1_12)) {
|
||||
if (data != null && data != -1 && ServerVersion.isServerVersionAtOrBelow(ServerVersion.V1_12)) {
|
||||
try {
|
||||
methodSetData.invoke(block, data);
|
||||
} catch (IllegalAccessException | InvocationTargetException e) {
|
||||
|
Loading…
Reference in New Issue
Block a user