Jump to content

Animefan8888

Forge Modder
  • Posts

    6157
  • Joined

  • Last visited

  • Days Won

    59

Everything posted by Animefan8888

  1. I don't know what your code looks like so the best I can tell you is look at HopperBlock#getStateForPlacement
  2. You can't. Sorta use the PlayerInteractEvent.EntityInteract or PlayerInteractEvent.EntityInteractSpecific. Not sure which one you should use.
  3. This can technically return true and have there be no TileEntity at the position. So you should instead Store the TileEntity in a local variable in the method(World#getTileEntity) and check if they are not null then drop all the items.
  4. I wouldn't use a capability for this. I would just save this to a file yourself. For simplicity sake probably a json file like the ops file. But if you really wanted to use a Capability here you would probably attach it to the Player and not use an ArrayList at all. No you don't need an interface. You only need to use an interface if your capability is modifiable. IE can have different implementations. Yes all Capabilities need an IStorage component. You would use NBTTagList.
  5. You need to learn Java. What you have there isnt a Forge error. You'd be able to fix it if you knew Java.
  6. They must not ever let it have an UP variant when its placed.
  7. So potion effects? LivingEntityBase#addPotionEffect
  8. Maybe post an issue on the github for minecraft forge.
  9. Nope it's probably a bug try updating to the most recent version of forge.
  10. Yes? I'm not sure why you brought that up. I was saying that the dispenser behavior might be added/registered before your eggs get registers/initialized. Therefore they don't get added to the behavior.
  11. Only when it is facing down? Have you looked at the block in F3 to make sure the facing property is down? Also could you post a screenshot or elaborate on what you mean by "won't render"?
  12. This is correct. This refers to the objects type name. While world refers to the field name.
  13. If it's not working for your own SpawnEggItem(s) then the behaviors are being registered before your Item is created which is a little weird. So you should register one for your self you can look in net.minecraft.dispenser.IDispenseItemBehavior. Its in the init method just look for SpawnEggItem.getEggs() for where it registers the spawn egg behavior.
  14. I would've preferred if you had posted them here. Have you deleted everything that has to do with the examplemod?
  15. All vanilla TileEntities with inventories implement IInventory. Look at the method in question to figure out what it does. You'll notice it all leads back to one method InventoryHelper.dropItems Which takes in a NonNullList<ItemStack> which you can get from your IItemHandler.
  16. This is not the appropriate location for recipes anymore. They go in data/modid/recipe.json
  17. Dont post source code that doesnt belong to you. Yes even the vanilla code. The Items class file.
  18. What diesieben said above me is very true. You should send a packet telling the server to check the calculation/do it itself. Then save the data and if necessary send it back to the client.
  19. Ok. You've yet to give us any of your files that could be causing the problem.
  20. This is the correct one, but you don't do anything in your handle method. You need to create an instance of your entity populate it with the data and then spawn it in the client world.
×
×
  • Create New...

Important Information

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