| At the start of a battle, each combatant's base timer duration is 50 times a reference party member's modified agility over 10 times its own modified agility, at least 1; the reference is the first present party member whose character ID is 1 or $0B, or failing that the first present one, so a combatant with twice the agility waits half as long between turns. | battle/init.asm L493–503battle/init.asm L518–550notes/ff4j-sfc-ram-map.txt L722 | Code |
BattleMain waits 1, 2, 4, 6, 8, or 11 frames by the battle speed setting (BattleSpeedTbl plus one), holding while the game is paused or in wait mode, then decrements every combatant's timers (DecTimers) and runs a pending action. An action timer's duration is the base duration times a speed modifier over 16, and 16 is the normal modifier. | battle/battle.asm L1021–1033battle/battle.asm L1067–1085battle/battle.asm L1476–1504battle/battle_data.asm L367–369battle/timer_dur.asm L282–298battle/init.asm L898–902 | Code |
| A Fight command makes one percentage roll per point of the attacker's attack multiplier and counts the rolls under its hit rate; the target rolls once per point of its defense multiplier and blocks one hit for each roll under its defense rate. The hits left after blocking multiply one damage roll, and none left is a miss. | battle/damage.asm L16–27battle/fight.asm L114–120battle/fight.asm L147–203 | Code |
| A character's attack multiplier, the number of hit rolls, is strength ÷ 8 + agility ÷ 16 + 1; the defense multiplier is agility ÷ 8 plus level ÷ 16 times the shield's multiplier. | battle/equip.asm L240–252battle/equip.asm L546–555 | Code |
CalcDmg takes attack power plus a random 0 to half of it, applies the elemental and creature-type multipliers, adds the crit bonus on a critical, and subtracts defense (floored at 0); that times the net hits, divided by the number of targets, is held to 1–9,999. A Fight command has one target. | battle/damage.asm L33–99battle/fight.asm L341–342 | Code |
A Fight command rolls once for a critical: a percentage roll under the attacker's crit rate adds its crit bonus to the damage before defense. Each character carries a crit rate and bonus of their own (the field code loads Cecil's from CharProp); dual-wielding doubles the rate, which falls to 99 only when the doubling overflows a byte (a rate of 50–127 doubles to 100–254), and adds half the left hand's attack to the bonus, and a bow triples a rate capped at 33 and adds the arrows' attack. | battle/fight.asm L311–318battle/fight.asm L343–345battle/equip.asm L684–734field/field.asm L2335–2351 | Code |
| A physical attack's element is tested against the target's very weak, weak, immune, and strong elements in that order, and the first match sets a damage multiplier of 4×, 2×, 0, or ½. | battle/fight.asm L222–247 | Code |
| Holding L and R escapes, with no roll, once the run counter reaches 0, if the battle allows running and some party member can act. The counter starts at $FF (no escape) and a character's turn sets it to 0, except against a monster of level 97, 98, or 99, where it starts at 3, 7, or 10 and drops by one each battle tick while L and R are held; at level 99 it resets to 15 whenever they are let go. | battle/battle.asm L1694–1730battle/battle.asm L1073battle/battle.asm L385–392battle/battle_data.asm L379–394battle/battle.asm L1060–1066battle/char.asm L344–361battle/battle.asm L409–447 | Code |
| On the overworld, each step reads a rate from an 8 × 8 grid of map regions (7, 8, or 10) and starts a battle when a byte from a fixed random table, plus an offset that grows by $11 each time the step counter wraps, is below it. | field/rand_battle.asm L19–27field/rand_battle.asm L93–129 | Code |
| Final Fantasy IV keeps Final Fantasy III's physical attack: percentage rolls per point of an attack multiplier, the target's successful evade rolls subtracted, and one damage roll of attack plus 0 to half of it, with the crit bonus added before defense, multiplied by the net hits and capped at 9,999. | battle/damage.asm L16–27battle/damage.asm L33–99 | Code |
| Final Fantasy III's physical attack has two elemental outcomes besides normal, double for a weakness and half for the target's other element byte; Final Fantasy IV adds very weak (4×) and immune (0) to weak (2×) and strong (½). | battle/fight.asm L222–247 | Code |
| Final Fantasy IV and V both give each combatant a timer that counts down to its turn. Final Fantasy IV sets its length from a ratio, 50 times a reference party member's agility over 10 times the combatant's; Final Fantasy V sets it to 120 plus equipment weight ÷ 8 minus agility. | battle/init.asm L518–550battle/battle.asm L1476–1504 | Code |
| Final Fantasy IV counts a weapon attack's hits from a loop of percentage rolls, one per point of the attack multiplier, less the target's evade rolls; Final Fantasy V's physical check makes one hit roll and one evade roll, and the attack either lands or misses. | battle/damage.asm L16–27 | Code |