Jump to content

onBlockBreak phantom event


Skkkitzo

Recommended Posts

When I run ./gradlew runClient it loads up the game, and all seems well. However, when I attack any block, it crashes giving:

[13:03:05] [Client thread/FATAL] [minecraft/Minecraft]: Unreported exception thrown!
java.lang.NoSuchFieldError: drill
      at net.skkkitzo.konstant.EventHandlerCommon.onBlockBreak(EventHandlerCommon.java:29) ~[EventHandlerCommon.class:?]
     at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_6_EventHandlerCommon_onBlockBreak_BreakSpeed.invoke(.dynamic) ~[?:?]
     at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90) ~[ASMEventHandler.class:?]
       at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:182) ~[EventBus.class:?]
     at net.minecraftforge.event.ForgeEventFactory.getBreakSpeed(ForgeEventFactory.java:199) ~[ForgeEventFactory.class:?]
   at net.minecraft.entity.player.EntityPlayer.getDigSpeed(EntityPlayer.java:916) ~[EntityPlayer.class:?]
 at net.minecraftforge.common.ForgeHooks.blockStrength(ForgeHooks.java:264) ~[ForgeHooks.class:?]
       at net.minecraft.block.Block.getPlayerRelativeBlockHardness(Block.java:702) ~[Block.class:?]
   at net.minecraft.block.state.BlockStateContainer$StateImplementation.getPlayerRelativeBlockHardness(BlockStateContainer.java:420) ~[BlockStateContainer$StateImplementation.class:?]
   at net.minecraft.client.multiplayer.PlayerControllerMP.clickBlock(PlayerControllerMP.java:269) ~[PlayerControllerMP.class:?]
   at net.minecraft.client.Minecraft.clickMouse(Minecraft.java:1630) ~[Minecraft.class:?]
 at net.minecraft.client.Minecraft.processKeyBinds(Minecraft.java:2376) ~[Minecraft.class:?]
    at net.minecraft.client.Minecraft.runTickKeyboard(Minecraft.java:2147) ~[Minecraft.class:?]
    at net.minecraft.client.Minecraft.runTick(Minecraft.java:1935) ~[Minecraft.class:?]
    at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1188) ~[Minecraft.class:?]
        at net.minecraft.client.Minecraft.run(Minecraft.java:442) [Minecraft.class:?]
  at net.minecraft.client.main.Main.main(Main.java:118) [Main.class:?]
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_251]
  at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_251]
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_251]
        at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_251]
     at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]
       at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]
  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_251]
  at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_251]
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_251]
        at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_251]
     at net.minecraftforge.gradle.GradleStartCommon.launch(GradleStartCommon.java:97) [start/:?]
    at GradleStart.main(GradleStart.java:25) [start/:?]

 

Now forgive me if I'm wrong, but I'm a bit confused about this. Because according to this line

at net.skkkitzo.konstant.EventHandlerCommon.onBlockBreak(EventHandlerCommon.java:29) ~[EventHandlerCommon.class:?]

I have a class called EventHandlerCommon in the package net.skkkitzo.konstant, which I do not. The class is actually located in the package net.skkkitzo.konstant.handlers.

And even more confusing, it says line #29 is the culprit.... but that is the line of my class. Is gradle using the wrong code or something? I am completely baffled.

Spoiler

28. @Mod.EventBusSubscriber
29. public class EventHandlerCommon {
30. 	
31.	// @SubscribeEvent
32. // public static void onMining(BreakSpeed event) {	
33.	// 	EntityPlayer player = (EntityPlayer) event.getEntity();

 

Any help is much appreciated. Using the latest version

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.