Issue
Hey. I've been developing a game and in the game, I was showing the version "1.0.13", and I quickly realized that it was completely incorrect, and it should display "1.9". I edit my code in Eclipse, and I didn't make backups for my code each version, so I couldn't just edit the String from Eclipse. I tried decompiling the .jar file for the game using a .jar decompiler. I downloaded the source code (.java files) and put it into Eclipse Neon. Upon putting the .java files in I realized a few errors appeared. I fixed them and ran the program. Many of the game's mechanics were completely broken. I realized that wasn't going to work, so I extracted the .jar with WinRAR and then tried editing the .class file manually (which was a stupid idea) using Notepad++. After using their built-in tool I quickly replaced all the "1.0.13"s with "1.9". Upon saving the code and running the .jar file a window appeared with the title "Java Virtual Machine Launcher" and the text "Error": A JNI error has occurred, please check your installation and try again". I then ran across a program named JBE (Java Bytecode Editor). When using the program I was unsure how to edit the constant variables, and I searched for tutorials using the program and found none.
I just want to edit a single String and I've spent hours of research, and I can't even find a solution. If you know how to solve this situation, please comment. Thanks in advance.
Info
Since I "need at least 10 reputation to post more thank 2 links." I'll just post a single PasteBin link that you can read that will link to all the websites and programs I have talked about in this post.
Do not decompile, and don't edit byte codes.
If you use a standard hex editor (http://www.hexedit.com/) you can open the binary class file. Look through there and you can probably the old version number in there someplace. You can change individual bytes (don't forget it is UTF-16 encoded!) and save the binary change.
The key is that nothing else in the class moves or changes position. Notepad will insert or remove characters, and that will break the class file. When you find the literal, you have to pad the string with space characters (you can't change the length of the string literal). That is, change the characters where they exist to the new number, or to space characters, but never add or remove anything.
Nothing changes except the bytes that represent the string in the class file.