aboutsummaryrefslogtreecommitdiffstats
path: root/yellow/bank3d/random.asm
diff options
context:
space:
mode:
authorluckytyphlosion <alan.rj.huang@gmail.com>2015-05-17 18:21:24 -0400
committerluckytyphlosion <alan.rj.huang@gmail.com>2015-05-17 18:21:24 -0400
commitb5f5a16f43ef62680f09666073f07911306e1561 (patch)
treeb62055647e8b02b8d0341639b398f1ed1a1913a2 /yellow/bank3d/random.asm
parentCreate main.asm (diff)
downloadpokeyellow-b5f5a16f43ef62680f09666073f07911306e1561.tar.gz
pokeyellow-b5f5a16f43ef62680f09666073f07911306e1561.tar.xz
pokeyellow-b5f5a16f43ef62680f09666073f07911306e1561.zip
Completed home/overworld.asm with other related functions
Diffstat (limited to 'yellow/bank3d/random.asm')
-rw-r--r--yellow/bank3d/random.asm30
1 files changed, 15 insertions, 15 deletions
diff --git a/yellow/bank3d/random.asm b/yellow/bank3d/random.asm
index b7fb0edd..c7245c3e 100644
--- a/yellow/bank3d/random.asm
+++ b/yellow/bank3d/random.asm
@@ -1,15 +1,15 @@
-SECTION "bank3d",ROMX[$67DC],BANK[$3D]
-
-Random_::
-; Generate a random 16-bit value.
- ld a, [rDIV]
- ld b, a
- ld a, [hRandomAdd]
- adc b
- ld [hRandomAdd], a
- ld a, [rDIV]
- ld b, a
- ld a, [hRandomSub]
- sbc b
- ld [hRandomSub], a
- ret
+SECTION "bank3d",ROMX[$67DC],BANK[$3D]
+
+Random_::
+; Generate a random 16-bit value.
+ ld a, [rDIV]
+ ld b, a
+ ld a, [hRandomAdd]
+ adc b
+ ld [hRandomAdd], a
+ ld a, [rDIV]
+ ld b, a
+ ld a, [hRandomSub]
+ sbc b
+ ld [hRandomSub], a
+ ret