HomeChrono TriggerDragon Quest VIFinal Fantasy VIHeroes III


Final Fantasy VI



Final Fantasy VI Home

Hacking Guides
My Hacks & Patches
ROM Hacking Links
Final Fantasy VI monster command scripts guide


Command F0: Random attack
Command F1: Set target
Command F2: Formation change
Command F3: Display message
Command F4: Use command
Command F5: ???
Command F6: Throw or Use
Command F7: Special Event
Command F8: Bit Manipulation
Command F9: Variable Bit Manipulation
Command FA: Anomation
Command FB: Miscellaneous
Command FC: Conditional attacks


Command F0 (3 bytes): Random attack
Causes the monster to randomly select one of 3 attacks to use. The next 3 bytes are which attacks to use, each having an equal chance of being picked.


Command F1 (1 byte): Set target
Sets a special target for the next attack in the monster's command script. If the target is not valid, then standard targetting is used for the next attack. The first and only byte determines which target(s) the attack will target as follows:


Byte valueTargetByte valueTarget
00Terra01Locke
02Cyan03Shadow
04Edgar04Sabin
05Celes06Strago
07Setzer08Relm
09Mog0AGau
0BGogo0CUmaro
0DBanon0ELeo
30Monster #131Monster #2
32Monster #333Monster #4
34Monster #535Monster #6
36Self37All monsters except self
38All monsters39Random monster excluding self
3ARandom monster3BAll dead characters
3CRandom dead character3DAll dead monsters
3EAll dead monsters3FAll characters with wall status
40Random character with wall status41All monsters with wall status
42Random monster with wall status43All characters
44Random character45Character who last attacked
46All characters and all monsters47Use normal targetting
48Character #149Character #2
4ACharacter #34BCharacter #4
4C50% chance all targets (except self), 50% one random target (not self)4DTarget that was last targetted by Targetting


Command F2 (3 bytes): Formation change
Changes to a new monster formation.
The purpose of the 1st byte is unknown, it seems to cause glitches if it's not 0.
The Second byte and last 7 bits of third byte are which formation to change to.
The first bit of last byte determines if the monsters should get Max HP or not. If it's 1, then the monsters get max HP. If it's 0, then monsters retain HP and max HP from current formation.


Command F3 (2 bytes): Display message
Displays a message. The next 2 bytes determine which message to display.


Command F4 (3 bytes): Use command
Causes the monster to use a random character command. The next 3 bytes are the 3 commands to choose from, with each having an equal chance of being picked. Not all commands work correctly. This chart explains the effects of each command:


CommandEffectCommandEffect
00 FightWorks correctly01 ItemSays Dirk, but casts Fire
02 MagicCasts Fire03 MorphWorks correctly, but causes monster to move forward a step each time
04 RevertWorks correctly, but causes monster to move forward a step each time05 StealWorks correctly - Monster steals gold from party
06 Capture Works correctly - Monster steals gold, and does damage07 SwdtechCasts Fire with messed up name, and no animation
08 Throw Throws a Dirk09 ToolsSays Dirk but has strange results
0A Blitz Casts Fire with messed up animation0B RunicWorks correctly
0C Lore Casts Fire0D SketchWorks correctly, but fails against characters, so must target monster
0E Control Fails if used on characters, causes strange glitches if used on monsters0F SlotsCasts Fire, with messed up name, and no animation
10 Rage Casts Fire11 Leap Ends battle, Gau leaves party and can't be gotten back
12 Mimic Works correctly (mimics party's last attack)13 Dance Tries to dance Wind Song, Always casts fire once successful
14 Row Works correctly15 Def. Works correctly
16 Jump Works correctly17 X-Magic Casts Fire (only once)
18 GP Rain Works correctly19 Summon Casts Fire, with messed up name, and no animation
1A Health Works correctly1B Shock Works correctly
1C PossessWorks correctly, but fails against characters, so must target monster1D Magitek Casts Fire


Command F5 (3 bytes): ???
Used to bring in monsters that are currently hidden in the formation, or to kill monsters that are in the formation. The first byte determines which animation to use. Byte 2 determines whether to show monsters or kill monsters.
If byte 2 is 0 then monsters are brought in that are currently hidden or killed at full max HP.
If byte 2 is 1 then monsters are killed.
If byte 2 is 2 then monsters are brought in at their current HP.
If byte 2 is 3 then monsters are hidden and restored to full HP
If byte 2 is 4 then monsters are hidden without restoring HP

Byte 3 determines which monsters to affect. Each bit represents a monster, so F5 01 00 05 would show monsters 1 and 3. If byte3 is 0 then only the monster itself is affected.


Command F6 (3 bytes): Throw or Use
Makes the monster throw or use an item. If byte 1 is 0, then it uses and item, otherwise throws the item.
Byte 2 and 3 are two random items to use or throw. each having an equal chance of being picked.


Command F7 (1 byte): Special Event
Triggers a special event. the first byte determines which special event to trigger.


Command F8 (2 bytes): Variable Manipulation
Changes the value of a variable (See information on variables).
The first byte determines which variable to change.
The second byte determines the operation to use, and the operand. Bits 6 and 7 determine the operation:

ValueOperation
00Set variable
01Set variable
10Add to variable
11Subtract from variable

The first 6 bits of byte 2 are the operand.


Command F9 (3 bytes): Variable Bit Manipulation
Manipulates a specific bit of a variable (See information on variables).
Byte 1 is the operation:

ValueOperation
0Toggle bit
1Set bit
2Clear bit

Byte 2 is which variable to use, and Byte 3 is which bit to alter.


Command FA (3 bytes): Animation
Does a special animation.
Byte 1 is the animation to use:


ValueOperation
0Monster(s) flashes red
1Monster(s) moves back 1 step slowly
2Monster(s) moves forward 1 step slowly
3Monster(s) moves back 1 step quickly
4Monster(s) moves forward 1 step quickly
5Characters run to the right
6Characters run to the left
7Monster(s) steps back 3 steps quickly
8Monster(s) steps forward 3 steps quickly
9Unknown
ACauses head to appear, screen to shake (used by Kefka)
BAll monsters flash for a long time
CMonsters(s) flashes for a long time
DScreen flashes like boss death

Byte 2 determines which monsters to effect with the animation, each bit representing a monster.
The purpose of byte3 is unknown.


Command FB (3 bytes): Miscellaneous

Has a miscellaneous effect.
Byte 1 determines which effect, byte 2 determines which target(s) to affect (the target are determined just like the F1 command, if byte 2 is 0 then only the monster itself is affected.


Byte 1Effect
0Sets the target(s) battle timer to 0
1Target(s) becomes invincible
2Ends the combat
3Gau is added as a party member
4Sets global battle timer to 0
5Target(s) loses invincibility
6Target(s) becomes targettable
7makes target(s) untargettable
8Unknown
9End the combat
ADoes nothing
BMonster gains an unremovable status.
CMonster loses a status gained by FB 0B

For values B and C, byte 2 determines which status to add or lose:

ValueStatusValueStatusValueStatusValueStatus
0Blind1Zombie2Poison3M-Tek
4Invizible5Imp6Stone7Death
8Count9WeakAImageBMute
CBerserkDConfuseESeizureFSleep
10Dance11Regen12Slow13Haste
14Stop15Shell16Safe17Wall


Command FC (3 bytes): Conditional attacks
All commands following FC, until the next FE, are only executed if certain conditions are met based on the next 3 bytes.


FC 01:
Commands are executed if the last attack was a Command specified by the next byte. See the F4 command for a list of commands.


FC 02:
Commands are executed if the last attack was a Spell specified by the next byte.


FC 03:
Commands are executed if the last attack was the use of an item specified by the next byte.


FC 04:
Commands are executed if the last attack was of the element specified by the next byte as follows:

ValueElementValueElementValueElementValueElement
1Fire2Ice4Lightning8Poison
16Wind32Pearl64Earth128Water


FC 05:
Commands are executed if the monster has been previously damaged.


FC 06:
Commands are executed if a target's HP are currently at or below 128 * the value of the third byte. The second byte determines which target to check and is used the same as the value for the F1 command.


FC 07:
Commands are executed if a target's MP are currently at or below the value of the third byte. The second byte determines which target to check and is used the same as the value for the F1 command.


FC 08:
Commands are executed if target(s) have a certain status. The second byte determines which target to check and is used the same as the value for the F1 command. The third byte determines which status to look. See command FB command for a list of statuses. The target for the next attack is automatically set to a random target from the ones checked.


FC 09:
Commands are executed if target(s) do not have a certain status. The second byte determines which target to check and is used the same as the value for the F1 command. The third byte determines which status to look. See command FB command for a list of statuses. The target for the next attack is automatically set to a random target from the ones checked.


FC 0A:
The commands following FC are never executed.


FC 0B:
Commands are executed if the monster's battle timer is more than the value of the next byte.


FC 0C:
Commands are executed if the value of the variable specified in the second byte is less than the value specified in the third byte.


FC 0D:
Commands are executed if the value of the variable specified in the second byte is greater than or equal to the value specified in the third byte.


FC 0E:
Commands are executed if the a target's level is less than the value in the third byte. The target is determined as the F1 command based on the second byte. If multiple targets are selected, the level of a random one is checked.


FC 0F:
Commands are executed if the a target's level is greater than or equal to the value in the third byte. The target is determined as the F1 command based on the second byte. If multiple targets are selected, the level of a random one is checked.


FC 10:
Commands are executed if only one type of monster is alive


FC 11:
Commands are executed if certain monsters are alive. The second byte determines which monsters to check, with each bit for each monster.


FC 12:
Commands are executed if certain monsters are dead. The second byte determines which monsters to check, with each bit for each monster. If the second byte equals 0, then the monster checks its own status.


FC 13:
Commands are executed if a certain number of monsters are characters are alive. If the second byte is 0, the number of characters are checked, otherwise the number of monsters are checked. The third byte specifies the number of characters/monsters must be alive exactly.


FC 14:
Commands are executed if a certain bit of a certain variable is set. The second byte determines which variable to check. The third byte determines which bit to test.


FC 15:
Commands are executed if a certain bit of a certain variable is not set. The second byte determines which variable to check. The third byte determines which bit to test.


FC 16:
Commands are executed if the global battle timer is larger than the value in the second byte.


FC 17:
Sets the target of the next attack, using the second byte to determine targets, just like the F1 command. Commands are executed if the target set is valid.


FC 18:
Commands are executed if Gau has not joined the party.


FC 19:
Commands are executed the monster is a certain number in the formation. The second byte determine which monster number in the formation it must be.


FC 1A:
Commands are executed if a target is weak vs. an element. The second byte determines which target to check, using the same method as the F1 command. The second byte determines which element to check for weakness against. See FC 04 for a list of elements.


FC 1B:
Commands are executed if the battle formation is equal to the value in the next two bytes.


FC 1C:
Always executes the commands, even if Quick is in effect.