Files
mm/src/code/title_setup.c
T
mzxrules 2c680efa91 z_map decompiled (#1032)
* First batch of functions

* more ok

* z_map_data OK

* More OKs, MinimapList ZAPD breaking change

* func_80103A58 improvements, more OK

* func_80106D5C and func_801091F0 decomped

* func_801031D0 decomped and some fixes

* house cleaning, more OKs more decomp

* Even more OKs

* func_80105C40 almost OK, more OKs

* func_80108AF8 OK and more

* All functions attempted

* func_8010534C OK

* Start documentation, rename DoorCtx

* More OKs, split map_data.data, more doc

* incremental clean-up, more function names

* more function names

* func_801068FC OK

* old uncommitted changes

* minor tweaks

* implement easy fixes

* more fixes

* z_map_disp OK, implement more suggestions

* delete utility program

* migrate data

* TransiActor ->TransitionActor

* Major documentation pass

* first pass of changes

* warning fix attempt, revert ZFile.cpp

* Fix FAKE match

* Easy fixes

* implement gDPLoadTextureBlock_Runtime

* z_demo bss patch

* Extract white square texture

* Implement more suggestions

* rework MapIndex/DungeonIndex

* revert dungeonSceneIndex -> mapIndex in some spots, implement suggestions

* more suggestions

* minor nits

* fix #include
2024-06-20 18:21:37 -07:00

70 lines
1.7 KiB
C

#include "z_title_setup.h"
#include "sys_flashrom.h"
#include "overlays/gamestates/ovl_title/z_title.h"
void Setup_InitRegs(void) {
XREG(2) = 0;
XREG(10) = 26;
XREG(11) = 20;
XREG(12) = 14;
XREG(13) = 0;
R_A_BTN_Y_OFFSET = 0;
R_MAGIC_CONSUME_TIMER_GIANTS_MASK = 80;
R_THREE_DAY_CLOCK_Y_POS = 64596;
R_THREE_DAY_CLOCK_SUN_MOON_CUTOFF = 215;
R_THREE_DAY_CLOCK_HOUR_DIGIT_CUTOFF = 218;
XREG(68) = 0x61;
XREG(69) = 0x93;
XREG(70) = 0x28;
XREG(73) = 0x1E;
XREG(74) = 0x42;
XREG(75) = 0x1E;
XREG(76) = 0x1C;
XREG(77) = 0x3C;
XREG(78) = 0x2F;
XREG(79) = 0x62;
R_PAUSE_OWL_WARP_ALPHA = 0;
XREG(88) = 0x56;
XREG(89) = 0x258;
XREG(90) = 0x1C2;
R_STORY_FILL_SCREEN_ALPHA = 0;
R_PLAYER_FLOOR_REVERSE_INDEX = 0;
R_MINIMAP_DISABLED = false;
R_PICTO_FOCUS_BORDER_TOPLEFT_X = 80;
R_PICTO_FOCUS_BORDER_TOPLEFT_Y = 60;
R_PICTO_FOCUS_BORDER_TOPRIGHT_X = 220;
R_PICTO_FOCUS_BORDER_TOPRIGHT_Y = 60;
R_PICTO_FOCUS_BORDER_BOTTOMLEFT_X = 80;
R_PICTO_FOCUS_BORDER_BOTTOMLEFT_Y = 160;
R_PICTO_FOCUS_BORDER_BOTTOMRIGHT_X = 220;
R_PICTO_FOCUS_BORDER_BOTTOMRIGHT_Y = 160;
R_PICTO_FOCUS_ICON_X = 142;
R_PICTO_FOCUS_ICON_Y = 108;
R_PICTO_FOCUS_TEXT_X = 204;
R_PICTO_FOCUS_TEXT_Y = 177;
}
void Setup_InitImpl(SetupState* this) {
SysFlashrom_InitFlash();
SaveContext_Init();
Setup_InitRegs();
STOP_GAMESTATE(&this->state);
SET_NEXT_GAMESTATE(&this->state, ConsoleLogo_Init, sizeof(ConsoleLogoState));
}
void Setup_Destroy(GameState* thisx) {
}
void Setup_Init(GameState* thisx) {
SetupState* this = (SetupState*)thisx;
this->state.destroy = Setup_Destroy;
Setup_InitImpl(this);
}