-
Notifications
You must be signed in to change notification settings - Fork 45
Tutorial: Actions
Like most RPGs, battles are an integral part of EarthBound, and what better way to fight than with yo-yos, baseball bats, and PSI Rockin'? Of course, the properties of these actions have to be defined somewhere, and that's what we'll look at in this chapter.
List of files used:
battle_action_table.yml
The battle_action_table.yml file describes every single possible action that can be taken
during a battle by either side, be it using a PSI ability, an item, or any of the miscellaneous abilities
available. Let's take a look at the entry for PSI Rockin:
12:
Action type: psi
Code Address: $c29568
Direction: enemy
PP Cost: 40
Target: all
Text Address: $ef8543-
Action type- Defines whether it is apsiability, anitem's action, a physical attack (which can be aphysical (affected by shields and defending)attack or aphysical (unaffected by shields and defending)attack), anotheraction (such as Paula's Pray), ornothing(which you should never use, but exists nonetheless). -
Code Address- Indicates the location of the assembly code to be executed when this action is triggered, whether through a pointer or a CCScript label (see the next section). -
Direction- Indicates whether the action should happen to theenemyor to theparty; the actual group referenced by this varies depending on who is using the action, whether it is one of the player characters or an enemy. -
PP Cost- The amount of PP points which will be subtracted from the ability-user's statistics. -
Target- Can either beall(to indicate all enemies or all party members),one(to indicate a specific character),row(to indicate a row of enemies),random(to randomly select an enemy) ornone(for miscellaneous battle actions). -
Text Address- Takes either a pointer or a CCScript label to the text to use as the action's text displayed when it has been used.
This nifty CCScript file can change the damage of PSI and some items! BattleNumbers.ccs by H.S
It was originally posted on the Starmen.net forums with this description:
This .ccs file makes it easy to edit the damage of PSI and some items, similar to what the old PSI Damage Editor did in JHack. As before, asm65816.ccs is required here.
Just to help clarify that PSI Thunder animation thing…
The line atThunder_Animationis used to determine which animation is used for PSI Thunder. If one of the ranks of Thunder has the same base damage as the number inThunder_Animation, then it will use Thunder alpha/beta’s animation. So ifThunder_Animationis equal to 120, than any rank of Thunder that has a base damage of 120 will use Thunder alpha/beta’s animation.In the future, I’d like to make another version of this file that lets you edit more stuff, but for now, this will have to do.
Now while editing PSI Power costs and targets can sound like the most exciting past-time since eating sliced bread was invented, it is a lot more rewarding to actually create completely new actions that change the purpose of PSI Abilities – whether this is to heal more, to make enemies instantly die, or whatever other crazy effect your brain can come up with!
Lamentably, while CoilSnake makes a lot of things easy, it still requires the use of ASM (assembly code) to modify the effects of battle actions. SNES programming is beyond the scope of this manual, but if you feel daring enough to learn this dark and ancient voodoo, you might be interested to know that you can write this code from within CCScript (see the CCScript tutorial for information on this), then reference it from within battle_action_table.yml.
There are ways to avoid directly writing assembly code, though. Many common battle actions can be created using the self-described "weird Lisp" macro format that attack_script by JTolmar provides. This file is also linked to on the CCScript Library.
If for whatever reason the vanilla game's 300+ actions aren't enough room for all of your attacks, or you just don't want to deal with certain recovery actions being on the "don't retarget to another battler" list, CoilSnake currently doesn't support adding new actions to battle_action_table.yml. Maybe it will in the future. In the meantime, though, the community has invented a CCScript solution to replace battle_action_table.yml's functionality with a CCScript file: Extended Battle Action Table by D-Man. This file is also linked to on the CCScript library.
With the power to change battle actions, you can find new and innovative ways to let your characters annihilate Giygas' minions (or even Giygas himself, with the mighty Smelly Sock of Doom!). The next step is to define these battle enemies...
- Overworld Sprites
- Battle Backgrounds
- Battle Sprites
- Title Screen
- Window Graphics
- Logos
- Fonts
- Layer 3 Animations
- Expand PSI Animations
- Swirls
- NPCs
- CCScript
- CCScript Command Documentation
- Event Flags
- Playable Characters
- Temporary Party Members
- PSI Abilities