The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Fan Games > Binary ROM Hacking
Reload this Page Script Setmaptile-Level script doesnt activate

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 30th, 2021 (12:21 PM).
Zarro Zarro is offline
 
Join Date: Aug 2021
Posts: 7
I wanted to insert the below level 1 setmaptile script into the game, where defeating certain trainers and reaching a certain flag spawns warp tiles in the top floor of a cave and also removes one barrier (so you dont have to walk the whole way everytime). While the warps generally work the tiles dont change, so the warps only work on the way out and the removal of the barrier also just doesnt happen. I tested with the compare command and without and with special 0x8E and without. I looked up the level scripts from vanilla firered where the same thing happens and basically copied what they did, but it still doesnt work. Can someone help me with that?

Spoiler:
Code:
'---------------
#org 0x904595
checktrainerflag 0x16D
if 0x1 call 0x89045A5
checktrainerflag 0x16C
if 0x1 call 0x89045C1
checkflag 0x220
if 0x1 call 0x89045D8
checktrainerflag 0x15C
if 0x1 call 0x89045F4
end

'---------------
#org 0x9045A5
setmaptile 0xD 0x11 0x390 0x0
special 0x8E
return


'---------------
#org 0x9045C1
setmaptile 0x1 0x11 0x390 0x0
special 0x8E
return

'---------------
#org 0x9045D8
setmaptile 0x7 0x11 0x390 0x0
special 0x8E
return

'---------------
#org 0x9045F4
setmaptile 0x16 0xC 0x282 0x0
setmaptile 0x17 0xC 0x281 0x0
setmaptile 0x17 0xB 0x281 0x0
setmaptile 0x17 0xA 0x281 0x0
setmaptile 0x16 0xB 0x282 0x0
setmaptile 0x16 0xA 0x281 0x0
setmaptile 0x17 0xD 0x281 0x0
special 0x8E
return
Reply With Quote
  #2   Link to this post, but load the entire thread.  
Old August 30th, 2021 (2:39 PM).
kalarie kalarie is offline
 
Join Date: Jun 2008
Posts: 760
@Zarro

A setmaptile levelscript loads once you enter the map. Did you re-enter the map somewhere?

If that is not the case, you need to set-up another type of script than a setmaptile level script.
Reply With Quote
  #3   Link to this post, but load the entire thread.  
Old August 30th, 2021 (3:21 PM).
Zarro Zarro is offline
 
Join Date: Aug 2021
Posts: 7
Yes, I did. So having a person event for example in addition to the level script or instead? How does the warp point at Saffron gym at Sabrina spawn when entering her room then? There isnt any script and it works, but maybe I am overseeing things.
Reply With Quote
  #4   Link to this post, but load the entire thread.  
Old August 31st, 2021 (4:27 AM).
Anon822 Anon822 is offline
 
Join Date: Nov 2017
Posts: 326
Are you sure those flags are actually set? I would try the script without the checktrainerflag and checkflag commands.
Reply With Quote
  #5   Link to this post, but load the entire thread.  
Old September 1st, 2021 (7:33 AM).
kalarie kalarie is offline
 
Join Date: Jun 2008
Posts: 760
@Zarro

Quote:
So having a person event for example in addition to the level script or instead?
Yes, in addition. As I said, a setmaptile script only activates once when you enter the map. When you stay on the same map and want tiles to change, you need to use the setmaptile command in combination with special 0x8E in some other script to activate this change of tiles while staying on the same map.

Quote:
How does the warp point at Saffron gym at Sabrina spawn when entering her room then?
As far as I know, there are only regular warp tiles in her gym in Gen III? The destination of those panels doesn't change throughout your gym's progress depending on what trainers you've beat. AKA they're not altered in any way by any kind of script.
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:15 AM.