Skip to content

Commit

Permalink
Post-merge fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
malte0811 committed Mar 31, 2024
1 parent aba8fe7 commit 5146778
Show file tree
Hide file tree
Showing 66 changed files with 1,734 additions and 1,648 deletions.
7 changes: 1 addition & 6 deletions changelog.json
@@ -1,11 +1,6 @@
{
"homepage": "https://minecraft.curseforge.com/projects/immersive-engineering",
"promos": {
"1.20.1-latest": "1.20.1-10.1.0-171",
"1.20.1-recommended": "1.20.1-10.1.0-171"
},
"1.20.1": {
"1.20.1-10.0.0-169": "- First release for 1.20.1, now supporting NeoForged!\n- Includes all features from 9.4.1\n- Add sawmill support for stripped wood (BluSunrize)\n- Add sawmill support for cherry wood (BluSunrize)\n- Add cloche support for torchflowers (BluSunrize)\n- Change hemp blocks to extend vanilla's CropBlock (BluSunrize)",
"1.20.1-10.1.0-171": "- Includes all features from 9.2.4\n- Add sounds for Arc Furnace, Excavator, and Automated Workbench (voidsong-dragonfly)\n- Add burn times for the diesel generator to the manual (BluSunrize)\n- Add support for armor trims on steel armor (BluSunrize)\n- Add additional uses for lead & nickel (voidsong-dragonfly)\n - Lead can be crafted into red and white dyes\n - Radiators now use constantan instead of copper\n - Tinted glass can be made in larger quantities by using lead\n- Add randomized textures for various hempcrete & concrete blocks (voidsong-dragonfly)\n- Add the electromagnet block (BluSunrize)\n - It attracts nearby items when given power! \n- Add the portable electromagnet! (BluSunrize)\n - Install it as an upgrade on your accumulator backpack to have a magnet on the go!\n- Add various blocks from Engineer's Decor (voidsong-dragonfly)\n - Thank you wilechaote for giving us permission to include these blocks in the mod <3\n- Add additional fertilizers for the cloche (voidsong-dragonfly)\n - This should allow people to use up their surplus suflur!\n- Add ability to place Engineer's Manual in a chiseled bookshelf (BluSunrize)\n- Add sawmill recipes for bamboo (BluSunrize)\n- Change hemp blocks to notify their neighbours when they grow (jrtc27)\n- Change Jade Tooltips for multiblocks to work when looking at any part of the machine (HermitOwO)\n- Fix conveyor rendering in the manual (Malte)\n- Fix broken translation keys (Malte & BluSunrize)\n- Fix turret GUI textfield not being editable (BluSunrize)\n- Fix taiga villager houses being surrounded by air blocks (BluSunrize)\n- Fix redstone control not working on the assembler (BluSunrize)\n- Fix villager names not being translated in JER and EMI (BluSunrize)\n- Fix error related to deprecated unicode font (BluSunrize)\n- Fix bottling machine deleting items on the conveyor (BluSunrize)\n- Fix bottling machine not rendering bucket-filling recipes properly (BluSunrize)\n- Fix hemp replacing blocks above it when growing (BluSunrize)\n- Fix fluid pipes losing their colour because the chunk wasn't marked as dirty (BluSunrize)\n- Fix transparency issues with the shield and a few other item models (BluSunrize)\n- Fix spawn interdiction from lanterns not working (BluSunrize)\n- Fix rare crash in arc recycling calculation (BluSunrize)\n- Fix possible crash in conveyor rendering (BluSunrize)\n- Translations Added/Updated: ja_jo (karakufire)"

}
}
Expand Up @@ -8,10 +8,11 @@

package blusunrize.immersiveengineering.data.recipes;

import blusunrize.immersiveengineering.api.crafting.ClocheFertilizer;
import blusunrize.immersiveengineering.api.IETags;
import blusunrize.immersiveengineering.client.utils.ClocheRenderFunctions.*;
import blusunrize.immersiveengineering.common.register.IEItems.Ingredients;
import blusunrize.immersiveengineering.common.register.IEItems.Misc;
import blusunrize.immersiveengineering.data.recipes.builder.ClocheFertilizerBuilder;
import blusunrize.immersiveengineering.data.recipes.builder.ClocheRecipeBuilder;
import net.minecraft.data.PackOutput;
import net.minecraft.data.recipes.RecipeOutput;
Expand All @@ -33,12 +34,7 @@ public ClocheRecipes(PackOutput p_248933_)
@Override
protected void buildRecipes(RecipeOutput out)
{
out.accept(
toRL("fertilizer/bone_meal"), new ClocheFertilizer(Ingredient.of(Items.BONE_MEAL), 1.25f), null
);
out.accept(
toRL("fertilizer/fertilizer"), new ClocheFertilizer(Ingredient.of(Misc.FERTILIZER), 1.25f), null
);
fertilizers(out);

simpleCrops(out);
stemCrops(out);
Expand All @@ -56,6 +52,33 @@ protected void buildRecipes(RecipeOutput out)
flowers(out);
}

private void fertilizers(RecipeOutput out)
{
//Minor nutrients are 10% boost (calcium, magnesium, sulfur), major nutrients are 20% (phosphorous, nitrogen, potassium)
//Single-nutrient fertilizers:
ClocheFertilizerBuilder.builder(1.10f)
.input(IETags.sulfurDust)
.build(out, toRL("fertilizer/sulfur"));
//Dual-nutrient fertilizers:
//Slag: Phosphorous, Calcium
ClocheFertilizerBuilder.builder(1.30f)
.input(IETags.slag)
.build(out, toRL("fertilizer/slag"));
//Nitrate: Nitrogen, no Potassium because it can be many things including sodium - and the recipe is closest to Chilean saltpeter (NaNO3)
ClocheFertilizerBuilder.builder(1.20f)
.input(IETags.saltpeterDust)
.build(out, toRL("fertilizer/saltpeter"));
//Bonemeal: Calcium, Phosphorous
ClocheFertilizerBuilder.builder(1.30f)
.input(Items.BONE_MEAL)
.build(out, toRL("fertilizer/bonemeal"));
//Quad-nutrient fertilizers:
//Industrial Fertilizer: Nitrogen, Phosphorous, Sulfur, Calcium
ClocheFertilizerBuilder.builder(1.60f)
.input(Misc.FERTILIZER)
.build(out, toRL("fertilizer/fertilizer"));
}

private void flowers(RecipeOutput out)
{
flower(out, Blocks.RED_TULIP);
Expand Down
Expand Up @@ -169,6 +169,29 @@ private void stoneDecoration(RecipeOutput out)
makeIngredient(Tags.Items.INGOTS_BRICK),
makeIngredient(Blocks.MAGMA_BLOCK),
has(Tags.Items.INGOTS_BRICK), out);
ShapedRecipeBuilder.shaped(RecipeCategory.MISC, StoneDecoration.SLAG_BRICK, 4)
.pattern("ss")
.pattern("ss")
.define('s', IETags.slag)
.unlockedBy("has_slag", has(IETags.slag))
.save(out, toRL(toPath(StoneDecoration.SLAG_BRICK)));
SimpleCookingRecipeBuilder.smoking(Ingredient.of(Blocks.BRICKS), RecipeCategory.MISC, StoneDecoration.CLINKER_BRICK, 0.1f, standardSmeltingTime)
.unlockedBy("has_bricks", has(Blocks.BRICKS))
.save(out, toRL("smoking/"+toPath(StoneDecoration.CLINKER_BRICK)));
ShapedRecipeBuilder.shaped(RecipeCategory.MISC, StoneDecoration.CLINKER_BRICK_QUOIN, 4)
.pattern("tb")
.pattern("bb")
.define('t', Blocks.WHITE_TERRACOTTA)
.define('b', StoneDecoration.CLINKER_BRICK)
.unlockedBy("has_bricks", has(Blocks.BRICKS))
.save(out, toRL(toPath(StoneDecoration.CLINKER_BRICK_QUOIN)));
ShapedRecipeBuilder.shaped(RecipeCategory.MISC, StoneDecoration.CLINKER_BRICK_SILL, 4)
.pattern("tt")
.pattern("bb")
.define('t', Blocks.WHITE_TERRACOTTA)
.define('b', StoneDecoration.CLINKER_BRICK)
.unlockedBy("has_bricks", has(Blocks.BRICKS))
.save(out, toRL(toPath(StoneDecoration.CLINKER_BRICK_SILL)));
addSandwich(StoneDecoration.HEMPCRETE, 6,
makeIngredient(IETags.clay),
makeIngredient(IETags.fiberHemp),
Expand All @@ -188,13 +211,25 @@ private void stoneDecoration(RecipeOutput out)
.save(out, toRL(toPath(StoneDecoration.HEMPCRETE_PILLAR)));
add3x3Conversion(StoneDecoration.COKE, IEItems.Ingredients.COAL_COKE, IETags.coalCoke, out);

addStairs(StoneDecoration.SLAG_BRICK, out);
addStairs(StoneDecoration.CLINKER_BRICK, out);
addStairs(StoneDecoration.HEMPCRETE, out);
addStairs(StoneDecoration.HEMPCRETE_BRICK, out);
addStairs(StoneDecoration.CONCRETE, out);
addStairs(StoneDecoration.CONCRETE_BRICK, out);
addStairs(StoneDecoration.CONCRETE_TILE, out);
addStairs(StoneDecoration.CONCRETE_LEADED, out);

addWall(StoneDecoration.SLAG_BRICK, out);
addWall(StoneDecoration.CLINKER_BRICK, out);

addStonecuttingRecipe(Ingredients.SLAG, StoneDecoration.SLAG_BRICK, out);
addStonecuttingRecipe(StoneDecoration.SLAG_BRICK, IEBlocks.TO_SLAB.get(StoneDecoration.SLAG_BRICK.getId()), 2, out);
addStonecuttingRecipe(StoneDecoration.SLAG_BRICK, IEBlocks.TO_STAIRS.get(StoneDecoration.SLAG_BRICK.getId()), out);
addStonecuttingRecipe(StoneDecoration.SLAG_BRICK, IEBlocks.TO_WALL.get(StoneDecoration.SLAG_BRICK.getId()), out);
addStonecuttingRecipe(StoneDecoration.CLINKER_BRICK, IEBlocks.TO_SLAB.get(StoneDecoration.CLINKER_BRICK.getId()), 2, out);
addStonecuttingRecipe(StoneDecoration.CLINKER_BRICK, IEBlocks.TO_STAIRS.get(StoneDecoration.CLINKER_BRICK.getId()), out);
addStonecuttingRecipe(StoneDecoration.CLINKER_BRICK, IEBlocks.TO_WALL.get(StoneDecoration.CLINKER_BRICK.getId()), out);
addStonecuttingRecipe(StoneDecoration.HEMPCRETE, IEBlocks.TO_SLAB.get(StoneDecoration.HEMPCRETE.getId()), 2, out);
addStonecuttingRecipe(StoneDecoration.HEMPCRETE, IEBlocks.TO_STAIRS.get(StoneDecoration.HEMPCRETE.getId()), out);
addStonecuttingRecipe(StoneDecoration.HEMPCRETE_BRICK, IEBlocks.TO_SLAB.get(StoneDecoration.HEMPCRETE_BRICK.getId()), 2, out);
Expand Down Expand Up @@ -225,7 +260,7 @@ private void stoneDecoration(RecipeOutput out)
.unlockedBy("has_concrete", has(StoneDecoration.CONCRETE))
.save(out, toRL("smelting/"+toPath(StoneDecoration.CONCRETE_BRICK_CRACKED)));
SimpleCookingRecipeBuilder.smelting(Ingredient.of(StoneDecoration.HEMPCRETE_BRICK), RecipeCategory.MISC, StoneDecoration.HEMPCRETE_BRICK_CRACKED, 0.1f, standardSmeltingTime)
.unlockedBy("has_hempcrete", has(StoneDecoration.CONCRETE))
.unlockedBy("has_hempcrete", has(StoneDecoration.HEMPCRETE))
.save(out, toRL("smelting/"+toPath(StoneDecoration.HEMPCRETE_BRICK_CRACKED)));

SimpleCookingRecipeBuilder.smelting(Ingredient.of(IETags.slag), RecipeCategory.MISC, StoneDecoration.SLAG_GLASS, 0.1f, standardSmeltingTime)
Expand Down
Expand Up @@ -9,6 +9,7 @@
package blusunrize.immersiveengineering.data.recipes;

import blusunrize.immersiveengineering.api.IEApi;
import blusunrize.immersiveengineering.common.register.IEBlocks;
import net.minecraft.advancements.Criterion;
import net.minecraft.core.registries.BuiltInRegistries;
import net.minecraft.data.PackOutput;
Expand Down Expand Up @@ -163,6 +164,17 @@ protected void addSandwich(ItemLike output, int count, Ingredient top, Ingredien
.save(out, toRL(toPath(output)));
}

protected void addWall(ItemLike block, RecipeOutput out)
{
ItemLike wall = IEBlocks.TO_WALL.get(BuiltInRegistries.ITEM.getKey(block.asItem()));
shapedMisc(wall, 6)
.define('s', block)
.pattern("sss")
.pattern("sss")
.unlockedBy("has_"+toPath(block), has(block))
.save(out, toRL(toPath(wall)));
}

protected void addStonecuttingRecipe(ItemLike input, ItemLike output, RecipeOutput out)
{
addStonecuttingRecipe(input, output, 1, out);
Expand Down
Expand Up @@ -26,11 +26,10 @@
import blusunrize.immersiveengineering.common.items.BulletItem;
import blusunrize.immersiveengineering.common.register.IEBannerPatterns;
import blusunrize.immersiveengineering.common.register.IEBlocks;
import blusunrize.immersiveengineering.common.register.IEBlocks.Cloth;
import blusunrize.immersiveengineering.common.register.IEBlocks.MetalDecoration;
import blusunrize.immersiveengineering.common.register.IEBlocks.MetalDevices;
import blusunrize.immersiveengineering.common.register.IEBlocks.WoodenDevices;
import blusunrize.immersiveengineering.common.register.IEBlocks.*;
import blusunrize.immersiveengineering.common.register.IEFluids;
import blusunrize.immersiveengineering.common.register.IEItems.Metals;
import blusunrize.immersiveengineering.common.register.IEItems.Misc;
import blusunrize.immersiveengineering.common.register.IEItems.*;
import blusunrize.immersiveengineering.common.util.ItemNBTHelper;
import blusunrize.immersiveengineering.data.recipes.builder.BlueprintCraftingRecipeBuilder;
Expand Down Expand Up @@ -738,10 +737,14 @@ private void recipesMisc(RecipeOutput out)
.define('W', ItemTags.WOOL)
.unlockedBy("has_iron_rod", has(IETags.ironRod))
.save(out, toRL(toPath(Misc.EARMUFFS)));
shapelessMisc(Misc.FERTILIZER)
shapelessMisc(Misc.FERTILIZER, 3)
.requires(IETags.saltpeterDust)
.requires(IETags.slag)
.requires(IETags.sulfurDust)
.requires(new IngredientFluidStack(FluidTags.WATER, FluidType.BUCKET_VOLUME))
.unlockedBy("has_saltpeter", has(IETags.saltpeterDust))
.unlockedBy("has_sulfur", has(IETags.sulfurDust))
.unlockedBy("has_slag", has(IETags.slag))
.save(out, toRL(toPath(Misc.FERTILIZER)));

shapedMisc(MetalDecoration.LANTERN)
Expand Down Expand Up @@ -782,6 +785,12 @@ private void recipesMisc(RecipeOutput out)
.define('C', Items.MINECART)
.unlockedBy("has_minecart", has(Items.MINECART))
.save(out, toRL(toPath(Minecarts.CART_METAL_BARREL)));
shapelessMisc(StoneDecoration.GRIT_SAND, 5)
.requires(Ingredient.of(Tags.Items.GRAVEL), 1)
.requires(Ingredient.of(Tags.Items.SAND_COLORLESS), 4)
.unlockedBy("has_sand", has(Tags.Items.GRAVEL))
.unlockedBy("has_gravel", has(Tags.Items.SAND_COLORLESS))
.save(out, toRL("grit_sand"));

//Lead to dye recipes
shapelessMisc(Items.WHITE_DYE, 16)
Expand Down
Expand Up @@ -362,7 +362,7 @@ private void sawmill(RecipeOutput out)
if(wood.getLog()!=null)
{
SawmillRecipeBuilder sawmillBuilder = SawmillRecipeBuilder.builder()
.output(wood.getPlank(), 6)
.output(wood.getPlank(), wood.plankCount())
.input(wood.getLog())
.setEnergy(1600);
if(wood.getStripped()!=null)
Expand All @@ -379,7 +379,7 @@ private void sawmill(RecipeOutput out)
if(wood.getWood()!=null)
{
var sawmillBuilder = SawmillRecipeBuilder.builder()
.output(wood.getPlank(), 6)
.output(wood.getPlank(), wood.plankCount())
.input(wood.getWood())
.setEnergy(1600);
if(wood.getStrippedWood()!=null)
Expand All @@ -396,7 +396,7 @@ private void sawmill(RecipeOutput out)
if(wood.getStripped()!=null)
{
var sawmillBuilder = SawmillRecipeBuilder.builder()
.output(wood.getPlank(), 6)
.output(wood.getPlank(), wood.plankCount())
.setEnergy(800);
if(wood.getWood()!=null)
sawmillBuilder.input(Ingredient.of(wood.getStripped(), wood.getStrippedWood()));
Expand Down
@@ -0,0 +1,44 @@
/*
* BluSunrize
* Copyright (c) 2024
*
* This code is licensed under "Blu's License of Common Sense"
* Details can be found in the license file in the root folder of this project
*/

package blusunrize.immersiveengineering.data.recipes.builder;

import blusunrize.immersiveengineering.api.crafting.ClocheFertilizer;
import blusunrize.immersiveengineering.data.recipes.builder.BaseHelpers.UnsizedItemInput;
import net.minecraft.data.recipes.RecipeOutput;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.world.item.crafting.Ingredient;

public class ClocheFertilizerBuilder extends IERecipeBuilder<ClocheFertilizerBuilder>
implements UnsizedItemInput<ClocheFertilizerBuilder>
{
private Ingredient input;
private final float modifier;

private ClocheFertilizerBuilder(float modifier)
{
this.modifier = modifier;
}

public static ClocheFertilizerBuilder builder(float modifier)
{
return new ClocheFertilizerBuilder(modifier);
}

@Override
public ClocheFertilizerBuilder input(Ingredient input)
{
this.input = input;
return this;
}

public void build(RecipeOutput out, ResourceLocation name)
{
out.accept(name, new ClocheFertilizer(input, modifier), null, getConditions());
}
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 5146778

Please sign in to comment.