mirror of
https://github.com/ciribob/DCS-CTLD.git
synced 2025-08-15 06:17:22 +00:00
Last fix commit !?
This commit is contained in:
7
CTLD.lua
7
CTLD.lua
@@ -4015,7 +4015,7 @@ function ctld.unpackCrates(_arguments)
|
|||||||
trigger.action.outTextForCoalition(_heli:getCoalition(),
|
trigger.action.outTextForCoalition(_heli:getCoalition(),
|
||||||
ctld.i18n_translate("%1 successfully deployed %2 to the field", ctld.getPlayerNameOrType(_heli),
|
ctld.i18n_translate("%1 successfully deployed %2 to the field", ctld.getPlayerNameOrType(_heli),
|
||||||
_crate.details.desc), 10)
|
_crate.details.desc), 10)
|
||||||
timer.scheduleFunction(ctld.autoUpdateRepackMenu, { reschedule = false }, timer.getTime() + 1)
|
timer.scheduleFunction(ctld.autoUpdateRepackMenu, { reschedule = false }, timer.getTime() + 1) -- for add unpacked unit in repack menu
|
||||||
if ctld.isJTACUnitType(_crate.details.unit) and ctld.JTAC_dropEnabled then
|
if ctld.isJTACUnitType(_crate.details.unit) and ctld.JTAC_dropEnabled then
|
||||||
local _code = table.remove(ctld.jtacGeneratedLaserCodes, 1)
|
local _code = table.remove(ctld.jtacGeneratedLaserCodes, 1)
|
||||||
--put to the end
|
--put to the end
|
||||||
@@ -4982,7 +4982,7 @@ function ctld.repairAASystem(_heli, _nearestCrate, _aaSystem)
|
|||||||
end
|
end
|
||||||
|
|
||||||
function ctld.unpackMultiCrate(_heli, _nearestCrate, _nearbyCrates)
|
function ctld.unpackMultiCrate(_heli, _nearestCrate, _nearbyCrates)
|
||||||
ctld.logTrace("FG_ ctld.unpackMultiCrate, _nearestCrate = %s", ctld.p(_nearestCrate))
|
--ctld.logTrace("FG_ ctld.unpackMultiCrate, _nearestCrate = %s", ctld.p(_nearestCrate))
|
||||||
-- unpack multi crate
|
-- unpack multi crate
|
||||||
local _nearbyMultiCrates = {}
|
local _nearbyMultiCrates = {}
|
||||||
|
|
||||||
@@ -5033,6 +5033,7 @@ function ctld.unpackMultiCrate(_heli, _nearestCrate, _nearbyCrates)
|
|||||||
if _spawnedGroup == nil then
|
if _spawnedGroup == nil then
|
||||||
ctld.logError("ctld.unpackMultiCrate group was not spawned - skipping setGrpROE")
|
ctld.logError("ctld.unpackMultiCrate group was not spawned - skipping setGrpROE")
|
||||||
else
|
else
|
||||||
|
timer.scheduleFunction(ctld.autoUpdateRepackMenu, { reschedule = false }, timer.getTime() + 1) -- for add unpacked unit in repack menu
|
||||||
ctld.setGrpROE(_spawnedGroup)
|
ctld.setGrpROE(_spawnedGroup)
|
||||||
ctld.processCallback({ unit = _heli, crate = _nearestCrate, spawnedGroup = _spawnedGroup, action = "unpack" })
|
ctld.processCallback({ unit = _heli, crate = _nearestCrate, spawnedGroup = _spawnedGroup, action = "unpack" })
|
||||||
trigger.action.outTextForCoalition(_heli:getCoalition(),
|
trigger.action.outTextForCoalition(_heli:getCoalition(),
|
||||||
@@ -7488,7 +7489,7 @@ function ctld.setGrpROE(_grp, _ROE)
|
|||||||
local _controller = _grp:getController();
|
local _controller = _grp:getController();
|
||||||
Controller.setOption(_controller, AI.Option.Ground.id.ALARM_STATE, AI.Option.Ground.val.ALARM_STATE.AUTO)
|
Controller.setOption(_controller, AI.Option.Ground.id.ALARM_STATE, AI.Option.Ground.val.ALARM_STATE.AUTO)
|
||||||
Controller.setOption(_controller, AI.Option.Ground.id.ROE, _ROE)
|
Controller.setOption(_controller, AI.Option.Ground.id.ROE, _ROE)
|
||||||
_controller:setTask(_grp)
|
--_controller:setTask(_grp)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user