hot_kage
I am like a rose cute and calm
- 35
- Posts
- 16
- Years
- Long Beach , California
- Seen Feb 14, 2009
XSE Scripting Tutorial
This Tutorial Does Not Cover Basics, Just Certain Scripts.
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 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.
now for the script itself:
The 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
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.
now for the explanation;
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:
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:
for example to warp to pallet town, your house you would type:
now 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
now the next warp we will discuss is the warpteleport! now here once again the only difference is that instead of warp, you do warpteleport;
next is the warpwalk;
now is the warp2:
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:
pretty simple?
now the checkpcitem checks if the player has the item of his/her PC.
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.
Code:
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 = 0xE
Code:
#dynamic 0x800000
#org @start
checkflag 0x200
if 0x1 goto @next
[B]setweather 0x7[/B]
doweather
setflag 0x200
release
end
#org @next
setweather 0x2
doweather
clearflag 0x200
release
end
Say you want it to snow you would replace the 0x3 with 0x7.
so now the script is
Spoiler:
#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
#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.
Code:
#dynamic 0x800000
#org @start
setmaptile 0x0E 0x13 0x1 0x0
special 0x8E
release
end
Spoiler:
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:
Spoiler:
0x0 = Passable
0x1 = Blocked off
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:
Code:
warp 0x(map bank) 0x(map number) 0x(warp number)
Code:
warp 0x3 0x0 0x0
the only difference is that instead of the warp command you write the warphole command
Code:
warphole 0x3 0x0 0x0
Code:
warpteleport 0x3 0x0 0x0
Code:
warpwalk 0x3 0x0 0x2
now is the warp2:
Code:
warp2 0x3 0x0 0x2
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:
Code:
addpcitem 0x(item number) 0x(quantity)
pretty simple?
now the checkpcitem checks if the player has the item of his/her PC.
Code:
checkpcitem 0x(item number) 0x(quantity)