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. Less "bad" and more "completely pointless." The only bad thing about it is that it violates the DRY principle ("don't repeat yourself") making you type the same 3 lines over and over again, as well as obfuscating how/if your models are being registered. Its not that it doesn't work, but that when it fails, its harder to figure out why (as well as serving no purpose: all items need models and none of the information needed to register one is private (but this CAN change in some circumstances--eg custom mesh definitions--and THAT'S what an interface is good for)). (Note that I'm the one that started the crusade against IHasModel and I'm pretty sure you're echoing what someone else said about it, and not what I've said. ) Other than that, pretty accurate post
  2. 1.7.10 is no longer supported here and your problem isn't one we support anyway (you're USING mods, we support mod MAKERS).
  3. Sounds like someone needs to make a Forge PR to fix this.
  4. https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/farming/block/BlockTanner.java#L89-L103
  5. Of course you "join world A" and then "join world B" won't carry a value with the player. They aren't the same player. It's the same player account, but World A and World B are two completely unrelated save files. Data does not carry over between them.
  6. This question is either backwards (JSON files point to IRecipe implemenations) or confused (slots don't "look for" json files). If you want to locate recipes, look at the list of recipes.
  7. Hardcore is not hard coded. Hard coded mean that the data is made up of magic numbers (strings, whatever) in the source code. This has nothing to do with "hard core" meaning very hard or advanced play.
  8. "Packets" are a conversion between runtime data and a binary serialization format. That's all. Look at this example: https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/java/com/draco18s/ores/networking/ToClientMessageOreParticles.java The only "code" that is there is writing to, and reading from, a ByteBuffer. Your MessageRestoreFatigue does fuckall: it writes no data and it reads no data and instead...gets the capability on the client and directly modifies the values there. What you should be doing, is sending a packet from the server to the client containing the fatigue value. Your packet also does that on the networking thread, which is a major no-no.
  9. https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/java/com/draco18s/ores/OresBase.java#L386-L394
  10. You can get the same effect by overriding the methods that call it and using a different implementation.
  11. You can't override static members. https://stackoverflow.com/questions/2223386/why-doesnt-java-allow-overriding-of-static-methods
  12. You don't need a tile entity for this. All that happens when you insert an eye of ender into an end portal frame is that the block changes state. As a result, it changes models. This can all be done with the JSON blockstate system. { "variants": { "eye=false,facing=south": { "model": "end_portal_frame_empty" }, "eye=false,facing=west": { "model": "end_portal_frame_empty", "y": 90 }, "eye=false,facing=north": { "model": "end_portal_frame_empty", "y": 180 }, "eye=false,facing=east": { "model": "end_portal_frame_empty", "y": 270 }, "eye=true,facing=south": { "model": "end_portal_frame_filled" }, "eye=true,facing=west": { "model": "end_portal_frame_filled", "y": 90 }, "eye=true,facing=north": { "model": "end_portal_frame_filled", "y": 180 }, "eye=true,facing=east": { "model": "end_portal_frame_filled", "y": 270 } } }
  13. (And register item models for all variants, as normal)
  14. Also, scrap IHasModel. All items need models. ALL OF THEM. ALL OF THEM. And none of the data needed to register one is private.
  15. You need an entirely different system for nbt. https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/industry/item/ItemCastingMold.java#L87-118 https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/hardlib/client/ClientEasyRegistry.java#L185-195
  16. https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/hardlib/client/ClientEasyRegistry.java#L147
  17. Are you trying to do something like I did here? https://github.com/Draco18s/ReasonableRealism/blob/1.12.1/src/main/java/com/draco18s/ores/item/ItemRawOre.java https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/resources/assets/harderores/blockstates/orechunks.json
  18. Also familiarize yourself with Minecraft's existing mechanics. Not just what it does, but how it does it. Many of the "I want X but Y" questions can be answered just by cribbing from vanilla.
  19. Gist updated. Fixes: Backspace and delete now function at line boundaries (collapsing 2 lines into 1). Enter now functions as expected when in the middle of a line (splitting at the cursor).
  20. OTG shouldn't have to, its called by world.setBlockState() automatically. Ooh, never mind, Forge did things that make it not called. You could make your block declare that it has a tile entity (hasTileEntity returns true) but never actually supply one (returns from getTileEntity are null checked). That'd make onBlockAdded get called for your blocks.
  21. This class is not marked with @EventBusSubscriber https://github.com/Colton-Slayden/Solis/blob/master/src/main/java/com/royalreject/solis/proxy/ClientProxy.java#L14
  22. Might've changed, I might've remembered wrong. public void onBlockAdded(World worldIn, BlockPos pos, IBlockState state)

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.