The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Fan Games > Binary ROM Hacking
Reload this Page Script Pokémon FireRed: Disabling the One Island event (SOLVED)

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 May 3rd, 2018 (12:39 AM). Edited May 7th, 2018 by Ebontope.
Ebontope's Avatar
Ebontope Ebontope is offline
 
Join Date: Dec 2017
Posts: 162
I'm working on a simple romhack for a friend of mine, who wanted something different from a standard randomized Pokémon FireRed playthrough. As a part of this, I want to disable the One Island event that takes place after beating the Cinnabar Gym.

If possible, I want to change the script so that instead of giving you the option to go to One Island, Bill instead gives you HM06 (Rock Smash). However, although I can find the strings of the event with Advance-Text, when I search for the offset of these strings XSE comes up with nothing.

Alternatively, I just want to disable the event entirely. I have noticed that the script that triggers upon defeating the Gym Leader is different for Blaine in comparison to that of the other Gym Leaders, so I assume the event must be activated here, but I don't know which parts are safe to erase and which parts would break the game when erased.

Could anybody look into this and give me a hand?
Reply With Quote
  #2   Link to this post, but load the entire thread.  
Old May 3rd, 2018 (11:44 PM). Edited May 4th, 2018 by DrFuji.
DrFuji's Avatar
DrFuji DrFuji is offline
Heiki Hecchara‌‌
 
Join Date: Sep 2009
Location: Aussie
Age: 30
Gender: Male
Nature: Jolly
Posts: 1,693
The full script can be found at 0x166FCD. I have no idea why its not showing up properly in A-Map, but oh well :/

Here's an edited version of the script which has Bill give you HM06:

Spoiler:
#dynamic 0x800000

#org 0x166FCD
goto @Repoint

#org @Repoint
lockall
textcolor 0x0
checkflag 0x2
if 0x0 call @Call1
checkflag 0x2
if 0x1 call @Call2
sound 0x15
applymovement 0x3 @Move1
waitmovement 0x0
applymovement 0x3 @Move2
waitmovement 0x0
checkflag 0x2
if 0x0 call @Call3
checkflag 0x2
if 0x1 call @Call4
msgbox @Talk1 0x6
msgbox @Talk2 0x6
fanfare 0x101
giveitem 0x158 0x1 0x0
waitfanfare
msgbox @Talk3 0x6
closeonkeypress
checkflag 0x2
if 0x0 call @Call5
checkflag 0x2
if 0x1 call @Call6
hidesprite 0x3
setvar 0x4071 0x2
clearflag 0xA2
releaseall
end

#org @Call1
applymovement 0x3 @Move3
waitmovement 0x0
return

#org @Call2
applymovement 0x3 @Move4
waitmovement 0x0
return

#org @Call3
applymovement 0x3 @Move5
waitmovement 0x0
return

#org @Call4
applymovement 0x3 @Move6
waitmovement 0x0
applymovement 0xFF @Move7
waitmovement 0x0
return

#org @Call5
applymovement 0x3 @Move8
waitmovement 0x0
return

#org @Call6
applymovement 0xFF @Move9
applymovement 0x3 @Move10
waitmovement 0x0
setdooropened 0xE 0xB
doorchange
applymovement 0x3 @Move11
waitmovement 0x0
setdoorclosed 0xE 0xB
doorchange
return

#org @Talk1
= Huh?\nHey, if it isn't [player]!

#org @Talk2
= Look, it's me, BILL.\nLong time no see!\pI hope you're still using my\nPC system.\pHere's something that I hope you\nwill find useful!

#org 0x180EAD
= [player] received HM06\nfrom BILL.

#org @Talk3
= It was great to see you again.\nDrop by once in a while to say hi!

#org @Move1
#raw 0x62
#raw 0xFE

#org @Move2
#raw 0x1C
#raw 0x1C
#raw 0x1C
#raw 0xFE

#org @Move3
#raw 0x2E
#raw 0xFE

#org @Move4
#raw 0x2F
#raw 0xFE

#org @Move5
#raw 0x11
#raw 0xFE

#org @Move6
#raw 0x12
#raw 0x12
#raw 0x12
#raw 0xFE

#org @Move7
#raw 0x30
#raw 0xFE

#org @Move8
#raw 0x13
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0xFE

#org @Move9
#raw 0x12
#raw 0x30
#raw 0xFE

#org @Move10
#raw 0x1C
#raw 0x12
#raw 0x2E
#raw 0xFE

#org @Move11
#raw 0x11
#raw 0x1A
#raw 0x60
#raw 0xFE


Just compile it and don't do anything with the offsets it give you. Since we're unable to properly edit it in A-Map this script will go to 0x166FCD before immediately branching away to the new dynamic offset chosen for @Repoint.
__________________
Reply With Quote
  #3   Link to this post, but load the entire thread.  
Old May 5th, 2018 (6:43 AM).
Cuetecillos Cuetecillos is offline
 
Join Date: May 2018
Posts: 3
Oh, thanks for the response, i want to change this script too. I have a question, Where is the location of these script in the A-Map? I tried to searching this script, but i can´t find it.
Reply With Quote
  #4   Link to this post, but load the entire thread.  
Old May 7th, 2018 (6:29 AM).
Ebontope's Avatar
Ebontope Ebontope is offline
 
Join Date: Dec 2017
Posts: 162
I've just been able to test this script and it worked like a charm! Thank you so much!


Quote:
Originally Posted by Cuetecillos View Post
Oh, thanks for the response, i want to change this script too. I have a question, Where is the location of these script in the A-Map? I tried to searching this script, but i can´t find it.
It doesn't seem to be displayed in A-Map at all for some reason. But by making 0x166FCD redirect to a new script, you can essentially change the event to whatever you want.
Reply With Quote
  #5   Link to this post, but load the entire thread.  
Old May 11th, 2018 (12:59 PM).
Cuetecillos Cuetecillos is offline
 
Join Date: May 2018
Posts: 3
I see, one question, How do you know that this offset (0x166FCD) corresponds to the One Island Event? which program indicates this? thanks. I have this dude because I´m searching scripts that no appear i n the A-Map (For example, the first battle agaisnt the Rival in teh Oak's Lab and this one).
Reply With Quote
  #6   Link to this post, but load the entire thread.  
Old May 12th, 2018 (3:07 AM).
DrFuji's Avatar
DrFuji DrFuji is offline
Heiki Hecchara‌‌
 
Join Date: Sep 2009
Location: Aussie
Age: 30
Gender: Male
Nature: Jolly
Posts: 1,693
Quote:
Originally Posted by Cuetecillos View Post
I see, one question, How do you know that this offset (0x166FCD) corresponds to the One Island Event? which program indicates this? thanks. I have this dude because I´m searching scripts that no appear i n the A-Map (For example, the first battle agaisnt the Rival in teh Oak's Lab and this one).
I was able to find the correct offset by opening a ROM in a HEX editor, going to 0x166F88 (the incorrect script offset displayed in A-Map) and backtracking until I reached the start of the script.

The first battle with your rival is actually fully visible in A-Map. The three script tiles in the middle of the lab have a second layer underneath, just move the ones on top out of the way and you'll be able to see it.
__________________
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
Thread Tools

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:14 AM.