Skip to main content

Match Flow

From the menus to the battle​

  1. The menus (or the Match Tester, or the online lobby) build an FAFTMatchConfig: match type, mode, both teams (fighters, palettes, controller, CPU level and CPU profile, local player slot), stage, rules, net mode and network settings, seed, skip intro.
  2. UAFTMatchSubsystem::LaunchMatch opens the stage level (UAFTStageData.Level, or AFT Game > Default Battle Map).
  3. AAFTBattleGameMode resolves the config, in this order: a Match Tester with Override Menus -> the config prepared by the menus -> the Match Tester of the map -> AFT Game > Quick Battle Fighters. Then it starts the battle and shows the HUD.
  4. UAFTBattleSubsystem (world subsystem) compiles the assets into the simulation database, creates the session (offline or rollback), spawns the fighter actors, the camera and the presentation, and steps the simulation at 60 frames per second.
  5. At the end, the result (FAFTMatchResult: winner, rounds, duration, disconnected, desynced) is reported to the match subsystem and the result screen offers rematch, character select or main menu (in arcade: next fight after a win, continue after a loss).

Phases​

PhaseDescriptionLength
IntroFighter intros (Level Sequences), skippable when both players press a button.Intro sequence length, or rules IntroFramesPerSide per side
RoundIntro"Round 1... Fight!"Rules RoundIntroFrames (100)
FightThe round. The timer counts down (RoundTimeSeconds, 0 = infinite).
RoundEndKO or time over. During the first half of the KO the simulation runs one frame out of three (deterministic slow motion).Rules RoundEndFrames (150)
RoundResultWin pose before the next round.Rules RoundResultFrames (150)
MatchEndVictory (Level Sequence of the winner, or win pose), then the result screen.Victory sequence length, or rules VictoryFrames (180)

The picked intro / victory sequence and its length are part of the rollback state: every peer sees the same intro for the same time, and a skip is synced. See Intro and Victory Cinematics.

Listen to the phases in Blueprint with UAFTBattleSubsystem::OnPhaseChanged, and to the end of the match with OnMatchEnded. AAFTBattleGameMode also exposes the Blueprint events On Match Started and On Match Finished.

Pause​

TogglePauseMenu (Start button) pauses offline matches (SetPaused, CanPause). Online, the pause menu opens but the match keeps running.

Simulation frame order​

Every frame, FAFTBattleSimulation::Step runs: inputs -> match flow -> fighters (state graph, commands, actions, frame events) -> projectiles -> physics (push boxes, walls, corner) -> hits (hit / guard / throw / clash, armor, counter hit, proration, combo decay) -> tag team (tag, assists, red health, partner entry on KO) -> round end -> camera.

Hits, cues, projectiles and round / match events are emitted as events with a stable key and played once by the presentation, even when a rollback simulates the frame again.