Checkpoint Counter
Checkpoint Counter

This code will display (via the milliseconds section of the timer) how many checkpoints you have passed on the track. Checkpoint counter resets to 0 per lap. Works in Solo TT and Online only.

C2530930 00000003
A0DE000A 3D808053
3D6638A0 916C10A0
60000000 00000000

C2535478 00000003
A0DE000A 3D808053
3D6638A0 916C5BE8
60000000 00000000

C2534DF8 00000003
A0DE000A 3D808053
3D6638A0 916C5568
60000000 00000000

C25234D0 00000003
A0DE000A 3D808052
3D6638A0 916C3C40
60000000 00000000

#Values per Region

.set region, '' #Must set region value, or else source will not compile

.if (region == 'E' || region == 'e') # RMCE
    .set _1sthalf, 0x8053
    .set _2ndhalf, 0x10A0
.elseif (region == 'P' || region == 'p') # RMCP
    .set _1sthalf, 0x8053
    .set _2ndhalf, 0x5BE8
.elseif (region == 'J' || region == 'j') # RMCJ
    .set _1sthalf, 0x8053
    .set _2ndhalf, 0x5568
.elseif (region == 'K' || region == 'k') # RMCK
    .set _1sthalf, 0x8052
    .set _2ndhalf, 0x3C40
.else # Invalid Region

lhz r6, 0x000A (r30) #Default Instruction; r6 holds checkpoint value

lis r12, _1sthalf
addis r11, r6, 0x38A0 #Add 0x38A00000 to r6
stw r11, _2ndhalf (r12)

Code creator: zak
Code credits: SwareJonge (Used his original code to help find the checkpoint value in dynamic/high Mem80, which helped setup a read breakpoint); Bully (Millisecond Display Modifier Code creator); mdmwii (subroutine founder for Millisecond Display)

Forum Jump:

Users browsing this thread: 1 Guest(s)