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.

Asanmi

Members
  • Joined

  • Last visited

  1. Yeah, both of those return true, but you did them separately. Write that entire if() statement into a println and you'll see it also always returns True. Separately, you probably want to change if (neighborBlock == Blocks.WHEAT || neighborBlock == Blocks.CARROTS || neighborBlock == Blocks.BEETROOTS || neighborBlock == Blocks.POTATOES || neighborBlock == Blocks.NETHER_WART) to if(neighbourBlock instanceof BlockCrops) which will work for modded crops that use the base Crop for their own.
  2. I didn't even notice the code in the OP! I just started so my Forge knowledge is baby-ish, but the logic definitely seems wrong? You're doing each check separately, and if either of those checks returns TRUE then the entire thing will run. If you want to only destroy the blocks to relative east-west, then you need &&. if (neighborPos != oppPos || neighborPos != facingPos) if( (neighbourPos IS NOT south) OR (neighbourPos IS NOT north) ) = always true if (neighborPos != oppPos && neighborPos != facingPos) if( (neighbourPos IS NOT south) AND (neighbourPos IS NOT north) ) = true only if neighbourPos is relative-east or relative-west
  3. Oh. Would probably be more helpful to paste the code chunk in that case, probably!
  4. It's hard to tell with so little to see, but it looks like you want && instead of || . OR means it will be TRUE if either of the conditions is met, and a position can't be north and south at the same time.
  5. Asanmi changed their profile photo
  6. I'm trying to add a colorMultiplier to a block and its itemblock, pulling the color from a cut-down EnumDyeColor for it, because I don't want to make textures and blockstates for every single color variant. The textures all work, everything works except I can't get the actual color to change for either. The particles are properly colored when breaking the blocks so I know it's registered. A chat output on block activation shows BlockColors itself is returning the correct value, so I know the code for that is correct. So I can't figure out where I've gone wrong, or whether I'm missing an obvious thing. Does anything immediately pop out to anyone? Color registration here. BlockState JSON for the block here. Model JSON for the block here.

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.