From a6072ae293b0c0c3577b280274a2fd755033ab9f Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Tue, 16 Jan 2018 18:59:06 +0100 Subject: decompile option menu --- include/option_menu.h | 6 ++++++ include/strings.h | 17 +++++++++++++++++ include/text_window.h | 2 +- include/unknown_task.h | 2 +- 4 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 include/option_menu.h (limited to 'include') diff --git a/include/option_menu.h b/include/option_menu.h new file mode 100644 index 000000000..b23a73c4c --- /dev/null +++ b/include/option_menu.h @@ -0,0 +1,6 @@ +#ifndef GUARD_OPTION_MENU_H +#define GUARD_OPTION_MENU_H + +void CB2_InitOptionMenu(void); + +#endif // GUARD_OPTION_MENU_H diff --git a/include/strings.h b/include/strings.h index a382191a0..5a26881a3 100644 --- a/include/strings.h +++ b/include/strings.h @@ -170,4 +170,21 @@ extern const u8 gText_Peak[]; extern const u8 gText_SafariBallStock[]; extern const u8 gText_BattlePyramidFloor[]; +// option menu texts +extern const u8 gText_TextSpeedSlow[]; +extern const u8 gText_TextSpeedMid[]; +extern const u8 gText_TextSpeedFast[]; +extern const u8 gText_BattleSceneOn[]; +extern const u8 gText_BattleSceneOff[]; +extern const u8 gText_BattleStyleShift[]; +extern const u8 gText_BattleStyleSet[]; +extern const u8 gText_SoundMono[]; +extern const u8 gText_SoundStereo[]; +extern const u8 gText_FrameTypeNumber[]; +extern const u8 gText_FrameType[]; +extern const u8 gText_ButtonTypeNormal[]; +extern const u8 gText_ButtonTypeLR[]; +extern const u8 gText_ButtonTypeLEqualsA[]; +extern const u8 gText_Option[]; + #endif //GUARD_STRINGS_H diff --git a/include/text_window.h b/include/text_window.h index 0af007397..f9a458cc3 100644 --- a/include/text_window.h +++ b/include/text_window.h @@ -7,7 +7,7 @@ struct TilesPal u16 *pal; }; -const struct TilesPal* sub_8098758(u8 id); +const struct TilesPal* GetWindowFrameTilesPal(u8 id); void copy_textbox_border_tile_patterns_to_vram(u8 windowId, u16 destOffset, u8 palOffset); void sub_809882C(u8 windowId, u16 destOffset, u8 palOffset); void sub_80987D4(u8 windowId, u8 frameId, u16 destOffset, u8 palOffset); diff --git a/include/unknown_task.h b/include/unknown_task.h index 9c6968c30..906fed3e0 100644 --- a/include/unknown_task.h +++ b/include/unknown_task.h @@ -15,7 +15,7 @@ extern struct UnknownTaskStruct gUnknown_0831AC70; // Exported RAM declarations // Exported ROM declarations -void remove_some_task(void); +void ScanlineEffect_Stop(void); void sub_80BA038(struct UnknownTaskStruct arg0); void sub_80BA0A8(void); -- cgit v1.2.3 From 4dd06dbcd327e2af38912e09d31d5c3e00bc93ba Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Tue, 16 Jan 2018 19:39:35 +0100 Subject: optiom menu move data to C --- include/strings.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'include') diff --git a/include/strings.h b/include/strings.h index 5a26881a3..7527e56fb 100644 --- a/include/strings.h +++ b/include/strings.h @@ -186,5 +186,13 @@ extern const u8 gText_ButtonTypeNormal[]; extern const u8 gText_ButtonTypeLR[]; extern const u8 gText_ButtonTypeLEqualsA[]; extern const u8 gText_Option[]; +extern const u8 gText_OptionMenu[]; +extern const u8 gText_TextSpeed[]; +extern const u8 gText_BattleScene[]; +extern const u8 gText_BattleStyle[]; +extern const u8 gText_Sound[]; +extern const u8 gText_Frame[]; +extern const u8 gText_OptionMenuCancel[]; +extern const u8 gText_ButtonMode[]; #endif //GUARD_STRINGS_H -- cgit v1.2.3 From e0fbd5daad0646c77d1f587d2763bc707df5d417 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Sun, 21 Jan 2018 13:32:11 +0100 Subject: text window cleanup --- include/graphics.h | 4 ++++ include/text_window.h | 13 +++++++++---- 2 files changed, 13 insertions(+), 4 deletions(-) (limited to 'include') diff --git a/include/graphics.h b/include/graphics.h index 85e31aec9..5917e9d2a 100644 --- a/include/graphics.h +++ b/include/graphics.h @@ -1,6 +1,10 @@ #ifndef GUARD_GRAPHICS_H #define GUARD_GRAPHICS_H +// overworld +extern const u32 gMessageBox_Gfx[]; +extern const u16 gMessageBox_Pal[]; + // interface pokeballs extern const u8 gInterfaceGfx_PokeBall[]; extern const u8 gInterfacePal_PokeBall[]; diff --git a/include/text_window.h b/include/text_window.h index f9a458cc3..e6a753fcb 100644 --- a/include/text_window.h +++ b/include/text_window.h @@ -1,12 +1,17 @@ #ifndef GUARD_TEXT_WINDOW_H #define GUARD_TEXT_WINDOW_H +#define WINDOW_FRAMES_COUNT 20 + struct TilesPal { - u32 *tiles; - u16 *pal; + const u32 *tiles; + const u16 *pal; }; +extern const u32 gTextWindowFrame1_Gfx[]; +extern const u16 gTextWindowFrame1_Pal[]; + const struct TilesPal* GetWindowFrameTilesPal(u8 id); void copy_textbox_border_tile_patterns_to_vram(u8 windowId, u16 destOffset, u8 palOffset); void sub_809882C(u8 windowId, u16 destOffset, u8 palOffset); @@ -15,8 +20,8 @@ void box_border_load_tiles_and_pal(u8 windowId, u16 destOffset, u8 palOffset); void sub_8098858(u8 windowId, u16 tileNum, u8 palNum); void sub_80989E0(u8 windowId, u16 tileNum, u8 palNum); void rbox_fill_rectangle(u8 windowId); -const u16* stdpal_get(u8 id); -const u16* GetOverworldTextboxPalettePtr(void); +const u16 *stdpal_get(u8 id); +const u16 *GetOverworldTextboxPalettePtr(void); void sub_8098C6C(u8 bg, u16 destOffset, u8 palOffset); #endif // GUARD_TEXT_WINDOW_H -- cgit v1.2.3