SkyTemple 101
This page contains some tips on how to use SkyTemple.
How to apply ASM patches or SkyPatches
When you open the ROM for the first time, double click on Patches -> ASM. There, you can find quite a few built-in patches. Some enhances the gameplay, some fixes bugs and some allows editing certain parts of the game. The most important patch for ROM hacking is ActorAndLevelLoader. It allows you to add new or editing existing actors and allows you to add or edit existing cutscenes or overworlds. Additionally, some patches require other patches to be applied first, the most often requirement being ExtraSpace.
In Patches->ASM, at the Others tab, you can apply your own, custom SkyPatches. If you open the location of your ROM, you'll see a folder with the same name as your ROM, with .skytemple at the end. In there, you can see the folder called "patches". Put any .skypatch file you need to apply to that ROM, head to Patches->ASM, then Others and apply the patch. When you open the Others tab, you may see a warning about compatibility. All this warning means is that in the future updates of SkyTemple, you may or may not be able to apply the patch. If you already applied the patch, updating SkyTemple won't break it.
This warning exists in the older version of SkyTemple. Newer versions disallow any incompatible patches.
Editing starter pokemon
Going to Lists->Starters allows you to edit the default Pokemon, default name, as well as the starting level and the list of what Pokemon you can get or select in Personality Quiz. If you only want to use the default starters, follow this tutorial.
Creating a scene
After applying ActorAndLevelLoader, you can edit existing or add new cutscenes or overworld in the game in Script Scenes tree. All existing cutscenes (Acting Scenes) and over worlds (Enter Scenes) are located in separate folders with the name, corresponding to the background it uses. All folders are sorted by what letter is in the beginning. To add a new folder, double click on Script Scenes, then in the opened tab, press the plus button at the bottom, name the folder, then scroll the list with scenes to the bottom. There, you can edit what background it uses, as well as what name will be shown to the player in the overworld if this scene is loaded. Then, if you're using the background from the original, search for applicable Script Scene in the list, remember its Type, then go back to your scene, then edit its Type to what was used by existing scene. If you're using a custom background, however, just put One Layer or Two Layers based on how many layers your background has.
To add a new Acting or Enter Scene, double click on the folder where you want the scene to be added, then press Add Acting Scene (or Add Enter Scene). Then, just place actors where you want them to be at the beginning of the scene, then place a performer where you want the camera to be in (only for Acting Scenes!)
Acting scripts: how to write, how to play
After creating your first Acting Scene and placing actors and performer, double click on the script on the right of the screen (SceneName.ssb). It'll open up an empty file.
Every single scene must have def 0 {//the rest of the code is here} at the beginning. In the list of important for an Acting script code, there is also:
main_SetGround(LEVEL_LEVELNAME);- loads the scene's backgroundsupervision_Acting(0);- loads all actors, objects and performers.camera_SetMyself<performer 0>();- sets the camera's position to wherever performer 0 is located.screen_FadeIn(1, 60);- starts to brighten up the bottom screen (1 disallows the script from continuing until this code finishes running, 60 is the amount of frames the game will take to fade in (in this case, 1 second)
All codes mentioned here must be run in this exact order! Otherwise, it won't work as expected.
After that, you can start writing whatever code you want. You can use scripting cheatsheet and list of Opcodes for help. In the end, scenes without a transition to the overworld should have screen_FadeOut(1, 60). Additionally, all scripts without the exceptions should have some way of ending the script (whether it is by using end;, JumpCommon, etc.)
To test whether the code is running or not, open COMMON/unionall.ssb on the left. Then, search for coro EVENT_M01_01_02 and put supervision_ExecuteActingSub(LEVEL_LEVELNAME, 'ScriptName', 0); after CallCommon. Then, save everything, start the game, press New Game, then, in the Debug menu, press No, go to the next page, then press Main 1.
Common scripting mistakes
- Scene looks like a garbled mess upon fade in
Wrong Script Scene's Type. The amount of layers specified in Script Scene's settings must match with the amount of layers used background has.
- The camera appears on the top left
Check if the scene has a performer. If it does, check if the order of codes at the beginning has been followed. If so, check if both scenes and scripts are saved.
- Game freaks out after the last line of code
Script doesn't contain any opcodes that would end it (end;, JumpCommon, etc.)
- SkyTemple throws an error on the line
camera_SetMyself<performer 0>();
Outdated version of SkyTemple. Use this instead:
with (performer 0) {
camera_SetMyself();
}
instead.
- Screen shows a garbled mess for a frame before showing a background, without any fade
Put screen_FadeOut(1,0); right after def 0 {.
Editing actors
To edit or add new actors, go to Lists->Actors. There, you can see all characters that exist in the game, and a plus button at the bottom to add new one. Upon pressing it, you need to scroll down all the way until you see an actor with a name NEW. By double clicking, you can change the internal name, the species, as well as what name should this character have. In order to do that, go to Text Strings -> English, and in the opened tab, search for "Dummy", double click on found entry, then put a name for your new character. Remember the ID of that string! Now, go back to Lists->Actors, scroll down to the end, then put an ID of the string you edited to Text String for Name.
Adding new objects
If you want to add the new object, apply ExtractObjectTable first. After that, double click on Objects Sprites, then click on New Object Sprite. After that, save and reload the ROM (it is necessary, otherwise, you'll get an error on the next step). Then, find the new object sprite, and import your object. If you just want a static object, press Import Image. An image you have must be indexed, have 16 colors (one of which is transparency color) and up to 512x512 resolution. Then, go to Lists->Objects, press plus button, scroll down, rename the last object exactly the same as object sprite is named, then save and reload the ROM again.
Adding new Pokemon
Before starting adding a Pokemon, head to a sprite repository and make sure that a Pokemon that you want to add has any sprites and portraits.
To add a new Pokemon without overwriting existing ones, expand the Pokemon list on a sidebar, and scroll down until you see ????????? slots. Do not use reserve slots, Pokemon in these slots cannot be used in dungeons! Then, expand the slot. You'll see two entries - one is used for a male, one is used for a female pokemon. Double click on the first entry. There, you need to edit pokemon name and category and, if needed, statistics and a moveset. After that, click ≡ button on the top, then click "Open SpriteCollab Browser..." There, you can search for a Pokemon of your choice and import the sprites and portraits. Sprites should be added in the new sprite slot, not overwrite existent one.
Keep in mind: if you want to publish your ROM hack in the hack repository, you must have credits for used sprites and portraits!
If you want to add a female version of a Pokemon too, click on Export, scroll the list in point 2b, then select the second entry of the Pokemon slot and press Export. Then, double click on that entry in the sidebar and change the Gender to Female. If a female version of a Pokemon has a different appearance compared to a male(example: Meowstic), open SpriteCollab Browser again and import female sprites and portraits.