2019-01-01 20:06:23 +00:00
|
|
|
Route7Gate_Script:
|
2014-05-18 18:19:10 +00:00
|
|
|
call EnableAutoTextBoxDrawing
|
2015-08-31 02:38:41 +00:00
|
|
|
ld a, [wRoute7GateCurScript]
|
2019-01-01 20:06:23 +00:00
|
|
|
ld hl, Route7Gate_ScriptPointers
|
2014-05-18 18:19:10 +00:00
|
|
|
call CallFunctionInTable
|
|
|
|
ret
|
|
|
|
|
2019-01-01 20:06:23 +00:00
|
|
|
Route7Gate_ScriptPointers:
|
2014-05-18 18:19:10 +00:00
|
|
|
dw Route7GateScript0
|
|
|
|
dw Route7GateScript1
|
|
|
|
|
2016-06-12 00:24:04 +00:00
|
|
|
Route7GateScript_1e111:
|
2014-05-26 21:04:56 +00:00
|
|
|
ld hl, wd730
|
2014-05-18 18:19:10 +00:00
|
|
|
set 7, [hl]
|
|
|
|
ld a, $20
|
2014-09-10 03:55:19 +00:00
|
|
|
ld [wSimulatedJoypadStatesEnd], a
|
2014-05-18 18:19:10 +00:00
|
|
|
ld a, $1
|
2014-09-10 03:55:19 +00:00
|
|
|
ld [wSimulatedJoypadStatesIndex], a
|
2014-05-18 18:19:10 +00:00
|
|
|
xor a
|
2020-07-05 21:29:11 +00:00
|
|
|
ld [wSpritePlayerStateData2MovementByte1], a
|
2014-09-10 03:55:19 +00:00
|
|
|
ld [wOverrideSimulatedJoypadStatesMask], a
|
2014-05-18 18:19:10 +00:00
|
|
|
ret
|
|
|
|
|
2016-06-12 00:24:04 +00:00
|
|
|
Route7GateScript0:
|
2014-05-26 21:04:56 +00:00
|
|
|
ld a, [wd728]
|
2014-05-18 18:19:10 +00:00
|
|
|
bit 6, a
|
|
|
|
ret nz
|
|
|
|
ld hl, CoordsData_1e167
|
|
|
|
call ArePlayerCoordsInArray
|
|
|
|
ret nc
|
2015-07-20 00:52:26 +00:00
|
|
|
ld a, PLAYER_DIR_UP
|
|
|
|
ld [wPlayerMovingDirection], a
|
2014-05-18 18:19:10 +00:00
|
|
|
xor a
|
2020-07-06 23:03:05 +00:00
|
|
|
ldh [hJoyHeld], a
|
2020-07-07 01:18:22 +00:00
|
|
|
farcall RemoveGuardDrink
|
2020-07-06 23:03:05 +00:00
|
|
|
ldh a, [hItemToRemoveID]
|
2014-05-18 18:19:10 +00:00
|
|
|
and a
|
2015-07-03 19:38:12 +00:00
|
|
|
jr nz, .asm_1e15a
|
2014-05-18 18:19:10 +00:00
|
|
|
ld a, $2
|
2020-07-06 23:03:05 +00:00
|
|
|
ldh [hSpriteIndexOrTextID], a
|
2014-05-18 18:19:10 +00:00
|
|
|
call DisplayTextID
|
|
|
|
call Route7GateScript_1e111
|
|
|
|
ld a, $1
|
2015-08-31 02:38:41 +00:00
|
|
|
ld [wRoute7GateCurScript], a
|
2014-05-18 18:19:10 +00:00
|
|
|
ret
|
|
|
|
.asm_1e15a
|
|
|
|
ld a, $3
|
2020-07-06 23:03:05 +00:00
|
|
|
ldh [hSpriteIndexOrTextID], a
|
2014-05-18 18:19:10 +00:00
|
|
|
call DisplayTextID
|
2014-05-26 21:04:56 +00:00
|
|
|
ld hl, wd728
|
2014-05-18 18:19:10 +00:00
|
|
|
set 6, [hl]
|
|
|
|
ret
|
|
|
|
|
2016-06-12 00:24:04 +00:00
|
|
|
CoordsData_1e167:
|
2014-05-18 18:19:10 +00:00
|
|
|
db 3,3
|
|
|
|
db 4,3
|
|
|
|
db $ff
|
|
|
|
|
2016-06-12 00:24:04 +00:00
|
|
|
Route7GateScript1:
|
2014-09-10 03:55:19 +00:00
|
|
|
ld a, [wSimulatedJoypadStatesIndex]
|
2014-05-18 18:19:10 +00:00
|
|
|
and a
|
|
|
|
ret nz
|
|
|
|
call Delay3
|
|
|
|
xor a
|
2014-05-25 17:51:53 +00:00
|
|
|
ld [wJoyIgnore], a
|
2015-08-31 02:38:41 +00:00
|
|
|
ld [wRoute7GateCurScript], a
|
|
|
|
ld [wCurMapScript], a
|
2014-05-18 18:19:10 +00:00
|
|
|
ret
|
|
|
|
|
2019-01-01 20:06:23 +00:00
|
|
|
Route7Gate_TextPointers:
|
2014-05-18 18:19:10 +00:00
|
|
|
dw Route7GateText1
|
|
|
|
dw Route7GateText2
|
|
|
|
dw Route7GateText3
|