• 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.

Sierra's MEGA-HUGE XSE Scripting Tutorial

TheZerox9

That's Right
10
Posts
13
Years
hey is it possible to script a wildbattle that is inescapable cause i need it 4 my game.
basically, the fact that you cannot proceed until a wild pokemon in your way is beaten.
NO RUNNING AWAY
 
6
Posts
12
Years
  • Seen Mar 1, 2014
What about creating a legendary poemon battle? I would guess that it uses something similar to a gym battle, but formatted for Pokemon...

If anyone knows this please PM me, I don't know if I can keep track of this
 

Quilava's Master

Shattered Dreams '13
694
Posts
16
Years
  • Seen Aug 14, 2023
hey is it possible to script a wildbattle that is inescapable cause i need it 4 my game.
basically, the fact that you cannot proceed until a wild pokemon in your way is beaten.
NO RUNNING AWAY
Use
"special2 LASTRESULT 0xB4
compare LASTRESULT 0x[insert number here]
if 0x1 goto @pointer"
after the wildbattle command. The special 0xB4 checks for the result of the battle then sets a value to the variable.

comparing 0x1 checks if the pokemon fainted
comparing 0x4 checks if you ran away
comparing 0x7 checks if you caught the Pokemon.
 

bcrobert

Lazy Antagonist
82
Posts
12
Years
  • Seen Aug 8, 2022
Great tutorial.

Is the list of flags that have been used in the Emerald ROM complete or partial? I've been adding flags from 0x900 to 0x920 since they look unused, but I just want to make sure I'm not screwing myself over for later.
 
26
Posts
14
Years
  • Seen Nov 6, 2016
hi, im getting stucked in scripting in emerald than fire red,

'---------------
#org 0x827D52
lock
applymovement 0x9 0x8827D68
waitmovement 0x9
msgbox 0x8827DAD 0x6 '"yoh!"
release
end


'---------
' Strings
'---------
#org 0x827DAD
= yoh!


'-----------
' Movements
'-----------
#org 0x827D68
#raw 0x8 'Step Down (Normal)
#raw 0xFE 'End of Movements


i putted that code (just a example), when i put the offset above and put the 4050 in var num and 0300 (i tried 0003) brendad dont walk and try to talk, its not freezing, but my char just step and, darn! nothing happen, i tried to 4051 to 5000 but nothing work, i tried 0000 to 0003 nothing work, do all combination, nothing work,, what should i put in var number and unknown in emerald, but i tried in fire red, RED walks and talk. but in emerald, nothing happens.

hi, im getting stucked in scripting in emerald than fire red,

'---------------
#org 0x827D52
lock
applymovement 0x9 0x8827D68
waitmovement 0x9
msgbox 0x8827DAD 0x6 '"yoh!"
release
end


'---------
' Strings
'---------
#org 0x827DAD
= yoh!


'-----------
' Movements
'-----------
#org 0x827D68
#raw 0x8 'Step Down (Normal)
#raw 0xFE 'End of Movements


i putted that code (just a example), when i put the offset above and put the 4050 in var num and 0300 (i tried 0003) brendad dont walk and try to talk, its not freezing, but my char just step and, darn! nothing happen, i tried to 4051 to 5000 but nothing work, i tried 0000 to 0003 nothing work, do all combination, nothing work,, what should i put in var number and unknown in emerald, but i tried in fire red, RED walks and talk. but in emerald, nothing happens.
 
Last edited:

peirau

........
53
Posts
17
Years
  • Age 28
  • Seen Apr 12, 2013
When I put boxset 5 in my Script it keeps giving me "unknown keyword" -_-....
Anyone a solution?
Thanks,
 

colcolstyles

Yours truly
1,588
Posts
15
Years
When I put boxset 5 in my Script it keeps giving me "unknown keyword" -_-....
Anyone a solution?
Thanks,

'callstd' is the XSE equivalent of 'boxset'. However, if you're using it with a 'msgbox' command, you should be appending the number (0x2, 0x6, etc.) to the end of the 'msgbox' construct instead.
 

peirau

........
53
Posts
17
Years
  • Age 28
  • Seen Apr 12, 2013
'callstd' is the XSE equivalent of 'boxset'. However, if you're using it with a 'msgbox' command, you should be appending the number (0x2, 0x6, etc.) to the end of the 'msgbox' construct instead.

Thank you very much brother I will test it :).
 

Weavile05

Currently Hacking BW
1,431
Posts
13
Years
Okay, I would just like to clarify something. I haven't gotten very far in the tutorial yet, but I want to see if I can impress myself with my awesome inference skills.

So I made a givepokemon script. Long story short, your Mom gives you a Houndoom because it is your birthday. After that, she tells you to go see Professor Oak (unless i decide to change the Prof.). What I plan on doing is having the Prof. give you a Pokedex when he sees you have a Pokemon. So in order to do this, would you do something like this?

#org @start
msgbox @1 0x6
checkflag 0x828
if 0x1 goto @pokedex
msgbox @2 0x6
release
end

#org @pokedex
checkflag 0x(pokedex flag, I think it's 829)
if 0x0 goto...

And I'm not sure from there, but it would be whatever code gives you the pokedex. Right? I mean I'm pretty sure that's not exactly right, but am I at least on the right track?
 

DrFuji

[I]Heiki Hecchara‌‌[/I]
1,691
Posts
14
Years
Okay, I would just like to clarify something. I haven't gotten very far in the tutorial yet, but I want to see if I can impress myself with my awesome inference skills.

So I made a givepokemon script. Long story short, your Mom gives you a Houndoom because it is your birthday. After that, she tells you to go see Professor Oak (unless i decide to change the Prof.). What I plan on doing is having the Prof. give you a Pokedex when he sees you have a Pokemon. So in order to do this, would you do something like this?

#org @start
msgbox @1 0x6
checkflag 0x828
if 0x1 goto @pokedex
msgbox @2 0x6
release
end

#org @pokedex
checkflag 0x(pokedex flag, I think it's 829)
if 0x0 goto...

And I'm not sure from there, but it would be whatever code gives you the pokedex. Right? I mean I'm pretty sure that's not exactly right, but am I at least on the right track?

Yes, the Pokedex is activated with flag 0x829.

You're heading in the right direction from what I can see from your script fragment. I can't see any errors and (at this point) it looks like it will be doing what you stated above.
 

Weavile05

Currently Hacking BW
1,431
Posts
13
Years
Yes, the Pokedex is activated with flag 0x829.

You're heading in the right direction from what I can see from your script fragment. I can't see any errors and (at this point) it looks like it will be doing what you stated above.

Awesome. Now I've just gotta figure out how to actually give the pokedex... I'm sure that's explained later in the tut though.
 

ZxC Mirai

Huh?
267
Posts
12
Years
TAKE A LOOK AT THIS PLEASE :D

T_T why it doesn't COMPILES???

i cant click the Compile Button

SORRY I AM NEBIE IN SCRIPTING

Look at my screenshot

Soory for Double Posting :D
 

DrFuji

[I]Heiki Hecchara‌‌[/I]
1,691
Posts
14
Years
T_T why it doesn't COMPILES???

i cant click the Compile Button

SORRY I AM NEBIE IN SCRIPTING

Look at my screenshot

Soory for Double Posting :D

You also need to open your ROM in XSE. Use the folder icon to select the ROM you want to insert the script in and then you should be able to compile the script.

You should also put in a viable offset at the top of your script.
 
Last edited:
32
Posts
13
Years
  • Seen May 9, 2015
Heh I have another problem...How can I delete scripts which was compiled to ROM by me...Well, there're too many problems witch overwrite it in hex, (ROM is unstable after it...)...So how can I do that ??
 

ZxC Mirai

Huh?
267
Posts
12
Years
what will i gonna do copy the Start offset and then Paste the
offset in a Person in AM????

please Help ME!!

can anyone answer my question PLEASE!!!

:(
 
Last edited:

aperso

Please feel free to VM random fruit types.
171
Posts
13
Years
what will i gonna do copy the Start offset and then Paste the
offset in a Person in AM????

please Help ME!!

can anyone answer my question PLEASE!!!

:(

yes that is what you do if you don't do that the script won't appear was that helpful enough
 
Back
Top