• 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 Trading Card Game 2 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.

[Archive] Script help thread

Status
Not open for further replies.
I edited in bold. You forgot the 'e' in take it.
#org $begin
lock
checkflag 0x800
if B_true goto $done
message $wait
$wait 1=Heey \v\h01!\pWait I still have \nyour Pokemon!
boxset 6
applymovement 0xFF $huh
pausemove 0
applymovement 0x1 $goto
pausemove 0
message $takeit
$takeit 1=Here take Pikachu \pI went to the \nPKMN Center with him ;)
boxset 6
givepokemon 25 5 0
#raw 0x75 0x52 0x00 0x0A 0x03
message $nice
$nice 1=Have a nice day honey!
boxset 6
#raw 0x76
message $wait2
$wait2 1=Ooh almost forgot I got \nyou an pokedex!\pHere take it!
setflag 0x829
setflag 0x828
special 0x16F
message $gotdex
$gotdex 1=\v\h01 received the PokeDex!
applymovement 0x1 $away
pausemove 0
setflag 0x800
release
end

#org $done
release
end

#org $huh
#raw 0x55 0x63 0xFE

#org $goto
#raw 0x10 0x10 0x10 0x10 0x10 0x10 0x12 0x10 0x12 0x02 0xFE

#org $away
#raw 0x13 0x11 0x13 0x11 0x11 0x11 0x11 0x11 0x11 0x03 0xFE
 
This is related to scripting, so I'll post it here.
Whats the fanfare that plays when you are about to go into a pokemon battle with a random trainer?
Theres 0x128 to 0x12B, theres more than one. They aren't fanfares though, they're music so you'll have to use playsong.
 
I'm pretty positive that there is a command that will allow you to change what happens in a script based on if you are standing above, below, or to either side of the person. What is this command, and how do you use it?

I've looked through the guides, and can't find it. But, it seems like I remember reading about it somewhere.

#raw 68
Compare 0x800C 0x1
If b_true goto $down
Compare 0x800C 0x2
If b_true goto $up
Compare 0x800C 0x3
If b_true goto $left
Compare 0x800C 0x4
If b_true goto $right

Depends on which direction the player is facing. ^_^
Thank you.
 
Last edited:
#raw 68
Compare 0x800C 0x1
If b_true goto $down
Compare 0x800C 0x2
If b_true goto $up
Compare 0x800C 0x3
If b_true goto $left
Compare 0x800C 0x4
If b_true goto $right

Depends on which direction the player is facing. ^_^
 
Could someone check what's wrong with this script... Thanks!

#org $Start
applymovement 0x03 $Move
pausemove 0x0
message $1
boxset 6
applymovement 0x03 $Move2
pausemove 0x0
setflag 0x200
end

#org $1
$1 1 = Text

#org $Move
#raw 0x10 0x02 0x03 0x10 0x10 0x02 0x03 0x10 0x10 0x63 0xFE

#org $Move2
#raw 0x11 0x11 0x11 0x11 0x11 0x11 0x11 0x11 0x11 0x11 0x11 0xFE
 
I tried this...

#org $Start
applymovement 0x03 $Move
pausemove 0x0
applymovement 0x03 $Move2
pausemove 0x0
message $1
boxset 6
applymovement 0x03 $Move3
pausemove 0x0
setflag 0x200
end

#org $1
$1 1 = Text

#org $Move
#raw 0x10 0x02 0x03 0x10 0x10 0xFE

#org $Move2
#raw 0x02 0x03 0x10 0x10 0x63 0xFE

#org $Move3
#raw 0x11 0x11 0x11 0x11 0x11 0x11 0xFE

BUt the same thing happens.... Nothing. I walk over the spot normally and no script occurs.

I then tried your method as well but no dice. Still nothing happens :(
 
Spoiler:


I use this in FireRed. However, the script worked 1x, it won't work again if I step in that script tile (or in one of the other 2 script tiles who got the other 2 setvars). Anyone knows what I'm doing wrong here?
 
Right, two things...

1) What do I add to a Script to prevent it from happening more than once?
2) How do I cause someone to disapear if I haven't talked to them through the use of a script event. I assign them there ID but I'm not sure how to make them actually disapear without having to leave the screen.

Thanks!
 
Right, two things...

1) What do I add to a Script to prevent it from happening more than once?
2) How do I cause someone to disapear if I haven't talked to them through the use of a script event. I assign them there ID but I'm not sure how to make them actually disapear without having to leave the screen.

Thanks!

1) Use checkflag / setflag, for instances something like this:

Code:
#org $start
checkflag 0x200
if b_true goto $end
lock
faceplayer ... etc
[b]setflag 0x200[/b]
release
end

#org $end
end

2) Use hidesprite and fadescreen. Now for instance, lets combine the prev script with the hide sprite thing:
Code:
#org $start
checkflag 0x200
if b_true goto $end
lock
faceplayer ... etc
[b]fadescreen 1
hidesprite 0xsprite number comes here
setflag 0x200
fadescreen 0[/b]
release
end

#org $end
end

Fadescreen 1 fades the screen completly, fadescreen 0 is actually only a flikker. However, when you use fadescreen 1, you must use fadescreen 0 after it so the screen would return to normal, cuz fadescreen 1 on it's own wouldn't un-fade the screen.
 
I tried this...

#org $Start
checkflag 0x200
if b_true goto $done

applymovement 0x03 $Move
pausemove 0
applymovement 0x03 $Move2
pausemove 0
message $1
boxset 6
applymovement 0x03 $Move3
pausemove 0
setflag 0x200
release
end

#org $done
release
end

#org $1
$1 1 = Text

#org $Move
#raw 0x10 0x02 0x03 0x10 0x10 0xFE

#org $Move2
#raw 0x02 0x03 0x10 0x10 0x63 0xFE

#org $Move3
#raw 0x11 0x11 0x11 0x11 0x11 0x11 0xFE

BUt the same thing happens.... Nothing. I walk over the spot normally and no script occurs.

I then tried your method as well but no dice. Still nothing happens :(

You forgot the release command.
I edited somethings in the bold.
Try now.

And DarkSalamnce
#org @end
release
end

And make sure to place your setvar value in varnumber in advance map, which in your case, is 4001.
 
what is the mistake in this script:
#org $der
lock
faceplayer
checkflag 0x200
if b_true goto $fight
trainerbattle 1 0x0A8 $before $after
message $ti sfido!
boxset 0x6
end

#org $fight
message $der
boxset 0x6
nop
nop
setflag 0x1204
release
end

#org $ti sfido!
= Mi chiamo Rino\pe sono un drago\nallenatore\palmeno lo dovrei essere\pdiventerò campione\ndel mondo\pall'attacco!

#org $before
= All'attacco

#org $after
= Noooo....!

#org $der
= la prossima volta...\pvincerò io!
 
TamerHaidar said:
And DarkSalamnce
#org @end
release
end

There's more to it than that. The first tile script works correctly (and keeps working after I stepped on it once) The other 2 however, don't, even though they use the same script. Once I stepped on the other 2, the first one stops working too....
 
Spoiler:


Try this.
And read thethethethe's tutorial clearly, since you have a lot of mistakes.

DarkSalamance
There maybe a problem with the setvars or varnumber.
Try changing th setvar or the value of it.
Like: setvar 7C40 0x1
Sorry if it didn't help.
 
Spoiler:


Try this.
And read thethethethe's tutorial clearly, since you have a lot of mistakes.

DarkSalamance
There maybe a problem with the setvars or varnumber.
Try changing th setvar or the value of it.
Like: setvar 7C40 0x1
Sorry if it didn't help.

Tried diffirent setvar, still same, tile one works until I step on one of the other 2. Varnumbers are correct, checked them all....
 
Status
Not open for further replies.
Back
Top