mirror of
https://github.com/FireEmblemUniverse/fireemblem8u.git
synced 2024-11-23 13:19:53 +00:00
Small cleanups in Talk_OnIdle, GetStrTalkLen, BmBgfx_Loop, and StartGmapRm
This commit is contained in:
parent
67758de6b6
commit
f667e6d662
11
src/scene.c
11
src/scene.c
@ -565,26 +565,21 @@ void Talk_OnIdle(ProcPtr proc) {
|
|||||||
Proc_Break(proc);
|
Proc_Break(proc);
|
||||||
return;
|
return;
|
||||||
|
|
||||||
case 1:
|
|
||||||
goto _08006CD0;
|
|
||||||
|
|
||||||
case 2:
|
case 2:
|
||||||
if (sTalkState->instantScroll || sTalkState->printDelay <= 0) {
|
if (sTalkState->instantScroll || sTalkState->printDelay <= 0) {
|
||||||
break;
|
break;
|
||||||
goto _08006CC2;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|
||||||
case 3:
|
case 3:
|
||||||
_08006CC2:
|
|
||||||
sTalkState->printClock = sTalkState->printDelay;
|
sTalkState->printClock = sTalkState->printDelay;
|
||||||
sTalkState->instantScroll = 0;
|
sTalkState->instantScroll = 0;
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
case 1:
|
||||||
default:
|
default:
|
||||||
_08006CD0:
|
|
||||||
if (!(CheckTalkFlag(TALK_FLAG_SPRITE))) {
|
if (!(CheckTalkFlag(TALK_FLAG_SPRITE))) {
|
||||||
if (TalkPrepNextChar(proc) == 1) {
|
if (TalkPrepNextChar(proc) == 1) {
|
||||||
return;
|
return;
|
||||||
@ -2285,9 +2280,7 @@ int GetStrTalkLen(const char* str, s8 isBubbleOpen) {
|
|||||||
continue;
|
continue;
|
||||||
|
|
||||||
case 0x10:
|
case 0x10:
|
||||||
str++;
|
str += 3;
|
||||||
str++;
|
|
||||||
str++;
|
|
||||||
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -1385,23 +1385,11 @@ void BmBgfx_Loop(struct ProcBmBgfx * proc)
|
|||||||
if (conf->type == BMFX_CONFT_BLOCKING)
|
if (conf->type == BMFX_CONFT_BLOCKING)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
#if NONMATCHING
|
|
||||||
switch (conf->type) {
|
|
||||||
case BMFX_CONFT_BREAK:
|
|
||||||
case BMFX_CONFT_END:
|
|
||||||
Proc_Break(proc);
|
|
||||||
return;
|
|
||||||
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
if (conf->type < 11 && conf->type > 8)
|
if (conf->type < 11 && conf->type > 8)
|
||||||
{
|
{
|
||||||
Proc_Break(proc);
|
Proc_Break(proc);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
if (proc->timer == 0)
|
if (proc->timer == 0)
|
||||||
{
|
{
|
||||||
|
@ -301,15 +301,8 @@ ProcPtr StartGmapRm(int x, int y, u32 mask, ProcPtr parent)
|
|||||||
else
|
else
|
||||||
proc = Proc_Start(ProcScr_GmapRM, PROC_TREE_3);
|
proc = Proc_Start(ProcScr_GmapRM, PROC_TREE_3);
|
||||||
|
|
||||||
#if NONMATCHING
|
proc->flag = (~GMAPRM_FLAG_UNBLOCK);
|
||||||
proc->flag = mask & (~GMAPRM_FLAG_UNBLOCK);
|
proc->flag &= mask;
|
||||||
#else
|
|
||||||
{
|
|
||||||
u8 * flag_it = &proc->flag;
|
|
||||||
u8 _mask = ~GMAPRM_FLAG_UNBLOCK;
|
|
||||||
*flag_it = _mask & mask;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
proc->x = x;
|
proc->x = x;
|
||||||
proc->y = y;
|
proc->y = y;
|
||||||
|
Loading…
Reference in New Issue
Block a user