Jump to content

Animefan8888

Forge Modder
  • Posts

    6157
  • Joined

  • Last visited

  • Days Won

    59

Everything posted by Animefan8888

  1. Override their loot table files. data.minecraft.loot_table.blocks I believe.
  2. Look at the item class because you can set the ToolType of an item.
  3. You would need a custom IRecipe implementation and a custom IRecipeFactory/IRecipeSerializer. Because all recipes should be loaded from JSON.
  4. Once you're done rendering you need to bind the ICONS resource because it expects it.
  5. How did you register your event class if you used EventBusSubscriber you need to make your method static.
  6. Unless you override the equals method checking if a list contains an entity whom we will call instance a when instance b is already there will always return false. You need to iterate through the list of entities and check if one is an instance of your entities class. And if it is say it cant spawn.
  7. Yeah and every player tick using the PlayerTickEvent you'll have to update the values.
  8. The problem is that the data isn't always the same between clients and the server. Ping an all. You will either have to keep with what you have and have that little leading thing or trust the client with no way to know if they are being cheaty unless you add some sort of check like if the rotation on the server is definitely not what the client says it was.
  9. I use Eclipse and I like it. Some others on here use InteliJ IDEA. It's ultimately up to you which IDE you use.
  10. event.getState() will give you the BlockState
  11. Well you know how to get the Item and the ItemStack the player is holding. You can check. Look at the tool Items in Items.class. They have methods you might be able to use. Or you can use instanceof checks.
  12. Does it really matter? Why would they make a mod where you can't progress?
  13. Then you'll want to check if they have a tool that can break the block.
  14. Oops my bad. Use ItemStack#isEmpty so event.getEntityPlayer().getHeldItem(Hand.MAIN_HAND).isEmpty()
  15. Instead use ItemStack.isEmpty(event.getEntityPlayer.getHeldItem(Hand.MAIN_HAND))
  16. It should still work what version are you modding for?
  17. No I am asking why are you doing this it might not be that complicated. Plus if the player hits another player with damage that isn't potions or an entity like an arrow. They had to have been looking at the player in question unless they are using hacks.
  18. Huh I wonder who gave you advice you just ignored.
  19. Go to this location in your IDE's package explorer.
  20. event.getEntityPlayer().getHeldItem(Hand.MAIN_HAND).getItem() == SOME_ITEM_FIELD
  21. Agreed that is disgusting. Though I feel that the only viable alternatives at this point is also disgusting. One being to use reflection to access the recipes field or RecipeManager#getRecipes(IRecipeType<?>) in the RecipeManger so you can access the specific list/map of the recipe type you want. Or use the collection given by RecipeManager#getRecipes() and cache the recipes that you have already come across in a separate list/map so as to not iterate over every last recipe ever.
×
×
  • Create New...

Important Information

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