LE-CODE Code List Extender [JoshuaMK] - Printable Version +- Mario Kart Wii Gecko Codes, Cheats, & Hacks (https://mariokartwii.com) +-- Forum: Cheat Codes (https://mariokartwii.com/forumdisplay.php?fid=51) +--- Forum: Misc/Other (https://mariokartwii.com/forumdisplay.php?fid=55) +--- Thread: LE-CODE Code List Extender [JoshuaMK] (/showthread.php?tid=1403) |
LE-CODE Code List Extender [JoshuaMK] - JoshuaMK - 12-28-2019 LE-CODE Code List Extender [JoshuaMK] A tutorial for how to use this code can be found here: https://mkwii.com/showthread.php?tid=1406 This code is designed to be injected into the main.dol using wstrt PATCH main.dol --add-section NAME.gct --add-lecode --DEST ./lecode/main.dol -o, although it can be properly run in the dolphin codehandler (Not Riivolution's nor Gecko OS's due to differing instructions). When run, this code constantly checks for the file header of the lecode.bin file (LECT), and when found, it grabs the file's size from the file header, adds it to the base address of 0x808DD400 to reach the end of the file. It then does a check for the existence of the F0000000 00000000 found at the end of a gct, and if found, loops backwards in the file until it finds 00DEC0DE 00DEC0DE, in which it stores the new pointer address at 0x80002FFC. Then it finally modifies the codehandler to load the pointer address as the start of the code list instead of the static styled (lis, ori) method it normally uses. (Region Free) C0000000 0000000F 3D80808D 618CD400 3D604C45 616B4354 814C0000 7C0A5800 4CA20020 3D604E80 616B0020 916F0000 816C0014 7D4C5A14 3D20F000 856AFFF8 7C0B4800 4C820020 3D2000D0 6129C0DE 856AFFFC 7C0B4800 4082FFF8 3D808000 394AFFFC 914C2FFC 3D4081EF 614A2FFC 914C1908 7C0004AC 4E800020 00000000 Code Creator: JoshuaMK RE: LE-CODE Code List Extender [JoshuaMK] - Leseratte10 - 12-29-2019 First, please read my post in the other LE-CODE thread before using this: https://mkwii.com/showthread.php?tid=1376&pid=3722#pid3722 Second, you cannot just loop backwards over a GCT until you find the 00d0c0de magic, because while that marks the start of a GCT file, it could just as well appear in the middle of a C0 or C2 code, for example. This code would then probably (I didn't test it) not find the beginning of the GCT, but the middle of the GCT. |