RunwayClear
Check if runway is clear
Usage: Used in 6 task(s)
Lua Implementation
-- Runway Clear
function evaluate(params)
local runway = params.runway_location
-- Check for obstacles on runway
local contacts = this:getContactList()
for _, contact in ipairs(contacts) do
if contact:isValid() then
local distance = spatialUtil.distance(runway, contact:getLocation3D())
if distance < 100 then -- Within 100m of runway
return false
end
end
end
return true
end
Tasks Using This Predicate (6)
Offensive Counter-Air (OCA) Missions
Air Superiority (AIR DOMAIN)
Airfield Air Defense Suppression
Suppression/Destruction of Enemy Air Defense (SEAD/DEAD) (AIR DOMAIN)
Runway Cratering
Airfield Attack (AIR DOMAIN)
Fuel/Ammunition Storage Targeting
Airfield Attack (AIR DOMAIN)
Air Traffic Control Destruction
Airfield Attack (AIR DOMAIN)
Airfield Defense Suppression
Airfield Attack (AIR DOMAIN)