Skip to content

Commit

Permalink
Merge remote-tracking branch 'Gordon-Frohman/master' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
Dream-Master committed Jun 20, 2024
2 parents d64e6f6 + ac19cb0 commit ddcdfc6
Show file tree
Hide file tree
Showing 4 changed files with 72 additions and 55 deletions.
2 changes: 2 additions & 0 deletions src/main/java/twilightforest/TwilightForestMod.java
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ public class TwilightForestMod {
public static String portalCreationItemString;

// integration
public static boolean isGTNHLoaded = false;
public static boolean isSkinportLoaded = false;
public static boolean areBaublesLoaded = false;
public static boolean isNeiLoaded = false;
Expand Down Expand Up @@ -255,6 +256,7 @@ public void preInit(FMLPreInitializationEvent event) {
} else {
areBaublesLoaded = false;
}
isGTNHLoaded = Loader.isModLoaded("dreamcraft");

// check for biome conflicts, load biomes
TFBiomeBase.assignBlankBiomeIds();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,29 +46,11 @@ public static boolean renderGlowingEdgeBlock(RenderBlocks renderblocks, IBlockAc
float m = (1.0f - p) / 2;
float s = 0.001f;

renderblocks.enableAO = true;

renderblocks.aoBrightnessXYNP = 255;
renderblocks.aoBrightnessXYPP = 255;
renderblocks.aoBrightnessYZPN = 255;
renderblocks.aoBrightnessYZPP = 255;
renderblocks.aoLightValueScratchXYNP = 1.0F;
renderblocks.aoLightValueScratchXYPP = 1.0F;
renderblocks.aoLightValueScratchYZPN = 1.0F;
renderblocks.aoLightValueScratchYZPP = 1.0F;

renderblocks.aoLightValueScratchXYZNPN = renderblocks.aoLightValueScratchXYNP;
renderblocks.aoBrightnessXYZNPN = renderblocks.aoBrightnessXYNP;
renderblocks.aoLightValueScratchXYZPPN = renderblocks.aoLightValueScratchXYPP;
renderblocks.aoBrightnessXYZPPN = renderblocks.aoBrightnessXYPP;
renderblocks.aoLightValueScratchXYZNPP = renderblocks.aoLightValueScratchXYNP;
renderblocks.aoBrightnessXYZNPP = renderblocks.aoBrightnessXYNP;
renderblocks.aoLightValueScratchXYZPPP = renderblocks.aoLightValueScratchXYPP;
renderblocks.aoBrightnessXYZPPP = renderblocks.aoBrightnessXYPP;
Tessellator tessellator = Tessellator.instance;
tessellator.setBrightness(15 << 20 | 15 << 4); // full brightness
tessellator.setColorOpaque_F(1.0f, 1.0f, 1.0f);

renderblocks.colorRedTopLeft = renderblocks.colorRedBottomLeft = renderblocks.colorRedBottomRight = renderblocks.colorRedTopRight = 1.0f;
renderblocks.colorGreenTopLeft = renderblocks.colorGreenBottomLeft = renderblocks.colorGreenBottomRight = renderblocks.colorGreenTopRight = 1.0f;
renderblocks.colorBlueTopLeft = renderblocks.colorBlueBottomLeft = renderblocks.colorBlueBottomRight = renderblocks.colorBlueTopRight = 1.0f;
renderblocks.enableAO = false;

// middle
renderblocks.renderAllFaces = true;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,34 @@ public static void registerTinkersConstructIntegration(FMLPostInitializationEven
}
}

// Fiery armor casting
if (!TwilightForestMod.isGTNHLoaded) {
tableCasting.addCastingRecipe(
new ItemStack(TFItems.fieryHelm),
new FluidStack(fieryEssenceFluid, TConstruct.ingotLiquidValue * 5),
new ItemStack(Items.iron_helmet, 1, 0),
true,
50);
tableCasting.addCastingRecipe(
new ItemStack(TFItems.fieryPlate),
new FluidStack(fieryEssenceFluid, TConstruct.ingotLiquidValue * 8),
new ItemStack(Items.iron_chestplate, 1, 0),
true,
50);
tableCasting.addCastingRecipe(
new ItemStack(TFItems.fieryLegs),
new FluidStack(fieryEssenceFluid, TConstruct.ingotLiquidValue * 7),
new ItemStack(Items.iron_leggings, 1, 0),
true,
50);
tableCasting.addCastingRecipe(
new ItemStack(TFItems.fieryBoots),
new FluidStack(fieryEssenceFluid, TConstruct.ingotLiquidValue * 4),
new ItemStack(Items.iron_boots, 1, 0),
true,
50);
}

// Fluids registry
fluids[0] = fieryEssenceFluid;
fluids[1] = moltenFieryMetalFluid;
Expand Down
71 changes: 38 additions & 33 deletions src/main/java/twilightforest/item/TFRecipes.java
Original file line number Diff line number Diff line change
Expand Up @@ -128,24 +128,27 @@ public static void registerRecipes() {
TFBlocks.trappedChestMangrove, TFBlocks.trappedChestDarkwood, TFBlocks.trappedChestTime,
TFBlocks.trappedChestTrans, TFBlocks.trappedChestMine, TFBlocks.trappedChestSort };
for (int i = 0; i < doors.length; i++) {
GameRegistry.addRecipe(
new ItemStack(doors[i], 1, 0),
new Object[] { "##", "##", "##", '#', new ItemStack(TFBlocks.planks, 1, i) });
GameRegistry
.addRecipe(trapdoors[i], new Object[] { "###", "###", '#', new ItemStack(TFBlocks.planks, 1, i) });
if (!TwilightForestMod.isGTNHLoaded) {
GameRegistry.addRecipe(
new ItemStack(doors[i], 1, 0),
new Object[] { "##", "##", "##", '#', new ItemStack(TFBlocks.planks, 1, i) });
GameRegistry.addRecipe(
trapdoors[i],
new Object[] { "###", "###", '#', new ItemStack(TFBlocks.planks, 1, i) });
GameRegistry.addRecipe(
new ItemStack(chests[i], 2),
new Object[] { "###", "#0#", "###", '#', new ItemStack(TFBlocks.planks, 1, i), '0',
new ItemStack(Blocks.chest) });
GameRegistry.addShapelessRecipe(
new ItemStack(trappedChests[i]),
new Object[] { new ItemStack(chests[i]), new ItemStack(Blocks.tripwire_hook) });
}
GameRegistry.addRecipe(
stairs[i],
new Object[] { "# ", "## ", "###", '#', new ItemStack(TFBlocks.planks, 1, i) });
GameRegistry.addRecipe(
new ItemStack(TFBlocks.woodenSlab, 6, i),
new Object[] { "###", '#', new ItemStack(TFBlocks.planks, 1, i) });
GameRegistry.addRecipe(
new ItemStack(chests[i], 2),
new Object[] { "###", "#0#", "###", '#', new ItemStack(TFBlocks.planks, 1, i), '0',
new ItemStack(Blocks.chest) });
GameRegistry.addShapelessRecipe(
new ItemStack(trappedChests[i]),
new Object[] { new ItemStack(chests[i]), new ItemStack(Blocks.tripwire_hook) });
}

// Dyes from TF plants
Expand Down Expand Up @@ -355,27 +358,29 @@ public static void registerRecipes() {
.addRecipe(new ItemStack(TFItems.fieryBoots), new Object[] { "# #", "# #", '#', TFItems.fieryIngot });

// Direct Fiery armor crafting
GameRegistry.addRecipe(
new ShapelessOreRecipe(
new ItemStack(TFItems.fieryHelm),
new Object[] { new ItemStack(Items.iron_helmet, 1, 0), "fieryEssence", "fieryEssence",
"fieryEssence", "fieryEssence", "fieryEssence" }));
GameRegistry.addRecipe(
new ShapelessOreRecipe(
new ItemStack(TFItems.fieryPlate),
new Object[] { new ItemStack(Items.iron_chestplate, 1, 0), "fieryEssence", "fieryEssence",
"fieryEssence", "fieryEssence", "fieryEssence", "fieryEssence", "fieryEssence",
"fieryEssence" }));
GameRegistry.addRecipe(
new ShapelessOreRecipe(
new ItemStack(TFItems.fieryLegs),
new Object[] { new ItemStack(Items.iron_leggings, 1, 0), "fieryEssence", "fieryEssence",
"fieryEssence", "fieryEssence", "fieryEssence", "fieryEssence", "fieryEssence" }));
GameRegistry.addRecipe(
new ShapelessOreRecipe(
new ItemStack(TFItems.fieryBoots),
new Object[] { new ItemStack(Items.iron_boots, 1, 0), "fieryEssence", "fieryEssence",
"fieryEssence", "fieryEssence" }));
if (!TwilightForestMod.isGTNHLoaded) {
GameRegistry.addRecipe(
new ShapelessOreRecipe(
new ItemStack(TFItems.fieryHelm),
new Object[] { new ItemStack(Items.iron_helmet, 1, 0), "fieryEssence", "fieryEssence",
"fieryEssence", "fieryEssence", "fieryEssence" }));
GameRegistry.addRecipe(
new ShapelessOreRecipe(
new ItemStack(TFItems.fieryPlate),
new Object[] { new ItemStack(Items.iron_chestplate, 1, 0), "fieryEssence", "fieryEssence",
"fieryEssence", "fieryEssence", "fieryEssence", "fieryEssence", "fieryEssence",
"fieryEssence" }));
GameRegistry.addRecipe(
new ShapelessOreRecipe(
new ItemStack(TFItems.fieryLegs),
new Object[] { new ItemStack(Items.iron_leggings, 1, 0), "fieryEssence", "fieryEssence",
"fieryEssence", "fieryEssence", "fieryEssence", "fieryEssence", "fieryEssence" }));
GameRegistry.addRecipe(
new ShapelessOreRecipe(
new ItemStack(TFItems.fieryBoots),
new Object[] { new ItemStack(Items.iron_boots, 1, 0), "fieryEssence", "fieryEssence",
"fieryEssence", "fieryEssence" }));
}

addEnchantedRecipe(
TFItems.fierySword,
Expand Down

0 comments on commit ddcdfc6

Please sign in to comment.