Expand tilesets from 192 to 255 tiles (#2) [Commit 2], Reorganization of pokecrystal charmap and fonts layout (#3)

This commit is contained in:
xCrystal 2023-08-02 19:52:51 +02:00
parent a1e095074c
commit 6e3c5fd008
67 changed files with 243 additions and 380 deletions

View File

@ -35,42 +35,6 @@
charmap "<ROCKET>", $5e ; "ROCKET"
charmap "<DEXEND>", $5f
; Actual characters (from gfx/font/font_extra.png)
; charmap "<BOLD_A>", $60 ; unused
; charmap "<BOLD_B>", $61 ; unused
; charmap "<BOLD_C>", $62 ; unused
; charmap "<BOLD_D>", $63 ; unused
; charmap "<BOLD_E>", $64 ; unused
; charmap "<BOLD_F>", $65 ; unused
; charmap "<BOLD_G>", $66 ; unused
; charmap "<BOLD_H>", $67 ; unused
; charmap "<BOLD_I>", $68 ; unused
; charmap "<BOLD_V>", $69 ; unused
; charmap "<BOLD_S>", $6a ; unused
; charmap "<BOLD_L>", $6b ; unused
; charmap "<BOLD_M>", $6c ; unused
; charmap "<COLON>", $6d ; unused (colon with tinier dots than ":")
; charmap "ぃ", $6e ; hiragana small i, unused
; charmap "ぅ", $6f ; hiragana small u, unused
charmap "<PO>", $63
charmap "<KE>", $64
charmap "“", $65 ; opening quote
charmap "”", $66 ; closing quote
; charmap "·", $74 ; middle dot, unused
charmap "…", $67 ; ellipsis
; charmap "ぁ", $76 ; hiragana small a, unused
; charmap "ぇ", $77 ; hiragana small e, unused
; charmap "ぉ", $78 ; hiragana small o, unused
charmap "┌", $79
charmap "─", $7a
charmap "┐", $7b
charmap "│", $7c
charmap "└", $7d
charmap "┘", $7e
charmap " ", $7f
; Actual characters (from gfx/font/font_battle_extra.png)
charmap "<LV>", $6e
@ -83,20 +47,13 @@
; Actual characters (from other graphics files)
; needed for _LoadFontsExtra1 (see engine/gfx/load_font.asm)
charmap "■", $60 ; gfx/font/black.2bpp
charmap "▲", $61 ; gfx/font/up_arrow.png
charmap "☎", $62 ; gfx/font/phone_icon.2bpp
; needed for MagikarpHouseSign (see engine/events/magikarp.asm)
charmap "", $6e ; gfx/font/feet_inches.png
charmap "″", $6f ; gfx/font/feet_inches.png
; needed for StatsScreen_PlaceShinyIcon and PrintPartyMonPage1
charmap "⁂", $3f ; gfx/stats/stats_tiles.png, tile 14
; Actual characters (from gfx/font/font.png)
charmap " ", $7f
charmap "A", $80
charmap "B", $81
charmap "C", $82
@ -123,14 +80,12 @@
charmap "X", $97
charmap "Y", $98
charmap "Z", $99
charmap "(", $9a
charmap ")", $9b
charmap ":", $9c
charmap ";", $9d
charmap "[", $9e
charmap "]", $9f
charmap "a", $a0
charmap "b", $a1
charmap "c", $a2
@ -157,56 +112,62 @@
charmap "x", $b7
charmap "y", $b8
charmap "z", $b9
charmap "■", $ba
charmap "▲", $bb
charmap "☎", $bc
charmap "“", $bd
charmap "”", $be
charmap "…", $bf
charmap "'d", $c0
charmap "'l", $c1
charmap "'m", $c2
charmap "'r", $c3
charmap "'s", $c4
charmap "'t", $c5
charmap "'v", $c6
charmap "", $c7
charmap "″", $c8
charmap "¥", $c9
charmap "'", $d0
charmap "<PK>", $d1
charmap "<MN>", $d2
charmap "-", $d3
charmap "<PO>", $d4
charmap "<KE>", $d5
charmap "?", $d6
charmap "!", $d7
charmap ".", $d8
charmap "&", $d9
charmap "é", $da
charmap "→", $db
charmap "▷", $dc
charmap "▶", $dd
charmap "▼", $de
charmap "♂", $df
charmap "←", $e0
charmap "×", $e1
; charmap "<DOT>", $e2 ; decimal point; same as "." in English
charmap "/", $e3
charmap ",", $e4
charmap "♀", $e5
charmap "0", $e6
charmap "1", $e7
charmap "2", $e8
charmap "3", $e9
charmap "4", $ea
charmap "5", $eb
charmap "6", $ec
charmap "7", $ed
charmap "8", $ee
charmap "9", $ef
; charmap "Ä", $c0
; charmap "Ö", $c1
; charmap "Ü", $c2
; charmap "ä", $c3
; charmap "ö", $c4
; charmap "ü", $c5
charmap "'d", $d0
charmap "'l", $d1
charmap "'m", $d2
charmap "'r", $d3
charmap "'s", $d4
charmap "'t", $d5
charmap "'v", $d6
charmap "←", $df
charmap "'", $e0
charmap "<PK>", $e1
charmap "<MN>", $e2
charmap "-", $e3
charmap "?", $e6
charmap "!", $e7
charmap ".", $e8
charmap "&", $e9
charmap "é", $ea
charmap "→", $eb
charmap "▷", $ec
charmap "▶", $ed
charmap "▼", $ee
charmap "♂", $ef
charmap "¥", $f0
charmap "×", $f1
; charmap "<DOT>", $f2 ; decimal point; same as "." in English
charmap "/", $f3
charmap ",", $f4
charmap "♀", $f5
charmap "0", $f6
charmap "1", $f7
charmap "2", $f8
charmap "3", $f9
charmap "4", $fa
charmap "5", $fb
charmap "6", $fc
charmap "7", $fd
charmap "8", $fe
charmap "9", $ff
; Textbox frame (from gfx/frame/*)
charmap "┌", $f0
charmap "─", $f1
charmap "┐", $f2
charmap "│", $f3
charmap "└", $f4
charmap "┘", $f5
; ASCII charmap, for mobile functions
pushc

View File

@ -234,7 +234,7 @@ INCBIN "gfx/battle/balls.2bpp"
_ShowLinkBattleParticipants:
call ClearBGPalettes
call LoadFontsExtra
call LoadFrame
hlcoord 2, 3
ld b, 9
ld c, 14

View File

@ -74,18 +74,7 @@ CheckMagikarpLength:
text_far _MagikarpGuruMeasureText
text_end
Magikarp_LoadFeetInchesChars:
ld hl, vTiles2 tile "" ; $6e
ld de, .feetinchchars
lb bc, BANK(.feetinchchars), 2
call Request2bpp
ret
.feetinchchars
INCBIN "gfx/font/feet_inches.2bpp"
PrintMagikarpLength:
call Magikarp_LoadFeetInchesChars
ld hl, wStringBuffer1
ld de, wMagikarpLength
lb bc, PRINTNUM_LEFTALIGN | 1, 2

View File

@ -22,7 +22,7 @@ _CardFlip:
call DelayFrame
call DisableLCD
call LoadStandardFont
call LoadFontsExtra
call LoadFrame
ld hl, CardFlipLZ01
ld de, vTiles2 tile $00

View File

@ -1,77 +1,39 @@
INCLUDE "gfx/font.asm"
EnableHDMAForGraphics:
db FALSE
Get1bppOptionalHDMA: ; unreferenced
ld a, [EnableHDMAForGraphics]
and a
jp nz, Get1bppViaHDMA
jp Get1bpp
Get2bppOptionalHDMA: ; unreferenced
ld a, [EnableHDMAForGraphics]
and a
jp nz, Get2bppViaHDMA
jp Get2bpp
_LoadStandardFont::
ld de, Font
ld hl, vTiles1
lb bc, BANK(Font), 128 ; "A" to "9"
lb bc, BANK(Font), 112 ; "A" to "9"
ldh a, [rLCDC]
bit rLCDC_ENABLE, a
jp z, Copy1bpp
ld de, Font
ld hl, vTiles1
lb bc, BANK(Font), 32 ; "A" to "]"
lb bc, BANK(Font), 32 ; "A" to...
call Get1bppViaHDMA
ld de, Font + 32 * LEN_1BPP_TILE
ld hl, vTiles1 tile $20
lb bc, BANK(Font), 32 ; "a" to $bf
lb bc, BANK(Font), 32
call Get1bppViaHDMA
ld de, Font + 64 * LEN_1BPP_TILE
ld hl, vTiles1 tile $40
lb bc, BANK(Font), 32 ; "Ä" to "←"
lb bc, BANK(Font), 32
call Get1bppViaHDMA
ld de, Font + 96 * LEN_1BPP_TILE
ld hl, vTiles1 tile $60
lb bc, BANK(Font), 32 ; "'" to "9"
lb bc, BANK(Font), 16 ; ..."9"
call Get1bppViaHDMA
ret
_LoadFontsExtra1::
ld de, FontsExtra_SolidBlackGFX
ld hl, vTiles2 tile "■" ; $60
lb bc, BANK(FontsExtra_SolidBlackGFX), 1
call Get1bppViaHDMA
ld de, PokegearPhoneIconGFX
ld hl, vTiles2 tile "☎" ; $62
lb bc, BANK(PokegearPhoneIconGFX), 1
call Get2bppViaHDMA
ld de, FontExtra ; "<PO>"
ld hl, vTiles2 tile "<PO>" ; $63
lb bc, BANK(FontExtra), 5 ; "<PO>" to "…"
call Get2bppViaHDMA
jr LoadFrame
_LoadFontsExtra2::
ld de, FontsExtra2_UpArrowGFX
ld hl, vTiles2 tile "▲" ; $61
ld b, BANK(FontsExtra2_UpArrowGFX)
ld c, 1
call Get2bppViaHDMA
ret
_LoadFontsBattleExtra::
ld de, FontBattleExtra
ld hl, vTiles2 tile $60
lb bc, BANK(FontBattleExtra), 25
call Get2bppViaHDMA
jr LoadFrame
jr _LoadFrame
LoadFrame:
_LoadFrame::
ld a, [wTextboxFrame]
maskbits NUM_FRAMES
ld bc, TEXTBOX_FRAME_TILES * LEN_1BPP_TILE
@ -79,10 +41,10 @@ LoadFrame:
call AddNTimes
ld d, h
ld e, l
ld hl, vTiles2 tile "┌" ; $79
ld hl, vTiles0 tile "┌" ; $f0
lb bc, BANK(Frames), TEXTBOX_FRAME_TILES ; "┌" to "┘"
call Get1bppViaHDMA
ld hl, vTiles2 tile " " ; $7f
ld hl, vTiles2 tile " " ; $f5
ld de, TextboxSpaceGFX
lb bc, BANK(TextboxSpaceGFX), 1
call Get1bppViaHDMA
@ -97,7 +59,7 @@ LoadBattleFontsHPBar:
ld de, FontBattleExtra + 16 tiles ; "<DO>"
lb bc, BANK(FontBattleExtra), 3 ; "<DO>" to "『"
call Get2bppViaHDMA
call LoadFrame
call _LoadFrame
LoadHPBar:
ld de, EnemyHPBarBorderGFX

View File

@ -1,7 +1,7 @@
LoadOverworldFont::
ld de, .OverworldFontGFX
ld hl, vTiles1
lb bc, BANK(.OverworldFontGFX), $80
lb bc, BANK(.OverworldFontGFX), 112
call Get2bpp
ld de, .OverworldFontSpaceGFX
ld hl, vTiles2 tile " "

View File

@ -3,7 +3,7 @@ _DeleteSaveData:
ld b, CGB_DIPLOMA
call GetCGBLayout
call LoadStandardFont
call LoadFontsExtra
call LoadFrame
ld de, MUSIC_MAIN_MENU
call PlayMusic
ld hl, .ClearAllSaveDataText

View File

@ -63,7 +63,7 @@ InitGenderScreen:
call DelayFrames
call ClearBGPalettes
call InitCrystalData
call LoadFontsExtra
call LoadFrame
hlcoord 0, 0
ld bc, SCREEN_HEIGHT * SCREEN_WIDTH
ld a, $0

View File

@ -40,7 +40,7 @@ NewGame_ClearTilemapEtc:
xor a
ldh [hMapAnims], a
call ClearTilemap
call LoadFontsExtra
call LoadFrame
call LoadStandardFont
call ClearWindowData
ret
@ -402,7 +402,7 @@ DisplayNormalContinueData:
call Continue_LoadMenuHeader
call Continue_DisplayBadgesDexPlayerName
call Continue_PrintGameTime
call LoadFontsExtra
call LoadFrame
call UpdateSprites
ret
@ -644,7 +644,7 @@ NamePlayer:
call RotateThreePalettesRight
call ClearTilemap
call LoadFontsExtra
call LoadFrame
call WaitBGMap
xor a
@ -732,7 +732,7 @@ ShrinkPlayer:
call DelayFrames
call Intro_PlacePlayerSprite
call LoadFontsExtra
call LoadFrame
ld c, 50
call DelayFrames
@ -1107,7 +1107,7 @@ DeleteSaveData:
Copyright:
call ClearTilemap
call LoadFontsExtra
call LoadFrame
ld de, CopyrightGFX
ld hl, vTiles2 tile $60
lb bc, BANK(CopyrightGFX), 29

View File

@ -210,7 +210,7 @@ ClearTilemapEtc:
xor a
ldh [hMapAnims], a
call ClearTilemap
call LoadFontsExtra
call LoadFrame
call LoadStandardFont
call ClearWindowData
ret

View File

@ -820,7 +820,7 @@ LoadNamingScreenGFX:
call ClearSprites
callfar ClearSpriteAnims
call LoadStandardFont
call LoadFontsExtra
call LoadFrame
ld de, NamingScreenGFX_MiddleLine
ld hl, vTiles0 tile NAMINGSCREEN_MIDDLELINE

View File

@ -480,7 +480,7 @@ UpdateFrame:
hlcoord 16, 15 ; where on the screen the number is drawn
add "1"
ld [hl], a
call LoadFontsExtra
call LoadFrame
and a
ret

View File

@ -82,7 +82,7 @@ StartMenu::
push af
ld a, 1
ldh [hOAMUpdate], a
call LoadFontsExtra
call LoadFrame
pop af
ldh [hOAMUpdate], a
.ReturnEnd:

View File

@ -70,7 +70,7 @@ LoadFonts_NoOAMUpdate::
ret
.LoadGFX:
call LoadFontsExtra
call LoadFrame
ld a, $90
ldh [hWY], a
call SafeUpdateSprites

View File

@ -287,7 +287,7 @@ LoadMapGraphics:
xor a
ldh [hTileAnimFrame], a
farcall RefreshSprites
call LoadFontsExtra
call LoadFrame
farcall LoadOverworldFont
ret

View File

@ -35,7 +35,7 @@ NewPokedexEntry:
.ReturnFromDexRegistration:
call ClearTilemap
call LoadFontsExtra
call LoadFrame
call LoadStandardFont
farcall Pokedex_PlaceFrontpicTopLeftCorner
call WaitBGMap2

View File

@ -2410,7 +2410,7 @@ Pokedex_LoadGFX:
xor a
call ByteFill
call Pokedex_LoadInvertedFont
call LoadFontsExtra
call LoadFrame
ld hl, vTiles2 tile $60
ld bc, $20 tiles
call Pokedex_InvertTiles
@ -2494,7 +2494,7 @@ _NewPokedexEntry:
call Pokedex_ResetBGMapMode
call DisableLCD
call LoadStandardFont
call LoadFontsExtra
call LoadFrame
call Pokedex_LoadGFX
call Pokedex_LoadAnyFootprint
ld a, [wTempSpecies]

View File

@ -26,7 +26,7 @@ ReadAnyMail:
call ClearSprites
call ClearTilemap
call DisableLCD
call LoadFontsExtra
call LoadFrame
pop de
push de
ld hl, vTiles1

View File

@ -1,6 +1,3 @@
FontExtra:
INCBIN "gfx/font/font_extra.2bpp"
Font:
INCBIN "gfx/font/font.1bpp"
@ -35,9 +32,6 @@ INCBIN "gfx/battle/expbar.2bpp"
TownMapGFX:
INCBIN "gfx/pokegear/town_map.2bpp.lz"
PokegearPhoneIconGFX:
INCBIN "gfx/font/phone_icon.2bpp"
UnusedBoldFontGFX: ; unreferenced
INCBIN "gfx/font/unused_bold_font.1bpp"
@ -45,10 +39,4 @@ TextboxSpaceGFX:
; StatsScreen_LoadTextboxSpaceGFX reads 2bpp; LoadFrame reads first half as 1bpp
INCBIN "gfx/font/space.2bpp"
FontsExtra_SolidBlackGFX:
INCBIN "gfx/font/black.1bpp"
FontsExtra2_UpArrowGFX:
INCBIN "gfx/font/up_arrow.2bpp"
INCLUDE "gfx/footprints.asm"

Binary file not shown.

Before

Width:  |  Height:  |  Size: 68 B

Some files were not shown because too many files have changed in this diff Show More