Compare commits

...
Author SHA1 Message Date
FalsePattern 76092e5c4c update buildscript 2023-04-02 14:21:31 +02:00
FalsePattern 0ecadb8563 bump deps 2023-04-02 14:20:38 +02:00
FalsePattern 147099d625 remap fixes 2023-04-02 14:01:31 +02:00
FalsePattern e699d67f4e IR3 compat (#104) 2023-04-02 13:48:06 +02:00
FalsePattern 6101766529 oops, forgot this 2023-04-02 13:22:58 +02:00
FalsePattern 8c715bd579 Restructured compat (#105) 2023-04-02 13:08:27 +02:00
FalsePattern e7340cd9b1 remove LOTR from readme until fixed 2023-04-02 12:54:24 +02:00
FalsePattern 786652504c DimDoors compat (#111) 2023-04-02 12:54:22 +02:00
FalsePattern 4ded45cc5c fix some mixin conflicts (#112) 2023-04-02 12:18:55 +02:00
FalsePattern 16be8d607c [ci skip] update publishing 2023-04-01 11:52:19 +02:00
14 changed files with 197 additions and 12 deletions

No files matched your search

+1 -1
View File
@@ -3,7 +3,7 @@ EndlessIDs
Copyright (C) 2022 FalsePattern
All Rights Reserved
The above copyright notice, this permission notice and the word "SNEED"
The above copyright notice, this permission notice and the words "MEGA"
shall be included in all copies or substantial portions of the Software.
This program is free software: you can redistribute it and/or modify
+3 -1
View File
@@ -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
@@ -41,12 +42,13 @@ This mod also contains patches for the following mods:
- GalactiCraft
- Highlands
- Immersive Cavegen
- LOTR
- Industrial Revolution by Redstone Rebooted
- More Fun Quicksand Mod
- Nature's Compass
- Netherlicious
- Nomadic Tents
- Random Things
- Restructured
- Realistic Terrain Generation
- Realistic World Generation
- Thaumcraft
+3 -1
View File
@@ -1,4 +1,4 @@
//version: 1656003793falsepattern63
//version: 1656003793falsepattern65
/*
DO NOT CHANGE THIS FILE!
@@ -670,6 +670,8 @@ def getCredentials = {
}
//Publishing
tasks.publish.dependsOn(build)
publishing {
publications {
maven(MavenPublication) {
+12 -3
View File
@@ -16,14 +16,14 @@ def deobfCurse(curseDep) {
dependencies {
////////////////Our dependencies////////////////
compileOnly("org.projectlombok:lombok:1.18.24") {
compileOnly("org.projectlombok:lombok:[1.18, 1.19)") {
transitive = false
}
annotationProcessor("org.projectlombok:lombok:1.18.24")
annotationProcessor("org.projectlombok:lombok:[1.18, 1.19)")
implementation("com.falsepattern:falsepatternlib-mc1.7.10:0.10.15:dev")
implementation("com.falsepattern:chunkapi-mc1.7.10:0.1.0:dev")
implementation("com.falsepattern:chunkapi-mc1.7.10:0.1.1:dev")
////////////////Patched mods////////////////
@@ -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"))
@@ -107,6 +110,9 @@ dependencies {
//Immersive Cavegen 1.2g
compileOnly(deobfCurse("immersivecavegen-521557:3649411"))
//Industrial Revolution by Redstone Rebooted 1.1.1
compileOnly(deobfCurse("industrialrevolutionbyredstonerebooted-241812:2538035"))
//LOTR Mod 36.14
compileOnly(deobfCurse("lotrmod-423748:3646430"))
@@ -128,6 +134,9 @@ dependencies {
//Realistic Terrain Generation 1.1.1.7
compileOnly(deobfCurse("rtg-237989:2521557"))
//Restructured 1.0.4.2
compileOnly(deobfCurse("restructured-230570:2276784"))
//Thaumcraft 4.2.3.5
compileOnly(deobfCurse("thaumcraft-223628:2227552"))
+2 -2
View File
@@ -72,7 +72,7 @@ modrinthProjectId = qGHY4QGo
# type can be one of [project, version],
# and the name is the Modrinth project or version slug/id of the other mod.
# Example: required-project:fplib;optional-project:spongemixin1710;incompatible-project:gregtech
modrinthDependencies = required-project:fplib
modrinthDependencies = required-project:fplib;required-project:chunkapi
#endregion modrinth
@@ -90,7 +90,7 @@ curseForgeProjectId = 665730
# Where type can be one of [requiredDependency, embeddedLibrary, optionalDependency, tool, incompatible],
# and the name is the CurseForge project id of the other mod.
# Example: requiredDependency:railcraft;embeddedLibrary:cofhlib;incompatible:buildcraft
curseForgeRelations = requiredDependency:fplib
curseForgeRelations = requiredDependency:fplib;requiredDependency:chunkapi
#endregion curseforge
@@ -0,0 +1,33 @@
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(value = DDBiomeGenBase.class,
priority = 999,
remap = false)
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!");
}
}
}
}
@@ -5,7 +5,8 @@ import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.Constant;
import org.spongepowered.asm.mixin.injection.ModifyConstant;
@Mixin(BiomeIDs.class)
@Mixin(value = BiomeIDs.class,
remap = false)
public abstract class BiomeIDsMixin {
@ModifyConstant(method = "<clinit>",
constant = @Constant(intValue = 39),
@@ -6,7 +6,8 @@ import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.Constant;
import org.spongepowered.asm.mixin.injection.ModifyConstant;
@Mixin(BiomeGenSpace.class)
@Mixin(value = BiomeGenSpace.class,
remap = false)
public abstract class BiomeGenSpaceMixin {
@ModifyConstant(method = "<clinit>",
constant = @Constant(intValue = 97),
@@ -0,0 +1,86 @@
package com.falsepattern.endlessids.mixin.mixins.common.biome.ir3;
import com.falsepattern.endlessids.mixin.helpers.IChunkMixin;
import jp.plusplus.ir2.IR2;
import jp.plusplus.ir2.blocks.BlockCore;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.Overwrite;
import org.spongepowered.asm.mixin.Shadow;
import net.minecraft.init.Blocks;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenMinable;
import net.minecraft.world.gen.feature.WorldGenerator;
import net.minecraftforge.event.terraingen.OreGenEvent;
import net.minecraftforge.event.terraingen.TerrainGen;
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
@Mixin(value = IR2.class,
priority = 999,
remap = false)
public abstract class IR2Mixin {
@Shadow public static boolean oresAreGenerated;
@Shadow public static boolean generateTinOre;
@Shadow public static boolean generateCopperOre;
@Shadow public static boolean generateSilverOre;
@Shadow public static boolean generateManganeseCrust;
@Shadow public static boolean generateCobaltCrust;
/**
* @author FalsePattern
* @reason Compat
*/
@SubscribeEvent
@Overwrite
public void generateOrePre(OreGenEvent.Pre event) {
if (oresAreGenerated) {
WorldGenerator genTin = new WorldGenMinable(BlockCore.ore, 0, 8, Blocks.stone);
WorldGenerator genCopper = new WorldGenMinable(BlockCore.ore, 1, 8, Blocks.stone);
WorldGenerator genSilver = new WorldGenMinable(BlockCore.ore, 2, 8, Blocks.stone);
WorldGenerator genManganese = new WorldGenMinable(BlockCore.crust, 0, 16, Blocks.gravel);
WorldGenerator genCobalt = new WorldGenMinable(BlockCore.crust, 1, 16, Blocks.gravel);
if (generateTinOre && TerrainGen.generateOre(event.world, event.rand, genTin, event.worldX, event.worldZ, OreGenEvent.GenerateMinable.EventType.CUSTOM)) {
for(int i = 0; i < 14; ++i) {
genTin.generate(event.world, event.rand, event.worldX + event.rand.nextInt(16), 30 + event.rand.nextInt(20), event.worldZ + event.rand.nextInt(16));
}
}
if (generateCopperOre && TerrainGen.generateOre(event.world, event.rand, genCopper, event.worldX, event.worldZ, OreGenEvent.GenerateMinable.EventType.CUSTOM)) {
for(int i = 0; i < 10; ++i) {
genCopper.generate(event.world, event.rand, event.worldX + event.rand.nextInt(16), 20 + event.rand.nextInt(20), event.worldZ + event.rand.nextInt(16));
}
}
if (generateSilverOre && TerrainGen.generateOre(event.world, event.rand, genSilver, event.worldX, event.worldZ, OreGenEvent.GenerateMinable.EventType.CUSTOM)) {
for(int i = 0; i < 4; ++i) {
genSilver.generate(event.world, event.rand, event.worldX + event.rand.nextInt(16), 1 + event.rand.nextInt(29), event.worldZ + event.rand.nextInt(16));
}
}
short[] bIds = ((IChunkMixin)event.world.getChunkFromBlockCoords(event.worldX, event.worldZ)).getBiomeShortArray();
for(int k = 0; k < bIds.length; ++k) {
if (bIds[k] == BiomeGenBase.ocean.biomeID || bIds[k] == BiomeGenBase.deepOcean.biomeID) {
if (generateManganeseCrust && TerrainGen.generateOre(event.world, event.rand, genSilver, event.worldX, event.worldZ, OreGenEvent.GenerateMinable.EventType.CUSTOM)) {
for(int i = 0; i < 7; ++i) {
genManganese.generate(event.world, event.rand, event.worldX + event.rand.nextInt(16), 16 + event.rand.nextInt(48), event.worldZ + event.rand.nextInt(16));
}
}
if (generateCobaltCrust && TerrainGen.generateOre(event.world, event.rand, genSilver, event.worldX, event.worldZ, OreGenEvent.GenerateMinable.EventType.CUSTOM)) {
for(int i = 0; i < 7; ++i) {
genCobalt.generate(event.world, event.rand, event.worldX + event.rand.nextInt(16), 16 + event.rand.nextInt(48), event.worldZ + event.rand.nextInt(16));
}
}
break;
}
}
}
}
}
@@ -0,0 +1,39 @@
package com.falsepattern.endlessids.mixin.mixins.common.biome.restructured;
import com.falsepattern.endlessids.mixin.helpers.IChunkMixin;
import org.blockartistry.mod.Restructured.world.BiomeHelper;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.Overwrite;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.chunk.Chunk;
import java.util.Random;
@Mixin(value = BiomeHelper.class,
priority = 999,
remap = false)
public abstract class BiomeHelperMixin {
/**
* @author FalsePattern
* @reason Compat
*/
@Overwrite
public static BiomeGenBase chunkBiomeSurvey(World world, Chunk chunk, Random rand) {
short[] biomes = ((IChunkMixin)chunk).getBiomeShortArray();
int[] counts = new int[biomes.length];
int highIndex = BiomeGenBase.plains.biomeID;
int highCount = -1;
for(int i = 0; i < 32; ++i) {
int id = biomes[rand.nextInt(biomes.length)] & 65535;
if (id != 65535 && ++counts[id] > highCount) {
highIndex = id;
highCount = counts[id];
}
}
return BiomeGenBase.getBiome(highIndex);
}
}
@@ -12,7 +12,7 @@ import net.minecraft.network.PacketBuffer;
import java.io.IOException;
@Mixin(PacketBuffer.class)
@Mixin(value = PacketBuffer.class, priority = 999)
public abstract class PacketBufferMixin {
@Shadow
@@ -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"),
@@ -113,6 +116,9 @@ public enum Mixin implements IMixin {
//region ICG
ICGMysteriumPatchesFixesCaveMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.ICG)), "biome.icg.MysteriumPatchesFixesCaveMixin"),
//endregion ICG
//region Industrial Revolution by Redstone Rebooted
IR3IR2Mixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.IR3)), "biome.ir3.IR2Mixin"),
//endregion Industrial Revolution by Redstone Rebooted
//region LOTR
LOTRBiomeVariantStorageMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.LOTR)), "biome.lotr.LOTRBiomeVariantStorageMixin"),
LOTRChunkProviderMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.LOTR)), "biome.lotr.LOTRChunkProviderMixin"),
@@ -133,6 +139,9 @@ public enum Mixin implements IMixin {
ItemBiomePainterMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.RANDOMTHINGS)), "biome.randomthings.ItemBiomePainterMixin"),
MessagePaintBiomeMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.RANDOMTHINGS)), "biome.randomthings.MessagePaintBiomeMixin"),
//endregion RandomThings
//region Restructured
RSBiomeHelperMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.RESTRUCTURED)), "biome.restructured.BiomeHelperMixin"),
//endregion Restructured
//region RTG
RTGChunkProviderRTGMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.RTG)), "biome.rtg.ChunkProviderRTGMixin"),
RTGLandscapeGeneratorMixin(Side.COMMON, condition(() -> GeneralConfig.extendBiome).and(require(TargetedMod.RTG)), "biome.rtg.LandscapeGeneratorMixin"),
@@ -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-")),
@@ -34,12 +35,14 @@ public enum TargetedMod implements ITargetedMod {
GALAXYSPACE("GalaxySpace", false, startsWith("galaxyspace-")),
HIGHLANDS("Highlands", false, startsWith("highlands")),
ICG("Immersive Cavegen", false, startsWith("immersivecavegen")),
IR3("Industrial Revolution by Redstone Rebooted", false, startsWith("industrialrevolutionbyredstonerebooted-")),
LOTR("LOTR Mod", false, startsWith("lotrmod")),
MFQM("More Fun Quicksand Mod", false, startsWith("morefunquicksandmod-")),
NATURESCOMPASS("Nature's Compass", false, startsWith("naturescompass")),
NETHERLICIOUS("Netherlicious", false, startsWith("netherlicious-")),
NOMADICTENTS("Nomadic Tents", false, startsWith("nomadictents")),
RANDOMTHINGS("Random Things", false, startsWith("randomthings-")),
RESTRUCTURED("Restructured", false, startsWith("restructured-")),
RTG("Realistic Terrain Generation", false, startsWith("rtg-")),
RWG("Realistic World Gen", false, startsWith("rwg-")),
THAUMCRAFT("Thaumcraft", false, startsWith("thaumcraft")),
+1 -1
View File
@@ -3,7 +3,7 @@ EndlessIDs
Copyright (C) 2022 FalsePattern
All Rights Reserved
The above copyright notice, this permission notice and the word "SNEED"
The above copyright notice, this permission notice and the word "MEGA"
shall be included in all copies or substantial portions of the Software.
This program is free software: you can redistribute it and/or modify