• 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.
I'm afraid you're chances of getting your question answered are low as, I think it's safe to say, Pokéscript is obsolete compared to languages like those present in XSE. Sorry. >:

I seem to have some trouble with this trigger script.

XSE, FireRed, Trigger Script
Spoiler:


Spoiler:

Okay, so what's meant to happen in this portion of the script is basically: screen fades to white, Raikou's cry is heard, the player, and events 7, 8 and 9 face left, the screen fades back to normal. Up to here works. Until, when I want Person # 10 and Person ID 901 to appear as it doesn't appear. Afterwards, a message is shown, person nine moves, more text is shown, which all works, until Person # 11 and Person ID 905 appears, followed by the hiding of #10, which also doesn't work. The pause for half a second works, but then, lo and behold, the hiding of #11 doesn't work.

The second spoiler shows part of the level script which hides #10 and #11 to begin with. The rest of this level script works, so I don't think that's the problem.

This is really annoying me. Any ideas why it's happening?

e: Although the rest of the script works, if I exit and re-enter the map, the script executes again, but if I stay in the map and walk over the tile, nothing happens. I have put flags in, so I dunno why that happens either. >:
 
Last edited:
I'm afraid you're chances of getting your question answered are low as, I think it's safe to say, Pokéscript is obsolete compared to languages like those present in XSE. Sorry. >:

I seem to have some trouble with this trigger script.

XSE, FireRed, Trigger Script
Spoiler:


Spoiler:

Okay, so what's meant to happen in this portion of the script is basically: screen fades to white, Raikou's cry is heard, the player, and events 7, 8 and 9 face left, the screen fades back to normal. Up to here works. Until, when I want Person # 10 and Person ID 901 to appear as it doesn't appear. Afterwards, a message is shown, person nine moves, more text is shown, which all works, until Person # 11 and Person ID 905 appears, followed by the hiding of #10, which also doesn't work. The pause for half a second works, but then, lo and behold, the hiding of #11 doesn't work.

The second spoiler shows part of the level script which hides #10 and #11 to begin with. The rest of this level script works, so I don't think that's the problem.

This is really annoying me. Any ideas why it's happening?

e: Although the rest of the script works, if I exit and re-enter the map, the script executes again, but if I stay in the map and walk over the tile, nothing happens. I have put flags in, so I dunno why that happens either. >:

FRom what I'm assuming, you're using a sequential order for your person event, so should be using the HEX numbers for people #10 and #11 (0xA and 0xB), that may be why they're not appearing - I do this all the time as well. I'm not sure why the script executes itself again after you reenter the map because you're setting and checking a flag, but hopefully this will help will help with your person problem.
 
This is going to sound like a really dumb question, I know. Bear with me.

I'm using the newest version of XSE to edit scripts in my Ruby ROM. If I go to "Open Script" in Advance Map and edit from there, how do I save the edited script to the ROM?
 
This is going to sound like a really dumb question, I know. Bear with me.

I'm using the newest version of XSE to edit scripts in my Ruby ROM. If I go to "Open Script" in Advance Map and edit from there, how do I save the edited script to the ROM?

You need to compile the script again (The two blue cogs on the top of XSE). This method will be fine if you're making the script shorter/ keeping it the same length, but if you are making it longer would be best to change the offsets in the script so it doesn't overwrite anything.

EDIT: Beaten ;_;
 
applymovement help

I have an applymovement script that I need help on. It goes like this:
Spoiler:



Everything works until after the person talks, then nothing happens. It's like the script stops. It won't go past that point. (I'm trying to make the guy run away after he says @tut.)
 
Last edited by a moderator:
I have an applymovement script that I need help on. It goes like this:

#dynamic 0x71A248

#org @start
goto @moved
release end

#org @tut
= WHAT!

#org @moved
applymovement 0x1 @?
pause 0x40
applymovement 0x1 @turn
pause 0x30
applymovement 0x1 @!
waitmovement 0x1
applymovement 0x1 @recoil
message @tut
boxset 6
applymovement 0x1 @run
release
end

#org @?
#raw 0x63
#raw 0xFE

#org @turn
#raw 0x4a
#raw 0x4c
#raw 0xFE

#org @!
#raw 0x62
#raw 0xFE

#org @recoil
#raw 0x20
#raw 0x20
#raw 0xFE

#org @run
#raw 0x4d
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0xFE




Everything works until after the person talks, then nothing happens. It's like the script stops. It won't go past that point. (I'm trying to make the guy run away after he says @tut.)


Code:
#dynamic 0x71A248

#org @start
goto @moved   [I]'I'd recommend just putting the movements here, but eh.. your choice.[/I]
release 
end

#org @tut
= WHAT!

#org @moved
applymovement 0x1 @?
pause 0x40
applymovement 0x1 @turn
pause 0x30
applymovement 0x1 @!
waitmovement 0x1
applymovement 0x1 @recoil
[B]waitmovement 0x0[/B]
message @tut    [I]'shouldn't it be [U]message @tut 0x6[/U] or something? :/[/I]
boxset 6
applymovement 0x1 @run
[B]waitmovement 0x0[/B]
release
end

#org @?
#raw 0x63
#raw 0xFE

#org @turn
#raw 0x4a
#raw 0x4c
#raw 0xFE

#org @!
#raw 0x62
#raw 0xFE

#org @recoil
#raw 0x20
#raw 0x20
#raw 0xFE

#org @run
#raw 0x4d
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0x20
#raw 0xFE
I'd recommend just using waitmovement 0x0, but as long as you're using the commands correctly, you're fine.
 
IT WORKED

IT WORKS NOW!

Thank you Thank you Thank you Thank you Thank you Thank you Thank you Thank you Thank you Thank you Thank you.
 
Last edited:
EDIT: Beaten ;_;
I read that very often from you :D

isaiahbob: Binary pretty much explained everything but I'd add this: don't use boxset ;) I think it's pokescript command so use the msgbox command in a way Binary showed you =)
 
Hi, I have a problem with my wildbattle script. The pokemon doesn't disappeared after the fight, i don't know what to do...

Here is my script:

'---------------
#org 0xE3CF70
lockall
checksound
cry 0x97 0x2
pause 0x28
waitcry
setwildbattle 0x97 0xA 0x0
setflag 0x8C1
special 0x13A
waitstate
clearflag 0x8C1
special2 0x800D 0xB7
compare 0x800D 0x1
if 0x1 goto 0x8E3D0B0
compare 0x800D 0x4
if 0x1 goto 0x8E3D180
compare 0x800D 0x5
if 0x1 goto 0x8E3D180
setflag 0x1C0
releaseall
end

'---------------
#org 0xE3D0B0
setflag 0x1C0
goto 0x8E3D290

'---------------
#org 0xE3D180
setvar 0x8004 0x97
goto 0x8E3D3D0

'---------------
#org 0xE3D290
fadescreen3 0x1
hidesprite 0x800F
fadescreen3 0x0
releaseall
end

'---------------
#org 0xE3D3D0
fadescreen3 0x1
hidesprite 0x800F
fadescreen3 0x0
bufferpokemon 0x0 0x8004
msgbox 0x8E3D630 0x4 '"Le MEW s'est enfui!"
releaseall
end


'---------
' Strings
'---------
#org 0xE3D630
= Le MEW s'est enfui!



Can you tell me what is wrong with it please?
EDIT: I used the Rayquaza's wildbattle script to help me...
 
i just wana ask have you put the setflag in the person id in A-Map?
 
i just wana ask have you put the setflag in the person id in A-Map?

Yes i read that but I don't know what flag I have to choose. Some are already used, aren't they? and do I have to translate them in Hex?

Sorry but I just begin to script :s
 
Yes i read that but I don't know what flag I have to choose. Some are already used, aren't they? and do I have to translate them in Hex?

Sorry but I just begin to script :s
You set this flag didn't you? "setflag 0x8C1"
Then that should be the one you want to put =)
If it's not flag that activates something =)
 
earthquake

Game: Ruby

I'm fairly new to this whole scripting business.

I'm trying to make a script where you would walk over it and a earthquake will happen with a sound, and shortly after that a msgbox will appear then closeonkeypress, then everything goes back to normal. (after the one time it wont happen again).

Unfortunately my script is not working, in fact it stops working on the 2nd line at "lockall".
But when I get rid of "lockall" the earthquake works, the sound goes on forever, the msgbox never appears and this will happen every time you walk over it.

Help Please.

Script,
Spoiler:
 
Game: Ruby

I'm fairly new to this whole scripting business.

I'm trying to make a script where you would walk over it and a earthquake will happen with a sound, and shortly after that a msgbox will appear then closeonkeypress, then everything goes back to normal. (after the one time it wont happen again).

Unfortunately my script is not working, in fact it stops working on the 2nd line at "lockall".
But when I get rid of "lockall" the earthquake works, the sound goes on forever, the msgbox never appears and this will happen every time you walk over it.

Help Please.

Script,
Spoiler:

Corrections in red.

Code:
#org @start
lockall
[COLOR=red]checkflag 0x200[/COLOR]
[COLOR=red]if 0x1[/COLOR] goto @Continue
[COLOR=red]releaseall[/COLOR]
end
 
#org @Continue
sound 0x31
[COLOR=red]setvar 0x8004 0xF[/COLOR]
[COLOR=red]setvar 0x8005 0xF[/COLOR]
[COLOR=red]setvar 0x8006 0xF[/COLOR]
setvar 0x8007 0xF
special 0x131
waitstate
pause 0x28
msgbox @Collide [COLOR=red]0x4[/COLOR]
closeonkeypress
[COLOR=red]setflag 0x200[/COLOR]
releaseall
end
 
#org @Collide
= It sounds as if something hit the/lplanet not far from here.

I have no idea why you have the command 'goto' when you aren't checking a flag/ variable beforehand - You might as well have just put the entire script in a huge block. I put in the 'setflag' command so that this script won't repeat each time you step on it.

The timing and magnitude of earthquakes are based on four variable values, rather than just the one you had originally. This might be why your earthquake was going on forever.
 
Corrections in red.

Code:
#org @start
lockall
[COLOR=red]checkflag 0x200[/COLOR]
[COLOR=red]if 0x1[/COLOR] goto @Continue
[COLOR=red]releaseall[/COLOR]
end
 
#org @Continue
sound 0x31
[COLOR=red]setvar 0x8004 0xF[/COLOR]
[COLOR=red]setvar 0x8005 0xF[/COLOR]
[COLOR=red]setvar 0x8006 0xF[/COLOR]
setvar 0x8007 0xF
special 0x131
waitstate
pause 0x28
msgbox @Collide [COLOR=red]0x4[/COLOR]
closeonkeypress
[COLOR=red]setflag 0x200[/COLOR]
releaseall
end
 
#org @Collide
= It sounds as if something hit the/lplanet not far from here.

I have no idea why you have the command 'goto' when you aren't checking a flag/ variable beforehand - You might as well have just put the entire script in a huge block. I put in the 'setflag' command so that this script won't repeat each time you step on it.

The timing and magnitude of earthquakes are based on four variable values, rather than just the one you had originally. This might be why your earthquake was going on forever.




Thank-you for your help and time.

I have tried the modified script you had wrote and the problem of the lock has gone.
But there is still a problem, When I place the script down on the floor and walk over it, nothing happens.
I don't freeze over it, I just walk over it as if nothing was there in the first place.

Thanks for your time.
 
Thank-you for your help and time.

I have tried the modified script you had wrote and the problem of the lock has gone.
But there is still a problem, When I place the script down on the floor and walk over it, nothing happens.
I don't freeze over it, I just walk over it as if nothing was there in the first place.

Thanks for your time.

Oh sorry, I'm afraid I messed up a bit when writing that. Instead of continuing if you had not set the flag, it was only continuing if you had.

At the beginning it should be:
...
checkflag 0x200
if 0x0 goto @Continue
...

Once again, sorry for being a bit careless.
 
Oh sorry, I'm afraid I messed up a bit when writing that. Instead of continuing if you had not set the flag, it was only continuing if you had.

At the beginning it should be:
...
checkflag 0x200
if 0x0 goto @Continue
...

Once again, sorry for being a bit careless.




Thanks again, and it's no problem as long I get the help I need.

But again unfortunately there is still a problem. I got a feeling I am doing something wrong because when I walk over this script it does one of two things, it will either get stuck on lock and freeze the player, or the player will just walk over it with nothing happen.

Sorry for being such a fuss.

Thanks again.
 
You set this flag didn't you? "setflag 0x8C1"
Then that should be the one you want to put =)
If it's not flag that activates something =)

I have done what you told me, but now, the pokemon disappeared until I come in and come out of a house. It comes back! How can I make it disappeared FOR EVER? :'(

Thank you for helping me
 
Status
Not open for further replies.
Back
Top