mirror of
https://github.com/ACreTeam/ac-decomp
synced 2026-07-02 18:46:03 -04:00
Implement & link m_submenu_ovl - necessary for custom submenus
This commit is contained in:
+177
-81
@@ -11,81 +11,81 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
typedef enum {
|
||||
GRAPH_DOING_ZERO = 0,
|
||||
GRAPH_DOING_CT,
|
||||
GRAPH_DOING_GAME_CT,
|
||||
GRAPH_DOING_GAME_CT_FINISHED,
|
||||
GRAPH_DOING_GAME_MAIN,
|
||||
GRAPH_DOING_GAME_TIME,
|
||||
GRAPH_DOING_GAME_TIME_FINISHED,
|
||||
GRAPH_DOING_GAME_EXEC,
|
||||
GRAPH_DOING_GAME_EXEC_FINISHED,
|
||||
GRAPH_DOING_GAME_BGM,
|
||||
GRAPH_DOING_GAME_BGM_FINISHED,
|
||||
GRAPH_DOING_GAME_MAIN_FINISHED,
|
||||
GRAPH_DOING_TASK_SET,
|
||||
GRAPH_DOING_WAIT_TASK,
|
||||
GRAPH_DOING_WAIT_TASK_FINISHED,
|
||||
GRAPH_DOING_TASK_SET_FINISHED,
|
||||
GRAPH_DOING_AUDIO,
|
||||
GRAPH_DOING_AUDIO_FINISHED,
|
||||
GRAPH_DOING_GAME_18, /* Not sure what this is, relevant code removed */
|
||||
GRAPH_DOING_GAME_DT,
|
||||
GRAPH_DOING_GAME_DT_FINISHED,
|
||||
GRAPH_DOING_DT,
|
||||
GRAPH_DOING_END
|
||||
GRAPH_DOING_ZERO = 0,
|
||||
GRAPH_DOING_CT,
|
||||
GRAPH_DOING_GAME_CT,
|
||||
GRAPH_DOING_GAME_CT_FINISHED,
|
||||
GRAPH_DOING_GAME_MAIN,
|
||||
GRAPH_DOING_GAME_TIME,
|
||||
GRAPH_DOING_GAME_TIME_FINISHED,
|
||||
GRAPH_DOING_GAME_EXEC,
|
||||
GRAPH_DOING_GAME_EXEC_FINISHED,
|
||||
GRAPH_DOING_GAME_BGM,
|
||||
GRAPH_DOING_GAME_BGM_FINISHED,
|
||||
GRAPH_DOING_GAME_MAIN_FINISHED,
|
||||
GRAPH_DOING_TASK_SET,
|
||||
GRAPH_DOING_WAIT_TASK,
|
||||
GRAPH_DOING_WAIT_TASK_FINISHED,
|
||||
GRAPH_DOING_TASK_SET_FINISHED,
|
||||
GRAPH_DOING_AUDIO,
|
||||
GRAPH_DOING_AUDIO_FINISHED,
|
||||
GRAPH_DOING_GAME_18, /* Not sure what this is, relevant code removed */
|
||||
GRAPH_DOING_GAME_DT,
|
||||
GRAPH_DOING_GAME_DT_FINISHED,
|
||||
GRAPH_DOING_DT,
|
||||
GRAPH_DOING_END
|
||||
} GRAPH_DOING_POINT;
|
||||
|
||||
#define GRAPH_MSG_BUF_COUNT 8
|
||||
|
||||
typedef struct graph_s {
|
||||
/* 0x0000 */ Gfx* Gfx_list00; /* polygon opaque */
|
||||
/* 0x0004 */ Gfx* Gfx_list01; /* polygon translucent */
|
||||
/* 0x0008 */ void* DepthBuffer;
|
||||
/* 0x000C */ Gfx* Gfx_list03; /* unused */
|
||||
/* 0x0010 */ Gfx* Gfx_list04; /* overlay */
|
||||
/* 0x0014 */ Gfx* Gfx_list07; /* font */
|
||||
/* 0x0018 */ Gfx* Gfx_list08; /* shadow */
|
||||
/* 0x001C */ Gfx* Gfx_list09; /* light */
|
||||
/* 0x0020 */ Gfx* gfxsave;
|
||||
/* 0x0024 */ u8 _unk24[32];
|
||||
/* 0x0044 */ OSMessage graphReplyMesgBuf[GRAPH_MSG_BUF_COUNT];
|
||||
/* 0x0064 */ OSMessageQueue* schedMesgQueue;
|
||||
/* 0x0068 */ OSMessageQueue graphReplyMesgQueue;
|
||||
/* 0x0088 */ u8 _unused_ossctask00p[0x68]; /* real type = OSScTask */
|
||||
/* 0x00F0 */ u8 _unused_ossctask01p[0x68]; /* real type = OSScTask */
|
||||
/* 0x0158 */ u8 _unused_ossctask02p[0x68]; /* real type = OSScTask */
|
||||
/* 0x01C0 */ Gfx* Gfx_list05; /* work */
|
||||
/* 0x01C4 */ THA_GA work_thaga;
|
||||
/* 0x01D4 */ u8 _unk1D4[0xBC]; /* Maybe related to more OSScTask stuff? */
|
||||
/* 0x0290 */ void* scheduler; /* Actually points to OSSched struct, only used in DnM? */
|
||||
/* 0x0294 */ void* vimode; /* Actually points to OSViMode struct, not used in AC. */
|
||||
/* 0x0298 */ THA_GA line_opaque_thaga;
|
||||
/* 0x02A8 */ THA_GA line_translucent_thaga;
|
||||
/* 0x02B8 */ THA_GA overlay_thaga;
|
||||
/* 0x02C8 */ THA_GA polygon_opaque_thaga;
|
||||
/* 0x02D8 */ THA_GA polygon_translucent_thaga;
|
||||
/* 0x02E8 */ THA_GA font_thaga;
|
||||
/* 0x02F8 */ THA_GA shadow_thaga;
|
||||
/* 0x0308 */ THA_GA light_thaga;
|
||||
/* 0x0318 */ THA_GA bg_opaque_thaga;
|
||||
/* 0x0328 */ THA_GA bg_translucent_thaga;
|
||||
/* 0x0338 */ int frame_counter;
|
||||
/* 0x033C */ u16* frameBuffer;
|
||||
/* 0x0340 */ u16* renderBuffer;
|
||||
/* 0x0344 */ u32 vispecial;
|
||||
/* 0x0348 */ u8 doing_point;
|
||||
/* 0x0349 */ u8 _unk349;
|
||||
/* 0x034A */ u8 need_viupdate;
|
||||
/* 0x034B */ u8 cfb_bank;
|
||||
/* 0x034C */ void (*taskEndCallback)(struct graph_s*, void*);
|
||||
/* 0x0350 */ void* taskEndData;
|
||||
/* 0x0354 */ f32 vixscale;
|
||||
/* 0x0358 */ f32 viyscale;
|
||||
/* 0x035C */ Gfx* last_dl;
|
||||
/* 0x0360 */ Gfx* Gfx_list10; /* new0 (highlight/reflections?) */
|
||||
/* 0x0364 */ Gfx* Gfx_list11; /* new1 (highlight/reflections?) */
|
||||
} GRAPH ATTRIBUTE_ALIGN(8); // one of the missing structs is likely aligned to 8 bytes.
|
||||
/* 0x0000 */ Gfx* Gfx_list00; /* polygon opaque */
|
||||
/* 0x0004 */ Gfx* Gfx_list01; /* polygon translucent */
|
||||
/* 0x0008 */ void* DepthBuffer;
|
||||
/* 0x000C */ Gfx* Gfx_list03; /* unused */
|
||||
/* 0x0010 */ Gfx* Gfx_list04; /* overlay */
|
||||
/* 0x0014 */ Gfx* Gfx_list07; /* font */
|
||||
/* 0x0018 */ Gfx* Gfx_list08; /* shadow */
|
||||
/* 0x001C */ Gfx* Gfx_list09; /* light */
|
||||
/* 0x0020 */ Gfx* gfxsave;
|
||||
/* 0x0024 */ u8 _unk24[32];
|
||||
/* 0x0044 */ OSMessage graphReplyMesgBuf[GRAPH_MSG_BUF_COUNT];
|
||||
/* 0x0064 */ OSMessageQueue* schedMesgQueue;
|
||||
/* 0x0068 */ OSMessageQueue graphReplyMesgQueue;
|
||||
/* 0x0088 */ u8 _unused_ossctask00p[0x68]; /* real type = OSScTask */
|
||||
/* 0x00F0 */ u8 _unused_ossctask01p[0x68]; /* real type = OSScTask */
|
||||
/* 0x0158 */ u8 _unused_ossctask02p[0x68]; /* real type = OSScTask */
|
||||
/* 0x01C0 */ Gfx* Gfx_list05; /* work */
|
||||
/* 0x01C4 */ THA_GA work_thaga;
|
||||
/* 0x01D4 */ u8 _unk1D4[0xBC]; /* Maybe related to more OSScTask stuff? */
|
||||
/* 0x0290 */ void* scheduler; /* Actually points to OSSched struct, only used in DnM? */
|
||||
/* 0x0294 */ void* vimode; /* Actually points to OSViMode struct, not used in AC. */
|
||||
/* 0x0298 */ THA_GA line_opaque_thaga;
|
||||
/* 0x02A8 */ THA_GA line_translucent_thaga;
|
||||
/* 0x02B8 */ THA_GA overlay_thaga;
|
||||
/* 0x02C8 */ THA_GA polygon_opaque_thaga;
|
||||
/* 0x02D8 */ THA_GA polygon_translucent_thaga;
|
||||
/* 0x02E8 */ THA_GA font_thaga;
|
||||
/* 0x02F8 */ THA_GA shadow_thaga;
|
||||
/* 0x0308 */ THA_GA light_thaga;
|
||||
/* 0x0318 */ THA_GA bg_opaque_thaga;
|
||||
/* 0x0328 */ THA_GA bg_translucent_thaga;
|
||||
/* 0x0338 */ int frame_counter;
|
||||
/* 0x033C */ u16* frameBuffer;
|
||||
/* 0x0340 */ u16* renderBuffer;
|
||||
/* 0x0344 */ u32 vispecial;
|
||||
/* 0x0348 */ u8 doing_point;
|
||||
/* 0x0349 */ u8 _unk349;
|
||||
/* 0x034A */ u8 need_viupdate;
|
||||
/* 0x034B */ u8 cfb_bank;
|
||||
/* 0x034C */ void (*taskEndCallback)(struct graph_s*, void*);
|
||||
/* 0x0350 */ void* taskEndData;
|
||||
/* 0x0354 */ f32 vixscale;
|
||||
/* 0x0358 */ f32 viyscale;
|
||||
/* 0x035C */ Gfx* last_dl;
|
||||
/* 0x0360 */ Gfx* Gfx_list10; /* new0 (highlight/reflections?) */
|
||||
/* 0x0364 */ Gfx* Gfx_list11; /* new1 (highlight/reflections?) */
|
||||
} GRAPH ATTRIBUTE_ALIGN(8); // one of the missing structs is likely aligned to 8 bytes.
|
||||
|
||||
extern void graph_proc(void* arg);
|
||||
extern void graph_ct(GRAPH* graph);
|
||||
@@ -95,16 +95,22 @@ extern void graph_dt(GRAPH* graph);
|
||||
|
||||
/* Graph display list macros for style and correctness enforcement */
|
||||
|
||||
#define OPEN_DISP(graph) \
|
||||
{ \
|
||||
GRAPH* __graph = (graph); \
|
||||
int __gfx_opened = 0; \
|
||||
while (0)
|
||||
// clang-format off
|
||||
#define OPEN_DISP(graph) \
|
||||
do {} while (0); \
|
||||
{ \
|
||||
GRAPH* __graph = (graph); \
|
||||
int __gfx_opened = 0; \
|
||||
do {} while (0)
|
||||
// clang-format on
|
||||
|
||||
#define CLOSE_DISP(graph) \
|
||||
(void)__gfx_opened; \
|
||||
} \
|
||||
while (0)
|
||||
// clang-format off
|
||||
#define CLOSE_DISP(graph) \
|
||||
do {} while (0); \
|
||||
(void)__gfx_opened; \
|
||||
} \
|
||||
do {} while (0)
|
||||
// clang-format on
|
||||
|
||||
#define NEXT_DISP(thaga) ((thaga)->thaGfx.head_p++)
|
||||
#define NOW_DISP(thaga) ((thaga)->thaGfx.head_p)
|
||||
@@ -116,7 +122,7 @@ extern void graph_dt(GRAPH* graph);
|
||||
#define NEXT_WORK_DISP NEXT_DISP(&__graph->work_thaga)
|
||||
#define NEXT_FONT_DISP NEXT_DISP(&__graph->font_thaga)
|
||||
#define NEXT_SHADOW_DISP NEXT_DISP(&__graph->shadow_thaga)
|
||||
#define NEXT_LIGHT_DISP NEXT_DISP(&__graph->light_thaga)
|
||||
#define NEXT_LIGHT_DISP NEXT_DISP(&__graph->light_thaga)
|
||||
#define NEXT_BG_OPA_DISP NEXT_DISP(&__graph->bg_opaque_thaga)
|
||||
#define NEXT_BG_XLU_DISP NEXT_DISP(&__graph->bg_translucent_thaga)
|
||||
|
||||
@@ -140,7 +146,97 @@ extern void graph_dt(GRAPH* graph);
|
||||
#define SET_BG_OPA_DISP(p) SET_DISP(&__graph->bg_opaque_thaga, p)
|
||||
#define SET_BG_XLU_DISP(p) SET_DISP(&__graph->bg_translucent_thaga, p)
|
||||
|
||||
#define GRAPH_ALLOC(graph, size) ((void*)((graph)->polygon_opaque_thaga.tha.tail_p = (char*)((int)(graph)->polygon_opaque_thaga.tha.tail_p - (int)(size))))
|
||||
// clang-format off
|
||||
#define OPEN_POLY_OPA_DISP(g) \
|
||||
do {} while (0); \
|
||||
OPEN_DISP(g); \
|
||||
{ \
|
||||
Gfx* __polyOpa = NOW_POLY_OPA_DISP; \
|
||||
s32 __poly_opa_gfx = 0; \
|
||||
do {} while (0)
|
||||
// clang-format on
|
||||
|
||||
// clang-format off
|
||||
#define CLOSE_POLY_OPA_DISP(g) \
|
||||
do {} while (0); \
|
||||
(void)__poly_opa_gfx; \
|
||||
SET_POLY_OPA_DISP(__polyOpa); \
|
||||
} \
|
||||
CLOSE_DISP(g); \
|
||||
do {} while (0)
|
||||
// clang-format on
|
||||
|
||||
#define POLY_OPA_DISP __polyOpa
|
||||
|
||||
// clang-format off
|
||||
#define OPEN_POLY_XLU_DISP(g) \
|
||||
do {} while (0); \
|
||||
OPEN_DISP(g); \
|
||||
{ \
|
||||
Gfx* __polyXlu = NOW_POLY_XLU_DISP; \
|
||||
s32 __poly_xlu_gfx = 0; \
|
||||
do {} while (0)
|
||||
// clang-format on
|
||||
|
||||
// clang-format off
|
||||
#define CLOSE_POLY_XLU_DISP(g) \
|
||||
do {} while (0); \
|
||||
(void)__poly_xlu_gfx; \
|
||||
SET_POLY_XLU_DISP(__polyXlu); \
|
||||
} \
|
||||
CLOSE_DISP(g); \
|
||||
do {} while (0)
|
||||
// clang-format on
|
||||
|
||||
#define POLY_XLU_DISP __polyXlu
|
||||
|
||||
// clang-format off
|
||||
#define OPEN_LIGHT_DISP(g) \
|
||||
do {} while (0); \
|
||||
OPEN_DISP(g); \
|
||||
{ \
|
||||
Gfx* __light = NOW_LIGHT_DISP; \
|
||||
s32 __light_gfx = 0; \
|
||||
do {} while (0)
|
||||
// clang-format on
|
||||
|
||||
// clang-format off
|
||||
#define CLOSE_LIGHT_DISP(g) \
|
||||
do {} while (0); \
|
||||
SET_LIGHT_DISP(__light); \
|
||||
(void)__light_gfx; \
|
||||
} \
|
||||
CLOSE_DISP(g); \
|
||||
do {} while (0)
|
||||
// clang-format on
|
||||
|
||||
#define LIGHT_DISP __light
|
||||
|
||||
// clang-format off
|
||||
#define OPEN_SHADOW_DISP(g) \
|
||||
do {} while (0); \
|
||||
OPEN_DISP(g); \
|
||||
{ \
|
||||
Gfx* __shadow_gfx = NOW_SHADOW_DISP; \
|
||||
s32 __shadow_opened = 0; \
|
||||
do {} while (0)
|
||||
// clang-format on
|
||||
|
||||
// clang-format off
|
||||
#define CLOSE_SHADOW_DISP(g) \
|
||||
do {} while (0); \
|
||||
(void)__shadow_opened; \
|
||||
SET_SHADOW_DISP(__shadow_gfx); \
|
||||
} \
|
||||
CLOSE_DISP(g); \
|
||||
do {} while (0)
|
||||
// clang-format on
|
||||
|
||||
#define SHADOW_DISP __shadow_gfx
|
||||
|
||||
#define GRAPH_ALLOC(graph, size) \
|
||||
((void*)((graph)->polygon_opaque_thaga.tha.tail_p = \
|
||||
(char*)((int)(graph)->polygon_opaque_thaga.tha.tail_p - (int)(size))))
|
||||
#define GRAPH_ALLOC_TYPE(graph, type, num) (GRAPH_ALLOC(graph, sizeof(type) * (num)))
|
||||
|
||||
extern u8 SoftResetEnable;
|
||||
|
||||
+20
-16
@@ -13,24 +13,28 @@ extern "C" {
|
||||
#define mAD_PAGE_NUM 3
|
||||
|
||||
struct address_ovl_s {
|
||||
u8 _00;
|
||||
u8 _01;
|
||||
u8 command;
|
||||
u8 _03;
|
||||
u8 _04;
|
||||
u8 selected_entry;
|
||||
u8 show_museum_address;
|
||||
u8 _07;
|
||||
u8 page_entry_count[mAD_PAGE_NUM];
|
||||
f32 _0C;
|
||||
f32 _10;
|
||||
f32 _14[mAD_PAGE_NUM];
|
||||
f32 _20[mAD_PAGE_NUM];
|
||||
Mail_nm_c player_mail_name[PLAYER_NUM + 1]; // last entry is the museum name
|
||||
Mail_nm_c animal_mail_name[ANIMAL_NUM_MAX];
|
||||
Gfx* display_list; // set to the beginning of the address display list data for drawing over editor etc
|
||||
u8 _00;
|
||||
u8 _01;
|
||||
u8 command;
|
||||
u8 _03;
|
||||
u8 _04;
|
||||
u8 selected_entry;
|
||||
u8 show_museum_address;
|
||||
u8 _07;
|
||||
u8 page_entry_count[mAD_PAGE_NUM];
|
||||
f32 _0C;
|
||||
f32 _10;
|
||||
f32 _14[mAD_PAGE_NUM];
|
||||
f32 _20[mAD_PAGE_NUM];
|
||||
Mail_nm_c player_mail_name[PLAYER_NUM + 1]; // last entry is the museum name
|
||||
Mail_nm_c animal_mail_name[ANIMAL_NUM_MAX];
|
||||
Gfx* display_list; // set to the beginning of the address display list data for drawing over editor etc
|
||||
};
|
||||
|
||||
extern void mAD_address_ovl_construct(Submenu* submenu);
|
||||
extern void mAD_address_ovl_destruct(Submenu* submenu);
|
||||
extern void mAD_address_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
#ifndef M_CALENDAR_OVL_H
|
||||
#define M_CALENDAR_OVL_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void mCD_calendar_ovl_construct(Submenu* submenu);
|
||||
extern void mCD_calendar_ovl_destruct(Submenu* submenu);
|
||||
extern void mCD_calendar_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,14 @@
|
||||
#ifndef M_CALENDAR_OVL_H_H
|
||||
#define M_CALENDAR_OVL_H_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,18 @@
|
||||
#ifndef M_CPEDIT_OVL_H
|
||||
#define M_CPEDIT_OVL_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void mCE_cpedit_ovl_construct(Submenu* submenu);
|
||||
extern void mCE_cpedit_ovl_destruct(Submenu* submenu);
|
||||
extern void mCE_cpedit_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,14 @@
|
||||
#ifndef M_CPEDIT_OVL_H_H
|
||||
#define M_CPEDIT_OVL_H_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,18 @@
|
||||
#ifndef M_CPMAIL_OVL_H
|
||||
#define M_CPMAIL_OVL_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void mCM_cpmail_ovl_construct(Submenu* submenu);
|
||||
extern void mCM_cpmail_ovl_destruct(Submenu* submenu);
|
||||
extern void mCM_cpmail_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,14 @@
|
||||
#ifndef M_CPMAIL_OVL_H_H
|
||||
#define M_CPMAIL_OVL_H_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -13,6 +13,12 @@ extern int mCO_top_folder(Submenu* submenu);
|
||||
extern int mCO_check_hide_flg(Submenu* submenu, int folder, int idx);
|
||||
extern void mCO_on_hide_flg(Submenu* submenu, int folder, int idx);
|
||||
extern void mCO_clear_hide_flg(Submenu* submenu);
|
||||
extern void mCO_draw_cporiginal(Submenu* submenu, GRAPH* graph, f32 pos_x, f32 pos_y, f32 scale, int idx,
|
||||
int color_flag);
|
||||
|
||||
extern void mCO_cporiginal_ovl_construct(Submenu* submenu);
|
||||
extern void mCO_cporiginal_ovl_destruct(Submenu* submenu);
|
||||
extern void mCO_cporiginal_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
#ifndef M_CPWARNING_OVL_H
|
||||
#define M_CPWARNING_OVL_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void mCW_cpwarning_ovl_construct(Submenu* submenu);
|
||||
extern void mCW_cpwarning_ovl_destruct(Submenu* submenu);
|
||||
extern void mCW_cpwarning_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,14 @@
|
||||
#ifndef M_CPWARNING_OVL_H_H
|
||||
#define M_CPWARNING_OVL_H_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -10,6 +10,10 @@ extern "C" {
|
||||
|
||||
extern void mDE_maskcat_init(MaskCat_c* mask_cat);
|
||||
|
||||
extern void mDE_design_ovl_construct(Submenu* submenu);
|
||||
extern void mDE_design_ovl_destruct(Submenu* submenu);
|
||||
extern void mDE_design_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
+33
-29
@@ -10,41 +10,45 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
enum {
|
||||
mDI_FIELD_BODY,
|
||||
mDI_FIELD_BODY,
|
||||
|
||||
mDI_FIELD_NUM
|
||||
mDI_FIELD_NUM
|
||||
};
|
||||
|
||||
struct diary_ovl_s {
|
||||
mDi_data_c* data;
|
||||
u8 field;
|
||||
u8 _05;
|
||||
s16 entry_len[mDI_FIELD_NUM];
|
||||
mDi_entry_c* current_entry;
|
||||
int _0C;
|
||||
int _10;
|
||||
int _14;
|
||||
int _18;
|
||||
s16 move_proc;
|
||||
s16 _1E;
|
||||
s16 _20;
|
||||
s16 _22;
|
||||
s16 _24;
|
||||
f32 _28;
|
||||
s16 _2C;
|
||||
s16 _2E;
|
||||
s16 _30;
|
||||
s16 _32;
|
||||
u32 trigger;
|
||||
u32 button;
|
||||
u32 last_button;
|
||||
s16 _40;
|
||||
s16 _42;
|
||||
s16 cursor_idx;
|
||||
s16 _46;
|
||||
s16 _48;
|
||||
mDi_data_c* data;
|
||||
u8 field;
|
||||
u8 _05;
|
||||
s16 entry_len[mDI_FIELD_NUM];
|
||||
mDi_entry_c* current_entry;
|
||||
int _0C;
|
||||
int _10;
|
||||
int _14;
|
||||
int _18;
|
||||
s16 move_proc;
|
||||
s16 _1E;
|
||||
s16 _20;
|
||||
s16 _22;
|
||||
s16 _24;
|
||||
f32 _28;
|
||||
s16 _2C;
|
||||
s16 _2E;
|
||||
s16 _30;
|
||||
s16 _32;
|
||||
u32 trigger;
|
||||
u32 button;
|
||||
u32 last_button;
|
||||
s16 _40;
|
||||
s16 _42;
|
||||
s16 cursor_idx;
|
||||
s16 _46;
|
||||
s16 _48;
|
||||
};
|
||||
|
||||
extern void mDI_diary_ovl_construct(Submenu* submenu);
|
||||
extern void mDI_diary_ovl_destruct(Submenu* submenu);
|
||||
extern void mDI_diary_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
#define M_ENDEDITCHK_H
|
||||
|
||||
#include "types.h"
|
||||
#include "m_editEndChk_h.h"
|
||||
#include "m_editEndChk_ovl_h.h"
|
||||
#include "m_submenu_ovl.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
@@ -11,21 +11,21 @@ extern "C" {
|
||||
|
||||
/* TODO: verify these */
|
||||
enum {
|
||||
mEE_TYPE_BOARD,
|
||||
mEE_TYPE_NOTICE,
|
||||
mEE_TYPE_MSCORE,
|
||||
mEE_TYPE_CPORIGINAL,
|
||||
mEE_TYPE_ORIGINAL_DESIGN,
|
||||
mEE_TYPE_BOARD,
|
||||
mEE_TYPE_NOTICE,
|
||||
mEE_TYPE_MSCORE,
|
||||
mEE_TYPE_CPORIGINAL,
|
||||
mEE_TYPE_ORIGINAL_DESIGN,
|
||||
|
||||
mEE_TYPE_NUM
|
||||
mEE_TYPE_NUM
|
||||
};
|
||||
|
||||
struct end_edit_chk_s {
|
||||
u8 moving_in;
|
||||
u8 selected_answer;
|
||||
u8 question_alpha_step;
|
||||
u8 question_alpha;
|
||||
f32 scale;
|
||||
u8 moving_in;
|
||||
u8 selected_answer;
|
||||
u8 question_alpha_step;
|
||||
u8 question_alpha;
|
||||
f32 scale;
|
||||
};
|
||||
|
||||
extern void mEE_editEndChk_ovl_set_proc(Submenu* submenu);
|
||||
@@ -9,6 +9,11 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
extern void mGB_copy_image(Submenu*, mActor_name_t, mActor_name_t);
|
||||
extern void mGB_draw_gba(Submenu* submenu, GRAPH* graph, f32 pos_x, f32 pos_y, f32 scale, int idx, int color_flag);
|
||||
|
||||
extern void mGB_gba_ovl_construct(Submenu* submenu);
|
||||
extern void mGB_gba_ovl_destruct(Submenu* submenu);
|
||||
extern void mGB_gba_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
#ifndef M_HANIWA_OVL_H
|
||||
#define M_HANIWA_OVL_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void mHW_haniwa_ovl_construct(Submenu* submenu);
|
||||
extern void mHW_haniwa_ovl_destruct(Submenu* submenu);
|
||||
extern void mHW_haniwa_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,14 @@
|
||||
#ifndef M_HANIWA_OVL_H_H
|
||||
#define M_HANIWA_OVL_H_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -46,6 +46,10 @@ struct inventory_ovl_s {
|
||||
u8 _3E3[0x5EC - 0x3E3];
|
||||
};
|
||||
|
||||
extern void mIV_inventory_ovl_construct(Submenu* submenu);
|
||||
extern void mIV_inventory_ovl_destruct(Submenu* submenu);
|
||||
extern void mIV_inventory_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
+12
-8
@@ -8,17 +8,21 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
enum {
|
||||
mLE_TYPE_PLAYER_NAME,
|
||||
mLE_TYPE_COUNTRY_NAME,
|
||||
mLE_TYPE_EPHRASE,
|
||||
mLE_TYPE_RESET,
|
||||
mLE_TYPE_REQUEST,
|
||||
mLE_TYPE_MYORIGINAL_NAME,
|
||||
mLE_TYPE_ISLAND_NAME,
|
||||
mLE_TYPE_PLAYER_NAME,
|
||||
mLE_TYPE_COUNTRY_NAME,
|
||||
mLE_TYPE_EPHRASE,
|
||||
mLE_TYPE_RESET,
|
||||
mLE_TYPE_REQUEST,
|
||||
mLE_TYPE_MYORIGINAL_NAME,
|
||||
mLE_TYPE_ISLAND_NAME,
|
||||
|
||||
mLE_TYPE_NUM
|
||||
mLE_TYPE_NUM
|
||||
};
|
||||
|
||||
extern void mLE_ledit_ovl_construct(Submenu* submenu);
|
||||
extern void mLE_ledit_ovl_destruct(Submenu* submenu);
|
||||
extern void mLE_ledit_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
#ifndef M_MAILBOX_OVL_H
|
||||
#define M_MAILBOX_OVL_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void mMB_mailbox_ovl_construct(Submenu* submenu);
|
||||
extern void mMB_mailbox_ovl_destruct(Submenu* submenu);
|
||||
extern void mMB_mailbox_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,14 @@
|
||||
#ifndef M_MAILBOX_OVL_H_H
|
||||
#define M_MAILBOX_OVL_H_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,18 @@
|
||||
#ifndef M_MSCORE_OVL_H
|
||||
#define M_MSCORE_OVL_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void mMS_mscore_ovl_construct(Submenu* submenu);
|
||||
extern void mMS_mscore_ovl_destruct(Submenu* submenu);
|
||||
extern void mMS_mscore_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,14 @@
|
||||
#ifndef M_MSCORE_OVL_H_H
|
||||
#define M_MSCORE_OVL_H_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -12,6 +12,11 @@ extern u8 mNW_get_image_no(Submenu* submenu, int slot_no);
|
||||
extern int mNW_check_hide_flg(Submenu* submenu, int idx);
|
||||
extern void mNW_on_hide_flg(Submenu* submenu, int idx);
|
||||
extern void mNW_clear_hide_flg(Submenu* submenu);
|
||||
extern void mNW_draw_original(Submenu* submenu, GRAPH* graph, f32 pos_x, f32 pos_y, f32 scale, int idx, int color_flag);
|
||||
|
||||
extern void mNW_needlework_ovl_construct(Submenu* submenu);
|
||||
extern void mNW_needlework_ovl_destruct(Submenu* submenu);
|
||||
extern void mNW_needlework_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
@@ -13,13 +13,17 @@ extern "C" {
|
||||
#define mPC_LINE_COUNT 2
|
||||
|
||||
struct passwordChk_ovl_s {
|
||||
int selected_line;
|
||||
u8 _04;
|
||||
u8 _05;
|
||||
u8 line0[mPC_STR_SIZE];
|
||||
u8 line1[mPC_STR_SIZE];
|
||||
int selected_line;
|
||||
u8 _04;
|
||||
u8 _05;
|
||||
u8 line0[mPC_STR_SIZE];
|
||||
u8 line1[mPC_STR_SIZE];
|
||||
};
|
||||
|
||||
extern void mPC_passwordChk_ovl_construct(Submenu* submenu);
|
||||
extern void mPC_passwordChk_ovl_destruct(Submenu* submenu);
|
||||
extern void mPC_passwordChk_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -11,19 +11,23 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
enum {
|
||||
mPM_ENTRY_TOWN,
|
||||
mPM_ENTRY_PLAYER,
|
||||
mPM_ENTRY_TOWN,
|
||||
mPM_ENTRY_PLAYER,
|
||||
|
||||
mPM_ENTRY_NUM
|
||||
mPM_ENTRY_NUM
|
||||
};
|
||||
|
||||
struct passwordMake_ovl_s {
|
||||
int selected_idx;
|
||||
u8 lengths[mPM_ENTRY_NUM];
|
||||
u8 town_name[LAND_NAME_SIZE];
|
||||
u8 player_name[PLAYER_NAME_LEN];
|
||||
int selected_idx;
|
||||
u8 lengths[mPM_ENTRY_NUM];
|
||||
u8 town_name[LAND_NAME_SIZE];
|
||||
u8 player_name[PLAYER_NAME_LEN];
|
||||
};
|
||||
|
||||
extern void mPM_passwordMake_ovl_construct(Submenu* submenu);
|
||||
extern void mPM_passwordMake_ovl_destruct(Submenu* submenu);
|
||||
extern void mPM_passwordMake_ovl_set_proc(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
+28
-4
@@ -18,7 +18,7 @@
|
||||
#include "m_board_ovl_h.h"
|
||||
#include "m_diary_ovl_h.h"
|
||||
#include "m_address_ovl_h.h"
|
||||
#include "m_editEndChk_h.h"
|
||||
#include "m_editEndChk_ovl_h.h"
|
||||
#include "m_haniwaPortrait_ovl_h.h"
|
||||
#include "m_timeIn_ovl_h.h"
|
||||
#include "m_repay_ovl_h.h"
|
||||
@@ -43,6 +43,28 @@ enum {
|
||||
mSM_OVL_PROC_NUM
|
||||
};
|
||||
|
||||
#define mSM_OVL_FLAG_NONE (0)
|
||||
#define mSM_OVL_FLAG_0 (1 << 0)
|
||||
#define mSM_OVL_FLAG_USE_ITEM (1 << 1)
|
||||
#define mSM_OVL_FLAG_USE_TAG (1 << 2)
|
||||
#define mSM_OVL_FLAG_USE_HAND (1 << 3)
|
||||
#define mSM_OVL_FLAG_USE_HANIWA_PORTRAIT (1 << 4)
|
||||
|
||||
typedef void (*mSM_OVL_CT_PROC)(Submenu*);
|
||||
typedef void (*mSM_OVL_DT_PROC)(Submenu*);
|
||||
typedef void (*mSM_OVL_SET_PROC)(Submenu*);
|
||||
|
||||
typedef struct submenu_ovl_dlftbl_s {
|
||||
int _00;
|
||||
int _04;
|
||||
u8* seg_start;
|
||||
u8* seg_end;
|
||||
mSM_OVL_CT_PROC ct_proc;
|
||||
mSM_OVL_DT_PROC dt_proc;
|
||||
mSM_OVL_SET_PROC set_proc;
|
||||
int in_ram_flag;
|
||||
} mSM_Ovl_dlftbl_c;
|
||||
|
||||
// TODO: fill this out
|
||||
typedef struct submenu_segment_s {
|
||||
int _00;
|
||||
@@ -50,7 +72,9 @@ typedef struct submenu_segment_s {
|
||||
s16 _06;
|
||||
s16 _08;
|
||||
s16 _0A;
|
||||
u8 _0C[0x54 - 0x0C];
|
||||
u8 _0C[0x30 - 0x0C];
|
||||
int dlftbl_loaded_num;
|
||||
mSM_Ovl_dlftbl_c* dlftbl_loaded_tbl[8];
|
||||
} mSM_Segment_c;
|
||||
|
||||
typedef struct submenu_menu_info_s {
|
||||
@@ -71,7 +95,7 @@ typedef struct submenu_menu_info_s {
|
||||
|
||||
int next_proc_status;
|
||||
s16 move_drt;
|
||||
u16 _36;
|
||||
s16 move_flag;
|
||||
|
||||
int data0;
|
||||
int data1;
|
||||
@@ -181,7 +205,7 @@ struct submenu_overlay_s {
|
||||
|
||||
extern void mSM_menu_ovl_init(Submenu* submenu);
|
||||
extern void mSM_draw_original(Submenu* submenu, GRAPH* graph, f32 pos_x, f32 pos_y, f32 scale, mActor_name_t item,
|
||||
int shadow_flag);
|
||||
int color_flag);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
@@ -166,6 +166,9 @@ struct tag_ovl_s {
|
||||
extern int mTG_mark_main(Submenu*, mSM_MenuInfo_c*, int, int);
|
||||
extern int mTG_mark_mainX(Submenu*, mSM_MenuInfo_c*, int, int, int, int);
|
||||
|
||||
extern void mTG_tag_ovl_construct(Submenu* submenu);
|
||||
extern void mTG_tag_ovl_destruct(Submenu* submenu);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user