Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to properly build the website #51

Open
samjviana opened this issue Jun 25, 2024 · 9 comments
Open

How to properly build the website #51

samjviana opened this issue Jun 25, 2024 · 9 comments

Comments

@samjviana
Copy link

Sorry if this is a dumb question, I've been reading and re-reading the README and wiki but I can't seem to manage to build the website.
I managed to build the mhrice.exe and even generated an TDB file ... but how can I generate the website? Or even generate the "database" that the website will use.
When I try to run gen-website I get Error: No matching hash for data/Define/Common/HunterNote/MonsterListBossData_MR.user. Is there a place where I need to specify the path to the game files?

@wwylele
Copy link
Owner

wwylele commented Jun 25, 2024

Hi, which game version are you using? I have only tested for PC version from 10.0.2 to 16.0.1. The error you got looks like a version that mhrice doesn't support

@samjviana
Copy link
Author

samjviana commented Jun 25, 2024

I'm running 16.0.2.0 (which the game update to in the last month or so) maybe that's the problem ...
Also, I've been trying to make it work and now i'm getting this error:

PAK_MAIN_KEY_MOD not provided. Going to guess the key...
PAK_MAIN_KEY_MOD not provided. Going to guess the key...
Error: Can't find a pivot

This because of the key right? How can I find this key, I never saw any reference about any key necessary across the community.

@wwylele
Copy link
Owner

wwylele commented Jun 25, 2024

Ah interesting. I never properly tested 16.0.2. Perhaps they updated something there. Let me see...

@wwylele
Copy link
Owner

wwylele commented Jun 25, 2024

I just installed a fresh copy of the latest version from steam and I was able to generate the website in the ./website folder with the following command

mhrice.exe gen-website -p g:\SteamLibrary\steamapps\common\MonsterHunterRise -o website --origin "https://mhrise.mhrice.info"

(replace that path with your steam library path)
Is your game folder clean without mod?

@samjviana
Copy link
Author

It worked, yay! I have both the GamePass and Steam versions, but I mostly play on the GamePass one. I didn't install them in the standard location, so sometimes I get confused between them when datamining or modding something... and I was passing the GamePass .paks (rookie mistake sorry).

Thank you for your help; this is truly an incredible project. I've been trying to find some of this information for about two weeks, and I can only imagine how much effort it took to make this work so well.

This is the first time I've worked with Rust. I'll try to dedicate some of my time to making it work with the Game Pass version. ^~^

@wwylele
Copy link
Owner

wwylele commented Jun 25, 2024

Ah, I keep forgetting the GamePass version and never got a chance to test it. Did you get it work with the GamePass version?

@samjviana
Copy link
Author

samjviana commented Jun 25, 2024

No (sadly) I just changed the pak path to point to Steam's version.
I did some memory reading, datamining and stuff in the past, and GamePass version seems to be very very similar to Steam version.
Specially in 16.0.2.0 ... in 16.0.1.0 the binary had some different offsets compared to Steam, I couldn't any different offset after the update.

Can you briefly explain what the guess_key method do? I've never needed to have any sort of key while modding/datamining etc.

@wwylele
Copy link
Owner

wwylele commented Jun 25, 2024

The header of pak files are "encrypted" using a key. Due to the weak algorithm used there, it is possible to derive the key by observing patterns in the encrypted data and decrypt it. That's what guess_key does. It is possible that the gamepass version uses a different algorithm so this method doesn't work any more.

I think many other modding tools simply provides you the key. I just included this guessing work in the program for fun

@samjviana
Copy link
Author

Oh, that's makes sense ... I did not know about this encryption thing.

I'll see if I can find any sort of key ^~^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants