• 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.
38
Posts
14
Years
  • Seen Mar 4, 2010
First off, remove release. Place the compiled offset of the script under an NPC in A-Map. Check the trainer box. Put the view range at whatever you wish.
k i understood the release thing but i dont get what you do mean but he compiled offset and setting it under an npc i already put it for a npc but and how does the view range affect it
 
38
Posts
14
Years
  • Seen Mar 4, 2010
how would i write a script where i wanted your rival to walk up to you after you walk past a certain spot and battle you?
 
38
Posts
14
Years
  • Seen Mar 4, 2010
Yes it is. It may be hard to understand as first but once you experiment with the commands, you'll be able to make your own. :3
:D im starting to understand some what but the thing is i forgot which part of the script describe what sprite theyre gonna be and what pokemon they will have?
 

.Tactic.

x.Paranoid's BackAlley.x
1,309
Posts
15
Years
At first the sprite changed work, but the character didn't move. so I re-pointed the offsets, now the overworld change doesn't happened but the character can move.
Spoiler:
 
38
Posts
14
Years
  • Seen Mar 4, 2010
k thanks pokepal i got it all fixed up what i want to know now is how would i make a character have a script where he could heal my pokemon i cant us the same one as nurse joy because it would require the machine wouldnt it
 

TB Pro

Old-timer
2,708
Posts
19
Years
Is there any way to continue a script after a trainer battle? Or would I have to do it in a level script?
Yeah, use trainerbattle 0x1.

k thanks pokepal i got it all fixed up what i want to know now is how would i make a character have a script where he could heal my pokemon i cant us the same one as nurse joy because it would require the machine wouldnt it
fadescreen 0x1
fanfare 0x[healing fanfare]
waitfanfare
special 0x0
fadescreen 0x0

That would look like: Screen fades to black, healing noise happens, pokemon is healed, screen fades back to normal. :D
 
Last edited:
38
Posts
14
Years
  • Seen Mar 4, 2010
Yeah, use trainerbattle 0x1.


fadescreen 0x1
fanfare 0x[healing fanfare]
waitfanfare
special 0x0
fadescreen 0x0

That would look like: Screen fades to black, healing noise happens, pokemon is healed, screen fades back to normal. :D
would i be able to put that on a Owsprite or will i have to put more into the script
 
1,774
Posts
15
Years
I'll delve into this more tomorrow when I'm actually on my computer, but I'm wondering...
In Emerald, you remember how you can have a Multi battle with Steven Vs the two Magma guys? Is there anyway to rescript a multi battle like that in Emerald, without using Raws? (you see, I remember once opening the script in XSE, and just seeing a crapload of Raws, I don't even think there's a trainerbattle command there).
Yes, I am relatively new to scripting, but I'm not having much trouble understanding stuff, so if anyone has a genuine answer then go as detailed as you want.
I guess I just want to know if it's possible to script such multi battles elsewhere in the game, and, if so, to use different backsprites, like Wally's or Red's.
 

/Circa

a face in the clouds.
881
Posts
16
Years
Script doesn't continue after the battle plus theres some wierd cmdc3 stuff which I didn't put there :S

Code:
'---------------
#org 0x27978C
checkflag 0x216
if 0x1 goto 0x82797EF
applymovement 0x6 0x82797F2
waitmovement 0x0
msgbox 0x82797FC MSG_NORMAL
applymovement 0x6 0x82797F5
waitmovement 0x0
trainerbattle 0x1 0x6 0x0 0x827980C 0x8279838 0x279852
msgbox 0x8279852 MSG_NORMAL
fadescreen 0x1
setflag 0x216
hidesprite 0x5
hidesprite 0x3
fadescreen 0x0
applymovement 0x1 0x82797F9
waitmovement 0x0
msgbox 0x8279893 MSG_NORMAL
setflag 0x829
release
end

'---------------
#org 0x2797EF
release
end

'---------------
#org 0x279852
cmdc3 0xB4

'---------
' Strings
'---------
#org 0x2797FC
= Erased

#org 0x27980C
= Erased

#org 0x279838
= Erased

#org 0x279852
= Erased

#org 0x279893
= Erased


'-----------
' Movements
'-----------
#org 0x2797F2
#raw 0x62 'Exclamation Mark (!)
#raw 0xFE 'End of Movements

#org 0x2797F5
#raw 0x10 'Step Down (Normal)
#raw 0x2 'Face Left
#raw 0xFE 'End of Movements

#org 0x2797F9
#raw 0x0 'Face Down
#raw 0xFE 'End of Movements
 
39
Posts
15
Years
  • Age 29
  • Seen Aug 20, 2010
I made a simple test script to ensure that I understand how to script warps, but nothing happens when you step on the script tile. What's wrong with it? (The script is in Ruby, if it matters.)

'-----------------------
#org 0xEEEEEE
warp 0x0 0x9 0xFF 0x2 0x2
 
39
Posts
15
Years
  • Age 29
  • Seen Aug 20, 2010
a lot, the offsets wrong, there is no end. you properly didn't put the unknown at 3 or the var number at 4050.

What's wrong with the offset? Offsets are 6 hex digits, so the maximum is 0xFFFFFF; I only did 0xEEEEEE and I've successfully used scripts at that offset before. What unknown and var number? I don't understand.

EDIT: Never mind, I added "end" and now it works.
 

TB Pro

Old-timer
2,708
Posts
19
Years
Script doesn't continue after the battle plus theres some wierd cmdc3 stuff which I didn't put there :S

Code:
'---------------
#org 0x27978C
checkflag 0x216
if 0x1 goto 0x82797EF
applymovement 0x6 0x82797F2
waitmovement 0x0
msgbox 0x82797FC MSG_NORMAL
applymovement 0x6 0x82797F5
waitmovement 0x0
trainerbattle 0x1 0x6 0x0 0x827980C 0x8279838 0x279852
msgbox 0x8279852 MSG_NORMAL
fadescreen 0x1
setflag 0x216
hidesprite 0x5
hidesprite 0x3
fadescreen 0x0
applymovement 0x1 0x82797F9
waitmovement 0x0
msgbox 0x8279893 MSG_NORMAL
setflag 0x829
release
end

'---------------
#org 0x2797EF
release
end

'---------------
#org 0x279852
cmdc3 0xB4

'---------
' Strings
'---------
#org 0x2797FC
= Erased

#org 0x27980C
= Erased

#org 0x279838
= Erased

#org 0x279852
= Erased

#org 0x279893
= Erased


'-----------
' Movements
'-----------
#org 0x2797F2
#raw 0x62 'Exclamation Mark (!)
#raw 0xFE 'End of Movements

#org 0x2797F5
#raw 0x10 'Step Down (Normal)
#raw 0x2 'Face Left
#raw 0xFE 'End of Movements

#org 0x2797F9
#raw 0x0 'Face Down
#raw 0xFE 'End of Movements
Yeah, trainerbattle 0x1 works differently than you thought. The last offset on trainerbattle(0x279852) is the offset where it continues from. So it would be like this:
Code:
trainerbattle 0x1 0x6 0x0 @before @after @later
end

#org @later
msgbox @talk 0x6
fadescreen 0x1
setflag 0x216
ect.
 
Status
Not open for further replies.
Back
Top