Jump to content

TrazorMC

Members
  • Posts

    16
  • Joined

  • Last visited

TrazorMC's Achievements

Tree Puncher

Tree Puncher (2/8)

1

Reputation

  1. If your custom crafting table has a different size crafting grid from the vanilla crafting table, you can check the size of the inventory in the matches method of your IRecipe implementation.
  2. I recently did something similar, you can take a look around my code and see if it helps: https://github.com/TrazorMC/Elemental-Swords-1.14/blob/master/src/main/java/trazormc/elementalswords/entities/render/ChargedFireballRenderer.java The projectile is definitely not a particle. I assume the ITEM_SNOWBALL particle type might only be used for the snowball.
  3. For your first error, you need to infer type arguments, <HeartEntity>, before the create method. Your HeartEntity needs to have a constructor with EntityType and World parameters.
  4. It looks like the filename is spelled wrong. Change the 1.5.2 to 1.15.2.
  5. Bump. Still not sure what's going on.
  6. I'm trying to create a custom crafting table with my own recipes. I have almost everything working, but when I go to try and craft something nothing happens. I attempted to mimic how WorkbenchContainer handles crafting. I looked into it a bit, and it appears that onCraftMatrixChange is never called. I do not know why this is or how to fix it. Any help is appreciated. Edit: I changed my code to just extends Container rather than RecipeBookContainer and changed my onCraftMatrixChanged method. It works properly not. My code: https://github.com/TrazorMC/Elemental-Swords/tree/master/java/trazormc/elementalswords
  7. I believe the method you are using is called on the client and the server. You can use worldIn#isRemote to check if you are on the server before casting to ServerWorld.
  8. It's a custom class in the same package as the class he linked.
  9. The ItemAxe constructor takes attack damage as an argument, not durability. You're passing in the durability, so it always ends up being 700.
  10. Still can't figure it out. Is there another way of creating recipes that I should use? Or am I just doing something wrong?
  11. It doesn't look like it enters the for loops. I add recipes in the constructor of the recipe handler.
  12. Yep, it stops on the other breakpoints.
  13. So I tried that, but that just set the output to the airsword as soon as the workbench is opened. It doesn't look like it gets all the way through the for loops when the method is run. It always skips past the breakpoint I put there.
  14. So, I went through it. My first problem was that onCraftMatrixChanged wasn't being called properly, so I added it to slotClick and it's getting called. Now my problem is that in my recipe handler, getImbuementResult is only returning an empty itemstack, even when I have the correct inputs. I found that method from a tutorial and I don't know exactly how it works, so I'm not sure how to fix it. I still fell like I might be doing the recipes wrong by using a table for them.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.