-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- theoretically fix issues with ovens not persisting recipes
- allow heat recipes to happen in ovens - fix issues with firmalife metals not being pileable and not going in molds - fix jack o lanterns to match tfc - update hangers/shelves to be better than vessels - added better oven tooltip
- Loading branch information
1 parent
8e95921
commit 8eba7c8
Showing
29 changed files
with
145 additions
and
113 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
54 changes: 0 additions & 54 deletions
54
src/main/java/com/eerussianguy/firmalife/common/blocks/BottomSupportedDeviceBlock.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 0 additions & 30 deletions
30
src/main/java/com/eerussianguy/firmalife/common/blocks/FLJackOLanternBlock.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
45 changes: 45 additions & 0 deletions
45
src/main/java/com/eerussianguy/firmalife/common/recipes/WrappedHeatingRecipe.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
package com.eerussianguy.firmalife.common.recipes; | ||
|
||
import java.util.function.Function; | ||
|
||
import net.minecraft.resources.ResourceLocation; | ||
import net.minecraft.world.item.ItemStack; | ||
|
||
import net.dries007.tfc.common.recipes.HeatingRecipe; | ||
import net.dries007.tfc.common.recipes.inventory.ItemStackInventory; | ||
import org.jetbrains.annotations.Nullable; | ||
|
||
public record WrappedHeatingRecipe(ResourceLocation id, Function<ItemStackInventory, ItemStack> output, float temperature, int duration, boolean oven) | ||
{ | ||
@Nullable | ||
public static WrappedHeatingRecipe getRecipe(ItemStack stack) | ||
{ | ||
OvenRecipe recipe = OvenRecipe.getRecipe(stack); | ||
if (recipe != null) | ||
{ | ||
return of(recipe); | ||
} | ||
HeatingRecipe heatRecipe = HeatingRecipe.getRecipe(stack); | ||
return heatRecipe == null ? null : of(heatRecipe); | ||
} | ||
|
||
public static WrappedHeatingRecipe of(HeatingRecipe recipe) | ||
{ | ||
return new WrappedHeatingRecipe(recipe.getId(), recipe::assemble, recipe.getTemperature(), 120, false); | ||
} | ||
|
||
public static WrappedHeatingRecipe of(OvenRecipe recipe) | ||
{ | ||
return new WrappedHeatingRecipe(recipe.getId(), recipe::assemble, recipe.getTemperature(), recipe.getDuration(), true); | ||
} | ||
|
||
public boolean isValidTemperature(float temperature) | ||
{ | ||
return temperature >= this.temperature; | ||
} | ||
|
||
public ItemStack assemble(ItemStackInventory inventory) | ||
{ | ||
return output.apply(inventory); | ||
} | ||
} |
Oops, something went wrong.