mirror of
https://github.com/FireEmblemUniverse/fireemblem8u.git
synced 2024-11-23 05:10:00 +00:00
Format, cleanup, and renames for player and prep phase
This commit is contained in:
parent
f70ff4391d
commit
a216e4e197
@ -76,8 +76,8 @@ gGfx_YellowTextBox4: @ 0x08A02B3C
|
||||
gGfx_YellowTextBox5: @ 0x08A02BAC
|
||||
.incbin "baserom.gba", 0xA02BAC, 0x88
|
||||
|
||||
.global gUnknown_08A02C34
|
||||
gUnknown_08A02C34: @ 0x08A02C34
|
||||
.global Img_LimitViewSquares
|
||||
Img_LimitViewSquares: @ 0x08A02C34
|
||||
.incbin "baserom.gba", 0xA02C34, 0x280
|
||||
|
||||
.global gUnknown_08A02EB4
|
||||
|
@ -1,7 +1,7 @@
|
||||
.section .data
|
||||
|
||||
.global gUnknown_08A199C8
|
||||
gUnknown_08A199C8: @ 0x08A199C8
|
||||
.global Img_PrepHelpButtonSprites
|
||||
Img_PrepHelpButtonSprites: @ 0x08A199C8
|
||||
.incbin "baserom.gba", 0xA199C8, 0x244
|
||||
|
||||
.global Img_MenuScrollBar
|
||||
|
@ -1,54 +1,73 @@
|
||||
#ifndef GUARD_PLAYERPHASE_H
|
||||
#define GUARD_PLAYERPHASE_H
|
||||
|
||||
// ??? PlayerPhase_Suspend(???);
|
||||
struct MoveLimitViewProc
|
||||
{
|
||||
/* 00 */ PROC_HEADER;
|
||||
|
||||
/* 29 */ STRUCT_PAD(0x29, 0x4A);
|
||||
/* 4A */ s16 flags;
|
||||
/* 4C */ s16 unk_4C;
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
PLAYER_SELECT_NOUNIT = 0,
|
||||
PLAYER_SELECT_TURNENDED = 1,
|
||||
PLAYER_SELECT_CONTROL = 2,
|
||||
PLAYER_SELECT_NOCONTROL = 3,
|
||||
PLAYER_SELECT_4 = 4,
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
LIMITVIEW_BLUE = (1 << 0),
|
||||
LIMITVIEW_RED = (1 << 1),
|
||||
LIMITVIEW_GREEN = (1 << 2),
|
||||
// (1 << 3)
|
||||
LIMITVIEW_UNK = (1 << 4),
|
||||
};
|
||||
|
||||
void PlayerPhase_Suspend(void);
|
||||
void HandlePlayerCursorMovement(void);
|
||||
int CanShowUnitStatScreen(struct Unit* unit);
|
||||
// ??? PlayerPhase_MainIdle(???);
|
||||
void DisplayUnitEffectRange(struct Unit* unit);
|
||||
// ??? PlayerPhase_InitUnitMovementSelect(???);
|
||||
// bool CanShowUnitStatScreen(struct Unit * unit);
|
||||
void PlayerPhase_MainIdle(ProcPtr proc);
|
||||
void DisplayUnitEffectRange(struct Unit * unit);
|
||||
void PlayerPhase_InitUnitMovementSelect(void);
|
||||
void DisplayActiveUnitEffectRange(ProcPtr proc);
|
||||
// ??? PlayerPhase_DisplayDangerZone(???);
|
||||
// ??? PlayerPhase_RangeDisplayIdle(???);
|
||||
// ??? PlayerPhase_CancelAction(???);
|
||||
// ??? PlayerPhase_BackToMove(???);
|
||||
// ??? PlayerPhase_PrepareAction(???);
|
||||
// ??? TryMakeCantoUnit(???);
|
||||
s8 RunPotentialWaitEvents(void);
|
||||
// ??? EnsureCameraOntoActiveUnitPosition(???);
|
||||
// ??? PlayerPhase_FinishAction(???);
|
||||
// ??? sub_801D404(???);
|
||||
// ??? sub_801D434(???);
|
||||
// ??? PlayerPhase_ApplyUnitMovement(???);
|
||||
int GetUnitSelectionValueThing(struct Unit* unit);
|
||||
// ??? CanMoveActiveUnitTo(???);
|
||||
// ??? PlayerPhase_DisplayUnitMovement(???);
|
||||
// ??? PlayerPhase_WaitForUnitMovement(???);
|
||||
// ??? PlayerPhase_ResumeRangeDisplay(???);
|
||||
// ??? PlayerPhase_ReReadGameSaveGfx(???);
|
||||
// ??? MakeMoveunitForActiveUnit(???);
|
||||
void ClearActiveUnit(struct Unit *);
|
||||
void PlayerPhase_DisplayDangerZone(void);
|
||||
void PlayerPhase_RangeDisplayIdle(ProcPtr proc);
|
||||
void PlayerPhase_CancelAction(ProcPtr proc);
|
||||
void PlayerPhase_BackToMove(ProcPtr proc);
|
||||
s8 PlayerPhase_PrepareAction(ProcPtr proc);
|
||||
bool TryMakeCantoUnit(ProcPtr proc);
|
||||
bool RunPotentialWaitEvents(void);
|
||||
bool EnsureCameraOntoActiveUnitPosition(ProcPtr proc);
|
||||
void PlayerPhase_FinishAction(ProcPtr proc);
|
||||
void sub_801D404(void);
|
||||
void sub_801D434(ProcPtr proc);
|
||||
void PlayerPhase_ApplyUnitMovement(ProcPtr proc);
|
||||
int GetPlayerSelectKind(struct Unit * unit);
|
||||
bool CanMoveActiveUnitTo(int x, int y);
|
||||
void PlayerPhase_DisplayUnitMovement(void);
|
||||
void PlayerPhase_WaitForUnitMovement(ProcPtr proc);
|
||||
void PlayerPhase_ResumeRangeDisplay(ProcPtr proc);
|
||||
void PlayerPhase_ReReadGameSaveGfx(void);
|
||||
void MakeMoveunitForActiveUnit(void);
|
||||
void ClearActiveUnit(struct Unit * unit);
|
||||
void PlayPhaseForcePressAButtonInRangeDisp(void);
|
||||
void PlayerPhase_RangeDisplayIdle_ForceAPress(ProcPtr proc);
|
||||
void PlayPhaseForceActiveUnitCanto(void);
|
||||
// ??? MoveLimitViewChange_OnInit(???);
|
||||
// ??? MoveLimitViewChange_OnLoop(???);
|
||||
// ??? MoveLimitView_OnInit(???);
|
||||
// ??? MoveLimitView_OnLoop(???);
|
||||
// ??? MoveLimitView_OnEnd(???);
|
||||
void MoveLimitViewChange_OnInit(struct MoveLimitViewProc * proc);
|
||||
void MoveLimitViewChange_OnLoop(struct MoveLimitViewProc * proc);
|
||||
void MoveLimitView_OnInit(ProcPtr proc);
|
||||
void MoveLimitView_OnLoop(struct MoveLimitViewProc * proc);
|
||||
void MoveLimitView_OnEnd(struct MoveLimitViewProc * proc);
|
||||
void DisplayMoveRangeGraphics(int flags);
|
||||
void HideMoveRangeGraphics(void);
|
||||
// ??? TrySetCursorOn(???);
|
||||
bool TrySetCursorOn(int unitId);
|
||||
void TrySwitchViewedUnit(int x, int y);
|
||||
// ??? PlayerPhase_HandleAutoEnd(???);
|
||||
|
||||
struct MoveLimitViewProc {
|
||||
PROC_HEADER;
|
||||
|
||||
/* 29 */ u8 pad[0x4A-0x29];
|
||||
/* 4A */ s16 unk_4A;
|
||||
/* 4C */ s16 unk_4C;
|
||||
};
|
||||
void PlayerPhase_HandleAutoEnd(ProcPtr proc);
|
||||
|
||||
extern const struct MenuDef gMapMenuDef;
|
||||
extern const struct MenuDef gUnitActionMenuDef;
|
||||
@ -59,39 +78,7 @@ extern u16 gUnknown_08A02FF4[];
|
||||
|
||||
extern u8 gUnknown_08A02EB4[];
|
||||
|
||||
void TrySwitchViewedUnit(int, int);
|
||||
int GetUnitSelectionValueThing(struct Unit* unit);
|
||||
void DisplayMoveRangeGraphics(int config);
|
||||
s8 CanMoveActiveUnitTo(int, int);
|
||||
|
||||
// code.s
|
||||
void PidStatsAddActAmt(u8);
|
||||
|
||||
extern struct ProcCmd gProcScr_0859ACE8[];
|
||||
|
||||
void PlayerPhase_Suspend(void);
|
||||
void PlayerPhase_MainIdle(ProcPtr proc);
|
||||
void PlayerPhase_InitUnitMovementSelect(void);
|
||||
void PlayerPhase_DisplayDangerZone(void);
|
||||
void PlayerPhase_RangeDisplayIdle(ProcPtr proc);
|
||||
s8 PlayerPhase_PrepareAction(ProcPtr proc);
|
||||
s8 EnsureCameraOntoActiveUnitPosition(ProcPtr proc);
|
||||
void PlayerPhase_FinishAction(ProcPtr proc);
|
||||
void PlayerPhase_ApplyUnitMovement(ProcPtr proc);
|
||||
void PlayerPhase_DisplayUnitMovement(void);
|
||||
void PlayerPhase_WaitForUnitMovement(ProcPtr proc);
|
||||
void PlayerPhase_ResumeRangeDisplay(ProcPtr proc);
|
||||
void PlayerPhase_ReReadGameSaveGfx(void);
|
||||
void PlayerPhase_RangeDisplayIdle_ForceAPress(ProcPtr);
|
||||
void PlayerPhase_HandleAutoEnd(ProcPtr);
|
||||
|
||||
void MakeMoveunitForActiveUnit(void);
|
||||
void MoveLimitViewChange_OnInit(struct MoveLimitViewProc* proc);
|
||||
void MoveLimitViewChange_OnLoop(struct MoveLimitViewProc* proc);
|
||||
void MoveLimitView_OnEnd(struct MoveLimitViewProc* proc);
|
||||
void MoveLimitView_OnInit(ProcPtr);
|
||||
void MoveLimitView_OnLoop(struct MoveLimitViewProc* proc);
|
||||
|
||||
extern struct ProcCmd gProcScr_PlayerPhase[];
|
||||
|
||||
#endif // GUARD_PLAYERPHASE_H
|
||||
|
@ -5,31 +5,32 @@
|
||||
#include "fontgrp.h"
|
||||
#include "ekrlevelup.h"
|
||||
|
||||
struct ProcPrepSallyCursor {
|
||||
PROC_HEADER;
|
||||
struct ProcPrepSallyCursor
|
||||
{
|
||||
/* 00 */ PROC_HEADER;
|
||||
|
||||
/* 2C */ int unk_2C;
|
||||
/* 30 */ int unk_30;
|
||||
/* 34 */ int unk_34;
|
||||
/* 38 */ int unk_38;
|
||||
/* 3C */ int unk_3C;
|
||||
/* 40 */ int unk_40;
|
||||
/* 3C */ int xCursor;
|
||||
/* 40 */ int yCursor;
|
||||
|
||||
/* 44 */ u8 _pad44[0x49-0x44];
|
||||
/* 44 */ STRUCT_PAD(0x44, 0x4A);
|
||||
|
||||
/* 4A */ s16 unk_4A;
|
||||
/* 4C */ short unk_4C;
|
||||
/* 4C */ s16 unk_4C;
|
||||
|
||||
/* 4E */ u8 _pad4E[0x53-0x4E];
|
||||
/* 4E */ STRUCT_PAD(0x4E, 0x54);
|
||||
|
||||
/* 54 */ struct APHandle* unk_54;
|
||||
/* 54 */ struct APHandle * ap;
|
||||
|
||||
/* 58 */ u32 unk_58;
|
||||
};
|
||||
|
||||
struct PrepUnitList {
|
||||
struct Unit *units[0x40];
|
||||
int max_num; /* A cunter maybe related to the amount of units in team */
|
||||
int max_num; /* A counter maybe related to the amount of units in team */
|
||||
int latest_pid; /* Last unit char-id when you leave the prep-unit-screen */
|
||||
};
|
||||
|
||||
@ -176,7 +177,7 @@ extern int sSupportScreenUnitCount;
|
||||
extern u16 gUnknown_020136F4[];
|
||||
|
||||
extern struct ProcCmd gProcScr_SALLYCURSOR[];
|
||||
extern struct ProcCmd gProcScr_SALLYCURSORHelpPrompt[];
|
||||
extern struct ProcCmd gProcScr_PrepHelpPrompt[];
|
||||
extern u16 gBgConfig_ItemUseScreen[];
|
||||
// extern ??? gUnknown_08A18200
|
||||
extern CONST_DATA struct ProcCmd ProcScr_PrepMenuDescHandler[];
|
||||
@ -237,7 +238,7 @@ extern CONST_DATA struct ProcCmd gProcScr_FortuneSubMenu[];
|
||||
extern int gUnknown_08A196BC[]; /* msg lists */
|
||||
extern int CONST_DATA gUnknown_08A196D0[];
|
||||
extern int CONST_DATA gUnused_08A196E4[];
|
||||
extern u16 CONST_DATA gUnknown_08A199C8[]; // TODO - Not sure; used in sallycursor
|
||||
extern u16 CONST_DATA Img_PrepHelpButtonSprites[];
|
||||
extern u8 Img_MenuScrollBar[];
|
||||
extern u16 Pal_MenuScrollBar[];
|
||||
extern u8 gUnknown_08A19CCC[]; // gfx
|
||||
@ -252,7 +253,7 @@ extern u8 CONST_DATA gUnknown_08A1A4C8[];
|
||||
extern u8 gGfx_SupportScreenBanner[];
|
||||
extern u8 CONST_DATA gUnknown_08A1AC88[];
|
||||
extern u16 CONST_DATA Img_SysBrownBox[];
|
||||
extern u16 CONST_DATA Pal_SysBrownBox[]; // TODO - palette data from sallycursor
|
||||
extern u16 CONST_DATA Pal_SysBrownBox[];
|
||||
extern u16 CONST_DATA gPal_SupportScreenBanner[];
|
||||
extern u16 CONST_DATA gUnknown_08A1B194[];
|
||||
extern u8 gUnknown_08A1B1FC[]; // gfx
|
||||
@ -296,11 +297,11 @@ extern u16 gPal_SupportMenu[];
|
||||
/* sally-cursor */
|
||||
int GetPlayerLeaderUnitId(void);
|
||||
void sub_80332D0(void);
|
||||
void sub_803334C(void);
|
||||
void EndPrepScreenMenu_(void);
|
||||
void PrepMapMenu_OnViewMap(struct ProcPrepSallyCursor*);
|
||||
void PrepMapMenu_OnFormation(struct ProcPrepSallyCursor*);
|
||||
bool8 PrepMapMenu_OnStartPress(ProcPtr);
|
||||
bool8 PrepMapMenu_OnBPress(ProcPtr);
|
||||
bool PrepMapMenu_OnStartPress(ProcPtr);
|
||||
bool PrepMapMenu_OnBPress(ProcPtr);
|
||||
void SALLYCURSOR_DeploySupplyUnit(void);
|
||||
void PrepMapMenu_OnOptions(struct ProcPrepSallyCursor*);
|
||||
void SALLYCURSOR_RemoveSupplyUnit(void);
|
||||
@ -308,45 +309,45 @@ void PrepMapMenu_OnSave(struct ProcPrepSallyCursor*);
|
||||
void sub_8033468(struct ProcPrepSallyCursor*);
|
||||
void sub_803348C(ProcPtr);
|
||||
void PrepScreenProc_InitMapMenu(struct ProcPrepSallyCursor*);
|
||||
void sub_80334CC(void);
|
||||
void sub_80334E8(ProcPtr);
|
||||
void PrepScreenProc_DimMapImmediate(void);
|
||||
void PrepScreenProc_StartBrightenMap(ProcPtr);
|
||||
void sub_8033514(ProcPtr);
|
||||
void sub_8033548(ProcPtr);
|
||||
void sub_8033574(void);
|
||||
void PrepHelpPrompt_Init(struct ProcPrepSallyCursor *);
|
||||
void PrepHelpPrompt_Loop(void);
|
||||
void sub_8033608(void);
|
||||
void sub_8033620(ProcPtr);
|
||||
void StartPrepHelpPrompt(ProcPtr);
|
||||
void PrepMapMenu_OnEnd(void);
|
||||
void PrepScreenProc_StartMapMenu(struct ProcPrepSallyCursor*);
|
||||
bool8 CanCharacterBePrepMoved(int);
|
||||
bool CanCharacterBePrepMoved(int);
|
||||
void sub_8033770(struct ProcPrepSallyCursor*);
|
||||
void sub_8033798(struct ProcPrepSallyCursor*);
|
||||
void sub_80337B4(struct ProcPrepSallyCursor*);
|
||||
void sub_80337D4(struct ProcPrepSallyCursor*);
|
||||
void sub_80337F0(struct ProcPrepSallyCursor*);
|
||||
void InitPrepScreenUnitsAndCamera(void);
|
||||
void sub_80338C0(void);
|
||||
void InitPrepScreenCursorPosition(void);
|
||||
void sub_8033940(struct ProcPrepSallyCursor*);
|
||||
void PrepScreenProc_MapIdle(struct ProcPrepSallyCursor* proc);
|
||||
int sub_8033BF8(void);
|
||||
void SALLYCURSOR6C_StartUnitSwap(struct ProcPrepSallyCursor*);
|
||||
void sub_8033C90(struct ProcPrepSallyCursor*);
|
||||
void PrepScreen_StartUnitSwap(struct ProcPrepSallyCursor*);
|
||||
void PrepScreen_UnitSwapIdle(struct ProcPrepSallyCursor*);
|
||||
void sub_8033DD8(ProcPtr);
|
||||
void sub_8033E08(ProcPtr);
|
||||
void sub_8033E8C(void);
|
||||
void sub_8033EA4(void);
|
||||
void sub_8033EC0(ProcPtr);
|
||||
void CallCursorShop(ProcPtr);
|
||||
void PrepScreen_StartUnitSwapAnim(ProcPtr);
|
||||
void InitMapChangeGraphicsIfFog(void);
|
||||
void DisplayMapChangeIfFog(void);
|
||||
void PrepScreenProc_StartConfigMenu(ProcPtr);
|
||||
void PrepScreenProc_StartShopScreen(ProcPtr);
|
||||
void PrepScreenProc_MapMovementLoop(ProcPtr);
|
||||
void sub_8034078(ProcPtr);
|
||||
void PrepScreenProc_Cleanup(ProcPtr);
|
||||
void sub_8034090(ProcPtr);
|
||||
void StartPrepSaveScreen(ProcPtr);
|
||||
void sub_8034168(void);
|
||||
void sub_8034194(void);
|
||||
void sub_80341D0(void);
|
||||
void sub_8034200(void);
|
||||
void PrepScreenProc_LockGame(void);
|
||||
void PrepScreenProc_HideEverythingAndUnlockGame(void);
|
||||
void ShrinkPlayerUnits(void);
|
||||
void EndPrepScreen(void);
|
||||
bool8 sub_80342FC(void);
|
||||
bool sub_80342FC(void);
|
||||
|
||||
void Prep_DrawChapterGoal(int VRAM_offset, int pal);
|
||||
|
||||
|
@ -94,7 +94,7 @@ struct BmSt // Game State Struct
|
||||
/* 3B */ u8 altBlendBCb;
|
||||
/* 3C */ u8 just_resumed;
|
||||
/* 3D */ u8 taken_action;
|
||||
/* 3E */ u8 unk3E;
|
||||
/* 3E */ u8 swapActionRangeCount;
|
||||
/* 3F */ s8 unk3F;
|
||||
};
|
||||
|
||||
|
@ -1009,7 +1009,7 @@ extern u8 gGfx_YellowTextBox2[];
|
||||
extern u8 gGfx_YellowTextBox3[];
|
||||
extern u8 gGfx_YellowTextBox4[];
|
||||
extern u8 gGfx_YellowTextBox5[];
|
||||
extern u8 CONST_DATA gUnknown_08A02C34[];
|
||||
extern u8 CONST_DATA Img_LimitViewSquares[];
|
||||
// extern ??? gUnknown_08A02EB4
|
||||
// extern ??? gUnknown_08A02F34
|
||||
// extern ??? gUnknown_08A02F94
|
||||
|
@ -169,7 +169,7 @@ u8 MapMenu_GuideCommand(struct MenuProc* menu, struct MenuItemProc* menuItem) {
|
||||
|
||||
u8 MapMenu_DangerZone_UnusedEffect(void) {
|
||||
gActiveUnit = NULL;
|
||||
gBmSt.unk3E = 0;
|
||||
gBmSt.swapActionRangeCount = 0;
|
||||
Proc_Goto(Proc_Find(gProcScr_PlayerPhase), 0xC);
|
||||
|
||||
return MENU_ACT_SKIPCURSOR | MENU_ACT_END | MENU_ACT_SND6A | MENU_ACT_CLEAR;
|
||||
|
@ -1691,7 +1691,7 @@ s8 IsAnyPlayerSideWindowRetracting() {
|
||||
}
|
||||
|
||||
void MenuButtonDisp_Init(struct PlayerInterfaceProc* proc) {
|
||||
Decompress(gUnknown_08A199C8, OBJ_VRAM1 + 0x1000);
|
||||
Decompress(Img_PrepHelpButtonSprites, OBJ_VRAM1 + 0x1000);
|
||||
|
||||
proc->unk_46 = 136;
|
||||
proc->unk_48 = 140;
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user