Skip to content

Commit 73529ba

Browse files
committed
Add missing unused user param to scissor_disp_control for correctness
1 parent f463287 commit 73529ba

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

ttyd-tools/rel/include/mod.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class Mod
3232
int32_t fixMarioKeyOn();
3333
bool performRelPatches(gc::OSModule::OSModuleInfo *, void *);
3434
ttyd::npcdrv::NpcEntry *fbatHitCheck_Work(uint32_t, void *);
35-
void drawArtAttackHitboxes(ttyd::dispdrv::CameraId);
35+
void drawArtAttackHitboxes(ttyd::dispdrv::CameraId, void *);
3636
int32_t displayActionCommandsTimingHook(void *, ttyd::battle_unit::AttackParams *);
3737
void errorHandler(uint16_t, gc::OSContext::OSContext *, uint32_t, uint32_t);
3838
ttyd::npcdrv::NpcEntry *checkForNpcNameToPtrError(const char *);
@@ -65,7 +65,7 @@ class Mod
6565
int32_t (*mPFN_marioKeyOn_trampoline)() = nullptr;
6666
bool (*mPFN_OSLink_trampoline)(gc::OSModule::OSModuleInfo *, void *) = nullptr;
6767
ttyd::npcdrv::NpcEntry *(*mPFN_fbatHitCheck_trampoline)(uint32_t, void *) = nullptr;
68-
void (*mPFN_scissor_disp_control_trampoline)(ttyd::dispdrv::CameraId) = nullptr;
68+
void (*mPFN_scissor_disp_control_trampoline)(ttyd::dispdrv::CameraId, void *) = nullptr;
6969

7070
int32_t (*mPFN_BattleActionCommandCheckDefence_trampoline)(
7171
void *, ttyd::battle_unit::AttackParams *) = nullptr;

ttyd-tools/rel/include/ttyd/sac_scissor.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ extern "C" {
1414
// scissor_init
1515
// scissor_disp_region
1616
// scissor_offscreen
17-
void scissor_disp_control(ttyd::dispdrv::CameraId cameraId);
17+
void scissor_disp_control(ttyd::dispdrv::CameraId cameraId, void *user);
1818
// scissor_capture
1919
// scissor_ofscreen_ok
2020
// scissor_damage_sub2

ttyd-tools/rel/source/draw.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6080,10 +6080,10 @@ void drawFileSelectScreenInfo()
60806080
drawTextAndInit(String, PosX, PosY, Alpha, TextColor, false, Scale);
60816081
}
60826082

6083-
void Mod::drawArtAttackHitboxes(ttyd::dispdrv::CameraId cameraId)
6083+
void Mod::drawArtAttackHitboxes(ttyd::dispdrv::CameraId cameraId, void *user)
60846084
{
60856085
// Call the original function immediately, as several functions need to run for the lines to be drawn properly
6086-
mPFN_scissor_disp_control_trampoline(cameraId);
6086+
mPFN_scissor_disp_control_trampoline(cameraId, user);
60876087

60886088
if (!Displays[ART_ATTACK_HITBOXES])
60896089
{

ttyd-tools/rel/source/mod.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,9 +133,9 @@ void Mod::init()
133133
});
134134

135135
mPFN_scissor_disp_control_trampoline = patch::hookFunction(
136-
ttyd::sac_scissor::scissor_disp_control, [](ttyd::dispdrv::CameraId cameraId)
136+
ttyd::sac_scissor::scissor_disp_control, [](ttyd::dispdrv::CameraId cameraId, void *user)
137137
{
138-
return gMod->drawArtAttackHitboxes(cameraId);
138+
return gMod->drawArtAttackHitboxes(cameraId, user);
139139
});
140140

141141
mPFN_BattleActionCommandCheckDefence_trampoline = patch::hookFunction(

0 commit comments

Comments
 (0)