Go Back   The PokéCommunity Forums > ROM Hacking > Tools, Tutorials & Resources
Reload this Page [Tutorial] diegoisawesome's MEGA-HUGE XSE Scripting Tutorial

Notices
For all updates, view the main page.

Tools, Tutorials & Resources Various tools to help you develop your hacks can be found here.
New threads in this forum are to be approved by a moderator before they are displayed.



Reply
 
Thread Tools
  #651    
Old July 3rd, 2011 (02:55 PM).
timaeus222's Avatar
timaeus222 timaeus222 is offline
MegaMan/Pokemon ROM Hacker
 
Join Date: Aug 2010
Gender: Male
Nature: Relaxed
Posts: 47
When I mean a pause, I mean a natural pause, like when you're reading something and you reach a comma.
__________________
~Timaeus.EXE

http://m-pcr.co.cc/
http://youtube.com/timaeus22222

Working on FireRed eXtreme Patch [hard mode with tile edits and extras]

Reply With Quote
  #652    
Old July 3rd, 2011 (04:11 PM).
Masou Shoujo Haruna's Avatar
Masou Shoujo Haruna Masou Shoujo Haruna is offline
Don't touch me, I'm sterile
 
Join Date: Jun 2011
Gender: Female
Nature: Naive
Posts: 13
Quote originally posted by timaeus222:
When I mean a pause, I mean a natural pause, like when you're reading something and you reach a comma.
you mean \c\h08\h0X - Wait X ticks
#dynamic 0x800000

#org @start
msgbox @msg 0x2
end

#org @msg

= .\c\h08\h05.\c\h08\h05.\c\h08\h05 And thats how the cookie\ncrumbles.
Reply With Quote
  #653    
Old July 3rd, 2011 (04:40 PM). Edited July 3rd, 2011 by timaeus222.
timaeus222's Avatar
timaeus222 timaeus222 is offline
MegaMan/Pokemon ROM Hacker
 
Join Date: Aug 2010
Gender: Male
Nature: Relaxed
Posts: 47
\c\h08\h05

I copied it exactly as it was, but after it compiled it became this:
\c\h08È

And there ended up being no pause.

EDIT: Never mind. 5 was just a really short pause. Thanks!
__________________
~Timaeus.EXE

http://m-pcr.co.cc/
http://youtube.com/timaeus22222

Working on FireRed eXtreme Patch [hard mode with tile edits and extras]

Reply With Quote
  #654    
Old July 8th, 2011 (05:17 AM).
Mephodicus's Avatar
Mephodicus Mephodicus is offline
Inventor
 
Join Date: Jul 2011
Location: North Wales, United Kingdom
Age: 23
Gender: Male
Nature: Quiet
Posts: 22
Is there any way to change the battle music for certain trainers by scripting? Such as battling team aqua/magma, their music is different to normal trainer battles, however I would want to do this in Fire Red.
Reply With Quote
  #655    
Old July 8th, 2011 (12:00 PM).
aperso's Avatar
aperso aperso is offline
Please feel free to VM rndom fruit types.
 
Join Date: Feb 2011
Location: I live nowhere
Age: 16
Nature: Brave
Posts: 170
Quote originally posted by Mephodicus:
Is there any way to change the battle music for certain trainers by scripting? Such as battling team aqua/magma, their music is different to normal trainer battles, however I would want to do this in Fire Red.
that is done with A-trainer if i remember rightly?
__________________
Visit ROM Hackers Online, the next best thing in ROM Hacking covering all video games with research, guides and tutorials to help you become a better hacker.

Reply With Quote
  #656    
Old July 8th, 2011 (12:35 PM).
Mephodicus's Avatar
Mephodicus Mephodicus is offline
Inventor
 
Join Date: Jul 2011
Location: North Wales, United Kingdom
Age: 23
Gender: Male
Nature: Quiet
Posts: 22
Thanks for the tip, just have to figure out how to do so now.
__________________
I'm back, Baby!
Reply With Quote
  #657    
Old July 14th, 2011 (10:49 AM).
EdensElite's Avatar
EdensElite EdensElite is offline
No0b, but getting there.
 
Join Date: Jun 2011
Location: UK
Gender: Male
Nature: Bold
Posts: 190
Can somebody write a script for me, I want to delete Oak out of the picture and have it so you pick up the pokedex just by clicking it, How do you do this?
Reply With Quote
  #658    
Old July 14th, 2011 (12:38 PM).
Satoshi Ookami's Avatar
Satoshi Ookami Satoshi Ookami is offline
Memento Mori
Gold Tier
 
Join Date: Jul 2008
Location: Abyss of Time, Great Seal
Age: 23
Gender: Male
Nature: Calm
Posts: 13,391
Quote originally posted by EdensElite:
Can somebody write a script for me, I want to delete Oak out of the picture and have it so you pick up the pokedex just by clicking it, How do you do this?
setflag of pokedex depending on ROM you're using
__________________
ROM hacking FAQ - Read before asking how to play a hack. | Previous Sign 2 | Previous Sign

Anime List | PSN Trophy List
Reply With Quote
  #659    
Old July 18th, 2011 (02:03 PM).
g0ast's Avatar
g0ast g0ast is offline
N0ob Hacker *_*
 
Join Date: Jun 2011
Location: Sardegna, IT
Gender: Male
Nature: Brave
Posts: 27
Wow this helped me a lot. A month ago I was like: "I'll never learn how to script", and now I can do simple things but I'm learning quickly. Amazing tutorial.
Reply With Quote
  #660    
Old July 21st, 2011 (02:25 AM). Edited July 23rd, 2011 by xequiaz.
xequiaz's Avatar
xequiaz xequiaz is offline
Noopy Infinoopy ;3
 
Join Date: Jul 2011
Gender: Male
Posts: 12
I really thank you for this! Say, do you know what are the scripts for a roaming pokemon after you talk to them?

Also, is it possible to have a double battle for wild pokemon? I was kinda thinking of making one for Latios and Latias for a hack S:
Reply With Quote
  #661    
Old July 25th, 2011 (11:16 AM).
[T]ouko's Avatar
[T]ouko [T]ouko is offline
Dedicated Scripter!
 
Join Date: Jul 2011
Gender: Female
Posts: 46
Quote originally posted by xequiaz:
I really thank you for this! Say, do you know what are the scripts for a roaming pokemon after you talk to them?

Also, is it possible to have a double battle for wild pokemon? I was kinda thinking of making one for Latios and Latias for a hack S:
About the double wild battle, if I'm correct, there's a "Wild Double/Triple Battle" thread in the "Research and Development" section (also in Emulation), you'll find your answer there, I think.

For the roaming, maybe you could make it randomly pick a number between let's say 0-10. If 0 it'll be on Route 1, if it's 5 it will be at the Victory Road, for example... Just an idea though.
Reply With Quote
  #662    
Old July 28th, 2011 (03:10 PM).
Fortunado Fortunado is offline
Prof. Hemlock is busy now...
 
Join Date: Jul 2011
Age: 20
Gender: Male
Nature: Lax
Posts: 30
I have a small question. I'm trying to program an event that allows you to encounter Regirock in my ROM. To be a good sport, I want to make it so that if you beat the Elite 4 after K.O.-ing it instead of catching it, you'll be able to catch it again. Is there a command to check the player's Pokédex??
Reply With Quote
  #663    
Old July 29th, 2011 (09:49 AM).
[T]ouko's Avatar
[T]ouko [T]ouko is offline
Dedicated Scripter!
 
Join Date: Jul 2011
Gender: Female
Posts: 46
Quote originally posted by Fortunado:
I have a small question. I'm trying to program an event that allows you to encounter Regirock in my ROM. To be a good sport, I want to make it so that if you beat the Elite 4 after K.O.-ing it instead of catching it, you'll be able to catch it again. Is there a command to check the player's Pokédex??
So you want to check if you already caught it or not? I wouldn't know how to do that. Curious, though.

I also have a question, is it possible to let a trainer say something different when he wins a battle, like, yay I won, and something different when he loses, like, damn I lost?
__________________


Credits to: .Mini
Reply With Quote
  #664    
Old July 29th, 2011 (01:50 PM).
colcolstyles's Avatar
colcolstyles colcolstyles is offline
Yours truly
Crystal Tier
 
Join Date: May 2008
Location: The Bay Area
Gender: Male
Nature: Lonely
Posts: 1,592
Quote originally posted by [T]ouko:
I also have a question, is it possible to let a trainer say something different when he wins a battle, like, yay I won, and something different when he loses, like, damn I lost?
When the player loses, it just says "Player is out of usable Pokémon. Player whited/blacked out" and then warps to the last healing spot. There is no victory text for the trainer.
__________________

Brother of Vrai
Reply With Quote
  #665    
Old July 29th, 2011 (01:59 PM).
Lyzo's Avatar
Lyzo Lyzo is offline
On vacation
 
Join Date: Mar 2007
Location: The Netherlands
Age: 20
Gender: Male
Nature: Bold
Posts: 251
Send a message via Windows Live Messenger to Lyzo
Quote originally posted by Fortunado:
I have a small question. I'm trying to program an event that allows you to encounter Regirock in my ROM. To be a good sport, I want to make it so that if you beat the Elite 4 after K.O.-ing it instead of catching it, you'll be able to catch it again. Is there a command to check the player's Pokédex??
Not that I know of. It is possible with ASM though, and I don't think it's that hard to make either. I just recentley started learning it, and this was one of the first things you do, using Pokemon Data, so try and look up Shiny Quagsires ASM tutorial, that was the one I did
__________________


Thank you The Blueprint !!!
Reply With Quote
  #666    
Old July 29th, 2011 (02:12 PM).
[T]ouko's Avatar
[T]ouko [T]ouko is offline
Dedicated Scripter!
 
Join Date: Jul 2011
Gender: Female
Posts: 46
Quote originally posted by colcolstyles:
When the player loses, it just says "Player is out of usable Pokémon. Player whited/blacked out" and then warps to the last healing spot. There is no victory text for the trainer.
Well, I found out if you use: trainerbattle 0x9 instead of 0x0 or 0x1 or 0x2, you can make a script with trainerbattle, and after the battle you can script further. Like with rival battles, you run into them, you battle them, they leave. And if you use 0x3 in the 3 parameter (called reserved), you get the oak explanation, like it's the first battle.

Sorry I didn't say that, I forgot. But anyway, is there maybe a var in which is stored if you won or not....
__________________


Credits to: .Mini
Reply With Quote
  #667    
Old July 29th, 2011 (03:27 PM).
Lyzo's Avatar
Lyzo Lyzo is offline
On vacation
 
Join Date: Mar 2007
Location: The Netherlands
Age: 20
Gender: Male
Nature: Bold
Posts: 251
Send a message via Windows Live Messenger to Lyzo
Quote originally posted by [T]ouko:
So you want to check if you already caught it or not? I wouldn't know how to do that. Curious, though.

I also have a question, is it possible to let a trainer say something different when he wins a battle, like, yay I won, and something different when he loses, like, damn I lost?
ALright, after some searching I found out that this is possible. You can use
Code:
trainerbattle 0x09 [trainer] 0x3 @winchat @losechat
If you do that you can have a message for both winning and losing. But you can only continue the script in one way, meaning that after that you'll need a sentence which fits with losing and winning...
__________________


Thank you The Blueprint !!!
Reply With Quote
  #668    
Old July 29th, 2011 (03:45 PM).
Fortunado Fortunado is offline
Prof. Hemlock is busy now...
 
Join Date: Jul 2011
Age: 20
Gender: Male
Nature: Lax
Posts: 30
Quote originally posted by Lyzo:
Not that I know of. It is possible with ASM though, and I don't think it's that hard to make either. I just recentley started learning it, and this was one of the first things you do, using Pokemon Data, so try and look up Shiny Quagsires ASM tutorial, that was the one I did
Thanks for the help. This will help make my hack much better!
Reply With Quote
  #669    
Old July 29th, 2011 (04:06 PM).
Lyzo's Avatar
Lyzo Lyzo is offline
On vacation
 
Join Date: Mar 2007
Location: The Netherlands
Age: 20
Gender: Male
Nature: Bold
Posts: 251
Send a message via Windows Live Messenger to Lyzo
Quote originally posted by Fortunado:
Thanks for the help. This will help make my hack much better!
I hope you can manage the ASM If not, contact me and I'll have a try at it I'm also a beginner at ASM but maybe I can make it work
__________________


Thank you The Blueprint !!!
Reply With Quote
  #670    
Old July 31st, 2011 (09:14 PM). Edited August 2nd, 2011 by Fortunado.
Fortunado Fortunado is offline
Prof. Hemlock is busy now...
 
Join Date: Jul 2011
Age: 20
Gender: Male
Nature: Lax
Posts: 30
Quote originally posted by Lyzo:
I hope you can manage the ASM If not, contact me and I'll have a try at it I'm also a beginner at ASM but maybe I can make it work
I'll keep you in mind, Lyzo. Well, I'm off to decapatlize everything. =.=

EDIT: Well, I'm trying to make a once-per-day step-count limited minigame. I've got most of the stuff down, I just need to know how to make it only happen once a day and have a step count limit of 500.
Reply With Quote
  #671    
Old August 5th, 2011 (02:09 PM).
Pokeshadow13's Avatar
Pokeshadow13 Pokeshadow13 is offline
Me^^
 
Join Date: May 2011
Location: Behind You!
Gender: Male
Nature: Jolly
Posts: 15
thankyou diego!

this is great.

im decent at scripting, but its allways helpfull to have the "owners manual"

thanks!
__________________
I am Pokeshadow to the 13th power - Pleased to meet you!

I support:



I make Banners for hire!
(Naranja banner by Me)

Hehehe... Rawr!
Reply With Quote
  #672    
Old August 6th, 2011 (07:06 PM).
madarawolf's Avatar
madarawolf madarawolf is offline
Espada Cuarta
 
Join Date: Nov 2008
Gender:
Posts: 56
I want to make a system like combing two pokemon. so I thought I would do it using a trade. for example, give venusaur and blastoise and get a venustoise back. Is it possible to set up a script that will let me do this?
__________________
why yes I am made of awsome
Reply With Quote
  #673    
Old August 6th, 2011 (10:44 PM).
ZxC Mirai's Avatar
ZxC Mirai ZxC Mirai is offline
Huh?
 
Join Date: Jun 2011
Location: Pampanga Philippines
Gender: Male
Nature: Timid
Posts: 267
could some one Tell me what is Wrong With this SCRIPT???

#dynamic 0x800000

#org @start
checkflag 0x1000
lock
faceplayer
msgbox @1 0x6
applymovement 0xFF @move
waitmovement 0x0
msgbox @2 0x6
applymovement 0x1 @move2
Hidesprite 0x1
setflag 0x1000
release
end

#org @1
= Finally You Have Come!\nPlease Fall in line over There!

#org @move
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x1
#raw 0xFE

#org @2
= Alright!We can start Now!\pToday is the Giving of POKeMON and\nTask! Listen Up New Recruits!\pLet's Start with giving POKeMON\pThere are 4 PokeBalls Here!\nEach Contained\lMeowth,Zigzagoon,Ekans and Ratata.\pChoose one here!\phmmmmm!! You Over There\nWhat is your Name?\pMe?\pAer:Yeah You!\pIm [player]\pekekekekek!What a Name!\nYour the First To Pick Go on\lChoose One!\pAfter all of you have choose Meet\nme at ??? CITY! Got It?\pAlright i gotta go!

#org @move2
#raw 0x13
#raw 0x13
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x12
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x60
#raw 0xFE

How can i make when it says the @2 he wouldn't say it Again??
and when i finished talking to Him wouldn't move??
i have put the Correct Person no.....
__________________





POKEMON SkyWhite COMING SOON....
Reply With Quote
  #674    
Old August 6th, 2011 (11:26 PM).
Satoshi Ookami's Avatar
Satoshi Ookami Satoshi Ookami is offline
Memento Mori
Gold Tier
 
Join Date: Jul 2008
Location: Abyss of Time, Great Seal
Age: 23
Gender: Male
Nature: Calm
Posts: 13,391
First you are missing waitmovement after second applymovement.
Second... you shouldn't use hidesprite... it's buggy. It's better to hide your script with movement hide/disappear (find it in diegoisawesome's tutorial =) depending on the game =)).
And then the another thing =)
If you want that OW to disappear permanently delete checkflag 0x1000 command and put 1000 into person's ID in A-Map.
If you want to leave OW where it is and you just don't want script to repeat itself add this after checkflag:
if 0x1 goto @after

And then the @after must be new #org with msgbox you want OW to say once it finishes the first script =)
__________________
ROM hacking FAQ - Read before asking how to play a hack. | Previous Sign 2 | Previous Sign

Anime List | PSN Trophy List
Reply With Quote
  #675    
Old August 7th, 2011 (12:17 AM). Edited August 7th, 2011 by ZxC Mirai.
ZxC Mirai's Avatar
ZxC Mirai ZxC Mirai is offline
Huh?
 
Join Date: Jun 2011
Location: Pampanga Philippines
Gender: Male
Nature: Timid
Posts: 267
Quote originally posted by Ash493:
First you are missing waitmovement after second applymovement.
Second... you shouldn't use hidesprite... it's buggy. It's better to hide your script with movement hide/disappear (find it in diegoisawesome's tutorial =) depending on the game =)).
And then the another thing =)
If you want that OW to disappear permanently delete checkflag 0x1000 command and put 1000 into person's ID in A-Map.
If you want to leave OW where it is and you just don't want script to repeat itself add this after checkflag:
if 0x1 goto @after

And then the @after must be new #org with msgbox you want OW to say once it finishes the first script =)
W0o0o0o0o0o0o0oW Thanks for the if 0x1 goto @after
i finally figure out that Hidesprite and Fixed it :D

Another Question:

How could i make a Script Like Gary?

in mine i have 2 Pokemon two choose ratata and meowth

what script if i choose ratata he will choose meowth
if i choose meowth he will choose ratata.

#dynamic 0x800000
#org @start
checkflag 0x350
lock
faceplayer
msgbox @talk 0x6
applymovement 0xFF @wew
waitmovement 0x0
applymovement 0x09 @wew2
waitmovement 0x0
msgbox @talk2 0x6
msgbox @talk3
applymovement 0x09 @wew3
waitmovement 0x0
setflag 0x350
release
end

#org @talk
= So?You have Finished Choosing Your\nPOKeMON? Alright i Choose mine\lnow!\pGet out of the Way!

#org @wew
#raw 0x10
#raw 0xFE

#org @wew2
#raw 0x13
#raw 0x13
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x2
#raw 0xFE

#org @talk2
= Alright i take This one then!

#org @talk3
= I gotta go and see Aer in ???\nCity!\pYou must seee him too [player]!

#org @wew3
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0x10
#raw 0xFE



and lastly what is the command when i talk to hi/her for the First time he/she will says:
blah blah blah was looking for you!

then after you tak to the blah blah blah his text will change with my Script is it if 0x1 goto @after??

Thanks to anyone who help me :D
__________________





POKEMON SkyWhite COMING SOON....
Reply With Quote
Reply
Quick Reply

Sponsored Links

You may also like.. (Beta)
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are UTC -8. The time now is 08:33 AM.