Could not pass event PlayerInteractEvent

Discussion in 'Spigot Plugin Help' started by arthur7777, Jun 21, 2021.

?

PlayerInteractEvent

  1. What is a error

    0 vote(s)
    0.0%
  2. if you can fix it

    1 vote(s)
    100.0%
Multiple votes are allowed.
Thread Status:
Not open for further replies.
  1. Error:

    Could not pass event PlayerInteractEvent to AtlasMaquinas v3.0
    org.bukkit.event.EventException
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:302) ~[patched.jar:git-PaperSpigot-"4c7641d"]
    at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:78) ~[patched.jar:git-PaperSpigot-"4c7641d"]
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) ~[patched.jar:git-PaperSpigot-"4c7641d"]
    at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:517) [patched.jar:git-PaperSpigot-"4c7641d"]
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:502) [patched.jar:git-PaperSpigot-"4c7641d"]
    at org.bukkit.craftbukkit.v1_8_R3.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:228) [patched.jar:git-PaperSpigot-"4c7641d"]
    at net.minecraft.server.v1_8_R3.PlayerInteractManager.interact(PlayerInteractManager.java:463) [patched.jar:git-PaperSpigot-"4c7641d"]
    at net.minecraft.server.v1_8_R3.PlayerConnection.a(PlayerConnection.java:763) [patched.jar:git-PaperSpigot-"4c7641d"]
    at net.minecraft.server.v1_8_R3.PacketPlayInBlockPlace.a(PacketPlayInBlockPlace.java:52) [patched.jar:git-PaperSpigot-"4c7641d"]
    at net.minecraft.server.v1_8_R3.PacketPlayInBlockPlace.a(PacketPlayInBlockPlace.java:1) [patched.jar:git-PaperSpigot-"4c7641d"]
    at net.minecraft.server.v1_8_R3.PlayerConnectionUtils$1.run(SourceFile:13) [patched.jar:git-PaperSpigot-"4c7641d"]
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_282]
    at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_282]
    at net.minecraft.server.v1_8_R3.SystemUtils.a(SourceFile:44) [patched.jar:git-PaperSpigot-"4c7641d"]
    at net.minecraft.server.v1_8_R3.MinecraftServer.B(MinecraftServer.java:774) [patched.jar:git-PaperSpigot-"4c7641d"]
    at net.minecraft.server.v1_8_R3.DedicatedServer.B(DedicatedServer.java:378) [patched.jar:git-PaperSpigot-"4c7641d"]
    at net.minecraft.server.v1_8_R3.MinecraftServer.A(MinecraftServer.java:713) [patched.jar:git-PaperSpigot-"4c7641d"]
    at net.minecraft.server.v1_8_R3.MinecraftServer.run(MinecraftServer.java:616) [patched.jar:git-PaperSpigot-"4c7641d"]
    at java.lang.Thread.run(Thread.java:748) [?:1.8.0_282]
    Caused by: java.lang.NumberFormatException: empty String
    at sun.misc.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:1842) ~[?:1.8.0_282]
    at sun.misc.FloatingDecimal.parseDouble(FloatingDecimal.java:110) ~[?:1.8.0_282]
    at java.lang.Double.parseDouble(Double.java:538) ~[?:1.8.0_282]
    at com.dont.maquinas.bukkit.LimiteListeners.onInteract(Unknown Source) ~[?:?]
    at sun.reflect.GeneratedMethodAccessor147.invoke(Unknown Source) ~[?:?]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_282]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_282]
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:300) ~[patched.jar:git-PaperSpigot-"4c7641d"]
    ... 18 more
     
  2. The error is that you (or the author of the plugin) are trying to parse a double from a string, but you provided it an empty string. I highly suggest that you contact the author of the plugin or if you made the plugin, fix it yourself by catching NumberFormatException on your Double.parseDouble() method.

    Code (Java):
    String input = "3.00"
    double output;
    try {
        output = Double.parseDouble(input);
    } catch (NumberFormatException error) {
        error.printStackTrace();
        return;
    }
    Something like that... (if it works please leave a (y) on my post)
     
    • Like Like x 1
Thread Status:
Not open for further replies.