f_pc_manager drawDvdCondition 90%

This commit is contained in:
Jasper St. Pierre
2023-09-23 13:51:55 -07:00
parent f0737907d5
commit 3416c1966e
3 changed files with 71 additions and 28 deletions
+21 -21
View File
@@ -40,28 +40,28 @@ public:
/* 0x1 */ UNK_METHOD_1 = 1
};
/* 80272040 */ void ctor_subroutine(const _GXRenderModeObj*, bool enableAlpha);
/* 802720F8 */ JFWDisplay(const _GXRenderModeObj*, JKRHeap*, JUTXfb::EXfbNumber, bool);
/* 802721DC */ static JFWDisplay* createManager(JKRHeap*, JUTXfb::EXfbNumber, bool);
/* 802722B8 */ void prepareCopyDisp();
/* 802723AC */ void drawendXfb_single();
/* 802723F4 */ void exchangeXfb_double();
/* 802724FC */ void exchangeXfb_triple();
/* 80272574 */ void copyXfb_triple();
/* 802725F8 */ void preGX();
/* 8027268C */ void endGX();
/* 80272C60 */ void waitBlanking(int);
/* 80272E10 */ void threadSleep(s64);
/* 80272EB8 */ void clearEfb_init();
/* 80272F9C */ void clearEfb(int param_0, int param_1, int param_2, int param_3, GXColor color);
/* 80272F2C */ void clearEfb();
/* 80272F58 */ void clearEfb(_GXColor color);
/* 8027331C */ void calcCombinationRatio();
void ctor_subroutine(const _GXRenderModeObj*, bool enableAlpha);
JFWDisplay(const _GXRenderModeObj*, JKRHeap*, JUTXfb::EXfbNumber, bool);
static JFWDisplay* createManager(JKRHeap*, JUTXfb::EXfbNumber, bool);
void prepareCopyDisp();
void drawendXfb_single();
void exchangeXfb_double();
void exchangeXfb_triple();
void copyXfb_triple();
void preGX();
void endGX();
void waitBlanking(int);
void threadSleep(s64);
void clearEfb_init();
void clearEfb(int param_0, int param_1, int param_2, int param_3, GXColor color);
void clearEfb();
void clearEfb(_GXColor color);
void calcCombinationRatio();
/* 80272798 */ virtual void beginRender();
/* 80272A04 */ virtual void endRender();
/* 80272AB0 */ virtual void endFrame();
/* 80272160 */ virtual ~JFWDisplay();
virtual void beginRender();
virtual void endRender();
virtual void endFrame();
virtual ~JFWDisplay();
static JFWDisplay* getManager() { return sManager; }
+13 -4
View File
@@ -202,6 +202,11 @@ public:
void clearPlayerStatus(int param_0, int i, u32 flag) { mPlayerStatus[param_0][i] &= ~flag; }
bool checkPlayerStatus(int param_0, int i, u32 flag) { return flag & mPlayerStatus[param_0][i]; }
void setCurrentGrafPort(J2DOrthoGraph* i_graf) { mCurrentGrafPort = i_graf; }
void setCurrentWindow(dDlst_window_c* i_window) { mCurrentWindow = i_window; }
void setCurrentView(view_class* i_view) { mCurrentView = i_view; }
void setCurrentViewport(view_port_class* i_viewport) { mCurrentViewport = i_viewport; }
/* 0x0000 */ dBgS mBgS;
/* 0x1404 */ dCcS mCcS;
/* 0x3DF8 */ dADM mADM;
@@ -357,10 +362,10 @@ public:
/* 0x4A28 */ u32 mPlayerStatus[2][2];
/* 0x4A38 */ u8 field_0x4A38[0x4A40 - 0x4A38];
/* 0x4A40 */ __d_timer_info_c mTimerInfo;
/* 0x4A54 */ dDlst_window_c* field_0x4a54;
/* 0x4A58 */ camera_class* field_0x4a58;
/* 0x4A5C */ dDlst_window_c* field_0x4a5c;
/* 0x4A60 */ J2DOrthoGraph* mp2DOrthoGraph;
/* 0x4A54 */ dDlst_window_c* mCurrentWindow;
/* 0x4A58 */ view_class* mCurrentView;
/* 0x4A5C */ view_port_class* mCurrentViewport;
/* 0x4A60 */ J2DOrthoGraph* mCurrentGrafPort;
/* 0x4A64 */ u8 mShipId;
/* 0x4A65 */ u8 mShipRoomId;
/* 0x4A66 */ u8 mIkadaShipBeforeRoomId;
@@ -1085,6 +1090,10 @@ inline bool dComIfGp_checkPlayerStatus1(int param_0, u32 flag) {
return g_dComIfG_gameInfo.play.checkPlayerStatus(param_0, 1, flag);
}
inline void dComIfGp_setCurrentGrafPort(J2DOrthoGraph* i_graf) {
g_dComIfG_gameInfo.play.setCurrentGrafPort(i_graf);
}
/**
* === EVENT ===*/
+37 -3
View File
@@ -12,11 +12,16 @@
#include "f_pc/f_pc_line.h"
#include "f_pc/f_pc_pause.h"
#include "f_pc/f_pc_priority.h"
#include "dolphin/dvd/DVD.h"
#include "d/d_com_inf_game.h"
#include "m_Do/m_Do_graphic.h"
#include "m_Do/m_Do_Reset.h"
#include "SSystem/SComponent/c_lib.h"
#include "SSystem/SComponent/c_API_graphic.h"
#include "JSystem/J2DGraph/J2DOrthoGraph.h"
#include "JSystem/J3DGraphBase/J3DSys.h"
#include "JSystem/JUtility/JUTAssert.h"
#include "dolphin/dvd/DVD.h"
#include "dolphin/gx/GX.h"
/* 8003E318-8003E338 .text fpcM_Draw__FPv */
void fpcM_Draw(void* i_proc) {
@@ -44,13 +49,42 @@ BOOL fpcM_IsCreating(unsigned int pID) {
}
/* 8003E3D0-8003E9F0 .text messageSet__FUl */
void messageSet(unsigned long) {
void messageSet(unsigned long status) {
/* Nonmatching */
}
/* 8003E9F0-8003EBD4 .text drawDvdCondition__Fl */
void drawDvdCondition(long status) {
/* Nonmatching */
JFWDisplay::getManager()->setFader(NULL);
GXColor backColor = mDoGph_gInf_c::getBackColor();
JFWDisplay::getManager()->setClearColor(backColor);
JFWDisplay::getManager()->beginRender();
GXSetAlphaUpdate(GX_FALSE);
j3dSys.drawInit();
J2DOrthoGraph draw2D(0.0f, 0.0f, 640.0f, 480.0f, -1.0f, 1.0);
draw2D.setOrtho(-9.0f, -21.0f, 650.0f, 503.0f, -1.0f, 1.0f);
draw2D.setPort();
dComIfGp_setCurrentGrafPort(&draw2D);
if (status == 4) {
messageSet(2);
} else if (status == 5) {
messageSet(1);
} else if (status == 6) {
messageSet(3);
} else if (status == 12) {
messageSet(4);
} else if (status == 1) {
messageSet(0);
} else if (status == -1) {
messageSet(5);
// JAInter::StreamLib::stop();
} else {
JUT_WARN(0x1e1, "Dvd Error !! <%d>\n", status);
}
JFWDisplay::getManager()->endRender();
}
/* 8003EBD4-8003EC84 .text checkDvdCondition__Fv */