missions.create_flight_plans can make CMO show the player a modal "cannot launch" dialog #28
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Live run of 2026-10-14 (
docs/verification/library/library-writes-2026-10-14.json, flightplans phase). The strike mission was inactive, with StrikeFlightSize and StrikeMinAircraftReq at 1, and two F-24As of one base and loadout assigned.missions.create_flight_plans(the tester's Lua callsmission:createFlightPlans({})) made CMO show a modal dialog in the operator's game: "Mission CMOnet LIB Flight Plan, aircraft type F-24A Hellcat II ... with loadout A/A: AIM-174B Gunslinger, Internal Long-Range based on Miami AB cannot launch! Reason: No contacts can be engaged by the available weapons 370 USG Drop Tank (not suitable)." No flight formed, and the read-back correctly refused the write.So
createFlightPlanschecks launchability itself, active mission or not. Refusing active missions (operator 2026-10-13) is not enough: the General can still interrupt the player through this tool by assigning aircraft whose loadout can't hit the mission's targets.The harness is fixed (
fabc229): it pairs only aircraft whose loadout has a weapon withLandRangeMax/SurfaceRangeMax> 0 for the target's domain (DataLoadoutWeapons -> DataWeaponRecord -> DataWeapon).Proposal for the product: before sending
missions.create_flight_plans, refuse unless every assigned aircraft's loadout can reach at least one of the mission's targets' domains, by the uploaded CMO database (library/cmo_db.py); without an uploaded database, refuse and say to upload it. Two places it could live:execution/runtime_port.py_library_preflight): it reads the mission's aircraft and targets fresh, then checks them against the catalog.Until then, the General should only call it when its own planning picked land- or ship-attack loadouts.