Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- I'm trying to add a stack-crushing feature to my anvil crushing recipes mod and I'm getting an issue I *really* don't understand.
- First a basic explanation:
- - the mod lets you define recipes with block or entity ingredients and that can output in a variety of ways
- - I'm adding a feature that lets you specify a lit of ingredients, all of which must be crushed to obtain the output
- - to accomplish this, I've:
- - mixin'ed to `FallingBlockEntity`, saving a `crushedList` that I save/retrieve by mixing into `writeCustomDataToTag` and `readCustomDataFromTag`
- - mixin'ed to `AnvilBlock`, implementing `BlockEntityProvider` (I've created an `AvnilBlockEntity` class)
- Now the issue:
- Somehow my `crushedList` is getting passed between different anvils or falling anvils.
- This makes recipes not work consistently when testing a single anvil, and makes trying to do multiple anvil crushing recipes at once consistently fail.
- I've double checked my mixin classes and I've made nothing static.
- I've also double checked that my `AnvilBlockEntity` is being removed the same way other BEs are removed (or at least the same removal code is reached).
- Here are
- - `AnvilBlockMixin` https://gitlab.com/supersaiyansubtlety/anvil_crushing_recipes/-/blob/stack-crushing-feature/src/main/java/net/sssubtlety/anvil_crushing_recipes/mixin/AnvilBlockMixin.java
- - `FallingBlockEntityMixin` https://gitlab.com/supersaiyansubtlety/anvil_crushing_recipes/-/blob/stack-crushing-feature/src/main/java/net/sssubtlety/anvil_crushing_recipes/mixin/FallingBlockEntityMixin.java
- - `AnvilCrushingRecipe` https://gitlab.com/supersaiyansubtlety/anvil_crushing_recipes/-/blob/stack-crushing-feature/src/main/java/net/sssubtlety/anvil_crushing_recipes/AnvilCrushingRecipe.java
- also, here's a test world where I have a setup to drop multiple anvils at once
- https://gitlab.com/supersaiyansubtlety/anvil_crushing_recipes/-/tree/stack-crushing-feature/run-client/saves/1_16_3
- Any pointers/suggestions would be appreciated.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement