mirror of
https://github.com/zeldaret/oot.git
synced 2025-07-15 04:14:34 +00:00
z_message_PAL, message_data_static and surrounding doc (#996)
* Initial progress on z_message_PAL, very messy * Fix merge * Some more progress * Fix merge * More z_message_PAL * Small progress * More small progress * message_data_static files OK * Prepare z_message_tables * Matched another function, small updates * Attempt to use asm-processor static-symbols branch * Refactor text id declarations * Begin large text codes parser function * Fix merge * Refactor done * Build OK, add color and highscore names * Remove encoded text headers and automatically encode during build * Fix kanfont * Various cleanups * DISP macros * Another match aside data * Further progress * Small improvements * Deduplicate magic values for text control codes, small improvements * Tiny progress * Minor cleanups * Clean up z_message_PAL comment * Progress on large functions * Further progress on large functions * Changes to mkldscript to link .data in the .rodata section * data OK * Few improvements * Use gDPLoadTextureBlock macros where appropriate * rm z_message_tables, progress on large functions * 2 more matches * Improvements * Small progress * More progress on big function * progress * match func_80107980 * match Message_Update * match func_8010BED8 * done * Progress on remaining large functions * Small progress on largest function * Another match, extract text and move to assets, improve text build system * Small nonmatchings improvements * docs wip * Largest function maybe equivalent * Fix merge * Document do_action values, largest function is almost instruction-matching * Rename NAVI do_action to NONE, as that appears to be how that value is used in practice * Fix merge * one match * Last function is instruction-matching * Fix * Improvements thanks to engineer124 * Stack matched thanks to petrie911, now just a/v/low t regalloc issues, some cleanup * More variables labeled, use text state enum everywhere * More labels and names * Fix * Actor_IsTalking -> Actor_TalkRequested * Match func_8010C39C and remove unused asm * More docs * Mostly ocarina related docs * All msgModes named * Fix assetclean * Cleanup * Extraction fixes and headers * Suggestions * Review suggestions * Change text extraction again, only extract if the headers do not already exist * Fix * Use ast for charmap, fix assetclean for real this time * Review suggestions * BGM ids and ran formatter * Review comments * rename include_readonly to include_data_with_rodata * Remove leading 0s in number directives * Review suggestions for message_data_static * textbox pos enum comments, rename several enum names from Message to TextBox Co-authored-by: Thar0 <maximilianc64@gmail.com> Co-authored-by: Zelllll <56516451+Zelllll@users.noreply.github.com> Co-authored-by: petrie911 <pmontag@DESKTOP-LG8A167.localdomain> Co-authored-by: Roman971 <romanlasnier@hotmail.com>
This commit is contained in:
parent
03636166b3
commit
a497f33bda
216 changed files with 7052 additions and 16801 deletions
|
@ -283,7 +283,7 @@ void Fault_UpdatePadImpl() {
|
|||
}
|
||||
|
||||
u32 Fault_WaitForInputImpl() {
|
||||
Input* curInput = &sFaultStructPtr->padInput;
|
||||
Input* input = &sFaultStructPtr->padInput;
|
||||
s32 count = 600;
|
||||
u32 kDown;
|
||||
|
||||
|
@ -291,7 +291,7 @@ u32 Fault_WaitForInputImpl() {
|
|||
Fault_Sleep(0x10);
|
||||
Fault_UpdatePadImpl();
|
||||
|
||||
kDown = curInput->press.button;
|
||||
kDown = input->press.button;
|
||||
|
||||
if (kDown == BTN_L) {
|
||||
sFaultStructPtr->faultActive = !sFaultStructPtr->faultActive;
|
||||
|
@ -539,7 +539,7 @@ void Fault_Wait5Seconds(void) {
|
|||
}
|
||||
|
||||
void Fault_WaitForButtonCombo() {
|
||||
Input* curInput = &sFaultStructPtr->padInput;
|
||||
Input* input = &sFaultStructPtr->padInput;
|
||||
s32 state;
|
||||
u32 s1;
|
||||
u32 s2;
|
||||
|
@ -567,8 +567,8 @@ void Fault_WaitForButtonCombo() {
|
|||
Fault_Sleep(0x10);
|
||||
Fault_UpdatePadImpl();
|
||||
|
||||
kDown = curInput->press.button;
|
||||
kCur = curInput->cur.button;
|
||||
kDown = input->press.button;
|
||||
kCur = input->cur.button;
|
||||
|
||||
if ((kCur == 0) && (s1 == s2)) {
|
||||
s1 = 0;
|
||||
|
@ -717,7 +717,7 @@ void Fault_DrawMemDumpPage(const char* title, u32* addr, u32 param_3) {
|
|||
}
|
||||
|
||||
void Fault_DrawMemDump(u32 pc, u32 sp, u32 unk0, u32 unk1) {
|
||||
Input* curInput = &sFaultStructPtr->padInput;
|
||||
Input* input = &sFaultStructPtr->padInput;
|
||||
u32 addr = pc;
|
||||
s32 count;
|
||||
u32 off;
|
||||
|
@ -743,7 +743,7 @@ void Fault_DrawMemDump(u32 pc, u32 sp, u32 unk0, u32 unk1) {
|
|||
count--;
|
||||
Fault_Sleep(0x10);
|
||||
Fault_UpdatePadImpl();
|
||||
if (CHECK_BTN_ALL(curInput->press.button, BTN_L)) {
|
||||
if (CHECK_BTN_ALL(input->press.button, BTN_L)) {
|
||||
sFaultStructPtr->faultActive = false;
|
||||
}
|
||||
}
|
||||
|
@ -751,40 +751,40 @@ void Fault_DrawMemDump(u32 pc, u32 sp, u32 unk0, u32 unk1) {
|
|||
do {
|
||||
Fault_Sleep(0x10);
|
||||
Fault_UpdatePadImpl();
|
||||
} while (curInput->press.button == 0);
|
||||
} while (input->press.button == 0);
|
||||
|
||||
if (CHECK_BTN_ALL(curInput->press.button, BTN_START) || CHECK_BTN_ALL(curInput->cur.button, BTN_A)) {
|
||||
if (CHECK_BTN_ALL(input->press.button, BTN_START) || CHECK_BTN_ALL(input->cur.button, BTN_A)) {
|
||||
return;
|
||||
}
|
||||
|
||||
off = 0x10;
|
||||
if (CHECK_BTN_ALL(curInput->cur.button, BTN_Z)) {
|
||||
if (CHECK_BTN_ALL(input->cur.button, BTN_Z)) {
|
||||
off = 0x100;
|
||||
}
|
||||
|
||||
if (CHECK_BTN_ALL(curInput->cur.button, BTN_B)) {
|
||||
if (CHECK_BTN_ALL(input->cur.button, BTN_B)) {
|
||||
off <<= 8;
|
||||
}
|
||||
|
||||
if (CHECK_BTN_ALL(curInput->press.button, BTN_DUP)) {
|
||||
if (CHECK_BTN_ALL(input->press.button, BTN_DUP)) {
|
||||
addr -= off;
|
||||
}
|
||||
if (CHECK_BTN_ALL(curInput->press.button, BTN_DDOWN)) {
|
||||
if (CHECK_BTN_ALL(input->press.button, BTN_DDOWN)) {
|
||||
addr += off;
|
||||
}
|
||||
if (CHECK_BTN_ALL(curInput->press.button, BTN_CUP)) {
|
||||
if (CHECK_BTN_ALL(input->press.button, BTN_CUP)) {
|
||||
addr = pc;
|
||||
}
|
||||
if (CHECK_BTN_ALL(curInput->press.button, BTN_CDOWN)) {
|
||||
if (CHECK_BTN_ALL(input->press.button, BTN_CDOWN)) {
|
||||
addr = sp;
|
||||
}
|
||||
if (CHECK_BTN_ALL(curInput->press.button, BTN_CLEFT)) {
|
||||
if (CHECK_BTN_ALL(input->press.button, BTN_CLEFT)) {
|
||||
addr = unk0;
|
||||
}
|
||||
if (CHECK_BTN_ALL(curInput->press.button, BTN_CRIGHT)) {
|
||||
if (CHECK_BTN_ALL(input->press.button, BTN_CRIGHT)) {
|
||||
addr = unk1;
|
||||
}
|
||||
} while (!CHECK_BTN_ALL(curInput->press.button, BTN_L));
|
||||
} while (!CHECK_BTN_ALL(input->press.button, BTN_L));
|
||||
|
||||
sFaultStructPtr->faultActive = true;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue