pokecrystal-board/event/squirtbottle.asm

48 lines
736 B
NASM
Raw Normal View History

2015-11-11 20:38:57 -08:00
_Squirtbottle: ; 50730
2016-05-10 09:59:34 -07:00
ld hl, .SquirtbottleScript
2015-11-11 20:38:57 -08:00
call QueueScript
ld a, $1
2015-12-17 14:51:32 -08:00
ld [wItemEffectSucceeded], a
2015-11-11 20:38:57 -08:00
ret
2016-05-10 09:59:34 -07:00
.SquirtbottleScript:
2015-11-11 20:38:57 -08:00
reloadmappart
special UpdateTimePals
2016-05-10 09:59:34 -07:00
callasm .CheckCanUseSquirtbottle
iffalse .NothingHappenedScript
2015-11-11 20:38:57 -08:00
farjump WateredWeirdTreeScript
2016-05-10 09:59:34 -07:00
.NothingHappenedScript:
jumptext .NothingHappenedText
2015-11-11 20:38:57 -08:00
2016-05-10 09:59:34 -07:00
.NothingHappenedText:
2015-11-11 20:38:57 -08:00
; sprinkled water. But nothing happened…
text_jump UnknownText_0x1c0b3b
db "@"
2016-05-10 09:59:34 -07:00
.CheckCanUseSquirtbottle:
2015-11-11 20:38:57 -08:00
ld a, [MapGroup]
cp GROUP_ROUTE_36
2016-05-10 09:59:34 -07:00
jr nz, .nope
2015-11-11 20:38:57 -08:00
ld a, [MapNumber]
cp MAP_ROUTE_36
2016-05-10 09:59:34 -07:00
jr nz, .nope
2015-11-11 20:38:57 -08:00
callba GetFacingObject
2016-05-10 09:59:34 -07:00
jr c, .nope
2015-11-11 20:38:57 -08:00
ld a, d
2016-05-10 09:59:34 -07:00
cp SPRITEMOVEDATA_SUDOWOODO
jr nz, .nope
2015-11-11 20:38:57 -08:00
2016-05-10 09:59:34 -07:00
ld a, 1
2015-11-11 20:38:57 -08:00
ld [ScriptVar], a
ret
2016-05-10 09:59:34 -07:00
.nope
2015-11-11 20:38:57 -08:00
xor a
ld [ScriptVar], a
ret
; 50779