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. So, what's not working?
  2. You don't need that line. I only highlighted lines 65 through 71, that was from line 64.
  3. That should work. You still need to invoke that method of course, but it looks correct. And it needs to be client-side-only, as does all other model registration code.
  4. Yes. You didn't do this:
  5. Take my code, put it inside of your line 95, replacing my line 70 with the equivalent in my prior post. Which I have to edit, because I forgot the new ModelResourceLocation bit.
  6. Register the block: looks fine Register the item: looks fine Register the item's model: see prior post
  7. The only loop you would need would be to register models for the ItemBlock variants, if applicable. For all variant blocks, you can use this: https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/hardlib/client/ClientEasyRegistry.java#L65-L71 (Line 70 eventually resolves to ModelLoader.setCustomModelResourceLocation(iblock, block.getMetaFromState(state), new ModelResourceLocation(block.getRegistryName(), str)); )
  8. Enum? Do you mean a block with a state property? Its done exactly the same way...
  9. for each(key in hashmap.keys) { nbt.putValue(key, hasmap.get(key)) } Its almost like this stuff writes itself.
  10. Well the BlockDirectional isn't being used by your block classes, so what did you expect?
  11. Look at how vanilla handles the cooldown on corus fruit.
  12. Of course not, that's a method in TileEntity. But in order for it to work, your model needs to be rendered from a TESR, not a block model.
  13. Without a TESR? Yes, multiple blocks.
  14. Look at BlockShulkerBox. It sets a tag on the item stack called "BlockEntityTag" which is automatically applied to the TE when the block is placed.
  15. Well yeah, the block that has that model is outside of your view. Minecraft assumes that all block models are no larger than 1x1x1, with some allowance given to the Y axis (but no more than half a block) due to fences. You can't fix this except by using multiple blocks and multiple models.
  16. A "factory" in the programming sense is a class and code that constructs an object of another class. https://en.wikipedia.org/wiki/Factory_(object-oriented_programming) The _factories.json file points the string key name from the type to a class reference. Specifically the factory that has a known constructor and input method that the JSON segment needing to be deserialized can be passed to in order to construct the unknown object type: https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/hardlib/api/recipes/RecipeToolMold.java#L245
  17. there's also a couple of Forge ones, for oredict. You need a _factories.json file: https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/resources/assets/hardlib/recipes/_factories.json Buckets of liquids automatically return an empty bucket due to the Container Item mechanics. This has nothing to do with the recipe.
  18. The post was edited. I can't view the edit history, but I'm almost certain he said "division" when I made my reply. I've slept since then. He also has "or MathHelper" in there, and MathHelper does not contain a "BlockToChunk" method (there is exactly one instance of >>4 in it: smallestEncompassingPowerOfTwo), so also wrong.
  19. Yep, that's how the display tags work: models/block/block.json: "display": { "gui": { "rotation": [ 30, 225, 0 ], "translation": [ 0, 0, 0], "scale":[ 0.625, 0.625, 0.625 ] }
  20. There really isn't. You could probably write a mod to generate them for you, but they still need to be rendered (they're literally 3D objects even when they're in your inventory).
  21. What is your end-goal? What are you using these icons for?
  22. Jesus Christ, you're as dumb as a post. No, only use >> 4, as I already said twice. The X is there because it failed to produce the correct result, therefore it is wrong and should not be used.
  23. No tag? Create one, set the tag to it.

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.