diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 17743b4..260dce4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -135,9 +135,9 @@ jobs: if-no-files-found: error retention-days: 30 path: | - build/libs/SkysGrassSlabs-1.1.0.120011.jar - build/libs/SkysGrassSlabs-1.1.0.120011-sources.jar - build/libs/SkysGrassSlabs-1.1.0.120011-javadoc.jar + build/libs/SkysGrassSlabs-1.1.1.120011.jar + build/libs/SkysGrassSlabs-1.1.1.120011-sources.jar + build/libs/SkysGrassSlabs-1.1.1.120011-javadoc.jar build/release/SHA256SUMS CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md index 3faa981..c72eaa2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## 1.1.1.120011 - Minecraft 1.20.1 + +- Corrected snowy grass slabs so their exposed top uses the snow texture + instead of remaining biome coloured green. +- Preserved the existing snowy side edges and all world data. + ## 1.1.0.120011 - Minecraft 1.20.1 - Ported the complete feature set to Minecraft 1.20.1. diff --git a/README.md b/README.md index b33090e..14f417b 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ thin layer of turf. Grass spreads naturally between full blocks and slabs, while new Overworld terrain uses grass slabs to soften suitable one block steps. -This branch is for Minecraft 1.20.1. Version `1.1.0.120011` requires Forge +This branch is for Minecraft 1.20.1. Version `1.1.1.120011` requires Forge 47.4.10 or a compatible Forge 47 build and Java 17. ## Installation @@ -34,7 +34,7 @@ or updating world changing mods. - [Gameplay and recipes](docs/GAMEPLAY.md) - [Configuration](docs/CONFIGURATION.md) - [Upgrading an older world](docs/WORLD-UPGRADES.md) -- [Release notes](docs/RELEASE-1.1.0.120011.md) +- [Release notes](docs/RELEASE-1.1.1.120011.md) ## License diff --git a/docs/RELEASE-1.1.1.120011.md b/docs/RELEASE-1.1.1.120011.md new file mode 100644 index 0000000..5481324 --- /dev/null +++ b/docs/RELEASE-1.1.1.120011.md @@ -0,0 +1,10 @@ +# Sky's Grass Slabs 1.1.1 for Minecraft 1.20.1 + +This update corrects the snowy appearance of grass slabs. When a grass slab +shows snowy side edges, its exposed top now uses the matching snow texture +instead of remaining green. + +All blocks, recipes, configuration options and world data remain compatible +with the previous Forge 1.20.1 release. + +Requires Minecraft 1.20.1, Forge 47.4.10 and Java 17. diff --git a/docs/WORLD-UPGRADES.md b/docs/WORLD-UPGRADES.md index db1f934..4a7e24e 100644 --- a/docs/WORLD-UPGRADES.md +++ b/docs/WORLD-UPGRADES.md @@ -6,7 +6,7 @@ world has been checked in game. ## Sky's Grass Slabs content -Install `SkysGrassSlabs-1.1.0.120011.jar` before opening a world that used an +Install `SkysGrassSlabs-1.1.1.120011.jar` before opening a world that used an earlier release. The permanent dirt slab, grass slab, path slab and turf IDs are unchanged. diff --git a/gradle.properties b/gradle.properties index 4236ebf..b1410c9 100644 --- a/gradle.properties +++ b/gradle.properties @@ -62,7 +62,7 @@ mod_name=Sky's Grass Slabs # The license of the mod. Review your options at https://choosealicense.com/. All Rights Reserved is the default. mod_license=LGPL-2.1-only # The mod version. See https://semver.org/ -mod_version=1.1.0.120011 +mod_version=1.1.1.120011 # The group ID for the mod. It is only important when publishing as an artifact to a Maven repository. # This should match the base package used for the mod sources. # See https://maven.apache.org/guides/mini/guide-naming-conventions.html diff --git a/src/main/java/zone/moddev/mc/skysgrassslabs/SkysGrassSlabs.java b/src/main/java/zone/moddev/mc/skysgrassslabs/SkysGrassSlabs.java index 2bf1419..08452b5 100644 --- a/src/main/java/zone/moddev/mc/skysgrassslabs/SkysGrassSlabs.java +++ b/src/main/java/zone/moddev/mc/skysgrassslabs/SkysGrassSlabs.java @@ -25,7 +25,7 @@ public final class SkysGrassSlabs { /** Stable Forge mod identifier and resource namespace. */ public static final String MOD_ID = "skysgrassslabs"; public static final String NAME = "Sky's Grass Slabs"; - public static final String VERSION = "1.1.0.120011"; + public static final String VERSION = "1.1.1.120011"; public static final Logger LOGGER = LogManager.getLogger(); /** Registers content, configuration, world generation, and persistent state. */ diff --git a/src/main/resources/assets/skysgrassslabs/models/block/grass_slab_snow.json b/src/main/resources/assets/skysgrassslabs/models/block/grass_slab_snow.json index 1d55b0c..9733047 100644 --- a/src/main/resources/assets/skysgrassslabs/models/block/grass_slab_snow.json +++ b/src/main/resources/assets/skysgrassslabs/models/block/grass_slab_snow.json @@ -1,11 +1,11 @@ { "parent": "minecraft:block/block", - "textures": { "particle": "minecraft:block/dirt", "bottom": "minecraft:block/dirt", "top": "minecraft:block/grass_block_top", "side": "minecraft:block/grass_block_snow" }, + "textures": { "particle": "minecraft:block/dirt", "bottom": "minecraft:block/dirt", "top": "minecraft:block/snow", "side": "minecraft:block/grass_block_snow" }, "elements": [{ "from": [0, 0, 0], "to": [16, 8, 16], "faces": { "down": { "uv": [0, 0, 16, 16], "texture": "#bottom", "cullface": "down" }, - "up": { "uv": [0, 0, 16, 16], "texture": "#top", "cullface": "up", "tintindex": 0 }, + "up": { "uv": [0, 0, 16, 16], "texture": "#top", "cullface": "up" }, "north": { "uv": [0, 0, 16, 8], "texture": "#side", "cullface": "north" }, "south": { "uv": [0, 0, 16, 8], "texture": "#side", "cullface": "south" }, "west": { "uv": [0, 0, 16, 8], "texture": "#side", "cullface": "west" }, diff --git a/src/main/resources/assets/skysgrassslabs/models/block/grass_slab_top_snow.json b/src/main/resources/assets/skysgrassslabs/models/block/grass_slab_top_snow.json index 496cb61..484d6e6 100644 --- a/src/main/resources/assets/skysgrassslabs/models/block/grass_slab_top_snow.json +++ b/src/main/resources/assets/skysgrassslabs/models/block/grass_slab_top_snow.json @@ -1,11 +1,11 @@ { "parent": "minecraft:block/block", - "textures": { "particle": "minecraft:block/dirt", "bottom": "minecraft:block/dirt", "top": "minecraft:block/grass_block_top", "side": "minecraft:block/grass_block_snow" }, + "textures": { "particle": "minecraft:block/dirt", "bottom": "minecraft:block/dirt", "top": "minecraft:block/snow", "side": "minecraft:block/grass_block_snow" }, "elements": [{ "from": [0, 8, 0], "to": [16, 16, 16], "faces": { "down": { "uv": [0, 0, 16, 16], "texture": "#bottom", "cullface": "down" }, - "up": { "uv": [0, 0, 16, 16], "texture": "#top", "cullface": "up", "tintindex": 0 }, + "up": { "uv": [0, 0, 16, 16], "texture": "#top", "cullface": "up" }, "north": { "uv": [0, 0, 16, 8], "texture": "#side", "cullface": "north" }, "south": { "uv": [0, 0, 16, 8], "texture": "#side", "cullface": "south" }, "west": { "uv": [0, 0, 16, 8], "texture": "#side", "cullface": "west" }, diff --git a/src/test/java/zone/moddev/mc/skysgrassslabs/ProjectContractTest.java b/src/test/java/zone/moddev/mc/skysgrassslabs/ProjectContractTest.java index ed40b65..7fedc50 100644 --- a/src/test/java/zone/moddev/mc/skysgrassslabs/ProjectContractTest.java +++ b/src/test/java/zone/moddev/mc/skysgrassslabs/ProjectContractTest.java @@ -32,14 +32,14 @@ public void playerAndMaintainerDocumentsExist() { assertTrue(Files.isRegularFile(Path.of("docs/GAMEPLAY.md"))); assertTrue(Files.isRegularFile(Path.of("docs/WORLD-UPGRADES.md"))); assertFalse(Files.exists(Path.of("docs/REPOSITORY.md"))); - assertTrue(Files.isRegularFile(Path.of("docs/RELEASE-1.1.0.120011.md"))); + assertTrue(Files.isRegularFile(Path.of("docs/RELEASE-1.1.1.120011.md"))); assertTrue(Files.isRegularFile(Path.of("docs/BETA-0.2.0.118021.md"))); } @Test public void releaseIdentityAndLicenseAreStable() throws Exception { String properties = Files.readString(Path.of("gradle.properties"), StandardCharsets.UTF_8); - assertTrue(properties.contains("mod_version=1.1.0.120011")); + assertTrue(properties.contains("mod_version=1.1.1.120011")); assertTrue(properties.contains("mod_license=LGPL-2.1-only")); assertEquals("LGPL-2.1-only", Files.readString(Path.of("LICENSE.spdx"), StandardCharsets.UTF_8).trim()); assertTrue(Files.readString(Path.of("NOTICE"), StandardCharsets.UTF_8) @@ -96,7 +96,7 @@ public void commonConfigAndWorldStateUsePermanentKeys() throws Exception { assertTrue(config.contains("push(\"compat\")")); assertTrue(config.contains("define(FORCE_REPLACE_BUILDINGBRICKS_SLABS, false)")); assertTrue(config.contains("define(FORCE_REPLACE_GRASS_SLABS_MOD_CONTENT, false)")); - assertTrue(main.contains("VERSION = \"1.1.0.120011\"")); + assertTrue(main.contains("VERSION = \"1.1.1.120011\"")); assertTrue(state.contains("skysgrassslabs_world_state")); assertTrue(state.contains("SCHEMA_VERSION = 1")); assertTrue(state.contains("schema_version")); @@ -229,9 +229,9 @@ public void continuousIntegrationTargetsTheStableBranchAndArtifacts() throws Exc } String ci = Files.readString(Path.of(".github/workflows/ci.yml"), StandardCharsets.UTF_8); - assertTrue(ci.contains("SkysGrassSlabs-1.1.0.120011.jar")); - assertTrue(ci.contains("SkysGrassSlabs-1.1.0.120011-sources.jar")); - assertTrue(ci.contains("SkysGrassSlabs-1.1.0.120011-javadoc.jar")); + assertTrue(ci.contains("SkysGrassSlabs-1.1.1.120011.jar")); + assertTrue(ci.contains("SkysGrassSlabs-1.1.1.120011-sources.jar")); + assertTrue(ci.contains("SkysGrassSlabs-1.1.1.120011-javadoc.jar")); assertTrue(ci.contains("if-no-files-found: error")); assertEquals(2, ci.lines() .filter(line -> line.contains("java-version: '8.0.502+7'")) diff --git a/src/test/java/zone/moddev/mc/skysgrassslabs/ResourceContractTest.java b/src/test/java/zone/moddev/mc/skysgrassslabs/ResourceContractTest.java index a32b1da..007abd1 100644 --- a/src/test/java/zone/moddev/mc/skysgrassslabs/ResourceContractTest.java +++ b/src/test/java/zone/moddev/mc/skysgrassslabs/ResourceContractTest.java @@ -1,6 +1,7 @@ package zone.moddev.mc.skysgrassslabs; import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; import java.io.IOException; @@ -65,6 +66,24 @@ public void turfModelIsOnePixelHighAndBiomeTinted() throws Exception { } } + @Test + public void snowyGrassSlabModelsUseUntintedSnowCaps() throws Exception { + for (String modelName : new String[] {"grass_slab_snow", "grass_slab_top_snow"}) { + JsonElement model = JsonParser.parseString(Files.readString(Path.of( + "src/main/resources/assets/skysgrassslabs/models/block/" + + modelName + ".json"))); + var object = model.getAsJsonObject(); + assertEquals("minecraft:block/snow", + object.getAsJsonObject("textures").get("top").getAsString()); + assertEquals("minecraft:block/grass_block_snow", + object.getAsJsonObject("textures").get("side").getAsString()); + var up = object.getAsJsonArray("elements").get(0).getAsJsonObject() + .getAsJsonObject("faces").getAsJsonObject("up"); + assertEquals("#top", up.get("texture").getAsString()); + assertFalse(up.has("tintindex")); + } + } + @Test public void grassSlabUsesVanillaGrassCutoutLayer() throws Exception { String client = Files.readString(Path.of(