diff --git a/include/applications/naming_screen.h b/include/applications/naming_screen.h index 1efe277183..1ad669b4f9 100644 --- a/include/applications/naming_screen.h +++ b/include/applications/naming_screen.h @@ -18,15 +18,20 @@ enum NamingScreenType { NAMING_SCREEN_TYPE_PAL_PAD, }; +enum NamingScreenReturnCode { + NAMING_SCREEN_CODE_OK, + NAMING_SCREEN_CODE_NO_INPUT, +}; + typedef struct NamingScreenArgs { enum NamingScreenType type; int playerGenderOrMonSpecies; int monForm; int maxChars; int monGender; - int unk_14; + enum NamingScreenReturnCode returnCode; Strbuf *textInputStr; - u16 unk_1C[20]; + charcode_t nameInputRaw[20]; int battleMsgID; PCBoxes *pcBoxes; Options *options; @@ -37,9 +42,9 @@ extern const ApplicationManagerTemplate gNamingScreenAppTemplate; NamingScreenArgs *NamingScreenArgs_Init( enum HeapId heapID, enum NamingScreenType type, - int param2, - int param3, + int playerGenderOrMonSpecies, + int maxChars, Options *options); -void NamingScreenArgs_Free(NamingScreenArgs *param0); +void NamingScreenArgs_Free(NamingScreenArgs *args); #endif // POKEPLATINUM_KEYBOARD_H diff --git a/platinum.us/filesys.csv b/platinum.us/filesys.csv index 67ccc2371b..b3c9e7df08 100644 --- a/platinum.us/filesys.csv +++ b/platinum.us/filesys.csv @@ -49,7 +49,7 @@ res/prebuilt/data/miniasasea.nsbtx,/data/miniasasea.nsbtx res/prebuilt/data/minihamabe.nsbtx,/data/minihamabe.nsbtx res/prebuilt/data/minimum.nsbtx,/data/minimum.nsbtx res/prebuilt/data/minirhana.nsbtx,/data/minirhana.nsbtx -res/prebuilt/data/namein.narc,/data/namein.narc +res/graphics/naming_screen/namein.narc,/data/namein.narc res/prebuilt/data/nfont.NCGR,/data/nfont.NCGR res/prebuilt/data/nfont.NCLR,/data/nfont.NCLR res/prebuilt/data/pc.nsbca,/data/pc.nsbca diff --git a/platinum.us/filesys.sha1 b/platinum.us/filesys.sha1 index 95142f020f..7170d62272 100644 --- a/platinum.us/filesys.sha1 +++ b/platinum.us/filesys.sha1 @@ -48,7 +48,7 @@ b6c7a3b01146ef7a8e5cd0c583a6185a62fce803 *res/prebuilt/data/miniasasea.nsbtx 0634ba96cde00f4ae9417aa3b503925272480752 *res/prebuilt/data/minihamabe.nsbtx 71f4cedade64a030172afc432049106ad198e0e6 *res/prebuilt/data/minimum.nsbtx 4bd3072a3c2e0d833feb9ce6c4b8264c73cf3c29 *res/prebuilt/data/minirhana.nsbtx -8138e762591a993179132f20550ca3c94aba6b9d *res/prebuilt/data/namein.narc +8138e762591a993179132f20550ca3c94aba6b9d *res/graphics/naming_screen/namein.narc 5d5c14fcfa0f8534c2eec79ffa945d01f4c547b4 *res/prebuilt/data/nfont.NCGR 9eae4f97e9e97b6cd427c95def1c166ea868da43 *res/prebuilt/data/nfont.NCLR bbec5b2143b48f7439efa8eb285b69635f3720fa *res/prebuilt/data/pc.nsbca diff --git a/res/graphics/meson.build b/res/graphics/meson.build index 4456cfd499..33891b127f 100644 --- a/res/graphics/meson.build +++ b/res/graphics/meson.build @@ -1,3 +1,4 @@ +subdir('naming_screen') subdir('options_menu') subdir('pokemon_summary_screen') subdir('scroll_prompts') diff --git a/res/graphics/naming_screen/meson.build b/res/graphics/naming_screen/meson.build new file mode 100644 index 0000000000..1a80023463 --- /dev/null +++ b/res/graphics/naming_screen/meson.build @@ -0,0 +1,105 @@ +naming_screen_pngs = files( + 'naming_screen_main_tiles.png', + 'naming_screen_dummy_0.png', + 'naming_screen_unk_tiles.png', +) + +naming_screen_sprites_pngs = files( + 'naming_screen_sprites.png', + 'naming_screen_unk_sprite.png', +) + +naming_screen_pals = files( + 'naming_screen.pal', + 'naming_screen_sprites.pal', +) + +naming_screen_cell_jsons = files( + 'naming_screen_sprites_cell.json', + 'naming_screen_unk_sprite_cell.json', +) + +naming_screen_anim_jsons = files( + 'naming_screen_sprites_anim.json', + 'naming_screen_unk_sprite_anim.json', +) + +naming_screen_nscrs = files( + 'naming_screen_bg.NSCR', + 'naming_screen_dummy_1.NSCR', + 'naming_screen_chars_bg_0.NSCR', + 'naming_screen_chars_bg_1.NSCR', + 'naming_screen_chars_bg_2.NSCR', + 'naming_screen_chars_bg_3.NSCR', + 'naming_screen_dummy_2.NSCR', + 'naming_screen_dummy_3.NSCR', +) + +naming_screen_sprites_ncgr_lzs = ncgr_lz_gen.process(naming_screen_sprites_pngs, + extra_args: [ + '-clobbersize', + '-version101', + '-mappingtype', '0', + '-nopad', + ] +) + +naming_screen_ncgr_lzs = ncgr_lz_gen.process(naming_screen_pngs, + extra_args: [ + '-sopc', + '-version101', + '-nopad', + ] +) + +naming_screen_nclrs = nclr_gen.process(naming_screen_pals, + extra_args: [ + '-bitdepth', '4', + ] +) + +naming_screen_ncer_lzs = ncer_lz_gen.process(naming_screen_cell_jsons, + extra_args: [ + '-nopad', + ] +) + +naming_screen_nanr_lzs = nanr_lz_gen.process(naming_screen_anim_jsons, + extra_args: [ + '-nopad', + ] +) + +naming_screen_nscr_lzs = lz_gen.process(naming_screen_nscrs, + extra_args: [ + '-nopad', + ] +) + +naming_screen_order = files('naming_screen.order') + +naming_screen_narc = custom_target('namein.narc', + output: [ + 'namein.narc', + 'namein.naix.h', + ], + input: [ + naming_screen_ncgr_lzs, + naming_screen_sprites_ncgr_lzs, + naming_screen_nclrs, + naming_screen_ncer_lzs, + naming_screen_nanr_lzs, + naming_screen_nscr_lzs, + naming_screen_order, + ], + command: [ + narc_exe, 'create', + '--naix', + '--order', naming_screen_order, + '--output', '@OUTPUT0@', + '@PRIVATE_DIR@', + ] +) + +nitrofs_files += naming_screen_narc +naix_headers += naming_screen_narc[1] diff --git a/res/graphics/naming_screen/naming_screen.order b/res/graphics/naming_screen/naming_screen.order new file mode 100644 index 0000000000..32340d1da8 --- /dev/null +++ b/res/graphics/naming_screen/naming_screen.order @@ -0,0 +1,19 @@ +naming_screen.NCLR +naming_screen_sprites.NCLR +naming_screen_main_tiles.NCGR.lz +naming_screen_dummy_0.NCGR.lz +naming_screen_bg.NSCR.lz +naming_screen_dummy_1.NSCR.lz +naming_screen_chars_bg_0.NSCR.lz +naming_screen_chars_bg_1.NSCR.lz +naming_screen_chars_bg_2.NSCR.lz +naming_screen_chars_bg_3.NSCR.lz +naming_screen_sprites.NCGR.lz +naming_screen_unk_sprite.NCGR.lz +naming_screen_sprites_cell.NCER.lz +naming_screen_unk_sprite_cell.NCER.lz +naming_screen_sprites_anim.NANR.lz +naming_screen_unk_sprite_anim.NANR.lz +naming_screen_unk_tiles.NCGR.lz +naming_screen_dummy_2.NSCR.lz +naming_screen_dummy_3.NSCR.lz diff --git a/res/graphics/naming_screen/naming_screen.pal b/res/graphics/naming_screen/naming_screen.pal new file mode 100644 index 0000000000..72646a52c2 --- /dev/null +++ b/res/graphics/naming_screen/naming_screen.pal @@ -0,0 +1,259 @@ +JASC-PAL +0100 +256 +238 189 255 +246 246 230 +172 180 213 +82 82 189 +123 139 189 +213 213 222 +98 98 197 +0 0 0 +0 0 0 +0 0 0 +222 246 131 +222 238 115 +213 238 98 +213 230 74 +16 24 32 +172 189 189 +189 189 255 +139 139 139 +246 131 115 +255 205 189 +255 222 205 +238 180 49 +255 222 164 +255 238 189 +74 238 123 +180 255 213 +213 255 238 +32 205 238 +189 230 255 +213 238 255 +16 24 32 +164 164 164 +205 106 255 +197 238 106 +189 238 74 +148 230 131 +156 222 82 +106 189 106 +197 246 164 +205 246 172 +106 205 139 +82 180 115 +115 213 123 +0 0 0 +0 0 0 +164 189 106 +205 246 156 +90 123 98 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 diff --git a/res/graphics/naming_screen/naming_screen_bg.NSCR b/res/graphics/naming_screen/naming_screen_bg.NSCR new file mode 100644 index 0000000000..cab16df3e8 Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_bg.NSCR differ diff --git a/res/graphics/naming_screen/naming_screen_chars_bg_0.NSCR b/res/graphics/naming_screen/naming_screen_chars_bg_0.NSCR new file mode 100644 index 0000000000..0eb39a037d Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_chars_bg_0.NSCR differ diff --git a/res/graphics/naming_screen/naming_screen_chars_bg_1.NSCR b/res/graphics/naming_screen/naming_screen_chars_bg_1.NSCR new file mode 100644 index 0000000000..0289705014 Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_chars_bg_1.NSCR differ diff --git a/res/graphics/naming_screen/naming_screen_chars_bg_2.NSCR b/res/graphics/naming_screen/naming_screen_chars_bg_2.NSCR new file mode 100644 index 0000000000..1de33a89a5 Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_chars_bg_2.NSCR differ diff --git a/res/graphics/naming_screen/naming_screen_chars_bg_3.NSCR b/res/graphics/naming_screen/naming_screen_chars_bg_3.NSCR new file mode 100644 index 0000000000..7b04c5190c Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_chars_bg_3.NSCR differ diff --git a/res/graphics/naming_screen/naming_screen_dummy_0.png b/res/graphics/naming_screen/naming_screen_dummy_0.png new file mode 100644 index 0000000000..2751a8016d Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_dummy_0.png differ diff --git a/res/graphics/naming_screen/naming_screen_dummy_1.NSCR b/res/graphics/naming_screen/naming_screen_dummy_1.NSCR new file mode 100644 index 0000000000..9bcabe6287 Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_dummy_1.NSCR differ diff --git a/res/graphics/naming_screen/naming_screen_dummy_2.NSCR b/res/graphics/naming_screen/naming_screen_dummy_2.NSCR new file mode 100644 index 0000000000..d3c5f0e9a5 Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_dummy_2.NSCR differ diff --git a/res/graphics/naming_screen/naming_screen_dummy_3.NSCR b/res/graphics/naming_screen/naming_screen_dummy_3.NSCR new file mode 100644 index 0000000000..b79e861ca6 Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_dummy_3.NSCR differ diff --git a/res/graphics/naming_screen/naming_screen_main_tiles.png b/res/graphics/naming_screen/naming_screen_main_tiles.png new file mode 100644 index 0000000000..1e9037b274 Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_main_tiles.png differ diff --git a/res/graphics/naming_screen/naming_screen_sprites.pal b/res/graphics/naming_screen/naming_screen_sprites.pal new file mode 100644 index 0000000000..e0c998e00a --- /dev/null +++ b/res/graphics/naming_screen/naming_screen_sprites.pal @@ -0,0 +1,259 @@ +JASC-PAL +0100 +256 +197 197 255 +246 246 172 +238 205 115 +222 213 106 +213 230 106 +197 238 98 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +238 255 197 +230 255 131 +98 148 115 +189 230 205 +57 82 98 +172 139 156 +189 148 41 +205 172 65 +123 123 123 +255 222 16 +230 230 230 +180 131 213 +238 131 213 +205 148 255 +172 131 24 +123 106 164 +238 32 16 +246 189 238 +230 189 255 +255 230 189 +246 246 230 +172 180 213 +123 164 197 +123 139 189 +106 123 156 +82 180 205 +131 172 205 +115 90 197 +189 148 230 +238 230 156 +213 139 197 +0 0 0 +0 0 0 +16 24 32 +172 189 189 +139 238 205 +0 131 255 +255 24 24 +164 164 131 +98 98 98 +139 222 246 +90 205 238 +41 189 205 +65 131 205 +222 213 197 +246 246 230 +172 139 156 +197 172 180 +8 255 0 +16 24 32 +172 189 189 +197 189 156 +98 115 189 +189 57 74 +222 106 123 +57 65 82 +57 98 139 +156 189 255 +90 131 230 +205 205 222 +205 156 57 +123 65 65 +222 164 123 +255 213 189 +0 0 0 +172 164 205 +238 238 255 +156 197 156 +197 106 156 +197 57 65 +238 106 106 +57 65 82 +57 98 139 +255 222 90 +238 148 197 +205 205 222 +205 156 57 +123 65 65 +222 164 123 +255 213 189 +0 0 0 +172 164 205 +238 238 255 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +131 189 156 +90 148 115 +197 106 57 +246 131 74 +57 65 82 +82 106 139 +255 222 131 +131 213 139 +205 205 222 +205 180 123 +139 106 65 +222 164 123 +255 213 189 +0 0 0 +172 164 205 +238 246 255 +139 238 205 +205 205 189 +197 205 213 +164 164 131 +98 98 98 +205 222 230 +164 189 189 +156 172 172 +115 115 115 +255 255 255 +246 246 230 +172 205 172 +205 205 230 +139 131 189 +238 246 246 +139 164 164 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 +0 0 0 diff --git a/res/graphics/naming_screen/naming_screen_sprites.png b/res/graphics/naming_screen/naming_screen_sprites.png new file mode 100644 index 0000000000..77c10d5d38 Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_sprites.png differ diff --git a/res/graphics/naming_screen/naming_screen_sprites_anim.json b/res/graphics/naming_screen/naming_screen_sprites_anim.json new file mode 100644 index 0000000000..e263784163 --- /dev/null +++ b/res/graphics/naming_screen/naming_screen_sprites_anim.json @@ -0,0 +1,1060 @@ +{ + "labelEnabled": true, + "sequenceCount": 61, + "frameCount": 126, + "sequences": [{ + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 0 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 0 + }, { + "frameDelay": 16, + "resultId": 1 + }, { + "frameDelay": 60, + "resultId": 0 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 0 + }, { + "frameDelay": 60, + "resultId": 2 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 2 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 2 + }, { + "frameDelay": 16, + "resultId": 3 + }, { + "frameDelay": 60, + "resultId": 0 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 4 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 4 + }, { + "frameDelay": 16, + "resultId": 5 + }, { + "frameDelay": 60, + "resultId": 4 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 4 + }, { + "frameDelay": 60, + "resultId": 6 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 6 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 6 + }, { + "frameDelay": 16, + "resultId": 7 + }, { + "frameDelay": 60, + "resultId": 4 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 8 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 8 + }, { + "frameDelay": 16, + "resultId": 9 + }, { + "frameDelay": 60, + "resultId": 8 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 8 + }, { + "frameDelay": 60, + "resultId": 10 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 10 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 10 + }, { + "frameDelay": 16, + "resultId": 11 + }, { + "frameDelay": 60, + "resultId": 8 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 12 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 12 + }, { + "frameDelay": 16, + "resultId": 13 + }, { + "frameDelay": 60, + "resultId": 12 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 12 + }, { + "frameDelay": 60, + "resultId": 14 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 14 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 14 + }, { + "frameDelay": 16, + "resultId": 15 + }, { + "frameDelay": 60, + "resultId": 12 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 8, + "resultId": 16 + }, { + "frameDelay": 1, + "resultId": 17 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 8, + "resultId": 18 + }, { + "frameDelay": 16, + "resultId": 17 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 8, + "resultId": 19 + }, { + "frameDelay": 16, + "resultId": 17 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 4, + "resultId": 20 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 8, + "resultId": 21 + }, { + "frameDelay": 60, + "resultId": 20 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 22 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 8, + "resultId": 23 + }, { + "frameDelay": 60, + "resultId": 22 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 24 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 24 + }, { + "frameDelay": 16, + "resultId": 25 + }, { + "frameDelay": 60, + "resultId": 24 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 24 + }, { + "frameDelay": 60, + "resultId": 26 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 26 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 26 + }, { + "frameDelay": 16, + "resultId": 27 + }, { + "frameDelay": 60, + "resultId": 24 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 28 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 28 + }, { + "frameDelay": 16, + "resultId": 29 + }, { + "frameDelay": 60, + "resultId": 28 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 28 + }, { + "frameDelay": 60, + "resultId": 30 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 30 + }] + }, { + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 60, + "resultId": 30 + }, { + "frameDelay": 16, + "resultId": 31 + }, { + "frameDelay": 60, + "resultId": 28 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 32 + }] + }, { + "frameCount": 4, + "loopStartFrame": 0, + "animationElement": 2, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 2, + "resultId": 33 + }, { + "frameDelay": 2, + "resultId": 34 + }, { + "frameDelay": 2, + "resultId": 35 + }, { + "frameDelay": 60, + "resultId": 36 + }] + }, { + "frameCount": 4, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 8, + "resultId": 37 + }, { + "frameDelay": 8, + "resultId": 38 + }, { + "frameDelay": 8, + "resultId": 39 + }, { + "frameDelay": 8, + "resultId": 38 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 40 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 41 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 42 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 43 + }] + }, { + "frameCount": 4, + "loopStartFrame": 0, + "animationElement": 2, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 6, + "resultId": 44 + }, { + "frameDelay": 3, + "resultId": 45 + }, { + "frameDelay": 3, + "resultId": 46 + }, { + "frameDelay": 4, + "resultId": 45 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 47 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 48 + }] + }, { + "frameCount": 4, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 6, + "resultId": 49 + }, { + "frameDelay": 6, + "resultId": 50 + }, { + "frameDelay": 6, + "resultId": 51 + }, { + "frameDelay": 6, + "resultId": 52 + }] + }, { + "frameCount": 4, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 12, + "resultId": 53 + }, { + "frameDelay": 12, + "resultId": 54 + }, { + "frameDelay": 12, + "resultId": 55 + }, { + "frameDelay": 12, + "resultId": 54 + }] + }, { + "frameCount": 4, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 12, + "resultId": 56 + }, { + "frameDelay": 12, + "resultId": 57 + }, { + "frameDelay": 12, + "resultId": 58 + }, { + "frameDelay": 12, + "resultId": 57 + }] + }, { + "frameCount": 2, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 20, + "resultId": 59 + }, { + "frameDelay": 3, + "resultId": 60 + }] + }, { + "frameCount": 4, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 12, + "resultId": 61 + }, { + "frameDelay": 12, + "resultId": 62 + }, { + "frameDelay": 12, + "resultId": 63 + }, { + "frameDelay": 12, + "resultId": 62 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 64 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 65 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 66 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 67 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 68 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 69 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 70 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 2, + "frameData": [{ + "frameDelay": 4, + "resultId": 71 + }] + }, { + "frameCount": 9, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 2, + "resultId": 72 + }, { + "frameDelay": 2, + "resultId": 73 + }, { + "frameDelay": 2, + "resultId": 74 + }, { + "frameDelay": 2, + "resultId": 75 + }, { + "frameDelay": 2, + "resultId": 76 + }, { + "frameDelay": 2, + "resultId": 75 + }, { + "frameDelay": 2, + "resultId": 74 + }, { + "frameDelay": 2, + "resultId": 73 + }, { + "frameDelay": 2, + "resultId": 72 + }] + }], + "animationResults": [{ + "resultType": 0, + "index": 0 + }, { + "resultType": 0, + "index": 1 + }, { + "resultType": 0, + "index": 2 + }, { + "resultType": 0, + "index": 3 + }, { + "resultType": 0, + "index": 4 + }, { + "resultType": 0, + "index": 5 + }, { + "resultType": 0, + "index": 6 + }, { + "resultType": 0, + "index": 7 + }, { + "resultType": 0, + "index": 8 + }, { + "resultType": 0, + "index": 9 + }, { + "resultType": 0, + "index": 10 + }, { + "resultType": 0, + "index": 11 + }, { + "resultType": 0, + "index": 12 + }, { + "resultType": 0, + "index": 13 + }, { + "resultType": 0, + "index": 14 + }, { + "resultType": 0, + "index": 15 + }, { + "resultType": 0, + "index": 16 + }, { + "resultType": 0, + "index": 51 + }, { + "resultType": 0, + "index": 17 + }, { + "resultType": 0, + "index": 18 + }, { + "resultType": 0, + "index": 19 + }, { + "resultType": 0, + "index": 20 + }, { + "resultType": 0, + "index": 21 + }, { + "resultType": 0, + "index": 22 + }, { + "resultType": 0, + "index": 23 + }, { + "resultType": 0, + "index": 24 + }, { + "resultType": 0, + "index": 25 + }, { + "resultType": 0, + "index": 26 + }, { + "resultType": 0, + "index": 27 + }, { + "resultType": 0, + "index": 28 + }, { + "resultType": 0, + "index": 29 + }, { + "resultType": 0, + "index": 30 + }, { + "resultType": 0, + "index": 31 + }, { + "resultType": 2, + "index": 31, + "positionX": 4, + "positionY": 0 + }, { + "resultType": 2, + "index": 31, + "positionX": -2, + "positionY": 0 + }, { + "resultType": 2, + "index": 31, + "positionX": 2, + "positionY": 0 + }, { + "resultType": 2, + "index": 31, + "positionX": 0, + "positionY": 0 + }, { + "resultType": 0, + "index": 32 + }, { + "resultType": 0, + "index": 37 + }, { + "resultType": 0, + "index": 38 + }, { + "resultType": 0, + "index": 33 + }, { + "resultType": 0, + "index": 34 + }, { + "resultType": 0, + "index": 35 + }, { + "resultType": 0, + "index": 36 + }, { + "resultType": 2, + "index": 36, + "positionX": 0, + "positionY": 0 + }, { + "resultType": 2, + "index": 36, + "positionX": 0, + "positionY": 1 + }, { + "resultType": 2, + "index": 36, + "positionX": 0, + "positionY": 2 + }, { + "resultType": 0, + "index": 39 + }, { + "resultType": 0, + "index": 40 + }, { + "resultType": 0, + "index": 41 + }, { + "resultType": 0, + "index": 42 + }, { + "resultType": 0, + "index": 43 + }, { + "resultType": 0, + "index": 44 + }, { + "resultType": 0, + "index": 45 + }, { + "resultType": 0, + "index": 46 + }, { + "resultType": 0, + "index": 47 + }, { + "resultType": 0, + "index": 48 + }, { + "resultType": 0, + "index": 49 + }, { + "resultType": 0, + "index": 50 + }, { + "resultType": 0, + "index": 52 + }, { + "resultType": 0, + "index": 53 + }, { + "resultType": 0, + "index": 54 + }, { + "resultType": 0, + "index": 55 + }, { + "resultType": 0, + "index": 56 + }, { + "resultType": 0, + "index": 57 + }, { + "resultType": 0, + "index": 58 + }, { + "resultType": 0, + "index": 59 + }, { + "resultType": 0, + "index": 60 + }, { + "resultType": 0, + "index": 61 + }, { + "resultType": 0, + "index": 62 + }, { + "resultType": 0, + "index": 63 + }, { + "resultType": 0, + "index": 64 + }, { + "resultType": 0, + "index": 65 + }, { + "resultType": 0, + "index": 66 + }, { + "resultType": 0, + "index": 67 + }, { + "resultType": 0, + "index": 68 + }, { + "resultType": 0, + "index": 69 + }], + "resultCount": 77, + "labels": ["CellAnime0", "CellAnime1", "CellAnime2", "CellAnime3", "CellAnime4", "CellAnime5", "CellAnime6", "CellAnime7", "CellAnime8", "CellAnime9", "CellAnime10", "CellAnime11", "CellAnime12", "CellAnime13", "CellAnime14", "CellAnime15", "CellAnime16", "CellAnime17", "CellAnime18", "CellAnime19", "CellAnime20", "CellAnime21", "CellAnime22", "CellAnime23", "CellAnime24", "CellAnime25", "CellAnime26", "CellAnime27", "CellAnime28", "CellAnime29", "CellAnime30", "CellAnime31", "CellAnime32", "CellAnime33", "CellAnime34", "CellAnime35", "CellAnime36", "CellAnime37", "CellAnime38", "CellAnime39", "CellAnime40", "CellAnime41", "CellAnime42", "CellAnime43", "CellAnime44", "CellAnime45", "CellAnime46", "CellAnime47", "CellAnime48", "CellAnime49", "CellAnime50", "CellAnime51", "CellAnime52", "CellAnime53", "CellAnime54", "CellAnime55", "CellAnime56", "CellAnime57", "CellAnime58", "CellAnime59", "CellAnime60"], + "labelCount": 61 +} \ No newline at end of file diff --git a/res/graphics/naming_screen/naming_screen_sprites_cell.json b/res/graphics/naming_screen/naming_screen_sprites_cell.json new file mode 100644 index 0000000000..a978c0ffc5 --- /dev/null +++ b/res/graphics/naming_screen/naming_screen_sprites_cell.json @@ -0,0 +1,2610 @@ +{ + "labelEnabled": true, + "extended": false, + "vramTransferEnabled": false, + "cellCount": 70, + "mappingType": 0, + "cells": [{ + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 9 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 0, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 9 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 16, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 9 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 32, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 9 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 48, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 9 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 64, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 9 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 80, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 9 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 96, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 7 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 504, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 112, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 11 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 128, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 32, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 144, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 11 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 148, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 32, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 164, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 11 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 168, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 32, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 184, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 11 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 188, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 32, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 204, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 13 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 0, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 32, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 208, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 13 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 216, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 32, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 232, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 13 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 48, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 32, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 240, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 13 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 248, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 32, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 264, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 62 + }, + "oamCount": 13, + "OAM": [{ + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 496, + "RotationScaling": 0, + "Size": 3 + }, + "Attr2": { + "CharName": 272, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 48, + "RotationScaling": 0, + "Size": 3 + }, + "Attr2": { + "CharName": 304, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 112, + "RotationScaling": 0, + "Size": 3 + }, + "Attr2": { + "CharName": 336, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 240, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 176, + "RotationScaling": 0, + "Size": 3 + }, + "Attr2": { + "CharName": 368, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 16, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 496, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 400, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 16, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 16, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 408, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 16, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 48, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 416, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 16, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 80, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 424, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 16, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 112, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 432, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 16, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 144, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 440, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 16, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 176, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 448, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 16, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 208, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 456, + "Priority": 0, + "Palette": 2 + } + }, { + "Attr0": { + "YCoordinate": 32, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 196, + "RotationScaling": 0, + "Size": 3 + }, + "Attr2": { + "CharName": 464, + "Priority": 0, + "Palette": 2 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 6 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 496, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": true, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 9 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 254, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 1, + "RotationScaling": 16, + "Size": 2 + }, + "Attr2": { + "CharName": 500, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 1, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 500, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": true, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 11 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 5, + "RotationScaling": 8, + "Size": 2 + }, + "Attr2": { + "CharName": 508, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 508, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": true, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 13 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 15, + "RotationScaling": 8, + "Size": 2 + }, + "Attr2": { + "CharName": 508, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 1, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 508, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 5 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 0 + }, + "Attr2": { + "CharName": 524, + "Priority": 0, + "Palette": 2 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 6 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 526, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 6 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 530, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 6 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 534, + "Priority": 0, + "Palette": 3 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 6 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 538, + "Priority": 0, + "Palette": 3 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 542, + "Priority": 0, + "Palette": 3 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 558, + "Priority": 0, + "Palette": 3 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 574, + "Priority": 0, + "Palette": 3 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 590, + "Priority": 0, + "Palette": 3 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 606, + "Priority": 0, + "Palette": 4 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 622, + "Priority": 0, + "Palette": 4 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 638, + "Priority": 0, + "Palette": 4 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 654, + "Priority": 0, + "Palette": 5 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 670, + "Priority": 0, + "Palette": 5 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 686, + "Priority": 0, + "Palette": 5 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 3 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 0 + }, + "Attr2": { + "CharName": 702, + "Priority": 0, + "Palette": 0 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 703, + "Priority": 0, + "Palette": 6 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 703, + "Priority": 0, + "Palette": 5 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 11 + }, + "oamCount": 2, + "OAM": [{ + "Attr0": { + "YCoordinate": 250, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 703, + "Priority": 0, + "Palette": 6 + } + }, { + "Attr0": { + "YCoordinate": 250, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 703, + "Priority": 0, + "Palette": 5 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 719, + "Priority": 0, + "Palette": 7 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 735, + "Priority": 0, + "Palette": 7 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 751, + "Priority": 0, + "Palette": 7 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 767, + "Priority": 0, + "Palette": 3 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 783, + "Priority": 0, + "Palette": 8 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 799, + "Priority": 0, + "Palette": 8 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 12 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 815, + "Priority": 0, + "Palette": 8 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 3 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 0 + }, + "Attr2": { + "CharName": 831, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": true, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 3 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 504, + "RotationScaling": 8, + "Size": 0 + }, + "Attr2": { + "CharName": 831, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": true, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 3 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 16, + "Size": 0 + }, + "Attr2": { + "CharName": 831, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": true, + "vFlip": true, + "hvFlip": true, + "boundingRect": false, + "boundingSphereRadius": 3 + }, + "oamCount": 1, + "OAM": [{ + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 504, + "RotationScaling": 24, + "Size": 0 + }, + "Attr2": { + "CharName": 831, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": true, + "vFlip": true, + "hvFlip": true, + "boundingRect": false, + "boundingSphereRadius": 6 + }, + "oamCount": 4, + "OAM": [{ + "Attr0": { + "YCoordinate": 8, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 8, + "RotationScaling": 24, + "Size": 0 + }, + "Attr2": { + "CharName": 832, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 8, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 16, + "Size": 0 + }, + "Attr2": { + "CharName": 832, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 8, + "RotationScaling": 8, + "Size": 0 + }, + "Attr2": { + "CharName": 832, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 0 + }, + "Attr2": { + "CharName": 832, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": true, + "vFlip": true, + "hvFlip": true, + "boundingRect": false, + "boundingSphereRadius": 6 + }, + "oamCount": 4, + "OAM": [{ + "Attr0": { + "YCoordinate": 8, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 8, + "RotationScaling": 24, + "Size": 0 + }, + "Attr2": { + "CharName": 833, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 8, + "RotationScaling": 8, + "Size": 0 + }, + "Attr2": { + "CharName": 833, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 8, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 16, + "Size": 0 + }, + "Attr2": { + "CharName": 833, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 0 + }, + "Attr2": { + "CharName": 833, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": true, + "vFlip": true, + "hvFlip": true, + "boundingRect": false, + "boundingSphereRadius": 6 + }, + "oamCount": 4, + "OAM": [{ + "Attr0": { + "YCoordinate": 8, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 8, + "RotationScaling": 24, + "Size": 0 + }, + "Attr2": { + "CharName": 834, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 8, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 16, + "Size": 0 + }, + "Attr2": { + "CharName": 834, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 8, + "RotationScaling": 8, + "Size": 0 + }, + "Attr2": { + "CharName": 834, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 0 + }, + "Attr2": { + "CharName": 834, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": true, + "vFlip": true, + "hvFlip": true, + "boundingRect": false, + "boundingSphereRadius": 6 + }, + "oamCount": 4, + "OAM": [{ + "Attr0": { + "YCoordinate": 8, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 8, + "RotationScaling": 24, + "Size": 0 + }, + "Attr2": { + "CharName": 835, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 8, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 16, + "Size": 0 + }, + "Attr2": { + "CharName": 835, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 8, + "RotationScaling": 8, + "Size": 0 + }, + "Attr2": { + "CharName": 835, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 0 + }, + "Attr2": { + "CharName": 835, + "Priority": 0, + "Palette": 1 + } + }] + }, { + "cellAttrs": { + "hFlip": true, + "vFlip": true, + "hvFlip": true, + "boundingRect": false, + "boundingSphereRadius": 6 + }, + "oamCount": 4, + "OAM": [{ + "Attr0": { + "YCoordinate": 8, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 8, + "RotationScaling": 24, + "Size": 0 + }, + "Attr2": { + "CharName": 836, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 8, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 16, + "Size": 0 + }, + "Attr2": { + "CharName": 836, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 8, + "RotationScaling": 8, + "Size": 0 + }, + "Attr2": { + "CharName": 836, + "Priority": 0, + "Palette": 1 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 0 + }, + "Attr2": { + "CharName": 836, + "Priority": 0, + "Palette": 1 + } + }] + }], + "labels": ["CellAnime0", "CellAnime1", "CellAnime2", "CellAnime3", "CellAnime4", "CellAnime5", "CellAnime6", "CellAnime7", "CellAnime8", "CellAnime9", "CellAnime10", "CellAnime11", "CellAnime12", "CellAnime13", "CellAnime14", "CellAnime15", "CellAnime16", "CellAnime17", "CellAnime18", "CellAnime19", "CellAnime20", "CellAnime21", "CellAnime22", "CellAnime23", "CellAnime24", "CellAnime25", "CellAnime26", "CellAnime27", "CellAnime28", "CellAnime29", "CellAnime30", "CellAnime31", "CellAnime32", "CellAnime33", "CellAnime34", "CellAnime35", "CellAnime36", "CellAnime37", "CellAnime38", "CellAnime39", "CellAnime40", "CellAnime41", "CellAnime42", "CellAnime43", "CellAnime44", "CellAnime45", "CellAnime46", "CellAnime47", "CellAnime48", "CellAnime49", "CellAnime50", "CellAnime51", "CellAnime52", "CellAnime53", "CellAnime54", "CellAnime55", "CellAnime56", "CellAnime57", "CellAnime58", "CellAnime59", "CellAnime60"], + "labelCount": 61 +} \ No newline at end of file diff --git a/res/graphics/naming_screen/naming_screen_unk_sprite.png b/res/graphics/naming_screen/naming_screen_unk_sprite.png new file mode 100644 index 0000000000..8348a494f1 Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_unk_sprite.png differ diff --git a/res/graphics/naming_screen/naming_screen_unk_sprite_anim.json b/res/graphics/naming_screen/naming_screen_unk_sprite_anim.json new file mode 100644 index 0000000000..f11c3ceb5d --- /dev/null +++ b/res/graphics/naming_screen/naming_screen_unk_sprite_anim.json @@ -0,0 +1,76 @@ +{ + "labelEnabled": true, + "sequenceCount": 3, + "frameCount": 9, + "sequences": [{ + "frameCount": 3, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 4, + "resultId": 0 + }, { + "frameDelay": 4, + "resultId": 1 + }, { + "frameDelay": 20, + "resultId": 2 + }] + }, { + "frameCount": 1, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 4, + "resultId": 3 + }] + }, { + "frameCount": 5, + "loopStartFrame": 0, + "animationElement": 0, + "animationType": 1, + "playbackMode": 1, + "frameData": [{ + "frameDelay": 2, + "resultId": 3 + }, { + "frameDelay": 2, + "resultId": 4 + }, { + "frameDelay": 4, + "resultId": 5 + }, { + "frameDelay": 4, + "resultId": 4 + }, { + "frameDelay": 4, + "resultId": 3 + }] + }], + "animationResults": [{ + "resultType": 0, + "index": 0 + }, { + "resultType": 0, + "index": 1 + }, { + "resultType": 0, + "index": 2 + }, { + "resultType": 0, + "index": 3 + }, { + "resultType": 0, + "index": 4 + }, { + "resultType": 0, + "index": 5 + }], + "resultCount": 6, + "labels": ["CellAnime1", "CellAnime0", "CellAnime2"], + "labelCount": 3 +} \ No newline at end of file diff --git a/res/graphics/naming_screen/naming_screen_unk_sprite_cell.json b/res/graphics/naming_screen/naming_screen_unk_sprite_cell.json new file mode 100644 index 0000000000..08501a3f17 --- /dev/null +++ b/res/graphics/naming_screen/naming_screen_unk_sprite_cell.json @@ -0,0 +1,1070 @@ +{ + "labelEnabled": true, + "extended": false, + "vramTransferEnabled": false, + "cellCount": 6, + "mappingType": 0, + "cells": [{ + "cellAttrs": { + "hFlip": true, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 41 + }, + "oamCount": 20, + "OAM": [{ + "Attr0": { + "YCoordinate": 56, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 112, + "RotationScaling": 8, + "Size": 2 + }, + "Attr2": { + "CharName": 0, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 24, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 112, + "RotationScaling": 8, + "Size": 2 + }, + "Attr2": { + "CharName": 0, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 56, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 384, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 0, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 24, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 2 + }, + "Attr1": { + "XCoordinate": 384, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 0, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 88, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 96, + "RotationScaling": 8, + "Size": 2 + }, + "Attr2": { + "CharName": 8, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 96, + "RotationScaling": 8, + "Size": 2 + }, + "Attr2": { + "CharName": 16, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 88, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 64, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 32, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 88, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 32, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 32, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 88, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 32, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 88, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 480, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 32, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 88, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 448, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 32, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 88, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 416, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 32, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 88, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 384, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 8, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 64, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 40, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 32, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 40, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 0, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 40, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 480, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 40, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 448, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 40, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 416, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 40, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 248, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 384, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 16, + "Priority": 0, + "Palette": 0 + } + }] + }, { + "cellAttrs": { + "hFlip": true, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 37 + }, + "oamCount": 9, + "OAM": [{ + "Attr0": { + "YCoordinate": 232, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 112, + "RotationScaling": 8, + "Size": 2 + }, + "Attr2": { + "CharName": 48, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 232, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 80, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 64, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 232, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 48, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 64, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 232, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 16, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 64, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 232, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 496, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 64, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 232, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 464, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 64, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 232, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 432, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 64, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 232, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 400, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 64, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 232, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 368, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 48, + "Priority": 0, + "Palette": 0 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 0 + }, + "oamCount": 0, + "OAM": [] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 29 + }, + "oamCount": 7, + "OAM": [{ + "Attr0": { + "YCoordinate": 27, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 52, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 72, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 27, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 30, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 76, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 48, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 80, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 80, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 88, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 496, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 96, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 0, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 16, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 104, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 27, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 9, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 112, + "Priority": 0, + "Palette": 0 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 28 + }, + "oamCount": 7, + "OAM": [{ + "Attr0": { + "YCoordinate": 24, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 52, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 72, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 24, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 30, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 76, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 253, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 48, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 80, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 253, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 80, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 88, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 253, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 496, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 96, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 253, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 16, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 104, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 24, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 9, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 112, + "Priority": 0, + "Palette": 0 + } + }] + }, { + "cellAttrs": { + "hFlip": false, + "vFlip": false, + "hvFlip": false, + "boundingRect": false, + "boundingSphereRadius": 28 + }, + "oamCount": 7, + "OAM": [{ + "Attr0": { + "YCoordinate": 22, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 52, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 72, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 22, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 30, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 76, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 251, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 48, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 80, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 251, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 80, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 88, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 251, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 496, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 96, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 251, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 1 + }, + "Attr1": { + "XCoordinate": 16, + "RotationScaling": 0, + "Size": 2 + }, + "Attr2": { + "CharName": 104, + "Priority": 0, + "Palette": 0 + } + }, { + "Attr0": { + "YCoordinate": 22, + "Rotation": false, + "SizeDisable": false, + "Mode": 0, + "Mosaic": false, + "Colours": 16, + "Shape": 0 + }, + "Attr1": { + "XCoordinate": 9, + "RotationScaling": 0, + "Size": 1 + }, + "Attr2": { + "CharName": 112, + "Priority": 0, + "Palette": 0 + } + }] + }], + "labels": ["CellAnime1", "CellAnime0", "CellAnime2"], + "labelCount": 3 +} \ No newline at end of file diff --git a/res/graphics/naming_screen/naming_screen_unk_tiles.png b/res/graphics/naming_screen/naming_screen_unk_tiles.png new file mode 100644 index 0000000000..d505b9b87d Binary files /dev/null and b/res/graphics/naming_screen/naming_screen_unk_tiles.png differ diff --git a/res/prebuilt/data/meson.build b/res/prebuilt/data/meson.build index 6f9aa4da29..ecfb10f067 100644 --- a/res/prebuilt/data/meson.build +++ b/res/prebuilt/data/meson.build @@ -51,7 +51,6 @@ prebuilt_files = [ 'minihamabe.nsbtx', 'minimum.nsbtx', 'minirhana.nsbtx', - 'namein.narc', 'nfont.NCGR', 'nfont.NCLR', 'pc.nsbca', diff --git a/res/prebuilt/data/namein.narc b/res/prebuilt/data/namein.narc deleted file mode 100644 index 7287dfe87c..0000000000 Binary files a/res/prebuilt/data/namein.narc and /dev/null differ diff --git a/res/text/generic_names.gmm b/res/text/generic_names.gmm index 226489fbd9..26b5495f6c 100644 --- a/res/text/generic_names.gmm +++ b/res/text/generic_names.gmm @@ -1,147 +1,147 @@ - + used Plato - + used Ash - + used Nic - + used Jimmy - + used Duncan - + used Todd - + used Ross - + used Steven - + used Darrell - + used Reed - + used Chris - + used Brad - + used Dwight - + used Randy - + used Andy - + used Joey - + used Eric - + used Mark - + used Plato - + used Joelle - + used Britney - + used Kelli - + used Nina - + used Heidi - + used Miriam - + used Teresa - + used Aubrey - + used Kelly - + used Naomi - + used Abby - + used Denise - + used Tamara - + used Linda - + used Faith - + used Mari - + used Maggie @@ -353,11 +353,11 @@ used Dawn - + used Pearl - + used Diamond diff --git a/src/applications/naming_screen.c b/src/applications/naming_screen.c index 5bcd0a977f..27f527b24f 100644 --- a/src/applications/naming_screen.c +++ b/src/applications/naming_screen.c @@ -9,6 +9,8 @@ #include "struct_defs/struct_02099F80.h" +#include "pch/global_pch.h" + #include "bg_window.h" #include "char_transfer.h" #include "charcode.h" @@ -48,8 +50,15 @@ #include "unk_0201567C.h" #include "vram_transfer.h" +#include "res/graphics/naming_screen/namein.naix.h" +#include "res/text/bank/generic_names.h" #include "res/text/bank/naming_screen.h" +// if these are modified, NamingScreen_InitializeCharsGraphics +// and calls to NamingScreen_PrintChars need to be adjusted. +#define NMS_NUM_ROWS 6 +#define NMS_NUM_COLS 13 + enum NamingScreenControlChars { NMS_CONTROL_DAKU = 0xD001, NMS_CONTROL_HANDAKU, @@ -73,10 +82,10 @@ enum NamingScreenAppState { }; enum NamingScreenState { - NMS_STATE_PLACEHOLDER_4 = 4, - NMS_STATE_PLACEHOLDER_5, - NMS_STATE_PLACEHOLDER_6, - NMS_STATE_PLACEHOLDER_7, + NMS_STATE_PROCESS_INPUTS = 4, + NMS_STATE_PRINT_BATTLE_MESSAGE, + NMS_STATE_WAIT_BATTLE_MESSAGE, + NMS_STATE_START_FADE_OUT, }; enum ChangeCharsState { @@ -95,8 +104,47 @@ enum NamingScreenSprite { NMS_SPRITE_JP_UNUSED_2_BUTTON, NMS_SPRITE_BACK_BUTTON, NMS_SPRITE_OK_BUTTON, + // all sprites before this one are treated as children of this one, + // and their positions will move when the overlay moves NMS_SPRITE_OVERLAY, NMS_SPRITE_CURSOR, + NMS_SPRITE_COUNT, +}; + +#define NMS_SPRITE_BUTTON_START NMS_SPRITE_BACK_BUTTON +#define NMS_SPRITE_BUTTON_END NMS_SPRITE_OK_BUTTON +#define NMS_SPRITE_PAGE_BUTTON_START NMS_SPRITE_UPPER_BUTTON +#define NMS_SPRITE_PAGE_BUTTON_END NMS_SPRITE_OTHERS_BUTTON + +enum NamingScreenWindows { + // there are two keyboards. when transitioning, both + // are active (one moves in the other moves out). + // otherwise, only one is active. + // these must stay beside each other. + NMS_WINDOW_KEYBOARD_0 = 0, + NMS_WINDOW_KEYBOARD_1, + // this window is never used, only created and destroyed + NMS_WINDOW_DUMMY, + NMS_WINDOW_ENTERED_TEXT, + // these windows are used in PrintCharOnWindowAndOBJ, but I don't know what they do. + // commenting out that function, and making these never get used, the result is that + // nothing changes + NMS_WINDOW_UNK_0, + NMS_WINDOW_UNK_1, + NMS_WINDOW_UNK_2, + NMS_WINDOW_UNK_3, + NMS_WINDOW_GROUP_TEXT, + NMS_WINDOW_PROMPT, + NMS_WINDOW_COUNT, +}; + +enum NamingScreenDpadMovement { + NMS_DPAD_MOVEMENT_NONE = 0, + NMS_DPAD_MOVEMENT_UP, + NMS_DPAD_MOVEMENT_DOWN, + NMS_DPAD_MOVEMENT_LEFT, + NMS_DPAD_MOVEMENT_RIGHT, + NMS_DPAD_MOVEMENT_COUNT, }; typedef struct NamingScreenCursor { @@ -119,21 +167,21 @@ typedef struct NamingScreen { Options *options; NamingScreenCursor keyboardCursor; u16 plttGlowEffectAngle; - u16 keyboardChars[6][13]; - u16 unk_D6; + charcode_t keyboardChars[NMS_NUM_ROWS][NMS_NUM_COLS]; + u16 dummy5; charcode_t entryBuf[32]; charcode_t entryBufBak[32]; u16 textCursorPos; - u16 tmpBuf[3]; + charcode_t tmpBuf[3]; BgConfig *bgConfig; - BOOL unk_164; + BOOL dummy4; StringTemplate *strTemplate; MessageLoader *namingScreenMsgLoader; MessageLoader *genericNamesMsgLoader; MessageLoader *battleStringsMsgLoader; Strbuf *promptString; Strbuf *unkJapaneseString; - Strbuf *unk_180; + Strbuf *battleMessageStrbuf; Strbuf *groupTextStrbuf; SpriteList *spriteList; G2dRenderer g2dRenderer; @@ -141,12 +189,14 @@ typedef struct NamingScreen { SpriteResource *spriteResources[2][4]; SpriteResourcesHeader mainSpriteResourceHeader; SpriteResourcesHeader subResourceSpriteHeader; + // I don't know where 14 comes from. + // only the first 9 elements are used. (NMS_SPRITE_COUNT) Sprite *uiSprites[14]; Sprite *textCursorSprites[12]; Sprite *entitySprite[2]; - SysTask *tasks[7]; - Window windows[10]; - int unk_4BC; + SysTask *spriteFollowTasks[NMS_SPRITE_OVERLAY]; + Window windows[NMS_WINDOW_COUNT]; + int battleMessagePrinter; union { enum NamingScreenState main; enum ChangeCharsState changeChars; @@ -160,7 +210,7 @@ typedef struct NamingScreen { int dummy0; int dummy1; int dummy2; - BOOL spritesToUpdate[7]; + BOOL spritesToUpdate[NMS_SPRITE_OVERLAY]; void *charDataAlloc; NNSG2dCharacterData *charData; void *monIconRawCharData; @@ -202,17 +252,22 @@ typedef struct NamingScreenSpriteAnim { int priority; } NamingScreenSpriteAnim; +typedef struct DpadMovement { + int x; + int y; +} DpadMovement; + static BOOL NamingScreen_Init(ApplicationManager *appMan, int *state); static BOOL NamingScreen_Main(ApplicationManager *appMan, int *state); static BOOL NamingScreen_Exit(ApplicationManager *appMan, int *state); static void NamingScreen_VBlankCallback(void *unused); static void NamingScreen_InitGraphicsBanks(void); static void NamingScreen_InitBgs(BgConfig *bgConfig); -static void sub_0208765C(BgConfig *param0, Window *param1); +static void NamingScreen_FreeBgs(BgConfig *bgConfig, Window *windows); static void NamingScreen_LoadGraphicsFromNarc(NamingScreen *namingScreen, NARC *narc); static void NamingScreen_AnimateChangeChars( BgConfig *bgConfig, - Window *window, + Window *windows, enum ChangeCharsState *statePtr, int currentCharsIdx, enum BgLayer *bgLayerPtr, @@ -227,7 +282,7 @@ static void NamingScreen_InitSprites(NamingScreen *namingScreen); static void NamingScreen_TransferChars(void); static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationManager *appMan, NARC *narc); static void NamingScreen_ProcessDirectionInputs(NamingScreen *namingScreen); -static void sub_02088514(u16 *param0); +static void NamingScreen_PaletteGlowEffect(u16 *param0); static void NamingScreen_PrintChars( Window *window, const charcode_t *charCodes, @@ -267,8 +322,10 @@ static void NamingScreen_InitializeCharsGraphics( int param2, TextColor param3, void *rawCharData); -static void NamingScreen_UpdateCursorSpritePosition(NamingScreen *namingScreen, int dpadMovement); -static void NamingScreen_UpdateSpriteAnimations(int param0[], Sprite **param1, int param2); +static void NamingScreen_UpdateCursorSpritePosition( + NamingScreen *namingScreen, + enum NamingScreenDpadMovement dpadMovement); +static void NamingScreen_UpdateSpriteAnimations(int param0[], Sprite **sprites, int unused); static void NamingScreen_SubspritePosControllerTask(SysTask *task, void *paramsPtr); static void NamingScreen_WiggleOverlayTask(SysTask *task, void *paramsPtr); static void NamingScreen_LoadMonIcon( @@ -277,16 +334,20 @@ static void NamingScreen_LoadMonIcon( enum Species monSpecies, int monForm); static void NamingScreen_ToggleEngineLayers(BOOL enable); -static void sub_02087544(NamingScreen *param0, ApplicationManager *appMan); +static void NamingScreen_PrepareBattleMessage(NamingScreen *namingScreen, ApplicationManager *appMan); static void NamingScreen_InitIconSprite(NamingScreen *namingScreen, AffineSpriteListTemplate *template); -static void sub_02086E6C(NamingScreen *param0, NamingScreenArgs *param1); -static void NamingScreen_PrintMessageOnWindowLeftAlign(Window *param0, int param1, Strbuf *param2); +static void NamingScreen_UseDefaultName(NamingScreen *namingScreen, NamingScreenArgs *args); +static void NamingScreen_PrintMessageOnWindowLeftAlign(Window *window, int unused, Strbuf *str); static void NamingScreen_PlaceCursorSprite(NamingScreen *namingScreen); static enum NamingScreenAppState NamingScreen_ProcessInputs( NamingScreen *namingScreen, enum NamingScreenAppState appState); -static int sub_02086F14(u16 *param0); -static void *NamingScreen_PrintStringOnWindowAndGetPixelBuffer(Window *param0, Strbuf *param1, u8 param2, TextColor param3); +static BOOL NamingScreen_IsRawStringAllSpaces(charcode_t *rawChars); +static void *NamingScreen_PrintStringOnWindowAndGetPixelBuffer( + Window *window, + Strbuf *string, + u8 fontId, + TextColor color); static BOOL NamingScreen_ProcessTouchInputs(NamingScreen *namingScreen); static const NamingScreenSpriteAnim sSpriteAnimations[] = { @@ -765,7 +826,7 @@ static const charcode_t sCharCodesNumpad345[] = { CHAR_EOS, }; -const charcode_t *sCharCodes[][5] = { +static const charcode_t *sCharCodes[][5] = { { sCharCodesUpper0, sCharCodesUpper1, @@ -929,7 +990,8 @@ static const u8 sCharsBgColor[4] = { 10, }; -const charcode_t sDummy0[] = { +// these need to be globals for some reason. +const charcode_t gNamingScreenDummy0[] = { CHAR_HIRAGANA_A, CHAR_HIRAGANA_NA, CHAR_HIRAGANA_TA, @@ -943,7 +1005,7 @@ const charcode_t sDummy0[] = { CHAR_EOS, }; -const charcode_t sDummy1[] = { +const charcode_t gNamingScreenDummy1[] = { CHAR_KATAKANA_PO, CHAR_KATAKANA_KE, CHAR_KATAKANA_MO, @@ -961,7 +1023,7 @@ const charcode_t sDummy1[] = { CHAR_EOS, }; -const charcode_t sDummy2[] = { +const charcode_t gNamingScreenDummy2[] = { CHAR_KATAKANA_BO, CHAR_KATAKANA_SOKUON, CHAR_KATAKANA_KU, @@ -977,9 +1039,9 @@ const charcode_t sDummy2[] = { }; static const charcode_t *sDummy3[] = { - sDummy0, - sDummy1, - sDummy2, + gNamingScreenDummy0, + gNamingScreenDummy1, + gNamingScreenDummy2, }; static const int sPromptTextIndices[] = { @@ -1055,7 +1117,7 @@ static BOOL NamingScreen_Init(ApplicationManager *appMan, int *state) NamingScreen_InitSprites(namingScreen); NamingScreen_InitWindows(namingScreen, appMan, narc); NamingScreen_PrintLastCharOfEntryBuf( - &namingScreen->windows[4], + &namingScreen->windows[NMS_WINDOW_UNK_0], namingScreen->entryBuf, namingScreen->textCursorPos, namingScreen->tmpBuf, @@ -1144,27 +1206,34 @@ static BOOL NamingScreen_Main(ApplicationManager *appMan, int *state) break; case NMS_APP_STATE_RUNNING: switch (namingScreen->state.main) { - case NMS_STATE_PLACEHOLDER_4: + case NMS_STATE_PROCESS_INPUTS: *state = NamingScreen_ProcessInputs(namingScreen, *state); NamingScreen_PlaceCursorSprite(namingScreen); break; - case NMS_STATE_PLACEHOLDER_5: - sub_02087544(namingScreen, appMan); - Window_FillTilemap(&namingScreen->windows[9], 0x0f); - Window_DrawMessageBoxWithScrollCursor(&namingScreen->windows[9], 0, 32 * 8, 10); - namingScreen->unk_4BC = Text_AddPrinterWithParams(&namingScreen->windows[9], FONT_MESSAGE, namingScreen->unk_180, 0, 0, TEXT_SPEED_FAST, NULL); - Window_CopyToVRAM(&namingScreen->windows[9]); - namingScreen->state.main = NMS_STATE_PLACEHOLDER_6; + case NMS_STATE_PRINT_BATTLE_MESSAGE: + NamingScreen_PrepareBattleMessage(namingScreen, appMan); + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_PROMPT], 0x0f); + Window_DrawMessageBoxWithScrollCursor(&namingScreen->windows[NMS_WINDOW_PROMPT], 0, 32 * 8, 10); + namingScreen->battleMessagePrinter = Text_AddPrinterWithParams( + &namingScreen->windows[NMS_WINDOW_PROMPT], + FONT_MESSAGE, + namingScreen->battleMessageStrbuf, + 0, + 0, + TEXT_SPEED_FAST, + NULL); + Window_CopyToVRAM(&namingScreen->windows[NMS_WINDOW_PROMPT]); + namingScreen->state.main = NMS_STATE_WAIT_BATTLE_MESSAGE; break; - case NMS_STATE_PLACEHOLDER_6: - if (Text_IsPrinterActive(namingScreen->unk_4BC) == 0) { + case NMS_STATE_WAIT_BATTLE_MESSAGE: + if (Text_IsPrinterActive(namingScreen->battleMessagePrinter) == 0) { Sound_PlayEffect(SEQ_SE_DP_PIRORIRO); namingScreen->spritesToUpdate[NMS_SPRITE_OK_BUTTON]++; namingScreen->delayUpdateCounter = 0; - namingScreen->state.main = NMS_STATE_PLACEHOLDER_7; + namingScreen->state.main = NMS_STATE_START_FADE_OUT; } break; - case NMS_STATE_PLACEHOLDER_7: + case NMS_STATE_START_FADE_OUT: namingScreen->delayUpdateCounter++; if (namingScreen->delayUpdateCounter > 30) { @@ -1183,7 +1252,7 @@ static BOOL NamingScreen_Main(ApplicationManager *appMan, int *state) NamingScreen_AnimateChangeChars( namingScreen->bgConfig, - &namingScreen->windows[0], + &namingScreen->windows[NMS_WINDOW_KEYBOARD_0], &namingScreen->state.changeChars, namingScreen->currentCharsIdx, &namingScreen->freeCharsBgLayer, @@ -1194,7 +1263,7 @@ static BOOL NamingScreen_Main(ApplicationManager *appMan, int *state) namingScreen->spritesToUpdate, namingScreen->uiSprites, namingScreen->currentCharsIdx); - sub_02088514(&namingScreen->plttGlowEffectAngle); + NamingScreen_PaletteGlowEffect(&namingScreen->plttGlowEffectAngle); break; case NMS_APP_STATE_WAIT_FADE_OUT: if (IsScreenFadeDone()) { @@ -1267,56 +1336,66 @@ static enum NamingScreenAppState NamingScreen_ProcessInputs( return appState; } -static void sub_02086E6C(NamingScreen *namingScreen, NamingScreenArgs *args) +#define RANDOM_NAME(TYPE) (TYPE##_First + LCRNG_Next() % (TYPE##_Last - TYPE##_First + 1)) + +static void NamingScreen_UseDefaultName(NamingScreen *namingScreen, NamingScreenArgs *args) { if (namingScreen->type == NAMING_SCREEN_TYPE_PLAYER) { Strbuf *strbuf; if (namingScreen->playerGenderOrMonSpecies == GENDER_MALE) { - strbuf = MessageLoader_GetNewStrbuf(namingScreen->genericNamesMsgLoader, 0 + LCRNG_Next() % 18); + strbuf = MessageLoader_GetNewStrbuf( + namingScreen->genericNamesMsgLoader, + RANDOM_NAME(GenericNames_PlayerMale)); } else if (namingScreen->playerGenderOrMonSpecies == GENDER_FEMALE) { - strbuf = MessageLoader_GetNewStrbuf(namingScreen->genericNamesMsgLoader, 18 + LCRNG_Next() % 18); + strbuf = MessageLoader_GetNewStrbuf( + namingScreen->genericNamesMsgLoader, + RANDOM_NAME(GenericNames_PlayerFemale)); } Strbuf_Copy(args->textInputStr, strbuf); Strbuf_Free(strbuf); - Strbuf_ToChars(args->textInputStr, args->unk_1C, 10); + Strbuf_ToChars(args->textInputStr, args->nameInputRaw, 10); } else if (namingScreen->type == NAMING_SCREEN_TYPE_RIVAL) { Strbuf *strbuf; - strbuf = MessageLoader_GetNewStrbuf(namingScreen->genericNamesMsgLoader, 88 + (LCRNG_Next() % 2)); + strbuf = MessageLoader_GetNewStrbuf( + namingScreen->genericNamesMsgLoader, + RANDOM_NAME(GenericNames_Rival)); Strbuf_Copy(args->textInputStr, strbuf); Strbuf_Free(strbuf); - Strbuf_ToChars(args->textInputStr, args->unk_1C, 10); + Strbuf_ToChars(args->textInputStr, args->nameInputRaw, 10); } else { - args->unk_14 = 1; + args->returnCode = NAMING_SCREEN_CODE_NO_INPUT; } } -static int sub_02086F14(u16 *param0) -{ - int v0 = 1; - int v1; +#undef RANDOM_NAME - for (v1 = 0;; v1++) { - if (param0[v1] == 0xffff) { +static BOOL NamingScreen_IsRawStringAllSpaces(charcode_t *rawChars) +{ + BOOL isAllSpaces = TRUE; + int i; + + for (i = 0;; i++) { + if (rawChars[i] == CHAR_EOS) { break; } - if (param0[v1] != 0x1de) { - v0 = 0; + if (rawChars[i] != CHAR_SPACE) { + isAllSpaces = FALSE; } } - return v0; + return isAllSpaces; } static BOOL NamingScreen_Exit(ApplicationManager *appMan, int *unusedState) { NamingScreen *namingScreen = ApplicationManager_Data(appMan); NamingScreenArgs *namingScreenArgs = (NamingScreenArgs *)ApplicationManager_Args(appMan); - int v2; + int i; namingScreen->entryBuf[namingScreen->textCursorPos] = CHAR_EOS; @@ -1328,27 +1407,29 @@ static BOOL NamingScreen_Exit(ApplicationManager *appMan, int *unusedState) Heap_Free(mon); } - if ((namingScreen->textCursorPos == 0) || (CharCode_Compare(namingScreen->entryBuf, namingScreen->entryBufBak) == 0) || sub_02086F14(namingScreen->entryBuf)) { - sub_02086E6C(namingScreen, namingScreenArgs); + if (namingScreen->textCursorPos == 0 + || CharCode_Compare(namingScreen->entryBuf, namingScreen->entryBufBak) == 0 + || NamingScreen_IsRawStringAllSpaces(namingScreen->entryBuf)) { + NamingScreen_UseDefaultName(namingScreen, namingScreenArgs); } else { CharCode_Copy(namingScreen->entryBufBak, namingScreen->entryBuf); - CharCode_Copy(namingScreenArgs->unk_1C, namingScreen->entryBuf); + CharCode_Copy(namingScreenArgs->nameInputRaw, namingScreen->entryBuf); Strbuf_CopyChars(namingScreenArgs->textInputStr, namingScreen->entryBuf); } Strbuf_Free(namingScreen->groupTextStrbuf); - for (v2 = 0; v2 < 7; v2++) { - SysTask_FinishAndFreeParam(namingScreen->tasks[v2]); + for (i = 0; i < NMS_SPRITE_OVERLAY; i++) { + SysTask_FinishAndFreeParam(namingScreen->spriteFollowTasks[i]); } - SpriteTransfer_ResetCharTransfer(namingScreen->spriteResources[0][0]); - SpriteTransfer_ResetCharTransfer(namingScreen->spriteResources[1][0]); - SpriteTransfer_ResetPlttTransfer(namingScreen->spriteResources[0][1]); - SpriteTransfer_ResetPlttTransfer(namingScreen->spriteResources[1][1]); + SpriteTransfer_ResetCharTransfer(namingScreen->spriteResources[0][SPRITE_RESOURCE_CHAR]); + SpriteTransfer_ResetCharTransfer(namingScreen->spriteResources[1][SPRITE_RESOURCE_CHAR]); + SpriteTransfer_ResetPlttTransfer(namingScreen->spriteResources[0][SPRITE_RESOURCE_PLTT]); + SpriteTransfer_ResetPlttTransfer(namingScreen->spriteResources[1][SPRITE_RESOURCE_PLTT]); - for (v2 = 0; v2 < 4; v2++) { - SpriteResourceCollection_Delete(namingScreen->spriteResourceCollections[v2]); + for (i = 0; i < 4; i++) { + SpriteResourceCollection_Delete(namingScreen->spriteResourceCollections[i]); } SpriteList_Delete(namingScreen->spriteList); @@ -1363,15 +1444,15 @@ static BOOL NamingScreen_Exit(ApplicationManager *appMan, int *unusedState) Bg_FreeTilemapBuffer(namingScreen->bgConfig, BG_LAYER_SUB_3); CharTransfer_Free(); PlttTransfer_Free(); - sub_0208765C(namingScreen->bgConfig, namingScreen->windows); + NamingScreen_FreeBgs(namingScreen->bgConfig, namingScreen->windows); Font_UseLazyGlyphAccess(FONT_SYSTEM); GX_SetVisibleWnd(GX_WNDMASK_NONE); Font_Free(FONT_SUBSCREEN); - if (namingScreen->unk_180) { - Strbuf_Free(namingScreen->unk_180); + if (namingScreen->battleMessageStrbuf) { + Strbuf_Free(namingScreen->battleMessageStrbuf); } Strbuf_Free(namingScreen->promptString); @@ -1384,40 +1465,43 @@ static BOOL NamingScreen_Exit(ApplicationManager *appMan, int *unusedState) SetVBlankCallback(NULL, NULL); Heap_Destroy(HEAP_ID_NAMING_SCREEN_APP); - { - gSystem.whichScreenIs3D = DS_SCREEN_MAIN; - GXLayers_SwapDisplay(); - } + gSystem.whichScreenIs3D = DS_SCREEN_MAIN; + GXLayers_SwapDisplay(); return TRUE; } -NamingScreenArgs *NamingScreenArgs_Init(enum HeapId heapID, enum NamingScreenType type, int param2, int maxChars, Options *options) +NamingScreenArgs *NamingScreenArgs_Init( + enum HeapId heapID, + enum NamingScreenType type, + int playerGenderOrMonSpecies, + int maxChars, + Options *options) { - NamingScreenArgs *v0 = (NamingScreenArgs *)Heap_AllocFromHeap(heapID, sizeof(NamingScreenArgs)); + NamingScreenArgs *args = (NamingScreenArgs *)Heap_AllocFromHeap(heapID, sizeof(NamingScreenArgs)); - v0->type = type; - v0->playerGenderOrMonSpecies = param2; - v0->maxChars = maxChars; - v0->unk_14 = 0; - v0->unk_1C[0] = 0xffff; - v0->textInputStr = Strbuf_Init(32, heapID); - v0->battleMsgID = 0; - v0->pcBoxes = NULL; - v0->monGender = 0; - v0->options = options; - v0->monForm = 0; + args->type = type; + args->playerGenderOrMonSpecies = playerGenderOrMonSpecies; + args->maxChars = maxChars; + args->returnCode = NAMING_SCREEN_CODE_OK; + args->nameInputRaw[0] = CHAR_EOS; + args->textInputStr = Strbuf_Init(32, heapID); + args->battleMsgID = 0; + args->pcBoxes = NULL; + args->monGender = GENDER_MALE; + args->options = options; + args->monForm = 0; - return v0; + return args; } -void NamingScreenArgs_Free(NamingScreenArgs *param0) +void NamingScreenArgs_Free(NamingScreenArgs *args) { - GF_ASSERT((param0->textInputStr) != NULL); - GF_ASSERT((param0) != NULL); + GF_ASSERT(args->textInputStr != NULL); + GF_ASSERT(args != NULL); - Strbuf_Free(param0->textInputStr); - Heap_Free(param0); + Strbuf_Free(args->textInputStr); + Heap_Free(args); } static void NamingScreen_VBlankCallback(void *unused) @@ -1566,7 +1650,7 @@ static void NamingScreen_InitCursorsAndChars(NamingScreen *namingScreen, Applica { NamingScreenArgs *namingScreenArgs = (NamingScreenArgs *)ApplicationManager_Args(appMan); - namingScreen->state.main = NMS_STATE_PLACEHOLDER_4; + namingScreen->state.main = NMS_STATE_PROCESS_INPUTS; NamingScreen_InitializeCharsPosition(namingScreen->charsPosition, BG_LAYER_MAIN_0); Bg_SetOffset( @@ -1630,7 +1714,7 @@ static void NamingScreen_InitCursorsAndChars(NamingScreen *namingScreen, Applica namingScreen->keyboardCursor.prevX = -1; namingScreen->keyboardCursor.prevY = -1; namingScreen->keyboardCursor.hasCharacterBeenEntered = FALSE; - namingScreen->keyboardCursor.ignoreInput = 0; + namingScreen->keyboardCursor.ignoreInput = FALSE; namingScreen->dummy0 = -1; namingScreen->dummy1 = 0; namingScreen->dummy2 = 0; @@ -1649,72 +1733,74 @@ static void NamingScreen_InitCursorsAndChars(NamingScreen *namingScreen, Applica } } -static void sub_02087544(NamingScreen *param0, ApplicationManager *appMan) +static void NamingScreen_PrepareBattleMessage(NamingScreen *namingScreen, ApplicationManager *appMan) { - Strbuf *v0 = NULL; - NamingScreenArgs *v1 = (NamingScreenArgs *)ApplicationManager_Args(appMan); + Strbuf *strbuf = NULL; + NamingScreenArgs *args = (NamingScreenArgs *)ApplicationManager_Args(appMan); - if (v1->battleMsgID != 0) { - int v2, v3; + if (args->battleMsgID != 0) { + int boxID, nextBoxID; - v0 = Strbuf_Init(200, HEAP_ID_NAMING_SCREEN_APP); - param0->unk_180 = NULL; - v2 = PCBoxes_GetCurrentBoxID(v1->pcBoxes); - v3 = PCBoxes_FirstEmptyBox(v1->pcBoxes); + strbuf = Strbuf_Init(200, HEAP_ID_NAMING_SCREEN_APP); + namingScreen->battleMessageStrbuf = NULL; + boxID = PCBoxes_GetCurrentBoxID(args->pcBoxes); + nextBoxID = PCBoxes_FirstEmptyBox(args->pcBoxes); - StringTemplate_SetPCBoxName(param0->strTemplate, 1, v1->pcBoxes, v2); + StringTemplate_SetPCBoxName(namingScreen->strTemplate, 1, args->pcBoxes, boxID); - if (v2 != v3) { - StringTemplate_SetPCBoxName(param0->strTemplate, 2, v1->pcBoxes, v3); - v1->battleMsgID += 2; + if (boxID != nextBoxID) { + StringTemplate_SetPCBoxName(namingScreen->strTemplate, 2, args->pcBoxes, nextBoxID); + args->battleMsgID += 2; } else { - StringTemplate_SetPCBoxName(param0->strTemplate, 2, v1->pcBoxes, v2); + StringTemplate_SetPCBoxName(namingScreen->strTemplate, 2, args->pcBoxes, boxID); } - if ((param0->textCursorPos == 0) || sub_02086F14(param0->entryBuf)) { - Pokemon *v4 = Pokemon_New(HEAP_ID_NAMING_SCREEN_APP); + if (namingScreen->textCursorPos == 0 || NamingScreen_IsRawStringAllSpaces(namingScreen->entryBuf)) { + Pokemon *mon = Pokemon_New(HEAP_ID_NAMING_SCREEN_APP); - Pokemon_InitWith(v4, param0->playerGenderOrMonSpecies, 1, 0, 0, 0, 0, 0); - StringTemplate_SetSpeciesName(param0->strTemplate, 0, Pokemon_GetBoxPokemon(v4)); - Heap_Free(v4); + Pokemon_InitWith(mon, namingScreen->playerGenderOrMonSpecies, 1, 0, FALSE, 0, OTID_NOT_SET, 0); + StringTemplate_SetSpeciesName(namingScreen->strTemplate, 0, Pokemon_GetBoxPokemon(mon)); + Heap_Free(mon); } else { - param0->entryBuf[param0->textCursorPos] = CHAR_EOS; - Strbuf_CopyChars(v0, param0->entryBuf); - StringTemplate_SetStrbuf(param0->strTemplate, 0, v0, 0, 0, 0); + namingScreen->entryBuf[namingScreen->textCursorPos] = CHAR_EOS; + Strbuf_CopyChars(strbuf, namingScreen->entryBuf); + StringTemplate_SetStrbuf(namingScreen->strTemplate, 0, strbuf, 0, 0, 0); } - param0->unk_180 = MessageUtil_ExpandedStrbuf(param0->strTemplate, param0->battleStringsMsgLoader, v1->battleMsgID, HEAP_ID_NAMING_SCREEN_APP); - param0->printedFromBattleGMM = TRUE; + namingScreen->battleMessageStrbuf = MessageUtil_ExpandedStrbuf( + namingScreen->strTemplate, + namingScreen->battleStringsMsgLoader, + args->battleMsgID, + HEAP_ID_NAMING_SCREEN_APP); + namingScreen->printedFromBattleGMM = TRUE; - Strbuf_Free(v0); + Strbuf_Free(strbuf); } } -static void sub_0208765C(BgConfig *param0, Window *param1) +static void NamingScreen_FreeBgs(BgConfig *bgConfig, Window *windows) { - int v0; - - for (v0 = 0; v0 < 10; v0++) { - Window_Remove(¶m1[v0]); + for (int i = 0; i < NMS_WINDOW_COUNT; i++) { + Window_Remove(&windows[i]); } - Bg_FreeTilemapBuffer(param0, BG_LAYER_SUB_0); - Bg_FreeTilemapBuffer(param0, BG_LAYER_MAIN_2); - Bg_FreeTilemapBuffer(param0, BG_LAYER_MAIN_1); - Bg_FreeTilemapBuffer(param0, BG_LAYER_MAIN_0); - Heap_FreeExplicit(HEAP_ID_NAMING_SCREEN_APP, param0); + Bg_FreeTilemapBuffer(bgConfig, BG_LAYER_SUB_0); + Bg_FreeTilemapBuffer(bgConfig, BG_LAYER_MAIN_2); + Bg_FreeTilemapBuffer(bgConfig, BG_LAYER_MAIN_1); + Bg_FreeTilemapBuffer(bgConfig, BG_LAYER_MAIN_0); + Heap_FreeExplicit(HEAP_ID_NAMING_SCREEN_APP, bgConfig); } static void NamingScreen_LoadGraphicsFromNarc(NamingScreen *namingScreen, NARC *narc) { BgConfig *bgConfig = namingScreen->bgConfig; - Graphics_LoadPaletteFromOpenNARC(narc, 0, PAL_LOAD_MAIN_BG, 0, 16 * 3 * 2, HEAP_ID_NAMING_SCREEN_APP); + Graphics_LoadPaletteFromOpenNARC(narc, naming_screen_NCLR, PAL_LOAD_MAIN_BG, 0, 16 * 3 * 2, HEAP_ID_NAMING_SCREEN_APP); Graphics_LoadPalette(NARC_INDEX_GRAPHIC__POKETCH, 12, PAL_LOAD_SUB_BG, 0, 16 * 2, HEAP_ID_NAMING_SCREEN_APP); Bg_MaskPalette(BG_LAYER_SUB_0, 0); Graphics_LoadTilesToBgLayerFromOpenNARC( narc, - 2, + naming_screen_main_tiles_NCGR_lz, bgConfig, BG_LAYER_MAIN_2, 0, @@ -1723,7 +1809,7 @@ static void NamingScreen_LoadGraphicsFromNarc(NamingScreen *namingScreen, NARC * HEAP_ID_NAMING_SCREEN_APP); Graphics_LoadTilemapToBgLayerFromOpenNARC( narc, - 4, + naming_screen_bg_NSCR_lz, bgConfig, BG_LAYER_MAIN_2, 0, @@ -1732,7 +1818,7 @@ static void NamingScreen_LoadGraphicsFromNarc(NamingScreen *namingScreen, NARC * HEAP_ID_NAMING_SCREEN_APP); Graphics_LoadTilesToBgLayerFromOpenNARC( narc, - 2, + naming_screen_main_tiles_NCGR_lz, bgConfig, BG_LAYER_MAIN_1, 0, @@ -1741,7 +1827,7 @@ static void NamingScreen_LoadGraphicsFromNarc(NamingScreen *namingScreen, NARC * HEAP_ID_NAMING_SCREEN_APP); Graphics_LoadTilemapToBgLayerFromOpenNARC( narc, - 6, + naming_screen_chars_bg_0_NSCR_lz, bgConfig, BG_LAYER_MAIN_1, 0, @@ -1750,7 +1836,7 @@ static void NamingScreen_LoadGraphicsFromNarc(NamingScreen *namingScreen, NARC * HEAP_ID_NAMING_SCREEN_APP); Graphics_LoadTilemapToBgLayerFromOpenNARC( narc, - 7, + naming_screen_chars_bg_1_NSCR_lz, bgConfig, BG_LAYER_MAIN_0, 0, @@ -1769,7 +1855,7 @@ static void NamingScreen_LoadGraphicsFromNarc(NamingScreen *namingScreen, NARC * namingScreen->charDataAlloc = Graphics_GetCharDataFromOpenNARC( narc, - 16, + naming_screen_unk_tiles_NCGR_lz, TRUE, &namingScreen->charData, HEAP_ID_NAMING_SCREEN_APP); @@ -1807,34 +1893,34 @@ static void NamingScreen_LoadObjectGfx(NamingScreen *namingScreen, NARC *narc) } namingScreen->spriteResources[0][SPRITE_RESOURCE_CHAR] = SpriteResourceCollection_AddTilesFrom( - namingScreen->spriteResourceCollections[0], + namingScreen->spriteResourceCollections[SPRITE_RESOURCE_CHAR], narc, - 10, + naming_screen_sprites_NCGR_lz, TRUE, 0, NNS_G2D_VRAM_TYPE_2DMAIN, HEAP_ID_NAMING_SCREEN_APP); namingScreen->spriteResources[0][SPRITE_RESOURCE_PLTT] = SpriteResourceCollection_AddPaletteFrom( - namingScreen->spriteResourceCollections[1], + namingScreen->spriteResourceCollections[SPRITE_RESOURCE_PLTT], narc, - 1, + naming_screen_sprites_NCLR, FALSE, 0, NNS_G2D_VRAM_TYPE_2DMAIN, 9, HEAP_ID_NAMING_SCREEN_APP); namingScreen->spriteResources[0][SPRITE_RESOURCE_CELL] = SpriteResourceCollection_AddFrom( - namingScreen->spriteResourceCollections[2], + namingScreen->spriteResourceCollections[SPRITE_RESOURCE_CELL], narc, - 12, + naming_screen_sprites_cell_NCER_lz, TRUE, 0, SPRITE_RESOURCE_CELL, HEAP_ID_NAMING_SCREEN_APP); namingScreen->spriteResources[0][SPRITE_RESOURCE_ANIM] = SpriteResourceCollection_AddFrom( - namingScreen->spriteResourceCollections[3], + namingScreen->spriteResourceCollections[SPRITE_RESOURCE_ANIM], narc, - 14, + naming_screen_sprites_anim_NANR_lz, TRUE, 0, SPRITE_RESOURCE_ANIM, @@ -1858,34 +1944,34 @@ static void NamingScreen_LoadObjectGfx(NamingScreen *namingScreen, NARC *narc) } namingScreen->spriteResources[1][SPRITE_RESOURCE_CHAR] = SpriteResourceCollection_AddTilesFrom( - namingScreen->spriteResourceCollections[0], + namingScreen->spriteResourceCollections[SPRITE_RESOURCE_CHAR], narc, - 11, + naming_screen_unk_sprite_NCGR_lz, TRUE, 1, NNS_G2D_VRAM_TYPE_2DSUB, HEAP_ID_NAMING_SCREEN_APP); namingScreen->spriteResources[1][SPRITE_RESOURCE_PLTT] = SpriteResourceCollection_AddPaletteFrom( - namingScreen->spriteResourceCollections[1], + namingScreen->spriteResourceCollections[SPRITE_RESOURCE_PLTT], narc, - 1, + naming_screen_sprites_NCLR, FALSE, 1, NNS_G2D_VRAM_TYPE_2DSUB, 3, HEAP_ID_NAMING_SCREEN_APP); namingScreen->spriteResources[1][SPRITE_RESOURCE_CELL] = SpriteResourceCollection_AddFrom( - namingScreen->spriteResourceCollections[2], + namingScreen->spriteResourceCollections[SPRITE_RESOURCE_CELL], narc, - 13, + naming_screen_unk_sprite_cell_NCER_lz, TRUE, 1, SPRITE_RESOURCE_CELL, HEAP_ID_NAMING_SCREEN_APP); namingScreen->spriteResources[1][SPRITE_RESOURCE_ANIM] = SpriteResourceCollection_AddFrom( - namingScreen->spriteResourceCollections[3], + namingScreen->spriteResourceCollections[SPRITE_RESOURCE_ANIM], narc, - 15, + naming_screen_unk_sprite_anim_NANR_lz, TRUE, 1, SPRITE_RESOURCE_ANIM, @@ -1963,7 +2049,7 @@ static void NamingScreen_InitSprites(NamingScreen *namingScreen) spriteTemplate.vramType = NNS_G2D_VRAM_TYPE_2DMAIN; spriteTemplate.heapID = HEAP_ID_NAMING_SCREEN_APP; - for (i = 0; i < 9; i++) { + for (i = 0; i < NMS_SPRITE_COUNT; i++) { spriteTemplate.position.x = FX32_ONE * sSpriteAnimations[i].x; spriteTemplate.position.y = FX32_ONE * sSpriteAnimations[i].y; @@ -1977,13 +2063,13 @@ static void NamingScreen_InitSprites(NamingScreen *namingScreen) Sprite_SetDrawFlag(namingScreen->uiSprites[NMS_SPRITE_JP_UNUSED_2_BUTTON], FALSE); Sprite_SetDrawFlag(namingScreen->uiSprites[NMS_SPRITE_CURSOR], FALSE); - for (i = 0; i < 7; i++) { - namingScreen->tasks[i] = SysTask_StartAndAllocateParam( + for (i = 0; i < NMS_SPRITE_OVERLAY; i++) { + namingScreen->spriteFollowTasks[i] = SysTask_StartAndAllocateParam( NamingScreen_SubspritePosControllerTask, sizeof(SubspritePosControllerParameters), 5, HEAP_ID_NAMING_SCREEN_APP); - SubspritePosControllerParameters *taskData = SysTask_GetParam(namingScreen->tasks[i]); + SubspritePosControllerParameters *taskData = SysTask_GetParam(namingScreen->spriteFollowTasks[i]); taskData->parent = namingScreen->uiSprites[NMS_SPRITE_OVERLAY]; taskData->child = namingScreen->uiSprites[i]; taskData->dx = FX32_ONE * sSpriteAnimations[i].x; @@ -2093,7 +2179,7 @@ static void NamingScreen_WiggleOverlayTask(SysTask *task, void *paramsPtr) static void NamingScreen_AnimateChangeChars( BgConfig *bgConfig, - Window *window, + Window *windows, enum ChangeCharsState *statePtr, int currentCharsIdx, enum BgLayer *bgLayerPtr, @@ -2110,7 +2196,7 @@ static void NamingScreen_AnimateChangeChars( Graphics_LoadTilemapToBgLayer( NARC_INDEX_DATA__NAMEIN, - 6 + currentCharsIdx, + naming_screen_chars_bg_0_NSCR_lz + currentCharsIdx, bgConfig, bgLayer, 0, @@ -2119,7 +2205,7 @@ static void NamingScreen_AnimateChangeChars( HEAP_ID_NAMING_SCREEN_APP); NamingScreen_InitializeCharsPosition(charsPosition, bgLayer); NamingScreen_InitializeCharsGraphics( - &window[bgLayer], + &windows[bgLayer], bgColor, currentCharsIdx, TEXT_COLOR(14, 15, 0), @@ -2146,8 +2232,8 @@ static void NamingScreen_AnimateChangeChars( wiggleParam = SysTask_GetParam(wiggleTask); wiggleParam->overlaySprite = sprites[NMS_SPRITE_OVERLAY]; wiggleParam->state = 0; - wiggleParam->overlayXPosition = Sprite_GetPosition(sprites[7])->x; - wiggleParam->overlayYPosition = Sprite_GetPosition(sprites[7])->y; + wiggleParam->overlayXPosition = Sprite_GetPosition(sprites[NMS_SPRITE_OVERLAY])->x; + wiggleParam->overlayYPosition = Sprite_GetPosition(sprites[NMS_SPRITE_OVERLAY])->y; charsPosition[bgLayer].x = -11; (*statePtr)++; @@ -2184,7 +2270,7 @@ static void NamingScreen_AnimateChangeChars( } } -static void NamingScreen_PrintMessageOnWindowLeftAlign(Window *window, int param1, Strbuf *str) +static void NamingScreen_PrintMessageOnWindowLeftAlign(Window *window, int unused, Strbuf *str) { Window_DrawMessageBoxWithScrollCursor(window, FALSE, 32 * 8, PLTT_10); Text_AddPrinterWithParams(window, FONT_MESSAGE, str, 0, 0, TEXT_SPEED_INSTANT, NULL); @@ -2215,10 +2301,19 @@ static void NamingScreen_PrintMessageOnWindow(Window *window, int param1, Strbuf static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationManager *appMan, NARC *narc) { - Window_Add(namingScreen->bgConfig, &namingScreen->windows[0], BG_LAYER_MAIN_0, 2, 1, 26, 12, PLTT_1, 32 * 8); Window_Add( namingScreen->bgConfig, - &namingScreen->windows[1], + &namingScreen->windows[NMS_WINDOW_KEYBOARD_0], + BG_LAYER_MAIN_0, + 2, + 1, + 26, + 12, + PLTT_1, + 32 * 8); + Window_Add( + namingScreen->bgConfig, + &namingScreen->windows[NMS_WINDOW_KEYBOARD_1], BG_LAYER_MAIN_1, 2, 1, @@ -2230,7 +2325,7 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana if (namingScreen->type == NAMING_SCREEN_TYPE_UNK4) { Graphics_LoadTilemapToBgLayerFromOpenNARC( narc, - 6 + 3, + naming_screen_chars_bg_3_NSCR_lz, namingScreen->bgConfig, BG_LAYER_MAIN_1, 0, @@ -2240,7 +2335,7 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana namingScreen->currentCharsIdx = 4; NamingScreen_LoadKeyboardLayout(namingScreen->keyboardChars, 4); NamingScreen_InitializeCharsGraphics( - &namingScreen->windows[1], + &namingScreen->windows[NMS_WINDOW_KEYBOARD_1], 0xa0a, 4, TEXT_COLOR(14, 15, 0), @@ -2249,7 +2344,7 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana namingScreen->currentCharsIdx = 0; NamingScreen_LoadKeyboardLayout(namingScreen->keyboardChars, 0); NamingScreen_InitializeCharsGraphics( - &namingScreen->windows[1], + &namingScreen->windows[NMS_WINDOW_KEYBOARD_1], 0x404, 0, TEXT_COLOR(14, 15, 0), @@ -2258,7 +2353,7 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana Window_Add( namingScreen->bgConfig, - &namingScreen->windows[2], + &namingScreen->windows[NMS_WINDOW_DUMMY], BG_LAYER_MAIN_2, 7, 2, @@ -2271,7 +2366,7 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana Window_Add( namingScreen->bgConfig, - &namingScreen->windows[3], + &namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], BG_LAYER_MAIN_2, 10, 3, @@ -2279,10 +2374,10 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana 2, PLTT_0, (((32 * 8) + (26 * 12)) + (26 * 12)) + 44); - Window_FillTilemap(&namingScreen->windows[3], 0x01); + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], 0x01); Window_Add( namingScreen->bgConfig, - &namingScreen->windows[8], + &namingScreen->windows[NMS_WINDOW_GROUP_TEXT], BG_LAYER_MAIN_2, 10 + width - 1, 3, @@ -2290,19 +2385,19 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana 2, PLTT_0, ((((32 * 8) + (26 * 12)) + (26 * 12)) + 44) + 36); - Window_FillTilemap(&namingScreen->windows[8], 0x01); + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_GROUP_TEXT], 0x01); if (namingScreen->type == NAMING_SCREEN_TYPE_GROUP) { NamingScreen_PrintMessageOnWindow( - &namingScreen->windows[8], + &namingScreen->windows[NMS_WINDOW_GROUP_TEXT], namingScreen->type, namingScreen->groupTextStrbuf); - Window_CopyToVRAM(&namingScreen->windows[8]); + Window_CopyToVRAM(&namingScreen->windows[NMS_WINDOW_GROUP_TEXT]); } Window_Add( namingScreen->bgConfig, - &namingScreen->windows[9], + &namingScreen->windows[NMS_WINDOW_PROMPT], BG_LAYER_SUB_0, 2, 19, @@ -2310,9 +2405,9 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana 4, PLTT_12, 120 + (2 * 2 * 3)); - Window_FillTilemap(&namingScreen->windows[9], 15); + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_PROMPT], 15); NamingScreen_PrintMessageOnWindowLeftAlign( - &namingScreen->windows[9], + &namingScreen->windows[NMS_WINDOW_PROMPT], namingScreen->type, namingScreen->promptString); @@ -2321,7 +2416,7 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana if (namingScreen->entryBufBak[0] != CHAR_EOS) { CharCode_Copy(namingScreen->entryBuf, namingScreen->entryBufBak); NamingScreen_PrintChars( - &namingScreen->windows[3], + &namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], namingScreen->entryBuf, 0, 0, @@ -2332,13 +2427,22 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana } for (int i = 0; i < 3; i++) { - Window_Add(namingScreen->bgConfig, &namingScreen->windows[4 + i], BG_LAYER_MAIN_2, 0, 0, 2, 2, PLTT_0, 120); - Window_FillTilemap(&namingScreen->windows[4 + i], 0); + Window_Add( + namingScreen->bgConfig, + &namingScreen->windows[NMS_WINDOW_UNK_0 + i], + BG_LAYER_MAIN_2, + 0, + 0, + 2, + 2, + PLTT_0, + 120); + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_UNK_0 + i], 0); } Window_Add( namingScreen->bgConfig, - &namingScreen->windows[7], + &namingScreen->windows[NMS_WINDOW_UNK_3], BG_LAYER_MAIN_2, 0, 0, @@ -2346,7 +2450,7 @@ static void NamingScreen_InitWindows(NamingScreen *namingScreen, ApplicationMana 2, PLTT_0, 120 + (2 * 2 * 3)); - Window_FillTilemap(&namingScreen->windows[7], 0); + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_UNK_3], 0); } static void NamingScreen_UpdateCharsPriorities(BgConfig *unused0, enum BgLayer oldBgLayer, VecFx32 unused1[]) @@ -2363,12 +2467,12 @@ static void NamingScreen_InitializeCharsPosition(VecFx32 charsPosition[], enum B charsPosition[freeBgLayer ^ 1].y = -80; } -static const int sDpadMovementCoordDeltas[][2] = { - { 0, 0 }, - { 0, -1 }, - { 0, 1 }, - { -1, 0 }, - { 1, 0 } +static const DpadMovement sDpadMovementCoordDeltas[NMS_DPAD_MOVEMENT_COUNT] = { + { .x = 0, .y = 0 }, + { .x = 0, .y = -1 }, + { .x = 0, .y = 1 }, + { .x = -1, .y = 0 }, + { .x = 1, .y = 0 } }; static int NamingScreen_WrapAroundWithinInterval(int value, int lower, int upper) @@ -2384,38 +2488,38 @@ static int NamingScreen_WrapAroundWithinInterval(int value, int lower, int upper return value; } -static void NamingScreen_MoveCursor(NamingScreen *namingScreen, int dpadMovement) +static void NamingScreen_MoveCursor(NamingScreen *namingScreen, enum NamingScreenDpadMovement dpadMovement) { int newX, newY; u16 prevKey; - if (dpadMovement == 0) { + if (dpadMovement == NMS_DPAD_MOVEMENT_NONE) { return; } prevKey = namingScreen->keyboardChars[namingScreen->keyboardCursor.y][namingScreen->keyboardCursor.x]; newX = NamingScreen_WrapAroundWithinInterval( - namingScreen->keyboardCursor.x + sDpadMovementCoordDeltas[dpadMovement][0], + namingScreen->keyboardCursor.x + sDpadMovementCoordDeltas[dpadMovement].x, 0, - 13); + NMS_NUM_COLS); newY = NamingScreen_WrapAroundWithinInterval( - namingScreen->keyboardCursor.y + sDpadMovementCoordDeltas[dpadMovement][1], + namingScreen->keyboardCursor.y + sDpadMovementCoordDeltas[dpadMovement].y, 0, - 6); + NMS_NUM_ROWS); while (namingScreen->keyboardChars[newY][newX] == NMS_CONTROL_SKIP || namingScreen->keyboardChars[newY][newX] == prevKey && namingScreen->keyboardChars[newY][newX] > NMS_BUTTON_START) { if (namingScreen->keyboardCursor.prevY == 0 && namingScreen->keyboardChars[newY][newX] == NMS_CONTROL_SKIP - && sDpadMovementCoordDeltas[dpadMovement][1] != 0) { + && sDpadMovementCoordDeltas[dpadMovement].y != 0) { newX += namingScreen->keyboardCursor.deltaX; - newX = NamingScreen_WrapAroundWithinInterval(newX, 0, 13); + newX = NamingScreen_WrapAroundWithinInterval(newX, 0, NMS_NUM_COLS); } else { - newX += sDpadMovementCoordDeltas[dpadMovement][0]; - newX = NamingScreen_WrapAroundWithinInterval(newX, 0, 13); - newY += sDpadMovementCoordDeltas[dpadMovement][1]; - newY = NamingScreen_WrapAroundWithinInterval(newY, 0, 6); + newX += sDpadMovementCoordDeltas[dpadMovement].x; + newX = NamingScreen_WrapAroundWithinInterval(newX, 0, NMS_NUM_COLS); + newY += sDpadMovementCoordDeltas[dpadMovement].y; + newY = NamingScreen_WrapAroundWithinInterval(newY, 0, NMS_NUM_ROWS); } } @@ -2426,7 +2530,7 @@ static void NamingScreen_MoveCursor(NamingScreen *namingScreen, int dpadMovement static void NamingScreen_ProcessDirectionInputs(NamingScreen *namingScreen) { BOOL didInput = FALSE; - int dpadMovement = 0; + enum NamingScreenDpadMovement dpadMovement = NMS_DPAD_MOVEMENT_NONE; BOOL buttonInputIsTransition = FALSE; if (!Sprite_GetDrawFlag(namingScreen->uiSprites[NMS_SPRITE_CURSOR])) { @@ -2436,28 +2540,28 @@ static void NamingScreen_ProcessDirectionInputs(NamingScreen *namingScreen) if (gSystem.pressedKeysRepeatable & PAD_KEY_UP) { Sound_PlayEffect(SEQ_SE_CONFIRM); Sprite_SetDrawFlag(namingScreen->uiSprites[NMS_SPRITE_CURSOR], TRUE); - dpadMovement = 1; + dpadMovement = NMS_DPAD_MOVEMENT_UP; didInput++; } if (gSystem.pressedKeysRepeatable & PAD_KEY_DOWN) { Sound_PlayEffect(SEQ_SE_CONFIRM); Sprite_SetDrawFlag(namingScreen->uiSprites[NMS_SPRITE_CURSOR], TRUE); - dpadMovement = 2; + dpadMovement = NMS_DPAD_MOVEMENT_DOWN; didInput++; } if (gSystem.pressedKeysRepeatable & PAD_KEY_LEFT) { Sound_PlayEffect(SEQ_SE_CONFIRM); Sprite_SetDrawFlag(namingScreen->uiSprites[NMS_SPRITE_CURSOR], TRUE); - dpadMovement = 3; + dpadMovement = NMS_DPAD_MOVEMENT_LEFT; didInput++; } if (gSystem.pressedKeysRepeatable & PAD_KEY_RIGHT) { Sound_PlayEffect(SEQ_SE_CONFIRM); Sprite_SetDrawFlag(namingScreen->uiSprites[NMS_SPRITE_CURSOR], TRUE); - dpadMovement = 4; + dpadMovement = NMS_DPAD_MOVEMENT_RIGHT; didInput++; } @@ -2471,7 +2575,7 @@ static void NamingScreen_ProcessDirectionInputs(NamingScreen *namingScreen) } if ((namingScreen->isTouchInput = NamingScreen_ProcessTouchInputs(namingScreen)) == TRUE) { - dpadMovement = 0; + dpadMovement = NMS_DPAD_MOVEMENT_NONE; didInput++; } @@ -2486,10 +2590,13 @@ static void NamingScreen_ProcessDirectionInputs(NamingScreen *namingScreen) } } -static void NamingScreen_UpdateCursorSpritePosition(NamingScreen *namingScreen, int dpadMovement) +static void NamingScreen_UpdateCursorSpritePosition( + NamingScreen *namingScreen, + enum NamingScreenDpadMovement dpadMovement) { if (namingScreen->keyboardCursor.y != 0) { - if ((namingScreen->keyboardCursor.prevY == 0) && (namingScreen->keyboardCursor.prevY != namingScreen->keyboardCursor.y)) { + if (namingScreen->keyboardCursor.prevY == 0 + && namingScreen->keyboardCursor.prevY != namingScreen->keyboardCursor.y) { Sprite_SetAnim(namingScreen->uiSprites[NMS_SPRITE_CURSOR], 39); } @@ -2516,28 +2623,23 @@ static void NamingScreen_UpdateCursorSpritePosition(NamingScreen *namingScreen, namingScreen->keyboardCursor.prevX = namingScreen->keyboardCursor.x; namingScreen->keyboardCursor.prevY = namingScreen->keyboardCursor.y; - if (sDpadMovementCoordDeltas[dpadMovement][0] != 0) { - namingScreen->keyboardCursor.deltaX = sDpadMovementCoordDeltas[dpadMovement][0]; + if (sDpadMovementCoordDeltas[dpadMovement].x != NMS_DPAD_MOVEMENT_NONE) { + namingScreen->keyboardCursor.deltaX = sDpadMovementCoordDeltas[dpadMovement].x; } } -static void sub_02088514(u16 *param0) +static void NamingScreen_PaletteGlowEffect(u16 *pSinArg) { - fx32 v0; - GXRgb v1; - int v2, v3, v4; + *pSinArg += 20; - *param0 += 20; - - if (*param0 > 360) { - *param0 = 0; + if (*pSinArg > 360) { + *pSinArg = 0; } - v0 = CalcSineDegrees_Wraparound(*param0); - v3 = 15 + (v0 * 10) / FX32_ONE; - v1 = GX_RGB(29, v3, 0); + int val = ((CalcSineDegrees_Wraparound(*pSinArg) * 10) / FX32_ONE) + 15; + GXRgb rgb = GX_RGB(29, val, 0); - GX_LoadOBJPltt((u16 *)&v1, (16 + 13) * 2, 2); + GX_LoadOBJPltt(&rgb, (16 + 13) * 2, 2); } static void NamingScreen_PrintChars( @@ -2555,8 +2657,10 @@ static void NamingScreen_PrintChars( Strbuf *strBuf = Strbuf_Init(2, HEAP_ID_NAMING_SCREEN_APP); while (charCodes[i] != CHAR_EOS) { - if ((charCodes[i] == 0xd001) || (charCodes[i] == (0xd001 + 1)) || (charCodes[i] == (0xd001 + 2))) { - u16 v5 = charCodes[i] - 0xd001; + if (charCodes[i] == NMS_CONTROL_DAKU + || charCodes[i] == NMS_CONTROL_HANDAKU + || charCodes[i] == NMS_CONTROL_SPACE) { + u16 v5 = charCodes[i] - NMS_CONTROL_DAKU; Window_BlitBitmapRect( window, (void *)&rawCharData[v5 * 8 * 8 * 4 / 2], @@ -2569,7 +2673,7 @@ static void NamingScreen_PrintChars( 12, 12); } else { - if (charCodes[i] == (0xd001 + 3)) { + if (charCodes[i] == NMS_CONTROL_SKIP) { i++; continue; } @@ -2605,14 +2709,18 @@ static const u8 sUnkGXObjOffsets1[] = { 0x58 }; -static void *NamingScreen_PrintStringOnWindowAndGetPixelBuffer(Window *window, Strbuf *string, u8 fontId, const TextColor color) +static void *NamingScreen_PrintStringOnWindowAndGetPixelBuffer( + Window *window, + Strbuf *string, + u8 fontId, + const TextColor color) { Text_AddPrinterWithParamsAndColor(window, fontId, string, 0, 0, TEXT_SPEED_NO_TRANSFER, color, NULL); return window->pixels; } static void NamingScreen_PrintCharOnWindowAndOBJ( - Window *window, + Window *windows, const charcode_t *tmpBuf, u8 *pixelBuf, Strbuf *string) @@ -2622,13 +2730,12 @@ static void NamingScreen_PrintCharOnWindowAndOBJ( void *ptr; Strbuf *string2; - Window_FillTilemap(&window[3], 0); - ptr = NamingScreen_PrintStringOnWindowAndGetPixelBuffer(&window[3], string, FONT_SUBSCREEN, TEXT_COLOR(13, 14, 15)); + Window_FillTilemap(&windows[3], 0); + ptr = NamingScreen_PrintStringOnWindowAndGetPixelBuffer(&windows[3], string, FONT_SUBSCREEN, TEXT_COLOR(13, 14, 15)); DC_FlushRange(ptr, 0x20 * 4 * 16); for (i = 0; i < 4; i++) { - // copy rect of pixels from window 3 - sub_02012C60(&window[3], 4, 2, 4 * i, 0, (char *)pixelBuf); + sub_02012C60(&windows[3], 4, 2, 4 * i, 0, (char *)pixelBuf); DC_FlushRange(pixelBuf, 0x20 * 4 * 2); GXS_LoadOBJ(pixelBuf, sUnkGXObjOffsets1[i] * 0x20, 0x20 * 4 * 2); } @@ -2639,11 +2746,11 @@ static void NamingScreen_PrintCharOnWindowAndOBJ( curCharBuf[0] = tmpBuf[i]; curCharBuf[1] = CHAR_EOS; - Window_FillTilemap(&window[i], 0); + Window_FillTilemap(&windows[i], 0); Strbuf_CopyChars(string2, curCharBuf); ptr = NamingScreen_PrintStringOnWindowAndGetPixelBuffer( - &window[i], + &windows[i], string2, FONT_SUBSCREEN, TEXT_COLOR(13, 14, 15)); @@ -2664,7 +2771,7 @@ static void NamingScreen_PrintLastCharOfEntryBuf( Strbuf *string) { int i, j; - const u16 *v2 = NULL; + const u16 *dummy = NULL; u16 charCode; if (srcCharIdx == CHAR_NONE) { @@ -2720,12 +2827,12 @@ static void NamingScreen_LoadKeyboardLayout(charcode_t out[][13], const int inde { int i, j; - for (i = 0; i < 13; i++) { + for (i = 0; i < NMS_NUM_COLS; i++) { out[0][i] = sHomeRowLayouts[index][i]; } - for (j = 0; j < 6 - 1; j++) { - for (i = 0; i < 13; i++) { + for (j = 0; j < NMS_NUM_ROWS - 1; j++) { + for (i = 0; i < NMS_NUM_COLS; i++) { out[1 + j][i] = sCharCodes[index][j][i]; } } @@ -2760,9 +2867,9 @@ static int NamingScreen_ProcessCharacterInput(NamingScreen *namingScreen, charco NMS_CONTROL_DAKU, namingScreen->entryBuf, namingScreen->textCursorPos)) { - Window_FillTilemap(&namingScreen->windows[3], 1); + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], 1); NamingScreen_PrintChars( - &namingScreen->windows[3], + &namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], namingScreen->entryBuf, 0, 0, @@ -2781,9 +2888,9 @@ static int NamingScreen_ProcessCharacterInput(NamingScreen *namingScreen, charco NMS_CONTROL_HANDAKU, namingScreen->entryBuf, namingScreen->textCursorPos)) { - Window_FillTilemap(&namingScreen->windows[3], 1); + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], 1); NamingScreen_PrintChars( - &namingScreen->windows[3], + &namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], namingScreen->entryBuf, 0, 0, @@ -2795,10 +2902,14 @@ static int NamingScreen_ProcessCharacterInput(NamingScreen *namingScreen, charco } break; case NMS_BUTTON_PAGE_JP_UNUSED_2: - if (NamingScreen_JPFlipAlphaCase(0, NELEMS(sJPCharConversionTable), namingScreen->entryBuf, namingScreen->textCursorPos)) { - Window_FillTilemap(&namingScreen->windows[3], 1); + if (NamingScreen_JPFlipAlphaCase( + 0, + NELEMS(sJPCharConversionTable), + namingScreen->entryBuf, + namingScreen->textCursorPos)) { + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], 1); NamingScreen_PrintChars( - &namingScreen->windows[3], + &namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], namingScreen->entryBuf, 0, 0, @@ -2828,13 +2939,13 @@ static int NamingScreen_ProcessCharacterInput(NamingScreen *namingScreen, charco namingScreen->entryBuf[namingScreen->textCursorPos - 1] = CHAR_EOS; namingScreen->textCursorPos--; - Window_FillTilemap(&namingScreen->windows[3], 1); + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], 1); if (namingScreen->textCursorPos == 0) { - Window_CopyToVRAM(&namingScreen->windows[3]); + Window_CopyToVRAM(&namingScreen->windows[NMS_WINDOW_ENTERED_TEXT]); } else { NamingScreen_PrintChars( - &namingScreen->windows[3], + &namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], namingScreen->entryBuf, 0, 0, @@ -2845,7 +2956,7 @@ static int NamingScreen_ProcessCharacterInput(NamingScreen *namingScreen, charco } NamingScreen_PrintLastCharOfEntryBuf( - &namingScreen->windows[4], + &namingScreen->windows[NMS_WINDOW_UNK_0], namingScreen->entryBuf, namingScreen->textCursorPos, namingScreen->tmpBuf, @@ -2879,7 +2990,7 @@ static int NamingScreen_ProcessCharacterInput(NamingScreen *namingScreen, charco HEAP_ID_NAMING_SCREEN_APP); return NMS_APP_STATE_WAIT_FADE_OUT; } else { - namingScreen->state.main = NMS_STATE_PLACEHOLDER_5; + namingScreen->state.main = NMS_STATE_PRINT_BATTLE_MESSAGE; } break; default: @@ -2890,9 +3001,9 @@ static int NamingScreen_ProcessCharacterInput(NamingScreen *namingScreen, charco if (namingScreen->textCursorPos != namingScreen->maxChars) { namingScreen->entryBuf[namingScreen->textCursorPos] = charCode; - Window_FillTilemap(&namingScreen->windows[3], 1); + Window_FillTilemap(&namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], 1); NamingScreen_PrintChars( - &namingScreen->windows[3], + &namingScreen->windows[NMS_WINDOW_ENTERED_TEXT], namingScreen->entryBuf, 0, 0, @@ -2914,10 +3025,10 @@ static int NamingScreen_ProcessCharacterInput(NamingScreen *namingScreen, charco G2_SetBlendAlpha(0, GX_BLEND_PLANEMASK_BG0 | GX_BLEND_PLANEMASK_BG1 | GX_BLEND_PLANEMASK_BG2, 8, 8); Sprite_SetAnim(namingScreen->uiSprites[NMS_SPRITE_CURSOR], 60); - namingScreen->keyboardCursor.ignoreInput = 1; + namingScreen->keyboardCursor.ignoreInput = TRUE; NamingScreen_PrintLastCharOfEntryBuf( - &namingScreen->windows[4], + &namingScreen->windows[NMS_WINDOW_UNK_0], namingScreen->entryBuf, namingScreen->textCursorPos, namingScreen->tmpBuf, @@ -2972,7 +3083,7 @@ static BOOL NamingScreen_JPFlipDiacritic( int i; charcode_t charCode; - if (cursorPos == 0 || charBuf[cursorPos - 1] == 1) { + if (cursorPos == 0 || charBuf[cursorPos - 1] == CHAR_WIDE_SPACE) { return FALSE; } @@ -3085,9 +3196,9 @@ static void NamingScreen_UpdateSpriteAnimations(BOOL spritesToUpdate[], Sprite * { int i, j; - for (i = 0; i < 3; i++) { + for (i = NMS_SPRITE_PAGE_BUTTON_START; i < NMS_SPRITE_PAGE_BUTTON_END + 1; i++) { if (spritesToUpdate[i]) { - for (j = 0; j < 3; j++) { + for (j = NMS_SPRITE_PAGE_BUTTON_START; j < NMS_SPRITE_PAGE_BUTTON_END + 1; j++) { Sprite_SetAnim(sprites[j], sSpriteAnimations[j].anim); } @@ -3096,13 +3207,13 @@ static void NamingScreen_UpdateSpriteAnimations(BOOL spritesToUpdate[], Sprite * } } - for (i = 5; i < 7; i++) { + for (i = NMS_SPRITE_BUTTON_START; i < NMS_SPRITE_BUTTON_END + 1; i++) { if (spritesToUpdate[i]) { Sprite_SetAnim(sprites[i], sSpriteAnimations[i].anim + 1); } } - for (i = 0; i < 7; i++) { + for (i = 0; i < NMS_SPRITE_OVERLAY; i++) { spritesToUpdate[i] = FALSE; } } @@ -3126,7 +3237,7 @@ static void NamingScreen_PlaceCursorSprite(NamingScreen *namingScreen) NamingScreen_UpdateCursorSpritePosition(namingScreen, 0); } - namingScreen->keyboardCursor.ignoreInput = 0; + namingScreen->keyboardCursor.ignoreInput = FALSE; Sprite_SetExplicitOAMMode(namingScreen->uiSprites[NMS_SPRITE_CURSOR], GX_OAM_MODE_NORMAL); } diff --git a/src/applications/rowan_intro/rowan_intro_app.c b/src/applications/rowan_intro/rowan_intro_app.c index dd3908b24d..6092271020 100644 --- a/src/applications/rowan_intro/rowan_intro_app.c +++ b/src/applications/rowan_intro/rowan_intro_app.c @@ -245,8 +245,8 @@ typedef struct RowanIntro { StringTemplate *strFormatter; UnkStruct_02015920 *unk_68; SysTask *unused; - NamingScreenArgs *unk_70; - NamingScreenArgs *unk_74; + NamingScreenArgs *playerNamingScreenArgs; + NamingScreenArgs *rivalNamingScreenArgs; enum FadeBgLayerState fadeBgLayerState; int fadeBgLayerCurAlpha; int fadeBgLayerCurAlphaInv; @@ -325,8 +325,8 @@ BOOL RowanIntro_Init(ApplicationManager *appMan, int *unusedState) manager->state = RI_STATE_FIRST_FADE_BLACK_START; manager->bufferedState = RI_STATE_FIRST_FADE_BLACK_START; manager->appMan = NULL; - manager->unk_70 = NamingScreenArgs_Init(heapID, NAMING_SCREEN_TYPE_PLAYER, 0, TRAINER_NAME_LEN, manager->options); - manager->unk_74 = NamingScreenArgs_Init(heapID, NAMING_SCREEN_TYPE_RIVAL, 0, TRAINER_NAME_LEN, manager->options); + manager->playerNamingScreenArgs = NamingScreenArgs_Init(heapID, NAMING_SCREEN_TYPE_PLAYER, 0, TRAINER_NAME_LEN, manager->options); + manager->rivalNamingScreenArgs = NamingScreenArgs_Init(heapID, NAMING_SCREEN_TYPE_RIVAL, 0, TRAINER_NAME_LEN, manager->options); manager->bgLayer3TilemapIndex = 0; manager->bgLayer1TilemapIndex = 0; manager->bgLayer2TilemapIndex = 0; @@ -436,19 +436,19 @@ BOOL RowanIntro_Exit(ApplicationManager *appMan, int *unusedState) TrainerInfo_SetNameFromStrbuf( SaveData_GetTrainerInfo(manager->saveData), - manager->unk_70->textInputStr); + manager->playerNamingScreenArgs->textInputStr); TrainerInfo_SetGender( SaveData_GetTrainerInfo(manager->saveData), - manager->unk_70->playerGenderOrMonSpecies); + manager->playerNamingScreenArgs->playerGenderOrMonSpecies); { MiscSaveBlock *miscSaveBlock = SaveData_MiscSaveBlock(manager->saveData); - MiscSaveBlock_SetRivalName(miscSaveBlock, manager->unk_74->textInputStr); + MiscSaveBlock_SetRivalName(miscSaveBlock, manager->rivalNamingScreenArgs->textInputStr); } - NamingScreenArgs_Free(manager->unk_70); - NamingScreenArgs_Free(manager->unk_74); + NamingScreenArgs_Free(manager->playerNamingScreenArgs); + NamingScreenArgs_Free(manager->rivalNamingScreenArgs); ApplicationManager_FreeData(appMan); Heap_Destroy(heapID); EnqueueApplication(FS_OVERLAY_ID(game_start), &gGameStartNewSaveAppTemplate); @@ -1001,14 +1001,14 @@ static BOOL RowanIntro_DisplayMessage(RowanIntro *manager, u32 textID, BOOL endE StringTemplate_SetStrbuf( manager->strFormatter, 0, - manager->unk_70->textInputStr, + manager->playerNamingScreenArgs->textInputStr, manager->playerGender, 1, GAME_LANGUAGE); StringTemplate_SetStrbuf( manager->strFormatter, 1, - manager->unk_74->textInputStr, + manager->rivalNamingScreenArgs->textInputStr, 0, 1, GAME_LANGUAGE); @@ -2704,10 +2704,10 @@ static BOOL RowanIntro_Run(RowanIntro *manager) } break; case RI_STATE_NAME_APP_KEYBOARD: - manager->unk_70->playerGenderOrMonSpecies = manager->playerGender; + manager->playerNamingScreenArgs->playerGenderOrMonSpecies = manager->playerGender; manager->appMan = ApplicationManager_New( &gNamingScreenAppTemplate, - manager->unk_70, + manager->playerNamingScreenArgs, manager->heapID); manager->state = RI_STATE_NAME_KEYBOARD; break; @@ -2773,7 +2773,7 @@ static BOOL RowanIntro_Run(RowanIntro *manager) break; case 2: case LIST_CANCEL: - Strbuf_Clear(manager->unk_70->textInputStr); + Strbuf_Clear(manager->playerNamingScreenArgs->textInputStr); manager->bufferedState = RI_STATE_GENDR_FADE_IN_AVATAR_PREP; manager->state = RI_STATE_NAME_FADE_OUT_AVATAR; break; @@ -2858,7 +2858,7 @@ static BOOL RowanIntro_Run(RowanIntro *manager) { Strbuf *tmpStrbuf = MessageLoader_GetNewStrbuf(manager->msgLoader, rivalNameTextID); - Strbuf_Copy(manager->unk_74->textInputStr, tmpStrbuf); + Strbuf_Copy(manager->rivalNamingScreenArgs->textInputStr, tmpStrbuf); Strbuf_Free(tmpStrbuf); } } @@ -2875,7 +2875,7 @@ static BOOL RowanIntro_Run(RowanIntro *manager) case RI_STATE_RIVAL_NAME_APP_KEYBOARD: manager->appMan = ApplicationManager_New( &gNamingScreenAppTemplate, - manager->unk_74, + manager->rivalNamingScreenArgs, manager->heapID); manager->state = RI_STATE_RIVAL_NAME_KEYBOARD; break; @@ -2919,7 +2919,7 @@ static BOOL RowanIntro_Run(RowanIntro *manager) break; case 2: case LIST_CANCEL: - Strbuf_Clear(manager->unk_74->textInputStr); + Strbuf_Clear(manager->rivalNamingScreenArgs->textInputStr); manager->state = RI_STATE_RIVAL_NAME_DIALOGUE; break; } diff --git a/src/battle/battle_script.c b/src/battle/battle_script.c index 43413ec921..4dad855568 100644 --- a/src/battle/battle_script.c +++ b/src/battle/battle_script.c @@ -10908,7 +10908,7 @@ static void BattleScript_CatchMonTask(SysTask *param0, void *param1) v19 = v2->tmpPtr[1]; v3 = BattleSystem_PartyPokemon(v2->battleSys, v1, v2->battleCtx->selectedPartySlot[v1]); - if (v19->unk_14 == 0) { + if (v19->returnCode == NAMING_SCREEN_CODE_OK) { Pokemon_SetValue(v3, MON_DATA_NICKNAME_STRBUF_AND_FLAG, v19->textInputStr); ov16_0223F24C(v2->battleSys, (1 + 48)); } diff --git a/src/overlay064/ov64_0222DCE0.c b/src/overlay064/ov64_0222DCE0.c index 2d8e5311cc..9ed0f90a92 100644 --- a/src/overlay064/ov64_0222DCE0.c +++ b/src/overlay064/ov64_0222DCE0.c @@ -2482,7 +2482,7 @@ static int ov64_0223044C(UnkStruct_ov64_02230444 *param0, UnkStruct_ov64_0222DFD ApplicationManager_Free(param0->appMan); - if (param0->unk_04->unk_14 == 0) { + if (param0->unk_04->returnCode == NAMING_SCREEN_CODE_OK) { param0->appMan = ApplicationManager_New(&Unk_020F2DBC, param0->unk_08, heapID); param2->unk_04 = 2; } else { @@ -2518,7 +2518,7 @@ static int ov64_0223044C(UnkStruct_ov64_02230444 *param0, UnkStruct_ov64_0222DFD ApplicationManager_Free(param0->appMan); - if (param0->unk_04->unk_14 == 0) { + if (param0->unk_04->returnCode == NAMING_SCREEN_CODE_OK) { ov64_0222E074(param2, 1, 12); ov64_0222E07C(param2, param0->unk_04->textInputStr, NULL); param2->unk_04 = 6; diff --git a/src/unk_0203D1B8.c b/src/unk_0203D1B8.c index 07f99d43f6..cb2b2f49db 100644 --- a/src/unk_0203D1B8.c +++ b/src/unk_0203D1B8.c @@ -1169,23 +1169,25 @@ static BOOL sub_0203DE98(FieldTask *param0) case 3: if (v2->unk_0C->type == NAMING_SCREEN_TYPE_POKEMON) { if (Strbuf_Compare(v2->unk_0C->textInputStr, v2->unk_10) == 0) { - v2->unk_0C->unk_14 = 1; + v2->unk_0C->returnCode = 1; } } else if (v2->unk_0C->type == NAMING_SCREEN_TYPE_GROUP) { const u16 *v3 = Strbuf_GetData(v2->unk_0C->textInputStr); RecordMixedRNG *v4 = SaveData_GetRecordMixedRNG(fieldSystem->saveData); if (RecordMixedRNG_DoesCollectionContainGroup(v4, v3)) { - v2->unk_0C->unk_14 = 2; + // this re-uses the returnCode field with values not associated with the naming + // screen. these should probably have their own enum. + v2->unk_0C->returnCode = 2; } } - if (v2->unk_0C->unk_14 == 0) { + if (v2->unk_0C->returnCode == 0) { sub_0203DF68(param0); } if (v2->unk_08 != NULL) { - *v2->unk_08 = v2->unk_0C->unk_14; + *v2->unk_08 = v2->unk_0C->returnCode; } NamingScreenArgs_Free(v2->unk_0C); @@ -1206,14 +1208,14 @@ static void sub_0203DF68(FieldTask *param0) switch (v1->unk_0C->type) { case NAMING_SCREEN_TYPE_PLAYER: { TrainerInfo *v2 = SaveData_GetTrainerInfo(fieldSystem->saveData); - TrainerInfo_SetName(v2, v1->unk_0C->unk_1C); + TrainerInfo_SetName(v2, v1->unk_0C->nameInputRaw); } break; case NAMING_SCREEN_TYPE_POKEMON: { Pokemon *v3; int v4; v3 = Party_GetPokemonBySlotIndex(SaveData_GetParty(fieldSystem->saveData), v1->unk_04); - Pokemon_SetValue(v3, MON_DATA_NICKNAME_AND_FLAG, (u8 *)&v1->unk_0C->unk_1C); + Pokemon_SetValue(v3, MON_DATA_NICKNAME_AND_FLAG, (u8 *)&v1->unk_0C->nameInputRaw); } break; case NAMING_SCREEN_TYPE_GROUP: { RecordMixedRNG *v5 = SaveData_GetRecordMixedRNG(fieldSystem->saveData); diff --git a/src/unk_02098218.c b/src/unk_02098218.c index de9cdaacad..b306935bba 100644 --- a/src/unk_02098218.c +++ b/src/unk_02098218.c @@ -242,7 +242,7 @@ static BOOL sub_0209843C(FieldTask *param0) v0->unk_00++; } break; case 4: - if (v0->unk_08->unk_14 == 0) { + if (v0->unk_08->returnCode == NAMING_SCREEN_CODE_OK) { Pokemon_SetValue(v0->unk_0C.unk_00, MON_DATA_NICKNAME_STRBUF_AND_FLAG, v0->unk_08->textInputStr); {