The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Fan Games > Binary ROM Hacking
Reload this Page Script Warp Script Issue

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 December 14th, 2021 (5:47 PM). Edited December 14th, 2021 by evangraham.
evangraham's Avatar
evangraham evangraham is offline
 
Join Date: Jun 2018
Gender: Male
Nature: Jolly
Posts: 12
I'm trying to get this warp to send me to a specific tile on another map and I can get it to send me using just basic X Y coordinates like 0x0 0x0 or 0x1 0x1 but when I try to set the exact tile it is either seemingly way off or giving me black screen.

More details if needed - map I'm trying to get to is the ferry port in Slateport City, in front of it as if you just got off the boat, for example.

What am I not understanding about this warp script? Also tried "warpmuted" before and same results. TIA for any help!
Attached Images
File Type: png warp-script.png‎ (152.1 KB, 10 views) (Save to Dropbox)
Reply With Quote
  #2   Link to this post, but load the entire thread.  
Old December 14th, 2021 (10:12 PM).
Asith's Avatar
Asith Asith is offline
Uwao
 
Join Date: Nov 2020
Posts: 204
1) Why don't you want to use exact coordinates? Figuring out the exact coordinates of your "tile" and using those is a valid solution, if I'm understanding correctly.

2) Your screenshot is you attempting to not use coordinates? In that case, it's not right. Having that 0xFF parameter in there is exactly what tells the game that you're using basic xy coordinates. If you don't want to do that, get rid of that byte.

This is the other commonly used warp command:
Code:
warp 0x[Map Bank] 0x[Map Number] 0x[Warp Number] 0x0 0x0
As you can see, it doesn't use the 0xFF byte. As you can also see, however, it is used to go to warps specifically, not just any tile. Afaik, the only way to go to any tile is to use coordinates.
__________________
Spectrobes, anyone?
Reply With Quote
  #3   Link to this post, but load the entire thread.  
Old December 15th, 2021 (4:21 AM).
evangraham's Avatar
evangraham evangraham is offline
 
Join Date: Jun 2018
Gender: Male
Nature: Jolly
Posts: 12
Problem is though, when I go to change the coordinates part of the script to 0x7 0x10 (assuming that's in front of the boat) I just get black screened. I figure I'm misunderstanding the coordinates, but I'm not sure.
Reply With Quote
  #4   Link to this post, but load the entire thread.  
Old December 15th, 2021 (6:01 AM). Edited December 15th, 2021 by ScripNewbie.
ScripNewbie ScripNewbie is offline
Mystc Creator
 
Join Date: Mar 2021
Posts: 38
Quote:
Originally Posted by evangraham View Post
Problem is though, when I go to change the coordinates part of the script to 0x7 0x10 (assuming that's in front of the boat) I just get black screened. I figure I'm misunderstanding the coordinates, but I'm not sure.
Can i see what is your script?

When im writing warp command my script is:

Spoiler:
darkenroom 0x10 (for smooth transition)
warpmuted (or any type of warp) 0x[bank]
0x[map]
0x[FF/PLAYER]or[coordinates]
if coordinate:
Code:
0x[x]
0x[y]
then follow it by 3 nop0
for clean warp then waitspecial and end.

PKSV EXAMPLE:
Code:
darkenroom 0x10
warpmuted 0x4 0x1 0xFF 0x4 0x6
nop0
nop0
nop0
waitspecial
end
XSE EXAMPLE:
Code:
darken 0x10
warpmuted 0x4 0x1 0xFF 0x4 0x6
nop
nop
nop
waitstate
end


I use it when working in my hack but i didn't encounter a problem in warp scripting when im using this method.

Ps. Sorry for bad english
Reply With Quote
  #5   Link to this post, but load the entire thread.  
Old December 15th, 2021 (12:32 PM).
evangraham's Avatar
evangraham evangraham is offline
 
Join Date: Jun 2018
Gender: Male
Nature: Jolly
Posts: 12
Sure I've attached the script with the exact coordinates I'm trying to use. This gives me black screen.
Attached Images
File Type: jpg IMG_20211215_151857_415~2.jpg‎ (446.9 KB, 9 views) (Save to Dropbox)
Reply With Quote
  #6   Link to this post, but load the entire thread.  
Old December 15th, 2021 (7:47 PM). Edited December 15th, 2021 by ScripNewbie.
ScripNewbie ScripNewbie is offline
Mystc Creator
 
Join Date: Mar 2021
Posts: 38
Try my suggestion.
If it didn't work then i will say something that might be the problem

Spoiler:
1. Put your script in free space,
What i see in your script is it's located in 23D3F0, it's so crowded of number in there i advice you put your script in something more spacy, like 800000, 900000.

2. Don't compile the file, many times.
I mean if you compile a file and something is wrong in there or you didn't like what you write in your script but you already compile it, change your script to your liking but don't compile it again.. You need to hex edit it. Go to the offset where you put your unlovable script and erase it, so that when you compile your recreated script it's clean and it will function the way that you want it..

3. Tips for compiling a script is
Example of script
PKSV:
Code:
#dyn 0x800000
#org @1
lock
faceplayer
message @2
callstd msg_normal
release
end

#org @2
= Not BAQ \v\h01
As you can see there is a mistake, the BAQ, you want to change it,
then change it.
#org @2
= Not BAD \v\h01
(Don't compile it yet)
But what if you delete your file or you didn't save it but you want to still edit the mistake, then open your script in your rom, it will be:
PKSV:
Code:
#org 0x8800001
lock
faceplayer
msgbox 0x8800008
callstd msg_normal
release
end

#org 0x8800008
= Not BAQ \v\h01
Change it to look like what you want and change all the pointer to @
Code:
#dyn 0x800000
#org @1
lock
faceplayer
message @2
callstd msg_normal
release
end

#org @2
= Not BAD \v\h01
Now you change it, and you want to compile it now, but first goto where you put your script in your rom, that's 800000. (If you put it in free space you can navigate your script fast and clean.)
Code:
YOUR FIRST SCRIPT:
800000      FC AB 67 10 00 00 80 08   
800010      FF FF FF FF FF FF FF FF
800020      FF FF FF FF FF FF FF FF
Clean it, fill it with FF so it will be free space again. Then compile your script again.
Code:
YOUR FIRST SCRIPT:
800000      FF FF FF FF FF FF FF FF
800010      FF FF FF FF FF FF FF FF
800020      FF FF FF FF FF FF FF FF
This method is important because if you didn't clean your rom before recompiling, it will add some rubbish offset and number and will make your script not clean and not functioning well, it will take a lot space too.
I recommend you if you want to write your next script, make a space to edit the other.
Example in hex:
Code:
YOUR FIRST SCRIPT:
800000      FC AB 67 10 00 00 80 08   
800010      FF FF FF FF FF FF FF FF
800020      FF FF FF FF FF FF FF FF
Put your next script in 800020 for you to freely edit the your first script if something you want to change.

Code:
#dyn 0x800020 //always change dyn for clean compiling and never worry about @
#org @1
lock
faceplayer
message @2
callstd msg_normal
release
end

#org @2
= 2nd Script
3. Don't place your setflag after warp, after the warp the script below the warp script will be rubbish and just going to make your script big, put your script before warp.

XSE:
Code:
Setflag 0x8AB
darken 0x10
warp 0x9 0x9 0xFF 0x8 0x7
nop
nop
nop
waitstate
end


If all of that is not the problem, then the problem is the map where you want to teleport to.
Reply With Quote
  #7   Link to this post, but load the entire thread.  
Old December 16th, 2021 (1:12 PM).
Asith's Avatar
Asith Asith is offline
Uwao
 
Join Date: Nov 2020
Posts: 204
Quote:
Originally Posted by evangraham View Post
Sure I've attached the script with the exact coordinates I'm trying to use. This gives me black screen.
Your coordinates/map is definitely wrong. 0x9 0x9 would mean map 9.9, which is a small map that certainly doesn't have room for a 0x10 y coordinate. Remember that you're working in hexadecimal, not decimal. By 0x7 0x10 you probably actually meant to use 0x7 0xA.
__________________
Spectrobes, anyone?
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:20 AM.