summaryrefslogtreecommitdiff
path: root/src/engine
diff options
context:
space:
mode:
authorKiritoDv <kiritodev01@gmail.com>2024-10-16 18:09:09 -0600
committerKiritoDv <kiritodev01@gmail.com>2024-10-16 18:09:09 -0600
commitbdf56300dfea2f428c43dd700de4603033df0de7 (patch)
tree4c2bb1415d15340cc39ce6944e2fd71d17172c38 /src/engine
parent3ef4f3b78d30fa3d1caa0694c10e69892f2e5631 (diff)
Fixed widescreen issues i think
Diffstat (limited to 'src/engine')
-rw-r--r--src/engine/fox_fade.c8
-rw-r--r--src/engine/fox_game.c4
-rw-r--r--src/engine/fox_hud.c6
-rw-r--r--src/engine/fox_std_lib.c2
4 files changed, 10 insertions, 10 deletions
diff --git a/src/engine/fox_fade.c b/src/engine/fox_fade.c
index 449cf264..5c5d51a4 100644
--- a/src/engine/fox_fade.c
+++ b/src/engine/fox_fade.c
@@ -1,13 +1,13 @@
#include "global.h"
void Wipe_Horizontal(s32 frame) {
- Graphics_FillRectangle(&gMasterDisp, 0, 0, frame, SCREEN_HEIGHT, 0, 0, 0, 255);
- Graphics_FillRectangle(&gMasterDisp, SCREEN_WIDTH - frame, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0, 0, 255);
+ Graphics_FillRectangle(&gMasterDisp, OTRGetRectDimensionFromLeftEdge(0), 0, OTRGetRectDimensionFromRightEdge(frame), SCREEN_HEIGHT, 0, 0, 0, 255);
+ Graphics_FillRectangle(&gMasterDisp, OTRGetRectDimensionFromLeftEdge(SCREEN_WIDTH - frame), 0, OTRGetRectDimensionFromRightEdge(SCREEN_WIDTH), SCREEN_HEIGHT, 0, 0, 0, 255);
}
void Wipe_Vertical(s32 frame) {
- Graphics_FillRectangle(&gMasterDisp, 0, 0, SCREEN_WIDTH, frame, 0, 0, 0, 255);
- Graphics_FillRectangle(&gMasterDisp, 0, SCREEN_HEIGHT - frame, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0, 0, 255);
+ Graphics_FillRectangle(&gMasterDisp, OTRGetRectDimensionFromLeftEdge(0), 0, OTRGetRectDimensionFromRightEdge(SCREEN_WIDTH), frame, 0, 0, 0, 255);
+ Graphics_FillRectangle(&gMasterDisp, OTRGetRectDimensionFromLeftEdge(0), SCREEN_HEIGHT - frame, OTRGetRectDimensionFromRightEdge(SCREEN_WIDTH), SCREEN_HEIGHT, 0, 0, 0, 255);
}
void Wipe_Circular(s32 frame) {
diff --git a/src/engine/fox_game.c b/src/engine/fox_game.c
index 2e7cfef9..f6f131d7 100644
--- a/src/engine/fox_game.c
+++ b/src/engine/fox_game.c
@@ -554,7 +554,7 @@ void Game_Update(void) {
partialFill = false;
if (gCamCount == 1) {
- Graphics_FillRectangle(&gMasterDisp, 0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1, gPlayerGlareReds[0],
+ Graphics_FillRectangle(&gMasterDisp, OTRGetRectDimensionFromLeftEdge(0), 0, OTRGetRectDimensionFromRightEdge(SCREEN_WIDTH - 1), SCREEN_HEIGHT - 1, gPlayerGlareReds[0],
gPlayerGlareGreens[0], gPlayerGlareBlues[0], gPlayerGlareAlphas[0]);
if ((gDrawMode == DRAW_PLAY) || (gDrawMode == DRAW_ENDING)) {
Radio_Draw();
@@ -591,7 +591,7 @@ void Game_Update(void) {
Wipe_Draw(WIPE_CIRCULAR, gCircleWipeFrame);
if (!partialFill) {
- Graphics_FillRectangle(&gMasterDisp, 0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1, gFillScreenRed,
+ Graphics_FillRectangle(&gMasterDisp, OTRGetRectDimensionFromLeftEdge(0), 0, OTRGetRectDimensionFromRightEdge(SCREEN_WIDTH - 1), SCREEN_HEIGHT - 1, gFillScreenRed,
gFillScreenGreen, gFillScreenBlue, gFillScreenAlpha);
}
Audio_dummy_80016A50();
diff --git a/src/engine/fox_hud.c b/src/engine/fox_hud.c
index 45d6979e..d32b2fe5 100644
--- a/src/engine/fox_hud.c
+++ b/src/engine/fox_hud.c
@@ -1452,7 +1452,7 @@ void HUD_PauseScreen_Update(void) {
sPauseScreenTimer[0] = 0;
case 3:
- Graphics_FillRectangle(&gMasterDisp, 0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1, 0, 0, 0, 255);
+ Graphics_FillRectangle(&gMasterDisp, OTRGetRectDimensionFromLeftEdge(0), 0, OTRGetRectDimensionFromRightEdge(SCREEN_WIDTH - 1), SCREEN_HEIGHT - 1, 0, 0, 0, 255);
gFillScreenAlphaTarget = 0;
@@ -1501,7 +1501,7 @@ void HUD_PauseScreen_Update(void) {
break;
case 4:
- Graphics_FillRectangle(&gMasterDisp, 0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1, 0, 0, 0, 255);
+ Graphics_FillRectangle(&gMasterDisp, OTRGetRectDimensionFromLeftEdge(0), 0, OTRGetRectDimensionFromRightEdge(SCREEN_WIDTH - 1), SCREEN_HEIGHT - 1, 0, 0, 0, 255);
if (sPauseScreenTimer[0] < 140) {
break;
}
@@ -1519,7 +1519,7 @@ void HUD_PauseScreen_Update(void) {
}
case 5:
- Graphics_FillRectangle(&gMasterDisp, 0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1, 0, 0, 0, 255);
+ Graphics_FillRectangle(&gMasterDisp, OTRGetRectDimensionFromLeftEdge(0), 0, OTRGetRectDimensionFromRightEdge(SCREEN_WIDTH - 1), SCREEN_HEIGHT - 1, 0, 0, 0, 255);
for (i = 0; i < 6; i++) {
if (gPrevPlanetTeamShields[i] == -1) {
diff --git a/src/engine/fox_std_lib.c b/src/engine/fox_std_lib.c
index 4e821ed3..b3c4e9c4 100644
--- a/src/engine/fox_std_lib.c
+++ b/src/engine/fox_std_lib.c
@@ -733,7 +733,7 @@ void Graphics_FillRectangle(Gfx** gfxPtr, s32 ulx, s32 uly, s32 lrx, s32 lry, u8
gDPSetCycleType((*gfxPtr)++, G_CYC_1CYCLE);
gDPSetCombineMode((*gfxPtr)++, G_CC_PRIMITIVE, G_CC_PRIMITIVE);
gDPSetRenderMode((*gfxPtr)++, G_RM_CLD_SURF, G_RM_CLD_SURF2);
- gDPFillRectangle((*gfxPtr)++, ulx, uly, lrx, lry);
+ gDPFillWideRectangle((*gfxPtr)++, ulx, uly, lrx, lry);
}
}