Jump to content

OoT / MM Interface Documentation


SanguinettiMods
 Share

Recommended Posts

Some of these things have been written down in the form of gameshark codes, but didn't always work correctly. I re documented some things in the form of ASM Blocks.
 
OoT - Incomplete, won't be for a while.
 

  Reveal hidden contents


 
Why is this useful? For the longest time, I couldn't find some attributes like the small key counter by sifting through RAM dumps. I also couldn't color the hearts outline independently from the hearts themselves, but with this small hack I made, you can.
 
 

.ORG 0x80078A64
J 0x801A0000
NOP
 
.ORG 0x80078BA8
ADDIU R0, R0, 0x0000
 
.ORG 0x80078BD4
ADDIU R0, R0, 0x0000
 
.ORG 0x80078BE8
ADDIU R0, R0, 0x0000
 
.ORG 0x80078C44
ADDIU R0, R0, 0x0000
 
.ORG 0x80078C74
ADDIU R0, R0, 0x0000
 
.ORG 0x80078C8C
ADDIU R0, R0, 0x0000
 
.ORG 0x80078AD4
ADDIU R0, R0, 0x0000
ADDIU R0, R0, 0x0000
ADDIU R0, R0, 0x0000
ADDIU R0, R0, 0x0000
ADDIU R0, R0, 0x0000
ADDIU R0, R0, 0x0000
 
.ORG 0x801A0000
LUI A0, 0x8022
ADDIU A0, A0, 0x2510
ADDIU T0, R0, 0x00FF ; Beating Heart Red Value
ANDI T1, T0, 0x00FF
SH T1, 0x0202(A0) ; Store Beating Heart Red Value
ADDIU T0, R0, 0x0046 ; Beating Heart Green Value
ANDI T1, T0, 0x00FF
SH T1, 0x0204(A0) ; Store Beating Heart Green Value
ADDIU T0, R0, 0x0032 ; Beating Heart Blue Value
ANDI T1, T0, 0x00FF
SH T1, 0x0206(A0) ; Store Beating Heart Blue Value
ADDIU T0, R0, 0x0032 ; Beating Heart Outline Red Value
ANDI T1, T0, 0x00FF
SH T1, 0x0208(A0) ; Store Beating Heart Outline Red Value
ADDIU T0, R0, 0x0028 ; Beating Heart Outline Green Value
ANDI T1, T0, 0x00FF
SH T1, 0x020A(A0) ; Store Beating Heart Outline Green Value
ADDIU T0, R0, 0x003C ; Beating Heart Outline Blue Value
ANDI T1, T0, 0x00FF
SH T1, 0x020C(A0) ; Store Beating Heart Outline Blue Value
ADDIU T0, R0, 0x00FF ; Heart Red Value
SH T0, 0x020E(A0) ; Store Heart Red Value
ADDIU T2, R0, 0x0046 ; Heart Green Value
SH T2, 0x0212(A0) ; Store Heart Green Value
ADDIU T0, R0, 0x0032 ; Heart Blue Value
SH T0, 0x0216(A0) ; Store Heart Blue Value
ADDIU T0, R0, 0x0032 ; Heart Outline Red Value
SH T0, 0x021A(A0) ; Store Heart Outline Red Value
ADDIU T0, R0, 0x0028 ; Heart Outline Green Value
SH T0, 0x021E(A0) ; Store Heart Outline Green Value
ADDIU T0, R0, 0x003C ; Heart Outline Blue Value
SH T0, 0x0222(A0) ; Store Heart Outline Blue Value
NOP
 
J 0x80078A68
NOP

MM - Incomplete, won't be for a while

  Reveal hidden contents

  • Like 3
Link to comment
Share on other sites

Since I wrote this just the other day, I may just as well contribute with it:

http://pastebin.com/qGDVSxda

That is a very, very small ASM hack that allows you to set the red green and blue of all the interface buttons individually.

 

Also, here's the RAM addresses for the Start Button Colors:

S Button Red & Green: 0x80089180

S Button Blue: 0x80089184

It doesn't use the same format as the other buttons. each color is a byte rather than a halfword.

 

I think all other things I have are there already? My documentation is such a big mess, I can't even find things myself. (it's a 900 rows text document filled with random stuff for the title screen, file select, pause menues and interface... Unorganized, etc.)

 

Edit:

A bunch of things for MM NSTC-U 1.0

80117390 Start Button Green

80117394 Start Button Blue

8011739C Start Button Red

Clock stuff:

80119914 Hour Lines Red & Green

80119918 Hour Lines Blue

801199D8 Halfcircle Blue

8011A110 Diamond Red & Green

8011A114 Diamond Blue

8011A1A4 Day Number Blue

8011A39C Star Red & Green

8011A3A0 Star Blue

8011A738 Sun Red & Green

8011A73C Sun Blue

8011A888 Moon Red & Green

8011A88C Moon Blue

8011AB84 Sun Text Blue

8011AD20 Moon Text Blue

 

I haven't doublechecked if these things actually are 100% correct, but it's what I have in my document.

That's about everything I have on MM (that isn't already in the main post) since I lost all my documentation last year when my computer had a rollback after it crashed.

  • Like 1
Link to comment
Share on other sites

  On 1/27/2014 at 8:23 PM, â–²ChriisTiianâ–² said:

I will locate all addresses of OoT Interface in ROM.

Thanks Sanguinetti & CloudMax for sharing this!.

That's some very simple math.

Take the addresses and subtract by 0x0001CE60. That gives you their offset in the code.zasm file.

If you want the offset withen the whole ROM directly, just add 0xA771A0.

Link to comment
Share on other sites

Yeah. First I looked up which file the code was located in. (took a small sample surrounding one of the addresses mentioned in the thread, searched for that in the ROM, checked which file that address belonged too)

It were located in the code.zasm, so we know that all the addresses are in there.

Then I just looked up where the code.zasm started in the RAM by taking a sample of the beginning of the code.zasm file and searching for it in the RAM, and it was at 0x0001CE60. So I know that by subtracting that value, we'll convert the addresses to their addresses relative to the code.zasm file.

Then I looked up where the code.zasm is located in the ROM, which is 0x00A94000.

And 0x00A94000-0x0001CE60=0x00A771A0

 

This is how I convert big bunches of RAM addresses to ROM addresses. A lot more useful than looking up all of them manually.

  • Like 2
Link to comment
Share on other sites

I'm working on the code.zasm file right now and so far have the A and B buttons done. I can release for download if anyone is interested once I'm completed.

 

@CloudMax: Are you sure the B button is completely correct? It seems a bit brighter green than it is in MM which is a duller green. Also, the start menu button color has not changed, it's still grayish black, not red. There were no changes in the coding for it.

 

Edit: I have finished the code.zasm and while it works on my actual hack in progress, applying it to a clean debug ROM makes it fail to boot so I'm not quite sure why it is doing this at the moment. CRC is okay so I'm going to look into why it is doing this. If anyone else has any ideas, that would be great to hear.

Edited by !Tommy
Link to comment
Share on other sites

Ops. The Start Button is still gray because the pastebin I linked to set it to the default color (gray).

the color should be FF823C not 787878 for it to be the MM color.

 

And I'm not sure why it doesn't work for you with a clean ROM, I'll test it myself and see what happens.

 

Edit:

I tried it myself, and it works just fine.

Edited by CloudMax
Link to comment
Share on other sites

  On 1/28/2014 at 1:45 PM, CloudMax said:

Ops. The Start Button is still gray because the pastebin I linked to set it to the default color (gray).

the color should be FF823C not 787878 for it to be the MM color.

 

And I'm not sure why it doesn't work for you with a clean ROM, I'll test it myself and see what happens.

 

Edit:

I tried it myself, and it works just fine.

I'm guessing because I extracted the entire code.zasm file from another debug ROM and plugged it into a clean one. Maybe it's not so much the button colors that changed but maybe I have another code change in my hack that the clean ROM isn't liking much. I can always upload the file and you can take a look at it if you so desire.

 

Here's the file, complete with all MM HUD style and colors: http://wikisend.com/download/127854/code.zasm

 

If anyone wants to try it out, feel free to but be warned that it might cause your game not to load properly.

Edited by !Tommy
Link to comment
Share on other sites

I hope you're aware that the code.zasm file you linked is not actually a code.zasm file. I opened it in a hex viewer and this is the first thing I see "%PDF-1.4.%âãÃÓ.3 0 obj.<</Subtype/Link/Rect[247.18 662.52 345.26 673.62]/A<</S/URI/URI(http://BitManual.com)>>/Border[0 0 0]/C[0 0 1]>>.endobj.4 0 obj.<</Subtype/Link/Rect[294.68 194.52 426.02 205.62]/A<</S/URI/URI(http://BitManual.com)>>/Border[0 0 0]/C[0 0 1]>>.endobj.5 0 obj.<</Length 1960/Filter/FlateDecode>>stream"

Could it be that you messed up and renamed some file to code.zasm? Because I am very confused right now, lol.

Link to comment
Share on other sites

  • 8 months later...

I know this has been a long time, but I am having a really hard time finding the A and B buttons ROM addresses for colour. I've done what was said above and once I modified the values and nothing happened, the second time on a copy of the same clean rom crashed the game. I'm thinking I obviously had the wrong addresses. 

Link to comment
Share on other sites

I thought they were textures and not controlled by the ROM but it appears I am wrong according to the Wiki:

 

http://wiki.spinout182.com/w/Interface_Hacking

 

I think these are gameshark codes so some adjusting may be in order. I am assuming the three values are RGB

Button Colours/Hue

Details         Code        Default Value
A-Button

            801C7951 00??    005A
            801C7953 00??    005A
            801C7955 00??    00FF

B-Button

            801C767B 00??    0000
            801C767D 00??    0096
            801C767F 00??    0000


C-Buttons

            801C7673 00??    00FF
            801C7675 00??    00A0
            801C7677 00??    0000

Map

            801C7DC9 00??    0000
            801C7DCB 00??    00FF
            801C7DCD 00??    00FF

Link to comment
Share on other sites

http://cloudmodding.com/applications/z64editor/resources/data/documentation.txt old documentation of mine from when I worked on the z64editor. (which originally was developed for MM, but then moved over to OoT debug ROM because people didn't give a shit about MM :P)

Go down to the "MAJORA'S MASK NTSC-U" section. everything below that is for majora's mask. it contains a whole lot of information about the MM interface, some of which may not be documented elsewhere.

It's all RAM though, but it should be easy to convert.

Link to comment
Share on other sites

 Share

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.