mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Merge remote-tracking branch 'origin/master' into branch
This commit is contained in:
commit
cad66e8241
@ -1317,6 +1317,10 @@ AIRBOSS.AircraftCarrier={
|
|||||||
-- @field #string FORRESTAL USS Forrestal (CV-59) [Heatblur Carrier Module]
|
-- @field #string FORRESTAL USS Forrestal (CV-59) [Heatblur Carrier Module]
|
||||||
-- @field #string VINSON USS Carl Vinson (CVN-70) [Deprecated!]
|
-- @field #string VINSON USS Carl Vinson (CVN-70) [Deprecated!]
|
||||||
-- @field #string ESSEX Essex class carrier (e.g. USS Yorktown (CV-10)) [Magnitude 3 Carrier Module]
|
-- @field #string ESSEX Essex class carrier (e.g. USS Yorktown (CV-10)) [Magnitude 3 Carrier Module]
|
||||||
|
-- @field #string BONHOMMERICHARD USS Bon Homme Richard carrier [VWV Mod]
|
||||||
|
-- @field #string ESSEXSCB125 Generic Essex class carrier with angled deck (SCB-125 upgrade) [VWV Mod]
|
||||||
|
-- @field #string ENTERPRISE66 USS Enterprise in the 1966 configuration [VWV Mod]
|
||||||
|
-- @field #string ENTERPRISEMODERN USS Enterprise in a modern configuration [Derived VWV Mod]
|
||||||
-- @field #string HERMES HMS Hermes (R12) [V/STOL Carrier]
|
-- @field #string HERMES HMS Hermes (R12) [V/STOL Carrier]
|
||||||
-- @field #string INVINCIBLE HMS Invincible (R05) [V/STOL Carrier]
|
-- @field #string INVINCIBLE HMS Invincible (R05) [V/STOL Carrier]
|
||||||
-- @field #string TARAWA USS Tarawa (LHA-1) [V/STOL Carrier]
|
-- @field #string TARAWA USS Tarawa (LHA-1) [V/STOL Carrier]
|
||||||
@ -1331,8 +1335,12 @@ AIRBOSS.CarrierType = {
|
|||||||
TRUMAN = "CVN_75",
|
TRUMAN = "CVN_75",
|
||||||
STENNIS = "Stennis",
|
STENNIS = "Stennis",
|
||||||
FORRESTAL = "Forrestal",
|
FORRESTAL = "Forrestal",
|
||||||
|
ENTERPRISE66 = "USS Enterprise 1966",
|
||||||
|
ENTERPRISEMODERN = "cvn-65",
|
||||||
VINSON = "VINSON",
|
VINSON = "VINSON",
|
||||||
ESSEX = "Essex",
|
ESSEX = "Essex",
|
||||||
|
BONHOMMERICHARD = "USS Bon Homme Richard",
|
||||||
|
ESSEXSCB125 = "essex_scb125",
|
||||||
HERMES = "HERMES81",
|
HERMES = "HERMES81",
|
||||||
INVINCIBLE = "hms_invincible",
|
INVINCIBLE = "hms_invincible",
|
||||||
TARAWA = "LHA_Tarawa",
|
TARAWA = "LHA_Tarawa",
|
||||||
@ -2019,11 +2027,19 @@ function AIRBOSS:New( carriername, alias )
|
|||||||
self:_InitNimitz()
|
self:_InitNimitz()
|
||||||
elseif self.carriertype == AIRBOSS.CarrierType.FORRESTAL then
|
elseif self.carriertype == AIRBOSS.CarrierType.FORRESTAL then
|
||||||
self:_InitForrestal()
|
self:_InitForrestal()
|
||||||
|
elseif self.carriertype == AIRBOSS.CarrierType.ENTERPRISE66 then
|
||||||
|
self:_InitEnterprise()
|
||||||
|
elseif self.carriertype == AIRBOSS.CarrierType.ENTERPRISEMODERN then
|
||||||
|
self:_InitEnterprise()
|
||||||
elseif self.carriertype == AIRBOSS.CarrierType.VINSON then
|
elseif self.carriertype == AIRBOSS.CarrierType.VINSON then
|
||||||
-- Carl Vinson is legacy now.
|
-- Carl Vinson is legacy now.
|
||||||
self:_InitStennis()
|
self:_InitStennis()
|
||||||
elseif self.carriertype == AIRBOSS.CarrierType.ESSEX then
|
elseif self.carriertype == AIRBOSS.CarrierType.ESSEX then
|
||||||
self:_InitEssex()
|
self:_InitEssex()
|
||||||
|
elseif self.carriertype == AIRBOSS.CarrierType.BONHOMMERICHARD then
|
||||||
|
self:_InitBonHommeRichard()
|
||||||
|
elseif self.carriertype == AIRBOSS.CarrierType.ESSEXSCB125 then
|
||||||
|
self:_InitEssexSCB125()
|
||||||
elseif self.carriertype == AIRBOSS.CarrierType.HERMES then
|
elseif self.carriertype == AIRBOSS.CarrierType.HERMES then
|
||||||
-- Hermes parameters.
|
-- Hermes parameters.
|
||||||
self:_InitHermes()
|
self:_InitHermes()
|
||||||
@ -4653,6 +4669,26 @@ function AIRBOSS:_InitForrestal()
|
|||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
--- Init parameters for Enterprise carrier.
|
||||||
|
-- @param #AIRBOSS self
|
||||||
|
function AIRBOSS:_InitEnterprise()
|
||||||
|
-- Using Forrestal as template
|
||||||
|
self:_InitForrestal()
|
||||||
|
|
||||||
|
self.carrierparam.sterndist = -164.30
|
||||||
|
self.carrierparam.deckheight = 19.52
|
||||||
|
|
||||||
|
self.carrierparam.totlength = 335
|
||||||
|
self.carrierparam.rwylength = 223
|
||||||
|
|
||||||
|
-- Wires.
|
||||||
|
self.carrierparam.wire1 = 57.7
|
||||||
|
self.carrierparam.wire2 = 69.6
|
||||||
|
self.carrierparam.wire3 = 79.5
|
||||||
|
self.carrierparam.wire4 = 90.0
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
--- Init parameters for Essec class carriers.
|
--- Init parameters for Essec class carriers.
|
||||||
-- @param #AIRBOSS self
|
-- @param #AIRBOSS self
|
||||||
function AIRBOSS:_InitEssex()
|
function AIRBOSS:_InitEssex()
|
||||||
@ -4698,6 +4734,35 @@ function AIRBOSS:_InitEssex()
|
|||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
--- Init parameters for CVA-31 Bon Homme Richard carriers.
|
||||||
|
-- @param #AIRBOSS self
|
||||||
|
function AIRBOSS:_InitBonHommeRichard()
|
||||||
|
-- Init Essex as default
|
||||||
|
self:_InitEssex()
|
||||||
|
|
||||||
|
self.carrierparam.deckheight = 16.95
|
||||||
|
|
||||||
|
-- Landing runway.
|
||||||
|
-- from BHR EssexRunwayAndRoutes.lua
|
||||||
|
self.carrierparam.rwyangle = -11.4
|
||||||
|
self.carrierparam.rwylength = 97
|
||||||
|
self.carrierparam.rwywidth = 20
|
||||||
|
|
||||||
|
-- Wires.
|
||||||
|
self.carrierparam.wire1 = 40.4 -- Distance from stern to first wire. Original from Frank - 42
|
||||||
|
self.carrierparam.wire2 = 45
|
||||||
|
self.carrierparam.wire3 = 51
|
||||||
|
self.carrierparam.wire4 = 58.1
|
||||||
|
end
|
||||||
|
|
||||||
|
--- Init parameters for Generic Essex SC125 class carriers.
|
||||||
|
-- @param #AIRBOSS self
|
||||||
|
function AIRBOSS:_InitEssexSCB125()
|
||||||
|
-- Init Bon Homme Richard as default
|
||||||
|
self:_InitBonHommeRichard()
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
--- Init parameters for R12 HMS Hermes carrier.
|
--- Init parameters for R12 HMS Hermes carrier.
|
||||||
-- @param #AIRBOSS self
|
-- @param #AIRBOSS self
|
||||||
function AIRBOSS:_InitHermes()
|
function AIRBOSS:_InitHermes()
|
||||||
|
|||||||
@ -2231,6 +2231,10 @@ function GROUP:Respawn( Template, Reset )
|
|||||||
|
|
||||||
--UTILS.PrintTableToLog(Template)
|
--UTILS.PrintTableToLog(Template)
|
||||||
|
|
||||||
|
if self.ValidateAndRepositionGroundUnits then
|
||||||
|
UTILS.ValidateAndRepositionGroundUnits(Template.units)
|
||||||
|
end
|
||||||
|
|
||||||
-- Spawn new group.
|
-- Spawn new group.
|
||||||
self:ScheduleOnce(0.1,_DATABASE.Spawn,_DATABASE,Template)
|
self:ScheduleOnce(0.1,_DATABASE.Spawn,_DATABASE,Template)
|
||||||
--_DATABASE:Spawn(Template)
|
--_DATABASE:Spawn(Template)
|
||||||
@ -3192,3 +3196,13 @@ function GROUP:IsAAA()
|
|||||||
end
|
end
|
||||||
return isAAA
|
return isAAA
|
||||||
end
|
end
|
||||||
|
|
||||||
|
--- This function uses Disposition and other fallback logic to find better ground positions for ground units.
|
||||||
|
--- NOTE: This is not a spawn randomizer.
|
||||||
|
--- It will try to find clear ground locations avoiding trees, water, roads, runways, map scenery, statics and other units in the area and modifies the provided positions table.
|
||||||
|
--- Maintains the original layout and unit positions as close as possible by searching for the next closest valid position to each unit.
|
||||||
|
--- Uses UTILS.ValidateAndRepositionGroundUnits.
|
||||||
|
-- @param #boolean Enabled Enable/disable the feature.
|
||||||
|
function GROUP:SetValidateAndRepositionGroundUnits(Enabled)
|
||||||
|
self.ValidateAndRepositionGroundUnits = Enabled
|
||||||
|
end
|
||||||
|
|||||||
@ -377,6 +377,10 @@ function UNIT:ReSpawnAt(Coordinate, Heading)
|
|||||||
|
|
||||||
--self:T( SpawnGroupTemplate )
|
--self:T( SpawnGroupTemplate )
|
||||||
|
|
||||||
|
if self.ValidateAndRepositionGroundUnits then
|
||||||
|
UTILS.ValidateAndRepositionGroundUnits(SpawnGroupTemplate.units)
|
||||||
|
end
|
||||||
|
|
||||||
_DATABASE:Spawn(SpawnGroupTemplate)
|
_DATABASE:Spawn(SpawnGroupTemplate)
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -1938,3 +1942,13 @@ end
|
|||||||
function UNIT:SetCarrierIlluminationMode(Mode)
|
function UNIT:SetCarrierIlluminationMode(Mode)
|
||||||
UTILS.SetCarrierIlluminationMode(self:GetID(), Mode)
|
UTILS.SetCarrierIlluminationMode(self:GetID(), Mode)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
--- This function uses Disposition and other fallback logic to find better ground positions for ground units.
|
||||||
|
--- NOTE: This is not a spawn randomizer.
|
||||||
|
--- It will try to find clear ground locations avoiding trees, water, roads, runways, map scenery, statics and other units in the area and modifies the provided positions table.
|
||||||
|
--- Maintains the original layout and unit positions as close as possible by searching for the next closest valid position to each unit.
|
||||||
|
--- Uses UTILS.ValidateAndRepositionGroundUnits.
|
||||||
|
-- @param #boolean Enabled Enable/disable the feature.
|
||||||
|
function UNIT:SetValidateAndRepositionGroundUnits(Enabled)
|
||||||
|
self.ValidateAndRepositionGroundUnits = Enabled
|
||||||
|
end
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user