Issue
so, I am following a Minecraft modding tutorial in 1.16, I use Eclipse and 1.16.4 mdk, everything was going great until I try to launch the game, it keeps getting an error, here is the console :
2023-04-25 18:39:51,378 main WARN Advanced terminal features are not available in this environment
[18:39:51] [main/INFO] [cp.mo.mo.Launcher/MODLAUNCHER]: ModLauncher running: args [--gameDir, ., --launchTarget, fmluserdevclient, --fml.mcpVersion, 20201102.104115, --fml.mcVersion, 1.16.4, --fml.forgeGroup, net.minecraftforge, --fml.forgeVersion, 35.1.4, --version, MOD_DEV, --assetIndex, 1.16, --assetsDir, C:\Users\codic\.gradle\caches\forge_gradle\assets, --username, Dev, --accessToken, ❄❄❄❄❄❄❄❄, --userProperties, {}]
[18:39:51] [main/INFO] [cp.mo.mo.Launcher/MODLAUNCHER]: ModLauncher 8.0.6+85+master.325de55 starting: java version 17.0.6 by Eclipse Adoptium
[18:39:51] [main/DEBUG] [cp.mo.mo.LaunchServiceHandler/MODLAUNCHER]: Found launch services [minecraft,fmldevdata,fmldevclient,fmldevserver,fmluserdevserver,fmluserdevdata,testharness,fmlclient,fmluserdevclient,fmlserver]
Exception in thread "main" java.lang.ExceptionInInitializerError
at cpw.mods.modlauncher.Launcher.lambda$new$6(Launcher.java:55)
at java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1708)
at cpw.mods.modlauncher.api.TypesafeMap.computeIfAbsent(TypesafeMap.java:52)
at cpw.mods.modlauncher.api.TypesafeMap.computeIfAbsent(TypesafeMap.java:47)
at cpw.mods.modlauncher.Environment.computePropertyIfAbsent(Environment.java:62)
at cpw.mods.modlauncher.Launcher.<init>(Launcher.java:55)
at cpw.mods.modlauncher.Launcher.main(Launcher.java:66)
at net.minecraftforge.userdev.LaunchTesting.main(LaunchTesting.java:105)
Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make field private final java.util.jar.JarVerifier java.util.jar.Manifest.jv accessible: module java.base does not "opens java.util.jar" to unnamed module @5f683daf
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:354)
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
at java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:178)
at java.base/java.lang.reflect.Field.setAccessible(Field.java:172)
at cpw.mods.modlauncher.SecureJarHandler.<clinit>(SecureJarHandler.java:48)
... 8 more
I tried using ChatGPT to fix that but it says that it is a Java compatibility issue, which after I checked several times is not, the version is right, JRE 1.8.
Solution
java.lang.reflect.InaccessibleObjectException: Unable to make field private final java.util.jar.JarVerifier java.util.jar.Manifest.jv accessible: module java.base does not "opens java.util.jar" to unnamed module @5f683daf
the version is right, JRE 1.8.
That line of your error implies that you're not actually on JRE 1.8. Modules and opens didn't even exist as concepts then. If you actually switch to JRE 1.8, then that error will go away.
Answered By - Joseph Sible-Reinstate Monica
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.