Code Patcher v1.0 [JoshuaMK]
#8
Hey Joshua, here's how you can get Easy Extender to work... (the limit for display aka string lenghth is a lot less than Star/Riis code btw) So if everything is right and it still fails, you may have went beyond the string length limit. Or... YS's code is using some part of the Exception Vectors that you are using too, to get around that, just throw shit on the stack and increase the frame size accordingly... View some of star's complex codes to see how to save extra data to the stack for doing args for function calls

First, grab everything BUT the C0 code from the original Easy Extender - http://mkwii.com/showthread.php?tid=790 This will be at the beginning of your code.

So with this, you have two function calls available in an ASM code...

Sprintf:
lis rX, 0x8000
lwz rX, 0x1858 (rX)
mtlr rX
blrl

Draw Code:
lis rX, 0x8000
lwz rX, 0x1850 (rX)
mtlr rX
blrl

Next you will make a C0 code....

When you push the stack frame, do this instruction right before to backup the LR...
mflr r12

Once you pop the stack frame, do this instruction right after
mtlr r12

Args for the Draw code...
r3 = Pointer where data is (already converted from previous sprintf)
r4 1st byte = X coordinate (make this 01)
r4 2nd byte = Y coordinate (make this 02)
r4 3rd byte = font color (make this 02)
r4 4th byte = bg color (make this 01)

I use to have a list of ALL the color combos but wiped them by mistake. they may be on the wayback machine somewhere (when the site was mkwii.org)... if you care enough

ofc since you use the python compiler like me, you don't need to add the blr at the end for the C0 code.

I just did a test run for "hello world" with these guidelines and it works. So if this works for you, your code will for the Wii console on ALL games.
I tried doing this for my Mem Viewer code but I bypassed the string length limit by a mile, so there's really no point bothering with it anymore....
Reply


Messages In This Thread
Code Patcher v1.0 [JoshuaMK] - by JoshuaMK - 10-16-2019, 05:49 AM
RE: Code Patcher v1.0 [JoshuaMK] - by Vega - 10-16-2019, 04:48 PM
RE: Code Patcher v1.0 [JoshuaMK] - by JoshuaMK - 10-16-2019, 04:56 PM
RE: Code Patcher v1.0 [JoshuaMK] - by Vega - 10-16-2019, 10:15 PM
RE: Code Patcher v1.0 [JoshuaMK] - by salmon01 - 10-17-2019, 01:38 AM
RE: Code Patcher v1.0 [JoshuaMK] - by Star - 10-17-2019, 10:56 PM
RE: Code Patcher v1.0 [JoshuaMK] - by Vega - 10-17-2019, 11:02 PM
RE: Code Patcher v1.0 [JoshuaMK] - by Vega - 11-19-2019, 12:31 AM
RE: Code Patcher v1.0 [JoshuaMK] - by JoshuaMK - 11-19-2019, 02:21 AM
RE: Code Patcher v1.0 [JoshuaMK] - by Vega - 11-19-2019, 03:27 AM
RE: Code Patcher v1.0 [JoshuaMK] - by JoshuaMK - 11-19-2019, 03:36 AM
RE: Code Patcher v1.0 [JoshuaMK] - by Vega - 11-19-2019, 04:08 AM
RE: Code Patcher v1.0 [JoshuaMK] - by JoshuaMK - 11-19-2019, 05:27 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)