11-12-2020, 07:02 PM
(This post was last modified: 01-02-2021, 01:28 PM by WhatisLoaf.
Edit Reason: dangling quote
)
This code replaces any number of texts with your own custom text.
It's basically the same code as the one used to change the title in the custom top 10 code.
As such I've modifed both so they don't interfere with eachother.
The program can be found here: https://www.tt-rec.com/msgeditor/
Some explanation on how to use it: https://www.tt-rec.com/howto/?page=msgeditor
A common use case for this is changing the "Personal Record" text to "World Champion" in the MK channel.
Just like the top 10 code, this is not really meant to be compiled manually but below is the source code for an example that replaces 2 message texts.
It's basically the same code as the one used to change the title in the custom top 10 code.
As such I've modifed both so they don't interfere with eachother.
The program can be found here: https://www.tt-rec.com/msgeditor/
Some explanation on how to use it: https://www.tt-rec.com/howto/?page=msgeditor
A common use case for this is changing the "Personal Record" text to "World Champion" in the MK channel.
Just like the top 10 code, this is not really meant to be compiled manually but below is the source code for an example that replaces 2 message texts.
Code:
#Address Ports
#NTSC-U = 805C12A8
#PAL = 805CDDC8
#NTSC-J = 805CD6A4
#NTSC-K = 805BBD88
mflr r11
bl set_address
# all strings are placed here back to back
# it's important to include 0000 at the end of every string to terminate it properly
.long XXXXXXXX
mflr r12
set_address:
cmpwi r14, 0xIIII # message ID 1
bne- next_id
mr r3, r12 # replace the address with our address
next_id:
cmpwi r14, 0xJJJJ # message ID 2
bne- function_end
addi r3, r12, 0x0001
function_end:
stw r3, 0x20(sp)
mtlr r11