[Decompilation] [th01] Verdict screen: Move all data to C land

Part of P0211, funded by Lmocinemod and Arandui.
This commit is contained in:
nmlgc 2022-08-06 18:08:27 +02:00
parent 64fe9bbff9
commit 6e36dfd93b
3 changed files with 30 additions and 55 deletions

View File

@ -504,17 +504,19 @@ void verdict_title_calculate_and_render(void)
(VERDICT_LEFT - VERDICT_TITLE_LEFT_OFFSET + VERDICT_TITLE_PADDED_W),
verdict_line_top(12),
FX_TITLE,
"%s\0 EASY \0NORMAL\0 HARD \0LUNATIC",
"%s",
VERDICT_TITLES[group][level]
);
}
void verdict_animate_and_regist(void)
{
struct hack { const char *str[RANK_COUNT]; }; // XXX
extern const hack ranks;
struct hack RANKS = ranks;
const char* RANKS[RANK_COUNT] = {
" EASY ",
"NORMAL",
" HARD ",
"LUNATIC"
};
grp_palette_black_out(10);
@ -532,7 +534,7 @@ void verdict_animate_and_regist(void)
);
frame_delay(30);
verdict_line_render1(2, VERDICT_RANK"%s", RANKS.str[rank]);
verdict_line_render1(2, VERDICT_RANK"%s", RANKS[rank]);
// Should really all be %10lu (with the superflous right-padding removed
// from the strings) if you're already using `long`s here. Scoreplayers

View File

@ -52,5 +52,26 @@ static const pixel_t VERDICT_TITLE_PADDED_W = shiftjis_w(VERDICT_TITLE " ");
static const int VERDICT_GROUPS = 3;
static const int VERDICT_LEVELS = 6;
extern const unsigned char *VERDICT_TITLES[VERDICT_GROUPS][VERDICT_LEVELS];
const unsigned char *VERDICT_TITLES[VERDICT_GROUPS][VERDICT_LEVELS] = { {
" モンキー ",
" 類人猿",
"ホモサピエンス",
" 超人",
" 靈神 ",
" 神を超越"
}, {
"お子様ゲーマー",
"似非スコアラー",
"ミドルスコアラー",
"ハイスコアラー",
"スーパーゲーマー",
"ゲーマーを超越",
}, {
"腐ったみかん",
"ザックームの実",
"禁断の林檎",
"世界樹の葉",
"黄帝九鼎神丹経",
" アムリタ"
} };
// --------------

View File

@ -235,54 +235,6 @@ include th01/hiscore/regist_name[data].asm
include th01/hardware/grppfnfx[data].asm
include th01/hiscore/scorelod[data].asm
include th01/hiscore/regist[data].asm
public _VERDICT_TITLES
_VERDICT_TITLES label dword
dd aB@gvguglbB@ ; " モンキー "
dd aB@cRlio ; " 類人猿"
dd aGzgvgtgsgggugx ; "ホモサピエンス"
dd aB@tRl ; " 超人"
dd aB@sR_b@ ; " 靈神 "
dd aB@r_v ; " 神を超越"
dd aVioqclgqbGB ; "お子様ゲーマー"
dd aOcf ; "似非スコアラー"
dd aGGhglgxgrgagib ; "ミドルスコアラー"
dd aGngcgxgrgagib ; "ハイスコアラー"
dd aGxbGpbGqbGB ; "スーパーゲーマー"
dd aGqbGBV ; "ゲーマーを超越"
dd aXevVVViv ; "腐ったみかん"
dd aGugbgnbGavO ; "ザックームの実"
dd aLTfvCMc ; "禁断の林檎"
dd aRvkeo ; "世界樹の葉"
dd aIitsluucr_tomo ; "黄帝九鼎神丹経"
dd aB@gagagkg ; " アムリタ"
public _ranks
_ranks label dword
dd DGROUP:0763h
dd DGROUP:076Ah
dd DGROUP:0771h
dd DGROUP:0778h
; Group 0
aB@gvguglbB@ db ' モンキー ',0
aB@cRlio db ' 類人猿',0
aGzgvgtgsgggugx db 'ホモサピエンス',0
aB@tRl db ' 超人',0
aB@sR_b@ db ' 靈神 ',0
aB@r_v db ' 神を超越',0
; Group 1
aVioqclgqbGB db 'お子様ゲーマー',0
aOcf db '似非スコアラー',0
aGGhglgxgrgagib db 'ミドルスコアラー',0
aGngcgxgrgagib db 'ハイスコアラー',0
aGxbGpbGqbGB db 'スーパーゲーマー',0
aGqbGBV db 'ゲーマーを超越',0
; Group 2
aXevVVViv db '腐ったみかん',0
aGugbgnbGavO db 'ザックームの実',0
aLTfvCMc db '禁断の林檎',0
aRvkeo db '世界樹の葉',0
aIitsluucr_tomo db '黄帝九鼎神丹経',0
aB@gagagkg db ' アムリタ',0
; th01/hardware/palette[data].asm
extern _z_Palettes:rgb_t:COLOR_COUNT