xforce / netease-messiah-tools

Tools working with files in NetEase's Messiah Engine (Primarily aimed towards Diablo Immortal for now)
MIT License
50 stars 17 forks source link

Is there a way to extract the localized text? #1

Open beside4ever opened 2 years ago

beside4ever commented 2 years ago

Hello, first of all thank you for your work! I'm doing a Diablo Immortal database, so I want to pull localized text data from the client. By compiling your program, I have unpacked the Package/Text folder, but the files are all in binary format. Is there a way to parse it into readable text?

xforce commented 2 years ago

I'm working on it. Starting from the top and working my way down. So expect more and more file types to be support in the following days/weeks.

xforce commented 2 years ago

Making small progress here. Similar to other NetEase games. All the translations are just maps in python files.

NetEase uses a heavily customized version of Python here, so decompiling is proving a bit of a time consuming endeavor.

However, I have managed to produce partial decompiles of some simple files locally, which do contain localized text. A lot more work required before this is in a shareable state

Just thought I'd give a quick update on what's happening.

xforce commented 2 years ago

So. Code to convert and decompile python scripts is now available.

Right now ~345 out of the ~8500 python files will either fail entirely or partially to decompile, this is something I will have to investigate at a future point. (That's actually quite a massive success, I think)

I will probably have to write a guide a some point on how to use it. You can find rough commands here Unless someone is willing to contribute that :slightly_smiling_face:

kryokil commented 2 years ago

keep following your tool and waiting patiently, could you please tell me which files are python? most of my extracted files are either no ext or *.6. Many thanks and looking forward for future features

xforce commented 2 years ago

keep following your tool and waiting patiently, could you please tell me which files are python? most of my extracted files are either no ext or *.6. Many thanks and looking forward for future features

If this is about Diablo Immortal, which is the game I'm currently using to build out all the basics. The mpk unpack tool will move them to a separate place with a .pyc extension. This was added recently. You can then use the scripts in the pyc directory to convert and decompile them. For the other files. Most of them will be moved to their correct name with the resource tool (using the arrange command). Right now this is all just about building out all the individual building blocks to have all things covered. I will then proceed to provide tools that combine them into some kind of easy to use interface and expand to other games from there.

kryokil commented 2 years ago

I might wait, im only for data fles, not sure if editing would be able or game would detect edits. Well done btw, you are doing fine work here ;)

Edit: tried scripts and decompiled 8788 and only 6 failed, this is Android version.