summaryrefslogtreecommitdiff
path: root/soh/src/code/code_800ACE70.c
diff options
context:
space:
mode:
authorM4xw <m4x@m4xw.net>2022-03-22 02:51:23 +0100
committerM4xw <m4x@m4xw.net>2022-03-22 02:51:23 +0100
commit39cc86c2608e2f75ace33fc7f43bc4f2ad743f1a (patch)
tree0d3fd9e995d7484eaaeb158ac808bd6a39121189 /soh/src/code/code_800ACE70.c
parent0bb0e7b53bd80bdc7f78e08c441691737e039b2b (diff)
git subrepo clone https://github.com/HarbourMasters/soh.git
subrepo: subdir: "soh" merged: "ba904bbd0" upstream: origin: "https://github.com/HarbourMasters/soh.git" branch: "master" commit: "ba904bbd0" git-subrepo: version: "0.4.1" origin: "???" commit: "???"
Diffstat (limited to 'soh/src/code/code_800ACE70.c')
-rw-r--r--soh/src/code/code_800ACE70.c97
1 files changed, 97 insertions, 0 deletions
diff --git a/soh/src/code/code_800ACE70.c b/soh/src/code/code_800ACE70.c
new file mode 100644
index 000000000..e22162777
--- /dev/null
+++ b/soh/src/code/code_800ACE70.c
@@ -0,0 +1,97 @@
+#include "global.h"
+
+// Note : This file is related to z_vismono, the original name was probably z_vis<something before "mono"
+// alphabetically>
+
+Gfx D_8012AC00[] = {
+ gsDPSetOtherMode(G_AD_PATTERN | G_CD_MAGICSQ | G_CK_NONE | G_TC_CONV | G_TF_POINT | G_TT_NONE | G_TL_TILE |
+ G_TD_CLAMP | G_TP_NONE | G_CYC_1CYCLE | G_PM_NPRIMITIVE,
+ G_AC_NONE | G_ZS_PRIM | G_RM_VISCVG | G_RM_VISCVG2),
+ gsDPFillRectangle(0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1),
+ gsDPPipeSync(),
+ gsDPSetBlendColor(0, 0, 0, 8),
+ gsSPEndDisplayList(),
+};
+
+Gfx D_8012AC28[] = {
+ gsDPSetOtherMode(G_AD_PATTERN | G_CD_MAGICSQ | G_CK_NONE | G_TC_CONV | G_TF_POINT | G_TT_NONE | G_TL_TILE |
+ G_TD_CLAMP | G_TP_NONE | G_CYC_1CYCLE | G_PM_NPRIMITIVE,
+ G_AC_NONE | G_ZS_PRIM | IM_RD | CVG_DST_CLAMP | ZMODE_OPA | FORCE_BL |
+ GBL_c1(G_BL_CLR_FOG, G_BL_A_FOG, G_BL_CLR_MEM, G_BL_A_MEM) |
+ GBL_c2(G_BL_CLR_FOG, G_BL_A_FOG, G_BL_CLR_MEM, G_BL_A_MEM)),
+ gsDPFillRectangle(0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1),
+ gsSPEndDisplayList(),
+};
+
+Gfx D_8012AC40[] = {
+ gsDPSetOtherMode(G_AD_PATTERN | G_CD_MAGICSQ | G_CK_NONE | G_TC_CONV | G_TF_POINT | G_TT_NONE | G_TL_TILE |
+ G_TD_CLAMP | G_TP_NONE | G_CYC_1CYCLE | G_PM_NPRIMITIVE,
+ G_AC_NONE | G_ZS_PRIM | IM_RD | CVG_DST_CLAMP | ZMODE_OPA | FORCE_BL |
+ GBL_c1(G_BL_CLR_IN, G_BL_0, G_BL_CLR_MEM, G_BL_A_MEM) |
+ GBL_c2(G_BL_CLR_IN, G_BL_0, G_BL_CLR_MEM, G_BL_A_MEM)),
+
+ gsDPFillRectangle(0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1),
+ gsSPEndDisplayList(),
+};
+
+Gfx D_8012AC58[] = {
+ gsDPSetCombineMode(G_CC_PRIMITIVE, G_CC_PRIMITIVE),
+ gsDPSetOtherMode(G_AD_NOTPATTERN | G_CD_DISABLE | G_CK_NONE | G_TC_CONV | G_TF_POINT | G_TT_NONE | G_TL_TILE |
+ G_TD_CLAMP | G_TP_NONE | G_CYC_1CYCLE | G_PM_NPRIMITIVE,
+ G_AC_NONE | G_ZS_PRIM | G_RM_CLD_SURF | G_RM_CLD_SURF2),
+ gsDPFillRectangle(0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1),
+ gsDPSetOtherMode(G_AD_PATTERN | G_CD_MAGICSQ | G_CK_NONE | G_TC_CONV | G_TF_POINT | G_TT_NONE | G_TL_TILE |
+ G_TD_CLAMP | G_TP_NONE | G_CYC_1CYCLE | G_PM_NPRIMITIVE,
+ G_AC_NONE | G_ZS_PRIM | IM_RD | CVG_DST_CLAMP | ZMODE_OPA | FORCE_BL |
+ GBL_c1(G_BL_CLR_IN, G_BL_0, G_BL_CLR_MEM, G_BL_A_MEM) |
+ GBL_c2(G_BL_CLR_IN, G_BL_0, G_BL_CLR_MEM, G_BL_A_MEM)),
+ gsDPFillRectangle(0, 0, SCREEN_WIDTH - 1, SCREEN_HEIGHT - 1),
+ gsSPEndDisplayList(),
+};
+
+// Init
+void func_800ACE70(struct_801664F0* this) {
+ this->type = 0;
+ this->setScissor = false;
+ this->color.r = 255;
+ this->color.g = 255;
+ this->color.b = 255;
+ this->color.a = 255;
+}
+
+// Destroy
+void func_800ACE90(struct_801664F0* this) {
+}
+
+// Draw
+void func_800ACE98(struct_801664F0* this, Gfx** gfxp) {
+ Gfx* gfx = *gfxp;
+
+ gDPPipeSync(gfx++);
+ gDPSetPrimDepth(gfx++, -1, -1);
+
+ if (this->setScissor == true) {
+ gDPSetScissor(gfx++, G_SC_NON_INTERLACE, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT);
+ }
+
+ switch (this->type) {
+ case 1:
+ gSPDisplayList(gfx++, D_8012AC40);
+ break;
+ case 2:
+ gDPSetColor(gfx++, G_SETPRIMCOLOR, this->color.rgba);
+ gSPDisplayList(gfx++, D_8012AC58);
+ break;
+ case 3:
+ gDPSetColor(gfx++, G_SETBLENDCOLOR, this->color.rgba);
+ gSPDisplayList(gfx++, D_8012AC00);
+ break;
+ case 4:
+ gDPSetColor(gfx++, G_SETFOGCOLOR, this->color.rgba);
+ gSPDisplayList(gfx++, D_8012AC28);
+ break;
+ }
+
+ gDPPipeSync(gfx++);
+ *gfxp = gfx;
+}