jam1garner / smash-minecraft-skins

A mod for downloading and using your own minecraft skin to use in game, just enter your username!
MIT License
110 stars 10 forks source link

Update to support Smash 13.0 #62

Closed jam1garner closed 2 years ago

jam1garner commented 2 years ago

See smash 12.0 porting for context: https://github.com/jam1garner/smash-minecraft-skins/commit/88e9d299851a4c38db9ef9310dc2c933b467307e

should just require a single offset update. I haven't dumped version 13.0 myself, so I'm not planning on updating this personally. Will accept PRs if anyone grabs the updated offset.

GlossyCoin15 commented 2 years ago

I'd like to help, but I don't know where to find the offset in question. Great mod btw

jam1garner commented 2 years ago

I'd like to help, but I don't know where to find the offset in question. Great mod btw

@GlossyCoin15 some instructions for you or whoever attempts this:

  1. Open the game's main executable from v12.0 in GHIDRA
  2. Jump to the offset (it's .text-relative)
  3. Find unique or recognizable bits of code nearby
  4. Open v13.0 in GHIDRA
  5. Search for the recognizable code from step 3 in this new version
  6. From there follow it back to the equivalent code to the provided offset. Note down the instruction offset equivalent

From there the mod can be compiled with the new offset and no portrait rendering support to confirm it works, then after that PR the offset and I'll provide a build with portrait rendering enabled.

(Portrait rendering is toggle-able by a Cargo.toml feature as I am not the owner of the rendering code and am complying with the author's request to not publish it. If you have trouble with compiling I am willing to provide limited assistance, e.g. help with anything specific to this project)

GlossyCoin15 commented 2 years ago

While I think I have the offset, 0x66d214, I do not have the time to deal with the compilation, I have tried on multiple different platforms (Windows 10, Ubuntu 20.04, and Windows Subsystem for Linux) using cargo-skyline, and I get a different error in each (nothing to do with the lack of portrait rendering). Hopefully someone sees this and tries to make it work, and sorry if the offset is wrong.

jam1garner commented 2 years ago

While I think I have the offset, 0x66d214, I do not have the time to deal with the compilation, I have tried on multiple different platforms (Windows 10, Ubuntu 20.04, and Windows Subsystem for Linux) using cargo-skyline, and I get a different error in each (nothing to do with the lack of portrait rendering). Hopefully someone sees this and tries to make it work, and sorry if the offset is wrong.

no worries, I appreciate that you made an attempt regardless of if it's correct or not, that's more than most people. TNN is looking into whether your offset or another is correct, so wheels are in motion on that front

GlossyCoin15 commented 2 years ago

I'd like to give compiling another try, so I'd like to know how to circumvent these errors I get. For compatibilities sake, I have been trying to compile in the jugeeya/cargo-skyline docker image and the only modifications I have made to the code are the removal of the features block and the minecraft_render line in Cargo.toml. When running cargo skyline build, I get this output: 1 I also tried editing that file, even though I'm sure it's not the correct thing to do, and got this: 2 I would appreciate knowing where I went wrong, or what sort of steps I should be taking to build this. I also tried using the rust_build.yml workflow in a private test repo, but it was hanging on build for about 2 hours, so I stopped it. Any help would be appreciated. (Sorry if this isn't the most relevant place to be asking questions about the compilation.)

Raytwo commented 2 years ago

Hi @GlossyCoin15, simply add « self. » in front of the fill_impl call to fix the problem.

GlossyCoin15 commented 2 years ago

That's what causes the second screenshot to occur.

jam1garner commented 2 years ago

Fixed (cc @GlossyCoin15 )

https://github.com/jam1garner/smash-minecraft-skins/releases/tag/v1.2.3