Querz / mcaselector

A tool to select chunks from Minecraft worlds for deletion or export.
MIT License
3.07k stars 171 forks source link

Error: Module jdk.unsupported.desktop not found, required by javafx.swing #454

Open Radon8472 opened 6 months ago

Radon8472 commented 6 months ago

Describe the bug I tried to run mcaselector v2.2.2 and tried to fix "Missing JavaFX"-Error like explained in instalation.

But it throws Module jdk.unsupported.desktop not found - error and is not starting successful.

To Reproduce Steps to reproduce the behavior:

  1. Install same java version like me (see below)
  2. Download and unzip javafx-sdk-17.0.7
  3. Download mcaselector 2.2.2
  4. run %JAVA_BIN% --module-path %JAVA_FX_DIR% --add-modules ALL-MODULE-PATH -jar mcaselector-2.2.2.jar (where %JAVA_BIN% is path to your java instalation and %JAVA_FX_DIR% path where you unziped java fx)
  5. See error

Expected behavior I expected mcaselector would open and run without errors

actual behavoir I get a error message on console, mca selector does not start.

>mcaselector-2.2.2.bat
Error occurred during initialization of boot layer
java.lang.module.FindException: Module jdk.unsupported.desktop not found, required by javafx.swing

Environment (please complete the following information):

Additional context This is my start.bat for mcaselector

@echo off
set JAVA_BIN=G:\Games\Minecraft\runtime\jre-x64\bin\java

:: see INFO at https://github.com/Querz/mcaselector/wiki/Installation#when-you-receive-an-error-from-a-previously-installed-version-of-java
::set JAVA_FX_DIR=G:\Programme\javafx\javafx-sdk-17.0.7\
set JAVA_FX_DIR=G:\Programme\javafx\javafx-sdk-17.0.7\lib

%JAVA_BIN% --module-path %JAVA_FX_DIR% --add-modules ALL-MODULE-PATH -jar mcaselector-2.2.2.jar
lilydjwg commented 1 week ago

I've got this problem and fixed it. You need to use JDK, not JRE.