From 7f5766b961a7164b77965da761d571d431f61c35 Mon Sep 17 00:00:00 2001 From: KevDaDev <65958288+KevinDaGame@users.noreply.github.com> Date: Sat, 27 May 2023 15:55:11 +0200 Subject: [PATCH] 1.16 fix for arclight --- .../github/kevindagame/voxelsniper/SpigotVoxelSniper.java | 7 ++++--- buildSrc/src/main/kotlin/voxel-core.gradle.kts | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/VoxelSniperSpigot/src/main/java/com/github/kevindagame/voxelsniper/SpigotVoxelSniper.java b/VoxelSniperSpigot/src/main/java/com/github/kevindagame/voxelsniper/SpigotVoxelSniper.java index bbfe67c0..7b015ab1 100644 --- a/VoxelSniperSpigot/src/main/java/com/github/kevindagame/voxelsniper/SpigotVoxelSniper.java +++ b/VoxelSniperSpigot/src/main/java/com/github/kevindagame/voxelsniper/SpigotVoxelSniper.java @@ -141,9 +141,10 @@ public List getOnlinePlayerNames() { @Override public IMaterial getMaterial(VoxelMaterial material) { - Material mat = Material.matchMaterial(material.getKey()); - if (mat != null) return new SpigotMaterial(mat); - return null; + Material mat = material.getNamespace().equals("minecraft") ? + Material.getMaterial(material.getKey().toUpperCase()) : + Material.getMaterial(material.getNamespace().toUpperCase() + "_" + material.getKey().toUpperCase()); // In case of arclight, which uses the syntax "_" + return mat == null ? null : new SpigotMaterial(mat); } @Override diff --git a/buildSrc/src/main/kotlin/voxel-core.gradle.kts b/buildSrc/src/main/kotlin/voxel-core.gradle.kts index d0f81ce4..8a25c16d 100644 --- a/buildSrc/src/main/kotlin/voxel-core.gradle.kts +++ b/buildSrc/src/main/kotlin/voxel-core.gradle.kts @@ -42,7 +42,7 @@ java { } group = "com.github.kevindagame" -version = "8.3.0" +version = "8.3.1" //java.sourceCompatibility = JavaVersion.VERSION_16 tasks.withType() {