Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

[SOLVED] [1.17.1] Error when trying to use :runClient / java.lang.StringIndexOutOfBoundsException: begin 0, end -1, lenght 3


Recommended Posts

After having a conversation with SizableShrimp in the Forge Discord I wanted to aks for help on the forums.

My mod works completely fine, it compiles fine, genIntellijRuns works fine, but every time I try to use :runClient I experience this error: https://pastebin.com/ekaF1MBL

What I have been told is that it is trying to load the eez class from the client-extra.jar. Someone else with a similiar issue deleted all the classes in this .jar and which fixed the issue, but I'm still getting the same error after deleting those classes.

I already did things like invalidate caches, and tried to add this to runs in the build.gradle: property 'legacyClassPath', '{minecraft_classpath}' but nothing works.

I also tried to run the latest MDK without changing any code but got the same error.

 

Does anyone else have an idea what I need to do? Or is this an issue on Forge's side that I need to report on GitHub?

Edited by CheckerMark79
Solved issue.
Link to comment
Share on other sites

  • CheckerMark79 changed the title to [1.17.1] Error when trying to use :runClient / The game loading classes it shouldn't

Alright, thanks to someone from the Forge Discord I managed to solve the issue.

If anyone ever gets this error: java.lang.RuntimeException: java.lang.StringIndexOutOfBounds: begin 0, end -1, length 3

Delete the client-extra.jar, found under external libraries, and refresh your gradle.

Also make sure you are using Java 16 (As of 1.17+)

This solved the issue for me, which took me days.

Link to comment
Share on other sites

  • CheckerMark79 changed the title to [SOLVED] [1.17.1] Error when trying to use :runClient / java.lang.StringIndexOutOfBoundsException: begin 0, end -1, lenght 3

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share



×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.