Skip to content

Commit a8f8bec

Browse files
committed
Yoshi Skip and Blimp Ticket Skip displays - call drawStickAngle instead of manually drawing the stick angle
1 parent 3dfb092 commit a8f8bec

File tree

2 files changed

+19
-26
lines changed

2 files changed

+19
-26
lines changed

ttyd-tools/rel/source/codes.cpp

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1074,18 +1074,6 @@ void displayStickAngle()
10741074
return;
10751075
}
10761076

1077-
// Don't display if the Yoshi Skip display is active
1078-
if (Displays[YOSHI_SKIP])
1079-
{
1080-
return;
1081-
}
1082-
1083-
// Don't display if the Blimp Ticket Skip display is active
1084-
if (Displays[BLIMP_TICKET_SKIP])
1085-
{
1086-
return;
1087-
}
1088-
10891077
drawFunctionOnDebugLayer(drawStickAngle);
10901078
}
10911079

ttyd-tools/rel/source/draw.cpp

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3934,7 +3934,7 @@ void drawMarioSpeedXZ()
39343934
PosY += 20;
39353935
}
39363936

3937-
// Move the text up if the Mario coordinates display is active
3937+
// Move the text up if the Mario Coordinates display is active
39383938
if (Displays[MARIO_COORDINATES] ||
39393939
Displays[YOSHI_SKIP] ||
39403940
Displays[PALACE_SKIP] ||
@@ -4040,8 +4040,9 @@ void drawStickAngle()
40404040
PosY += 20;
40414041
}
40424042

4043-
// Move the text up if the Mario coordinates display is active
4043+
// Move the text up if the Mario Coordinates display is active
40444044
if (Displays[MARIO_COORDINATES] ||
4045+
Displays[YOSHI_SKIP] ||
40454046
Displays[PALACE_SKIP] ||
40464047
Displays[BRIDGE_SKIP])
40474048
{
@@ -4111,17 +4112,19 @@ void drawYoshiSkipDetails()
41114112
}
41124113

41134114
// Draw the text
4114-
char StickAngleString[32];
4115-
getStickAngleString(StickAngleString);
4116-
41174115
char *tempDisplayBuffer = DisplayBuffer;
41184116
sprintf(tempDisplayBuffer,
4119-
"YST: %" PRIu32 "\nStickAngle: %s",
4120-
YoshiSkip.MainTimer,
4121-
StickAngleString);
4117+
"YST: %" PRIu32,
4118+
YoshiSkip.MainTimer);
41224119

41234120
drawText(tempDisplayBuffer, PosX, PosY, Alpha, TextColor, Scale);
41244121

4122+
// Draw the Stick Angle if it's not already drawn
4123+
if (!Displays[STICK_ANGLE])
4124+
{
4125+
drawStickAngle();
4126+
}
4127+
41254128
// Draw Mario's coordinates if they're not already drawn
41264129
if (!Displays[MARIO_COORDINATES])
41274130
{
@@ -4374,18 +4377,20 @@ void drawBlimpTicketSkipDetails()
43744377
}
43754378

43764379
// Draw the text
4377-
char StickAngleString[32];
4378-
getStickAngleString(StickAngleString);
4379-
43804380
char *tempDisplayBuffer = DisplayBuffer;
43814381
sprintf(tempDisplayBuffer,
4382-
"URT: %" PRIu32 "\nSUT: %" PRIu32 "\nStickAngle: %s",
4382+
"URT: %" PRIu32 "\nSUT: %" PRIu32,
43834383
BlimpTicketSkip.UpRightTimer,
4384-
BlimpTicketSkip.StraightUpTimer,
4385-
StickAngleString);
4384+
BlimpTicketSkip.StraightUpTimer);
43864385

43874386
drawText(tempDisplayBuffer, PosX, PosY, Alpha, TextColor, Scale);
43884387

4388+
// Draw the Stick Angle if it's not already drawn
4389+
if (!Displays[STICK_ANGLE])
4390+
{
4391+
drawStickAngle();
4392+
}
4393+
43894394
// Draw Mario's coordinates if they're not already drawn
43904395
if (!Displays[MARIO_COORDINATES])
43914396
{

0 commit comments

Comments
 (0)