• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

Script Help Thread (DO NOT REQUEST SCRIPTS)

Status
Not open for further replies.
6,355
Posts
18
Years
  • Seen Apr 16, 2020
hello friends i m making a script such that when i step on a tile my mother[in game] comes with a seal following her and then gives me that seal and after giving me seal the seal's ow should disappear and the player's mom goes outside.The problem is that the script isn't compiling i hope a help from you all

Spoiler:

From what I can see, it looks like you pressed enter while writing the dialogue for the @hi message at the "I have to go see ya" part, which is why your Script Editor won't let you compile. It should compile fine if you fix that, but I really think you should change the flags you're using.
 

Joexv

ManMadeOfGouda joexv.github.io
1,037
Posts
11
Years
It should work fine if you're hacking Ruby or Fire Red. However, if you're hacking Emerald, you should use special 0x91 to refresh the map so that the tile changes appear. special 0x8E in Emerald either does nothing or something else, this is why they appeared when you re-entered the map, since there is no need to refresh the map with setmaptile level scipts.

Now, if you're not using Emerald, then I find nothing wrong with the script. Once it gets to the '":Well done:\n:Now guide others to ..." part, the tiles should be changed.

Ah well that would explain it as I am using emerald. Figures XD. Thanks ill edit it and see what happens.
 
8
Posts
14
Years
#dynamic 0x800000

#org @start
lockall
faceplayer
checkflag 0x828
if 0x1 goto @done
msgbox @1 0x5
compare LASTRESULT 0x1
if 0x1 goto @take
msgbox @2 0x6
release
end

#org @take
givepokemon 0x4 0x5 0x0 0x0 0x0 0x0
fanfare 0x13E
msgbox @3 0x4
waitfanfare
closeonkeypress
setflag 0x828
msgbox @4 0x5
compare LASTRESULT 0x1
if 0x1 gosub @name
msgbox @5 0x6
release
end

#org @name
call 0x1A74EB
return

#org @done
msgbox @6 0x6
release
end

#org @1
= Hello.\nSorry to trouble you.\nI can't take care\nof my Charmander.\pCan you take care of\nit for me?

#org @2
= That's okay.\pI'm sure someone else will\ntake it.

#org @3
= [black_fr]You received a Charmander!

#org @4
= [black_fr]Would you like to give a\nnickname to Charmander?

#org @5
= Please take care of\nCharmander.

#org @6
= Are you taking good care\nof Charmander?
 
6,355
Posts
18
Years
  • Seen Apr 16, 2020
#dynamic 0x800000
Spoiler:

It'd help if you actually write what's wrong with your script before you post it.

Anyway, the pokémon that's supposed to show up on the nicknaming screen is defined by the variable 8004, which gives the position in the party your new pokémon will be in. So setvar 0x8004 0x0 would nickname the first pokémon in your slot, 0x2 the second and so on. I edited your script so that it works correctly for any number of pokémon in the party except 6. The problem is that if your party is full and Charmander is set to a PC box, the screen will show the last pokémon in your party, not Charmander. special 0x9E only works with pokémon currently in your party as far as I know, so you should check if the party is full in the script before continuing to give the pokémon.
 

Andrut

Collecting dust since 1898
284
Posts
14
Years
I can't believe I'm actually asking this...
What is the special for activating the regional Pokédex in FR? I want to find it in the script and replace it with the National dex special.
 
55
Posts
10
Years
  • Age 27
  • Seen Oct 18, 2014
Alright. I'm back with a similar problem to what I've had before. Here's the script:
#dynamic 0x800000

#org @start
lock
faceplayer
checkflag 0x200
if 0x1 goto @finished
msgbox @yes 0x5
compare 0x800D 0x1
if 0x1 goto @bulba
msgbox @no 0x6
release
end

#org @finished
msgbox @already_recieved 0x6
release
end

#org @bulba
msgbox@bulba_ask 0x5
compare 0x800D 0x1
if 0x1 goto @bulba_yes
goto @char

#org @char
msgbox@char_ask 0x5
compare 0x800D 0x1
if 0x1 goto @char_yes
goto @squir

#org @squir
msgbox @squir_ask 0x5
compare 0x800D 0x1
if 0x1 goto @bulba

#org @bulba_yes
compare 0x4011 0x0
if 0x0 goto @not_bulba
giveitem 0x1 0x1 MSG_OBTAIN
msgbox @enjoy_bulba 0x6
setflag 0x200
release
end

#org @not_bulba
msgbox @bulbanotstarter 0x6
release
end

#org @bulbanotstarter
= Wait! I don't think you chose Bulbasaur. I have no time for liars!

#org @enjoy_bulba
= Enjoy that Venusaurite!

#org @char_yes
compare 0x4011 0x1
if 0x0 goto @not_char
giveitem 0x2 0x1 MSG_OBTAIN
msgbox @enjoy_char 0x6
setflag 0x200
release
end

#org @not_char
msgbox @charnotstarter 0x6
release
end

#org @charnotstarter
= Wait! I don't think you chose Charmander. I have no time for liars!

#org @enjoy_char
= Enjoy that Charizardite!

#org @squir_yes
compare 0x4011 0x2
if 0x0 goto @not_squir
giveitem 0x3 0x1 MSG_OBTAIN
msgbox @enjoy_squir 0x6
setflag 0x200
release
end

#org @not_squir
msgbox @squirnotstarter 0x6
release
end

#org @squirnotstarter
= Wait! I don't think you chose Squirtle. I have no time for liars!

#org @enjoy_squir
= Enjoy that Blastoisite!

#org @already_recieved
= I already gave you your item! Go away!

#org @yes
= Can I check your starter?

#org @no
= Why won't you let me check your starter?

Now I think this is perfect. The problem is when I hit compile, it compiles and saves to the rom. I then insert the script offset into A-Map onto a clean sprite. I test the rom to see if it works, and I can only hear the ding. He faces me however, but only on the first time. I'll try talking to him the next couple of times, but nothing works. How do I make this actually work? Also, if anything is wrong with the script, just mention that.

***I might want to add that the item offsets are just fillers for when I get a chance to change the items to what I want. So don't say anything about how a Masterball isn't a Mega Stone.
 
16
Posts
10
Years
  • Age 28
  • Seen Dec 21, 2019
Hey guys, I'm pretty new to ROM hacking, so forgive me if this is a dumb question but I don't understand what's wrong with this script for a starter (for the first pokeball):
Spoiler:

It freezes everytime I'm trying to "talk" to the pokeball.
Thanks in advance
 
6,355
Posts
18
Years
  • Seen Apr 16, 2020
Hey guys, I'm pretty new to ROM hacking, so forgive me if this is a dumb question but I don't understand what's wrong with this script for a starter (for the first pokeball):
Spoiler:

It freezes everytime I'm trying to "talk" to the pokeball.
Thanks in advance

Your script seems to work fine, are you sure you copied the correct compiled offset for @bulbasaur to the script offset box of the pokéball in Advance Map?

Alright. I'm back with a similar problem to what I've had before. Here's the script:


Now I think this is perfect. The problem is when I hit compile, it compiles and saves to the rom. I then insert the script offset into A-Map onto a clean sprite. I test the rom to see if it works, and I can only hear the ding. He faces me however, but only on the first time. I'll try talking to him the next couple of times, but nothing works. How do I make this actually work? Also, if anything is wrong with the script, just mention that.

***I might want to add that the item offsets are just fillers for when I get a chance to change the items to what I want. So don't say anything about how a Masterball isn't a Mega Stone.

There are few things wrong with your script, but it should compile properly and you should be able to see what's wrong so you can fix it. If all you can hear is a ding then look at my answer for Ik-Stan.
 
Last edited:
16
Posts
10
Years
  • Age 28
  • Seen Dec 21, 2019
Spheal, thanks for your reaction. I'm sure I copied the right offset. Any more ideas?
 
55
Posts
10
Years
  • Age 27
  • Seen Oct 18, 2014
Your script seems to work fine, are you sure you copied the correct compiled offset for @bulbasaur to the script offset box of the pokéball in Advance Map?

There are few things wrong with your script, but it should compile properly and you should be able to see what's wrong so you can fix it. If all you can hear is a ding then look at my answer for Ik-Stan.

Well I used offset 0x9B0000 as my script offset, and I entered that in A-Map. But it only pops up as a ding, no text though...
 

Teh Blazer

Divider of Zero
776
Posts
15
Years
Well I used offset 0x9B0000 as my script offset, and I entered that in A-Map. But it only pops up as a ding, no text though...

Have you tried turning it off and on again using a different offset? 9B0000 seems a bit high, usually around 800000 is what people use for script offsets.
 
6,355
Posts
18
Years
  • Seen Apr 16, 2020
Well I used offset 0x9B0000 as my script offset, and I entered that in A-Map. But it only pops up as a ding, no text though...

Okay so I tried the script myself and it works fine. So you must be doing something wrong with the compiling.

You started the script with "#dynamic 0x800000", right? When you compile with XSE, you a small window pops up showing you where the script was located, which is at free space after the offset you specified (800000). Just copy the offset compiled for @start and enter it in Advance Map.
 

Rezordaxx

Asks many questions!
290
Posts
10
Years
Fire red
editor XSE

soon as it warps the screen just stays black and nothing happens

Spoiler:
 
8
Posts
14
Years
I put this script into the game. Normally when I try to use XSE and I talk to the person, they say nothing. When I talked to the guy this time, he said something that one of the other guys says.

#Dynamic 0x270200

#ORG @Main
Lock
FacePlayer
Message @Speak
BoxSet 0x6
Release
End

#ORG @Speak
= Hello there!
 

Logan

[img]http://pldh.net/media/pokecons_action/403.gif
10,417
Posts
15
Years
I put this script into the game. Normally when I try to use XSE and I talk to the person, they say nothing. When I talked to the guy this time, he said something that one of the other guys says.

#Dynamic 0x270200

#ORG @Main
Lock
FacePlayer
Message @Speak
BoxSet 0x6
Release
End

#ORG @Speak
= Hello there!
I think you may be using an old version of XSE, I'd definitely suggest updating to a newer version. Also I certainly wouldn't compile that script to that offset as that is probably your problem. The new version of XSE doesn't require the boxset command, instead you can just put the 0x6 inside the msgbox command. Also, a quick tip would be to use the MSG_FACE type as it doesn't require lock, faceplayer or release commands. Here is what your script should look like, just compile it and copy the @start offset into the A-Map person event.

Code:
#dynamic 0x800000

#org @start
msgbox @msg1 MSG_FACE
end

#org @msg1
= Hello there!
 
16
Posts
10
Years
  • Age 28
  • Seen Dec 21, 2019
Well, I can't see anything wrong with the script. Are you sure you're compiling it into the same ROM?

I tried it on a clean ROM and it worked, so I'm guessing there's something wrong with my ROM.
 
Status
Not open for further replies.
Back
Top