The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Fan Games > Binary ROM Hacking
Reload this Page Script Pokemon Fire Red Rockfall Script

Notices
For all updates, view the main page.

Binary ROM Hacking Need a helping hand or just want to talk about binary ROM hacks? Get comments and answers to any ROM Hacking-related problems, questions or thoughts you have here.

Ad Content
Reply
 
Thread Tools
  #1   Link to this post, but load the entire thread.  
Old August 22nd, 2018 (2:13 PM).
buhing5 buhing5 is offline
 
Join Date: Aug 2018
Posts: 1
Hi there!

I'm currently working on a Pokemon Fire Red hack which centers around Misty after she returns to Kanto. I have a point in Mt. Moon where I want an earthquake to happen and rocks to "fall" (per-say) and block the main route. The script I have below works for the earthquake and to move the rocks. However, once the player leaves sight of the rocks they all return to the original position. Is there anything I'm missing/can add to make the position stay?

Thanks for any advice!

Spoiler:
#dynamic 0x800200

#org @start
lock
checkflag 0x259
if 0x1 goto @done
setvar 0x8004 0x4
setvar 0x8005 0x4
setvar 0x8006 0x9
setvar 0x8007 0x4
special 0x136
fadescreen 0x1
applymovement 0xB @move11
applymovement 0xC @move12
applymovement 0xD @move11
applymovement 0xE @move11
applymovement 0xF @move12
waitmovement 0x0
fadescreen 0x0
setvar 0x8004 0x4
setvar 0x8005 0x4
setvar 0x8006 0x9
setvar 0x8007 0x4
special 0x136
fadescreen 0x1
applymovement 0x10 @move12
applymovement 0x11 @move2
applymovement 0x12 @move12
applymovement 0x13 @move11
applymovement 0x14 @move13
waitmovement 0x0
fadescreen 0x0
applymovement 0xFF @move
waitmovement 0x0
textcolor 0x01
msgbox @1 0x6
setflag 0x259
setvar 0x8008 0x1
release
end

#org @done
release
end

#org @move
#raw 0x62
#raw 0xFE

#org @move2
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0xFE

#org @move11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0xFE

#org @move12
#raw 0x11
#raw 0x11
#raw 0xFE

#org @move13
#raw 0x11
#raw 0xFE

#org @1
= Hm...\pGuess I'll have to find a\ndifferent way around.

?
Reply With Quote
  #2   Link to this post, but load the entire thread.  
Old August 24th, 2018 (3:09 PM).
Skeli's Avatar
Skeli Skeli is offline
Lord of the Rings
 
Join Date: Apr 2014
Location: Canada
Age: 24
Gender: Male
Nature: Adamant
Posts: 300
First, you need to add the following in your script somewhere after the last waitmovement 0x0:
Code:
call @movesprite

#org @movesprite
movesprite2 0x[Person Event #] 0x[X-Coordinate] 0x[Y-Coordinate]
movesprite2 0x[Person Event #] 0x[X-Coordinate] 0x[Y-Coordinate]
movesprite2 0x[Person Event #] 0x[X-Coordinate] 0x[Y-Coordinate]
movesprite2 0x[Person Event #] 0x[X-Coordinate] 0x[Y-Coordinate]
...
return
Change the movesprite2s to match your rocks and they should stay in place. You can always add more than what I've shown above.

So, for example, say you wanted to move rocks 0xB and 0xC to x-coordinates 0x7 & 0x8 respectively, and y-coordinates 0x9 & 0xA respectively, your script would like this:
Code:
#org @movesprite
movesprite2 0xB 0x7 0x9
movesprite2 0xC 0x8 0xA
return
Also, you need to add a On entering map/not on menu close [03] level script to your map. It should look something like this.
Code:
checkflag 0x259
if true call @movesprite
end
Where @movesprite refers to that @movesprite from the previous code.
__________________
Pokemon Unbound

Reply With Quote
Reply

Quick Reply

Join the conversation!

Create an account to post a reply in this thread, participate in other discussions, and more!

Create a PokéCommunity Account
Ad Content

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 9:18 AM.