Compare commits

..

4 Commits

Author SHA1 Message Date
FlightControl
dd242bc1fe Finish 2.4.10 2018-11-09 07:44:37 +01:00
FlightControl
34d73af8bf Changed the default lase duration for designations to 120 seconds. A new method has been added to change the lase duration yourself. Use SetLaseDuratioin API! 2018-11-09 07:44:11 +01:00
FlightControl
604255bfba Finish 2.4.9 2018-11-09 06:46:23 +01:00
FlightControl
cfc0367c55 Fixing problems with A2A_GCI. 2018-11-09 06:45:34 +01:00
2 changed files with 14 additions and 4 deletions

View File

@@ -1024,13 +1024,15 @@ do -- AI_A2A_DISPATCHER
--- @param #AI_A2A_DISPATCHER self --- @param #AI_A2A_DISPATCHER self
function AI_A2A_DISPATCHER:onafterStart( From, Event, To ) function AI_A2A_DISPATCHER:onafterStart( From, Event, To )
self:GetParent( self ).onafterStart( self, From, Event, To ) self:GetParent( self, AI_A2A_DISPATCHER ).onafterStart( self, From, Event, To )
-- Spawn the resources. -- Spawn the resources.
for SquadronName, DefenderSquadron in pairs( self.DefenderSquadrons ) do for SquadronName, DefenderSquadron in pairs( self.DefenderSquadrons ) do
DefenderSquadron.Resource = {} DefenderSquadron.Resource = {}
for Resource = 1, DefenderSquadron.ResourceCount do if DefenderSquadron.ResourceCount then
self:ParkDefender( DefenderSquadron ) for Resource = 1, DefenderSquadron.ResourceCount do
self:ParkDefender( DefenderSquadron )
end
end end
end end
end end

View File

@@ -474,7 +474,7 @@ do -- DESIGNATE
self.Designating = {} self.Designating = {}
self:SetDesignateName() self:SetDesignateName()
self.LaseDuration = 60 self:SetLaseDuration() -- Default is 120 seconds.
self:SetFlashStatusMenu( false ) self:SetFlashStatusMenu( false )
self:SetFlashDetectionMessages( true ) self:SetFlashDetectionMessages( true )
@@ -677,6 +677,14 @@ do -- DESIGNATE
return self return self
end end
--- Set the lase duration for designations.
-- @param #DESIGNATE self
-- @param #number LaseDuration The time in seconds a lase will continue to hold on target. The default is 120 seconds.
-- @return #DESIGNATE
function DESIGNATE:SetLaseDuration( LaseDuration )
self.LaseDuration = LaseDuration or 120
return self
end
--- Generate an array of possible laser codes. --- Generate an array of possible laser codes.
-- Each new lase will select a code from this table. -- Each new lase will select a code from this table.