Mario Kart Wii - Spying on a CPU

Channel:
Subscribers:
1,090
Published on ● Video Link: https://www.youtube.com/watch?v=zf5soaNkClQ



Game:
Duration: 0:00
851 views
44


This video shows a Mirror Special Cup Grand Prix from the perspective of a single CPU racer (in this case, Koopa Troopa) VS a human player (in this case, Funky Kong). On the lower-right side of the screen, the current speed of the CPU is displayed.

This better exposes the AI's particular behaviour, including rubberbanding, incredible steering as well as being able to pass through course objects.

For example, Koopa Troopa, despite being in one of the slowest vehicles, can reach speeds that easily surpass mine (I'm using the Spear, one of the fastest vehicles). This is mostly true when I'm far ahead from the CPU - if I am far behind him, the CPU will slow down considerably to make it easier for me to catch up. CPUs will vary their maximum speed throughout the race depending on this and a few other conditions, such as the current lap.

Likewise, CPUs are able to pass through course objects, such as the Moonview Highway cars (4:37), if they are far behind the human player (i.e. more than 5000 units behind). This is handled by function 0x807308dc (PAL), known as "Enemy::AIControlRace::watchPlayerAndSwitchCollision" in Mario Kart 7.

Note that despite the camera being attached to the CPU, the HUD as well as some camera effects (including going out of bounds) are still targetting the human player. This is just a side effects from the code I used.

-------------------------------

This was possible by using the cheat code below, which is a combination of various other codes by several creators. More specifically:

Racer Count Modifier (456) https ://mariokartwii.com/showthread.php?tid=2369 : Modifies the total racer count to 2 (me + the CPU)
Pretty Speedometer (stebler) https ://mariokartwii.com/showthread.php?tid=1730 : Allows you to view the speed on screen. I modified a line of this code to force it into displaying racer 1 (the CPU)'s speed.
Steer / Drift like CPUs (me) https ://mariokartwii.com/showthread.php?tid=2218 : Allows human players to steer like the CPUs would. I used this to make navigation for myself easier, as I the camera is attached to the CPU the whole time
Attach the camera to player ID (me) : This code forces the camera to be attached to the specified player ID (in this case, player 1, the CPU)

If you want to use the specific code I used in the video, here it is (again, this is a combination of the above codes, credits go to the respective creators). Note that this was only tested in Grand Prix / VS Race for this showcase, and may not work properly or crash the game if used under other conditions.

(PAL)
C252F914 00000002
3900000X 99040000
60000000 00000000
048ca7f8 807332a0
048ca850 807332a0
C267DE94 00000002
3800000Y 9803009C
8803009C 00000000
C2857CA0 00000002
7C63F214 83E1001C
60000000 00000000
04857EDC 56B50630
C25E88F0 00000006
4E800421 80930000
3CA0636F 60A5696E
7C042800 40820014
3C804370 90830190
38800020 B0830198
60000000 00000000
C2857F4C 0000001A
72A00001 408200BC
7CA802A6 4800003D
4358C30C C30CC365
436CC365 436CC336
41D0C343 42DC42DC
C2D2C2D2 4398C366
C366C3A6 43ACC3A6
43ACC33E 41C8C347
42E642E6 C2E6C2E6
7C6802A6 88810016
3884FFCF 7C848A14
5484083C 7C632214
3C808038 80846000
80840058 1C84001C
7C632214 A0830000
B094001C A083000E
B0940020 807400BC
80630014 80630010
3C803E80 90830040
90830044 38800002
988300FC 3865006C
2C150000 4182000C
3865FF94 62B50001
7C6803A6 4E800020
98140081 38600208
60000000 00000000
C27ED1D8 00000021
887E0081 2C030000
408200F8 8BFE0190
3C60809C 8063D728
7C63FA14 3880000Z
3C60809C 806318F8
80630020 5484103A
7C63202E 80630000
80630028 C0230020
38610008 3880000D
48000019 001A0800
00010030 0025002E
00320066 00000000
7CA802A6 4CC63242
3D808001 618C7814
7D8903A6 4E800421
38810010 387F0030
3CA0809C 80A5D728
1CDF00F0 7CA53214
80A500F4 2C050002
41820008 38650020
B064FFFE A0640000
2C030000 41820038
2C03002D 40820008
3860246D 2C03002E
40820008 3860246B
38A3FFD0 28050009
41810008 38652460
B0640000 38840001
4BFFFFC4 7FC3F378
38810008 38A00000
3D808063 618CDDB4
7D8903A6 4E800421
800100E4 00000000
C25F8C88 00000003
2C040000 4080000C
7C832378 4E800020
80A30010 00000000
045F8D08 7C832378
045F8D44 386DBFC4
045CDDAC 2C14FFFF
045CDDB0 4082000C

Where
X: Racer count (2)
Y: Player ID from the player you want to attach the camera to (1)
Z: Player ID from the player you wanna see their speed (1) (this is the line that was modified from the original speedometer code)

You can also use the following code alongside a button activator to temporarily stop CPUs from driving, in case you want to take some advantage (JoshuaMK): https ://mariokartwii.com/showthread.php?tid=1282

The codes above may have a side effect where, if you as a human don't keep driving or go very slow, you may get respawned. Use this to avoid such scenario from happening. This will prevent CPU racers from getting respawned if stuck too:

(PAL)
04744ba4 4e800020







Other Statistics

Mario Kart Wii Statistics For B_squo

There are 305,794 views in 173 videos for Mario Kart Wii. The game makes up 5 hours of published video on his channel, roughly 28.21% of Mario Kart Wii content that B_squo has uploaded to YouTube.