aboutsummaryrefslogtreecommitdiffstats
path: root/home/predef_text.asm
blob: bdecd3cf16399a97e2d8ed4f115a5441264db67b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
PrintPredefTextID::
	ldh [hTextID], a
	ld hl, TextPredefs
	call SetMapTextPointer
	ld hl, wTextPredefFlag
	set 0, [hl]
	call DisplayTextID

RestoreMapTextPointer::
	ld hl, wCurMapTextPtr
	ldh a, [hSavedMapTextPtr]
	ld [hli], a
	ldh a, [hSavedMapTextPtr + 1]
	ld [hl], a
	ret

SetMapTextPointer::
	ld a, [wCurMapTextPtr]
	ldh [hSavedMapTextPtr], a
	ld a, [wCurMapTextPtr + 1]
	ldh [hSavedMapTextPtr + 1], a
	ld a, l
	ld [wCurMapTextPtr], a
	ld a, h
	ld [wCurMapTextPtr + 1], a
	ret

INCLUDE "data/text_predef_pointers.asm"