Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Draco18s

Members
  • Joined

  • Last visited

Everything posted by Draco18s

  1. You edited your post...to not edit your post.
  2. Assets must be all lower case. en_us.lang not en_US.lang Also, you should include your mod ID in your unlocalized names to avoid conflicts with other mods ("gb"? really?)
  3. Oh, oh yeah, that would be a problem. I would make that function match other translucent blocks like Glass and Water, where it doesn't render the interior surfaces, just the exterior.
  4. I do it like this in one of my mods: Random r = new Random(pos.toLong());
  5. Custom blocks do not take any more time to use during worldgen than vanilla blocks. There's almost always something else at fault (e.g. using a block with a TE will be slower).
  6. This is not always true: EntityPlayer player = (EntityPlayer) entity; I.e. if the entity causing the damage is not a player, your code will outright crash. This is dumb: ItemStack hand = ItemStack.EMPTY; hand = player.getHeldItemMainhand(); Just assign the return to the variable when you create it. This gets tossed in the garbage bin: This item is the one that actually gets dropped: event.getDrops().add(new EntityItem(event.getEntity().getEntityWorld(), event.getEntity().posX, event.getEntity().posY, event.getEntity().posZ, new ItemStack(ModItems.mobSouls))); Don't see it? It's waaaaaaaaaaaayyyyyyyyyyyyyyy over heeeeeeeeeeeeeeeeeeeeeeeeeeeerrreeeeeeeeeee: event.getDrops().add(new EntityItem(event.getEntity().getEntityWorld(), event.getEntity().posX, event.getEntity().posY, event.getEntity().posZ, new ItemStack(ModItems.mobSouls))); -----------------> -----------------------------------------> ----------------------------------------> -----------------------------> ------------------------^
  7. Why do you implement ITickable? Is there a reason to make your TE tick?
  8. ASM is heavily discouraged. Mostly due to the fact that if you do not know how to ASM you should not be using ASM and this forum won't teach you. There are many, many pitfalls and some of them won't even be obvious, but which will make your mod incompatible with other mods without you being aware of it.
  9. I'm not seeing anything obvious.
  10. You haven't called setRegistryName on your potion type.
  11. You probably want something more like dotProd < -0.8
  12. This is a really complicated thing you want to do. Mineraft isn't set up to handle something like this, Tinker's Construct manages it, but it's built on top of a system that was never intended to handle it. There's a lot of steps to go through and they're not simple things. I suggest starting with an easier mod first.
  13. You don't need capabilities for that. An event handler for the LivingHurtEvent will work just fine. Capabilites are for data
  14. Eh, fuck it. I can't be bothered to work out the math myself. Have this instead
  15. That depends. What are you trying to do.
  16. It's called vector math. "Vec3d" stands for "Vector (size 3, type double)" and contains 3 doubles. Vectors can represent a position in space (like how a BlockPos does) or it can represent a direction (which is what LookVec does). Adding the two together can let you figure out where an entity is looking. Which means you can use that same information to figure out if one entity is in front of another or not.
  17. You need to use vector math. And the entity's LookVec
  18. If that is your blockstate json file, it is incomplete, lacking all of the variants it is supposed to be specifying. Also, there should be an error for missing models, which you have not included.
  19. There are also mutex bits, which control if two tasks are allowed to run together (regardless of priority)
  20. It's still going to crash the dedicated server. Also, stop using the model mesher. Use ModelLoader.setCustomModelResourceLocation and do it inside the ModelRegistryEvent.
  21. No. You use Capabilities to store information on the player.
  22. Your registerRenders method is not called from anywhere. Also, it will crash the dedicated server.
  23. Ah, you're right. I saw the super call (with a base class of Block, which generally doesn't do much), but I didn't see that it called BlockPistonBase.getFacingFromEntity.
  24. Are there vanilla blocks that do this? How do they do it?
  25. Capabilities are not automatically synced, as there may be capabilities that the client does not need to know about.

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.