From d4f5558b962b849f2e8ac0084e4427b9934cd632 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ales=CC=8C=20Fabia=CC=81nek?= Date: Sat, 11 Jun 2022 17:02:31 +0200 Subject: [PATCH] Fixed mob spawns --- .github/versions.json | 4 +- .github/workflows/publish-with-quilt.yml | 42 +++++++++---------- .github/workflows/publish.yml | 28 ++++++------- CHANGELOG.md | 4 ++ .../friendsandfoes/FriendsAndFoes.java | 2 +- .../friendsandfoes/init/ModEntityTypes.java | 18 ++++---- gradle.properties | 2 +- 7 files changed, 52 insertions(+), 48 deletions(-) diff --git a/.github/versions.json b/.github/versions.json index a421f4efd..564bfadf3 100644 --- a/.github/versions.json +++ b/.github/versions.json @@ -1,6 +1,6 @@ { - "1.19": "1.5.0", - "1.19-rc1": "1.5.0", + "1.19": "1.5.1", + "1.19-rc1": "1.5.1", "1.18.2": "1.4.3", "1.18.1": "1.2.5", "1.18": "1.2.5" diff --git a/.github/workflows/publish-with-quilt.yml b/.github/workflows/publish-with-quilt.yml index be1c7d2ba..4a96558f2 100644 --- a/.github/workflows/publish-with-quilt.yml +++ b/.github/workflows/publish-with-quilt.yml @@ -45,9 +45,9 @@ jobs: with: name: "friends-and-foes" path: | - fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.0.jar - forge/build/libs/friendsandfoes-forge-mc1.19-1.5.0.jar - quilt/build/libs/friendsandfoes-quilt-mc1.19-1.5.0.jar + fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.1.jar + forge/build/libs/friendsandfoes-forge-mc1.19-1.5.1.jar + quilt/build/libs/friendsandfoes-quilt-mc1.19-1.5.1.jar LICENSE.txt publish-license-to-release: @@ -83,7 +83,7 @@ jobs: - name: "Publish Fabric to GitHub" uses: AButler/upload-release-assets@v2.0 with: - files: 'fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.0.jar' + files: 'fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.1.jar' repo-token: ${{ secrets.GITHUB_TOKEN }} publish-fabric-to-curseforge: @@ -104,11 +104,11 @@ jobs: curseforge-id: 551364 curseforge-token: ${{ secrets.CURSEFORGE_RELEASE_TOKEN }} - files-primary: "fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.0.jar" + files-primary: "fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.1.jar" version-type: ${{ env.VERSION_TYPE }} loaders: fabric game-versions: 1.19 - name: "Friends&Foes mc1.19-1.5.0 (Fabric)" + name: "Friends&Foes mc1.19-1.5.1 (Fabric)" dependencies: ${{ env.FABRIC_DEPENDENCIES }} java: ${{ env.JAVA_VERSIONS }} @@ -134,12 +134,12 @@ jobs: modrinth-id: POQ2i9zu modrinth-token: ${{ secrets.MODRINTH_RELEASE_TOKEN }} - files-primary: "fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.0.jar" + files-primary: "fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.1.jar" version-type: ${{ env.VERSION_TYPE }} loaders: fabric game-versions: 1.19 - name: "Friends&Foes mc1.19-1.5.0 (Fabric)" - version: "fabric-mc1.19-1.5.0" + name: "Friends&Foes mc1.19-1.5.1 (Fabric)" + version: "fabric-mc1.19-1.5.1" dependencies: ${{ env.FABRIC_DEPENDENCIES }} java: ${{ env.JAVA_VERSIONS }} retry-attempts: ${{ env.RETRY_ATTEMPTS }} @@ -161,7 +161,7 @@ jobs: - name: "Publish Forge to GitHub" uses: AButler/upload-release-assets@v2.0 with: - files: 'forge/build/libs/friendsandfoes-forge-mc1.19-1.5.0.jar' + files: 'forge/build/libs/friendsandfoes-forge-mc1.19-1.5.1.jar' repo-token: ${{ secrets.GITHUB_TOKEN }} publish-forge-to-curseforge: @@ -182,11 +182,11 @@ jobs: curseforge-id: 602059 curseforge-token: ${{ secrets.CURSEFORGE_RELEASE_TOKEN }} - files-primary: "forge/build/libs/friendsandfoes-forge-mc1.19-1.5.0.jar" + files-primary: "forge/build/libs/friendsandfoes-forge-mc1.19-1.5.1.jar" version-type: ${{ env.VERSION_TYPE }} loaders: forge game-versions: 1.19 - name: "Friends&Foes mc1.19-1.5.0 (Forge)" + name: "Friends&Foes mc1.19-1.5.1 (Forge)" dependencies: ${{ env.FORGE_DEPENDENCIES }} java: ${{ env.JAVA_VERSIONS }} @@ -212,12 +212,12 @@ jobs: modrinth-id: BOCJKD49 modrinth-token: ${{ secrets.MODRINTH_RELEASE_TOKEN }} - files-primary: "forge/build/libs/friendsandfoes-forge-mc1.19-1.5.0.jar" + files-primary: "forge/build/libs/friendsandfoes-forge-mc1.19-1.5.1.jar" version-type: ${{ env.VERSION_TYPE }} loaders: forge game-versions: 1.19 - name: "Friends&Foes mc1.19-1.5.0 (Forge)" - version: "forge-mc1.19-1.5.0" + name: "Friends&Foes mc1.19-1.5.1 (Forge)" + version: "forge-mc1.19-1.5.1" dependencies: ${{ env.FORGE_DEPENDENCIES }} java: ${{ env.JAVA_VERSIONS }} retry-attempts: ${{ env.RETRY_ATTEMPTS }} @@ -240,7 +240,7 @@ jobs: - name: "Publish Quilt to GitHub" uses: AButler/upload-release-assets@v2.0 with: - files: 'quilt/build/libs/friendsandfoes-quilt-mc1.19-1.5.0.jar' + files: 'quilt/build/libs/friendsandfoes-quilt-mc1.19-1.5.1.jar' repo-token: ${{ secrets.GITHUB_TOKEN }} publish-quilt-to-curseforge: @@ -261,11 +261,11 @@ jobs: curseforge-id: 628248 curseforge-token: ${{ secrets.CURSEFORGE_RELEASE_TOKEN }} - files-primary: "quilt/build/libs/friendsandfoes-quilt-mc1.19-1.5.0.jar" + files-primary: "quilt/build/libs/friendsandfoes-quilt-mc1.19-1.5.1.jar" version-type: ${{ env.VERSION_TYPE }} loaders: quilt game-versions: 1.19 - name: "Friends&Foes mc1.19-1.5.0 (Quilt)" + name: "Friends&Foes mc1.19-1.5.1 (Quilt)" dependencies: ${{ env.QUILT_DEPENDENCIES }} java: ${{ env.JAVA_VERSIONS }} @@ -291,12 +291,12 @@ jobs: modrinth-id: NxP9xmhw modrinth-token: ${{ secrets.MODRINTH_RELEASE_TOKEN }} - files-primary: "quilt/build/libs/friendsandfoes-quilt-mc1.19-1.5.0.jar" + files-primary: "quilt/build/libs/friendsandfoes-quilt-mc1.19-1.5.1.jar" version-type: ${{ env.VERSION_TYPE }} loaders: quilt game-versions: 1.19 - name: "Friends&Foes mc1.19-1.5.0 (Quilt)" - version: "quilt-mc1.19-1.5.0" + name: "Friends&Foes mc1.19-1.5.1 (Quilt)" + version: "quilt-mc1.19-1.5.1" dependencies: ${{ env.QUILT_DEPENDENCIES }} java: ${{ env.JAVA_VERSIONS }} retry-attempts: ${{ env.RETRY_ATTEMPTS }} diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index b7830c899..5378a8d5a 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -46,8 +46,8 @@ jobs: with: name: "friends-and-foes" path: | - fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.0.jar - forge/build/libs/friendsandfoes-forge-mc1.19-1.5.0.jar + fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.1.jar + forge/build/libs/friendsandfoes-forge-mc1.19-1.5.1.jar LICENSE.txt publish-license-to-release: @@ -83,7 +83,7 @@ jobs: - name: "Publish Fabric to GitHub" uses: AButler/upload-release-assets@v2.0 with: - files: 'fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.0.jar' + files: 'fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.1.jar' repo-token: ${{ secrets.GITHUB_TOKEN }} publish-fabric-to-curseforge: @@ -104,11 +104,11 @@ jobs: curseforge-id: 551364 curseforge-token: ${{ secrets.CURSEFORGE_RELEASE_TOKEN }} - files-primary: "fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.0.jar" + files-primary: "fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.1.jar" version-type: ${{ env.VERSION_TYPE }} loaders: fabric game-versions: 1.19 - name: "Friends&Foes mc1.19-1.5.0 (Fabric)" + name: "Friends&Foes mc1.19-1.5.1 (Fabric)" dependencies: ${{ env.FABRIC_DEPENDENCIES }} java: ${{ env.JAVA_VERSIONS }} @@ -134,12 +134,12 @@ jobs: modrinth-id: POQ2i9zu modrinth-token: ${{ secrets.MODRINTH_RELEASE_TOKEN }} - files-primary: "fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.0.jar" + files-primary: "fabric/build/libs/friendsandfoes-fabric-mc1.19-1.5.1.jar" version-type: ${{ env.VERSION_TYPE }} loaders: fabric game-versions: 1.19 - name: "Friends&Foes mc1.19-1.5.0 (Fabric)" - version: "fabric-mc1.19-1.5.0" + name: "Friends&Foes mc1.19-1.5.1 (Fabric)" + version: "fabric-mc1.19-1.5.1" dependencies: ${{ env.FABRIC_DEPENDENCIES }} java: ${{ env.JAVA_VERSIONS }} retry-attempts: ${{ env.RETRY_ATTEMPTS }} @@ -161,7 +161,7 @@ jobs: - name: "Publish Forge to GitHub" uses: AButler/upload-release-assets@v2.0 with: - files: 'forge/build/libs/friendsandfoes-forge-mc1.19-1.5.0.jar' + files: 'forge/build/libs/friendsandfoes-forge-mc1.19-1.5.1.jar' repo-token: ${{ secrets.GITHUB_TOKEN }} publish-forge-to-curseforge: @@ -182,11 +182,11 @@ jobs: curseforge-id: 602059 curseforge-token: ${{ secrets.CURSEFORGE_RELEASE_TOKEN }} - files-primary: "forge/build/libs/friendsandfoes-forge-mc1.19-1.5.0.jar" + files-primary: "forge/build/libs/friendsandfoes-forge-mc1.19-1.5.1.jar" version-type: ${{ env.VERSION_TYPE }} loaders: forge game-versions: 1.19 - name: "Friends&Foes mc1.19-1.5.0 (Forge)" + name: "Friends&Foes mc1.19-1.5.1 (Forge)" dependencies: ${{ env.FORGE_DEPENDENCIES }} java: ${{ env.JAVA_VERSIONS }} @@ -212,12 +212,12 @@ jobs: modrinth-id: BOCJKD49 modrinth-token: ${{ secrets.MODRINTH_RELEASE_TOKEN }} - files-primary: "forge/build/libs/friendsandfoes-forge-mc1.19-1.5.0.jar" + files-primary: "forge/build/libs/friendsandfoes-forge-mc1.19-1.5.1.jar" version-type: ${{ env.VERSION_TYPE }} loaders: forge game-versions: 1.19 - name: "Friends&Foes mc1.19-1.5.0 (Forge)" - version: "forge-mc1.19-1.5.0" + name: "Friends&Foes mc1.19-1.5.1 (Forge)" + version: "forge-mc1.19-1.5.1" dependencies: ${{ env.FORGE_DEPENDENCIES }} java: ${{ env.JAVA_VERSIONS }} retry-attempts: ${{ env.RETRY_ATTEMPTS }} diff --git a/CHANGELOG.md b/CHANGELOG.md index ccbf81a50..1b7a94c6f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## mc1.19-1.5.1, June 11, 2022 + +- Fixed natural mob spawning + ## mc1.19-1.5.0, June 11, 2022 - Ported to 1.19 diff --git a/common/src/main/java/com/faboslav/friendsandfoes/FriendsAndFoes.java b/common/src/main/java/com/faboslav/friendsandfoes/FriendsAndFoes.java index a62a10063..5eeb69376 100644 --- a/common/src/main/java/com/faboslav/friendsandfoes/FriendsAndFoes.java +++ b/common/src/main/java/com/faboslav/friendsandfoes/FriendsAndFoes.java @@ -16,7 +16,7 @@ public final class FriendsAndFoes private static final FriendsAndFoesConfig CONFIG = OmegaConfig.register(FriendsAndFoesConfig.class); private static final Logger LOGGER = LoggerFactory.getLogger(FriendsAndFoes.MOD_ID); public static final String MOD_ID = "friendsandfoes"; - public static final String MOD_VERSION = "1.5.0"; + public static final String MOD_VERSION = "1.5.1"; public static final ServerTickDeltaCounter serverTickDeltaCounter = new ServerTickDeltaCounter(20.0F, 0L); public static Identifier makeID(String path) { diff --git a/common/src/main/java/com/faboslav/friendsandfoes/init/ModEntityTypes.java b/common/src/main/java/com/faboslav/friendsandfoes/init/ModEntityTypes.java index 1d106dad9..d22dad2b5 100644 --- a/common/src/main/java/com/faboslav/friendsandfoes/init/ModEntityTypes.java +++ b/common/src/main/java/com/faboslav/friendsandfoes/init/ModEntityTypes.java @@ -78,17 +78,17 @@ public static void initBiomeModifications() { var config = FriendsAndFoes.getConfig(); if (config.enableGlare && config.enableGlareSpawn) { - Predicate LUSH_CAVES = (ctx) -> Objects.equals(ctx.getKey(), BiomeKeys.LUSH_CAVES.getValue()); + Predicate LUSH_CAVES = (ctx) -> Objects.equals(ctx.getKey().get(), BiomeKeys.LUSH_CAVES.getValue()); registerBiomeModification(LUSH_CAVES, GLARE.get(), SpawnGroup.valueOf(ExpandedEnumValues.GLARES), config.glareSpawnWeight, config.glareSpawnMinGroupSize, config.glareSpawnMaxGroupSize); } if (config.enableMauler && config.enableMaulerSpawn) { - Predicate DESERT = (ctx) -> Objects.equals(ctx.getKey(), BiomeKeys.DESERT.getValue()); - Predicate BADLANDS = (ctx) -> Objects.equals(ctx.getKey(), BiomeKeys.BADLANDS.getValue()); - Predicate ERODED_BADLANDS = (ctx) -> Objects.equals(ctx.getKey(), BiomeKeys.ERODED_BADLANDS.getValue()); - Predicate WOODED_BADLANDS = (ctx) -> Objects.equals(ctx.getKey(), BiomeKeys.WOODED_BADLANDS.getValue()); - Predicate SAVANNA = (ctx) -> Objects.equals(ctx.getKey(), BiomeKeys.SAVANNA.getValue()); - Predicate SAVANNA_PLATEAU = (ctx) -> Objects.equals(ctx.getKey(), BiomeKeys.SAVANNA_PLATEAU.getValue()); + Predicate DESERT = (ctx) -> Objects.equals(ctx.getKey().get(), BiomeKeys.DESERT.getValue()); + Predicate BADLANDS = (ctx) -> Objects.equals(ctx.getKey().get(), BiomeKeys.BADLANDS.getValue()); + Predicate ERODED_BADLANDS = (ctx) -> Objects.equals(ctx.getKey().get(), BiomeKeys.ERODED_BADLANDS.getValue()); + Predicate WOODED_BADLANDS = (ctx) -> Objects.equals(ctx.getKey().get(), BiomeKeys.WOODED_BADLANDS.getValue()); + Predicate SAVANNA = (ctx) -> Objects.equals(ctx.getKey().get(), BiomeKeys.SAVANNA.getValue()); + Predicate SAVANNA_PLATEAU = (ctx) -> Objects.equals(ctx.getKey().get(), BiomeKeys.SAVANNA_PLATEAU.getValue()); registerBiomeModification(DESERT, MAULER.get(), SpawnGroup.CREATURE, config.maulerDesertSpawnWeight, config.maulerDesertSpawnMinGroupSize, config.maulerDesertSpawnMaxGroupSize); registerBiomeModification(BADLANDS, MAULER.get(), SpawnGroup.CREATURE, config.maulerBadlandsSpawnWeight, config.maulerBadlandsSpawnMinGroupSize, config.maulerBadlandsSpawnMaxGroupSize); @@ -99,8 +99,8 @@ public static void initBiomeModifications() { } if (config.enableMoobloom && config.enableMoobloomSpawn) { - Predicate FLOWER_FOREST = (ctx) -> Objects.equals(ctx.getKey(), BiomeKeys.FLOWER_FOREST.getValue()); - Predicate MEADOW = (ctx) -> Objects.equals(ctx.getKey(), BiomeKeys.MEADOW.getValue()); + Predicate FLOWER_FOREST = (ctx) -> Objects.equals(ctx.getKey().get(), BiomeKeys.FLOWER_FOREST.getValue()); + Predicate MEADOW = (ctx) -> Objects.equals(ctx.getKey().get(), BiomeKeys.MEADOW.getValue()); registerBiomeModification(FLOWER_FOREST, MOOBLOOM.get(), SpawnGroup.CREATURE, config.moobloomFlowerForestSpawnWeight, config.moobloomFlowerForestSpawnMinGroupSize, config.moobloomFlowerForestSpawnMaxGroupSize); registerBiomeModification(MEADOW, MOOBLOOM.get(), SpawnGroup.CREATURE, config.moobloomMeadowSpawnWeight, config.moobloomMeadowSpawnMinGroupSize, config.moobloomMeadowSpawnMaxGroupSize); diff --git a/gradle.properties b/gradle.properties index 861463cc2..4489115db 100644 --- a/gradle.properties +++ b/gradle.properties @@ -8,7 +8,7 @@ org.gradle.configureondemand=false # Mod mod_name=Friends&Foes mod_id=friendsandfoes -mod_version=1.5.0 +mod_version=1.5.1 mod_author=Faboslav mod_description=Adds all eliminated mobs from the minecraft mob votes along with the forgotten mobs like the Illusioner. maven_group=com.faboslav.friendsandfoes