pokecrystal-board/engine/pokegear/townmap_convertlinebreakcharacters.asm
mid-kid 1fc7430a2b Fix misnamed character codes
Some character codes were erroneously named after their text command
counterparts. This has caused a lot of confusion with naming their
functions and with other things.

I've also removed the `dict2` macro and expanded the `dict` macro. This
really isn't something we should be doing for macros but I can't deny it
looks a lot neater than repeated code.
2018-07-18 10:55:30 +02:00

22 lines
263 B
NASM

TownMap_ConvertLineBreakCharacters:
ld hl, wStringBuffer1
.loop
ld a, [hl]
cp "@"
jr z, .end
cp "%"
jr z, .line_feed
cp "¯"
jr z, .line_feed
inc hl
jr .loop
.line_feed
ld [hl], "<LF>"
.end
ld de, wStringBuffer1
hlcoord 9, 0
call PlaceString
ret