Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 05/09/19 in all areas

  1. Don't use ItemBase. Well, you are not setting your item in use. You are just clicking it which does nothing. Bow uses EntityPlayer#setActiveHand
    1 point
  2. No. In this case a custom block class is acceptable. I mean, the fields are technically not final, just private, so you could use reflection but why? see https://github.com/MinecraftForge/MinecraftForge/issues/5560 for reasons as to why there isn't a setter.
    1 point
  3. That PR is perfect, except for the fact that it also doesn't allow transparency + tinting (It might actually if you override canRenderInLayer in your block and return true for TRANSLUCENT and also add the tint to the raw model data if thats possible, but this would be pretty hard to do and would require doing stuff relatively low level)
    1 point
  4. Also worth mentioning that the MBE04 approach linked above won't work in 1.13.2 at all, since extended blockstates are no longer a thing. However, this PR just got merged: https://github.com/MinecraftForge/MinecraftForge/pull/5564, which is great.
    1 point
  5. IIRC you can do this with a custom IRecipe implementation. I can't get you more info because the forum's search function isn't finding anything (even the topics that I know exist). I think that @diesieben07 has given advice on this before. Edit: found this
    1 point
  6. Forge is only for java edition of minecraft. And I don't think it will ever be for windows 10 version. Mojang is planning to create their one modding-like thing for bedrock edition I believe.
    1 point
  7. The filenames of some of your mods suggest you are not getting mods from their official sources, please read my forum signature below for more info on why this is a problem.
    1 point
  8. See https://mcforge.readthedocs.io/en/latest/tileentities/tileentity/#synchronizing-the-data-to-the-client Personally, I'd go with a custom packet - NBT is a poor format for network communication (overly verbose), and a custom packet will be more efficient in terms of network traffic. Also, I noticed you're using a PropertyInteger for your block's facing - why?? There's a builtin PropertyDirection class for exactly this (look at BlockFurnace for an example of a horizontally-constrained rotation, or BlockDispenser for an example of an unconstrained rotation). That would allow you to ditch that disgusting code in onBlockPlacedBy().
    1 point
  9. You can probably make use of the active item use mechanic used by bows, food, shields, etc. Try overriding Item#onItemRightClick to do the following: Call EntityLivingBase#isHandActive to check if the player is actively using an item. If they aren't, call EntityLivingBase#setActiveHand to make the player start using your item and then perform the effect. If they are, do nothing. You'll also need to override Item#getMaxItemUseDuration to return the maximum duration in ticks that the player can actively use your item (bows and shields use 72000, which is 1 hour), and optionally Item#getItemUseAction to return something other than EnumAction.NONE.
    1 point
×
×
  • Create New...

Important Information

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