mirror of
https://github.com/zeldaret/mm.git
synced 2026-05-26 07:38:45 -04:00
158d1b26b0
* PlayState rename * Make this work with the latest master and run format * Respond to hensldm's review * Respond to Elliptic's review * Add Effect_GetPlayState to namefixer.py * Add missed comma
29 lines
954 B
C
29 lines
954 B
C
#include "global.h"
|
|
#include "message_data_static.h"
|
|
|
|
void Message_FindCreditsMessage(PlayState* play, u16 textId) {
|
|
MessageContext* msgCtx = &play->msgCtx;
|
|
Font* font = &msgCtx->font;
|
|
MessageTableEntry* msgEntry = msgCtx->messageTableStaff;
|
|
const char* segment = msgEntry->segment;
|
|
const char* foundSegment;
|
|
const char* nextSegment;
|
|
|
|
while (msgEntry->textId != 0xFFFF) {
|
|
if (msgEntry->textId == textId) {
|
|
foundSegment = msgEntry->segment;
|
|
font->charBuf[font->unk_11D88][0] = msgEntry->typePos;
|
|
msgEntry++;
|
|
nextSegment = msgEntry->segment;
|
|
font->messageStart = foundSegment - segment;
|
|
font->messageEnd = nextSegment - foundSegment;
|
|
return;
|
|
}
|
|
msgEntry++;
|
|
}
|
|
}
|
|
|
|
#pragma GLOBAL_ASM("asm/non_matchings/code/z_message_staff/func_8015E7EC.s")
|
|
|
|
#pragma GLOBAL_ASM("asm/non_matchings/code/z_message_staff/func_8015F8A8.s")
|