-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move all REI code into REI package for safety
- Loading branch information
1 parent
2e9efe3
commit 734c022
Showing
10 changed files
with
71 additions
and
52 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
* Fix recipe serialization not working on dedicated servers | ||
* Make barrel recipe abort if connections change | ||
* Make barrel recipe abort if connections change | ||
* Make rei compat code slightly more safe |
19 changes: 19 additions & 0 deletions
19
src/main/java/wraith/fabricaeexnihilo/compatibility/rei/ReiIngredientUtil.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,19 @@ | ||
package wraith.fabricaeexnihilo.compatibility.rei; | ||
|
||
import me.shedaniel.rei.api.common.entry.EntryIngredient; | ||
import me.shedaniel.rei.api.common.util.EntryIngredients; | ||
import me.shedaniel.rei.api.common.util.EntryStacks; | ||
import wraith.fabricaeexnihilo.recipe.util.BlockIngredient; | ||
import wraith.fabricaeexnihilo.recipe.util.FluidIngredient; | ||
|
||
public class ReiIngredientUtil { | ||
private ReiIngredientUtil() {} | ||
|
||
public static EntryIngredient of(FluidIngredient fluid) { | ||
return fluid.getValue().map(EntryIngredients::of, EntryIngredients::ofFluidTag); | ||
} | ||
|
||
public static EntryIngredient of(BlockIngredient fluid) { | ||
return fluid.getValue().map(EntryIngredients::of, tag -> EntryIngredients.ofTag(tag, entry -> EntryStacks.of(entry.value()))); | ||
} | ||
} |
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
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