PDA

View Full Version : Special XSE Scripts


hot_kage
December 28th, 2008, 05:41 PM
XSE Scripting Tutorial

This Tutorial Does Not Cover Basics, Just Certain Scripts.

In This Tutorial:
Weather Scripts
Warp Scripts
Setmaptile script
add/check pc item (addpcitem and checkpcitem)

To Come:
Money Scripts
Contest Scripts
sethealingplace
buffer scripts
pokepic scripts


Weather


Their are two simple commands to the weather script; setweather and doweather.

setweather will set the weather and doweather with activate it.

Now Here's A List of all the weather commands.
None = 0x0
Reflected Clouds = 0x1
Normal = 0x2
Rain = 0x3
3 Snowflakes = 0x4
Thunderstorm = 0x5
Fog = 0x6
Snow = 0x7
Sandstorm = 0x8
Diagonal Fog = 0x9
Thin Fog = 0xA
Bit Dark = 0xB
Overheat = 0xC
Thunderstorm2 = 0xD
None = 0xEnow for the script itself:

#dynamic 0x800000

#org @start
checkflag 0x200
if 0x1 goto @next
setweather 0x7
doweather
setflag 0x200
release
end

#org @next
setweather 0x2
doweather
clearflag 0x200
release
endThe Line setweather 0x3 means it sets rain and then doweather makes it rain. no another example.

Say you want it to snow you would replace the 0x3 with 0x7.
so now the script is

#dynamic 0x800000
#org @start
checkflag 0x200
if 0x1 goto @next
setweather 0x3
doweather
setflag 0x200
release
end

#org @next
setweather 0x2
doweather
clearflag 0x200
release
end
now another useful command is; resetweather.
this command resets the default weather of that area.
as it only prepares the ROM for the weather, it still suppose to be followed by doweather.

Setmaptile

This script replaces tiles in the map and replaces them with other tiles.
now the script for the setmaptile.

#dynamic 0x800000

#org @start
setmaptile 0x0E 0x13 0x1 0x0
special 0x8E
release
endnow for the explanation;
setmaptile 0x(X Coordinate) 0x(Y Coordinate) 0x(Tile Number) 0x(movement allowed)

You can find The X and Y coordinates and the tile number in Advance map. In the little status bar at the bottom on the far left of AM, you should have Block: Offset:
Movement allowed has two possible options:

0x0 = Passable
0x1 = Blocked off

This will reset the map so that it allows the tile to change . Without it you have to leave the map and then return for it to work

Warp

I Will be showing you all 4 Different Kinds of Warps!

First Is The Basic Warp:

warp 0x(map bank) 0x(map number) 0x(warp number)for example to warp to pallet town, your house you would type:

warp 0x3 0x0 0x0now for the second type of warp; warphole this script warps the player but with a hole effect.

the only difference is that instead of the warp command you write the warphole command

warphole 0x3 0x0 0x0now the next warp we will discuss is the warpteleport! now here once again the only difference is that instead of warp, you do warpteleport;

warpteleport 0x3 0x0 0x0next is the warpwalk;

warpwalk 0x3 0x0 0x2

now is the warp2:

warp2 0x3 0x0 0x2
now warp2 warps the player but with no sound effect.

now my final scripts are the addpcitem and checkpcitem

NOTE: These might not work properly cause i don't really know them D:

now the addpcitem adds a specified item to the PC.

here is how it works:

addpcitem 0x(item number) 0x(quantity)

pretty simple?

now the checkpcitem checks if the player has the item of his/her PC.

checkpcitem 0x(item number) 0x(quantity)

HackMew
December 29th, 2008, 09:17 PM
Not bad, but what about adjusting it to the new XSE database? XSE v1.1.1 is out now, and everyone should update as soon as possible ;)

Pokepal17
December 30th, 2008, 02:46 AM
This is pretty useful. Good work :P

hot_kage
December 30th, 2008, 09:05 AM
Not bad, but what about adjusting it to the new XSE database? XSE v1.1.1 is out now, and everyone should update as soon as possible ;)

oh okay i didn't know a new version was released

This is pretty useful. Good work :P

Thank You, Though Did Anyone else make a tutorial for these script?

Pokepal17
January 15th, 2009, 11:19 AM
oh okay i didn't know a new version was released



Thank You, Though Did Anyone else make a tutorial for these script?

Well as far as I know, they can be found in other tutorials but the are buried in themsomewhere and this tutorial is useful if I want to quicky find out about these three things.

The Void
July 18th, 2011, 05:19 AM
Does this work for PKSV? Just curious to know.

Articuno23
July 20th, 2011, 05:41 PM
Thanks for this. When is the next section out? I really want to know sethealingplace!

Quickster
July 20th, 2011, 07:15 PM
Thanks for this. When is the next section out? I really want to know sethealingplace!

Woahhh, I think you should find another tutuorial about sethealingplace, as this thread was created in 2008...

RomHacker23
October 10th, 2011, 07:34 PM
Thanks for this. When is the next section out? I really want to know sethealingplace!

You mean like the one in The Pokemon Tower of Lavender Town (FireRed/LeafGreen)?

If you want that script and you're slightly on the lazy side like I am (always tries to find a "cheat" or "side-route" around scripting...then I'd suggest copying the sethealingplace script from Pokemon Tower and adding it to the new area where you'd like your healing spot to be.

Now, if you'd like to learn the script so you can write it yourself or modify (if possible, not real sure on that) it to your needs...I'd suggest checking the Tutorial section. I'm sure you'll find something there that can show the afore-mentioned script (sethealingplace).

DavidJCobb
October 11th, 2011, 12:24 AM
Does this work for PKSV? Just curious to know.XSEI doubt it.

Thanks for this. When is the next section out? I really want to know sethealingplace!List of healing places. (http://www.pokecommunity.com/showthread.php?t=189304)