• 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.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • Our weekly protagonist poll is now up! Vote for your favorite Conquest protagonist in the poll by clicking here.
  • 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.
Hey, all. I'm getting this problem:
When I try to have a trigger (the green 's' in A-Map) run a trainerbattle, the game stops working. It basically locks you there and never releases, and it never actually runs the script. However, I know it is possible to do this without the game breaking, because it happens in the normal version of the game (Ruby) multiple times.
Thanks.


@Collen: I think your problem might be that you don't have "release" and "end" at the end of #org 0x7226AD. And another thing, you should probably have the "waitmovement" command following "applymovement." Let me know if that works!
 
Okay, I'm having more problems.

Spoiler:

When I give the running shoes, she disappears for a second and then runs away when I walk. If I follow her, the game crashes...
I've added in bold what you forgot to add in.

Also, I have no idea why you had those comparefarbytetovar commands. :\
 
Hey, all. I'm getting this problem:
When I try to have a trigger (the green 's' in A-Map) run a trainerbattle, the game stops working. It basically locks you there and never releases, and it never actually runs the script. However, I know it is possible to do this without the game breaking, because it happens in the normal version of the game (Ruby) multiple times.
Thanks.

If you think that your script is causing the problem, then post it here.
However, based on what you have said, I think you forgot to set the unknown and variable numbers of the said "green 's'" tile through Advance Map...
If you're hacking Ruby, then put 0003 on 'Unknown' and 4000 on 'Var Number'.
If you're hacking FireRed, then put 0003 on 'Unknown' and 4050(not sure) on 'Var Number'...
Either which of the ROMs you are hacking, write 0000 on 'Var Value'...
[PokeCommunity.com] Script Help Thread (DO NOT REQUEST SCRIPTS)
 
Hi i'm using XSE and Advance Map and trying to script all the people in an art gallery scene. Ive never used XSE before but because it is good for editing scripts and can be opened on A-Map i am trying to learn.

Anyway this is the script
Spoiler:


and the problem is that whenever i talk to the sprite she faces me but nothing happens and i can just walk away, this only happens once and i have to double tap A again to get her to face me but there is still no text.

Thanks

I am having the same problem. I tried removing faceplayer, lock, and release but it still won't work.
 
^ try putting "callstd 0x6" after the "msgbox" thing.

I'm having problems with a script as well.
Spoiler:

It's supposed to make a sprite disapear after I activate the flag.
But when I activate the flag (it activates inside a house) and come outside, he's still there, even though the flag is set.
 
If you think that your script is causing the problem, then post it here.
However, based on what you have said, I think you forgot to set the unknown and variable numbers of the said "green 's'" tile through Advance Map...
If you're hacking Ruby, then put 0003 on 'Unknown' and 4000 on 'Var Number'.
If you're hacking FireRed, then put 0003 on 'Unknown' and 4050(not sure) on 'Var Number'...
Either which of the ROMs you are hacking, write 0000 on 'Var Value'...


Thanks, destinedjagold, it worked quite well!!
 
^ try putting "callstd 0x6" after the "msgbox" thing.

I'm having problems with a script as well.
Spoiler:

It's supposed to make a sprite disapear after I activate the flag.
But when I activate the flag (it activates inside a house) and come outside, he's still there, even though the flag is set.

Still no luck. I dunno if it's the way I'm adding the scripts to the game, I'm using PokeScript, is this right?

EDIT: I just found out I can compile using XSE.. silly me :P
 
Last edited:
Oh, right. I should probably mention that it's a Map Script (you know, in the "header" thing?).
 
I'm having another problem, now with applymovement.

My situation is, there is an area like this:

[attachment]

When the player steps on one of the four spaces in front of the man, a message box will come up telling the player to not go in there, and it will move the player three spaces to the left and one up. The thing is, it works perfectly but once the player finishes moving he is stuck there.

Code:
Spoiler:
 
Oh, right. I should probably mention that it's a Map Script (you know, in the "header" thing?).

Put 508 as the sprite's ID # if you haven't already (to hide a sprite, it must have an ID # and you must set the same flag # equivalent).


I'm having another problem, now with applymovement.

My situation is, there is an area like this:

[attachment]

When the player steps on one of the four spaces in front of the man, a message box will come up telling the player to not go in there, and it will move the player three spaces to the left and one up. The thing is, it works perfectly but once the player finishes moving he is stuck there.

Code:
Spoiler:

Put #raw 0xfe at the end of the movements - you need this at the end to indicate to the game that there are no more movements to be completed.
 
Put 508 as the sprite's ID # if you haven't already (to hide a sprite, it must have an ID # and you must set the same flag # equivalent).




Put #raw 0xfe at the end of the movements - you need this at the end to indicate to the game that there are no more movements to be completed.

Thanks! Works perfectly :)
 
Problem:
When the script ends the pokeball doesn't dissapear.

Game: FireRed
Type:
Person event
Editor: XSE
Script:
Spoiler:

 
I'm not quite sure what the clearflag there is for, but to hide the Pokéball, you'll need to include this:

Code:
hidesprite 0x#
setflag 0x*

# = the person event number of the Pokéball
* = choose a flag, and put it as the Person ID of the Pokéball overworld.

Some other notes: you need to add "release" and "end" to the end of the main part of the script.
 
Problem:
When the script ends the pokeball doesn't dissapear.

Game: FireRed
Type:
Person event
Editor: XSE
Script:
Spoiler:


Like Spherical Ice said, you need a setflag an hidesprite, but you also need some other stuff. For this example, I'll use the flag 0x828 as the person ID. Also, you don't need the person event number when talking to a sprite as you can use LASTTALKED. Oh, and you don't need lock or faceplayer as the 0x2 in the msgbox construct automatically does it for you.

So here is the fixed script:

#dynamic 0x800000
#org @start
msgbox @speak 0x2
givepokemon 0x85 0x5 0x0 0x0 0x0 0x0
hidesprite LASTTALKED
setflag 0x828
setflag 0x829
fadescreen 0x0
clearflag 0xBB
end

#org @speak
= A co to jest?\nWidocznie jakis trener\lzgubil swojego pokemon'a i pokedex'a\lOtrzymales EEVEE i POKEDEX
 
Like Spherical Ice said, you need a setflag an hidesprite, but you also need some other stuff. For this example, I'll use the flag 0x828 as the person ID. Also, you don't need the person event number when talking to a sprite as you can use LASTTALKED. Oh, and you don't need lock or faceplayer as the 0x2 in the msgbox construct automatically does it for you.

So here is the fixed script:

#dynamic 0x800000
#org @start
msgbox @speak 0x2
givepokemon 0x85 0x5 0x0 0x0 0x0 0x0
hidesprite LASTTALKED
setflag 0x828
setflag 0x829
fadescreen 0x0
clearflag 0xBB
end

#org @speak
= A co to jest?\nWidocznie jakis trener\lzgubil swojego pokemon'a i pokedex'a\lOtrzymales EEVEE i POKEDEX


Thank you it really helped.
 
I am hacking Fire Red and I can't get my script to work. I put in the script offset into Advance Map and I put in the values (0003 and 4050) but the script won't activate. I just step over it and nothing happens. Does anyone know why and how to fix it?

The value for 'Unknown' is 0300, not 0003.

I'm having some trouble.. for some reason my scripts seem to get "mixed up", like, in my starter town I have two person scripts. One is a Nurse Joy that heals your Pokemon for $250, and the other is a Team Rocket grunt who gives you a Pidgey. If, I start up the ROM and talk to the grunt first, he will give me it and leave normally, and then if I talk to Nurse Joy she will heal, and after she has, the give-pidgey script seems to start somehow, and I get another Pidgey. If, however, I talk to Nurse Joy first, she will heal, and give me my Pidgey, and then for some reason the rocket grunt dissapears off the map. I am guessing this is because I set to hidesprite <person number> and not LASTTALKED..

Anyway, does anyone know why my scripts get mixed up like this?
 
Last edited by a moderator:
I'm having some trouble.. for some reason my scripts seem to get "mixed up", like, in my starter town I have two person scripts. One is a Nurse Joy that heals your Pokemon for $250, and the other is a Team Rocket grunt who gives you a Pidgey. If, I start up the ROM and talk to the grunt first, he will give me it and leave normally, and then if I talk to Nurse Joy she will heal, and after she has, the give-pidgey script seems to start somehow, and I get another Pidgey. If, however, I talk to Nurse Joy first, she will heal, and give me my Pidgey, and then for some reason the rocket grunt dissapears off the map. I am guessing this is because I set to hidesprite <person number> and not LASTTALKED..

Anyway, does anyone know why my scripts get mixed up like this?
Try making Nurse Joy's/Team Rocket Grunt's offset farther away than Team Rocket Grunt's/Nurse Joy's. I was having the same problem, so I added a hundred to the offset to make it work.
 
Try making Nurse Joy's/Team Rocket Grunt's offset farther away than Team Rocket Grunt's/Nurse Joy's. I was having the same problem, so I added a hundred to the offset to make it work.

Hmm, well now when I try to compile the script it says "#define missing".. I don't see the need for that in this script?

Spoiler:
 
Are you sure you're XSE has all the needed RBH files? If not, then replace LASTRESULT with 0x8005, though you should have all the RBHs in your XSE folder.

I am hacking Fire Red and I can't get my script to work. I put in the script offset into Advance Map and I put in the values (0003 and 4050) but the script won't activate. I just step over it and nothing happens. Does anyone know why and how to fix it?

Mind posting the script?
 
Status
Not open for further replies.
Back
Top