PixelGuys / Cubyz

Voxel sandbox game with a large render distance, procedurally generated content and some cool graphical effects.
GNU General Public License v3.0
436 stars 55 forks source link

Version java check #56

Closed Ygarr closed 1 year ago

Ygarr commented 1 year ago

installed 18 java, but said "it`s old need 11 at least not 8"

IntegratedQuantum commented 1 year ago

You probably installed java 8 in the past and it's set as your default java version somewhere. If you type java -version in a terminal (cmd.exe) you will see that it uses java 8 instead of java 18. This is a common problem on windows and it's a bit annoying to get rid of the java 8 installation.

Ygarr commented 1 year ago

Thanks I removed all old javas 8 from windows(in cmd I got java 18 though), but now I have: java -jar .\Cubyz.jar Exception in thread "main" java.lang.NoClassDefFoundError: pixelguys/json/Json at cubyz.utils.Logger.(Logger.java:43) at cubyz.client.GameLauncher.main(GameLauncher.java:29) Caused by: java.lang.ClassNotFoundException: pixelguys.json.Json at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641) at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188) at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521) ... 2 more

IntegratedQuantum commented 1 year ago

I recommend to use the launcher to run the game. The Cubyz.jar file requires a bunch of libraries and assets and cannot simply be launched with java -jar. The launcher takes care about all of this and stores the libraries and assets in .cubyz in your home directory.