Page 1 of 1
Lua and the Operations Planner and Flight Plans
Posted: Tue Jul 11, 2023 10:41 am
by thewood1
Are there lua functions associated with the ops planner or the flight plan editor? I didn't see any in the github docs but didn't remember if any were listed in the release notes. I couldn't find anything or see any discussion on it.
Re: Lua and the Operations Planner and Flight Plans
Posted: Tue Jul 11, 2023 11:22 am
by blu3s
AFAIK the lua that was introduced it was in relation to the new terrain mask type and zones. In tiny release notes I found nothing related to the Operations Planner.
Re: Lua and the Operations Planner and Flight Plans
Posted: Sun Aug 13, 2023 2:40 am
by thewood1
Does anyone know if there is a plan to have lua support for ops planner or flight plans?
Re: Lua and the Operations Planner and Flight Plans
Posted: Sun Aug 13, 2023 12:18 pm
by michaelm75au
It is on my list. Just need to figure out what exactly is needed.
There are already some Lua properties present in game which have yet to be documented.
Re: Lua and the Operations Planner and Flight Plans
Posted: Thu Aug 17, 2023 10:55 am
by thewood1
One of the key things is manipulating the phase. Being able to force a mission from satisfied back to another phase is something I would like to do. The other one is being able to adjust priorities.
Re: Lua and the Operations Planner and Flight Plans
Posted: Wed Jul 24, 2024 1:50 am
by thewood1
Is there any news on this topic?
Re: Lua and the Operations Planner and Flight Plans
Posted: Wed Jul 24, 2024 7:26 am
by blu3s
Next update will have the possibility to edit some elements of the flight planner via lua
Re: Lua and the Operations Planner and Flight Plans
Posted: Wed Aug 21, 2024 4:14 pm
by thewood1
Is there an update on this?
Re: Lua and the Operations Planner and Flight Plans
Posted: Sun Sep 01, 2024 9:58 am
by blu3s
There's no official documentation yet since it's a work in progress but let me share some code here to illustrate how to access the flight plan of a mission:
Code: Select all
local mission = ScenEdit_GetMission('BLUE','STRIKE')
--List of flights
local flights = mission.flightlist
print(flights)
--1st Flight Course Table
local flight_1 = mission.flightlist[1]
print(flight_1.course)
You can change some of the WPs fields (latitude, longitude...) but I have not tested it in depth.
Time on target/station was also added to the mission wrapper, atm it only works for strike missions since for patrol you need to chek also the "Use Flightplans" settings.
I have submitted a ticket to link the introducion of a ToS to a Patrol/Support mission to automatically checks the "Use Flightplans", when this is implemented ToS through lua will work for all the missions.

Re: Lua and the Operations Planner and Flight Plans
Posted: Mon Oct 14, 2024 5:17 pm
by thewood1
Thanks. Just getting back to this and will play around with it.