mirror of
https://github.com/GTMEGA/EndlessIDs.git
synced 2026-11-23 22:59:44 +00:00
DimDoors compat (#111)
This commit is contained in:
5 files changed
+39
No files matched your search
@@ -30,6 +30,7 @@ This mod also contains patches for the following mods:
|
||||
- Compact Machines
|
||||
- CoFH Lib
|
||||
- Dark World
|
||||
- Dimensional Doors
|
||||
- DragonAPI
|
||||
- Dynamic Surroundings
|
||||
- Enderlicious
|
||||
|
||||
@@ -70,6 +70,9 @@ dependencies {
|
||||
//Dark World 0.2
|
||||
compileOnly(deobfCurse("darkworld-225075:2225172"))
|
||||
|
||||
//DimDoors 2.2.5-test9
|
||||
compileOnly(deobf("https://github.com/CannibalVox/DimDoors/releases/download/2.2.5-test9/DimensionalDoors-2.2.5-test9.jar"))
|
||||
|
||||
//DragonAPI V31b
|
||||
compileOnly(deobfCurse("dragonapi-235591:3574508"))
|
||||
|
||||
|
||||
+31
@@ -0,0 +1,31 @@
|
||||
package com.falsepattern.endlessids.mixin.mixins.common.biome.dimdoors;
|
||||
|
||||
import StevenDimDoors.mod_pocketDim.world.DDBiomeGenBase;
|
||||
import com.falsepattern.endlessids.PlaceholderBiome;
|
||||
import lombok.val;
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
import org.spongepowered.asm.mixin.Overwrite;
|
||||
|
||||
import net.minecraft.world.biome.BiomeGenBase;
|
||||
|
||||
@Mixin(DDBiomeGenBase.class)
|
||||
public abstract class DDBiomeGenBaseMixin extends BiomeGenBase {
|
||||
private DDBiomeGenBaseMixin(int p_i1971_1_) {
|
||||
super(p_i1971_1_);
|
||||
}
|
||||
|
||||
/**
|
||||
* @author FalsePattern
|
||||
* @reason Compat patch
|
||||
*/
|
||||
@Overwrite
|
||||
public static void checkBiomes(int[] biomes) {
|
||||
val arr = getBiomeGenArray();
|
||||
for(int k = 0; k < biomes.length; ++k) {
|
||||
val b = arr[biomes[k]];
|
||||
if (b != null && !(b instanceof DDBiomeGenBase || b instanceof PlaceholderBiome)) {
|
||||
throw new IllegalStateException("There is a biome ID conflict between a biome from Dimensional Doors and another biome type. Fix your configuration!");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -68,6 +68,9 @@ public enum Mixin implements IMixin {
|
||||
//region DarkWorld
|
||||
DarkWorldModBiomesMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.DARKWORLD)), "biome.darkworld.ModBiomesMixin"),
|
||||
//endregion DarkWorld
|
||||
//region DimDoors
|
||||
DDBiomeGenBaseMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.DIMDOORS)), "biome.dimdoors.DDBiomeGenBaseMixin"),
|
||||
//endregion DimDoors
|
||||
//region DragonAPI
|
||||
DragonAPIGenLayerRiverMixVanillaMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.DRAGONAPI)), "biome.dragonapi.vanilla.GenLayerRiverMixMixin"),
|
||||
DragonAPIGenLayerRiverEventMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.DRAGONAPI)), "biome.dragonapi.GenLayerRiverEventMixin"),
|
||||
|
||||
@@ -23,6 +23,7 @@ public enum TargetedMod implements ITargetedMod {
|
||||
COFHLIB("CoFH Lib", false, startsWith("cofhlib-")),
|
||||
COMPACTMACHINES("Compact Machines", false, startsWith("compactmachines-")),
|
||||
DARKWORLD("Dark World", false, startsWith("darkworld-")),
|
||||
DIMDOORS("Dimensional Doors", false, startsWith("dimensionaldoors-").or(startsWith("dimdoors-"))),
|
||||
DRAGONAPI("DragonAPI", false, startsWith("dragonapi")),
|
||||
EB("Enhanced Biomes", false, startsWith("Enhanced Biomes").or(startsWith("enhancedbiomes"))),
|
||||
ENDERLICIOUS("Enderlicious", false, startsWith("enderlicious-")),
|
||||
|
||||
Reference in new issue
Block a user