-
-
Notifications
You must be signed in to change notification settings - Fork 339
Generalize recipes and implement them #1449
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Changes from all commits
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
8ba0ae6
refactor recipe interfaces
Limeth 9c7701f
fix license
Limeth 3c06bed
fix a NPE
Limeth 9614e90
add a getter for the smelting recipe registry to the GameRegistry
Limeth ec67f57
fix javadocs in RecipeRegistry
95c6ca1
improve javadocs of ShapedCraftingRecipe
03ee6e2
add missing spaces
83da10c
add missing spaces before braces
722d9e8
explain CraftingRecipe#getRecipeSize()
Limeth 5e3a284
added missing null-checks
Limeth 7c1bc39
move unnecessary implementation to SpongeCommon
Limeth 15c63c5
added a world parameter to CraftingRecipe methods
Limeth 83d9c96
fix various javadoc issues
d097751
remove unnecessary implementation
Limeth b759045
added CraftingResult
3e6a86f
builder improvements
6ad27ed
more builder improvements
ebfb0bf
make CraftingResult actually return ItemStackSnapshots, because it ne…
c4561f6
revert CraftingRecipe
0ebfe74
symmetry to nms
b5e0a3d
conflicting method
e628dad
create separate interfaces for recipe registries
d97cefd
make SmeltingRecipeRegistry actually extend RecipeRegistry
8b30232
remove the default implementation of ShapedCraftingRecipe#getSize()
Limeth f7a8356
satisfy @liach, mostly
Limeth 38b102d
remove @Nullable from ItemStackSnapshots
Limeth 6f4784f
interface improvements, remove unwanted @Nullables
Limeth 5d85b69
minor adjustments
Limeth 124a286
added a findMatchingRecipe method
Limeth 63b7ac6
implement smelting recipes
Limeth b84a8a7
PR adjustments
de99fc1
remove unnecessary @Nonnulls
Limeth 8f7d40b
No star imports.
Limeth 0ef092b
make getIngredientPredicate throw an exception if out of bounds
40b6241
expose various methods in recipe registries; reintroduce CraftingResult
ea6161b
implement equals/hashCode/toString in recipe result classes
Limeth 2b0ba2d
improve javadocs
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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
142 changes: 0 additions & 142 deletions
142
src/main/java/org/spongepowered/api/item/recipe/ShapedRecipe.java
This file was deleted.
Oops, something went wrong.
81 changes: 0 additions & 81 deletions
81
src/main/java/org/spongepowered/api/item/recipe/ShapelessRecipe.java
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if 'exemplary' makes sense here. What does this represent?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think its the item you see in the CraftingOutput before you take it out.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The native
IRecipeclass contains anItemStack getRecipeOutput(), where this value is used as the return value, and theFurnaceRecipesclass contains aMap<ItemStack, ItemStack> smeltingList, where this value is used as a value in the map. I think these might be used in TooManyItems/NotEnoughItems to display the recipes, that's why I chose the word 'exemplary'.