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.

[1.17.1] Games crashes when calling LivingEntity$hurt inside LivingEntityHurt

Featured Replies

Posted

Games crashes when calling LivingEntity$hurt inside LivingEntityHurt. I'm passing LivingEntityHurt$source and LivingEntityHurt$damage to it.

Spoiler
[19:41:38] [Server thread/ERROR]: Encountered an unexpected exception
java.lang.LinkageError: loader constraint violation: loader 'MC-BOOTSTRAP' @59309333 wants to load interface org.apache.logging.log4j.util.MessageSupplier. (org.apache.logging.log4j.util.MessageSupplier is in module [email protected] of loader 'MC-BOOTSTRAP' @59309333, parent loader 'bootstrap')
	at net.minecraftforge.eventbus.EventBus.handleException(EventBus.java:316) ~[eventbus-5.0.3.jar%237!:?]
	at net.minecraftforge.eventbus.EventBus.post(EventBus.java:307) ~[eventbus-5.0.3.jar%237!:?]
	at net.minecraftforge.eventbus.EventBus.post(EventBus.java:283) ~[eventbus-5.0.3.jar%237!:?]
	at net.minecraftforge.common.ForgeHooks.onLivingHurt(ForgeHooks.java:321) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2374%2380!:?]
	at net.minecraft.world.entity.LivingEntity.actuallyHurt(LivingEntity.java:1533) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.world.entity.LivingEntity.hurt(LivingEntity.java:1044) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.world.entity.monster.Zombie.hurt(Zombie.java:266) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.world.entity.player.Player.attack(Player.java:1113) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.level.ServerPlayer.attack(ServerPlayer.java:1310) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.network.ServerGamePacketListenerImpl$1.onAttack(ServerGamePacketListenerImpl.java:1227) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.network.protocol.game.ServerboundInteractPacket$1.dispatch(ServerboundInteractPacket.java:22) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.network.protocol.game.ServerboundInteractPacket.dispatch(ServerboundInteractPacket.java:75) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.network.ServerGamePacketListenerImpl.handleInteract(ServerGamePacketListenerImpl.java:1201) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.network.protocol.game.ServerboundInteractPacket.handle(ServerboundInteractPacket.java:62) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.network.protocol.game.ServerboundInteractPacket.handle(ServerboundInteractPacket.java:12) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$0(PacketUtils.java:21) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.TickTask.run(TickTask.java:17) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:139) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:22) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:775) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:162) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:112) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:758) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:752) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:122) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.MinecraftServer.waitUntilNextTick(MinecraftServer.java:738) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:687) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at net.minecraft.server.MinecraftServer.lambda$spin$2(MinecraftServer.java:258) ~[forge-1.17.1-37.0.108_mapped_official_1.17.1-recomp.jar%2375!:?]
	at java.lang.Thread.run(Unknown Source) [?:?]

 

 

  • Author
2 hours ago, diesieben07 said:

Post the full debug.log and your code.

Since i has just trying to change the damage that will be dealt to the entity, i just used LivingEntityHurt$setDamage instead of calling hurt function, and it worked.
still, thanks
 

Guest
This topic is now closed to further replies.

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.