From 19949528a0a2d0b6e06971f532fddd0cd417e51d Mon Sep 17 00:00:00 2001 From: Mike Primm Date: Thu, 20 Aug 2020 21:42:25 -0500 Subject: [PATCH] Fix chest rendering (block state case problem) --- DynmapCore/src/main/resources/models_1.txt | 2 +- .../src/main/java/org/dynmap/renderer/DynmapBlockState.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/DynmapCore/src/main/resources/models_1.txt b/DynmapCore/src/main/resources/models_1.txt index 21bf2d52..34a18f6d 100644 --- a/DynmapCore/src/main/resources/models_1.txt +++ b/DynmapCore/src/main/resources/models_1.txt @@ -853,7 +853,7 @@ layer:3,4 --****-- # Chest - single or double # Trap Chest - single or double -customblock:id=chest,id=trapped_chest,class=org.dynmap.hdmap.renderer.ChestStateRenderer +customblock:id=chest,id=trapped_chest,class=org.dynmap.hdmap.renderer.ChestStateRenderer,doublechest=true # Cake Block block:id=cake,scale=16 diff --git a/DynmapCoreAPI/src/main/java/org/dynmap/renderer/DynmapBlockState.java b/DynmapCoreAPI/src/main/java/org/dynmap/renderer/DynmapBlockState.java index f9648417..f9f48937 100644 --- a/DynmapCoreAPI/src/main/java/org/dynmap/renderer/DynmapBlockState.java +++ b/DynmapCoreAPI/src/main/java/org/dynmap/renderer/DynmapBlockState.java @@ -133,7 +133,7 @@ public class DynmapBlockState { } base.states[stateidx] = this; } - stateList = stateName.split(","); + stateList = stateName.toLowerCase().split(","); // If base block state, add to map if (base == this) { blocksByName.put(blkname, this); @@ -232,7 +232,7 @@ public class DynmapBlockState { DynmapBlockState blk = getBaseStateByName(name); if (blk != null) { if (blk.states != null) { - String[] statelist = statename.split(","); + String[] statelist = statename.toLowerCase().split(","); for (DynmapBlockState bb : blk.states) { boolean match = true; for (int i = 0; i < statelist.length; i++) {