shithub: pokecrystal

Download patch

ref: 5fbd2fb8ba74e10ce5a493b83b911a8e8f888549
parent: d9d688df4e4cdce07991856b13e9cf579de45bd4
parent: df337fc417b8de58ab0b2bfc4dd8fa488f9fd3b8
author: Rangi <35663410+Rangi42@users.noreply.github.com>
date: Sat Feb 16 07:49:18 EST 2019

Merge pull request #602 from Rangi42/master

Update to rgbds 0.3.8

--- a/FAQ.md
+++ b/FAQ.md
@@ -32,7 +32,7 @@
 
 ### "ERROR: `UNION` already defined"
 
-Download [**rgbds 0.3.7**][rgbds]. Older versions will not work.
+Download [**rgbds 0.3.8**][rgbds]. Older versions will not work.
 
 ### "Segmentation fault" from `rgbgfx`
 
--- a/INSTALL.md
+++ b/INSTALL.md
@@ -38,7 +38,7 @@
 
 Then download [**rgbds**](https://github.com/rednex/rgbds/releases/): the latest **win64.zip** or **win32.zip** release. Extract it and put all the `exe` and `dll` files individually in **C:\cygwin64\usr\local\bin**.
 
-**Note: If you already have an older rgbds, you will need to update to 0.3.7.** Ignore this if you have never installed rgbds before. If a version newer than 0.3.7 does not work, try downloading 0.3.7.
+**Note: If you already have an older rgbds, you will need to update to 0.3.8.** Ignore this if you have never installed rgbds before. If a version newer than 0.3.8 does not work, try downloading 0.3.8.
 
 Now open the **Cygwin terminal** and enter the following commands.
 
--- a/engine/battle/battle_transition.asm
+++ b/engine/battle/battle_transition.asm
@@ -6,7 +6,7 @@
 BATTLETRANSITION_FINISH           EQU $20
 BATTLETRANSITION_END              EQU $80
 
-BATTLETRANSITION_SQUARE EQUS "\"8\"" ; $fe
+BATTLETRANSITION_SQUARE EQU "8" ; $fe
 
 DoBattleTransition:
 	call .InitGFX
--- a/engine/events/print_unown.asm
+++ b/engine/events/print_unown.asm
@@ -1,5 +1,5 @@
-UNOWNSTAMP_BOLD_A EQUS "\"♂\"" ; $ef
-UNOWNSTAMP_BOLD_B EQUS "\"♀\"" ; $f5
+UNOWNSTAMP_BOLD_A EQU "♂" ; $ef
+UNOWNSTAMP_BOLD_B EQU "♀" ; $f5
 
 _UnownPrinter:
 	ld a, [wUnownDex]
--- a/engine/games/card_flip.asm
+++ b/engine/games/card_flip.asm
@@ -1,5 +1,5 @@
-CARDFLIP_LIGHT_OFF EQUS "\"♂\"" ; $ef
-CARDFLIP_LIGHT_ON  EQUS "\"♀\"" ; $f5
+CARDFLIP_LIGHT_OFF EQU "♂" ; $ef
+CARDFLIP_LIGHT_ON  EQU "♀" ; $f5
 
 CARDFLIP_DECK_SIZE EQU 4 * 6
 
--- a/engine/gfx/load_push_oam.asm
+++ b/engine/gfx/load_push_oam.asm
@@ -4,7 +4,7 @@
 	ld hl, .PushOAM
 .loop
 	ld a, [hli]
-	ld [$ff00+c], a
+	ldh [c], a
 	inc c
 	dec b
 	jr nz, .loop
--- a/engine/link/mystery_gift.asm
+++ b/engine/link/mystery_gift.asm
@@ -256,7 +256,7 @@
 	jr c, .ly_loop
 	ld c, LOW(rRP)
 	ld a, $c0
-	ld [$ff00+c], a
+	ldh [c], a
 	ld b, 240 ; This might have been intended as a 4-second timeout buffer.
 	          ; However, it is reset with each frame.
 .loop3
@@ -267,7 +267,7 @@
 	ld c, LOW(rRP)
 	; Delay frame
 .ly_loop2
-	ld a, [$ff00+c]
+	ldh a, [c]
 	and b
 	ld b, a
 	ldh a, [rLY]
@@ -274,7 +274,7 @@
 	cp LY_VBLANK
 	jr nc, .ly_loop2
 .ly_loop3
-	ld a, [$ff00+c]
+	ldh a, [c]
 	and b
 	ld b, a
 	ldh a, [rLY]
@@ -657,7 +657,7 @@
 	xor a
 	ldh [rIF], a
 	halt
-	ld a, [$ff00+c]
+	ldh a, [c]
 	bit 1, a
 	jr z, Function104da9
 	or a
@@ -669,7 +669,7 @@
 	xor a
 	ldh [rIF], a
 	halt
-	ld a, [$ff00+c]
+	ldh a, [c]
 	bit 1, a
 	jr nz, Function104db7
 	or a
@@ -677,7 +677,7 @@
 
 Function104dc5:
 	ld a, $c1
-	ld [$ff00+c], a
+	ldh [c], a
 .wait
 	dec d
 	ret z
@@ -688,7 +688,7 @@
 
 Function104dd1:
 	ld a, $c0
-	ld [$ff00+c], a
+	ldh [c], a
 .wait
 	dec d
 	ret z
@@ -716,7 +716,7 @@
 .next
 	bit 0, a
 	jr nz, Function104e3a
-	ld a, [$ff00+c]
+	ldh a, [c]
 	and b
 	jr nz, .loop
 
@@ -997,7 +997,7 @@
 .asm_104fdb
 	inc d
 	jr z, .asm_104fe5
-	ld a, [$ff00+c]
+	ldh a, [c]
 	bit 1, a
 	jr z, .asm_104fdb
 	ld d, $0
@@ -1004,7 +1004,7 @@
 .asm_104fe5
 	inc d
 	jr z, .asm_104fed
-	ld a, [$ff00+c]
+	ldh a, [c]
 	bit 1, a
 	jr nz, .asm_104fe5
 .asm_104fed
--- a/engine/menus/naming_screen.asm
+++ b/engine/menus/naming_screen.asm
@@ -1,8 +1,8 @@
 NAMINGSCREEN_CURSOR     EQU $7e
 
-NAMINGSCREEN_BORDER     EQUS "\"■\"" ; $60
-NAMINGSCREEN_MIDDLELINE EQUS "\"→\"" ; $eb
-NAMINGSCREEN_UNDERLINE  EQUS "\"<DOT>\"" ; $f2
+NAMINGSCREEN_BORDER     EQU "■" ; $60
+NAMINGSCREEN_MIDDLELINE EQU "→" ; $eb
+NAMINGSCREEN_UNDERLINE  EQU "<DOT>" ; $f2
 
 _NamingScreen:
 	call DisableSpriteUpdates
--- a/engine/menus/savemenu_copytilemapatonce.asm
+++ b/engine/menus/savemenu_copytilemapatonce.asm
@@ -53,7 +53,7 @@
 rept SCREEN_WIDTH / 2
 	pop de
 .loop\@
-	ld a, [$ff00+c]
+	ldh a, [c]
 	and b
 	jr nz, .loop\@
 	ld [hl], e
--- a/engine/movie/trade_animation.asm
+++ b/engine/movie/trade_animation.asm
@@ -1,5 +1,5 @@
-TRADEANIM_RIGHT_ARROW EQUS "\"▶\"" ; $ed
-TRADEANIM_LEFT_ARROW  EQUS "\"▼\"" ; $ee
+TRADEANIM_RIGHT_ARROW EQU "▶" ; $ed
+TRADEANIM_LEFT_ARROW  EQU "▼" ; $ee
 
 ; TradeAnim_TubeAnimJumptable.Jumptable indexes
 	const_def
--- a/engine/phone/phonering_copytilemapatonce.asm
+++ b/engine/phone/phonering_copytilemapatonce.asm
@@ -56,7 +56,7 @@
 rept SCREEN_WIDTH / 2
 	pop de
 .loop\@
-	ld a, [$ff00+c]
+	ldh a, [c]
 	and b
 	jr nz, .loop\@
 	ld [hl], e
--- a/engine/printer/print_party.asm
+++ b/engine/printer/print_party.asm
@@ -1,4 +1,4 @@
-PRINTPARTY_HP EQUS "\"◀\"" ; $71
+PRINTPARTY_HP EQU "◀" ; $71
 
 PrintPage1:
 	hlcoord 0, 0
--- a/engine/rtc/timeset.asm
+++ b/engine/rtc/timeset.asm
@@ -1,5 +1,5 @@
-TIMESET_UP_ARROW   EQUS "\"♂\"" ; $ef
-TIMESET_DOWN_ARROW EQUS "\"♀\"" ; $f5
+TIMESET_UP_ARROW   EQU "♂" ; $ef
+TIMESET_DOWN_ARROW EQU "♀" ; $f5
 
 InitClock:
 ; Ask the player to set the time.
--- a/home/lcd.asm
+++ b/home/lcd.asm
@@ -6,7 +6,7 @@
 	ret nz
 	ld c, a
 	ld a, [wLYOverrides]
-	ld [$ff00+c], a
+	ldh [c], a
 	ret
 
 LCD::
@@ -25,7 +25,7 @@
 	ldh a, [hLCDCPointer]
 	ld c, a
 	ld a, b
-	ld [$ff00+c], a
+	ldh [c], a
 	pop bc
 
 .done
--- a/home/palettes.asm
+++ b/home/palettes.asm
@@ -33,7 +33,7 @@
 .bgp
 rept (1 palettes) * 2
 	ld a, [hli]
-	ld [$ff00+c], a
+	ldh [c], a
 endr
 
 	dec b
@@ -49,7 +49,7 @@
 .obp
 rept (1 palettes) * 2
 	ld a, [hli]
-	ld [$ff00+c], a
+	ldh [c], a
 endr
 
 	dec b
--- a/home/tilemap.asm
+++ b/home/tilemap.asm
@@ -119,7 +119,7 @@
 	pop de
 ; if in v/hblank, wait until not in v/hblank
 .loop\@
-	ld a, [$ff00+c]
+	ldh a, [c]
 	and b
 	jr nz, .loop\@
 ; load BGMap0
--- a/lib/mobile/main.asm
+++ b/lib/mobile/main.asm
@@ -215,9 +215,9 @@
 	ld [$c815], a
 	ld c, $7
 	ld a, $2
-	ld [$ff00+c], a
+	ldh [c], a
 	ld a, $6
-	ld [$ff00+c], a
+	ldh [c], a
 	ret
 
 Function110115:
@@ -604,9 +604,9 @@
 
 Function110393:
 	ld c, LOW(rIE)
-	ld a, [$ff00+c]
+	ldh a, [c]
 	or $c
-	ld [$ff00+c], a
+	ldh [c], a
 	ret
 
 Function11039a:
@@ -3416,9 +3416,9 @@
 	xor a
 	ldh [rTAC], a
 	ld c, $ff
-	ld a, [$ff00+c]
+	ldh a, [c]
 	and $f3
-	ld [$ff00+c], a
+	ldh [c], a
 	ld a, [$cb48]
 	ld [$c86a], a
 	ld a, [$cb47]