Removed old Enderscape integration as new Versions are built using BCLib.

This commit is contained in:
Frank 2022-06-02 08:18:47 +02:00
parent be746ba286
commit 03c39d4a69
5 changed files with 7 additions and 58 deletions

View file

@ -11,7 +11,7 @@ fabric_version = 0.48.0+1.18.2
loom_version=0.10-SNAPSHOT
# Mod Properties
mod_version=1.1.0
mod_version=1.1.1
maven_group=ru.betterend
archives_base_name=better-end

View file

@ -1,50 +0,0 @@
package ru.betterend.integration;
import net.minecraft.core.Holder;
import net.minecraft.core.MappedRegistry;
import net.minecraft.resources.ResourceKey;
import net.minecraft.world.level.biome.Biome;
import net.minecraft.world.level.levelgen.GenerationStep.Decoration;
import ru.bclib.api.biomes.BiomeAPI;
import ru.bclib.api.tag.NamedCommonBlockTags;
import ru.bclib.api.tag.TagAPI;
import ru.bclib.integration.ModIntegration;
import ru.bclib.world.features.BCLFeature;
public class EnderscapeIntegration extends ModIntegration {
public EnderscapeIntegration() {
super("enderscape");
}
@Override
public void init() {
Class<?> enderscape = getClass("net.enderscape.Enderscape");
Class<?> enderscapeIslandsBiome = getClass("net.enderscape.world.biomes.EnderscapeIslandsBiome");
MappedRegistry<?> biomes = getStaticFieldValue(enderscape, "ENDERSCAPE_BIOME");
biomes.entrySet().forEach(entry -> {
ResourceKey key = entry.getKey();
Holder<Biome> biome = getBiome(key.location().getPath());
if (enderscapeIslandsBiome.isInstance(entry.getValue())) {
BiomeAPI.registerEndVoidBiome(biome);
}
else {
BiomeAPI.registerEndLandBiome(biome);
}
});
BCLFeature scatteredShadowQuartzOre = getFeature("scattered_shadow_quartz_ore", Decoration.UNDERGROUND_DECORATION);
BCLFeature voidNebuliteOre = getFeature("void_nebulite_ore", Decoration.UNDERGROUND_DECORATION);
BCLFeature nebuliteOre = getFeature("nebulite_ore", Decoration.UNDERGROUND_DECORATION);
BiomeAPI.registerEndBiomeModification((biomeID, biome) -> {
if (!biomeID.getNamespace().equals("enderscape")) {
BiomeAPI.addBiomeFeature(biome, scatteredShadowQuartzOre);
BiomeAPI.addBiomeFeature(biome, voidNebuliteOre);
BiomeAPI.addBiomeFeature(biome, nebuliteOre);
}
});
TagAPI.addBlockTag(NamedCommonBlockTags.GEN_END_STONES, getBlock("nebulite_ore"));
TagAPI.addBlockTag(NamedCommonBlockTags.GEN_END_STONES, getBlock("shadow_quartz_ore"));
}
}

View file

@ -18,7 +18,6 @@ public class Integrations {
public static final ModIntegration BYG = ModIntegrationAPI.register(new BYGIntegration());
public static final ModIntegration NOURISH = ModIntegrationAPI.register(new NourishIntegration());
public static final ModIntegration FLAMBOYANT_REFABRICATED = ModIntegrationAPI.register(new FlamboyantRefabricatedIntegration());
public static final ModIntegration ENDERSCAPE = ModIntegrationAPI.register(new EnderscapeIntegration());
private static boolean hasHydrogen;

View file

@ -12,15 +12,15 @@ import ru.betterend.integration.Integrations;
public class EndEffectsMixin {
@Inject(method = "getBrightnessDependentFogColor", at = @At("HEAD"), cancellable = true)
private void be_restoreBrightness(Vec3 color, float sunHeight, CallbackInfoReturnable<Vec3> info) {
if (Integrations.ENDERSCAPE.modIsInstalled()) {
info.setReturnValue(color.scale(0.15000000596046448D));
}
// if (Integrations.ENDERSCAPE.modIsInstalled()) {
// info.setReturnValue(color.scale(0.15000000596046448D));
// }
}
@Inject(method = "isFoggyAt", at = @At("HEAD"), cancellable = true)
private void be_restoreFog(int camX, int camY, CallbackInfoReturnable<Boolean> info) {
if (Integrations.ENDERSCAPE.modIsInstalled()) {
/*if (Integrations.ENDERSCAPE.modIsInstalled()) {
info.setReturnValue(false);
}
}*/
}
}

View file

@ -46,7 +46,7 @@
"fabricloader": ">=0.13.3",
"fabric": ">=0.44.0",
"minecraft": "1.18.2",
"bclib": ">=1.4.3"
"bclib": ">=1.4.7"
},
"suggests": {
"byg": ">=1.1.3",