Posted June 2, 20232 yr Hi! I've been trying to use external libraries like JOML (for animating) and Jsoup (for html parsing), It compiles fine, however at runtime if I call a class that uses one of these external libraries it crashes my game saying "ClassNotFoundException: {external library maven url here}". Here's my relevant code: // build.gradle dependencies { minecraft "net.minecraftforge:forge:${mc_version}-43.2.0" // Other dependencies... implementation "org.joml:joml:${joml_version}" implementation "org.jsoup:jsoup:${jsoup_version}" } // gradle.properties joml_version=1.10.5 jsoup_version=1.16.1 // Class using external joml library (crashes when I call this method) public Quaternionf toQuatf(float x, float y, float z, float w) { return new Quaternionf(x, y, z, w); } If I'm missing something please let me know! I'm not so familiar with Gradle as I originally used maven Poms/XMLs with Java xD
June 2, 20232 yr 7 hours ago, SnakerBone said: I've been trying to use external libraries like JOML (for animating) and Jsoup (for html parsing), It compiles fine, however at runtime if I call a class that uses one of these external libraries it crashes my game saying "ClassNotFoundException: {external library maven url here}". First, use Mojang's math functions pre 1.19.3. If you want to use JOML, update to 1.19.3 or later, since Mojang switched off the library. Second, non-mod artifacts need to be added using the `minecraftLibrary` configuration, so it gets picked up by the class loader.
June 2, 20232 yr Author 39 minutes ago, ChampionAsh5357 said: First, use Mojang's math functions pre 1.19.3. If you want to use JOML, update to 1.19.3 or later, since Mojang switched off the library. Second, non-mod artifacts need to be added using the `minecraftLibrary` configuration, so it gets picked up by the class loader. Thanks 🙂 I wasn't aware mojang started using JOML in 1.19.3 my bad haha
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.