shithub: pokecrystal

Download patch

ref: 7ab8f76117e13a192a1f4f797ee73c48f6154cff
parent: 60e19487a7a94021605805d07149e677ad1cbb96
author: yenatch <[email protected]>
date: Mon Mar 3 17:53:43 EST 2014

Label map trigger functions in home.asm.

--- a/engine/scripting.asm
+++ b/engine/scripting.asm
@@ -1884,7 +1884,7 @@
 	ld b, a
 	call GetScriptByte
 	ld c, a
-	call Function2147
+	call GetMapTrigger
 	ld a, d
 	or e
 	jr z, .asm_975e5 ; 0x975de $5
@@ -1923,7 +1923,7 @@
 	; fallthrough
 
 Unknown_975fd: ; 0x975fd
-	call Function2147
+	call GetMapTrigger
 	ld a, d
 	or e
 	jr z, .asm_97608 ; 0x97602 $4
--- a/home/map.asm
+++ b/home/map.asm
@@ -24,7 +24,7 @@
 	ret
 ; 212a
 
-Function212a:: ; 212a
+GetCurrentMapTrigger:: ; 212a
 	ld a, [MapGroup]
 	ld b, a
 	ld a, [MapNumber]
@@ -32,7 +32,7 @@
 	xor a
 	ld [$dbf7], a
 	ld [$dbf8], a
-	call Function2147
+	call GetMapTrigger
 	ret c
 	ld a, e
 	ld [$dbf7], a
@@ -42,14 +42,14 @@
 	ret
 ; 2147
 
-Function2147:: ; 2147
+GetMapTrigger:: ; 2147
 	push bc
 	ld a, [hROMBank]
 	push af
-	ld a, BANK(Unknown_4d01e)
+	ld a, BANK(MapTriggers)
 	rst Bankswitch
 
-	ld hl, Unknown_4d01e
+	ld hl, MapTriggers
 .asm_2151
 	push hl
 	ld a, [hli]
--- a/main.asm
+++ b/main.asm
@@ -53815,7 +53815,7 @@
 	ret
 ; 4d01e
 
-Unknown_4d01e:: ; 4d01e
+MapTriggers:: ; 4d01e
 ; Map triggers
 
 trigger_def: MACRO
@@ -92098,7 +92098,7 @@
 	call Function210f
 	call Function2e50
 	call Function2e5d
-	call Function212a
+	call GetCurrentMapTrigger
 	call Function2e56
 	ld a, $5
 	call Function263b
@@ -98752,7 +98752,7 @@
 	ld b, a
 	ld a, [MapNumber]
 	ld c, a
-	call Function2147
+	call GetMapTrigger
 	ld a, d
 	or e
 	jr z, .asm_11b872