More work on miss on purpose

This commit is contained in:
Pax1601
2023-10-02 21:52:04 +02:00
parent 5035c408e7
commit 4da407008e
2 changed files with 44 additions and 19 deletions

View File

@@ -229,6 +229,14 @@ function Olympus.buildTask(groupName, options)
-- Fire at a specific point
elseif options['id'] == 'FireAtPoint' and options['lat'] and options['lng'] and options['radius'] then
local point = coord.LLtoLO(options['lat'], options['lng'], 0)
local expendQtyEnabled = false
local expendQty = 0
if options['expendQty'] then
expendQtyEnabled = true
expendQty = options['expendQty']
end
if options['alt'] then
task = {
id = 'FireAtPoint',
@@ -236,7 +244,9 @@ function Olympus.buildTask(groupName, options)
point = {x = point.x, y = point.z},
radius = options['radius'],
altitude = options['alt'],
alt_type = 0 -- ASL
alt_type = 0, -- ASL
expendQtyEnabled = expendQtyEnabled,
expendQty = expendQty
}
}
else
@@ -244,7 +254,9 @@ function Olympus.buildTask(groupName, options)
id = 'FireAtPoint',
params = {
point = {x = point.x, y = point.z},
radius = options['radius']
radius = options['radius'],
expendQtyEnabled = expendQtyEnabled,
expendQty = expendQty
}
}
end