The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Fan Games > Binary ROM Hacking
Reload this Page Script Scripts do not activate when stepped on

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 January 19th, 2020 (11:23 AM).
taipachi taipachi is offline
 
Join Date: Jan 2020
Posts: 7
I'm very new to ROM Hacks. Just started a couple days ago. Using LeafGreen.

All of my Person Event Scripts work really great.

But none of my Script Event tiles work. In the starting town I made, I have a Script Tile (Green S tile) that should activate when stepped on, if I understand scripts correctly.
However, nothing happens when I step on this tile.

My script had a bit more in it, but I took a lot out to make it as simple as possible, and still nothing happens.
When I compiled the script in XSE, I got an offset of 8001CB. So for the Script Event, the Script Offset field says $8001CB.
For the Variable Number, I used 4100. The Var Value is set at 0000.

There is probably some fundamental step I'm missing, but I really can't figure this one out. Any help is appreciated.
Script included below.

'----------------------------------------------------
#dynamic 0x800000
#org @start
lock
msgbox @t1 0x6
setvar 0x4100 0x1
release
end

#org @t1
= Hey you! You're finally awake!!
Reply With Quote
  #2   Link to this post, but load the entire thread.  
Old January 19th, 2020 (3:08 PM).
aymancero's Avatar
aymancero aymancero is offline
The chosen
 
Join Date: Nov 2018
Location: Madrid, Spain
Gender: Male
Posts: 2
Hey Taipichi, I could help but for the next time I recommend you to paste an image about where is happening your problem.
I think that your problem is on the tile configuration where you are putting your script.
You may go the configuration of the tile and corrected
If you didn't understood me you can say it and I will explain everything with details.
Have a nice day!
Reply With Quote
  #3   Link to this post, but load the entire thread.  
Old January 19th, 2020 (3:19 PM).
DrFuji's Avatar
DrFuji DrFuji is offline
Heiki Hecchara‌‌
 
Join Date: Sep 2009
Location: Aussie
Age: 30
Gender: Male
Nature: Jolly
Posts: 1,693
First off, Leaf Green isn't well supported or known about, especially when compared to FireRed so I'd suggest changing your base as I can guarantee that you're going to experience compatibility errors the deeper you get into hacking.

Your script is properly structure to step onto a tile, activate it and not have it activate again - the error is with the variable you've chosen. In FR at least (I'm 99.99% sure its the same in LG), variables 0x4100 and above are dedicated to 'hidden variables' used by some script commands. These variables can change without any user input so its most likely the case that your script isn't activating because 0x4100 is no longer set to 0x0. Checkout this thread to learn more, including which variables are safe to use (generally 0x4011 - 0x40FF).
__________________
Reply With Quote
  #4   Link to this post, but load the entire thread.  
Old January 19th, 2020 (3:34 PM).
taipachi taipachi is offline
 
Join Date: Jan 2020
Posts: 7
Is there a way that I can move the maps and events I created from a LeafGreen ROM to a FireRed ROM?
Reply With Quote
  #5   Link to this post, but load the entire thread.  
Old January 19th, 2020 (3:40 PM).
DrFuji's Avatar
DrFuji DrFuji is offline
Heiki Hecchara‌‌
 
Join Date: Sep 2009
Location: Aussie
Age: 30
Gender: Male
Nature: Jolly
Posts: 1,693
You can export your maps in Advance Map by going to 'File > Map > Save Map As'. To import them, go to 'File > Map > Open Map' and then 'File > Map > Insert Map'. You can overwrite the map that you were originally using by choosing its bank and map number and then selecting replace. All of the events on the map (NPCs, script tiles etc.) should be carried over, but their attached scripts won't be. You'll have to compile their scripts again with XSE to make them work properly.
__________________
Reply With Quote
  #6   Link to this post, but load the entire thread.  
Old January 19th, 2020 (3:47 PM).
taipachi taipachi is offline
 
Join Date: Jan 2020
Posts: 7
Sounds good. Thanks. I'm glad I found out about this before I had too much done. It shouldn't take too long to move this over to FireRed :)
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:15 AM.