Vice City: Multiplayer

VC:MP Discussion => Support => Topic started by: Mateus on Jan 19, 2020, 03:22 PM

Title: [INVESTIGATION] Java | Exception classes not found
Post by: Mateus on Jan 19, 2020, 03:22 PM
(https://forum.vc-mp.org/proxy.php?request=http%3A%2F%2Fbr-onemedia.000webhostapp.com%2Fimages%2Fone-media.png%3Fcrc%3D4078626641&hash=63a2fab5e343960bf739e6988c05b554e053d574)
one media team of game servers

INVESTIGATION


Our team is investigating and solving problems in the development of a Java server.

We have the following error:
1579446572245:  INFO - (VcmpPluginInit) VC:MP Java integration plugin loading...
1579446572276:  INFO - (JavaCore::LoadLibraryFunctions) Java VM library loaded.
1579446572276:  INFO - (JavaCore::LoadLibraryFunctions) Java VM library functions loaded.
1579446572276:  INFO - (JavaCore::SetupJVMArguments) Java VM settings initialized.
1579446572526:  INFO - (JavaCore::CreateJVM) Java VM created.
1579446572526:  INFO - (JavaCore::AttachThreadToJVM) Server thread attached to VM.
1579446572541: ERROR - (JavaExceptionHandler::Initialise) Exception in Java code
java.lang.NoClassDefFoundError: com/maxorator/vcmp/java/plugin/exceptions/DeadEntityException
Caused by: java.lang.ClassNotFoundException: com.maxorator.vcmp.java.plugin.exceptions.DeadEntityException
    java.net.URLClassLoader.findClass(Unknown Source)
    java.lang.ClassLoader.loadClass(Unknown Source)
    sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
    java.lang.ClassLoader.loadClass(Unknown Source)
1579446572557: ERROR - (JavaExceptionHandler::Initialise) Exception classes not found (ThreadSafetyException, DeadEntityException, NullPointerException).
1579446572557: ERROR - (JavaCore::Initialise) Setting up exception handler failed.
1579446572557: ERROR - (JavaEventProxy::StartVM) JavaCore initialisation failed.

javaplugin.propeties -OK

jvmLibPath=C:\Program Files\Java\jre1.8.0_241\bin\server\jvm.dll
mainEventsClass=com.github.newk5.vcmp.samplescript.controllers.MainController
classPath=C:\Users\geren\Documents\NetBeansProjects\vcmp-java-script\dist
maxMemory=50m

We also ask for your help to solve this problem and give a definitive answer to the community that also reported similar or similar errors.
Title: Re: [INVESTIGATION] Java | Exception classes not found
Post by: NewK on Jan 20, 2020, 04:20 AM
Your classPath property on your javaplugin.properties file is wrong, it should point to your script .jar file.

This:
classPath=C:\Users\geren\Documents\NetBeansProjects\vcmp-java-script\dist
Should be pointed to the .jar file. I can't 100% guess for sure the name of it without seeing what's inside the "dist" folder, but I'd assume it's probably something like:
classPath=C:\Users\geren\Documents\NetBeansProjects\vcmp-java-script\dist\vcmp-java-script.jar