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. Note that for 2D item models, you need to copy the item/generated vanilla json and put it inside your block models folder to use as a parent: https://github.com/Draco18s/ReasonableRealism/tree/master/src/main/resources/assets/harderores/models/block/item https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/resources/assets/harderores/blockstates/largedust.json#L4
  2. https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/java/com/draco18s/ores/client/ClientProxy.java#L96
  3. TL;DR: You can't insure you only get this tree's leaves. But you can get all of the log blocks. Every log in a tree is connected to every other log in one of the following ways: Up North South East West NE NW SE SW Up+North Up+South Up+East Up+West Up+NE Up+NW Up+SE Up+SW
  4. Nearly ALL methods in the block class are deprecated you'll notice. That means "don't call this" (use the IBlockState method instead) not "don't implement this."
  5. @Override public boolean isFullCube(IBlockState state) { return false; }
  6. They all do slightly different things. I ended up with all four because something wasn't working right (turned out to be a problem elsewhere, oops) and having all four doesn't hurt necessarily. It could probably be reduced two two of them and work Just Fine. Next, there's actually three network methods, not two. https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/java/com/draco18s/farming/entities/TileEntityTanner.java#L176-L188 One is called when the TE is first created, the other the rest of the time (and no, I can't remember which is which).
  7. Why are you extending BlockContainer? You don't need this, it fucks everything else up and stop using it. This does dick and as such you shouldn't even be extending BlockContainer at all, even if that class had value (which it doesn't): public TileEntity createNewTileEntity(World worldIn, int meta) { return null; } Seriously. WTF. Unless you meant for it to be abstract like the rest of the class... Why do you create your own FACING property? Why not using the one from BlockDirectional or BlockHorizontal? As for textures based on properties inside a TE, you need to sync the TE state to the client: https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/java/com/draco18s/farming/entities/TileEntityTanner.java#L95-L98
  8. Those two tasks cannot run simultaneously and you have them at the same priority.
  9. if(player.hasAchievement(AchievementHandler.achievementBulletProof)) { if(!player.hasAchievement(AchievementHandler.achievementBattleReady)) { } } Are you testing and making sure that the you have the bullet proof achievement? And you do know you can parent achievements, right?
  10. That's pretty much the only way you're going to be able to do it.
  11. Obviously you know--or can determine--which 9 slots you passed into the simulated InventoryCrafting. Which means you can do the reverse in order to place items. "Oh, my top-left corner is [0][1] -> pass as input" later "Ok I need to construct output, here's the top-left corner, where does it go again? Oh right my top-left corner for input is [0][1]"
  12. How about where they already are?
  13. It can't possibly be the only way you can figure out: it doesn't work for a variety of reasons. You have a meaningless loop (for example, if player.getHeldItemOffhand() isn't null, it will loop forever and never exit so really, what did you expect?) Have you tried player.getHeldItemOffhand().getItem() possibly?
  14. http://mcforge.readthedocs.io/en/latest/concepts/sides/ ...Add an variant named "inventory"?
  15. You would have to use the LivingUpdateEvent. And you'd have to write the swimming mechanics yourself.
  16. And you're still comparing an ItemStack to an Item
  17. I don't know. Maybe invoke it on the item stack in the player's hand?
  18. That's not a good solution. What if there's some block....say....molten iron that when entities are inside it it sets them on fire? Your block would say "nope, not inside!" And besides, all the swimming code is inside the Entity class (for players, EntityPlayer) and explicitly checks for Material.WATER so again, your code double-fails because if someone wants to have a material other than water this code doesn't make the block swimmable.
  19. Yes but this: ClientProxy.registerRenderers(); Is in common code and that's a static reference to your client proxy. Next to the run button is a dropdown, click that and click "run server."
  20. You can't do this. This will 100% crash the dedicated server. Remember: the client proxy cannot load on the server, it references classes that don't exist. The only way to reference proxy methods is through an instance. Mainmod.instance.proxy.registerRenderers();
  21. Proxies are not a Java thing. http://mcforge.readthedocs.io/en/latest/concepts/sides/ Your model can't be loaded because either: Your blockstate file lacks an inventory variant or because there is no item model json
  22. This does actually nothing: if(entityFacing == EnumFacing.NORTH) { entityFacing = EnumFacing.NORTH; } else if(entityFacing == EnumFacing.SOUTH) { entityFacing = EnumFacing.SOUTH; } else if(entityFacing == EnumFacing.EAST) { entityFacing = EnumFacing.EAST; } else if(entityFacing == EnumFacing.WEST) { entityFacing = EnumFacing.WEST; } If value is A, set value to A. If it's B, set it to B... You also have no code that supplies a different bounding box based on facing. You in fact, supply a single bounding box (which you reconstruct every time) regardless of block state: public AxisAlignedBB getBoundingBox(IBlockState state, IBlockAccess source, BlockPos pos) { return new AxisAlignedBB(posX, posY, posZ, sizeX, sizeY, sizeZ); }

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.