Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 01/21/19 in all areas

  1. You can edit your original post and add “[SOLVED] “ to the title. Here is an example of how I drop my items https://github.com/Cadiboo/WIPTechAlpha/blob/fb5883e9d76ef0361ec1ebbcb9c508611dd2ef6b/src/main/java/cadiboo/wiptech/capability/inventory/ModItemStackHandler.java#L23-L35 You still need to - Not use ITileEntityProvider: It is legacy vanilla code, simply override hasTileEntity and createTileEntity. - Not use IHasModel: It is a stupid way of registering things that makes you write the exact same lines of code for ever class, it is unneeded and a better result can be achieved with 1 single line of code. - Check for null before using the tile entity you get from world#getTileEntity - Check that the tile entity you get from world#getTileEntity actually is an instance of your tile entity before you cast it (when the block is replaced, a structure is loaded on top of it, commands like /fill, /clone or /setblock are used, or even if the server is just overloaded, it might not be an instance of your tile entity)
    1 point
  2. In the breakBlock method, loop through the inventory's slots. Create a new EntityItem in the for loop and then call spawnAsEntity. I think InventoryHelper#dropInventoryItems wants an IInventory, which probably won't work in your case. This is somewhat how I did it, and I use ItemStackHandler.
    1 point
  3. None, at start i followed a tutorial but there is too many error then I tried myself (with ForgeDocs). Big thank, my error was : @SubscribeEvent //You didn't wrote it. public static void onBlockRegister(RegistryEvent.Register<Block> event) { event.getRegistry().registerAll(MTBlocks.BLOCKS); }
    1 point
  4. You need to use Java 8, later versions are not currently supported.
    1 point
  5. i figured making pixelmon sidemods would be a relatively popular search so atta give it its own tutorial and since its really not much effort lets go for it. create a folder in eclipse package explorer named "libs" (you must name it libs otherwise you would'nt be able to build your mod via gradlew) in eclipse package explorer and place your mod of choice's jar file inside like you can see with pixelmon right here. then right click your mod of choice, goto build path then add to build path so your mod of choice turns to look like so now in main.java add a dependency under @Mod example: with pixelmon in " dependencies = "required-after:pixelmon" " being your mod of choice's mod id at this point you're pretty much done, now you can import from the mod.
    1 point
  6. Why is there no forge for the 1.13? It's being so long since the realese of Minecraft 1.13.
    1 point
×
×
  • Create New...

Important Information

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