fix(battle): enforce single-sortie Air Realistic rules
Carry the queued aircraft and crew index into LocalMP, apply the native single-spawn limits to players and aircraft bots, and disable spares for single-slot modes. Verified with root and launcher type checks, check-patches and check-gui for 2.61.0.37 and 2.61.0.43, and an isolated launch-payload check.
This commit is contained in:
1 parent
6c55c64222
commit
7ba66340b6
14 files changed
+122
-56
No files matched your search
@@ -40,6 +40,9 @@ export const MISSION_DIFFICULTY: Readonly<Record<ModeDifficulty, string>> = {
|
||||
simulator: 'hardcore',
|
||||
};
|
||||
|
||||
// globals/missions/respawnCountModes.nut: RESPAWN_COUNT_MODE.SINGLE_SPAWN.
|
||||
export const SINGLE_SPAWN = 1;
|
||||
|
||||
export type ModeDefinition = Readonly<Record<string, unknown>>;
|
||||
|
||||
export function buildModeDefinition(mode: GameModeDeclaration, missions: readonly MissionHeader[],
|
||||
@@ -79,6 +82,7 @@ export function buildModeDefinition(mode: GameModeDeclaration, missions: readonl
|
||||
teamB: structuredClone(team),
|
||||
mission_decl: {
|
||||
difficulty: MISSION_DIFFICULTY[mode.difficulty],
|
||||
...(mode.multiSlot === false ? { maxRespawns: SINGLE_SPAWN } : {}),
|
||||
missions_list: Object.fromEntries(missions.map((mission) => [mission.name, {}])),
|
||||
},
|
||||
};
|
||||
|
||||
Reference in new issue
Block a user