mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2026-06-17 22:31:52 +00:00
use TerraPluginImpl over TerraFabricPlugin
This commit is contained in:
@@ -130,6 +130,10 @@ public abstract class AbstractTerraPlugin implements TerraPlugin {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public CommandManager getManager() {
|
||||||
|
return manager;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Logger getDebugLogger() {
|
public Logger getDebugLogger() {
|
||||||
return debugLogger.value();
|
return debugLogger.value();
|
||||||
|
|||||||
+2
-1
@@ -6,6 +6,7 @@ import com.dfsek.terra.api.world.generator.ChunkData;
|
|||||||
import com.dfsek.terra.api.world.generator.Chunkified;
|
import com.dfsek.terra.api.world.generator.Chunkified;
|
||||||
import com.dfsek.terra.api.world.generator.GeneratorWrapper;
|
import com.dfsek.terra.api.world.generator.GeneratorWrapper;
|
||||||
import com.dfsek.terra.api.world.generator.ChunkGenerator;
|
import com.dfsek.terra.api.world.generator.ChunkGenerator;
|
||||||
|
import com.dfsek.terra.fabric.FabricEntryPoint;
|
||||||
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
||||||
import com.dfsek.terra.fabric.block.FabricBlockState;
|
import com.dfsek.terra.fabric.block.FabricBlockState;
|
||||||
import com.dfsek.terra.fabric.mixin.StructureAccessorAccessor;
|
import com.dfsek.terra.fabric.mixin.StructureAccessorAccessor;
|
||||||
@@ -44,7 +45,7 @@ public class FabricChunkGeneratorWrapper extends net.minecraft.world.gen.chunk.C
|
|||||||
config -> config.group(
|
config -> config.group(
|
||||||
Codec.STRING.fieldOf("pack")
|
Codec.STRING.fieldOf("pack")
|
||||||
.forGetter(ConfigPack::getID)
|
.forGetter(ConfigPack::getID)
|
||||||
).apply(config, config.stable(TerraFabricPlugin.getInstance().getConfigRegistry()::get)));
|
).apply(config, config.stable(FabricEntryPoint.getTerraPlugin().getConfigRegistry()::get)));
|
||||||
|
|
||||||
public static final Codec<FabricChunkGeneratorWrapper> CODEC = RecordCodecBuilder.create(
|
public static final Codec<FabricChunkGeneratorWrapper> CODEC = RecordCodecBuilder.create(
|
||||||
instance -> instance.group(
|
instance -> instance.group(
|
||||||
|
|||||||
+2
-1
@@ -3,6 +3,7 @@ package com.dfsek.terra.fabric.generation;
|
|||||||
import com.dfsek.terra.api.config.ConfigPack;
|
import com.dfsek.terra.api.config.ConfigPack;
|
||||||
import com.dfsek.terra.api.world.biome.TerraBiome;
|
import com.dfsek.terra.api.world.biome.TerraBiome;
|
||||||
import com.dfsek.terra.api.world.biome.generation.BiomeProvider;
|
import com.dfsek.terra.api.world.biome.generation.BiomeProvider;
|
||||||
|
import com.dfsek.terra.fabric.FabricEntryPoint;
|
||||||
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
||||||
import com.dfsek.terra.fabric.util.FabricUtil;
|
import com.dfsek.terra.fabric.util.FabricUtil;
|
||||||
import com.mojang.serialization.Codec;
|
import com.mojang.serialization.Codec;
|
||||||
@@ -19,7 +20,7 @@ import java.util.stream.Collectors;
|
|||||||
public class TerraBiomeSource extends BiomeSource {
|
public class TerraBiomeSource extends BiomeSource {
|
||||||
public static final Codec<ConfigPack> PACK_CODEC = (RecordCodecBuilder.create(config -> config.group(
|
public static final Codec<ConfigPack> PACK_CODEC = (RecordCodecBuilder.create(config -> config.group(
|
||||||
Codec.STRING.fieldOf("pack").forGetter(ConfigPack::getID)
|
Codec.STRING.fieldOf("pack").forGetter(ConfigPack::getID)
|
||||||
).apply(config, config.stable(TerraFabricPlugin.getInstance().getConfigRegistry()::get))));
|
).apply(config, config.stable(FabricEntryPoint.getTerraPlugin().getConfigRegistry()::get))));
|
||||||
public static final Codec<TerraBiomeSource> CODEC = RecordCodecBuilder.create(instance -> instance.group(
|
public static final Codec<TerraBiomeSource> CODEC = RecordCodecBuilder.create(instance -> instance.group(
|
||||||
RegistryLookupCodec.of(Registry.BIOME_KEY).forGetter(source -> source.biomeRegistry),
|
RegistryLookupCodec.of(Registry.BIOME_KEY).forGetter(source -> source.biomeRegistry),
|
||||||
Codec.LONG.fieldOf("seed").stable().forGetter(source -> source.seed),
|
Codec.LONG.fieldOf("seed").stable().forGetter(source -> source.seed),
|
||||||
|
|||||||
+2
-1
@@ -1,6 +1,7 @@
|
|||||||
package com.dfsek.terra.fabric.generation;
|
package com.dfsek.terra.fabric.generation;
|
||||||
|
|
||||||
import com.dfsek.terra.api.config.ConfigPack;
|
import com.dfsek.terra.api.config.ConfigPack;
|
||||||
|
import com.dfsek.terra.fabric.FabricEntryPoint;
|
||||||
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
||||||
import com.dfsek.terra.fabric.event.BiomeRegistrationEvent;
|
import com.dfsek.terra.fabric.event.BiomeRegistrationEvent;
|
||||||
import net.fabricmc.api.EnvType;
|
import net.fabricmc.api.EnvType;
|
||||||
@@ -25,7 +26,7 @@ public class TerraGeneratorType extends GeneratorType {
|
|||||||
@Override
|
@Override
|
||||||
public GeneratorOptions createDefaultOptions(DynamicRegistryManager.Impl registryManager, long seed, boolean generateStructures, boolean bonusChest) {
|
public GeneratorOptions createDefaultOptions(DynamicRegistryManager.Impl registryManager, long seed, boolean generateStructures, boolean bonusChest) {
|
||||||
GeneratorOptions options = super.createDefaultOptions(registryManager, seed, generateStructures, bonusChest);
|
GeneratorOptions options = super.createDefaultOptions(registryManager, seed, generateStructures, bonusChest);
|
||||||
TerraFabricPlugin.getInstance().getEventManager().callEvent(new BiomeRegistrationEvent(registryManager)); // register biomes
|
FabricEntryPoint.getTerraPlugin().getEventManager().callEvent(new BiomeRegistrationEvent(registryManager)); // register biomes
|
||||||
return options;
|
return options;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -3,6 +3,7 @@ package com.dfsek.terra.fabric.mixin;
|
|||||||
import com.dfsek.terra.api.command.exception.CommandException;
|
import com.dfsek.terra.api.command.exception.CommandException;
|
||||||
import com.dfsek.terra.api.entity.CommandSender;
|
import com.dfsek.terra.api.entity.CommandSender;
|
||||||
import com.dfsek.terra.api.entity.Entity;
|
import com.dfsek.terra.api.entity.Entity;
|
||||||
|
import com.dfsek.terra.fabric.FabricEntryPoint;
|
||||||
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
||||||
import com.mojang.brigadier.CommandDispatcher;
|
import com.mojang.brigadier.CommandDispatcher;
|
||||||
import com.mojang.brigadier.arguments.StringArgumentType;
|
import com.mojang.brigadier.arguments.StringArgumentType;
|
||||||
@@ -33,7 +34,7 @@ public abstract class CommandManagerMixin {
|
|||||||
|
|
||||||
@Inject(method = "<init>", at = @At(value = "INVOKE", target = "Lcom/mojang/brigadier/CommandDispatcher;findAmbiguities(Lcom/mojang/brigadier/AmbiguityConsumer;)V", remap = false))
|
@Inject(method = "<init>", at = @At(value = "INVOKE", target = "Lcom/mojang/brigadier/CommandDispatcher;findAmbiguities(Lcom/mojang/brigadier/AmbiguityConsumer;)V", remap = false))
|
||||||
private void injectTerraCommands(CommandManager.RegistrationEnvironment environment, CallbackInfo ci) {
|
private void injectTerraCommands(CommandManager.RegistrationEnvironment environment, CallbackInfo ci) {
|
||||||
com.dfsek.terra.api.command.CommandManager manager = TerraFabricPlugin.getInstance().getManager();
|
com.dfsek.terra.api.command.CommandManager manager = FabricEntryPoint.getTerraPlugin().getManager();
|
||||||
int max = manager.getMaxArgumentDepth();
|
int max = manager.getMaxArgumentDepth();
|
||||||
RequiredArgumentBuilder<ServerCommandSource, String> arg = argument("arg" + (max - 1), StringArgumentType.word());
|
RequiredArgumentBuilder<ServerCommandSource, String> arg = argument("arg" + (max - 1), StringArgumentType.word());
|
||||||
for(int i = 0; i < max; i++) {
|
for(int i = 0; i < max; i++) {
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package com.dfsek.terra.fabric.mixin;
|
package com.dfsek.terra.fabric.mixin;
|
||||||
|
|
||||||
|
import com.dfsek.terra.fabric.FabricEntryPoint;
|
||||||
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
||||||
import com.dfsek.terra.fabric.generation.FabricChunkGeneratorWrapper;
|
import com.dfsek.terra.fabric.generation.FabricChunkGeneratorWrapper;
|
||||||
import net.minecraft.server.MinecraftServer;
|
import net.minecraft.server.MinecraftServer;
|
||||||
@@ -26,7 +27,7 @@ public abstract class ServerWorldMixin {
|
|||||||
public void injectConstructor(MinecraftServer server, Executor workerExecutor, LevelStorage.Session session, ServerWorldProperties properties, RegistryKey<World> registryKey, DimensionType dimensionType, WorldGenerationProgressListener worldGenerationProgressListener, ChunkGenerator chunkGenerator, boolean debugWorld, long l, List<Spawner> list, boolean bl, CallbackInfo ci) {
|
public void injectConstructor(MinecraftServer server, Executor workerExecutor, LevelStorage.Session session, ServerWorldProperties properties, RegistryKey<World> registryKey, DimensionType dimensionType, WorldGenerationProgressListener worldGenerationProgressListener, ChunkGenerator chunkGenerator, boolean debugWorld, long l, List<Spawner> list, boolean bl, CallbackInfo ci) {
|
||||||
if(chunkGenerator instanceof FabricChunkGeneratorWrapper) {
|
if(chunkGenerator instanceof FabricChunkGeneratorWrapper) {
|
||||||
((FabricChunkGeneratorWrapper) chunkGenerator).setWorld((ServerWorld) (Object) this);
|
((FabricChunkGeneratorWrapper) chunkGenerator).setWorld((ServerWorld) (Object) this);
|
||||||
TerraFabricPlugin.getInstance().logger().info("Registered world " + this);
|
FabricEntryPoint.getTerraPlugin().logger().info("Registered world " + this);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+5
-4
@@ -6,6 +6,7 @@ import com.dfsek.terra.api.util.collection.MaterialSet;
|
|||||||
import com.dfsek.terra.api.vector.Vector3;
|
import com.dfsek.terra.api.vector.Vector3;
|
||||||
import com.dfsek.terra.api.world.Tree;
|
import com.dfsek.terra.api.world.Tree;
|
||||||
import com.dfsek.terra.api.world.World;
|
import com.dfsek.terra.api.world.World;
|
||||||
|
import com.dfsek.terra.fabric.FabricEntryPoint;
|
||||||
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.registry.BuiltinRegistries;
|
import net.minecraft.util.registry.BuiltinRegistries;
|
||||||
@@ -32,7 +33,7 @@ public abstract class ConfiguredFeatureMixin {
|
|||||||
@SuppressWarnings({"ConstantConditions", "try"})
|
@SuppressWarnings({"ConstantConditions", "try"})
|
||||||
public boolean terra$plant(Vector3 l, World world, Random r) {
|
public boolean terra$plant(Vector3 l, World world, Random r) {
|
||||||
String id = BuiltinRegistries.CONFIGURED_FEATURE.getId((ConfiguredFeature<?, ?>) (Object) this).toString();
|
String id = BuiltinRegistries.CONFIGURED_FEATURE.getId((ConfiguredFeature<?, ?>) (Object) this).toString();
|
||||||
try(ProfileFrame ignore = TerraFabricPlugin.getInstance().getProfiler().profile("fabric_tree:" + id.toLowerCase(Locale.ROOT))) {
|
try(ProfileFrame ignore = FabricEntryPoint.getTerraPlugin().getProfiler().profile("fabric_tree:" + id.toLowerCase(Locale.ROOT))) {
|
||||||
StructureWorldAccess fabricWorldAccess = ((StructureWorldAccess) world);
|
StructureWorldAccess fabricWorldAccess = ((StructureWorldAccess) world);
|
||||||
ChunkGenerator generatorWrapper = ((ServerWorldAccess) world).toServerWorld().getChunkManager().getChunkGenerator();
|
ChunkGenerator generatorWrapper = ((ServerWorldAccess) world).toServerWorld().getChunkManager().getChunkGenerator();
|
||||||
return generate(fabricWorldAccess, generatorWrapper, r, new BlockPos(l.getBlockX(), l.getBlockY(), l.getBlockZ()));
|
return generate(fabricWorldAccess, generatorWrapper, r, new BlockPos(l.getBlockX(), l.getBlockY(), l.getBlockZ()));
|
||||||
@@ -40,8 +41,8 @@ public abstract class ConfiguredFeatureMixin {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public Set<BlockType> terra$getSpawnable() {
|
public Set<BlockType> terra$getSpawnable() {
|
||||||
return MaterialSet.get(TerraFabricPlugin.getInstance().getWorldHandle().createBlockData("minecraft:grass_block"),
|
return MaterialSet.get(FabricEntryPoint.getTerraPlugin().getWorldHandle().createBlockData("minecraft:grass_block"),
|
||||||
TerraFabricPlugin.getInstance().getWorldHandle().createBlockData("minecraft:podzol"),
|
FabricEntryPoint.getTerraPlugin().getWorldHandle().createBlockData("minecraft:podzol"),
|
||||||
TerraFabricPlugin.getInstance().getWorldHandle().createBlockData("minecraft:mycelium"));
|
FabricEntryPoint.getTerraPlugin().getWorldHandle().createBlockData("minecraft:mycelium"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-1
@@ -3,6 +3,7 @@ package com.dfsek.terra.fabric.mixin.implementations.block.state;
|
|||||||
import com.dfsek.terra.api.block.entity.MobSpawner;
|
import com.dfsek.terra.api.block.entity.MobSpawner;
|
||||||
import com.dfsek.terra.api.block.entity.SerialState;
|
import com.dfsek.terra.api.block.entity.SerialState;
|
||||||
import com.dfsek.terra.api.entity.EntityType;
|
import com.dfsek.terra.api.entity.EntityType;
|
||||||
|
import com.dfsek.terra.fabric.FabricEntryPoint;
|
||||||
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
||||||
import com.dfsek.terra.fabric.mixin.access.MobSpawnerLogicAccessor;
|
import com.dfsek.terra.fabric.mixin.access.MobSpawnerLogicAccessor;
|
||||||
import net.minecraft.block.BlockState;
|
import net.minecraft.block.BlockState;
|
||||||
@@ -96,7 +97,7 @@ public abstract class MobSpawnerBlockEntityMixin extends BlockEntity {
|
|||||||
SerialState.parse(state).forEach((k, v) -> {
|
SerialState.parse(state).forEach((k, v) -> {
|
||||||
switch(k) {
|
switch(k) {
|
||||||
case "type":
|
case "type":
|
||||||
terra$setSpawnedType(TerraFabricPlugin.getInstance().getWorldHandle().getEntity(v));
|
terra$setSpawnedType(FabricEntryPoint.getTerraPlugin().getWorldHandle().getEntity(v));
|
||||||
return;
|
return;
|
||||||
case "delay":
|
case "delay":
|
||||||
terra$setDelay(Integer.parseInt(v));
|
terra$setDelay(Integer.parseInt(v));
|
||||||
|
|||||||
+3
-2
@@ -1,5 +1,6 @@
|
|||||||
package com.dfsek.terra.fabric.mixin.lifecycle.client;
|
package com.dfsek.terra.fabric.mixin.lifecycle.client;
|
||||||
|
|
||||||
|
import com.dfsek.terra.fabric.FabricEntryPoint;
|
||||||
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
||||||
import com.dfsek.terra.api.event.events.platform.PlatformInitializationEvent;
|
import com.dfsek.terra.api.event.events.platform.PlatformInitializationEvent;
|
||||||
import com.dfsek.terra.fabric.generation.TerraGeneratorType;
|
import com.dfsek.terra.fabric.generation.TerraGeneratorType;
|
||||||
@@ -19,8 +20,8 @@ public class MinecraftClientMixin {
|
|||||||
target = "Lnet/minecraft/client/util/WindowProvider;createWindow(Lnet/minecraft/client/WindowSettings;Ljava/lang/String;Ljava/lang/String;)Lnet/minecraft/client/util/Window;", // sorta arbitrary position, after mod init, before window opens
|
target = "Lnet/minecraft/client/util/WindowProvider;createWindow(Lnet/minecraft/client/WindowSettings;Ljava/lang/String;Ljava/lang/String;)Lnet/minecraft/client/util/Window;", // sorta arbitrary position, after mod init, before window opens
|
||||||
shift = At.Shift.BEFORE))
|
shift = At.Shift.BEFORE))
|
||||||
public void injectConstructor(RunArgs args, CallbackInfo callbackInfo) {
|
public void injectConstructor(RunArgs args, CallbackInfo callbackInfo) {
|
||||||
TerraFabricPlugin.getInstance().getEventManager().callEvent(new PlatformInitializationEvent());
|
FabricEntryPoint.getTerraPlugin().getEventManager().callEvent(new PlatformInitializationEvent());
|
||||||
TerraFabricPlugin.getInstance().getConfigRegistry().forEach(pack -> {
|
FabricEntryPoint.getTerraPlugin().getConfigRegistry().forEach(pack -> {
|
||||||
final GeneratorType generatorType = new TerraGeneratorType(pack);
|
final GeneratorType generatorType = new TerraGeneratorType(pack);
|
||||||
//noinspection ConstantConditions
|
//noinspection ConstantConditions
|
||||||
((GeneratorTypeAccessor) generatorType).setTranslationKey(new LiteralText("Terra:" + pack.getID()));
|
((GeneratorTypeAccessor) generatorType).setTranslationKey(new LiteralText("Terra:" + pack.getID()));
|
||||||
|
|||||||
+3
-1
@@ -1,7 +1,9 @@
|
|||||||
package com.dfsek.terra.fabric.mixin.lifecycle.server;
|
package com.dfsek.terra.fabric.mixin.lifecycle.server;
|
||||||
|
|
||||||
import com.dfsek.terra.api.config.ConfigPack;
|
import com.dfsek.terra.api.config.ConfigPack;
|
||||||
|
import com.dfsek.terra.fabric.FabricEntryPoint;
|
||||||
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
||||||
|
import com.dfsek.terra.fabric.TerraPluginImpl;
|
||||||
import com.dfsek.terra.fabric.event.BiomeRegistrationEvent;
|
import com.dfsek.terra.fabric.event.BiomeRegistrationEvent;
|
||||||
import com.dfsek.terra.fabric.generation.FabricChunkGeneratorWrapper;
|
import com.dfsek.terra.fabric.generation.FabricChunkGeneratorWrapper;
|
||||||
import com.dfsek.terra.fabric.generation.TerraBiomeSource;
|
import com.dfsek.terra.fabric.generation.TerraBiomeSource;
|
||||||
@@ -30,7 +32,7 @@ public abstract class GeneratorOptionsMixin {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
TerraFabricPlugin main = TerraFabricPlugin.getInstance();
|
TerraPluginImpl main = FabricEntryPoint.getTerraPlugin();
|
||||||
|
|
||||||
String prop = properties.get("level-type").toString().trim();
|
String prop = properties.get("level-type").toString().trim();
|
||||||
if(prop.startsWith("Terra")) {
|
if(prop.startsWith("Terra")) {
|
||||||
|
|||||||
+2
-1
@@ -1,5 +1,6 @@
|
|||||||
package com.dfsek.terra.fabric.mixin.lifecycle.server;
|
package com.dfsek.terra.fabric.mixin.lifecycle.server;
|
||||||
|
|
||||||
|
import com.dfsek.terra.fabric.FabricEntryPoint;
|
||||||
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
import com.dfsek.terra.fabric.TerraFabricPlugin;
|
||||||
import com.dfsek.terra.api.event.events.platform.PlatformInitializationEvent;
|
import com.dfsek.terra.api.event.events.platform.PlatformInitializationEvent;
|
||||||
import net.minecraft.server.Main;
|
import net.minecraft.server.Main;
|
||||||
@@ -12,6 +13,6 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
|||||||
public class ServerMainMixin {
|
public class ServerMainMixin {
|
||||||
@Inject(method = "main([Ljava/lang/String;)V", at = @At(value = "INVOKE", target = "Lnet/minecraft/util/registry/DynamicRegistryManager;create()Lnet/minecraft/util/registry/DynamicRegistryManager$Impl;"))
|
@Inject(method = "main([Ljava/lang/String;)V", at = @At(value = "INVOKE", target = "Lnet/minecraft/util/registry/DynamicRegistryManager;create()Lnet/minecraft/util/registry/DynamicRegistryManager$Impl;"))
|
||||||
private static void injectConstructor(String[] args, CallbackInfo ci) {
|
private static void injectConstructor(String[] args, CallbackInfo ci) {
|
||||||
TerraFabricPlugin.getInstance().getEventManager().callEvent(new PlatformInitializationEvent()); // Load during MinecraftServer construction, after other mods have registered blocks and stuff
|
FabricEntryPoint.getTerraPlugin().getEventManager().callEvent(new PlatformInitializationEvent()); // Load during MinecraftServer construction, after other mods have registered blocks and stuff
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ public final class FabricUtil {
|
|||||||
// BiomeTemplate template = biome.getTemplate();
|
// BiomeTemplate template = biome.getTemplate();
|
||||||
Map<String, Integer> colors = new HashMap<>(); // template.getColors();
|
Map<String, Integer> colors = new HashMap<>(); // template.getColors();
|
||||||
|
|
||||||
TerraFabricPlugin.FabricAddon fabricAddon = TerraFabricPlugin.getInstance().getFabricAddon();
|
//TerraFabricPlugin.FabricAddon fabricAddon = TerraFabricPlugin.getInstance().getFabricAddon();
|
||||||
|
|
||||||
Registry<Biome> biomeRegistry = registryManager.get(Registry.BIOME_KEY);
|
Registry<Biome> biomeRegistry = registryManager.get(Registry.BIOME_KEY);
|
||||||
Biome vanilla = ((ProtoBiome) (new ArrayList<>(biome.getVanillaBiomes().getContents()).get(0))).get(biomeRegistry);
|
Biome vanilla = ((ProtoBiome) (new ArrayList<>(biome.getVanillaBiomes().getContents()).get(0))).get(biomeRegistry);
|
||||||
|
|||||||
Reference in New Issue
Block a user