mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2026-06-17 22:31:52 +00:00
update to 1.18 prerelease 5 & Java 17
This commit is contained in:
@@ -9,6 +9,6 @@ repositories {
|
|||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
"implementation"("com.github.jengelman.gradle.plugins:shadow:+")
|
"implementation"("gradle.plugin.com.github.jengelman.gradle.plugins:shadow:+")
|
||||||
"implementation"("org.yaml:snakeyaml:1.27")
|
"implementation"("org.yaml:snakeyaml:1.27")
|
||||||
}
|
}
|
||||||
@@ -21,8 +21,8 @@ fun Project.configureCompilation() {
|
|||||||
apply(plugin = "idea")
|
apply(plugin = "idea")
|
||||||
|
|
||||||
configure<JavaPluginExtension> {
|
configure<JavaPluginExtension> {
|
||||||
sourceCompatibility = JavaVersion.VERSION_16
|
sourceCompatibility = JavaVersion.VERSION_17
|
||||||
targetCompatibility = JavaVersion.VERSION_16
|
targetCompatibility = JavaVersion.VERSION_17
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.withType<JavaCompile> {
|
tasks.withType<JavaCompile> {
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ import com.modrinth.minotaur.TaskModrinthUpload
|
|||||||
import net.fabricmc.loom.task.RemapJarTask
|
import net.fabricmc.loom.task.RemapJarTask
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
id("fabric-loom").version("0.10.55")
|
id("fabric-loom").version("0.10.58")
|
||||||
id("com.modrinth.minotaur").version("1.1.0")
|
id("com.modrinth.minotaur").version("1.1.0")
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -16,7 +16,7 @@ tasks.named<ShadowJar>("shadowJar") {
|
|||||||
relocate("org.yaml", "com.dfsek.terra.lib.yaml")
|
relocate("org.yaml", "com.dfsek.terra.lib.yaml")
|
||||||
}
|
}
|
||||||
|
|
||||||
val minecraft = "1.18-pre1"
|
val minecraft = "1.18-pre5"
|
||||||
val yarn = "4"
|
val yarn = "4"
|
||||||
val fabricLoader = "0.12.5"
|
val fabricLoader = "0.12.5"
|
||||||
|
|
||||||
|
|||||||
+4
-4
@@ -31,7 +31,6 @@ import com.dfsek.terra.util.FastRandom;
|
|||||||
import com.mojang.serialization.Codec;
|
import com.mojang.serialization.Codec;
|
||||||
import com.mojang.serialization.codecs.RecordCodecBuilder;
|
import com.mojang.serialization.codecs.RecordCodecBuilder;
|
||||||
import net.minecraft.block.BlockState;
|
import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.class_6748;
|
|
||||||
import net.minecraft.entity.SpawnGroup;
|
import net.minecraft.entity.SpawnGroup;
|
||||||
import net.minecraft.server.world.ServerWorld;
|
import net.minecraft.server.world.ServerWorld;
|
||||||
import net.minecraft.structure.StructureManager;
|
import net.minecraft.structure.StructureManager;
|
||||||
@@ -52,6 +51,7 @@ import net.minecraft.world.biome.source.util.MultiNoiseUtil.NoiseValuePoint;
|
|||||||
import net.minecraft.world.chunk.Chunk;
|
import net.minecraft.world.chunk.Chunk;
|
||||||
import net.minecraft.world.gen.GenerationStep.Carver;
|
import net.minecraft.world.gen.GenerationStep.Carver;
|
||||||
import net.minecraft.world.gen.StructureAccessor;
|
import net.minecraft.world.gen.StructureAccessor;
|
||||||
|
import net.minecraft.world.gen.chunk.Blender;
|
||||||
import net.minecraft.world.gen.chunk.StructuresConfig;
|
import net.minecraft.world.gen.chunk.StructuresConfig;
|
||||||
import net.minecraft.world.gen.chunk.VerticalBlockSample;
|
import net.minecraft.world.gen.chunk.VerticalBlockSample;
|
||||||
import net.minecraft.world.gen.feature.*;
|
import net.minecraft.world.gen.feature.*;
|
||||||
@@ -169,7 +169,7 @@ public class FabricChunkGeneratorWrapper extends net.minecraft.world.gen.chunk.C
|
|||||||
if(!accessor.hasStructureReferences(pos)) {
|
if(!accessor.hasStructureReferences(pos)) {
|
||||||
return super.getEntitySpawnList(biome, accessor, group, pos);
|
return super.getEntitySpawnList(biome, accessor, group, pos);
|
||||||
} else {
|
} else {
|
||||||
if(accessor.method_38854(pos, StructureFeature.SWAMP_HUT).hasChildren()) {
|
if(accessor.getStructureAt(pos, StructureFeature.SWAMP_HUT).hasChildren()) {
|
||||||
if(group == SpawnGroup.MONSTER) {
|
if(group == SpawnGroup.MONSTER) {
|
||||||
return SwampHutFeature.MONSTER_SPAWNS;
|
return SwampHutFeature.MONSTER_SPAWNS;
|
||||||
}
|
}
|
||||||
@@ -188,7 +188,7 @@ public class FabricChunkGeneratorWrapper extends net.minecraft.world.gen.chunk.C
|
|||||||
return OceanMonumentFeature.MONSTER_SPAWNS;
|
return OceanMonumentFeature.MONSTER_SPAWNS;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(accessor.method_38854(pos, StructureFeature.FORTRESS).hasChildren()) {
|
if(accessor.getStructureAt(pos, StructureFeature.FORTRESS).hasChildren()) {
|
||||||
return NetherFortressFeature.MONSTER_SPAWNS;
|
return NetherFortressFeature.MONSTER_SPAWNS;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -210,7 +210,7 @@ public class FabricChunkGeneratorWrapper extends net.minecraft.world.gen.chunk.C
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public CompletableFuture<Chunk> populateNoise(Executor executor, class_6748 arg, StructureAccessor structureAccessor, Chunk chunk) {
|
public CompletableFuture<Chunk> populateNoise(Executor executor, Blender arg, StructureAccessor structureAccessor, Chunk chunk) {
|
||||||
return CompletableFuture.supplyAsync(() -> {
|
return CompletableFuture.supplyAsync(() -> {
|
||||||
World world = (World) ((StructureAccessorAccessor) structureAccessor).getWorld();
|
World world = (World) ((StructureAccessorAccessor) structureAccessor).getWorld();
|
||||||
delegate.generateChunkData(world, new FastRandom(), chunk.getPos().x, chunk.getPos().z, (ChunkData) chunk);
|
delegate.generateChunkData(world, new FastRandom(), chunk.getPos().x, chunk.getPos().z, (ChunkData) chunk);
|
||||||
|
|||||||
Reference in New Issue
Block a user