Vatuu / discord-rpc

Java Wrapper of the Discord-RPC Library for Discord Rich Presence.
MIT License
194 stars 42 forks source link

java.lang.NoClassDefFoundError on line 10 #48

Closed ZachLudwick closed 3 years ago

ZachLudwick commented 3 years ago

Describe the bug I am making adding RPC to my minecraft client. When I run in debug the RPC works but when I implement to the launcher i get all those errors and I can't figure out why. Any help is appreciated.

Source package EfeClient;

public class Client {

private static final Client INSTANCE = new Client();
public static final Client getInstance() {
    return INSTANCE;
}

private DiscordRP discordRP = new DiscordRP();

public void init() {
    discordRP.start();
}

public void shutdown() {
    discordRP.shutdown();
}

public DiscordRP getDiscordRP() {
    return discordRP;
}

}

Error

Versions (Must be completed): java.lang.NoClassDefFoundError: net/arikia/dev/drpc/callbacks/ReadyCallback at EfeClient.Client.(Client.java:10) at EfeClient.Client.(Client.java:5) at net.minecraft.client.Minecraft.startGame(Minecraft.java:470) at net.minecraft.client.Minecraft.run(Minecraft.java:401) at net.minecraft.client.main.Main.main(Main.java:113) Caused by: java.lang.ClassNotFoundException: net.arikia.dev.drpc.callbacks.ReadyCallback at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ... 5 more

A detailed walkthrough of the error, its code path and all known details is as follows:

-- Head -- Stacktrace: at EfeClient.Client.(Client.java:10) at EfeClient.Client.(Client.java:5) at net.minecraft.client.Minecraft.startGame(Minecraft.java:470)

-- Initialization -- Details: Stacktrace: at net.minecraft.client.Minecraft.run(Minecraft.java:401) at net.minecraft.client.main.Main.main(Main.java:113)

-- System Details -- Details: Minecraft Version: 1.8.8 Operating System: Windows 10 (amd64) version 10.0 Java Version: 1.8.0_51, Oracle Corporation Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation Memory: 87987328 bytes (83 MB) / 167772160 bytes (160 MB) up to 2147483648 bytes (2048 MB) JVM Flags: 8 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xmx2G -XX:+UnlockExperimentalVMOptions -XX:+UseG1GC -XX:G1NewSizePercent=20 -XX:G1ReservePercent=20 -XX:MaxGCPauseMillis=50 -XX:G1HeapRegionSize=32M IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0 Launched Version: EfeClient LWJGL: 2.9.4 OpenGL: ERROR RuntimeException: No OpenGL context found in the current thread. GL Caps: Using VBOs: ERROR NullPointerException: null Is Modded: Very likely; Jar signature invalidated Type: Client (map_client.txt) Resource Packs: ERROR NullPointerException: null Current Language: ERROR NullPointerException: null Profiler Position: N/A (disabled) CPU:

Additional info

lawrencfgsdfg commented 3 years ago

https://xkcd.com/979/

ItzzParsher commented 2 years ago

maybe class ReadyCallBack was not found bro, i have same problem

TheDarkLach commented 2 years ago

@ItzzParsher Make sure you have discordrpc either in the .json or extracted into the jar.