mirror of https://github.com/pret/pokecrystal.git
174 lines
3.3 KiB
NASM
174 lines
3.3 KiB
NASM
GoldenrodDeptStore6F_MapScriptHeader:
|
|
; trigger count
|
|
db 0
|
|
|
|
; callback count
|
|
db 0
|
|
|
|
GoldenrodVendingMachine:
|
|
loadfont
|
|
writetext GoldenrodVendingText
|
|
.Start
|
|
special Function24ae8
|
|
loadmenudata .MenuData
|
|
interpretmenu2
|
|
writebackup
|
|
if_equal $1, .FreshWater
|
|
if_equal $2, .SodaPop
|
|
if_equal $3, .Lemonade
|
|
loadmovesprites
|
|
end
|
|
|
|
.FreshWater
|
|
checkmoney $0, 200
|
|
if_equal $2, .NotEnoughMoney
|
|
giveitem FRESH_WATER, $1
|
|
iffalse .NotEnoughSpace
|
|
takemoney $0, 200
|
|
itemtotext FRESH_WATER, $0
|
|
jump .VendItem
|
|
|
|
.SodaPop
|
|
checkmoney $0, 300
|
|
if_equal $2, .NotEnoughMoney
|
|
giveitem SODA_POP, $1
|
|
iffalse .NotEnoughSpace
|
|
takemoney $0, 300
|
|
itemtotext SODA_POP, $0
|
|
jump .VendItem
|
|
|
|
.Lemonade
|
|
checkmoney $0, 350
|
|
if_equal $2, .NotEnoughMoney
|
|
giveitem LEMONADE, $1
|
|
iffalse .NotEnoughSpace
|
|
takemoney $0, 350
|
|
itemtotext LEMONADE, $0
|
|
jump .VendItem
|
|
|
|
.VendItem
|
|
pause 10
|
|
playsound SFX_ENTER_DOOR
|
|
writetext GoldenrodClangText
|
|
keeptextopen
|
|
itemnotify
|
|
jump .Start
|
|
|
|
.NotEnoughMoney
|
|
writetext GoldenrodVendingNoMoneyText
|
|
closetext
|
|
jump .Start
|
|
|
|
.NotEnoughSpace
|
|
writetext GoldenrodVendingNoSpaceText
|
|
closetext
|
|
jump .Start
|
|
|
|
.MenuData
|
|
db $40 ; flags
|
|
db 02, 00 ; start coords
|
|
db 11, 19 ; end coords
|
|
dw .MenuData2
|
|
db 1 ; default option
|
|
|
|
.MenuData2
|
|
db $80 ; flags
|
|
db 4 ; items
|
|
db "FRESH WATER ¥200@"
|
|
db "SODA POP ¥300@"
|
|
db "LEMONADE ¥350@"
|
|
db "CANCEL@"
|
|
|
|
|
|
LassScript_0x564bf:
|
|
jumptextfaceplayer UnknownText_0x5654b
|
|
|
|
SuperNerdScript_0x564c2:
|
|
jumptextfaceplayer UnknownText_0x565ca
|
|
|
|
GoldenrodDeptStore6FDirectory:
|
|
jumptext GoldenrodDeptStore6FDirectoryText
|
|
|
|
GoldenrodDeptStore6FElevatorButton:
|
|
jumpstd elevatorbutton
|
|
|
|
GoldenrodVendingText:
|
|
text "A vending machine!"
|
|
line "Here's the menu."
|
|
done
|
|
|
|
GoldenrodClangText:
|
|
text "Clang! A can of"
|
|
line "@"
|
|
text_from_ram StringBuffer3
|
|
text $55
|
|
db "popped out!"
|
|
done
|
|
|
|
GoldenrodVendingNoMoneyText:
|
|
text "Oops, not enough"
|
|
line "money."
|
|
done
|
|
|
|
GoldenrodVendingNoSpaceText:
|
|
text "There's no more"
|
|
line "room for stuff."
|
|
done
|
|
|
|
UnknownText_0x5654b:
|
|
text "Do you listen to"
|
|
line "LUCKY CHANNEL?"
|
|
|
|
para "If you want to"
|
|
line "win, trade #MON"
|
|
|
|
para "with as many peo-"
|
|
line "ple as possible to"
|
|
|
|
para "get different ID"
|
|
line "numbers."
|
|
done
|
|
|
|
UnknownText_0x565ca:
|
|
text "If you're tired,"
|
|
line "try the vending"
|
|
cont "machine's drinks."
|
|
|
|
para "Your #MON will"
|
|
line "love them too."
|
|
done
|
|
|
|
GoldenrodDeptStore6FDirectoryText:
|
|
text "Take a Break from"
|
|
line "Shopping!"
|
|
|
|
para "6F TRANQUIL SQUARE"
|
|
done
|
|
|
|
GoldenrodDeptStore6F_MapEventHeader:
|
|
; filler
|
|
db 0, 0
|
|
|
|
; warps
|
|
db 3
|
|
warp_def $0, $f, 2, GROUP_GOLDENROD_DEPT_STORE_5F, MAP_GOLDENROD_DEPT_STORE_5F
|
|
warp_def $0, $2, 1, GROUP_GOLDENROD_DEPT_STORE_ELEVATOR, MAP_GOLDENROD_DEPT_STORE_ELEVATOR
|
|
warp_def $0, $d, 1, GROUP_GOLDENROD_DEPT_STORE_ROOF, MAP_GOLDENROD_DEPT_STORE_ROOF
|
|
|
|
; xy triggers
|
|
db 0
|
|
|
|
; signposts
|
|
db 6
|
|
signpost 0, 14, $0, GoldenrodDeptStore6FDirectory
|
|
signpost 0, 3, $0, GoldenrodDeptStore6FElevatorButton
|
|
signpost 1, 8, $1, GoldenrodVendingMachine
|
|
signpost 1, 9, $1, GoldenrodVendingMachine
|
|
signpost 1, 10, $1, GoldenrodVendingMachine
|
|
signpost 1, 11, $1, GoldenrodVendingMachine
|
|
|
|
; people-events
|
|
db 2
|
|
person_event SPRITE_LASS, 6, 14, $5, $1, 255, 255, $a0, 0, LassScript_0x564bf, $ffff
|
|
person_event SPRITE_SUPER_NERD, 6, 12, $7, $0, 255, 255, $80, 0, SuperNerdScript_0x564c2, $ffff
|