Merge remote-tracking branch 'origin/main'
This commit is contained in:
+10
-2
@@ -5,7 +5,8 @@ image: gradle:eclipse-temurin
|
||||
|
||||
# all stages need to be defined here
|
||||
stages:
|
||||
# TODO: Make stages depending on what is in versionProperties
|
||||
# TODO: Make stages depend on what is in versionProperties
|
||||
- build_1_16_5
|
||||
- build_1_18_2
|
||||
- build_1_19_2
|
||||
- build_1_19_4
|
||||
@@ -54,6 +55,13 @@ variables:
|
||||
extends: .build_java
|
||||
|
||||
|
||||
# 1.16.5 build
|
||||
build_1_16_5:
|
||||
stage: build_1_16_5
|
||||
variables:
|
||||
MC_VER: "1.16.5"
|
||||
extends: .build_mc
|
||||
|
||||
# 1.18.2 build
|
||||
build_1_18_2:
|
||||
stage: build_1_18_2
|
||||
@@ -130,7 +138,7 @@ pages:
|
||||
|
||||
|
||||
|
||||
# ============================== Previos CI for future reference ============================== #
|
||||
# ============================== Previous CI for future reference ============================== #
|
||||
## all stages need to be defined here
|
||||
# # Don't build the standalone jar yet because it isn't done yet
|
||||
# # - build_standalone
|
||||
|
||||
+3
-3
@@ -40,7 +40,7 @@ import net.minecraft.data.worldgen.biome.NetherBiomes;
|
||||
|
||||
#if MC_1_16_5
|
||||
import net.minecraft.core.Registry;
|
||||
#elif MC_1_18_2
|
||||
#elif MC_1_18_2 || MC_1_19_2
|
||||
import net.minecraft.core.Holder;
|
||||
import net.minecraft.core.Registry;
|
||||
import net.minecraft.core.RegistryAccess;
|
||||
@@ -110,7 +110,7 @@ public class BiomeWrapper implements IBiomeWrapper
|
||||
ResourceLocation resourceLocation;
|
||||
#if MC_1_16_5
|
||||
resourceLocation = registryAccess.registryOrThrow(Registry.BIOME_REGISTRY).getKey(this.biome);
|
||||
#elif MC_1_18_2
|
||||
#elif MC_1_18_2 || MC_1_19_2
|
||||
resourceLocation = registryAccess.registryOrThrow(Registry.BIOME_REGISTRY).getKey(this.biome.value());
|
||||
#else
|
||||
resourceLocation = registryAccess.registryOrThrow(Registries.BIOME).getKey(this.biome.value());
|
||||
@@ -152,7 +152,7 @@ public class BiomeWrapper implements IBiomeWrapper
|
||||
|
||||
#if MC_1_16_5
|
||||
Biome biome = registryAccess.registryOrThrow(Registry.BIOME_REGISTRY).get(resourceLocation);
|
||||
#elif MC_1_18_2
|
||||
#elif MC_1_18_2 || MC_1_19_2
|
||||
Biome unwrappedBiome = registryAccess.registryOrThrow(Registry.BIOME_REGISTRY).get(resourceLocation);
|
||||
Holder<Biome> biome = new Holder.Direct<>(unwrappedBiome);
|
||||
#else
|
||||
|
||||
+3
-3
@@ -16,7 +16,7 @@ import java.util.concurrent.ConcurrentHashMap;
|
||||
|
||||
#if MC_1_16_5
|
||||
import net.minecraft.core.Registry;
|
||||
#elif MC_1_18_2
|
||||
#elif MC_1_18_2 || MC_1_19_2
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.core.BlockPos;
|
||||
import net.minecraft.core.Registry;
|
||||
@@ -103,7 +103,7 @@ public class BlockStateWrapper implements IBlockStateWrapper
|
||||
ResourceLocation resourceLocation;
|
||||
#if MC_1_16_5
|
||||
resourceLocation = Registry.BLOCK.getKey(this.blockState.getBlock());
|
||||
#elif MC_1_18_2
|
||||
#elif MC_1_18_2 || MC_1_19_2
|
||||
net.minecraft.core.RegistryAccess registryAccess = Minecraft.getInstance().level.registryAccess();
|
||||
resourceLocation = registryAccess.registryOrThrow(Registry.BLOCK_REGISTRY).getKey(this.blockState.getBlock());
|
||||
#else
|
||||
@@ -150,7 +150,7 @@ public class BlockStateWrapper implements IBlockStateWrapper
|
||||
Block block;
|
||||
#if MC_1_16_5
|
||||
block = Registry.BLOCK.get(resourceLocation);
|
||||
#elif MC_1_18_2
|
||||
#elif MC_1_18_2 || MC_1_19_2
|
||||
net.minecraft.core.RegistryAccess registryAccess = Minecraft.getInstance().level.registryAccess();
|
||||
block = registryAccess.registryOrThrow(Registry.BLOCK_REGISTRY).get(resourceLocation);
|
||||
#else
|
||||
|
||||
Reference in New Issue
Block a user