Remove invisible walls [jawa] - Printable Version +- Mario Kart Wii Gecko Codes, Cheats, & Hacks (https://mariokartwii.com) +-- Forum: Cheat Codes (https://mariokartwii.com/forumdisplay.php?fid=51) +--- Forum: Visual & Sound Effects (https://mariokartwii.com/forumdisplay.php?fid=56) +--- Thread: Remove invisible walls [jawa] (/showthread.php?tid=2001) |
Remove invisible walls [jawa] - jawa - 11-19-2022 Removes invisible walls. WARNING! Halfpipes do not work as intended. NTSC-U C251508C 0000001C 7D2000A6 552C045E 7D800124 38210120 9421FF60 BDC10008 7E4802A6 2C030000 418200A4 48000011 636F7572 73652E6B 636C0000 7E2802A6 7F95E378 3A600000 7E138A14 89F00000 7E13AA14 89D00000 7E8F7214 2C140000 41820018 7C0F7000 41820008 48000060 3A730001 4BFFFFD4 7C701B78 82300008 82B0000C 7E318214 7EB58214 7E348B78 7C14A800 41800008 48000034 A274000E 39E0001F 7E737838 2C13001F 41810020 2C13000D 41820008 4800000C 39E00018 91F4000E 3A940010 4BFFFFC8 7E4803A6 B9C10008 382100A0 7D8000A6 512C0420 7D800124 00000000 PAL C2519500 0000001C 7D2000A6 552C045E 7D800124 38210120 9421FF60 BDC10008 7E4802A6 2C030000 418200A4 48000011 636F7572 73652E6B 636C0000 7E2802A6 7F95E378 3A600000 7E138A14 89F00000 7E13AA14 89D00000 7E8F7214 2C140000 41820018 7C0F7000 41820008 48000060 3A730001 4BFFFFD4 7C701B78 82300008 82B0000C 7E318214 7EB58214 7E348B78 7C14A800 41800008 48000034 A274000E 39E0001F 7E737838 2C13001F 41810020 2C13000D 41820008 4800000C 39E00018 91F4000E 3A940010 4BFFFFC8 7E4803A6 B9C10008 382100A0 7D8000A6 512C0420 7D800124 00000000 NTSC-J C2518E80 0000001C 7D2000A6 552C045E 7D800124 38210120 9421FF60 BDC10008 7E4802A6 2C030000 418200A4 48000011 636F7572 73652E6B 636C0000 7E2802A6 7F95E378 3A600000 7E138A14 89F00000 7E13AA14 89D00000 7E8F7214 2C140000 41820018 7C0F7000 41820008 48000060 3A730001 4BFFFFD4 7C701B78 82300008 82B0000C 7E318214 7EB58214 7E348B78 7C14A800 41800008 48000034 A274000E 39E0001F 7E737838 2C13001F 41810020 2C13000D 41820008 4800000C 39E00018 91F4000E 3A940010 4BFFFFC8 7E4803A6 B9C10008 382100A0 7D8000A6 512C0420 7D800124 00000000 NTSC-K C2507520 0000001C 7D2000A6 552C045E 7D800124 38210120 9421FF60 BDC10008 7E4802A6 2C030000 418200A4 48000011 636F7572 73652E6B 636C0000 7E2802A6 7F95E378 3A600000 7E138A14 89F00000 7E13AA14 89D00000 7E8F7214 2C140000 41820018 7C0F7000 41820008 48000060 3A730001 4BFFFFD4 7C701B78 82300008 82B0000C 7E318214 7EB58214 7E348B78 7C14A800 41800008 48000034 A274000E 39E0001F 7E737838 2C13001F 41810020 2C13000D 41820008 4800000C 39E00018 91F4000E 3A940010 4BFFFFC8 7E4803A6 B9C10008 382100A0 7D8000A6 512C0420 7D800124 00000000 Code: # System::DVDArchive::getFile([DVDArchive* d_arc], char const*, unsigned int*) RE: Remove invisible walls [jawa] - Seeky - 11-20-2022 You can get weird bugs by manually disabling interrupts if a context switch happens after your mfmsr and before your mtmsr, and the msr is changed on another thread. OSLoadContext has special code to prevent this issue in OSDisableInterrupts (moves pc back to the start of the function if it was interrupted before the mtmsr), so really you should always call the actual function for this Also, do you actually need interrupts disabled here? RE: Remove invisible walls [jawa] - Vega - 11-20-2022 @Seeky Just to make sure I understand your post, does "Context Switch" refer to an external interrupt (of any sort) occurring on one of the first two instructions of his manual disable interrupts code? When I see Context Switch, I personally keep thinking of Context Synchronization (isync), lol. Also, are you saying he should function call OSDisableInterrupts or any such task? Or are you saying to function call OSSave/Load Context which itself later on calls OSDisable/Restore Interrupts ? Because if it's the former, then yes that would make sense. He would either need to call OSDisableInterrupts, or just execute the exact function manually (so r3 and r4 are used/filled accordingly if a external interrupt does indeed happen during this time). At the end of his code, the method in which he restores interrupts shouldn't matter as long as he grabs the latest MSR and re-inserts the original MSR EE bit since interrupts are disabled at this moment in time. In essence, the Restore Interrupts function is "silly" for its need to check r3 (old EE bit) and branch. A simple bit re-insertion should work. I just woke up, so apologies if I'm missing something obvious. Regardless, I share your same final thought, I'm not sure why Interrupts are being disabled at all? --- @Jawa Nice work on learning some of the more advanced stuff on PPC Assembly. Was there a weird issues occurring in your code before you added in the Interrupt stuff? RE: Remove invisible walls [jawa] - Seeky - 11-20-2022 I'm saying that using a manual recreation of OSDisableInterrupts instead of calling the actual function isn't safe Context switch being a change between threads (OSLoadContext) RE: Remove invisible walls [jawa] - Vega - 11-21-2022 Looks like I'll have to update a couple of my tutorial threads due to now learning about this. RE: Remove invisible walls [jawa] - jawa - 11-21-2022 (11-20-2022, 01:07 PM)Seeky Wrote: You can get weird bugs by manually disabling interrupts if a context switch happens after your mfmsr and before your mtmsr, and the msr is changed on another thread. OSLoadContext has special code to prevent this issue in OSDisableInterrupts (moves pc back to the start of the function if it was interrupted before the mtmsr), so really you should always call the actual function for this Dolphin would sometimes crash. Maybe it's just an issue on my machine, but i included it just in case. |