This commit is contained in:
kuba6000 committed 2023-04-30 23:07:11 +02:00
1 parent 68ac0d8b05
commit 25ae719ab9
36 files changed
+944 -43

No files matched your search

@@ -17,6 +17,7 @@ import minetweaker.api.item.IngredientAny;
import minetweaker.api.liquid.ILiquidStack;
import modtweaker2.helpers.LogHelper;
import modtweaker2.mods.tconstruct.TConstructHelper;
import modtweaker2.mods.thaumcraft.Thaumcraft;
import modtweaker2.utils.BaseListAddition;
import modtweaker2.utils.BaseListRemoval;
import stanhebben.zenscript.annotations.Optional;
@@ -68,6 +69,44 @@ public class Casting {
this.recipes.add(recipe);
}
@Override
public void apply() {
super.apply();
if (!successful.isEmpty()) {
for (CastingRecipe recipe : successful) {
if (list == TConstructHelper.basinCasting) {
Thaumcraft.info(
"TConstructRegistry.getBasinCasting().addCastingRecipe("
+ Thaumcraft.convertStack(recipe.output)
+ ", "
+ Thaumcraft.convertFluidStack(recipe.castingMetal)
+ ", "
+ Thaumcraft.convertStack(recipe.cast)
+ ", "
+ (recipe.consumeCast ? "true" : "false")
+ ", "
+ recipe.coolTime
+ ");");
} else if (list == TConstructHelper.tableCasting) {
Thaumcraft.info(
"TConstructRegistry.getTableCasting().addCastingRecipe("
+ Thaumcraft.convertStack(recipe.output)
+ ", "
+ Thaumcraft.convertFluidStack(recipe.castingMetal)
+ ", "
+ Thaumcraft.convertStack(recipe.cast)
+ ", "
+ (recipe.consumeCast ? "true" : "false")
+ ", "
+ recipe.coolTime
+ ");");
}
}
}
}
@Override
protected String getRecipeInfo(CastingRecipe recipe) {
return LogHelper.getStackDescription(recipe.output);
@@ -144,6 +183,23 @@ public class Casting {
super(Casting.name, list, recipes);
}
@Override
public void apply() {
super.apply();
if (!successful.isEmpty()) {
for (CastingRecipe recipe : successful) {
if (list == TConstructHelper.basinCasting) {
Thaumcraft.info(
"TConstructHelper.removeBasinRecipe(" + Thaumcraft.convertStack(recipe.output) + ");");
} else if (list == TConstructHelper.tableCasting) {
Thaumcraft.info(
"TConstructHelper.removeTableRecipe(" + Thaumcraft.convertStack(recipe.output) + ");");
}
}
}
}
@Override
protected String getRecipeInfo(CastingRecipe recipe) {
return LogHelper.getStackDescription(recipe.output);