Skip to content

Commit f1758b1

Browse files
committed
Renamed writeBranchLR to writeBranchBL
1 parent e36ecaa commit f1758b1

File tree

3 files changed

+19
-19
lines changed

3 files changed

+19
-19
lines changed

ttyd-tools/rel/include/patch.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ namespace mod::patch {
77
void clear_DC_IC_Cache(void *ptr, uint32_t size);
88
void writeStandardBranches(void *address, void functionStart(), void functionBranchBack());
99
void writeBranch(void *ptr, void *destination);
10-
void writeBranchLR(void *ptr, void *destination);
10+
void writeBranchBL(void *ptr, void *destination);
1111
void writeBranchMain(void *ptr, void *destination, uint32_t branch);
1212

1313
template<typename Func, typename Dest>

ttyd-tools/rel/source/main.cpp

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -684,39 +684,39 @@ void initAddressOverwrites()
684684
void *FallThroughMostObjectsBowserAddress = reinterpret_cast<void *>(0x8021DD9C);
685685
#endif
686686

687-
patch::writeBranchLR(AllowRunningFromBattlesAddress, reinterpret_cast<void *>(StartAllowRunningFromBattles));
687+
patch::writeBranchBL(AllowRunningFromBattlesAddress, reinterpret_cast<void *>(StartAllowRunningFromBattles));
688688

689-
patch::writeBranchLR(ForceNPCItemDropAddress, reinterpret_cast<void *>(StartForceNPCItemDrop));
689+
patch::writeBranchBL(ForceNPCItemDropAddress, reinterpret_cast<void *>(StartForceNPCItemDrop));
690690

691-
patch::writeBranchLR(ReplaceJumpAnimAddress, reinterpret_cast<void *>(StartReplaceJumpFallAnim));
691+
patch::writeBranchBL(ReplaceJumpAnimAddress, reinterpret_cast<void *>(StartReplaceJumpFallAnim));
692692

693-
patch::writeBranchLR(DisplayBattleMenuJumpAddress, reinterpret_cast<void *>(StartDisplayMegaJumpBadgeBattleMenu));
693+
patch::writeBranchBL(DisplayBattleMenuJumpAddress, reinterpret_cast<void *>(StartDisplayMegaJumpBadgeBattleMenu));
694694

695-
patch::writeBranchLR(DisplayBattleMenuHammerAddress, reinterpret_cast<void *>(StartDisplayMegaHammerBadgesBattleMenu));
695+
patch::writeBranchBL(DisplayBattleMenuHammerAddress, reinterpret_cast<void *>(StartDisplayMegaHammerBadgesBattleMenu));
696696

697-
patch::writeBranchLR(FixBlooperCrash1Address, reinterpret_cast<void *>(StartFixBlooperCrash1));
697+
patch::writeBranchBL(FixBlooperCrash1Address, reinterpret_cast<void *>(StartFixBlooperCrash1));
698698

699-
patch::writeBranchLR(FixBlooperCrash2Address, reinterpret_cast<void *>(StartFixBlooperCrash2));
699+
patch::writeBranchBL(FixBlooperCrash2Address, reinterpret_cast<void *>(StartFixBlooperCrash2));
700700

701-
patch::writeBranchLR(PreventTextboxSelectionAddress, reinterpret_cast<void *>(StartPreventTextboxSelection));
701+
patch::writeBranchBL(PreventTextboxSelectionAddress, reinterpret_cast<void *>(StartPreventTextboxSelection));
702702

703-
patch::writeBranchLR(FixRoomProblemsAddress, reinterpret_cast<void *>(fixRoomProblems));
703+
patch::writeBranchBL(FixRoomProblemsAddress, reinterpret_cast<void *>(fixRoomProblems));
704704

705-
patch::writeBranchLR(DisableDPadOptionsDisplayAddress, reinterpret_cast<void *>(StartDisableDPadOptionsDisplay));
705+
patch::writeBranchBL(DisableDPadOptionsDisplayAddress, reinterpret_cast<void *>(StartDisableDPadOptionsDisplay));
706706

707-
patch::writeBranchLR(FixEvtMapBlendSetFlagPartnerCrashAddress, reinterpret_cast<void *>(StartFixEvtMapBlendSetFlagPartnerCrash));
707+
patch::writeBranchBL(FixEvtMapBlendSetFlagPartnerCrashAddress, reinterpret_cast<void *>(StartFixEvtMapBlendSetFlagPartnerCrash));
708708

709-
patch::writeBranchLR(FixEvtMapBlendSetFlagFollowerCrashAddress, reinterpret_cast<void *>(StartFixEvtMapBlendSetFlagFollowerCrash));
709+
patch::writeBranchBL(FixEvtMapBlendSetFlagFollowerCrashAddress, reinterpret_cast<void *>(StartFixEvtMapBlendSetFlagFollowerCrash));
710710

711-
patch::writeBranchLR(PreventPouchInitMemoryLeakAddress, reinterpret_cast<void *>(preventPouchInitMemoryLeak));
711+
patch::writeBranchBL(PreventPouchInitMemoryLeakAddress, reinterpret_cast<void *>(preventPouchInitMemoryLeak));
712712

713-
patch::writeBranchLR(InitStageEventsAddress, reinterpret_cast<void *>(initStageEvents));
713+
patch::writeBranchBL(InitStageEventsAddress, reinterpret_cast<void *>(initStageEvents));
714714

715-
patch::writeBranchLR(FallThroughMostObjectsStandAddress, reinterpret_cast<void *>(StartFallThroughMostObjectsStandard));
715+
patch::writeBranchBL(FallThroughMostObjectsStandAddress, reinterpret_cast<void *>(StartFallThroughMostObjectsStandard));
716716

717-
patch::writeBranchLR(FallThroughMostObjectsTubeAddress, reinterpret_cast<void *>(StartFallThroughMostObjectsStandard));
717+
patch::writeBranchBL(FallThroughMostObjectsTubeAddress, reinterpret_cast<void *>(StartFallThroughMostObjectsStandard));
718718

719-
patch::writeBranchLR(FallThroughMostObjectsBowserAddress, reinterpret_cast<void *>(StartFallThroughMostObjectsBowser));
719+
patch::writeBranchBL(FallThroughMostObjectsBowserAddress, reinterpret_cast<void *>(StartFallThroughMostObjectsBowser));
720720

721721
*reinterpret_cast<uint32_t *>(DebugModeInitialzeAddress) = 0x3800FFFF; // li r0,-1
722722
*reinterpret_cast<uint32_t *>(DebugModeShowBuildDateAddress) = 0x60000000; // nop

ttyd-tools/rel/source/patch.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ void writeBranch(void *ptr, void *destination)
2727
writeBranchMain(ptr, destination, branch);
2828
}
2929

30-
void writeBranchLR(void *ptr, void *destination)
30+
void writeBranchBL(void *ptr, void *destination)
3131
{
3232
uint32_t branch = 0x48000001; // bl
3333
writeBranchMain(ptr, destination, branch);

0 commit comments

Comments
 (0)