mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Beacon - added deactivate Link4
This commit is contained in:
parent
ab50d0a514
commit
f19740e376
@ -265,7 +265,7 @@ function BEACON:ActivateLink4(Frequency, Morse, Duration)
|
|||||||
|
|
||||||
-- Stop sheduler
|
-- Stop sheduler
|
||||||
if Duration then -- Schedule the stop of the BEACON if asked by the MD
|
if Duration then -- Schedule the stop of the BEACON if asked by the MD
|
||||||
self.Positionable:DeactivateBeacon(Duration)
|
self.Positionable:CommandDeactivateLink4(Duration)
|
||||||
end
|
end
|
||||||
|
|
||||||
return self
|
return self
|
||||||
|
|||||||
@ -681,7 +681,7 @@ end
|
|||||||
--- Activate ICLS system of the CONTROLLABLE. The controllable should be an aircraft carrier!
|
--- Activate ICLS system of the CONTROLLABLE. The controllable should be an aircraft carrier!
|
||||||
-- @param #CONTROLLABLE self
|
-- @param #CONTROLLABLE self
|
||||||
-- @param #number Channel ICLS channel.
|
-- @param #number Channel ICLS channel.
|
||||||
-- @param #number UnitID The ID of the unit the ICLS system is attached to. Useful if more units are in one group.
|
-- @param #number UnitID The DCS UNIT ID of the unit the ICLS system is attached to. Useful if more units are in one group.
|
||||||
-- @param #string Callsign Morse code identification callsign.
|
-- @param #string Callsign Morse code identification callsign.
|
||||||
-- @param #number Delay (Optional) Delay in seconds before the ICLS is deactivated.
|
-- @param #number Delay (Optional) Delay in seconds before the ICLS is deactivated.
|
||||||
-- @return #CONTROLLABLE self
|
-- @return #CONTROLLABLE self
|
||||||
@ -710,9 +710,9 @@ end
|
|||||||
--- Activate LINK4 system of the CONTROLLABLE. The controllable should be an aircraft carrier!
|
--- Activate LINK4 system of the CONTROLLABLE. The controllable should be an aircraft carrier!
|
||||||
-- @param #CONTROLLABLE self
|
-- @param #CONTROLLABLE self
|
||||||
-- @param #number Frequency Link4 Frequency in MHz, e.g. 336
|
-- @param #number Frequency Link4 Frequency in MHz, e.g. 336
|
||||||
-- @param #number UnitID The ID of the unit the ICLS system is attached to. Useful if more units are in one group.
|
-- @param #number UnitID The DCS UNIT ID of the unit the LINK4 system is attached to. Useful if more units are in one group.
|
||||||
-- @param #string Callsign Morse code identification callsign.
|
-- @param #string Callsign Morse code identification callsign.
|
||||||
-- @param #number Delay (Optional) Delay in seconds before the ICLS is deactivated.
|
-- @param #number Delay (Optional) Delay in seconds before the LINK4 is deactivated.
|
||||||
-- @return #CONTROLLABLE self
|
-- @return #CONTROLLABLE self
|
||||||
function CONTROLLABLE:CommandActivateLink4(Frequency, UnitID, Callsign, Delay)
|
function CONTROLLABLE:CommandActivateLink4(Frequency, UnitID, Callsign, Delay)
|
||||||
|
|
||||||
@ -745,7 +745,7 @@ function CONTROLLABLE:CommandDeactivateBeacon(Delay)
|
|||||||
local CommandDeactivateBeacon={id='DeactivateBeacon', params={}}
|
local CommandDeactivateBeacon={id='DeactivateBeacon', params={}}
|
||||||
|
|
||||||
if Delay and Delay>0 then
|
if Delay and Delay>0 then
|
||||||
SCHEDULER:New(nil, self.CommandActivateBeacon, {self}, Delay)
|
SCHEDULER:New(nil, self.CommandDeactivateBeacon, {self}, Delay)
|
||||||
else
|
else
|
||||||
self:SetCommand(CommandDeactivateBeacon)
|
self:SetCommand(CommandDeactivateBeacon)
|
||||||
end
|
end
|
||||||
@ -753,6 +753,24 @@ function CONTROLLABLE:CommandDeactivateBeacon(Delay)
|
|||||||
return self
|
return self
|
||||||
end
|
end
|
||||||
|
|
||||||
|
--- Deactivate the active Link4 of the CONTROLLABLE.
|
||||||
|
-- @param #CONTROLLABLE self
|
||||||
|
-- @param #number Delay (Optional) Delay in seconds before the Link4 is deactivated.
|
||||||
|
-- @return #CONTROLLABLE self
|
||||||
|
function CONTROLLABLE:CommandDeactivateLink4(Delay)
|
||||||
|
|
||||||
|
-- Command to deactivate
|
||||||
|
local CommandDeactivateLink4={id='DeactivateLink4', params={}}
|
||||||
|
|
||||||
|
if Delay and Delay>0 then
|
||||||
|
SCHEDULER:New(nil, self.CommandDeactivateLink4, {self}, Delay)
|
||||||
|
else
|
||||||
|
self:SetCommand(CommandDeactivateLink4)
|
||||||
|
end
|
||||||
|
|
||||||
|
return self
|
||||||
|
end
|
||||||
|
|
||||||
--- Deactivate the ICLS of the CONTROLLABLE.
|
--- Deactivate the ICLS of the CONTROLLABLE.
|
||||||
-- @param #CONTROLLABLE self
|
-- @param #CONTROLLABLE self
|
||||||
-- @param #number Delay (Optional) Delay in seconds before the ICLS is deactivated.
|
-- @param #number Delay (Optional) Delay in seconds before the ICLS is deactivated.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user