diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a3f8421f..bf9158c4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,7 +22,7 @@ jobs: strategy: matrix: - mcVersion: ['1.8.8', '1.9.4', '1.10.2', '1.11.2', '1.12.2', '1.13.2', '1.14.4', '1.15.2', '1.16.1', '1.16.4', '1.17.1', '1.18.1', '1.19', '1.20.1'] + mcVersion: ['1.8.8', '1.9.4', '1.10.2', '1.11.2', '1.12.2', '1.13.2', '1.14.4', '1.15.2', '1.16.1', '1.16.4', '1.17.1', '1.18.1', '1.19', '1.20.1', '1.21.1'] fail-fast: false steps: @@ -34,7 +34,7 @@ jobs: - name: Setup Java JDK uses: actions/setup-java@v1 with: - java-version: 17 + java-version: 21 java-package: jre - name: Install xi run: sudo apt-get install -y libxi-dev libglu1-mesa-dev diff --git a/README.md b/README.md index 7f52d92d..4fd4be96 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,7 @@ Web based viewer for servers and bots [viewer](https://prismarinejs.github.io/prismarine-viewer/) -Supports versions 1.8.8, 1.9.4, 1.10.2, 1.11.2, 1.12.2, 1.13.2, 1.14.4, 1.15.2, 1.16.1, 1.16.4, 1.17.1, 1.18.1, 1.19, 1.20.1. +Supports versions 1.8.8, 1.9.4, 1.10.2, 1.11.2, 1.12.2, 1.13.2, 1.14.4, 1.15.2, 1.16.1, 1.16.4, 1.17.1, 1.18.1, 1.19, 1.20.1, 1.21.1. ## Install diff --git a/viewer/lib/modelsBuilder.js b/viewer/lib/modelsBuilder.js index 1a6ab5cb..a7736c6b 100644 --- a/viewer/lib/modelsBuilder.js +++ b/viewer/lib/modelsBuilder.js @@ -53,6 +53,11 @@ function prepareModel (model, texturesJson) { if (face.texture.charAt(0) === '#') { face.texture = JSON.parse(JSON.stringify(model.textures[face.texture.substr(1)])) + } else if ( + !(cleanupBlockName(face.texture) in texturesJson) && + face.texture in model.textures + ) { + face.texture = JSON.parse(JSON.stringify(model.textures[face.texture])) } else { let name = face.texture name = cleanupBlockName(name) diff --git a/viewer/lib/version.js b/viewer/lib/version.js index d6808954..196930e6 100644 --- a/viewer/lib/version.js +++ b/viewer/lib/version.js @@ -1,4 +1,4 @@ -const supportedVersions = ['1.8.8', '1.9.4', '1.10.2', '1.11.2', '1.12.2', '1.13.2', '1.14.4', '1.15.2', '1.16.1', '1.16.4', '1.17.1', '1.18.1', '1.19', '1.20.1'] +const supportedVersions = ['1.8.8', '1.9.4', '1.10.2', '1.11.2', '1.12.2', '1.13.2', '1.14.4', '1.15.2', '1.16.1', '1.16.4', '1.17.1', '1.18.1', '1.19', '1.20.1', '1.21.1'] const lastOfMajor = {} for (const version of supportedVersions) {