- 7
- Posts
- 5
- Years
- Seen Oct 3, 2019
I am trying to make a script to turn the player around if they try to enter a door I placed in Oak's lab (Fire Red). The script seems to work in the beginning, before trying to leave Pallet Town, but after Oak brings you to his lab it no longer works. Here is my code so far.
I am attempting to use flag 0x2B to check if Oak is there or not, as that is his ID in that map. To summarize, the issue I'm having SEEMS to be that after this line
if the flag is set (Oak is hidden), it operates as intended. If the flag is not set (Oak is visible in the lab), the script appears to do nothing which I take to mean that it terminates after reading the if statement.
Any help or suggestions are appreciated!
Spoiler:
Code:
#dynamic 0x800000
#org @start
lock
checkflag 0x2B
if 0x1 goto @gone
applymovement 0x4 @excl
waitmovement 0x0
msgbox @1 0x6
applymovement 0x4 @down
waitmovement 0x0
applymovement 0xFF @step
waitmovement 0x0
release
end
#org @gone
msgbox @2 0x6
applymovement 0xFF @step
waitmovement 0x0
release
end
#org @excl
#raw 0x3
#raw 0x62
#raw 0xFE
#org @1
= [blue_fr]OAK: I have important research\nback there!\pPlease keep out!
#org @2
= You don't know what's back there!\pBest not to snoop around!
#org @down
#raw 0x0
#raw 0xFE
#org @step
#raw 0x0
#raw 0x10
#raw 0xFE
Code:
if 0x1 goto @gone
Any help or suggestions are appreciated!
Last edited: