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.

nshmura

Members
  • Joined

  • Last visited

Everything posted by nshmura

  1. hitResult worked fine! > LeftClickEmpty is a client-side event, so creating an explosion will do nothing meaningful I'm new to forge, and it's a little surprising. Thank you!
  2. Hi, Is there any way to get player's targeted block? I read below topic about 1.7. https://forums.minecraftforge.net/topic/21107-1710sloved-help-how-do-i-get-a-players-target-block/ But objectMouseOver is not found at 1.16.5. I'm trying to create a mod that explode at targeted block on PlayerInteractEvent.LeftClickEmpty event occurred. @Mod(ExampleMod.MOD_ID) class ExampleMod { private val logger: Logger = LogManager.getLogger(MOD_ID) init { MinecraftForge.EVENT_BUS.register(this) } @SubscribeEvent fun on(event: PlayerInteractEvent.LeftClickEmpty) { val pos = // get player's target block logger.info("${pos.x} ${pos.y} ${pos.z} ") event.world.explode( event.player, pos.x.toDouble(), pos.y.toDouble(), pos.z.toDouble(), 4.0F, Explosion.Mode.DESTROY ) } companion object { const val MOD_ID: String = "examplemod" } } Thanks

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.