• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Our friends from the Johto Times are hosting a favorite Pokémon poll - and we'd love for you to participate! Click here for information on how to vote for your favorites!
  • Scottie, Todd, Serena, Kris - which Pokémon protagonist is your favorite? Let us know by voting in our poll!
  • 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.
#dynamic 0x800000

#org @start
lock
faceplayer
cry 0x1 0x2
msgbox @1 0x6
setwildbattle 0x1 0x5 0x0
special 0x138
playsong 0x299 0x0
hidesprite 0x800D
setflag 0x105
release
end

#org @1
= A wild Bulbasaur attacks!

I use this code for legendary Pokemons. But one what I did with it wrong? Everytime when I start battle sprite not vanished but they reapeared sometimes. Someone can help? I use Pokemon Ruby.
 
#dynamic 0x800000

#org @start
lock
faceplayer
cry 0x1 0x2
msgbox @1 0x6
setwildbattle 0x1 0x5 0x0
special 0x138
playsong 0x299 0x0
hidesprite 0x800D
setflag 0x105
release
end

#org @1
= A wild Bulbasaur attacks!

I use this code for legendary Pokemons. But one what I did with it wrong? Everytime when I start battle sprite not vanished but they reapeared sometimes. Someone can help? I use Pokemon Ruby.
Are you sure the sprite's ID in Advance-Map is set to 105??
If yes, then either you're clearing that flag in an other script or it is not a safe flag for such a use.
 
#dynamic 0x800000

#org @start
lock
faceplayer
cry 0x1 0x2
msgbox @1 0x6
setwildbattle 0x1 0x5 0x0
special 0x138
playsong 0x299 0x0
hidesprite 0x800D
setflag 0x105
release
end

#org @1
= A wild Bulbasaur attacks!

I use this code for legendary Pokemons. But one what I did with it wrong? Everytime when I start battle sprite not vanished but they reapeared sometimes. Someone can help? I use Pokemon Ruby.

You used flag 105, so go to the overworld sprite for the pokemon that you're battling and where it says "Person ID" set it 105
 
I'd like to modify the damage done by wrap/firespin during the end of phase part. (the 1/16th of Max hp)

someone told me I can use the BSP to easily edit the damage done at this part. I read the guide for the BSP but have trouble understanding it as I just started out hacking.

here is the script for wrap
Spoiler:


can someone tell me what I'd need to modify in order to do this?
 
You used flag 105, so go to the overworld sprite for the pokemon that you're battling and where it says "Person ID" set it 105

Ok. But when I set right flag in the A-Map. My OW dissapeared totaly. It do not show correctly. When I put normaly this script. It was never endless battle. But with put right flag. It do not show even, that I do not start an battle.
 
hi friends i made a script but have some problems i think u guys can solve it so i m here.Friends i made a script such that when i talk to a pidgey the screen fades assuming that it is evolving and then a pidgeotto's ow appears and when i talk to it it flees.It works but there is a problem that how to keep pidgeottto's ow hidden until i talk to piddgey and it evolves to pidgeotto?
by the way here is the script

'---------------
#org 0x800000
lock
faceplayer
cry 0x10 0x0
msgbox 0x8800038 MSG_NORMAL '"PIDGEY: Pidgey!!!!!"
waitcry
fadescreen 0x3
hidesprite 0x1
fadescreen 0x2
setflag 0x500
showsprite 0x2
cry 0x11 0x0
msgbox 0x880004E MSG_NORMAL '"PIDGEOTTO: Pidgeo!!!!!!"
waitcry
fadescreen 0x1
hidesprite 0x2
fadescreen 0x0
setflag 0x300
release
end

'---------
' Strings
'---------
#org 0x800038
= PIDGEY: Pidgey!!!!!

#org 0x80004E
= PIDGEOTTO: Pidgeo!!!!!!

please tell me a solution to this also pidgeottos person event is 2 while pidgeys person event is 1 and pidgeotto's movement type is hidden
 
I'd like to modify the damage done by wrap/firespin during the end of phase part. (the 1/16th of Max hp)
No, altering the damage requires you to find the check for "trapped" and do some ASM hacking to it, depending on how you want to modify the damage and how Game Freak did the effect, it can be done by a simple and easy Hex editing, but you need to find the check first.

Ok. But when I set right flag in the A-Map. My OW dissapeared totaly. It do not show correctly. When I put normaly this script. It was never endless battle. But with put right flag. It do not show even, that I do not start an battle.

This means one thing, the flag you're trying to use (0x105) was already set before. Some flags are set by default, or you have a script that sets 0x105 before this event. You have 2 solutions:
_ Clear the flag before the event takes place.
_ Use a different flag.

hi friends i made a script but have some problems i think u guys can solve it so i m here.Friends i made a script such that when i talk to a pidgey the screen fades assuming that it is evolving and then a pidgeotto's ow appears and when i talk to it it flees.It works but there is a problem that how to keep pidgeottto's ow hidden until i talk to piddgey and it evolves to pidgeotto?
by the way here is the script



please tell me a solution to this also pidgeottos person event is 2 while pidgeys person event is 1 and pidgeotto's movement type is hidden

You need to setflag 0x300 before the event takes place.
Clear the flag after Pidgey evolves
Set it a second time when Pidgeotto flees away.

Note: If you're hack FireRed, flags 0x300 and 0x500 are not safe to use. flags between 0x200 and 0x2FF are the most safe flags to use, inclusive.
 
Last edited:
No, altering the damage requires you to find the check for "trapped" and do some ASM hacking to it, depending on how you want to modify the damage and how Game Freak did the effect, it can be done by a simple and easy Hex editing, but you need to find the check first.

thank you for clearing that up.
 
How would I make a script that as the player walks, someone behind him follows him/her? Sorta like in RSE in Oldale town, that you follow the Shop guy and he gives you a potion, but this time, you're walking and someone's following you. Fire Red btw, if it matters.
 
How would I make a script that as the player walks, someone behind him follows him/her? Sorta like in RSE in Oldale town, that you follow the Shop guy and he gives you a potion, but this time, you're walking and someone's following you. Fire Red btw, if it matters.
Try these I think they might help:
https://www.pokecommunity.com/showthread.php?t=204651
Spoiler:
 
How would I make a script that as the player walks, someone behind him follows him/her? Sorta like in RSE in Oldale town, that you follow the Shop guy and he gives you a potion, but this time, you're walking and someone's following you. Fire Red btw, if it matters.

Just have the same applymovement of the player and the other person. I recommend you take XSE scripting tutorial.

Example:
Code:
#dynamic 0x800000

#org @start
msgbox @1 0x1
applymovement 0x1 @move
applymovement 0xFF @follow1
waitmovement 0x0
release 
end

#org @1
= Follow me!

#org @move
#raw 0x11 = Step Up (Normal)
#raw 0x11 = Step Up (Normal)
#raw 0x11 = Step Up (Normal)
#raw 0x0 = Face Down

#org @follow1
#raw 0x11 = Step Up (Normal)
#raw 0x11 = Step Up (Normal)

Try these I think they might help:
https://www.pokecommunity.com/showthread.php?t=204651
Spoiler:

I think this one is for HG/SS and he clearly meant from RSE :)
 
Hey there people, I'm working on a ROM hack and I wanted to include an old man in Reclend Village (the first town) who gives you a Teachy TV. My script is in the spoiler tag, what's wrong with it?!
The error message is that I'm missing #define.

Spoiler:

What's going on? I'm using XSE on FireRed, btw.
 
Last edited:
Hey there people, I'm working on a ROM hack and I wanted to include an old man in Reclend Village (the first town) who gives you a Teachy TV. My script is in the spoiler tag, what's wrong with it?!
The error message is that I'm missing #define.

Spoiler:

What's going on? I'm using XSE on FireRed, btw.

XSE already told you which line in your script has a #define problem, you just didn't pay attention.
Anyway, your XSE doesn't have the file std.rbh, download it and put it where XSE.exe is.
Meanwhile, you can use this instruction giveitem 0x366 0x1 0x2. (0x2 = MSG_OBTAIN)
 
But i don't see any scripts on the TVs nor the persons in the house with the tv have any special scrips except msgbox.
 
Status
Not open for further replies.
Back
Top