Port Scrolling Texture Interpolation over from 2Ship (#6224)

This commit is contained in:
Christopher Leggett
2026-02-26 13:36:55 +00:00
committed by GitHub
parent c2cf154e3e
commit d4d3e8bc0f
109 changed files with 925 additions and 675 deletions
+6
View File
@@ -22,6 +22,7 @@ extern "C"
void gSPSegment(void* value, int segNum, uintptr_t target);
void gSPSegmentLoadRes(void* value, int segNum, uintptr_t target);
void gSPDisplayList(Gfx* pkt, Gfx* dl);
void gDPSetTileSizeInterp(Gfx* pkt, int t, float uls, float ult, float lrs, float lrt);
void gSPDisplayListOffset(Gfx* pkt, Gfx* dl, int offset);
void gSPVertex(Gfx* pkt, uintptr_t v, int n, int v0);
void gSPInvalidateTexCache(Gfx* pkt, uintptr_t texAddr);
@@ -1220,10 +1221,15 @@ void Gfx_SetupDL_56Ptr(Gfx** gfxp);
Gfx* Gfx_BranchTexScroll(Gfx** gfxp, u32 x, u32 y, s32 width, s32 height);
Gfx* func_80094E78(GraphicsContext* gfxCtx, u32 x, u32 y);
Gfx* Gfx_TexScroll(GraphicsContext* gfxCtx, u32 x, u32 y, s32 width, s32 height);
Gfx* Gfx_TexScrollEx(GraphicsContext* gfxCtx, u32 x, u32 y, s32 width, s32 height, s32 xStep, s32 yStep);
Gfx* Gfx_TwoTexScroll(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 width1, s32 height1, s32 tile2, u32 x2,
u32 y2, s32 width2, s32 height2);
Gfx* Gfx_TwoTexScrollEx(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 width1, s32 height1, s32 tile2, u32 x2,
u32 y2, s32 width2, s32 height2, s32 xStep1, s32 yStep1, s32 xStep2, s32 yStep2);
Gfx* Gfx_TwoTexScrollEnvColor(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 width1, s32 height1, s32 tile2,
u32 x2, u32 y2, s32 width2, s32 height2, s32 r, s32 g, s32 b, s32 a);
Gfx* Gfx_TwoTexScrollEnvColorEx(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 width1, s32 height1, s32 tile2,
u32 x2, u32 y2, s32 width2, s32 height2, s32 r, s32 g, s32 b, s32 a, s32 xStep1, s32 yStep1, s32 xStep2, s32 yStep2);
Gfx* Gfx_EnvColor(GraphicsContext* gfxCtx, s32 r, s32 g, s32 b, s32 a);
void Gfx_SetupFrame(GraphicsContext* gfxCtx, u8 r, u8 g, u8 b);
void func_80095974(GraphicsContext* gfxCtx);
@@ -100,8 +100,8 @@ extern "C" void CustomLogoTitle_Draw(TitleContext* titleContext, uint8_t logoToD
f32 scale = 0.4f;
gSPSegment(POLY_OPA_DISP++, 0x08,
(uintptr_t)Gfx_TwoTexScroll(titleContext->state.gfxCtx, 0, 0, (0 - 1) % 128, 32, 32, 1, 0,
(1 * -2) % 128, 32, 32));
(uintptr_t)Gfx_TwoTexScrollEx(titleContext->state.gfxCtx, 0, 0, (0 - 1) % 128, 32, 32, 1, 0,
(1 * -2) % 128, 32, 32, 0, 0, 0, 0));
Matrix_Translate(0.0f, -10.0f, 0.0f, MTXMODE_APPLY);
Matrix_Scale(scale, scale, scale, MTXMODE_APPLY);
+28 -26
View File
@@ -373,9 +373,9 @@ extern "C" void Randomizer_DrawMasterSword(PlayState* play, GetItemEntry* getIte
Gfx_SetupDL_25Opa(play->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 1),
0 * (play->state.frames * 1), 32, 32, 1, 0 * (play->state.frames * 1),
0 * (play->state.frames * 1), 32, 32));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 1 * (play->state.frames * 1),
0 * (play->state.frames * 1), 32, 32, 1, 0 * (play->state.frames * 1),
0 * (play->state.frames * 1), 32, 32, 1, 0, 0, 0));
Matrix_Scale(0.05f, 0.05f, 0.05f, MTXMODE_APPLY);
Matrix_RotateZ(2.1f, MTXMODE_APPLY);
@@ -611,8 +611,8 @@ extern "C" s32 OverrideLimbDrawBarinade(PlayState* play, s32 limbIndex, Gfx** dL
if (limbIndex == 20) {
gDPPipeSync(POLY_OPA_DISP++);
gSPSegment(POLY_OPA_DISP++, 0x08,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 8, 16, 1, 0,
(play->gameplayFrames * -2) % 64, 16, 16));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 8, 16, 1, 0,
(play->gameplayFrames * -2) % 64, 16, 16, 0, 0, 0, -2));
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 200);
Matrix_RotateX(-M_PIf / 2.0f, MTXMODE_APPLY);
} else if ((limbIndex >= 10) && (limbIndex < 20)) {
@@ -637,8 +637,8 @@ extern "C" void PostLimbDrawBarinade(PlayState* play, s32 limbIndex, Gfx** dList
if (limbIndex == 25) {
gSPSegment(POLY_XLU_DISP++, 0x09,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (play->gameplayFrames * 10) % 128, 16, 32, 1,
0, (play->gameplayFrames * 5) % 128, 16, 32));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (play->gameplayFrames * 10) % 128, 16, 32, 1,
0, (play->gameplayFrames * 5) % 128, 16, 32, 0, 10, 0, 5));
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(play->state.gfxCtx, (char*)__FILE__, __LINE__),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, (Gfx*)gBarinadeDL_008D70);
@@ -693,11 +693,11 @@ extern "C" void DrawBarinade(PlayState* play) {
Matrix_Scale(0.03f, 0.03f, 0.03f, MTXMODE_APPLY);
gSPSegment(POLY_OPA_DISP++, 0x08,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 8, 16, 1, 0, (play->gameplayFrames * -10) % 16,
16, 16));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 8, 16, 1, 0,
(play->gameplayFrames * -10) % 16, 16, 16, 0, 0, 0, -10));
gSPSegment(POLY_OPA_DISP++, 0x09,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (play->gameplayFrames * -10) % 32, 16, 0x20, 1, 0,
(play->gameplayFrames * -5) % 32, 16, 32));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (play->gameplayFrames * -10) % 32, 16, 0x20, 1,
0, (play->gameplayFrames * -5) % 32, 16, 32, 0, -10, 0, -5));
SkelAnime_DrawSkeletonOpa(play, &skelAnime, OverrideLimbDrawBarinade, PostLimbDrawBarinade, NULL);
@@ -763,8 +763,8 @@ extern "C" void DrawVolvagia(PlayState* play) {
gSPSegment(POLY_OPA_DISP++, 0x09, (uintptr_t)gVolvagiaEyeOpenTex);
gSPSegment(POLY_OPA_DISP++, 0x08,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->state.frames * 4, 120, 0x20, 0x20, 1,
play->state.frames * 3, play->state.frames * -2, 0x20, 0x20));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, play->state.frames * 4, 120, 0x20, 0x20, 1,
play->state.frames * 3, play->state.frames * -2, 0x20, 0x20, 4, 0, 3, -2));
gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 255, 255, 255);
gDPSetEnvColor(POLY_OPA_DISP++, 255, 255, 255, 255);
@@ -782,12 +782,13 @@ extern "C" void DrawMorpha(PlayState* play) {
Matrix_Scale(0.015f, 0.015f, 0.015f, MTXMODE_APPLY);
gSPSegment(POLY_XLU_DISP++, 0x08,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->state.frames * 3, play->state.frames * 3, 32,
32, 1, play->state.frames * -3, play->state.frames * -3, 32, 32));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, play->state.frames * 3, play->state.frames * 3, 32,
32, 1, play->state.frames * -3, play->state.frames * -3, 32, 32, 3, 3, -3,
-3));
gSPSegment(POLY_XLU_DISP++, 0x09,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->state.frames * 3, 0, 32, 32, 1, 0,
play->state.frames * -5, 32, 32));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, play->state.frames * 3, 0, 32, 32, 1, 0,
play->state.frames * -5, 32, 32, 3, 0, 0, -5));
Matrix_RotateX(play->state.frames * 0.1f, MTXMODE_APPLY);
Matrix_RotateZ(play->state.frames * 0.16f, MTXMODE_APPLY);
@@ -892,11 +893,12 @@ extern "C" void DrawKotake(PlayState* play) {
gSPSegment(POLY_OPA_DISP++, 10, (uintptr_t)gTwinrovaKotakeKoumeEyeOpenTex);
gSPSegment(POLY_XLU_DISP++, 10, (uintptr_t)gTwinrovaKotakeKoumeEyeOpenTex);
gSPSegment(POLY_XLU_DISP++, 8,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 & 0x7F, 0 & 0x7F, 0x20, 0x20, 1,
play->state.frames & 0x7F, (play->state.frames * -7) & 0xFF, 0x20, 0x40));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 & 0x7F, 0 & 0x7F, 0x20, 0x20, 1,
play->state.frames & 0x7F, (play->state.frames * -7) & 0xFF, 0x20, 0x40, 0,
0, 1, -7));
gSPSegment(POLY_XLU_DISP++, 9,
(uintptr_t)Gfx_TexScroll(play->state.gfxCtx, 0 & 0x7F, play->state.frames & 0xFF, 0x20, 0x40));
(uintptr_t)Gfx_TexScrollEx(play->state.gfxCtx, 0 & 0x7F, play->state.frames & 0xFF, 0x20, 0x40, 0, 1));
SkelAnime_DrawSkeletonOpa(play, &skelAnime, OverrideLimbDrawKotake, PostLimbDrawKotake, NULL);
@@ -982,9 +984,9 @@ extern "C" void Randomizer_DrawBossSoul(PlayState* play, GetItemEntry* getItemEn
OPEN_DISPS(play->state.gfxCtx);
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 8,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0),
0 * (play->state.frames * 0), 16, 32, 1, 1 * (play->state.frames * 1),
-1 * (play->state.frames * 8), 16, 32));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 * (play->state.frames * 0),
0 * (play->state.frames * 0), 16, 32, 1, 1 * (play->state.frames * 1),
-1 * (play->state.frames * 8), 16, 32, 0, 0, 1, -8));
Matrix_Push();
Matrix_Translate(0.0f, -70.0f, 0.0f, MTXMODE_APPLY);
Matrix_Scale(5.0f, 5.0f, 5.0f, MTXMODE_APPLY);
@@ -1123,9 +1125,9 @@ extern "C" void Randomizer_DrawBronzeScale(PlayState* play, GetItemEntry* getIte
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
(uintptr_t)Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 2),
-1 * (play->state.frames * 2), 64, 64, 1, 1 * (play->state.frames * 4),
-1 * (play->state.frames * 4), 32, 32));
(uintptr_t)Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 1 * (play->state.frames * 2),
-1 * (play->state.frames * 2), 64, 64, 1, 1 * (play->state.frames * 4),
-1 * (play->state.frames * 4), 32, 32, 2, -2, 4, -4));
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(play->state.gfxCtx, (char*)__FILE__, __LINE__),
G_MTX_MODELVIEW | G_MTX_LOAD);
+14
View File
@@ -77,6 +77,20 @@ extern "C" void gSPDisplayList(Gfx* pkt, Gfx* dl) {
__gSPDisplayList(pkt, dl);
}
extern "C" void gDPSetTileSizeInterp(Gfx* pkt, int t, float uls, float ult, float lrs, float lrt) {
__gDPSetTileSizeInterp(pkt, t, 0, 0, 0, 0);
pkt->words.w0 = _SHIFTL(G_SETTILESIZE_INTERP, 24, 8);
pkt++;
pkt->words.w0 = *(u32*)&uls;
pkt->words.w1 = *(u32*)&ult;
pkt++;
pkt->words.w0 = *(u32*)&lrs;
pkt->words.w1 = *(u32*)&lrt;
pkt++;
}
extern "C" void gSPDisplayListOffset(Gfx* pkt, Gfx* dl, int offset) {
char* imgData = (char*)dl;
+13
View File
@@ -1713,11 +1713,15 @@ void RunCommands(Gfx* Commands, const std::vector<std::unordered_map<Mtx*, MtxF>
// Process window events for resize, mouse, keyboard events
wnd->HandleEvents();
auto intp = wnd->GetInterpreterWeak().lock().get();
intp->mInterpolationIndex = 0;
UIWidgets::Colors themeColor =
static_cast<UIWidgets::Colors>(CVarGetInteger(CVAR_SETTING("Menu.Theme"), UIWidgets::Colors::LightBlue));
ImGui::PushStyleColor(ImGuiCol_TitleBgActive, UIWidgets::ColorValues.at(themeColor));
for (const auto& m : mtx_replacements) {
wnd->DrawAndRunGraphicsCommands(Commands, m);
intp->mInterpolationIndex++;
}
ImGui::PopStyleColor();
}
@@ -2557,3 +2561,12 @@ bool SoH_HandleConfigDrop(char* filePath) {
extern "C" void CheckTracker_RecalculateAvailableChecks() {
CheckTracker::RecalculateAvailableChecks();
}
extern "C" uint32_t Ship_GetInterpolationFPS() {
return OTRGlobals::Instance->GetInterpolationFPS();
}
// Number of interpolated frames
extern "C" uint32_t Ship_GetInterpolationFrameCount() {
return ceil((float)Ship_GetInterpolationFPS() / 20.0f);
}
+3
View File
@@ -164,6 +164,9 @@ void CheckTracker_RecalculateAvailableChecks();
GetItemID RetrieveGetItemIDFromItemID(ItemID itemID);
RandomizerGet RetrieveRandomizerGetFromItemID(ItemID itemID);
void Messagebox_ShowErrorBox(char* title, char* body);
uint32_t Ship_GetInterpolationFPS();
uint32_t Ship_GetInterpolationFrameCount();
#endif
#ifdef __cplusplus
+39 -28
View File
@@ -476,10 +476,10 @@ void GetItem_DrawJewel(PlayState* play, s16 drawId) {
OPEN_DISPS(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 % 256, (256 - (0 % 256)) - 1, 64, 64, 1, 0 % 256,
(256 - (0 % 256)) - 1, 16, 16));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 % 256, (256 - (0 % 256)) - 1, 64, 64, 1, 0 % 256,
(256 - (0 % 256)) - 1, 16, 16, 0, 0, 0, 0));
gSPSegment(POLY_OPA_DISP++, 8, Gfx_TexScroll(play->state.gfxCtx, (u8)0, (u8)0, 16, 16));
gSPSegment(POLY_OPA_DISP++, 8, Gfx_TexScrollEx(play->state.gfxCtx, (u8)0, (u8)0, 16, 16, 0, 0));
Matrix_Push();
Matrix_RotateZYX(0, -0x4000, 0x4000, MTXMODE_APPLY);
@@ -541,8 +541,9 @@ void GetItem_DrawBlueFire(PlayState* play, s16 drawId) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 0 * (play->state.frames * 0), 16,
32, 1, 1 * (play->state.frames * 1), 1 * -(play->state.frames * 8), 16, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 0 * (play->state.frames * 0), 16,
32, 1, 1 * (play->state.frames * 1), 1 * -(play->state.frames * 8), 16, 32, 0, 0, 1,
-8));
Matrix_Push();
Matrix_Translate(-8.0f, -2.0f, 0.0f, MTXMODE_APPLY);
Matrix_ReplaceRotation(&play->billboardMtxF);
@@ -566,8 +567,9 @@ void GetItem_DrawPoes(PlayState* play, s16 drawId) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[1]);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 0 * (play->state.frames * 0), 16,
32, 1, 1 * (play->state.frames * 1), 1 * -(play->state.frames * 6), 16, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 0 * (play->state.frames * 0), 16,
32, 1, 1 * (play->state.frames * 1), 1 * -(play->state.frames * 6), 16, 32, 0, 0, 1,
-6));
Matrix_Push();
Matrix_ReplaceRotation(&play->billboardMtxF);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
@@ -591,8 +593,9 @@ void GetItem_DrawFairy(PlayState* play, s16 drawId) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[1]);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 0 * (play->state.frames * 0), 32,
32, 1, 1 * (play->state.frames * 1), 1 * -(play->state.frames * 6), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 0 * (play->state.frames * 0), 32,
32, 1, 1 * (play->state.frames * 1), 1 * -(play->state.frames * 6), 32, 32, 0, 0, 1,
-6));
Matrix_Push();
Matrix_ReplaceRotation(&play->billboardMtxF);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
@@ -609,9 +612,9 @@ void GetItem_DrawMirrorShield(PlayState* play, s16 drawId) {
Gfx_SetupDL_25Opa(play->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0) % 256,
1 * (play->state.frames * 2) % 256, 64, 64, 1, 0 * (play->state.frames * 0) % 128,
1 * (play->state.frames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 * (play->state.frames * 0) % 256,
1 * (play->state.frames * 2) % 256, 64, 64, 1, 0 * (play->state.frames * 0) % 128,
1 * (play->state.frames * 1) % 128, 32, 32, 0, 2, 0, 1));
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]);
@@ -633,8 +636,9 @@ void GetItem_DrawSkullToken(PlayState* play, s16 drawId) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 1 * -(play->state.frames * 5), 32,
32, 1, 0 * (play->state.frames * 0), 0 * (play->state.frames * 0), 32, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 1 * -(play->state.frames * 5),
32, 32, 1, 0 * (play->state.frames * 0), 0 * (play->state.frames * 0), 32, 64, 0, -5,
0, 0));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[1]);
@@ -677,8 +681,9 @@ void GetItem_DrawPotion(PlayState* play, s16 drawId) {
Gfx_SetupDL_25Opa(play->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, -1 * (play->state.frames * 1), 1 * (play->state.frames * 1), 32,
32, 1, -1 * (play->state.frames * 1), 1 * (play->state.frames * 1), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, -1 * (play->state.frames * 1), 1 * (play->state.frames * 1),
32, 32, 1, -1 * (play->state.frames * 1), 1 * (play->state.frames * 1), 32, 32, -1, 1,
-1, 1));
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[1]);
gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]);
@@ -700,8 +705,9 @@ void GetItem_DrawGoronSword(PlayState* play, s16 drawId) {
Gfx_SetupDL_25Opa(play->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 1), 0 * (play->state.frames * 1), 32,
32, 1, 0 * (play->state.frames * 1), 0 * (play->state.frames * 1), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 1 * (play->state.frames * 1), 0 * (play->state.frames * 1), 32,
32, 1, 0 * (play->state.frames * 1), 0 * (play->state.frames * 1), 32, 32, 1, 0, 0,
0));
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]);
@@ -715,8 +721,9 @@ void GetItem_DrawDekuNuts(PlayState* play, s16 drawId) {
Gfx_SetupDL_25Opa(play->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6), 32,
32, 1, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6), 32,
32, 1, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6), 32, 32, 6, 6, 6,
6));
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
gSPDisplayList(POLY_OPA_DISP++, sDrawItemTable[drawId].dlists[0]);
@@ -730,8 +737,9 @@ void GetItem_DrawRecoveryHeart(PlayState* play, s16 drawId) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 1), 1 * -(play->state.frames * 3), 32,
32, 1, 0 * (play->state.frames * 1), 1 * -(play->state.frames * 2), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 * (play->state.frames * 1), 1 * -(play->state.frames * 3),
32, 32, 1, 0 * (play->state.frames * 1), 1 * -(play->state.frames * 2), 32, 32, 0, -3,
0, -2));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
if (CVarGetInteger(CVAR_COSMETIC("Consumable.Hearts.Changed"), 0)) {
Color_RGB8 color = CVarGetColor24(CVAR_COSMETIC("Consumable.Hearts.Value"), (Color_RGB8){ 255, 70, 50 });
@@ -752,8 +760,9 @@ void GetItem_DrawFish(PlayState* play, s16 drawId) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 1 * (play->state.frames * 1), 32,
32, 1, 0 * (play->state.frames * 0), 1 * (play->state.frames * 1), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 * (play->state.frames * 0), 1 * (play->state.frames * 1), 32,
32, 1, 0 * (play->state.frames * 0), 1 * (play->state.frames * 1), 32, 32, 0, 1, 0,
1));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[0]);
@@ -867,8 +876,9 @@ void GetItem_DrawMagicSpell(PlayState* play, s16 drawId) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 2), 1 * -(play->state.frames * 6), 32,
32, 1, 1 * (play->state.frames * 1), -1 * (play->state.frames * 2), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 1 * (play->state.frames * 2), 1 * -(play->state.frames * 6),
32, 32, 1, 1 * (play->state.frames * 1), -1 * (play->state.frames * 2), 32, 32, 2, -6,
1, -2));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[0]);
gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[1]);
@@ -937,8 +947,9 @@ void GetItem_DrawScale(PlayState* play, s16 drawId) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 2), -1 * (play->state.frames * 2), 64,
64, 1, 1 * (play->state.frames * 4), 1 * -(play->state.frames * 4), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 1 * (play->state.frames * 2), -1 * (play->state.frames * 2),
64, 64, 1, 1 * (play->state.frames * 4), 1 * -(play->state.frames * 4), 32, 32, 2, -2,
4, -4));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[2]);
gSPDisplayList(POLY_XLU_DISP++, sDrawItemTable[drawId].dlists[3]);
+2 -2
View File
@@ -2427,8 +2427,8 @@ void Environment_DrawSandstorm(PlayState* play, u8 sandstormState) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, primColor.r, primColor.g, primColor.b, play->envCtx.sandstormPrimA);
gDPSetEnvColor(POLY_XLU_DISP++, envColor.r, envColor.g, envColor.b, play->envCtx.sandstormEnvA);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (u32)sp96 % 0x1000, 0, 0x200, 0x20, 1, (u32)sp94 % 0x1000,
0xFFF - ((u32)sp92 % 0x1000), 0x100, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (u32)sp96 % 0x1000, 0, 0x200, 0x20, 1, (u32)sp94 % 0x1000,
0xFFF - ((u32)sp92 % 0x1000), 0x100, 0x40, sp98, 0, sp98 * 1.5f, -sp98));
gDPSetTextureLUT(POLY_XLU_DISP++, G_TT_NONE);
gSPDisplayList(POLY_XLU_DISP++, gFieldSandstormDL);
+2 -2
View File
@@ -1593,8 +1593,8 @@ void Player_DrawGetItemIceTrap(PlayState* play, Player* this, Vec3f* refPos, s32
iceTrapScale += 0.2f;
}
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (0 - play->gameplayFrames) % 128, 32, 32, 1, 0,
(play->gameplayFrames * -2) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (0 - play->gameplayFrames) % 128, 32, 32, 1, 0,
(play->gameplayFrames * -2) % 128, 32, 32, 0, -1, 0, -2));
Matrix_Translate(0.0f, -40.0f, 0.0f, MTXMODE_APPLY);
Matrix_Scale(iceTrapScale, iceTrapScale, iceTrapScale, MTXMODE_APPLY);
+126
View File
@@ -1394,6 +1394,38 @@ Gfx* Gfx_TexScroll(GraphicsContext* gfxCtx, u32 x, u32 y, s32 width, s32 height)
return displayList;
}
Gfx* Gfx_TexScrollEx(GraphicsContext* gfxCtx, u32 x, u32 y, s32 width, s32 height, s32 xStep, s32 yStep) {
int interpFrames = Ship_GetInterpolationFrameCount();
Gfx* gfx = Graph_Alloc(gfxCtx, (2 + (interpFrames * 4)) * sizeof(Gfx));
x %= 2048;
y %= 2048;
float xFlt = (float)x;
float yFlt = (float)y;
float xInc = (float)xStep / (float)interpFrames;
float yInc = (float)yStep / (float)interpFrames;
int idx = 0;
gDPTileSync(&gfx[idx++]);
for (int i = 0; i < interpFrames; i++) {
gDPSetInterpolation(&gfx[idx++], i);
gDPSetTileSizeInterp(&gfx[idx], 0, xFlt, yFlt, (xFlt + ((width - 1) << 2)), (yFlt + ((height - 1) << 2)));
idx += 3;
xFlt += xInc;
yFlt += yInc;
}
gSPEndDisplayList(&gfx[idx++]);
return gfx;
}
Gfx* Gfx_TwoTexScroll(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 width1, s32 height1, s32 tile2, u32 x2,
u32 y2, s32 width2, s32 height2) {
Gfx* displayList = Graph_Alloc(gfxCtx, 5 * sizeof(Gfx));
@@ -1412,6 +1444,52 @@ Gfx* Gfx_TwoTexScroll(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 wi
return displayList;
}
Gfx* Gfx_TwoTexScrollEx(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 width1, s32 height1, s32 tile2, u32 x2,
u32 y2, s32 width2, s32 height2, s32 xStep1, s32 yStep1, s32 xStep2, s32 yStep2) {
int interpFrames = Ship_GetInterpolationFrameCount();
Gfx* gfx = Graph_Alloc(gfxCtx, (5 + (interpFrames * 7)) * sizeof(Gfx));
x1 %= 2048;
y1 %= 2048;
x2 %= 2048;
y2 %= 2048;
float x1Flt = (float)x1;
float y1Flt = (float)y1;
float x2Flt = (float)x2;
float y2Flt = (float)y2;
int index = 0;
gDPTileSync(&gfx[index++]);
float xInc1 = (float)xStep1 / (float)interpFrames;
float yInc1 = (float)yStep1 / (float)interpFrames;
float xInc2 = (float)xStep2 / (float)interpFrames;
float yInc2 = (float)yStep2 / (float)interpFrames;
for (int i = 0; i < interpFrames; i++) {
gDPSetInterpolation(&gfx[index++], i);
gDPSetTileSizeInterp(&gfx[index], tile1, x1Flt, y1Flt, (x1Flt + ((width1 - 1) << 2)),
(y1Flt + ((height1 - 1) << 2)));
index += 3;
gDPSetTileSizeInterp(&gfx[index], tile2, x2Flt, y2Flt, (x2Flt + ((width2 - 1) << 2)),
(y2Flt + ((height2 - 1) << 2)));
index += 3;
x1Flt += xInc1;
x2Flt += xInc2;
y1Flt += yInc1;
y2Flt += yInc2;
}
gSPEndDisplayList(&gfx[index]);
return gfx;
}
Gfx* Gfx_TwoTexScrollEnvColor(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 width1, s32 height1, s32 tile2,
u32 x2, u32 y2, s32 width2, s32 height2, s32 r, s32 g, s32 b, s32 a) {
Gfx* displayList = Graph_Alloc(gfxCtx, 6 * sizeof(Gfx));
@@ -1431,6 +1509,54 @@ Gfx* Gfx_TwoTexScrollEnvColor(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1
return displayList;
}
Gfx* Gfx_TwoTexScrollEnvColorEx(GraphicsContext* gfxCtx, s32 tile1, u32 x1, u32 y1, s32 width1, s32 height1, s32 tile2,
u32 x2, u32 y2, s32 width2, s32 height2, s32 r, s32 g, s32 b, s32 a, s32 xStep1,
s32 yStep1, s32 xStep2, s32 yStep2) {
int interpFrames = Ship_GetInterpolationFrameCount();
Gfx* gfx = Graph_Alloc(gfxCtx, (6 + (interpFrames * 7)) * sizeof(Gfx));
x1 %= 2048;
y1 %= 2048;
x2 %= 2048;
y2 %= 2048;
float x1Flt = (float)x1;
float y1Flt = (float)y1;
float x2Flt = (float)x2;
float y2Flt = (float)y2;
int index = 0;
gDPTileSync(&gfx[index++]);
float xInc1 = (float)xStep1 / (float)interpFrames;
float yInc1 = (float)yStep1 / (float)interpFrames;
float xInc2 = (float)xStep2 / (float)interpFrames;
float yInc2 = (float)yStep2 / (float)interpFrames;
for (int i = 0; i < interpFrames; i++) {
gDPSetInterpolation(&gfx[index++], i);
gDPSetTileSizeInterp(&gfx[index], tile1, x1Flt, y1Flt, (x1Flt + ((width1 - 1) << 2)),
(y1Flt + ((height1 - 1) << 2)));
index += 3;
gDPSetTileSizeInterp(&gfx[index], tile2, x2Flt, y2Flt, (x2Flt + ((width2 - 1) << 2)),
(y2Flt + ((height2 - 1) << 2)));
index += 3;
x1Flt += xInc1;
x2Flt += xInc2;
y1Flt += yInc1;
y2Flt += yInc2;
}
gDPSetEnvColor(&gfx[index++], r, g, b, a);
gSPEndDisplayList(&gfx[index]);
return gfx;
}
Gfx* Gfx_EnvColor(GraphicsContext* gfxCtx, s32 r, s32 g, s32 b, s32 a) {
Gfx* displayList = Graph_Alloc(gfxCtx, 2 * sizeof(Gfx));
+205 -187
View File
@@ -128,8 +128,8 @@ void func_800995DC(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - (gameplayFrames % 128), (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - (gameplayFrames % 128), (gameplayFrames * 1) % 128, 32,
32, 1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gDPPipeSync(POLY_XLU_DISP++);
gDPSetEnvColor(POLY_XLU_DISP++, 128, 128, 128, 128);
@@ -153,8 +153,8 @@ void func_80099760(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (gameplayFrames * 2) % 256, 0, 64, 32, 1, 0,
(gameplayFrames * 2) % 128, 64, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 2) % 256, 0, 64, 32, 1, 0,
(gameplayFrames * 2) % 128, 64, 32, 0, 2, 0, 2));
gDPPipeSync(POLY_XLU_DISP++);
gDPSetEnvColor(POLY_XLU_DISP++, 128, 128, 128, 128);
@@ -189,11 +189,11 @@ void func_80099878(PlayState* play) {
gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(sDCLavaFloorTextures[(s32)(gameplayFrames & 14) >> 1]));
}
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (gameplayFrames * 1) % 256, 0, 64, 32, 1, 0,
(gameplayFrames * 1) % 128, 64, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 1) % 256, 0, 64, 32, 1, 0,
(gameplayFrames * 1) % 128, 64, 32, 1, 0, 0, 1));
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 128, 32, 32, 1, 0,
(gameplayFrames * 2) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 128, 32, 32, 1, 0,
(gameplayFrames * 2) % 128, 32, 32, 0, 1, 0, 2));
{ s32 pad2[2]; }
@@ -285,18 +285,20 @@ void func_8009A45C(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 0, (gameplayFrames * 1) % 64, 256, 16));
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 1) % 64, 256, 16, 0, 1));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - (gameplayFrames % 128), (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - (gameplayFrames % 128), (gameplayFrames * 1) % 128, 32,
32, 1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, 0, 127 - (gameplayFrames * 1) % 128, 32, 32));
gSPSegment(POLY_OPA_DISP++, 0x0B, Gfx_TexScroll(play->state.gfxCtx, 0, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, 0, 127 - (gameplayFrames * 1) % 128, 32, 32,
0, 0, 0, -1));
gSPSegment(POLY_OPA_DISP++, 0x0B, Gfx_TexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 1) % 128, 32, 32, 0, 1));
gSPSegment(POLY_XLU_DISP++, 0x0C,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 50) % 2048, 8, 512, 1, 0,
(gameplayFrames * 60) % 2048, 8, 512));
gSPSegment(POLY_OPA_DISP++, 0x0D,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 50) % 2048, 8, 512, 1, 0,
(gameplayFrames * 60) % 2048, 8, 512, 0, 50, 0, 60));
gSPSegment(
POLY_OPA_DISP++, 0x0D,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (gameplayFrames * 1) % 128, 32, 32, 0, 0, 0, 1));
gDPPipeSync(POLY_XLU_DISP++);
gDPSetEnvColor(POLY_XLU_DISP++, 128, 128, 128, 128);
@@ -314,17 +316,17 @@ void func_8009A798(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 0, (gameplayFrames * 2) % 256, 64, 64));
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 2) % 256, 64, 64, 0, 2));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - (gameplayFrames * 1) % 128, (gameplayFrames * 1) % 256, 32,
64, 1, 0, 0, 32, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - (gameplayFrames * 1) % 128, (gameplayFrames * 1) % 256,
32, 64, 1, 0, 0, 32, 128, -1, 1, 0, 0));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -343,11 +345,11 @@ void func_8009A9DC(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 256, 32, 64,
1, gameplayFrames % 128, (gameplayFrames * 3) % 256, 32, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 256, 32, 64,
1, gameplayFrames % 128, (gameplayFrames * 3) % 256, 32, 64, -1, 3, 1, 3));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32, -1, 3, 1, 3));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -365,7 +367,7 @@ void func_8009AB98(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 0, gameplayFrames % 64, 256, 16));
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScrollEx(play->state.gfxCtx, 0, gameplayFrames % 64, 256, 16, 0, 1));
gDPPipeSync(POLY_XLU_DISP++);
gDPSetEnvColor(POLY_XLU_DISP++, 128, 128, 128, 128);
@@ -384,9 +386,9 @@ void func_8009ACA8(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32));
gSPSegment(POLY_XLU_DISP++, 0x09, Gfx_TexScroll(play->state.gfxCtx, 0, gameplayFrames % 64, 256, 16));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32, -1, 3, 1, 3));
gSPSegment(POLY_XLU_DISP++, 0x09, Gfx_TexScrollEx(play->state.gfxCtx, 0, gameplayFrames % 64, 256, 16, 0, 1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -407,12 +409,12 @@ void func_8009AE30(PlayState* play) {
if (play->sceneNum == SCENE_SHADOW_TEMPLE_BOSS) {
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (gameplayFrames * 2) % 128, 0, 32, 32, 1,
(gameplayFrames * 2) % 128, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 2) % 128, 0, 32, 32, 1,
(gameplayFrames * 2) % 128, 0, 32, 32, 2, 0, 2, 0));
} else {
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (gameplayFrames * 2) % 128, 0, 32, 32, 1,
(gameplayFrames * 2) % 128, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 2) % 128, 0, 32, 32, 1,
(gameplayFrames * 2) % 128, 0, 32, 32, 2, 0, 2, 0));
}
gDPPipeSync(POLY_OPA_DISP++);
@@ -436,7 +438,7 @@ void func_8009AFE0(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x09, Gfx_TexScroll(play->state.gfxCtx, 0, (gameplayFrames * 3) % 128, 32, 32));
gSPSegment(POLY_OPA_DISP++, 0x09, Gfx_TexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 3) % 128, 32, 32, 0, 3));
{ s32 pad[2]; }
@@ -470,54 +472,54 @@ void func_8009B0FC(PlayState* play) {
if (spB0 == 1) {
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0,
0, spAC));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0,
0, 0, spAC, 1, 0, 0, 0));
} else if (spB0 < 1) {
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0,
0, 255));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0,
0, 0, 255, 1, 0, 0, 0));
} else {
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0,
0, 160));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0,
0, 0, 160, 1, 0, 0, 0));
}
if (spB0 == 2) {
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0,
0, spAC));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0,
0, 0, spAC, 1, 0, 0, 0));
} else if (spB0 < 2) {
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0,
0, 255));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0,
0, 0, 255, 1, 0, 0, 0));
} else {
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0,
0, 160));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0,
0, 0, 160, 1, 0, 0, 0));
}
if (spB0 != 0) {
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0,
0, 160));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0,
0, 0, 160, 1, 0, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x0B,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 3, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0,
0, 180));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 3, 0, 32, 32, 1, 0, 0, 32, 32, 0,
0, 0, 180, 3, 0, 0, 0));
} else {
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, (gameplayFrames * 1) % 128, 0, 32, 32, 1, 0, 0, 32,
32, 0, 0, 0, 160 + (s32)((spAC / 200.0f) * 95.0f)));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, (gameplayFrames * 1) % 128, 0, 32, 32, 1, 0, 0, 32,
32, 0, 0, 0, 160 + (s32)((spAC / 200.0f) * 95.0f), 1, 0, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x0B,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 3, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0,
0, 185 + (s32)((spAC / 200.0f) * 70.0f)));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 3, 0, 32, 32, 1, 0, 0, 32, 32, 0,
0, 0, 185 + (s32)((spAC / 200.0f) * 70.0f), 3, 0, 0, 0));
}
gSPSegment(POLY_XLU_DISP++, 0x0C,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 1, gameplayFrames * 1, 32, 32, 1, 0,
127 - (gameplayFrames * 1), 32, 32, 0, 0, 0, 128));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 1, gameplayFrames * 1, 32, 32, 1, 0,
127 - (gameplayFrames * 1), 32, 32, 0, 0, 0, 128, 1, 1, 0, -1));
gSPSegment(POLY_XLU_DISP++, 0x0D,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames * 4, 0, 32, 32, 1, gameplayFrames * 4, 0,
32, 32, 0, 0, 0, 128));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames * 4, 0, 32, 32, 1, gameplayFrames * 4,
0, 32, 32, 0, 0, 0, 128, 4, 0, 4, 0));
{ s32 pad[2]; }
@@ -532,7 +534,7 @@ void func_8009B86C(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, gameplayFrames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 1, 0, 0, 0));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, play->roomCtx.unk_74[0]);
@@ -550,7 +552,7 @@ void func_8009B9BC(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 0, gameplayFrames % 64, 4, 16));
gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TexScrollEx(play->state.gfxCtx, 0, gameplayFrames % 64, 4, 16, 0, 1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -566,11 +568,12 @@ void func_8009BAA4(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32, -1, 3, 1, 3));
if (play->sceneNum == SCENE_CASTLE_COURTYARD_GUARDS_DAY) {
gSPSegment(POLY_XLU_DISP++, 0x09, Gfx_TexScroll(play->state.gfxCtx, 0, (gameplayFrames * 10) % 256, 32, 64));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 10) % 256, 32, 64, 0, 10));
}
gDPPipeSync(POLY_OPA_DISP++);
@@ -594,15 +597,17 @@ void func_8009BC44(PlayState* play) {
gameplayFrames = play->gameplayFrames;
if (play->sceneNum == SCENE_OUTSIDE_GANONS_CASTLE) {
gSPSegment(POLY_XLU_DISP++, 0x09, Gfx_TexScroll(play->state.gfxCtx, 0, (gameplayFrames * 1) % 256, 64, 64));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 1) % 256, 64, 64, 0, 1));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 255 - (gameplayFrames * 1) % 256, 64, 64, 1, 0,
(gameplayFrames * 1) % 256, 64, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 255 - (gameplayFrames * 1) % 256, 64, 64, 1, 0,
(gameplayFrames * 1) % 256, 64, 64, 0, -1, 0, 1));
}
gSPSegment(POLY_OPA_DISP++, 0x0B,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 255 - (gameplayFrames * 1) % 128, (gameplayFrames * 1) % 128, 32,
32, 1, (gameplayFrames * 1) % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 255 - (gameplayFrames * 1) % 128, (gameplayFrames * 1) % 128,
32, 32, 1, (gameplayFrames * 1) % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1,
1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -647,14 +652,14 @@ void func_8009C0AC(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 512, 64, 128, 1, 0,
511 - (gameplayFrames * 1) % 512, 64, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 512, 64, 128, 1, 0,
511 - (gameplayFrames * 1) % 512, 64, 128, 0, 1, 0, -1));
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 256, 32, 64, 1, 0,
255 - (gameplayFrames * 1) % 256, 32, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 256, 32, 64, 1, 0,
255 - (gameplayFrames * 1) % 256, 32, 64, 0, 1, 0, -1));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 20) % 2048, 16, 512, 1, 0,
(gameplayFrames * 30) % 2048, 16, 512));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 20) % 2048, 16, 512, 1, 0,
(gameplayFrames * 30) % 2048, 16, 512, 0, 20, 0, 30));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -695,11 +700,11 @@ void func_8009C3EC(PlayState* play) {
gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sIceCavernEntranceTextures[gSaveContext.nightFlag]));
}
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
{ s32 pad[2]; }
@@ -719,16 +724,16 @@ void func_8009C608(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 0, (gameplayFrames * 1) % 64, 256, 16));
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 1) % 64, 256, 16, 0, 1));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 60) % 2048, 8, 512, 1, 0,
(gameplayFrames * 50) % 2048, 8, 512));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 60) % 2048, 8, 512, 1, 0,
(gameplayFrames * 50) % 2048, 8, 512, 0, 60, 0, 50));
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - (gameplayFrames * 1) % 128, 0, 32, 32, 1,
(gameplayFrames * 1) % 128, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - (gameplayFrames * 1) % 128, 0, 32, 32, 1,
(gameplayFrames * 1) % 128, 0, 32, 32, -1, 0, 1, 0));
gSPSegment(POLY_XLU_DISP++, 0x0B,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 1023 - (gameplayFrames * 6) % 1024, 16, 256, 1, 0,
1023 - (gameplayFrames * 3) % 1024, 16, 256));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 1023 - (gameplayFrames * 6) % 1024, 16, 256, 1, 0,
1023 - (gameplayFrames * 3) % 1024, 16, 256, 0, -6, 0, -3));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -746,12 +751,14 @@ void func_8009C8B8(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, 0, (gameplayFrames * 1) % 128, 32, 32));
gSPSegment(
POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, 0, (gameplayFrames * 1) % 128, 32, 32, 0, 0, 0, 1));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
gSPSegment(POLY_XLU_DISP++, 0x09, Gfx_TexScroll(play->state.gfxCtx, 0, 255 - (gameplayFrames * 10) % 256, 32, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TexScrollEx(play->state.gfxCtx, 0, 255 - (gameplayFrames * 10) % 256, 32, 64, 0, -10));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -770,8 +777,8 @@ void func_8009CAC0(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -800,11 +807,11 @@ void func_8009CC00(PlayState* play) {
gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sGTGEntranceTextures[gSaveContext.nightFlag]));
}
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
{ s32 pad[2]; }
@@ -864,11 +871,14 @@ void func_8009D0E8(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 127 - (gameplayFrames * 4) % 128, 0, 32, 32));
gSPSegment(POLY_OPA_DISP++, 0x09, Gfx_TexScroll(play->state.gfxCtx, 0, (gameplayFrames * 5) % 64, 16, 16));
gSPSegment(POLY_OPA_DISP++, 0x0A, Gfx_TexScroll(play->state.gfxCtx, 0, 63 - (gameplayFrames * 2) % 64, 16, 16));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TexScrollEx(play->state.gfxCtx, 127 - (gameplayFrames * 4) % 128, 0, 32, 32, -4, 0));
gSPSegment(POLY_OPA_DISP++, 0x09, Gfx_TexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 5) % 64, 16, 16, 0, 5));
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TexScrollEx(play->state.gfxCtx, 0, 63 - (gameplayFrames * 2) % 64, 16, 16, 0, -2));
gSPSegment(POLY_XLU_DISP++, 0x0B,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 127 - (gameplayFrames * 3) % 128, 32, 32, 1, 0, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 127 - (gameplayFrames * 3) % 128, 32, 32, 1, 0, 0, 32, 32,
0, -1, 0, 0));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -941,10 +951,10 @@ void func_8009D5B4(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 0, (gameplayFrames * 3) % 128, 32, 32));
gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 3) % 128, 32, 32, 0, 3));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 1023 - (gameplayFrames * 3) % 1024, 16, 256, 1, 0,
1023 - (gameplayFrames * 6) % 1024, 16, 256));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 1023 - (gameplayFrames * 3) % 1024, 16, 256, 1, 0,
1023 - (gameplayFrames * 6) % 1024, 16, 256, 0, -3, 0, -6));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -974,11 +984,11 @@ void func_8009D758(PlayState* play) {
gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sForestTempleEntranceTextures[gSaveContext.nightFlag]));
}
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
{ s32 pad[2]; }
@@ -1023,11 +1033,11 @@ void func_8009DA30(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32, -1, 3, 1, 3));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 10) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 10) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 10) % 128, 32,
32, 1, gameplayFrames % 128, (gameplayFrames * 10) % 128, 32, 32, -1, 10, 1, 10));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1088,14 +1098,14 @@ void func_8009DE78(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 6) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 6) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 6) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 6) % 128, 32, 32, -1, 6, 1, 6));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32, -1, 3, 1, 3));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1121,11 +1131,11 @@ void func_8009E0B8(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 10) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 10) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 10) % 128, 32,
32, 1, gameplayFrames % 128, (gameplayFrames * 10) % 128, 32, 32, -1, 10, 1, 10));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1154,8 +1164,9 @@ void func_8009E0B8(PlayState* play) {
gSPEndDisplayList(displayListHead);
gSPSegment(POLY_OPA_DISP++, 0x0C,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (s16)(-play->roomCtx.unk_74[0] * 0.02f), 32, 16, 1, 0,
(s16)(-play->roomCtx.unk_74[0] * 0.02f), 32, 16));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (s16)(-play->roomCtx.unk_74[0] * 0.02f), 32, 16, 1, 0,
(s16)(-play->roomCtx.unk_74[0] * 0.02f), 32, 16, 0,
play->roomCtx.unk_74[0] == 0 ? 0 : -1, 0, play->roomCtx.unk_74[0] == 0 ? 0 : 1));
CLOSE_DISPS(play->state.gfxCtx);
}
@@ -1173,11 +1184,11 @@ void func_8009E54C(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, gameplayFrames, gameplayFrames, 32, 32, 1, 0, 0, 32, 32,
0, 0, 0, play->roomCtx.unk_74[0] + 168));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, gameplayFrames, gameplayFrames, 32, 32, 1, 0, 0, 32,
32, 0, 0, 0, play->roomCtx.unk_74[0] + 168, 1, 1, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, -gameplayFrames, -gameplayFrames, 32, 32, 1, 0, 0, 16,
64, 0, 0, 0, play->roomCtx.unk_74[0] + 168));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, -gameplayFrames, -gameplayFrames, 32, 32, 1, 0, 0, 16,
64, 0, 0, 0, play->roomCtx.unk_74[0] + 168, -1, -1, 0, 0));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 255, 255, 255, 128);
@@ -1202,7 +1213,8 @@ void func_8009E730(PlayState* play) {
if (LINK_IS_ADULT) {
var = 0;
}
gSPSegment(POLY_OPA_DISP++, 0x0C, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 64, 32, 1, 0, var, 64, 32));
gSPSegment(POLY_OPA_DISP++, 0x0C,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 64, 32, 1, 0, var, 64, 32, 0, 0, 0, -1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1221,14 +1233,15 @@ void func_8009E8C0(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (gameplayFrames * 1) % 128, 0, 32, 32, 1, 0, 0, 32, 32));
gSPSegment(
POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 1) % 128, 0, 32, 32, 1, 0, 0, 32, 32, 1, 0, 0, 0));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 255 - (gameplayFrames * 2) % 256, 64, 64, 1, 0,
255 - (gameplayFrames * 2) % 256, 64, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 255 - (gameplayFrames * 2) % 256, 64, 64, 1, 0,
255 - (gameplayFrames * 2) % 256, 64, 64, 0, -2, 0, -2));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 128, 32, 32, 1, 0,
(gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 128, 32, 32, 1, 0,
(gameplayFrames * 1) % 128, 32, 32, 0, 1, 0, 1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1247,22 +1260,23 @@ void func_8009EAD8(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 3) % 1024, 32, 256, 1, 0,
(gameplayFrames * 3) % 1024, 32, 256));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 3) % 1024, 32, 256, 1, 0,
(gameplayFrames * 3) % 1024, 32, 256, 0, 3, 0, 3));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 256, 64, 64, 1, 0,
(gameplayFrames * 1) % 256, 64, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 256, 64, 64, 1, 0,
(gameplayFrames * 1) % 256, 64, 64, 0, 1, 0, 1));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 2) % 128, 32, 32, 1, 0,
(gameplayFrames * 2) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 2) % 128, 32, 32, 1, 0,
(gameplayFrames * 2) % 128, 32, 32, 0, 2, 0, 2));
gSPSegment(POLY_OPA_DISP++, 0x0B,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, 0, 127 - (gameplayFrames * 3) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, 0, 127 - (gameplayFrames * 3) % 128, 32, 32,
0, 0, 0, -3));
gSPSegment(POLY_XLU_DISP++, 0x0C,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 128, 32, 32, 1, 0,
(gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 128, 32, 32, 1, 0,
(gameplayFrames * 1) % 128, 32, 32, 0, 1, 0, 1));
gSPSegment(POLY_XLU_DISP++, 0x0D,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 64, 16, 16, 1, 0,
(gameplayFrames * 1) % 64, 16, 16));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (gameplayFrames * 1) % 64, 16, 16, 1, 0,
(gameplayFrames * 1) % 64, 16, 16, 0, 1, 0, 1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1280,12 +1294,12 @@ void func_8009EE44(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(
POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, gameplayFrames % 128, 0, 32, 16, 1, gameplayFrames % 128, 0, 32, 16));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, gameplayFrames % 128, 0, 32, 16, 1, gameplayFrames % 128, 0,
32, 16, 1, 0, 1, 0));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, gameplayFrames % 128, 32, 32, 1,
gameplayFrames % 128, gameplayFrames % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, gameplayFrames % 128, 32, 32, 1,
gameplayFrames % 128, gameplayFrames % 128, 32, 32, -1, 1, 1, 1));
gDPPipeSync(POLY_XLU_DISP++);
gDPSetEnvColor(POLY_XLU_DISP++, 128, 128, 128, 128);
@@ -1315,8 +1329,9 @@ void func_8009F074(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, 0, 127 - gameplayFrames % 128, 32, 32));
gSPSegment(
POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, 0, 127 - gameplayFrames % 128, 32, 32, 0, 0, 0, -1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1351,12 +1366,12 @@ void func_8009F270(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(
POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, gameplayFrames % 128, 32, 32, 1, 0, gameplayFrames % 128, 32, 32));
gSPSegment(
POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, gameplayFrames % 128, 32, 32, 1, 0, gameplayFrames % 128, 32, 32));
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, gameplayFrames % 128, 32, 32, 1, 0, gameplayFrames % 128,
32, 32, 0, 1, 0, 1));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, gameplayFrames % 128, 32, 32, 1, 0, gameplayFrames % 128,
32, 32, 0, 1, 0, 1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1375,11 +1390,11 @@ void func_8009F40C(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 10) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 10) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 10) % 128, 32,
32, 1, gameplayFrames % 128, (gameplayFrames * 10) % 128, 32, 32, -1, 10, 1, 10));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 3) % 128, 32, 32, -1, 3, 1, 3));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1437,9 +1452,9 @@ void func_8009F7D4(PlayState* play) {
sp6F = (sp6F >> 1) + 192;
sp6E = (sp6E >> 1) + 192;
gSPSegment(
POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, gameplayFrames % 128, 32, 32, 1, 0, gameplayFrames % 128, 32, 32));
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, gameplayFrames % 128, 32, 32, 1, 0, gameplayFrames % 128,
32, 32, 0, 1, 0, 1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, sp6F, sp6E, 255, 128);
@@ -1463,8 +1478,8 @@ void func_8009F9D0(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 127 - gameplayFrames % 128, 32, 32, 1, gameplayFrames % 128,
0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 127 - gameplayFrames % 128, 32, 32, 1, gameplayFrames % 128,
0, 32, 32, 0, -1, 1, 0));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1509,11 +1524,12 @@ void func_8009FC90(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 127 - gameplayFrames % 128, 32, 32, 1,
127 - gameplayFrames % 128, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 127 - gameplayFrames % 128, 32, 32, 1,
127 - gameplayFrames % 128, 0, 32, 32, 0, -1, -1, 0));
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (gameplayFrames * 3) % 128, 127 - (gameplayFrames * 6) % 128, 32,
32, 1, (gameplayFrames * 6) % 128, 127 - (gameplayFrames * 3) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 3) % 128, 127 - (gameplayFrames * 6) % 128,
32, 32, 1, (gameplayFrames * 6) % 128, 127 - (gameplayFrames * 3) % 128, 32, 32, 3,
-6, 6, -3));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 64);
@@ -1537,15 +1553,15 @@ void func_8009FE58(PlayState* play) {
gameplayFrames = play->gameplayFrames;
if (play->sceneNum == SCENE_JABU_JABU) {
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, gameplayFrames % 128, (gameplayFrames * 2) % 128, 32, 32, 1,
127 - gameplayFrames % 128, (gameplayFrames * 2) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, gameplayFrames % 128, (gameplayFrames * 2) % 128, 32, 32,
1, 127 - gameplayFrames % 128, (gameplayFrames * 2) % 128, 32, 32, 1, 2, -1, 2));
gSPSegment(POLY_OPA_DISP++, 0x0B,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 255 - (gameplayFrames * 4) % 256, 32, 64, 1, 0,
255 - (gameplayFrames * 4) % 256, 32, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 255 - (gameplayFrames * 4) % 256, 32, 64, 1, 0,
255 - (gameplayFrames * 4) % 256, 32, 64, 0, -4, 0, -4));
} else {
gSPSegment(
POLY_OPA_DISP++, 0x08,
Gfx_TexScroll(play->state.gfxCtx, (127 - (gameplayFrames * 1)) % 128, (gameplayFrames * 1) % 128, 32, 32));
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TexScrollEx(play->state.gfxCtx, (127 - (gameplayFrames * 1)) % 128, (gameplayFrames * 1) % 128,
32, 32, -1, 1));
}
gDPPipeSync(POLY_OPA_DISP++);
@@ -1616,14 +1632,14 @@ void func_800A0334(PlayState* play) {
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 512, 32, 128,
1, gameplayFrames % 128, (gameplayFrames * 1) % 512, 32, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 512, 32,
128, 1, gameplayFrames % 128, (gameplayFrames * 1) % 512, 32, 128, -1, 1, 1, 1));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -1651,8 +1667,10 @@ void func_800A059C(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gameplayFrames = play->gameplayFrames;
gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 127 - (gameplayFrames * 2) % 128, 0, 32, 64));
gSPSegment(POLY_OPA_DISP++, 0x09, Gfx_TexScroll(play->state.gfxCtx, 0, (gameplayFrames * 2) % 512, 128, 128));
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TexScrollEx(play->state.gfxCtx, 127 - (gameplayFrames * 2) % 128, 0, 32, 64, -2, 0));
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 2) % 512, 128, 128, 0, 2));
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, 128, 128, 128, 128);
@@ -242,9 +242,9 @@ void ArrowFire_Draw(Actor* thisx, PlayState* play2) {
Matrix_Translate(0.0f, -700.0f, 0.0f, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, sMaterialDL);
gSPDisplayList(POLY_XLU_DISP++,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 255 - (stateFrames * 2) % 256, 0, 64, 32, 1,
255 - stateFrames % 256, 511 - (stateFrames * 10) % 512, 64, 64));
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 255 - (stateFrames * 2) % 256, 0, 64,
32, 1, 255 - stateFrames % 256,
511 - (stateFrames * 10) % 512, 64, 64, -2, 0, -1, -10));
gSPDisplayList(POLY_XLU_DISP++, sModelDL);
CLOSE_DISPS(play->state.gfxCtx);
@@ -240,9 +240,9 @@ void ArrowIce_Draw(Actor* thisx, PlayState* play) {
Matrix_Translate(0.0f, -700.0f, 0.0f, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, sMaterialDL);
gSPDisplayList(POLY_XLU_DISP++,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 511 - (stateFrames * 5) % 512, 0, 128, 32, 1,
511 - (stateFrames * 10) % 512, 511 - (stateFrames * 10) % 512, 4, 16));
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 511 - (stateFrames * 5) % 512, 0, 128,
32, 1, 511 - (stateFrames * 10) % 512,
511 - (stateFrames * 10) % 512, 4, 16, -5, 0, -10, -10));
gSPDisplayList(POLY_XLU_DISP++, sModelDL);
CLOSE_DISPS(play->state.gfxCtx);
@@ -238,9 +238,9 @@ void ArrowLight_Draw(Actor* thisx, PlayState* play) {
Matrix_Translate(0.0f, -700.0f, 0.0f, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, sMaterialDL);
gSPDisplayList(POLY_XLU_DISP++,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 511 - (stateFrames * 5) % 512, 0, 4, 32, 1,
511 - (stateFrames * 10) % 512, 511 - (stateFrames * 30) % 512, 8, 16));
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 511 - (stateFrames * 5) % 512, 0, 4,
32, 1, 511 - (stateFrames * 10) % 512,
511 - (stateFrames * 30) % 512, 8, 16, -5, 0, -10, -30));
gSPDisplayList(POLY_XLU_DISP++, sModelDL);
CLOSE_DISPS(play->state.gfxCtx);
@@ -204,7 +204,8 @@ void BgBowlWall_Draw(Actor* thisx, PlayState* play2) {
OPEN_DISPS(play->state.gfxCtx);
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x8, Gfx_TexScroll(play->state.gfxCtx, 0, -2 * (frames = play->state.frames), 16, 16));
gSPSegment(POLY_OPA_DISP++, 0x8,
Gfx_TexScrollEx(play->state.gfxCtx, 0, -2 * (frames = play->state.frames), 16, 16, 0, -2));
gDPPipeSync(POLY_OPA_DISP++);
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -338,8 +338,8 @@ void BgGanonOtyuka_Draw(Actor* thisx, PlayState* play) {
if ((platform->dyna.actor.projectedPos.z > -30.0f) && (platform->flashState != FLASH_NONE)) {
FrameInterpolation_RecordOpenChild(platform, 0);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, platform->flashTimer * 4, 0, 32, 64, 1,
platform->flashTimer * 4, 0, 32, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, platform->flashTimer * 4, 0, 32, 64, 1,
platform->flashTimer * 4, 0, 32, 64, 4, 0, 4, 0));
gDPPipeSync(POLY_XLU_DISP++);
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, platform->flashPrimColorR, platform->flashPrimColorG,
platform->flashPrimColorB, 0);
@@ -121,11 +121,12 @@ void BgGjyoBridge_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TexScroll(play->state.gfxCtx, play->gameplayFrames & 127, play->gameplayFrames * -3 & 127, 32, 32));
Gfx_TexScrollEx(play->state.gfxCtx, play->gameplayFrames & 127, play->gameplayFrames * -3 & 127, 32, 32,
1, -3));
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, -play->gameplayFrames & 127, 32, 32, 1, 0,
play->gameplayFrames & 127, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, -play->gameplayFrames & 127, 32, 32, 1, 0,
play->gameplayFrames & 127, 32, 32, 0, -1, 0, 1));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -319,8 +319,8 @@ void BgHakaGate_DrawFlame(BgHakaGate* this, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, (this->vScrollTimer * -20) & 0x1FF,
0x20, 0x80));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, (this->vScrollTimer * -20) & 0x1FF,
0x20, 0x80, 0, 0, 0, -20));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 255, 0, 255);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 0);
@@ -237,8 +237,8 @@ void BgHakaTubo_DrawFlameCircle(BgHakaTubo* this, PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 0, 170, 255, 255);
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 255, 255);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->fireScroll & 127, 0, 32, 64, 1, 0,
(this->fireScroll * -15) & 0xFF, 32, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, this->fireScroll & 127, 0, 32, 64, 1, 0,
(this->fireScroll * -15) & 0xFF, 32, 64, 1, 0, 0, -15));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, gEffFireCircleDL);
@@ -123,8 +123,8 @@ void BgHakaWater_Draw(Actor* thisx, PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, (u8)(0.765f * temp));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->gameplayFrames % 128, play->gameplayFrames % 128, 32, 32,
1, 0, (0 - play->gameplayFrames) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, play->gameplayFrames % 128, play->gameplayFrames % 128, 32, 32,
1, 0, (0 - play->gameplayFrames) % 128, 32, 32, 1, 1, 0, -1));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, gBotwWaterRingDL);
@@ -254,8 +254,8 @@ void BgHidanCurtain_Draw(Actor* thisx, PlayState* play) {
gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 0);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->texScroll & 0x7F, 0, 0x20, 0x40, 1, 0,
(this->texScroll * -0xF) & 0xFF, 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, this->texScroll & 0x7F, 0, 0x20, 0x40, 1, 0,
(this->texScroll * -0xF) & 0xFF, 0x20, 0x40, 1, 0, 0, -0xF));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -268,8 +268,8 @@ void BgHidanFwbig_Draw(Actor* thisx, PlayState* play) {
gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 0);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->gameplayFrames % 0x80, 0, 0x20, 0x40, 1, 0,
(u8)(play->gameplayFrames * -15), 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, play->gameplayFrames % 0x80, 0, 0x20, 0x40, 1, 0,
(u8)(play->gameplayFrames * -15), 0x20, 0x40, 1, 0, 0, -15));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -475,20 +475,20 @@ void BgIceShelter_Draw(Actor* thisx, PlayState* play2) {
case 1:
case 4:
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, -play->gameplayFrames & 0x7F,
-play->gameplayFrames & 0x7F, 0x20, 0x20, 1, -play->gameplayFrames & 0x7F,
play->gameplayFrames & 0x7F, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, -play->gameplayFrames & 0x7F,
-play->gameplayFrames & 0x7F, 0x20, 0x20, 1, -play->gameplayFrames & 0x7F,
play->gameplayFrames & 0x7F, 0x20, 0x20, -1, -1, -1, 1));
gSPDisplayList(POLY_XLU_DISP++, gRedIceBlockDL);
break;
case 2:
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, play->gameplayFrames & 0xFF, 0x40, 0x40, 1, 0,
-play->gameplayFrames & 0xFF, 0x40, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, play->gameplayFrames & 0xFF, 0x40, 0x40, 1, 0,
-play->gameplayFrames & 0xFF, 0x40, 0x40, 0, 1, 0, -1));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, -play->gameplayFrames & 0xFF,
play->gameplayFrames & 0xFF, 0x40, 0x40, 1, play->gameplayFrames & 0xFF,
play->gameplayFrames & 0xFF, 0x40, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, -play->gameplayFrames & 0xFF,
play->gameplayFrames & 0xFF, 0x40, 0x40, 1, play->gameplayFrames & 0xFF,
play->gameplayFrames & 0xFF, 0x40, 0x40, -1, 1, 1, 1));
gSPDisplayList(POLY_XLU_DISP++, gRedIcePlatformDL);
break;
@@ -508,17 +508,17 @@ void BgMizuBwall_Draw(Actor* thisx, PlayState* play2) {
Gfx_SetupDL_25Opa(play->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, 1 * frames, 0, 0x20, 0x20, 1, 0, 0, 0x20, 0x20, 0, 0, 0,
this->scrollAlpha1));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, 1 * frames, 0, 0x20, 0x20, 1, 0, 0, 0x20, 0x20, 0, 0,
0, this->scrollAlpha1, 1, 0, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, 1 * frames, 0, 0x20, 0x20, 1, 0, 0, 0x20, 0x20, 0, 0, 0,
this->scrollAlpha2));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, 1 * frames, 0, 0x20, 0x20, 1, 0, 0, 0x20, 0x20, 0, 0,
0, this->scrollAlpha2, 1, 0, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, 1 * frames, 0, 0x20, 0x20, 1, 0, 0, 0x20, 0x20, 0, 0, 0,
this->scrollAlpha3));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, 1 * frames, 0, 0x20, 0x20, 1, 0, 0, 0x20, 0x20, 0, 0,
0, this->scrollAlpha3, 1, 0, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x0B,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, 3 * frames, 0, 0x20, 0x20, 1, 0, 0, 0x20, 0x20, 0, 0, 0,
this->scrollAlpha4));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, 3 * frames, 0, 0x20, 0x20, 1, 0, 0, 0x20, 0x20, 0, 0,
0, this->scrollAlpha4, 3, 0, 0, 0));
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), 2);
if (this->dList != NULL) {
@@ -367,20 +367,20 @@ void BgMizuMovebg_Draw(Actor* thisx, PlayState* play2) {
Gfx_SetupDL_25Opa(play->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, frames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0, 0,
this->scrollAlpha1));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, frames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0, 0,
this->scrollAlpha1, 1, 0, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, frames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0, 0,
this->scrollAlpha2));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, frames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0, 0,
this->scrollAlpha2, 1, 0, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, frames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0, 0,
this->scrollAlpha3));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, frames * 1, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0, 0,
this->scrollAlpha3, 1, 0, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x0B,
Gfx_TwoTexScrollEnvColor(play->state.gfxCtx, 0, frames * 3, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0, 0,
this->scrollAlpha4));
Gfx_TwoTexScrollEnvColorEx(play->state.gfxCtx, 0, frames * 3, 0, 32, 32, 1, 0, 0, 32, 32, 0, 0, 0,
this->scrollAlpha4, 3, 0, 0, 0));
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -332,8 +332,8 @@ void BgMizuWater_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x0C,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, -gameplayFrames * 1, gameplayFrames * 1, 32, 32, 1, 0,
-gameplayFrames * 1, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, -gameplayFrames * 1, gameplayFrames * 1, 32, 32, 1, 0,
-gameplayFrames * 1, 32, 32, -1, 1, 0, -1));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -173,8 +173,8 @@ void BgMoriIdomizu_Draw(Actor* thisx, PlayState* play) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, 128);
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0x7F - (gameplayFrames & 0x7F), gameplayFrames % 0x80, 0x20,
0x20, 1, gameplayFrames & 0x7F, gameplayFrames % 0x80, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0x7F - (gameplayFrames & 0x7F), gameplayFrames % 0x80, 0x20,
0x20, 1, gameplayFrames & 0x7F, gameplayFrames % 0x80, 0x20, 0x20, -1, 1, 1, 1));
gSPDisplayList(POLY_XLU_DISP++, gMoriIdomizuWaterDL);
@@ -168,8 +168,8 @@ void BgPoSyokudai_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (this->flameTextureScroll * -20) & 0x1FF,
32, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0,
(this->flameTextureScroll * -20) & 0x1FF, 32, 128, 0, 0, 0, -20));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, primColor->r, primColor->g, primColor->b, 255);
gDPSetEnvColor(POLY_XLU_DISP++, envColor->r, envColor->g, envColor->b, 255);
@@ -282,8 +282,8 @@ void BgSpot00Hanebasi_DrawTorches(Actor* thisx, PlayState* play2) {
FrameInterpolation_RecordOpenChild("Hanebasi Torch", i);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0,
((play->gameplayFrames + i) * -20) & 0x1FF, 32, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0,
((play->gameplayFrames + i) * -20) & 0x1FF, 32, 128, 0, 0, 0, -20));
Matrix_Translate((i == 0) ? 260.0f : -260.0f, 128.0f, 690.0f, MTXMODE_NEW);
Matrix_RotateY(angle, MTXMODE_APPLY);
@@ -78,8 +78,8 @@ void BgSpot01Idomizu_Draw(Actor* thisx, PlayState* play) {
frames = play->state.frames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - frames % 128, frames & 0x7F, 32, 32, 1, frames % 128,
frames & 0x7F, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - frames % 128, frames & 0x7F, 32, 32, 1, frames % 128,
frames & 0x7F, 32, 32, -1, 1, 1, 1));
gSPDisplayList(POLY_XLU_DISP++, gKakarikoWellWaterDL);
@@ -322,8 +322,8 @@ void func_808AD450(Actor* thisx, PlayState* play) {
gDPSetEnvColor(POLY_XLU_DISP++, 150, 120, 0, 128);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 2 * this->timer, -3 * this->timer, 32, 64, 1,
4 * this->timer, -6 * this->timer, 32, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 2 * this->timer, -3 * this->timer, 32, 64, 1,
4 * this->timer, -6 * this->timer, 32, 64, 2, -3, 4, -6));
gDPPipeSync(POLY_XLU_DISP++);
gSPDisplayList(POLY_XLU_DISP++, object_spot02_objects_DL_0013F0);
gDPPipeSync(POLY_XLU_DISP++);
@@ -130,9 +130,9 @@ void BgSpot03Taki_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(
POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, gameplayFrames * 5, 64, 64, 1, 0, gameplayFrames * 5, 64, 64));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, gameplayFrames * 5, 64, 64, 1, 0, gameplayFrames * 5, 64,
64, 0, 5, 0, 5));
gSPDisplayList(POLY_XLU_DISP++, object_spot03_object_DL_000B20);
@@ -145,8 +145,8 @@ void BgSpot03Taki_Draw(Actor* thisx, PlayState* play) {
gSPDisplayList(POLY_XLU_DISP++, object_spot03_object_DL_000BC0);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, gameplayFrames * 1, gameplayFrames * 3, 64, 64, 1,
-gameplayFrames, gameplayFrames * 3, 64, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, gameplayFrames * 1, gameplayFrames * 3, 64, 64, 1,
-gameplayFrames, gameplayFrames * 3, 64, 64, 1, 3, -1, 3));
gSPDisplayList(POLY_XLU_DISP++, object_spot03_object_DL_001580);
@@ -533,11 +533,11 @@ void BgSpot06Objects_DrawLakeHyliaWater(BgSpot06Objects* this, PlayState* play)
gameplayFrames = play->state.frames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, -gameplayFrames, gameplayFrames, 32, 32, 1, gameplayFrames,
gameplayFrames, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, -gameplayFrames, gameplayFrames, 32, 32, 1, gameplayFrames,
gameplayFrames, 32, 32, -1, 1, 1, 1));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, -gameplayFrames, gameplayFrames * 6, 32, 32, 1, gameplayFrames,
gameplayFrames * 6, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, -gameplayFrames, gameplayFrames * 6, 32, 32, 1, gameplayFrames,
gameplayFrames * 6, 32, 32, -1, 6, 1, 6));
gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, 128);
@@ -86,26 +86,26 @@ void BgSpot07Taki_Draw(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, ((frames * -1) & 0x7F), ((frames * 1) & 0x7F), 32, 32, 1,
((frames * 1) & 0x7F), ((frames * 1) & 0x7F), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, ((frames * -1) & 0x7F), ((frames * 1) & 0x7F), 32, 32, 1,
((frames * 1) & 0x7F), ((frames * 1) & 0x7F), 32, 32, -1, 1, 1, 1));
if (!LINK_IS_ADULT) {
gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, 128);
if (this->dyna.actor.params == 0) {
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, ((frames * -1) & 0x7F), ((frames * -3) & 0xFF), 64, 64,
1, ((frames * 1) & 0x7F), ((frames * -3) & 0xFF), 64, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, ((frames * -1) & 0x7F), ((frames * -3) & 0xFF), 64, 64,
1, ((frames * 1) & 0x7F), ((frames * -3) & 0xFF), 64, 64, -1, -3, 1, -3));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, frames * 0, ((frames * 3) & 0x1FF), 32, 128, 1,
frames * 0, ((frames * 3) & 0x1FF), 32, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, frames * 0, ((frames * 3) & 0x1FF), 32, 128, 1,
frames * 0, ((frames * 3) & 0x1FF), 32, 128, 0, 3, 0, 3));
gSPDisplayList(POLY_XLU_DISP++, object_spot07_object_DL_000460);
} else {
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, frames * 0, ((frames * -1) & 0x7F), 32, 32, 1,
frames * 0, ((frames * -1) & 0x7F), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, frames * 0, ((frames * -1) & 0x7F), 32, 32, 1,
frames * 0, ((frames * -1) & 0x7F), 32, 32, 0, -1, 0, -1));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, frames * 0, ((frames * 3) & 0x1FF), 32, 128, 1,
frames * 0, ((frames * 3) & 0x1FF), 32, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, frames * 0, ((frames * 3) & 0x1FF), 32, 128, 1,
frames * 0, ((frames * 3) & 0x1FF), 32, 128, 0, 3, 0, 3));
gSPDisplayList(POLY_XLU_DISP++, object_spot07_object_DL_000BE0);
}
} else if (this->dyna.actor.params == 0) {
@@ -155,8 +155,8 @@ void BgSpot11Oasis_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 127 - (gameplayFrames % 128), (gameplayFrames * 1) % 128, 32, 32,
1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 127 - (gameplayFrames % 128), (gameplayFrames * 1) % 128, 32,
32, 1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32, -1, 1, 1, 1));
gSPDisplayList(POLY_XLU_DISP++, gDesertColossusOasisDL);
CLOSE_DISPS(play->state.gfxCtx);
}
@@ -129,7 +129,8 @@ void BgSpot16Doughnut_Draw(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
if (this->fireFlag & 1) {
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, scroll * (-1), 0, 16, 32, 1, scroll, scroll * (-2), 16, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, scroll * (-1), 0, 16, 32, 1, scroll, scroll * (-2), 16, 32,
-1, 0, 1, -2));
gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, this->envColorAlpha);
gSPDisplayList(POLY_XLU_DISP++, gDeathMountainCloudCircleFieryDL);
} else {
@@ -63,8 +63,8 @@ void func_808B7478(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (0 - play->gameplayFrames) & 0x7F, 0x20, 0x20, 1, 0,
(0 - play->gameplayFrames) & 0x7F, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (0 - play->gameplayFrames) & 0x7F, 0x20, 0x20, 1, 0,
(0 - play->gameplayFrames) & 0x7F, 0x20, 0x20, 0, -1, 0, -1));
gSPDisplayList(POLY_XLU_DISP++, gCraterSmokeConeDL);
CLOSE_DISPS(play->state.gfxCtx);
@@ -94,9 +94,11 @@ void func_808BA018(BgTokiHikari* this, PlayState* play) {
} else {
gSPDisplayList(POLY_OPA_DISP++, object_toki_objects_DL_007E20);
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 8, Gfx_TexScroll(play->state.gfxCtx, 0, play->gameplayFrames % 128, 64, 32));
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TexScrollEx(play->state.gfxCtx, 0, play->gameplayFrames % 128, 64, 32, 0, 1));
gSPSegment(POLY_XLU_DISP++, 9, Gfx_TexScroll(play->state.gfxCtx, 0, play->gameplayFrames % 128, 64, 32));
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TexScrollEx(play->state.gfxCtx, 0, play->gameplayFrames % 128, 64, 32, 0, 1));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -147,8 +149,8 @@ void func_808BA2CC(BgTokiHikari* this, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, -2 * (play->gameplayFrames & 0x7F), 0, 0x20, 0x40, 1,
(play->gameplayFrames & 0x7F) * 4, 0, 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, -2 * (play->gameplayFrames & 0x7F), 0, 0x20, 0x40, 1,
(play->gameplayFrames & 0x7F) * 4, 0, 0x20, 0x40, -2, 0, 4, 0));
gSPDisplayList(POLY_XLU_DISP++, object_toki_objects_DL_000880);
Matrix_Pop();
@@ -209,7 +209,8 @@ void BgTokiSwd_Draw(Actor* thisx, PlayState* play2) {
func_8002EBCC(&this->actor, play, 0);
gSPSegment(POLY_OPA_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 0, -(play->gameplayFrames % 0x80), 32, 32));
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TexScrollEx(play->state.gfxCtx, 0, -(play->gameplayFrames % 0x80), 32, 32, 0, -1));
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_OPA_DISP++, object_toki_objects_DL_001BD0);
@@ -184,8 +184,9 @@ void BgYdanHasi_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, -play->gameplayFrames % 128, play->gameplayFrames % 128,
0x20, 0x20, 1, play->gameplayFrames % 128, play->gameplayFrames % 128, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, -play->gameplayFrames % 128, play->gameplayFrames % 128,
0x20, 0x20, 1, play->gameplayFrames % 128, play->gameplayFrames % 128, 0x20, 0x20,
-1, 1, 1, 1));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, gDTWaterPlaneDL);
@@ -1841,9 +1841,10 @@ void BossFd_DrawBody(PlayState* play, BossFd* this) {
gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeState]));
}
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (s16)this->fwork[BFD_TEX1_SCROLL_X],
(s16)this->fwork[BFD_TEX1_SCROLL_Y], 0x20, 0x20, 1, (s16)this->fwork[BFD_TEX2_SCROLL_X],
(s16)this->fwork[BFD_TEX2_SCROLL_Y], 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (s16)this->fwork[BFD_TEX1_SCROLL_X],
(s16)this->fwork[BFD_TEX1_SCROLL_Y], 0x20, 0x20, 1,
(s16)this->fwork[BFD_TEX2_SCROLL_X], (s16)this->fwork[BFD_TEX2_SCROLL_Y], 0x20, 0x20,
4, 1, 3, -2));
gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 255, 255, 255);
gDPSetEnvColor(POLY_OPA_DISP++, 255, 255, 255, (s8)this->fwork[BFD_BODY_TEX2_ALPHA]);
@@ -1214,10 +1214,10 @@ void BossFd2_Draw(Actor* thisx, PlayState* play) {
gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(eyeTextures[this->eyeState]));
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (s16)this->fwork[FD2_TEX1_SCROLL_X],
(s16)this->fwork[FD2_TEX1_SCROLL_Y], 0x20, 0x20, 1,
(s16)this->fwork[FD2_TEX2_SCROLL_X], (s16)this->fwork[FD2_TEX2_SCROLL_Y], 0x20,
0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (s16)this->fwork[FD2_TEX1_SCROLL_X],
(s16)this->fwork[FD2_TEX1_SCROLL_Y], 0x20, 0x20, 1,
(s16)this->fwork[FD2_TEX2_SCROLL_X], (s16)this->fwork[FD2_TEX2_SCROLL_Y], 0x20,
0x20, 4, 0, 3, -2));
gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 255, 255, 255);
gDPSetEnvColor(POLY_OPA_DISP++, 255, 255, 255, 128);
@@ -3447,9 +3447,9 @@ void BossGanon_DrawShock(BossGanon* this, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
if (this->shockGlow) {
gSPSegment(
POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (this->unk_1A2 + i) * -15, 32, 64));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (this->unk_1A2 + i) * -15,
32, 64, 0, 0, 0, -15));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 200, 255, 170, 255);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 0, 128);
gSPDisplayList(POLY_XLU_DISP++, gGanondorfShockGlowDL);
@@ -3518,8 +3518,8 @@ void BossGanon_DrawBigMagicCharge(BossGanon* this, PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 170, (s8)this->unk_290);
gDPSetEnvColor(POLY_XLU_DISP++, 200, 255, 0, 128);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->unk_1A2 * -2, 0, 0x40, 0x40, 1, 0, this->unk_1A2 * 0xA,
0x40, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, this->unk_1A2 * -2, 0, 0x40, 0x40, 1, 0,
this->unk_1A2 * 0xA, 0x40, 0x40, -2, 0, 0, 0xA));
Matrix_Translate(this->unk_278.x, this->unk_278.y, this->unk_278.z, MTXMODE_NEW);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Scale(this->unk_28C, this->unk_28C, this->unk_28C, MTXMODE_APPLY);
@@ -3533,14 +3533,15 @@ void BossGanon_DrawBigMagicCharge(BossGanon* this, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 0, 100, (s8)this->unk_288);
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, 0, this->unk_1A2 * -4, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, 0, this->unk_1A2 * -4, 0x20, 0x20, 0,
0, 0, -4));
gSPDisplayList(POLY_XLU_DISP++, gGanondorfBigMagicBGCircleDL);
// yellow background dot
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 150, 170, 0, (s8)this->unk_288);
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, this->unk_1A2 * 2,
this->unk_1A2 * -0x14, 0x40, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, this->unk_1A2 * 2,
this->unk_1A2 * -0x14, 0x40, 0x40, 0, 0, 2, -0x14));
gSPDisplayList(POLY_XLU_DISP++, gGanondorfDotDL);
// light ball material
@@ -3647,8 +3648,8 @@ void BossGanon_DrawDarkVortex(BossGanon* this, PlayState* play) {
Matrix_Push();
gDPPipeSync(POLY_XLU_DISP++);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->unk_1A2 * -8, 0, 0x20, 0x40, 1, this->unk_1A2 * -4,
this->unk_1A2 * -8, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, this->unk_1A2 * -8, 0, 0x20, 0x40, 1, this->unk_1A2 * -4,
this->unk_1A2 * -8, 0x20, 0x20, -8, 0, -4, -8));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 100, 0, 200, (s8)this->fwork[GDF_VORTEX_ALPHA]);
gDPSetEnvColor(POLY_XLU_DISP++, 130, 0, 0, 128);
@@ -5018,8 +5019,8 @@ void BossGanon_DrawEffects(PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 0, 0, 0, eff->alpha);
gDPSetEnvColor(POLY_XLU_DISP++, 100, 70, 0, 128);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, eff->timer * 4, 0, 32, 64, 1, eff->timer * 2,
eff->timer * -20, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, eff->timer * 4, 0, 32, 64, 1, eff->timer * 2,
eff->timer * -20, 32, 32, 4, 0, 2, -20));
Matrix_Translate(eff->pos.x, eff->pos.y, eff->pos.z, MTXMODE_NEW);
Matrix_Scale(eff->scale, eff->unk_40 * eff->scale, eff->scale, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -5037,8 +5038,8 @@ void BossGanon_DrawEffects(PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, eff->alpha);
gDPSetEnvColor(POLY_XLU_DISP++, 200, 100, 0, 128);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, eff->timer * 4, 0, 32, 64, 1, eff->timer * 2,
eff->timer * -20, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, eff->timer * 4, 0, 32, 64, 1, eff->timer * 2,
eff->timer * -20, 32, 32, 4, 0, 2, -20));
Matrix_Translate(eff->pos.x, eff->pos.y, eff->pos.z, MTXMODE_NEW);
Matrix_Scale(eff->scale, eff->unk_40 * eff->scale, eff->scale, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -5056,8 +5057,8 @@ void BossGanon_DrawEffects(PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 170, eff->alpha);
gDPSetEnvColor(POLY_XLU_DISP++, 150, 255, 0, 128);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (eff->timer * 100), 0, 64, 32, 1, (eff->timer * 100), 0,
64, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (eff->timer * 100), 0, 64, 32, 1, (eff->timer * 100),
0, 64, 32, 100, 0, 100, 0));
Matrix_Translate(eff->pos.x, eff->pos.y, eff->pos.z, MTXMODE_NEW);
Matrix_Scale((eff->scale * 200.0f) / 1500.0f, (eff->unk_40 * 200.0f) / 1500.0f,
(eff->scale * 200.0f) / 1500.0f, MTXMODE_APPLY);
@@ -5075,9 +5076,9 @@ void BossGanon_DrawEffects(PlayState* play) {
gDPPipeSync(POLY_XLU_DISP++);
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 150, 170, 0, eff->alpha);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, 128);
gSPSegment(
POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, eff->timer * 2, eff->timer * -20, 64, 64));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, eff->timer * 2, eff->timer * -20, 64,
64, 0, 0, 2, -20));
Matrix_Translate(eff->pos.x, eff->pos.y, eff->pos.z, MTXMODE_NEW);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Scale(eff->scale, eff->scale, 1.0f, MTXMODE_APPLY);
@@ -2449,7 +2449,8 @@ void func_80903F38(BossGanon2* this, PlayState* play) {
if (D_80910638 >= 4) {
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, play->gameplayFrames * 18, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, play->gameplayFrames * 18, 0, 32, 32, 0,
0, 18, 0));
gDPPipeSync(POLY_XLU_DISP++);
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, D_80907080);
Matrix_Translate(0.0f, 0.0f, 0.0f, MTXMODE_NEW);
@@ -2469,8 +2470,8 @@ void func_80904108(BossGanon2* this, PlayState* play) {
Matrix_Push();
gDPPipeSync(POLY_XLU_DISP++);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (s32)play->gameplayFrames, 0, 32, 64, 1,
-play->gameplayFrames * 2, -play->gameplayFrames * 8, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (s32)play->gameplayFrames, 0, 32, 64, 1,
-play->gameplayFrames * 2, -play->gameplayFrames * 8, 32, 32, 1, 0, -2, -8));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 200, 0, (s8)this->unk_324);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 128);
Matrix_Translate(-200.0f, 1086.0f, -200.0f, MTXMODE_NEW);
@@ -2779,8 +2780,8 @@ void func_80905674(BossGanon2* this, PlayState* play) {
Matrix_Push();
gDPPipeSync(POLY_XLU_DISP++);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->unk_19C * -8, 0, 32, 64, 1, this->unk_19C * -4,
this->unk_19C * -8, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, this->unk_19C * -8, 0, 32, 64, 1, this->unk_19C * -4,
this->unk_19C * -8, 32, 32, -8, 0, -4, -8));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 170, (s16)this->unk_37C);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 200, 0, 128);
Matrix_Translate(sBossGanon2Zelda->actor.world.pos.x + 100.0f,
@@ -2975,7 +2976,7 @@ void func_809060E8(PlayState* play) {
Matrix_RotateX(effect->unk_38.y, MTXMODE_APPLY);
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TexScroll(play->state.gfxCtx, 0, 0 - (play->gameplayFrames & 0x7F), 32, 32));
Gfx_TexScrollEx(play->state.gfxCtx, 0, 0 - (play->gameplayFrames & 0x7F), 32, 32, 0, -1));
gSPDisplayList(POLY_OPA_DISP++, gGanonMasterSwordDL);
if ((play->envCtx.unk_BD == 1) || (play->envCtx.unk_BD == 2)) {
alpha = (s16)(play->envCtx.unk_D8 * 150.0f) + 50;
+14 -12
View File
@@ -2601,8 +2601,8 @@ void BossMo_DrawWater(BossMo* this, PlayState* play) {
Matrix_Translate(0.0f, MO_WATER_LEVEL(play), 0.0f, MTXMODE_NEW);
gSPSegment(POLY_XLU_DISP++, 0x0D,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (s16)this->waterTex1x, (s16)this->waterTex1y, 32, 32, 1,
(s16)this->waterTex2x, (s16)this->waterTex2y, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (s16)this->waterTex1x, (s16)this->waterTex1y, 32, 32, 1,
(s16)this->waterTex2x, (s16)this->waterTex2y, 32, 32, -1, -1, 0, 1));
gDPPipeSync(POLY_XLU_DISP++);
@@ -2631,13 +2631,13 @@ void BossMo_DrawCore(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, sMorphaTent1->work[MO_TENT_VAR_TIMER] * 3,
sMorphaTent1->work[MO_TENT_VAR_TIMER] * 3, 32, 32, 1,
sMorphaTent1->work[MO_TENT_VAR_TIMER] * -3,
sMorphaTent1->work[MO_TENT_VAR_TIMER] * -3, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, sMorphaTent1->work[MO_TENT_VAR_TIMER] * 3,
sMorphaTent1->work[MO_TENT_VAR_TIMER] * 3, 32, 32, 1,
sMorphaTent1->work[MO_TENT_VAR_TIMER] * -3,
sMorphaTent1->work[MO_TENT_VAR_TIMER] * -3, 32, 32, 3, 3, -3, -3));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, sMorphaTent1->work[MO_TENT_VAR_TIMER] * 5, 0, 32, 32, 1, 0,
sMorphaTent1->work[MO_TENT_VAR_TIMER] * -10, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, sMorphaTent1->work[MO_TENT_VAR_TIMER] * 5, 0, 32, 32, 1, 0,
sMorphaTent1->work[MO_TENT_VAR_TIMER] * -10, 32, 32, 5, 0, 0, -10));
Matrix_RotateX(this->work[MO_TENT_MOVE_TIMER] * 0.5f, MTXMODE_APPLY);
Matrix_RotateZ(this->work[MO_TENT_MOVE_TIMER] * 0.8f, MTXMODE_APPLY);
@@ -2704,8 +2704,9 @@ void BossMo_DrawCore(Actor* thisx, PlayState* play) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 100, 255, (s8)this->fwork[MO_CORE_INTRO_WATER_ALPHA]);
gSPSegment(POLY_XLU_DISP++, 0x0D,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (s16)sMorphaTent1->waterTex1x, (s16)sMorphaTent1->waterTex1y,
32, 32, 1, (s16)sMorphaTent1->waterTex2x, (s16)sMorphaTent1->waterTex2y, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (s16)sMorphaTent1->waterTex1x,
(s16)sMorphaTent1->waterTex1y, 32, 32, 1, (s16)sMorphaTent1->waterTex2x,
(s16)sMorphaTent1->waterTex2y, 32, 32, 0, 0, 0, 0));
sp8C = this->cameraAt.x - this->cameraEye.x;
sp88 = this->cameraAt.y - this->cameraEye.y;
@@ -2755,8 +2756,9 @@ void BossMo_DrawTent(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->work[MO_TENT_BASE_TEX1_X], this->work[MO_TENT_BASE_TEX1_Y],
32, 32, 1, this->work[MO_TENT_BASE_TEX2_X], this->work[MO_TENT_BASE_TEX2_Y], 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, this->work[MO_TENT_BASE_TEX1_X],
this->work[MO_TENT_BASE_TEX1_Y], 32, 32, 1, this->work[MO_TENT_BASE_TEX2_X],
this->work[MO_TENT_BASE_TEX2_Y], 32, 32, 1, 1, 1, 1));
gDPSetPrimColor(POLY_XLU_DISP++, 0xFF, 0xFF, 200, 255, 255, (s8)((this->baseAlpha * 12.0f) / 10.0f));
gDPSetEnvColor(POLY_XLU_DISP++, 0, 100, 255, (s8)this->baseAlpha);
scroll = (s16)(Math_SinS(this->work[MO_TENT_VAR_TIMER] * 0xB00) * 30.0f) + 350;
@@ -3195,8 +3195,8 @@ void BossSst_DrawEffect(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
if (this->effectMode == BONGO_ICE) {
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, play->gameplayFrames % 256, 0x20, 0x10, 1, 0,
(play->gameplayFrames * 2) % 256, 0x40, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, play->gameplayFrames % 256, 0x20, 0x10, 1, 0,
(play->gameplayFrames * 2) % 256, 0x40, 0x20, 0, 1, 0, 2));
gDPSetEnvColor(POLY_XLU_DISP++, 0, 50, 100, this->effects[0].alpha);
gSPDisplayList(POLY_XLU_DISP++, gBongoIceCrystalDL);
@@ -3229,8 +3229,8 @@ void BossSst_DrawEffect(Actor* thisx, PlayState* play) {
gDPPipeSync(POLY_XLU_DISP++);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->gameplayFrames % 128, 0, 0x20, 0x40, 1, 0,
(play->gameplayFrames * -15) % 256, 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, play->gameplayFrames % 128, 0, 0x20, 0x40, 1, 0,
(play->gameplayFrames * -15) % 256, 0x20, 0x40, 1, 0, 0, -15));
for (i = 0; i < 3; i++, scaleY -= 0.001f) {
effect = &this->effects[i];
+84 -72
View File
@@ -3267,8 +3267,8 @@ void func_80941BC0(BossTw* this, PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 215, 215, 215, (s16)this->workf[UNK_F11] * this->workf[UNK_F14]);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, 128);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, (u32)this->workf[UNK_F16] & 0x3F,
(this->work[CS_TIMER_2] * 4) & 0x3F, 0x10, 0x10));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, (u32)this->workf[UNK_F16] & 0x3F,
(this->work[CS_TIMER_2] * 4) & 0x3F, 0x10, 0x10, 0, 0, 5, 4));
Matrix_Push();
Matrix_RotateY(this->workf[UNK_F15], MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_LOAD | G_MTX_MODELVIEW | G_MTX_NOPUSH);
@@ -3276,9 +3276,9 @@ void func_80941BC0(BossTw* this, PlayState* play) {
Matrix_Pop();
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_LOAD | G_MTX_MODELVIEW | G_MTX_NOPUSH);
gSPSegment(POLY_XLU_DISP++, 0xD,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->work[CS_TIMER_2] & 0x7F,
(this->work[CS_TIMER_2] * 8) & 0xFF, 0x20, 0x40, 1,
(-this->work[CS_TIMER_2] * 2) & 0x3F, 0, 0x10, 0x10));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, this->work[CS_TIMER_2] & 0x7F,
(this->work[CS_TIMER_2] * 8) & 0xFF, 0x20, 0x40, 1,
(-this->work[CS_TIMER_2] * 2) & 0x3F, 0, 0x10, 0x10, 1, 8, 2, 0));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 195, 225, 235, (s16)this->workf[UNK_F9]);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 255, 255, 128);
gDPSetRenderMode(POLY_XLU_DISP++,
@@ -3303,8 +3303,8 @@ void func_80942180(BossTw* this, PlayState* play) {
Matrix_Translate(this->groundBlastPos2.x, this->groundBlastPos2.y, this->groundBlastPos2.z, MTXMODE_NEW);
Matrix_Scale(this->workf[KM_GD_CRTR_SCL], this->workf[KM_GD_CRTR_SCL], this->workf[KM_GD_CRTR_SCL], MTXMODE_APPLY);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (-this->work[CS_TIMER_1]) & 0x7F, 0, 0x20, 0x20, 1,
(this->work[CS_TIMER_1] * 2) & 0x7F, 0, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (-this->work[CS_TIMER_1]) & 0x7F, 0, 0x20, 0x20, 1,
(this->work[CS_TIMER_1] * 2) & 0x7F, 0, 0x20, 0x20, -1, 0, 2, 0));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_LOAD | G_MTX_MODELVIEW | G_MTX_NOPUSH);
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 100, 40, 00, (s16)this->workf[KM_GRND_CRTR_A]);
gDPPipeSync(POLY_XLU_DISP++);
@@ -3314,17 +3314,18 @@ void func_80942180(BossTw* this, PlayState* play) {
Matrix_ReplaceRotation(&play->billboardMtxF);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_LOAD | G_MTX_MODELVIEW | G_MTX_NOPUSH);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->work[CS_TIMER_1] & 0x7F,
(-this->work[CS_TIMER_1] * 6) & 0xFF, 0x20, 0x40, 1,
(this->work[CS_TIMER_1] * 2) & 0x7F, (-this->work[CS_TIMER_1] * 6) & 0xFF, 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, this->work[CS_TIMER_1] & 0x7F,
(-this->work[CS_TIMER_1] * 6) & 0xFF, 0x20, 0x40, 1,
(this->work[CS_TIMER_1] * 2) & 0x7F, (-this->work[CS_TIMER_1] * 6) & 0xFF, 0x20, 0x40,
1, -6, 2, -6));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 80, 0, 0, (s16)this->workf[KM_GD_SMOKE_A]);
gDPPipeSync(POLY_XLU_DISP++);
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, 100);
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gTwinrovaFireSmokeDL));
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (-this->work[CS_TIMER_1] * 3) & 0x7F, 0, 0x20, 0x20, 1, 0,
(-this->work[CS_TIMER_1] * 10) & 0xFF, 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (-this->work[CS_TIMER_1] * 3) & 0x7F, 0, 0x20, 0x20, 1, 0,
(-this->work[CS_TIMER_1] * 10) & 0xFF, 0x20, 0x40, -3, 0, 0, -10));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 100, 50, 0, (s16)(this->workf[KM_GD_FLM_A] * 0.7f));
gDPPipeSync(POLY_XLU_DISP++);
gDPSetEnvColor(POLY_XLU_DISP++, 200, 235, 240, 128);
@@ -3344,8 +3345,8 @@ void func_809426F0(BossTw* this, PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (u8)(-this->work[CS_TIMER_2] * 15), 0x20, 0x40, 1, 0, 0, 0x40,
0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (u8)(-this->work[CS_TIMER_2] * 15), 0x20, 0x40, 1, 0, 0,
0x40, 0x40, 0, -15, 0, 0));
Matrix_Push();
Matrix_Translate(0.0f, 0.0f, 5000.0f, MTXMODE_APPLY);
Matrix_Scale(this->spawnPortalScale / 2000.0f, this->spawnPortalScale / 2000.0f, this->spawnPortalScale / 2000.0f,
@@ -3379,8 +3380,9 @@ void func_809426F0(BossTw* this, PlayState* play) {
Matrix_RotateZ(((i * M_PI) * 2.0f * 0.125f) + this->flameRotation, MTXMODE_APPLY);
Matrix_Translate(0.0f, this->spawnPortalScale * 1.5f, 0.0f, MTXMODE_APPLY);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, ((this->work[CS_TIMER_2] * 3) + (i * 10)) & 0x7F,
(u8)((-this->work[CS_TIMER_2] * 15) + (i * 50)), 0x20, 0x40, 1, 0, 0, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, ((this->work[CS_TIMER_2] * 3) + (i * 10)) & 0x7F,
(u8)((-this->work[CS_TIMER_2] * 15) + (i * 50)), 0x20, 0x40, 1, 0, 0, 0x20, 0x20,
3, -15, 0, 0));
Matrix_Scale(0.4f, 0.4f, 0.4f, MTXMODE_APPLY);
Matrix_ReplaceRotation(&play->billboardMtxF);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_LOAD | G_MTX_MODELVIEW | G_MTX_NOPUSH);
@@ -3402,7 +3404,7 @@ void func_80942C70(Actor* thisx, PlayState* play) {
if (this->beamDist != 0.0f) {
Matrix_Push();
gSPSegment(POLY_XLU_DISP++, 0xC,
Gfx_TexScroll(play->state.gfxCtx, 0, (u8)(this->work[CS_TIMER_1] * -0xF), 0x20, 0x40));
Gfx_TexScrollEx(play->state.gfxCtx, 0, (u8)(this->work[CS_TIMER_1] * -0xF), 0x20, 0x40, 0, -0xF));
alpha = this->beamScale * 100.0f * 255.0f;
if (this->actor.params == 1) {
@@ -3480,21 +3482,24 @@ void BossTw_Draw(Actor* thisx, PlayState* play2) {
gSPSegment(POLY_OPA_DISP++, 10, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeTexIdx]));
gSPSegment(POLY_XLU_DISP++, 10, SEGMENTED_TO_VIRTUAL(sEyeTextures[this->eyeTexIdx]));
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (s16)this->workf[OUTR_CRWN_TX_X1] & 0x7F,
(s16)this->workf[OUTR_CRWN_TX_Y1] & 0x7F, 0x20, 0x20, 1,
(s16)this->workf[OUTR_CRWN_TX_X2] & 0x7F, (s16)this->workf[OUTR_CRWN_TX_Y2] & 0xFF,
0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (s16)this->workf[OUTR_CRWN_TX_X1] & 0x7F,
(s16)this->workf[OUTR_CRWN_TX_Y1] & 0x7F, 0x20, 0x20, 1,
(s16)this->workf[OUTR_CRWN_TX_X2] & 0x7F,
(s16)this->workf[OUTR_CRWN_TX_Y2] & 0xFF, 0x20, 0x40, 0, 0,
this->actor.params == 0 ? 1 : 0, this->actor.params == 0 ? -7 : -15));
if (this->actor.params == TW_KOTAKE) {
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TexScroll(play->state.gfxCtx, (s16)this->workf[INNR_CRWN_TX_X1] & 0x7F,
(s16)this->workf[INNR_CRWN_TX_Y1] & 0xFF, 0x20, 0x40));
Gfx_TexScrollEx(play->state.gfxCtx, (s16)this->workf[INNR_CRWN_TX_X1] & 0x7F,
(s16)this->workf[INNR_CRWN_TX_Y1] & 0xFF, 0x20, 0x40, 0,
this->actor.params == 0 ? 1 : 0));
} else {
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (s16)this->workf[INNR_CRWN_TX_X1] & 0x7F,
(s16)this->workf[INNR_CRWN_TX_Y1] & 0x7F, 0x20, 0x20, 1,
(s16)this->workf[INNR_CRWN_TX_X2] & 0x7F,
(s16)this->workf[INNR_CRWN_TX_Y2] & 0xFF, 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (s16)this->workf[INNR_CRWN_TX_X1] & 0x7F,
(s16)this->workf[INNR_CRWN_TX_Y1] & 0x7F, 0x20, 0x20, 1,
(s16)this->workf[INNR_CRWN_TX_X2] & 0x7F,
(s16)this->workf[INNR_CRWN_TX_Y2] & 0xFF, 0x20, 0x40, 0, 0, 0,
this->actor.params == 0 ? 0 : -10));
}
Gfx_SetupDL_25Opa(play->state.gfxCtx);
@@ -3562,7 +3567,7 @@ s32 BossTw_TwinrovaOverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList,
switch (limbIndex) {
case 21:
gSPSegment(POLY_OPA_DISP++, 0xC,
Gfx_TexScroll(play->state.gfxCtx, 0, (s16)(f32)this->work[CS_TIMER_1], 8, 8));
Gfx_TexScrollEx(play->state.gfxCtx, 0, (s16)(f32)this->work[CS_TIMER_1], 8, 8, 0, 1));
gSPSegment(POLY_OPA_DISP++, 8, SEGMENTED_TO_VIRTUAL(D_8094A9B0[this->eyeTexIdx]));
gSPSegment(POLY_OPA_DISP++, 9, SEGMENTED_TO_VIRTUAL(D_8094A9B0[this->leftEyeTexIdx]));
gDPSetEnvColor(POLY_OPA_DISP++, 255, 255, 255, this->work[UNK_S8]);
@@ -3571,27 +3576,28 @@ s32 BossTw_TwinrovaOverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList,
case 41:
*dList = NULL;
gSPSegment(POLY_XLU_DISP++, 0xA,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, 0, -this->work[CS_TIMER_1] * 0xF,
0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, 0, -this->work[CS_TIMER_1] * 0xF,
0x20, 0x40, 0, 0, 0, -0xF));
break;
case 18:
case 42:
*dList = NULL;
gSPSegment(POLY_XLU_DISP++, 0xB,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, 0, -this->work[CS_TIMER_1] * 0xA,
0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, 0, -this->work[CS_TIMER_1] * 0xA,
0x20, 0x40, 0, 0, 0, -0xA));
break;
case 16:
case 32:
*dList = NULL;
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, this->work[CS_TIMER_1],
-this->work[CS_TIMER_1] * 7, 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, this->work[CS_TIMER_1],
-this->work[CS_TIMER_1] * 7, 0x20, 0x40, 0, 0, 1, -7));
break;
case 15:
case 31:
*dList = NULL;
gSPSegment(POLY_XLU_DISP++, 9, Gfx_TexScroll(play->state.gfxCtx, 0, this->work[CS_TIMER_1], 0x20, 0x40));
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TexScrollEx(play->state.gfxCtx, 0, this->work[CS_TIMER_1], 0x20, 0x40, 0, 1));
break;
case 19:
if (this->unk_5F8 != 0) {
@@ -3702,16 +3708,18 @@ void BossTw_ShieldChargeDraw(BossTw* this, PlayState* play) {
gDPSetEnvColor(POLY_XLU_DISP++, 255, 245, 255, temp_a0);
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gTwinrovaMirrorShieldFireChargeSidesDL));
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (this->work[CS_TIMER_1] * 2) * temp_t0, 0, 0x20,
0x20, 1, (-this->work[CS_TIMER_1] * 2) * temp_t0, 0, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (this->work[CS_TIMER_1] * 2) * temp_t0, 0, 0x20,
0x20, 1, (-this->work[CS_TIMER_1] * 2) * temp_t0, 0, 0x20, 0x20, 0,
2 * temp_t0, -2 * temp_t0, 0));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 100, 20, 0, (s16)D_8094C854);
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gTwinrovaMirrorShieldFireChargeCenterDL));
} else {
gDPSetEnvColor(POLY_XLU_DISP++, 225, 255, 255, temp_a0);
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gTwinrovaMirrorShieldIceChargeSidesDL));
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (-this->work[CS_TIMER_1] * 5) * temp_t0, 0x20,
0x40, 1, (this->work[CS_TIMER_1] * 4) * temp_t0, 0, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (-this->work[CS_TIMER_1] * 5) * temp_t0, 0x20,
0x40, 1, (this->work[CS_TIMER_1] * 4) * temp_t0, 0, 0x20, 0x200, 0,
-5 * temp_t0, 4 * temp_t0, 0));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 175, 205, 195, (s16)D_8094C854);
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gTwinrovaMirrorShieldIceChargeCenterDL));
}
@@ -3745,8 +3753,8 @@ void BossTw_ShieldChargeDraw(BossTw* this, PlayState* play) {
}
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, this->work[CS_TIMER_1] * D_8094C872, 0x20, 0x40, 1, 0,
this->work[CS_TIMER_1] * D_8094C872, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, this->work[CS_TIMER_1] * D_8094C872, 0x20, 0x40, 1, 0,
this->work[CS_TIMER_1] * D_8094C872, 0x20, 0x20, 0, D_8094C872, 0, D_8094C872));
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gTwinrovaShieldAbsorbAndReflectEffectDL));
}
@@ -3761,9 +3769,9 @@ void BossTw_SpawnPortalDraw(BossTw* this, PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(
POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, -this->work[CS_TIMER_1] * 15, 0x20, 0x40, 1, 0, 0, 0x40, 0x40));
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, -this->work[CS_TIMER_1] * 15, 0x20, 0x40, 1, 0, 0, 0x40,
0x40, 0, -15, 0, 0));
Matrix_Push();
@@ -3812,16 +3820,16 @@ void func_80944C50(BossTw* this, PlayState* play) {
Matrix_Pop();
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, -sKoumePtr->work[CS_TIMER_1] * 2, 0, 0x20, 0x20, 1,
-sKoumePtr->work[CS_TIMER_1] * 2, 0, 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, -sKoumePtr->work[CS_TIMER_1] * 2, 0, 0x20, 0x20, 1,
-sKoumePtr->work[CS_TIMER_1] * 2, 0, 0x20, 0x40, -2, 0, -2, 0));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, (s16)this->workf[UNK_F18] / 2);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_LOAD | G_MTX_MODELVIEW | G_MTX_NOPUSH);
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gTwinrovaLightRaysDL));
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, -sKoumePtr->work[CS_TIMER_1] * 5,
-sKoumePtr->work[CS_TIMER_1] * 2, 0x20, 0x40, 1, 0, -sKoumePtr->work[CS_TIMER_1] * 2,
0x10, 0x10));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, -sKoumePtr->work[CS_TIMER_1] * 5,
-sKoumePtr->work[CS_TIMER_1] * 2, 0x20, 0x40, 1, 0, -sKoumePtr->work[CS_TIMER_1] * 2,
0x10, 0x10, -5, -2, 0, -2));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, (s16)(this->workf[UNK_F18] * 0.3f));
scale = this->workf[UNK_F18] / 150.0f;
@@ -4416,9 +4424,9 @@ void BossTw_BlastDraw(Actor* thisx, PlayState* play2) {
FrameInterpolation_RecordOpenChild("Twinrova Fire Blast", i);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, ((this->work[CS_TIMER_1] * 3) + (i * 10)) & 0x7F,
((-this->work[CS_TIMER_1] * 15) + (i * 50)) & 0xFF, 0x20, 0x40, 1, 0, 0,
0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, ((this->work[CS_TIMER_1] * 3) + (i * 10)) & 0x7F,
((-this->work[CS_TIMER_1] * 15) + (i * 50)) & 0xFF, 0x20, 0x40, 1, 0, 0,
0x20, 0x20, 3, -15, 0, 0));
tailIdx = ((this->work[TAIL_IDX] - i) + 30) % 30;
Matrix_Translate(this->blastTailPos[tailIdx].x, this->blastTailPos[tailIdx].y,
this->blastTailPos[tailIdx].z, MTXMODE_NEW);
@@ -4444,9 +4452,9 @@ void BossTw_BlastDraw(Actor* thisx, PlayState* play2) {
FrameInterpolation_RecordOpenChild("Twinrova Ice Blast", i);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, ((this->work[CS_TIMER_1] * 3) + (i * 0xA)) & 0x7F,
(u8)((-this->work[CS_TIMER_1] * 0xF) + (i * 50)), 0x20, 0x40, 1, 0, 0, 0x20,
0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, ((this->work[CS_TIMER_1] * 3) + (i * 0xA)) & 0x7F,
(u8)((-this->work[CS_TIMER_1] * 0xF) + (i * 50)), 0x20, 0x40, 1, 0, 0,
0x20, 0x20, 3, -0xF, 0, 0));
tailIdx = ((this->work[TAIL_IDX] - i) + 30) % 30;
Matrix_Translate(this->blastTailPos[tailIdx].x, this->blastTailPos[tailIdx].y,
this->blastTailPos[tailIdx].z, MTXMODE_NEW);
@@ -4488,9 +4496,9 @@ void BossTw_DrawDeathBall(Actor* thisx, PlayState* play2) {
FrameInterpolation_RecordOpenChild("Twinrova Death Ball 0", i);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (((this->work[CS_TIMER_1] * 3) + (i * 0xA))) & 0x7F,
(u8)((-this->work[CS_TIMER_1] * 0xF) + (i * 50)), 0x20, 0x40, 1, 0, 0, 0x20,
0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (((this->work[CS_TIMER_1] * 3) + (i * 0xA))) & 0x7F,
(u8)((-this->work[CS_TIMER_1] * 0xF) + (i * 50)), 0x20, 0x40, 1, 0, 0, 0x20,
0x20, 3, -0xF, 0, 0));
tailIdx = ((this->work[TAIL_IDX] - i) + 30) % 30;
Matrix_Translate(this->blastTailPos[tailIdx].x, this->blastTailPos[tailIdx].y,
this->blastTailPos[tailIdx].z, MTXMODE_NEW);
@@ -4511,9 +4519,9 @@ void BossTw_DrawDeathBall(Actor* thisx, PlayState* play2) {
FrameInterpolation_RecordOpenChild("Twinrova Death Ball 1", i);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (((this->work[CS_TIMER_1] * 3) + (i * 0xA))) & 0x7F,
(u8)((-this->work[CS_TIMER_1] * 0xF) + (i * 50)), 0x20, 0x40, 1, 0, 0, 0x20,
0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (((this->work[CS_TIMER_1] * 3) + (i * 0xA))) & 0x7F,
(u8)((-this->work[CS_TIMER_1] * 0xF) + (i * 50)), 0x20, 0x40, 1, 0, 0, 0x20,
0x20, 3, -0xF, 0, 0));
tailIdx = ((this->work[TAIL_IDX] - i) + 30) % 30;
Matrix_Translate(this->blastTailPos[tailIdx].x, this->blastTailPos[tailIdx].y,
this->blastTailPos[tailIdx].z, MTXMODE_NEW);
@@ -4924,8 +4932,9 @@ void BossTw_DrawEffects(PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 195, 225, 235, currentEffect->alpha);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (currentEffect->frame * 3) & 0x7F,
(currentEffect->frame * 15) & 0xFF, 0x20, 0x40, 1, 0, 0, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (currentEffect->frame * 3) & 0x7F,
(currentEffect->frame * 15) & 0xFF, 0x20, 0x40, 1, 0, 0, 0x20, 0x20, 3, 15, 0,
0));
Matrix_Translate(currentEffect->pos.x, currentEffect->pos.y, currentEffect->pos.z, MTXMODE_NEW);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Scale(currentEffect->workf[EFF_SCALE], currentEffect->workf[EFF_SCALE], 1.0f, MTXMODE_APPLY);
@@ -4952,8 +4961,9 @@ void BossTw_DrawEffects(PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 200, 20, 0, currentEffect->alpha);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (currentEffect->frame * 3) & 0x7F,
(currentEffect->frame * 15) & 0xFF, 0x20, 0x40, 1, 0, 0, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (currentEffect->frame * 3) & 0x7F,
(currentEffect->frame * 15) & 0xFF, 0x20, 0x40, 1, 0, 0, 0x20, 0x20, 3, 15, 0,
0));
Matrix_Translate(currentEffect->pos.x, currentEffect->pos.y, currentEffect->pos.z, MTXMODE_NEW);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Scale(currentEffect->workf[EFF_SCALE], currentEffect->workf[EFF_SCALE], 1.0f, MTXMODE_APPLY);
@@ -4978,9 +4988,9 @@ void BossTw_DrawEffects(PlayState* play) {
}
gSPSegment(POLY_XLU_DISP++, 0xD,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, currentEffect->frame & 0x7F,
(currentEffect->frame * 8) & 0xFF, 0x20, 0x40, 1,
(currentEffect->frame * -2) & 0x7F, 0, 0x10, 0x10));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, currentEffect->frame & 0x7F,
(currentEffect->frame * 8) & 0xFF, 0x20, 0x40, 1,
(currentEffect->frame * -2) & 0x7F, 0, 0x10, 0x10, 1, 8, -2, 0));
if (currentEffect->work[EFF_ARGS] == 1) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 65, 0, currentEffect->alpha);
@@ -5027,8 +5037,9 @@ void BossTw_DrawEffects(PlayState* play) {
if (sp18F == 0) {
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gTwinrovaIceSurroundingPlayerMaterialDL));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 195, 225, 235, 255);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, 0, 0x20, 0x20));
gSPSegment(
POLY_XLU_DISP++, 8,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, 0, 0x20, 0x20, 0, 0, 0, 0));
sp18F++;
BossTw_InitRand(1, 0x71AC, 0x263A);
}
@@ -5080,8 +5091,9 @@ void BossTw_DrawEffects(PlayState* play) {
}
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (currentEffect->frame * 3) & 0x7F,
(-currentEffect->frame * 15) & 0xFF, 0x20, 0x40, 1, 0, 0, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (currentEffect->frame * 3) & 0x7F,
(-currentEffect->frame * 15) & 0xFF, 0x20, 0x40, 1, 0, 0, 0x20, 0x20, 3, -15,
0, 0));
Matrix_Translate(currentEffect->pos.x, currentEffect->pos.y, currentEffect->pos.z, MTXMODE_NEW);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Scale(currentEffect->workf[EFF_SCALE], currentEffect->workf[EFF_SCALE], 1.0f, MTXMODE_APPLY);
+11 -11
View File
@@ -2897,9 +2897,9 @@ s32 BossVa_BodyOverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec
if (limbIndex == 20) {
gDPPipeSync(POLY_OPA_DISP++);
gSPSegment(
POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 8, 16, 1, 0, (play->gameplayFrames * -2) % 64, 16, 16));
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 8, 16, 1, 0, (play->gameplayFrames * -2) % 64, 16,
16, 0, 0, 0, -2));
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, this->bodyGlow);
Matrix_RotateX(-M_PI / 2, MTXMODE_APPLY);
} else if ((limbIndex >= 10) && (limbIndex < 20)) {
@@ -2948,8 +2948,8 @@ void BossVa_BodyPostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s*
Matrix_MultVec3f(&sp78, &this->effectPos[limbIndex - 10]);
} else if (limbIndex == 25) {
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (play->gameplayFrames * 10) % 128, 16, 32, 1, 0,
(play->gameplayFrames * 5) % 128, 16, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (play->gameplayFrames * 10) % 128, 16, 32, 1, 0,
(play->gameplayFrames * 5) % 128, 16, 32, 0, 10, 0, 5));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, gBarinadeDL_008D70);
} else if ((*dList != NULL) && (limbIndex >= 29) && (limbIndex < 56)) {
@@ -3173,8 +3173,8 @@ void BossVa_BariPostLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s*
if (limbIndex == 2) {
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (play->gameplayFrames * 10) % 32, 16, 32, 1, 0,
(play->gameplayFrames * -5) % 32, 16, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (play->gameplayFrames * 10) % 32, 16, 32, 1, 0,
(play->gameplayFrames * -5) % 32, 16, 32, 0, 10, 0, -5));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, gBarinadeDL_000FA0);
} else if ((limbIndex == 3) || (limbIndex == 4)) {
@@ -3221,11 +3221,11 @@ void BossVa_Draw(Actor* thisx, PlayState* play) {
if (!this->isDead) {
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 8, 16, 1, 0, (play->gameplayFrames * -10) % 16,
16, 16));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 8, 16, 1, 0,
(play->gameplayFrames * -10) % 16, 16, 16, 0, 0, 0, -10));
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (play->gameplayFrames * -10) % 32, 16, 0x20, 1, 0,
(play->gameplayFrames * -5) % 32, 16, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (play->gameplayFrames * -10) % 32, 16, 0x20, 1,
0, (play->gameplayFrames * -5) % 32, 16, 32, 0, -10, 0, -5));
SkelAnime_DrawSkeletonOpa(play, &this->skelAnime, BossVa_BodyOverrideLimbDraw, BossVa_BodyPostLimbDraw,
this);
}
@@ -570,8 +570,8 @@ void func_80967FFC(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
Matrix_RotateX(-M_PI / 2, MTXMODE_APPLY);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0x7FFF - ((timer1 * 8) & 0x7FFF), 16, 512, 1, 0,
0x7FFF - ((timer1 * 8) & 0x7FFF), 16, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0x7FFF - ((timer1 * 8) & 0x7FFF), 16, 512, 1, 0,
0x7FFF - ((timer1 * 8) & 0x7FFF), 16, 32, 0, -8, 0, -8));
{
s32 i;
@@ -639,8 +639,8 @@ void func_80968298(Actor* thisx, PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, 210, 210, 210, 255);
gDPSetEnvColor(POLY_XLU_DISP++, 100, 100, 100, 255);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (0xFFF - (timer1 * 6)) & 0xFFF, (timer1 * 12) & 0xFFF, 128, 64,
1, (0xFFF - (timer1 * 6)) & 0xFFF, (timer1 * 12) & 0xFFF, 64, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (0xFFF - (timer1 * 6)) & 0xFFF, (timer1 * 12) & 0xFFF, 128, 64,
1, (0xFFF - (timer1 * 6)) & 0xFFF, (timer1 * 12) & 0xFFF, 64, 32, -6, 12, -6, 12));
gSPDisplayList(POLY_XLU_DISP++, object_demo_6k_DL_0039D0);
Matrix_Scale(scale, scale, scale, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -737,8 +737,8 @@ void func_80968B70(Actor* thisx, PlayState* play) {
Matrix_RotateX(M_PI / 2, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0xFF - ((timer2 * 2) & 0xFF), 0, 32, 32, 1,
0xFF - ((timer2 * 2) & 0xFF), (timer2 * 15) & 0x3FF, 16, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0xFF - ((timer2 * 2) & 0xFF), 0, 32, 32, 1,
0xFF - ((timer2 * 2) & 0xFF), (timer2 * 15) & 0x3FF, 16, 64, -2, 0, -2, 15));
if (this->timer2 < 40) {
primColor[0] = primColor[2] = 100 - (this->timer2 * 2.5f);
@@ -1739,29 +1739,29 @@ void DemoEffect_DrawJewel(Actor* thisx, PlayState* play2) {
switch (this->jewel.type) {
case DEMO_EFFECT_JEWEL_KOKIRI:
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (frames * 4) % 256,
(256 - ((frames * 2) % 256)) - 1, 64, 64, 1, (frames * 2) % 256,
(256 - (frames % 256)) - 1, 16, 16));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (frames * 4) % 256,
(256 - ((frames * 2) % 256)) - 1, 64, 64, 1, (frames * 2) % 256,
(256 - (frames % 256)) - 1, 16, 16, 4, -2, 2, -1));
break;
case DEMO_EFFECT_JEWEL_GORON:
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (frames * 4) % 128,
(256 - ((frames * 2) % 256)) - 1, 32, 64, 1, (frames * 2) % 256,
(256 - (frames % 256)) - 1, 16, 8));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (frames * 4) % 128,
(256 - ((frames * 2) % 256)) - 1, 32, 64, 1, (frames * 2) % 256,
(256 - (frames % 256)) - 1, 16, 8, 4, -2, 2, -1));
break;
case DEMO_EFFECT_JEWEL_ZORA:
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (frames * 4) % 256,
(256 - ((frames * 2) % 256)) - 1, 32, 32, 1, (frames * 2) % 256,
(256 - (frames % 256)) - 1, 16, 16));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (frames * 4) % 256,
(256 - ((frames * 2) % 256)) - 1, 32, 32, 1, (frames * 2) % 256,
(256 - (frames % 256)) - 1, 16, 16, 4, -2, 2, -1));
break;
}
if (!frames) {}
gSPSegment(POLY_OPA_DISP++, 8, Gfx_TexScroll(play->state.gfxCtx, (u8)frames, (u8)frames, 16, 16));
gSPSegment(POLY_OPA_DISP++, 8, Gfx_TexScrollEx(play->state.gfxCtx, (u8)frames, (u8)frames, 16, 16, 1, 1));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
@@ -1801,8 +1801,8 @@ void DemoEffect_DrawCrystalLight(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (frames * 2) % 512, 512 - (frames % 512) - 1, 128, 128, 1,
512 - ((frames * 2) % 512) - 1, 0, 64, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (frames * 2) % 512, 512 - (frames % 512) - 1, 128, 128, 1,
512 - ((frames * 2) % 512) - 1, 0, 64, 64, 2, -1, -2, 0));
Matrix_Push();
Matrix_RotateY(0.0f, MTXMODE_APPLY);
Matrix_RotateX((11.0 * M_PI) / 180.0, MTXMODE_APPLY);
@@ -1841,7 +1841,8 @@ void DemoEffect_DrawFireBall(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPMatrix(POLY_XLU_DISP++, play->billboardMtx, G_MTX_NOPUSH | G_MTX_MUL | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, 0, 128 - ((frames * 20) % 128) - 1, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 32, 1, 0, 128 - ((frames * 20) % 128) - 1, 32, 32, 0,
0, 0, -20));
gSPDisplayList(POLY_XLU_DISP++, gCreationFireBallDL);
CLOSE_DISPS(play->state.gfxCtx);
}
@@ -1871,11 +1872,11 @@ void DemoEffect_DrawGodLgt(Actor* thisx, PlayState* play) {
}
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (frames * 4) % 512, 0, 128, 64, 1, (frames * 2) % 256,
512 - ((frames * 70) % 512) - 1, 64, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (frames * 4) % 512, 0, 128, 64, 1, (frames * 2) % 256,
512 - ((frames * 70) % 512) - 1, 64, 32, 4, 0, 2, -70));
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 16, 96, 1, (frames * 10) % 256,
256 - ((frames * 30) % 512) - 1, 8, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 16, 96, 1, (frames * 10) % 256,
256 - ((frames * 30) % 512) - 1, 8, 32, 0, 0, 10, -30));
gDPSetPrimColor(POLY_XLU_DISP++, 128, 128, this->primXluColor[0], this->primXluColor[1], this->primXluColor[2],
255);
gDPSetEnvColor(POLY_XLU_DISP++, this->envXluColor[0], this->envXluColor[1], this->envXluColor[2], 255);
@@ -1975,8 +1976,8 @@ void DemoEffect_DrawLgtShower(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (frames * 5) % 1024, 0, 256, 64, 1, (frames * 10) % 128,
512 - ((frames * 50) % 512), 32, 16));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (frames * 5) % 1024, 0, 256, 64, 1, (frames * 10) % 128,
512 - ((frames * 50) % 512), 32, 16, 5, 0, 10, -50));
gSPDisplayList(POLY_XLU_DISP++, gEnliveningLightDL);
CLOSE_DISPS(play->state.gfxCtx);
}
@@ -1996,8 +1997,8 @@ void DemoEffect_DrawLightRing(Actor* thisx, PlayState* play2) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 100, 255, 255);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (frames * 5) % 64, 512 - ((frames * 2) % 512) - 1, 16, 128, 1, 0,
0, 8, 1024));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (frames * 5) % 64, 512 - ((frames * 2) % 512) - 1, 16, 128, 1,
0, 0, 8, 1024, 5, -2, 0, 0));
gSPDisplayList(POLY_XLU_DISP++, gGoldenGoddessLightRingDL);
CLOSE_DISPS(play->state.gfxCtx);
@@ -2022,8 +2023,8 @@ void DemoEffect_DrawTriforceSpot(Actor* thisx, PlayState* play) {
Matrix_Scale(1.0f, 2.4f, 1.0f, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 256 - ((frames * 4) % 256) - 1, 64, 64, 1, 0,
256 - ((frames * 2) % 256) - 1, 64, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 256 - ((frames * 4) % 256) - 1, 64, 64, 1, 0,
256 - ((frames * 2) % 256) - 1, 64, 32, 0, -4, 0, -2));
vertices[86].n.a = vertices[87].n.a = vertices[88].n.a = vertices[89].n.a = vertices[92].n.a =
vertices[93].n.a = vertices[94].n.a = vertices[95].n.a = (s8)this->triforceSpot.lightColumnOpacity;
gDPSetPrimColor(POLY_XLU_DISP++, 128, 128, 180, 255, 255, this->triforceSpot.lightColumnOpacity);
@@ -2043,7 +2044,8 @@ void DemoEffect_DrawTriforceSpot(Actor* thisx, PlayState* play) {
Matrix_RotateY(this->triforceSpot.rotation * (M_PI / 0x8000), MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 8, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 16, 1, 0, 0, 16, 8));
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 16, 1, 0, 0, 16, 8, 0, 0, 0, 0));
gDPSetPrimColor(POLY_XLU_DISP++, 128, 128, 255, 255, 160, this->triforceSpot.triforceSpotOpacity);
gDPSetEnvColor(POLY_XLU_DISP++, 170, 140, 0, 255);
gSPDisplayList(POLY_XLU_DISP++, gTriforceDL);
@@ -2054,7 +2056,8 @@ void DemoEffect_DrawTriforceSpot(Actor* thisx, PlayState* play) {
Matrix_RotateY(this->triforceSpot.rotation * (M_PI / 0x8000), MTXMODE_APPLY);
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_OPA_DISP++, 8, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 16, 1, 0, 0, 16, 8));
gSPSegment(POLY_OPA_DISP++, 8,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 16, 1, 0, 0, 16, 8, 0, 0, 0, 0));
gDPSetPrimColor(POLY_OPA_DISP++, 128, 128, 255, 255, 160, 255);
gDPSetEnvColor(POLY_OPA_DISP++, 170, 140, 0, 255);
gSPDisplayList(POLY_OPA_DISP++, gTriforceDL);
@@ -2154,8 +2157,8 @@ s32 DemoEffect_DrawTimewarpLimbs(PlayState* play, SkelAnimeCurve* skelCuve, s32
gDPSetPrimColor(POLY_XLU_DISP++, 0, 128, 170, 255, 255, 255);
gDPSetEnvColor(POLY_XLU_DISP++, this->envXluColor[0], this->envXluColor[1], this->envXluColor[2], 255);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (frames * 6) % 1024, 256 - ((frames * 16) % 256) - 1, 256, 64, 1,
(frames * 4) % 512, 128 - ((frames * 12) % 128) - 1, 128, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (frames * 6) % 1024, 256 - ((frames * 16) % 256) - 1, 256, 64,
1, (frames * 4) % 512, 128 - ((frames * 12) % 128) - 1, 128, 32, 6, -16, 4, -12));
CLOSE_DISPS(play->state.gfxCtx);
if (limbIndex == 0) {
@@ -205,9 +205,9 @@ void DemoExt_DrawVortex(Actor* thisx, PlayState* play) {
gDPSetEnvColor(POLY_XLU_DISP++, kREG(29) + 90, kREG(30) + 50, kREG(31) + 95, this->envAlpha);
curScroll = this->curScroll;
gSPSegment(
POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(gfxCtx, 0, curScroll[0], curScroll[1], 0x40, 0x40, 1, curScroll[2], curScroll[3], 0x40, 0x40));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScrollEx(gfxCtx, 0, curScroll[0], curScroll[1], 0x40, 0x40, 1, curScroll[2], curScroll[3],
0x40, 0x40, 25, 40, 5, 30));
gSPMatrix(POLY_XLU_DISP++, mtx, G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, gPhantomWarpDL);
@@ -669,18 +669,20 @@ void DemoGt_Draw1(DemoGt* this, PlayState* play) {
Gfx_SetupDL_25Opa(gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEnvColor(gfxCtx, 0, 0, unk198[0], 0x20, 0x40, 1, 0, unk198[1], 0x20, 0x40, unk178[0],
unk178[1], unk178[2], 0x80));
Gfx_TwoTexScrollEnvColorEx(gfxCtx, 0, 0, unk198[0], 0x20, 0x40, 1, 0, unk198[1], 0x20, 0x40, unk178[0],
unk178[1], unk178[2], 0x80, 0, unk198[0] < 0 ? -1 : 1, 0,
unk198[1] < 0 ? -1 : 1));
gSPSegment(POLY_OPA_DISP++, 0x0A,
Gfx_TwoTexScrollEnvColor(gfxCtx, 0, 0, unk198[0], 0x20, 0x40, 1, 0, unk198[1], 0x20, 0x40, unk188[0],
unk188[1], unk188[2], 0x80));
Gfx_TwoTexScrollEnvColorEx(gfxCtx, 0, 0, unk198[0], 0x20, 0x40, 1, 0, unk198[1], 0x20, 0x40, unk188[0],
unk188[1], unk188[2], 0x80, 0, unk198[0] < 0 ? -1 : 1, 0,
unk198[1] < 0 ? -1 : 1));
gSPMatrix(POLY_OPA_DISP++, spB4, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_OPA_DISP++, gTowerCollapseCsExteriorStructureDL);
Gfx_SetupDL_25Xlu(gfxCtx);
gDPSetEnvColor(POLY_XLU_DISP++, 128, 128, 128, 128);
gSPSegment(
POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(gfxCtx, 0, 0, gameplayFrames * 0x14, 0x10, 0x200, 1, 0, gameplayFrames * 0x1E, 0x10, 0x200));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScrollEx(gfxCtx, 0, 0, gameplayFrames * 0x14, 0x10, 0x200, 1, 0, gameplayFrames * 0x1E, 0x10,
0x200, 0, 0x14, 0, 0x1E));
gSPMatrix(POLY_XLU_DISP++, spB4, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, gTowerCollapseCsFlameSmokeDL);
@@ -855,8 +857,9 @@ void DemoGt_Draw2(DemoGt* this, PlayState* play) {
unk198 = this->unk_198;
unk178 = this->unk_178;
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScrollEnvColor(gfxCtx, 0, 0, unk198[0], 0x20, 0x40, 1, 0, unk198[1], 0x20, 0x40, unk178[0],
unk178[1], unk178[2], 128));
Gfx_TwoTexScrollEnvColorEx(gfxCtx, 0, 0, unk198[0], 0x20, 0x40, 1, 0, unk198[1], 0x20, 0x40, unk178[0],
unk178[1], unk178[2], 128, 0, unk198[0] < 0 ? -1 : 1, 0,
unk198[1] < 0 ? -1 : 1));
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(gfxCtx), G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_OPA_DISP++, gTowerCollapseCsCollapsedStructureInnerDL);
gSPPopMatrix(POLY_OPA_DISP++, G_MTX_MODELVIEW);
@@ -720,7 +720,8 @@ void DemoKankyo_DrawLightPlane(Actor* thisx, PlayState* play) {
if (play->csCtx.state == CS_STATE_IDLE || gSaveContext.sceneSetupIndex >= 4) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TexScroll(play->state.gfxCtx, 0, play->state.frames & 0x7F, 64, 32));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TexScrollEx(play->state.gfxCtx, 0, play->state.frames & 0x7F, 64, 32, 0, 1));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, object_toki_objects_DL_008390);
}
@@ -302,15 +302,16 @@ void DemoKekkai_DrawTrialBarrier(Actor* thisx, PlayState* play2) {
Matrix_Translate(0.0f, -1200.0f, 0.0f, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, frames * 5, frames * -10, 0x20, 0x20, 1, frames * 5,
frames * -10, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, frames * 5, frames * -10, 0x20, 0x20, 1, frames * 5,
frames * -10, 0x20, 0x20, 5, -10, 5, -10));
gSPDisplayList(POLY_XLU_DISP++, gTrialBarrierOrbDL);
Matrix_Pop();
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPPipeSync(POLY_XLU_DISP++);
gDPSetPrimColor(POLY_XLU_DISP++, 0x00, 0x80, 50, 0, 100, 255);
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, frames, frames, 0x20, 0x20));
gSPSegment(
POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, frames, frames, 0x20, 0x20, 0, 0, 1, 1));
gSPDisplayList(POLY_XLU_DISP++, gTrialBarrierFloorDL);
gDPPipeSync(POLY_XLU_DISP++);
gDPSetPrimColor(POLY_XLU_DISP++, 0x00, 0x80, sEnergyColors[colorIndex + 0], sEnergyColors[colorIndex + 1],
@@ -318,8 +319,8 @@ void DemoKekkai_DrawTrialBarrier(Actor* thisx, PlayState* play2) {
gDPSetEnvColor(POLY_XLU_DISP++, sEnergyColors[colorIndex + 3], sEnergyColors[colorIndex + 4],
sEnergyColors[colorIndex + 5], 128);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, frames * 5, frames * -10, 0x20, 0x20, 1, frames * 5,
frames * -10, 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, frames * 5, frames * -10, 0x20, 0x20, 1, frames * 5,
frames * -10, 0x20, 0x40, 5, -10, 5, -10));
gSPDisplayList(POLY_XLU_DISP++, gTrialBarrierEnergyDL);
CLOSE_DISPS(play->state.gfxCtx);
}
@@ -336,8 +337,8 @@ void DemoKekkai_DrawTowerBarrier(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPSetPrimColor(POLY_XLU_DISP++, 0x00, 0x80, 255, 170, 255, 255);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, scroll * 2, scroll * -4, 0x20, 0x40, 1, scroll * 2, scroll * -4,
0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, scroll * 2, scroll * -4, 0x20, 0x40, 1, scroll * 2,
scroll * -4, 0x20, 0x40, 2, -4, 2, -4));
gSPDisplayList(POLY_XLU_DISP++, gTowerBarrierDL);
CLOSE_DISPS(play->state.gfxCtx);
}
@@ -110,12 +110,14 @@ void DemoShd_Draw(Actor* thisx, PlayState* play) {
gSPDisplayList(POLY_XLU_DISP++, D_809932D0);
if (this->unk_14C & 1) {
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0x3FF - ((unk_14E * 5) & 0x3FF), 16,
256, 1, 0, 255 - ((unk_14E * 5) & 255), 32, 32));
gSPDisplayList(POLY_XLU_DISP++,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0x3FF - ((unk_14E * 5) & 0x3FF), 16, 256, 1, 0,
255 - ((unk_14E * 5) & 255), 32, 32, 0, -5, 0, -5));
gSPDisplayList(POLY_XLU_DISP++, D_80993390);
} else if (this->unk_14C & 2) {
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0x3FF - ((unk_14E * 5) & 0x3FF), 16,
256, 1, 0, 255 - ((unk_14E * 5) & 255), 32, 32));
gSPDisplayList(POLY_XLU_DISP++,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0x3FF - ((unk_14E * 5) & 0x3FF), 16, 256, 1, 0,
255 - ((unk_14E * 5) & 255), 32, 32, 0, -5, 0, -5));
gSPDisplayList(POLY_XLU_DISP++, D_809934B8);
}
@@ -139,8 +139,8 @@ s32 DemoTreLgt_PostLimbDraw(PlayState* play, SkelAnimeCurve* skelCurve, s32 limb
OPEN_DISPS(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (play->state.frames * 2) % 256, 0, 64, 32, 1,
(play->state.frames * -2) % 256, 0, 64, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (play->state.frames * 2) % 256, 0, 64, 32, 1,
(play->state.frames * -2) % 256, 0, 64, 32, 2, 0, -2, 0));
if (limbIndex == 1) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, 255, 255, 180, this->unk_170);
@@ -1035,9 +1035,9 @@ void DoorWarp1_DrawWarp(DoorWarp1* this, PlayState* play) {
Matrix_Push();
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, spEC & 0xFF, -((s16)(this->unk_19C + this->unk_19C) & 511),
0x100, 0x100, 1, spEC & 0xFF, -((s16)(this->unk_19C + this->unk_19C) & 511), 0x100,
0x100));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, spEC & 0xFF, -((s16)(this->unk_19C + this->unk_19C) & 511),
0x100, 0x100, 1, spEC & 0xFF, -((s16)(this->unk_19C + this->unk_19C) & 511), 0x100,
0x100, 10, -2, 10, -2));
Matrix_Translate(0.0f, this->unk_194 * 230.0f, 0.0f, MTXMODE_APPLY);
xzScale = (((f32)this->unk_1AE * spE8) / 100.0f) + 1.0f;
@@ -1072,8 +1072,8 @@ void DoorWarp1_DrawWarp(DoorWarp1* this, PlayState* play) {
spEC *= 2;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, spEC & 0xFF, -((s16)this->unk_19C & 511), 0x100, 0x100, 1,
spEC & 0xFF, -((s16)this->unk_19C & 511), 0x100, 0x100));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, spEC & 0xFF, -((s16)this->unk_19C & 511), 0x100, 0x100, 1,
spEC & 0xFF, -((s16)this->unk_19C & 511), 0x100, 0x100, 10, -1, 10, -1));
Matrix_Translate(0.0f, this->unk_198 * 60.0f, 0.0f, MTXMODE_APPLY);
@@ -121,16 +121,16 @@ void EfcErupc_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->unk_14C * 1, this->unk_14E * -4, 32, 64, 1,
this->unk_14C * 4, this->unk_14E * -20, 64, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, this->unk_14C * 1, this->unk_14E * -4, 32, 64, 1,
this->unk_14C * 4, this->unk_14E * -20, 64, 64, 1, -4, 4, -20));
gSPSegment(
POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, this->unk_150 * -4, 16, 128, 1, 0, this->unk_150 * 12, 32, 32));
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, this->unk_150 * -4, 16, 128, 1, 0, this->unk_150 * 12, 32,
32, 0, -4, 0, 12));
gSPSegment(
POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, this->unk_150 * -4, 16, 128, 1, 0, this->unk_150 * 12, 32, 32));
gSPSegment(POLY_XLU_DISP++, 0x0A,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, this->unk_150 * -4, 16, 128, 1, 0, this->unk_150 * 12, 32,
32, 0, -4, 0, 12));
Matrix_Push();
Matrix_Scale(0.8f, 0.8f, 0.8f, MTXMODE_APPLY);
+6 -6
View File
@@ -489,9 +489,9 @@ void EnBa_Draw(Actor* thisx, PlayState* play) {
Matrix_Push();
gSPSegment(POLY_OPA_DISP++, 0x0C, mtx);
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_809B8118[this->actor.params]));
gSPSegment(
POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 16, 16, 1, 0, (play->gameplayFrames * -10) % 128, 32, 32));
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 16, 16, 1, 0, (play->gameplayFrames * -10) % 128, 32,
32, 0, 0, 0, -10));
for (i = 0; i < 14; i++, mtx++) {
FrameInterpolation_RecordOpenChild(this, this->epoch + i * 25);
@@ -518,9 +518,9 @@ void EnBa_Draw(Actor* thisx, PlayState* play) {
gSPDisplayList(POLY_OPA_DISP++, object_bxa_DL_000890);
} else {
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (play->gameplayFrames * 2) % 128,
(play->gameplayFrames * 2) % 128, 32, 32, 1, (play->gameplayFrames * -5) % 128,
(play->gameplayFrames * -5) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (play->gameplayFrames * 2) % 128,
(play->gameplayFrames * 2) % 128, 32, 32, 1, (play->gameplayFrames * -5) % 128,
(play->gameplayFrames * -5) % 128, 32, 32, 2, 2, -5, -5));
gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 125, 100, 255);
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_OPA_DISP++, object_bxa_DL_001D80);
+5 -5
View File
@@ -1329,11 +1329,11 @@ void EnBb_Draw(Actor* thisx, PlayState* play) {
if (this->actor.params != ENBB_WHITE) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0,
((play->gameplayFrames + (this->flameScrollMod * 10)) *
(-20 - (this->flameScrollMod * -2))) %
0x200,
0x20, 0x80));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0,
((play->gameplayFrames + (this->flameScrollMod * 10)) *
(-20 - (this->flameScrollMod * -2))) %
0x200,
0x20, 0x80, 0, 0, 0, (-20 - (this->flameScrollMod * -2))));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 255, this->flamePrimBlue, this->flamePrimAlpha);
gDPSetEnvColor(POLY_XLU_DISP++, this->flameEnvColor.r, this->flameEnvColor.g, this->flameEnvColor.b, 0);
Matrix_RotateY(((s16)(Camera_GetCamDirYaw(GET_ACTIVE_CAM(play)) - this->actor.shape.rot.y + 0x8000)) *
@@ -167,8 +167,9 @@ void EnBlkobj_Draw(Actor* thisx, PlayState* play) {
gameplayFrames = play->gameplayFrames % 128;
gSPSegment(POLY_XLU_DISP++, 0x0D,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, gameplayFrames, 0, 32, 32, 1, gameplayFrames, 0, 32, 32));
gSPSegment(
POLY_XLU_DISP++, 0x0D,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, gameplayFrames, 0, 32, 32, 1, gameplayFrames, 0, 32, 32, 1, 0, 1, 0));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
if (this->alpha != 0) {
+5 -4
View File
@@ -815,8 +815,9 @@ s32 EnBw_OverrideLimbDraw(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* po
EnBw* this = (EnBw*)thisx;
if (limbIndex == 1) {
gSPSegment((*gfx)++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, 0, this->unk_23A, 0x20, 0x20));
gSPSegment(
(*gfx)++, 0x09,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x20, 1, 0, this->unk_23A, 0x20, 0x20, 0, 0, 0, 1));
if ((this->unk_220 == 1) || (this->unk_220 == 5)) {
Matrix_Push();
Matrix_Scale(1.0f, 1.0f, 1.0f, MTXMODE_APPLY);
@@ -883,8 +884,8 @@ void EnBw_Draw(Actor* thisx, PlayState* play2) {
gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 0);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, (play->gameplayFrames * -20) % 0x200,
0x20, 0x80));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, (play->gameplayFrames * -20) % 0x200,
0x20, 0x80, 0, 0, 0, -20));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 255, 0, 255);
Matrix_Scale(this->unk_248 * 0.01f, this->unk_248 * 0.01f, this->unk_248 * 0.01f, MTXMODE_APPLY);
Matrix_ReplaceRotation(&play->billboardMtxF);
+2 -1
View File
@@ -215,7 +215,8 @@ void EnBx_Draw(Actor* thisx, PlayState* play) {
gSPSegment(POLY_OPA_DISP++, 0x0C, mtx);
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_809D2560[this->actor.params & 0x7F]));
gSPSegment(POLY_OPA_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 16, 16, 1, 0, (play->gameplayFrames * -10) % 128, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 16, 16, 1, 0, (play->gameplayFrames * -10) % 128, 32, 32,
0, 0, 0, -10));
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
if (this->actor.params & 0x80) {
@@ -980,7 +980,8 @@ void EnClearTag_DrawEffects(PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, (s8)effect->primColor.r, (s8)effect->primColor.g,
(s8)effect->primColor.b, (s8)effect->primColor.a);
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, effect->random * -5, 32, 64, 1, 0, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, effect->random * -5, 32, 64, 1, 0, 0, 32, 32, 0, -5,
0, 0));
Matrix_Translate(effect->position.x, effect->position.y, effect->position.z, MTXMODE_NEW);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Scale(effect->scale, effect->scale, 1.0f, MTXMODE_APPLY);
@@ -1008,9 +1009,9 @@ void EnClearTag_DrawEffects(PlayState* play) {
// Draw the fire effect.
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 200, 20, 0, (s8)effect->primColor.a);
gSPSegment(
POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, (effect->random * -15) & 0xFF, 32, 64, 1, 0, 0, 32, 32));
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, (effect->random * -15) & 0xFF, 32, 64, 1, 0, 0, 32,
32, 0, -15, 0, 0));
Matrix_Translate(effect->position.x, effect->position.y, effect->position.z, MTXMODE_NEW);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Scale(effect->scale, effect->scale, 1.0f, MTXMODE_APPLY);
+3 -2
View File
@@ -572,8 +572,9 @@ void EnDh_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gDPSetEnvColor(POLY_XLU_DISP++, 85, 55, 0, 130);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (play->state.frames * -3) % 0x80, 0, 0x20, 0x40, 1,
(play->state.frames * -10) % 0x80, (play->state.frames * -20) % 0x100, 0x20, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (play->state.frames * -3) % 0x80, 0, 0x20, 0x40, 1,
(play->state.frames * -10) % 0x80, (play->state.frames * -20) % 0x100, 0x20, 0x40,
-3, 0, -10, -20));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 0, 0, 0, this->dirtWaveAlpha);
Matrix_Translate(0.0f, -this->actor.shape.yOffset, 0.0f, MTXMODE_APPLY);
@@ -115,8 +115,8 @@ void EnDyExtra_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->state.frames * 2, 0, 0x20, 0x40, 1, play->state.frames,
play->state.frames * -8, 0x10, 0x10));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, play->state.frames * 2, 0, 0x20, 0x40, 1, play->state.frames,
play->state.frames * -8, 0x10, 0x10, 2, 0, 1, -8));
gDPPipeSync(POLY_XLU_DISP++);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, primColors[this->type].r, primColors[this->type].g,
+2 -1
View File
@@ -787,7 +787,8 @@ void EnFd_Draw(Actor* thisx, PlayState* play) {
gDPSetEnvColor(POLY_XLU_DISP++, envColors[clampedHealth / 8].r, envColors[clampedHealth / 8].g,
envColors[clampedHealth / 8].b, (u8)this->fadeAlpha);
gSPSegment(POLY_XLU_DISP++, 0x8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, 0xFF - (u8)(frames * 6), 8, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, 0xFF - (u8)(frames * 6), 8, 0x40,
0, 0, 0, -6));
gDPPipeSync(POLY_XLU_DISP++);
gSPSegment(POLY_XLU_DISP++, 0x9, D_80116280);
@@ -265,9 +265,9 @@ void EnFdFire_Draw(Actor* thisx, PlayState* play) {
Matrix_Scale(1.0f, sp84, 1.0f / sp84, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(
POLY_XLU_DISP++, 0x8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, play->state.frames * this->tile2Y, 0x20, 0x80));
gSPSegment(POLY_XLU_DISP++, 0x8,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, play->state.frames * this->tile2Y,
0x20, 0x80, 0, 0, 0, this->tile2Y));
gDPSetPrimColor(POLY_XLU_DISP++, 128, 128, primColors[((this->actor.params & 0x8000) >> 0xF)].r,
primColors[((this->actor.params & 0x8000) >> 0xF)].g,
primColors[((this->actor.params & 0x8000) >> 0xF)].b,
@@ -735,10 +735,12 @@ void EnFhgFire_Draw(Actor* thisx, PlayState* play) {
gDPPipeSync(POLY_XLU_DISP++);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (s16)this->fwork[FHGFIRE_WARP_TEX_1_X],
(s16)this->fwork[FHGFIRE_WARP_TEX_1_Y], 0x40, 0x40, 1,
(s16)this->fwork[FHGFIRE_WARP_TEX_2_X], (s16)this->fwork[FHGFIRE_WARP_TEX_2_Y],
0x40, 0x40));
Gfx_TwoTexScrollEx(
play->state.gfxCtx, 0, (s16)this->fwork[FHGFIRE_WARP_TEX_1_X],
(s16)this->fwork[FHGFIRE_WARP_TEX_1_Y], 0x40, 0x40, 1, (s16)this->fwork[FHGFIRE_WARP_TEX_2_X],
(s16)this->fwork[FHGFIRE_WARP_TEX_2_Y], 0x40, 0x40, 25 * this->fwork[FHGFIRE_WARP_TEX_SPEED],
-40 * this->fwork[FHGFIRE_WARP_TEX_SPEED], 5 * this->fwork[FHGFIRE_WARP_TEX_SPEED],
-30 * this->fwork[FHGFIRE_WARP_TEX_SPEED]));
gSPDisplayList(POLY_XLU_DISP++, gPhantomWarpDL);
} else {
osSyncPrintf("FF DRAW 1\n");
+4 -4
View File
@@ -737,8 +737,8 @@ void EnFz_Draw(Actor* thisx, PlayState* play) {
func_8002ED80(&this->actor, play, 0);
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, play->state.frames & 0x7F, 32, 32, 1, 0,
(2 * play->state.frames) & 0x7F, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, play->state.frames & 0x7F, 32, 32, 1, 0,
(2 * play->state.frames) & 0x7F, 32, 32, 0, 1, 0, 2));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPSetCombineLERP(POLY_XLU_DISP++, TEXEL1, PRIMITIVE, PRIM_LOD_FRAC, TEXEL0, TEXEL1, TEXEL0, PRIMITIVE, TEXEL0,
PRIMITIVE, ENVIRONMENT, COMBINED, ENVIRONMENT, COMBINED, 0, ENVIRONMENT, 0);
@@ -887,8 +887,8 @@ void EnFz_DrawIceSmoke(EnFz* this, PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 195, 225, 235, iceSmoke->primAlpha);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 3 * (iceSmoke->timer + (3 * i)),
15 * (iceSmoke->timer + (3 * i)), 32, 64, 1, 0, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 3 * (iceSmoke->timer + (3 * i)),
15 * (iceSmoke->timer + (3 * i)), 32, 64, 1, 0, 0, 32, 32, 3, 15, 0, 0));
Matrix_Translate(iceSmoke->pos.x, iceSmoke->pos.y, iceSmoke->pos.z, MTXMODE_NEW);
Matrix_ReplaceRotation(&play->billboardMtxF);
Matrix_Scale(iceSmoke->xyScale, iceSmoke->xyScale, 1.0f, MTXMODE_APPLY);
+3 -2
View File
@@ -536,8 +536,9 @@ void EnGb_DrawCagedSouls(EnGb* this, PlayState* play) {
FrameInterpolation_RecordOpenChild(&this->cagedSouls[i], this->cagedSouls[i].epoch);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0,
(u32)(sCagedSoulInfo[idx].timerMultiplier * this->frameTimer) % 512, 32, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0,
(u32)(sCagedSoulInfo[idx].timerMultiplier * this->frameTimer) % 512, 32, 128, 0,
0, 0, sCagedSoulInfo[idx].timerMultiplier));
gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(sCagedSoulInfo[idx].texture));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, sCagedSoulInfo[idx].prim.r, sCagedSoulInfo[idx].prim.g,
sCagedSoulInfo[idx].prim.b, sCagedSoulInfo[idx].prim.a);
+2 -1
View File
@@ -613,7 +613,8 @@ void EnGs_Draw(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, -frames * 0x14, 0x20, 0x80));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, -frames * 0x14, 0x20, 0x80, 0,
0, 0, -0x14));
gDPSetPrimColor(POLY_XLU_DISP++, 128, 128, 255, 255, 0, 255);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 0);
gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
@@ -514,8 +514,9 @@ void EnHonotrap_DrawFlame(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
this->flameScroll -= 20;
this->flameScroll &= 0x1FF;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, this->flameScroll, 0x20, 0x80));
gSPSegment(
POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, this->flameScroll, 0x20, 0x80, 0, 0, 0, -20));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 200, 0, 255);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 0);
Matrix_RotateY((s16)(Camera_GetCamDirYaw(GET_ACTIVE_CAM(play)) - this->actor.shape.rot.y + 0x8000) *
@@ -377,7 +377,8 @@ void EnIceHono_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (play->state.frames * -20) % 512, 32, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (play->state.frames * -20) % 512, 32, 128,
0, 0, 0, -20));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 170, 255, 255, this->alpha);
@@ -164,7 +164,8 @@ void EnLight_Draw(Actor* thisx, PlayState* play) {
if (this->actor.params >= 0) {
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (this->timer * -20) & 511, 32, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (this->timer * -20) & 511, 32, 128, 0,
0, 0, -20));
dList = gEffFire1DL;
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, flameParams->primColor.r, flameParams->primColor.g,
@@ -172,8 +173,8 @@ void EnLight_Draw(Actor* thisx, PlayState* play) {
gDPSetEnvColor(POLY_XLU_DISP++, flameParams->envColor.r, flameParams->envColor.g, flameParams->envColor.b, 0);
} else {
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 16, 32, 1, ((this->timer * 2) & 63),
(this->timer * -6) & 127 * 1, 16, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 16, 32, 1, ((this->timer * 2) & 63),
(this->timer * -6) & 127 * 1, 16, 32, 0, 0, 2, -6));
dList = gUnusedCandleDL;
gDPSetPrimColor(POLY_XLU_DISP++, 0xC0, 0xC0, 255, 200, 0, 0);
@@ -333,8 +333,9 @@ void EnMThunder_Draw(Actor* thisx, PlayState* play2) {
case 0:
case 1:
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0xFF - ((u8)(s32)(this->unk_1B4 * 30) & 0xFF), 0, 0x40,
0x20, 1, 0xFF - ((u8)(s32)(this->unk_1B4 * 20) & 0xFF), 0, 8, 8));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0xFF - ((u8)(s32)(this->unk_1B4 * 30) & 0xFF), 0, 0x40,
0x20, 1, 0xFF - ((u8)(s32)(this->unk_1B4 * 20) & 0xFF), 0, 8, 8, -30, 0, -20,
0));
break;
}
@@ -422,8 +423,9 @@ void EnMThunder_Draw(Actor* thisx, PlayState* play2) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (play->gameplayFrames * 5) & 0xFF, 0, 0x20, 0x20, 1,
(play->gameplayFrames * 20) & 0xFF, (play->gameplayFrames * phi_t1) & 0xFF, 8, 8));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (play->gameplayFrames * 5) & 0xFF, 0, 0x20, 0x20, 1,
(play->gameplayFrames * 20) & 0xFF, (play->gameplayFrames * phi_t1) & 0xFF, 8, 8, 5,
0, 20, phi_t1));
gSPDisplayList(POLY_XLU_DISP++, gSpinAttackChargingDL);
@@ -181,8 +181,9 @@ void EnNutsball_Draw(Actor* thisx, PlayState* play) {
if (CVarGetInteger(CVAR_ENHANCEMENT("NewDrops"), 0) != 0) {
Gfx_SetupDL_25Opa(play->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6),
32, 32, 1, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6),
32, 32, 1, 1 * (play->state.frames * 6), 1 * (play->state.frames * 6), 32, 32, 6,
6, 6, 6));
Matrix_Scale(25.0f, 25.0f, 25.0f, MTXMODE_APPLY);
Matrix_RotateX(thisx->home.rot.z * 9.58738e-05f, MTXMODE_APPLY);
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
@@ -767,9 +767,9 @@ void EnOkuta_Draw(Actor* thisx, PlayState* play) {
if (CVarGetInteger(CVAR_ENHANCEMENT("NewDrops"), 0) != 0) {
Gfx_SetupDL_25Opa(play->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 1 * (play->state.frames * 6),
1 * (play->state.frames * 6), 32, 32, 1, 1 * (play->state.frames * 6),
1 * (play->state.frames * 6), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 1 * (play->state.frames * 6),
1 * (play->state.frames * 6), 32, 32, 1, 1 * (play->state.frames * 6),
1 * (play->state.frames * 6), 32, 32, 6, 6, 6, 6));
Matrix_Scale(7.0f, 7.0f, 7.0f, MTXMODE_APPLY);
Matrix_RotateX(thisx->home.rot.z * (M_PI / 0x8000), MTXMODE_APPLY);
gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_MODELVIEW | G_MTX_LOAD);
@@ -789,9 +789,9 @@ void EnPoField_DrawFlame(EnPoField* this, PlayState* play) {
if (this->flameTimer != 0) {
OPEN_DISPS(play->state.gfxCtx);
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(
POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (play->gameplayFrames * -20) % 512, 32, 128));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (play->gameplayFrames * -20) % 512, 32,
128, 0, 0, 0, -20));
sp4C = this->flameScale * 85000.0f;
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 255, 0, sp4C);
Matrix_Translate(this->flamePosition.x, this->flamePosition.y, this->flamePosition.z, MTXMODE_NEW);
@@ -991,8 +991,8 @@ void EnPoField_DrawSoul(Actor* thisx, PlayState* play) {
} else {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0,
(play->gameplayFrames * info->unk_9) & 0x1FF, 0x20, 0x80));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0,
(play->gameplayFrames * info->unk_9) & 0x1FF, 0x20, 0x80, 0, 0, 0, info->unk_9));
gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(info->soulTexture));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, info->primColor.r, info->primColor.g, info->primColor.b,
this->lightColor.a);
@@ -1378,8 +1378,8 @@ void EnPoSisters_Draw(Actor* thisx, PlayState* play) {
gSPDisplayList(POLY_OPA_DISP++, gPoSistersTorchDL);
}
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, (play->gameplayFrames * -20) % 512, 0x20,
0x80));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, (play->gameplayFrames * -20) % 512,
0x20, 0x80, 0, 0, 0, -20));
gDPSetEnvColor(POLY_XLU_DISP++, temp_s1->r, temp_s1->g, temp_s1->b, temp_s1->a);
if (this->actionFunc == func_80ADB17C) {
if (this->unk_19A < 32) {
@@ -1187,8 +1187,9 @@ void EnPoh_DrawSoul(Actor* thisx, PlayState* play) {
} else {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0,
(this->visibilityTimer * this->info->unk_8) % 512U, 0x20, 0x80));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0,
(this->visibilityTimer * this->info->unk_8) % 512U, 0x20, 0x80, 0, 0, 0,
this->info->unk_8));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, this->info->primColor.r, this->info->primColor.g,
this->info->primColor.b, this->lightColor.a);
gDPSetEnvColor(POLY_XLU_DISP++, this->lightColor.r, this->lightColor.g, this->lightColor.b, 255);
+3 -2
View File
@@ -854,8 +854,9 @@ void EnRr_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x0C, segMtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (this->scrollTimer * 0) & 0x7F, (this->scrollTimer * 0) & 0x3F,
32, 16, 1, (this->scrollTimer * 0) & 0x3F, (this->scrollTimer * -6) & 0x7F, 32, 16));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (this->scrollTimer * 0) & 0x7F, (this->scrollTimer * 0) & 0x3F,
32, 16, 1, (this->scrollTimer * 0) & 0x3F, (this->scrollTimer * -6) & 0x7F, 32, 16, 0,
0, 0, this->stopScroll ? 0 : -6));
Matrix_Push();
Matrix_Scale((1.0f + this->bodySegs[RR_BASE].scaleMod.x) * this->bodySegs[RR_BASE].scale.x,
@@ -293,7 +293,8 @@ void EnSiofuki_Draw(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
x = gameplayFrames * 15;
y = gameplayFrames * -15;
gSPSegment(POLY_XLU_DISP++, 0x08, Gfx_TwoTexScroll(play->state.gfxCtx, 0, x, y, 64, 64, 1, x, y, 64, 64));
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, x, y, 64, 64, 1, x, y, 64, 64, 15, -15, 15, -15));
gSPDisplayList(POLY_XLU_DISP++, object_siofuki_DL_000B70);
CLOSE_DISPS(play->state.gfxCtx);
@@ -137,8 +137,8 @@ void EnStream_Draw(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
multipliedFrames = frames * 20;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, frames * 30, -multipliedFrames, 0x40, 0x40, 1, multipliedFrames,
-multipliedFrames, 0x40, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, frames * 30, -multipliedFrames, 0x40, 0x40, 1,
multipliedFrames, -multipliedFrames, 0x40, 0x40, 30, -20, 20, -20));
gSPDisplayList(POLY_XLU_DISP++, object_stream_DL_000950);
CLOSE_DISPS(play->state.gfxCtx);
}
@@ -801,7 +801,7 @@ void EnVali_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TexScroll(play->state.gfxCtx, 0, (127 - (play->gameplayFrames * 12)) % 128, 32, 32));
Gfx_TexScrollEx(play->state.gfxCtx, 0, (127 - (play->gameplayFrames * 12)) % 128, 32, 32, 0, -12));
if ((this->lightningTimer % 2) != 0) {
gSPSegment(POLY_XLU_DISP++, 0x09, D_80B28998);
@@ -853,8 +853,8 @@ void EnViewer_DrawFireEffects(EnViewer* this2, PlayState* play) {
MTXMODE_NEW);
Matrix_Scale(this->fireEffects[i].scale, this->fireEffects[i].scale, this->fireEffects[i].scale, MTXMODE_APPLY);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (10 * i - 20 * play->state.frames) % 512,
32, 128));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0,
(10 * i - 20 * play->state.frames) % 512, 32, 128, 0, 0, 0, -20));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 255, 170, 255);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 50, 00, 255);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -1279,8 +1279,8 @@ void Fishing_DrawEffects(FishingEffect* effect, PlayState* play) {
gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 40, 90, 80, effect->alpha);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, effect->timer + (i * 3), (effect->timer + (i * 3)) * 5,
32, 64, 1, 0, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, effect->timer + (i * 3), (effect->timer + (i * 3)) * 5,
32, 64, 1, 0, 0, 32, 32, 1, 5, 0, 0));
Matrix_Translate(effect->pos.x, effect->pos.y, effect->pos.z, MTXMODE_NEW);
Matrix_ReplaceRotation(&play->billboardMtxF);
@@ -1426,8 +1426,8 @@ void Fishing_DrawStreamSplash(PlayState* play) {
OPEN_DISPS(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x09,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->gameplayFrames * 1, play->gameplayFrames * 8, 32, 64, 1,
-(play->gameplayFrames * 2), 0, 16, 16));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, play->gameplayFrames * 1, play->gameplayFrames * 8, 32, 64, 1,
-(play->gameplayFrames * 2), 0, 16, 16, 1, 8, -2, 0));
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 195, 225, 235, 50);
@@ -231,8 +231,9 @@ void MagicDark_DiamondDraw(Actor* thisx, PlayState* play) {
(s32)(this->primAlpha * 0.6f) & 0xFF);
gDPSetEnvColor(POLY_XLU_DISP++, Spell_env.r, Spell_env.g, Spell_env.b, 128);
gSPDisplayList(POLY_XLU_DISP++, sDiamondMaterialDL);
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScroll(play->state.gfxCtx, 0, gameplayFrames * 2, gameplayFrames * -4,
32, 32, 1, 0, gameplayFrames * -16, 64, 32));
gSPDisplayList(POLY_XLU_DISP++,
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, gameplayFrames * 2, gameplayFrames * -4, 32, 32, 1, 0,
gameplayFrames * -16, 64, 32, 2, -4, 0, -16));
gSPDisplayList(POLY_XLU_DISP++, sDiamondModelDL);
}
@@ -249,9 +249,9 @@ void MagicFire_Draw(Actor* thisx, PlayState* play) {
gDPSetTileSize(POLY_XLU_DISP++, 1, 0, 0, 252, 252);
gSPDisplayList(POLY_XLU_DISP++, sMaterialDL);
gSPDisplayList(POLY_XLU_DISP++,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (gameplayFrames * 2) % 512,
511 - ((gameplayFrames * 5) % 512), 64, 64, 1, (gameplayFrames * 2) % 256,
255 - ((gameplayFrames * 20) % 256), 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (gameplayFrames * 2) % 512,
511 - ((gameplayFrames * 5) % 512), 64, 64, 1, (gameplayFrames * 2) % 256,
255 - ((gameplayFrames * 20) % 256), 32, 32, 2, -5, 2, -20));
gSPDisplayList(POLY_XLU_DISP++, sModelDL);
CLOSE_DISPS(play->state.gfxCtx);
@@ -150,17 +150,17 @@ s32 MagicWind_OverrideLimbDraw(PlayState* play, SkelAnimeCurve* skelCurve, s32 l
if (limbIndex == 1) {
gSPSegment(POLY_XLU_DISP++, 8,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (play->state.frames * 9) & 0xFF,
0xFF - ((play->state.frames * 0xF) & 0xFF), 0x40, 0x40, 1,
(play->state.frames * 0xF) & 0xFF, 0xFF - ((play->state.frames * 0x1E) & 0xFF),
0x40, 0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (play->state.frames * 9) & 0xFF,
0xFF - ((play->state.frames * 0xF) & 0xFF), 0x40, 0x40, 1,
(play->state.frames * 0xF) & 0xFF, 0xFF - ((play->state.frames * 0x1E) & 0xFF),
0x40, 0x40, 9, -0xF, 0xF, -0x1E));
} else if (limbIndex == 2) {
gSPSegment(POLY_XLU_DISP++, 9,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, (play->state.frames * 3) & 0xFF,
0xFF - ((play->state.frames * 5) & 0xFF), 0x40, 0x40, 1,
(play->state.frames * 6) & 0xFF, 0xFF - ((play->state.frames * 0xA) & 0xFF), 0x40,
0x40));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, (play->state.frames * 3) & 0xFF,
0xFF - ((play->state.frames * 5) & 0xFF), 0x40, 0x40, 1,
(play->state.frames * 6) & 0xFF, 0xFF - ((play->state.frames * 0xA) & 0xFF), 0x40,
0x40, 3, -5, 6, -0xA));
}
CLOSE_DISPS(play->state.gfxCtx);
@@ -162,7 +162,8 @@ void ObjDekujr_Draw(Actor* thisx, PlayState* play) {
frameCount = play->state.frames;
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, frameCount % 128, 0, 32, 32, 1, frameCount % 128, 0, 32, 32));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, frameCount % 128, 0, 32, 32, 1, frameCount % 128, 0, 32, 32, 1,
0, 1, 0));
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, object_dekujr_DL_0032D8);
@@ -200,8 +200,8 @@ void ObjIcePoly_Draw(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, play->gameplayFrames % 0x100, 0x20, 0x10, 1, 0,
(play->gameplayFrames * 2) % 0x100, 0x40, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, play->gameplayFrames % 0x100, 0x20, 0x10, 1, 0,
(play->gameplayFrames * 2) % 0x100, 0x40, 0x20, 0, 1, 0, 2));
gDPSetEnvColor(POLY_XLU_DISP++, 0, 50, 100, this->alpha);
gSPDisplayList(POLY_XLU_DISP++, gEffIceFragment3DL);
@@ -779,8 +779,8 @@ void ObjSwitch_DrawCrystal(ObjSwitch* this, PlayState* play) {
gDPSetEnvColor(POLY_OPA_DISP++, this->crystalColor.r, this->crystalColor.g, this->crystalColor.b, 128);
gSPSegment(POLY_OPA_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, this->x1TexScroll, this->y1TexScroll, 0x20, 0x20, 1,
this->x2TexScroll, this->y2TexScroll, 0x20, 0x20));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, this->x1TexScroll, this->y1TexScroll, 0x20, 0x20, 1,
this->x2TexScroll, this->y2TexScroll, 0x20, 0x20, -1, 1, 1, -1));
gSPDisplayList(POLY_OPA_DISP++, opaDLists[subType]);
CLOSE_DISPS(play->state.gfxCtx);
@@ -287,8 +287,8 @@ void ObjSyokudai_Draw(Actor* thisx, PlayState* play) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, (this->flameTexScroll * -20) & 0x1FF,
0x20, 0x80));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0,
(this->flameTexScroll * -20) & 0x1FF, 0x20, 0x80, 0, 0, 0, -20));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 255, 0, 255);
@@ -934,8 +934,9 @@ void ObjectKankyo_DrawBeams(ObjectKankyo* this2, PlayState* play2) {
gDPSetEnvColor(POLY_XLU_DISP++, sBeamEnvColors[i].r, sBeamEnvColors[i].g, sBeamEnvColors[i].b, 128);
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_LOAD);
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(play->state.gfxCtx, 0, play->state.frames * 5, play->state.frames * 10, 32,
64, 1, play->state.frames * 5, play->state.frames * 10, 32, 64));
Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, play->state.frames * 5, play->state.frames * 10,
32, 64, 1, play->state.frames * 5, play->state.frames * 10, 32, 64, 5, 10,
5, 10));
gSPDisplayList(POLY_XLU_DISP++, gDemoKekkaiDL_005FF0);
FrameInterpolation_RecordCloseChild();
}
@@ -156,8 +156,8 @@ void OceffSpot_Draw(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, sCylinderMaterialDL);
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScroll(play->state.gfxCtx, 0, scroll * 2, scroll * (-2), 32, 32, 1, 0,
scroll * (-8), 32, 32));
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, scroll * 2, scroll * (-2), 32, 32, 1, 0,
scroll * (-8), 32, 32, 2, -2, 0, -8));
gSPDisplayList(POLY_XLU_DISP++, sCylinderModelDL);
CLOSE_DISPS(play->state.gfxCtx);
@@ -138,8 +138,8 @@ void OceffStorm_Draw2(Actor* thisx, PlayState* play) {
gDPSetColorDither(POLY_XLU_DISP++, G_CD_NOISE);
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 200, 200, 150, this->primColorAlpha);
gSPDisplayList(POLY_XLU_DISP++, sMaterialDL);
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScroll(play->state.gfxCtx, 0, scroll * 8, scroll * 4, 64, 64, 1,
scroll * 4, scroll * 4, 64, 64));
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, scroll * 8, scroll * 4, 64, 64, 1,
scroll * 4, scroll * 4, 64, 64, 8, 4, 4, 4));
gSPWideTextureRectangle(POLY_XLU_DISP++, OTRGetRectDimensionFromLeftEdge(0) << 2, 0,
OTRGetRectDimensionFromRightEdge(SCREEN_WIDTH) << 2, 0x03C0, G_TX_RENDERTILE, 0, 0, 0x008C,
-0x008C);
@@ -167,8 +167,8 @@ void OceffStorm_Draw(Actor* thisx, PlayState* play) {
gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, sCylinderMaterialDL);
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScroll(play->state.gfxCtx, 0, scroll * 4, (0 - scroll) * 8, 32, 32, 1,
scroll * 8, (0 - scroll) * 12, 32, 32));
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, scroll * 4, (0 - scroll) * 8, 32, 32, 1,
scroll * 8, (0 - scroll) * 12, 32, 32, 4, -8, 8, -12));
gSPDisplayList(POLY_XLU_DISP++, sCylinderModelDL);
CLOSE_DISPS(play->state.gfxCtx);
@@ -122,8 +122,8 @@ void OceffWipe_Draw(Actor* thisx, PlayState* play) {
}
gSPDisplayList(POLY_XLU_DISP++, sMaterialDL);
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScroll(play->state.gfxCtx, 0, 0 - scroll, scroll * (-2), 32, 32, 1,
0 - scroll, scroll * (-2), 32, 32));
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, 0 - scroll, scroll * (-2), 32, 32, 1,
0 - scroll, scroll * (-2), 32, 32, -1, -2, -1, -2));
gSPDisplayList(POLY_XLU_DISP++, sFrustumDL);
CLOSE_DISPS(play->state.gfxCtx);
@@ -105,8 +105,8 @@ void OceffWipe2_Draw(Actor* thisx, PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 170, 255);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 100, 0, 128);
gSPDisplayList(POLY_XLU_DISP++, sMaterialDL);
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScroll(play->state.gfxCtx, 0, scroll * 6, scroll * (-6), 64, 64, 1,
scroll * (-6), 0, 64, 64));
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, scroll * 6, scroll * (-6), 64, 64, 1,
scroll * (-6), 0, 64, 64, 6, -6, -6, 0));
gSPDisplayList(POLY_XLU_DISP++, sFrustumDL);
CLOSE_DISPS(play->state.gfxCtx);
@@ -106,8 +106,8 @@ void OceffWipe3_Draw(Actor* thisx, PlayState* play) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 170, 255);
gDPSetEnvColor(POLY_XLU_DISP++, 100, 200, 0, 128);
gSPDisplayList(POLY_XLU_DISP++, sMaterialDL);
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScroll(play->state.gfxCtx, 0, scroll * 12, scroll * (-12), 64, 64, 1,
scroll * 8, scroll * (-8), 64, 64));
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScrollEx(play->state.gfxCtx, 0, scroll * 12, scroll * (-12), 64, 64, 1,
scroll * 8, scroll * (-8), 64, 64, 12, -12, 8, -8));
gSPDisplayList(POLY_XLU_DISP++, sFrustumDL);
CLOSE_DISPS(play->state.gfxCtx);

Some files were not shown because too many files have changed in this diff Show More