Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tinkers' Construct support #37

Merged
merged 32 commits into from
Mar 24, 2023
Merged
Show file tree
Hide file tree
Changes from 15 commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
3c35f2d
Basic tinkers support
Testure Mar 2, 2023
a8131ad
Move SmelteryFuelRecipe
Testure Mar 2, 2023
6def08a
Add entity melting
Testure Mar 2, 2023
ccc905b
Add casting
Testure Mar 3, 2023
c0d87fa
Add materials
Testure Mar 4, 2023
d588ce2
Fix ore dict
Testure Mar 5, 2023
6af1a3b
Merge branch 'CleanroomMC:master' into tinkers
Testure Mar 5, 2023
78c57e3
Improve melting recipes
Testure Mar 5, 2023
2294caa
Tinkers Complement support
Testure Mar 5, 2023
88025e3
Bracket handlers
Testure Mar 5, 2023
85f25d3
Disable tinkers debug
Testure Mar 5, 2023
048cee4
Use EntityEntry for entity melting
Testure Mar 6, 2023
5e3ebe0
Add validation to ToolMaterialBuilder
Testure Mar 6, 2023
658b574
General cleanup
Testure Mar 6, 2023
cedc1ad
Replace loader with events
Testure Mar 6, 2023
9729b8f
Remove trait builder
Testure Mar 6, 2023
7de5203
Update Melter.java
Testure Mar 6, 2023
93e8c38
Merge branch 'CleanroomMC:master' into tinkers
Testure Mar 6, 2023
7657506
Update GroovyScriptSandbox.java
Testure Mar 6, 2023
e8d6ae5
Allow custom material class
Testure Mar 6, 2023
eec9ca0
Manually call reload on nested registries
Testure Mar 9, 2023
656b5c1
Merge branch 'CleanroomMC:master' into tinkers
Testure Mar 10, 2023
e5175c8
Update GroovyScriptSandbox.java
Testure Mar 11, 2023
2a80ca1
Remove null check for bracket handlers
Testure Mar 11, 2023
096eeda
Fix repair amounts
Testure Mar 12, 2023
275d324
Run materials on item register
Testure Mar 13, 2023
71bd9e9
Fix traits
Testure Mar 17, 2023
132b0a5
Allow materials to be uncraftable
Testure Mar 17, 2023
864f208
Allow no cast for casting recipes
Testure Mar 19, 2023
024faf0
Merge branch 'CleanroomMC:master' into tinkers
Testure Mar 19, 2023
83c4f2b
Merge branch 'CleanroomMC:master' into tinkers
Testure Mar 20, 2023
d1405e4
Merge branch 'CleanroomMC:master' into tinkers
Testure Mar 24, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,18 @@ dependencies {
} else {
deobfProvided 'curse.maven:immersive_engineering-231951:2974106'
}

if (project.debug_tinkers.toBoolean()) {
deobfCompile 'slimeknights.mantle:Mantle:1.12-1.3.3.55'
deobfCompile 'slimeknights:TConstruct:1.12.2-2.13.0.190'
deobfCompile 'curse.maven:constructs-armory-287683:3174535'
deobfCompile 'curse.maven:tinkers-complement-272671:2843439'
} else {
deobfProvided 'slimeknights.mantle:Mantle:1.12-1.3.3.55'
deobfProvided 'slimeknights:TConstruct:1.12.2-2.13.0.190'
deobfProvided 'curse.maven:constructs-armory-287683:3174535'
deobfProvided 'curse.maven:tinkers-complement-272671:2843439'
}
}

sourceSets {
Expand Down
3 changes: 2 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,5 @@ debug_de = false
debug_ie = false
debug_enderio = false
debug_astral = false
debug_blood_magic = false
debug_blood_magic = false
debug_tinkers = false
15 changes: 12 additions & 3 deletions src/main/java/com/cleanroommc/groovyscript/GroovyScript.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import com.cleanroommc.groovyscript.command.GSCommand;
import com.cleanroommc.groovyscript.compat.content.GroovyResourcePack;
import com.cleanroommc.groovyscript.compat.mods.ModSupport;
import com.cleanroommc.groovyscript.compat.mods.tinkersconstruct.TinkersConstruct;
import com.cleanroommc.groovyscript.compat.vanilla.VanillaModule;
import com.cleanroommc.groovyscript.core.mixin.DefaultResourcePackAccessor;
import com.cleanroommc.groovyscript.event.EventHandler;
Expand Down Expand Up @@ -38,9 +39,7 @@
import net.minecraftforge.fml.client.registry.ClientRegistry;
import net.minecraftforge.fml.common.Loader;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.event.FMLConstructionEvent;
import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
import net.minecraftforge.fml.common.event.FMLServerStartingEvent;
import net.minecraftforge.fml.common.event.*;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import net.minecraftforge.fml.common.gameevent.InputEvent;
import org.apache.logging.log4j.LogManager;
Expand Down Expand Up @@ -107,6 +106,16 @@ public void onConstruction(FMLConstructionEvent event) {
}
}

@Mod.EventHandler
public void onInit(FMLInitializationEvent event) {
if (ModSupport.TINKERS_CONSTRUCT.isLoaded()) TinkersConstruct.init();
}

@Mod.EventHandler()
public void preInit(FMLPreInitializationEvent event) {
if (ModSupport.TINKERS_CONSTRUCT.isLoaded()) TinkersConstruct.preInit();
}

@ApiStatus.Internal
public static void initializeGroovyPreInit() {
// called via mixin in between construction and fml pre init
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import com.cleanroommc.groovyscript.compat.mods.immersiveengineering.ImmersiveEngineering;
import com.cleanroommc.groovyscript.compat.mods.jei.JustEnoughItems;
import com.cleanroommc.groovyscript.compat.mods.mekanism.Mekanism;
import com.cleanroommc.groovyscript.compat.mods.tcomplement.TinkersComplement;
import com.cleanroommc.groovyscript.compat.mods.thaumcraft.Thaumcraft;
import com.cleanroommc.groovyscript.compat.mods.thermalexpansion.ThermalExpansion;
import com.cleanroommc.groovyscript.compat.mods.tinkersconstruct.TinkersConstruct;
Expand Down Expand Up @@ -39,6 +40,7 @@ public class ModSupport implements IDynamicGroovyProperty {
public static final Container<Mekanism> MEKANISM = new Container<>("mekanism", "Mekanism", Mekanism::new);
public static final Container<ThermalExpansion> THERMAL_EXPANSION = new Container<>("thermalexpansion", "Thermal Expansion", ThermalExpansion::new, "te", "thermal");
public static final Container<TinkersConstruct> TINKERS_CONSTRUCT = new Container<>("tconstruct", "Tinkers' Construct", TinkersConstruct::new, "ticon", "tinkersconstruct");
public static final Container<TinkersComplement> TINKERS_COMPLEMENT = new Container<>("tcomplement", "Tinkers Complement", TinkersComplement::new, "tcomp", "tinkerscomplement");
public static final Container<DraconicEvolution> DRACONIC_EVO = new Container<>("draconicevolution", "Draconic Evolution", DraconicEvolution::new, "de");
public static final Container<BloodMagic> BLOOD_MAGIC = new Container<>("bloodmagic", "Blood Magic: Alchemical Wizardry", BloodMagic::new, "bm");
public static final Container<ImmersiveEngineering> IMMERSIVE_ENGINEERING = new Container<>("immersiveengineering", "Immersive Engineering", ImmersiveEngineering::new, "ie");
Expand Down
Loading