From faccee88e7b916729363cbb79f0b996ea14536fe Mon Sep 17 00:00:00 2001 From: nasgroup94 Date: Wed, 22 Oct 2025 05:19:50 -0400 Subject: [PATCH 1/5] added missing end to TIG "_OK_" subtraction --- Moose Development/Moose/Ops/Airboss.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Moose Development/Moose/Ops/Airboss.lua b/Moose Development/Moose/Ops/Airboss.lua index f73fd7e24..604243a4c 100644 --- a/Moose Development/Moose/Ops/Airboss.lua +++ b/Moose Development/Moose/Ops/Airboss.lua @@ -12713,7 +12713,7 @@ function AIRBOSS:_LSOgrade( playerData ) local nS=count(G, '%(') local nN=N-nS-nL - if TIG=="_OK_" then nL = nL -1 --Circuit added to prevent grade deduction for perfect groove + if TIG=="_OK_" then nL = nL -1 end --Circuit added to prevent grade deduction for perfect groove -- Groove time 15-18.99 sec for a unicorn. Or 60-65 for V/STOL unicorn. local Tgroove=playerData.Tgroove From 7d4e1036602f291330260e47f9c99f3efcfcae81 Mon Sep 17 00:00:00 2001 From: Applevangelist Date: Sat, 25 Oct 2025 16:56:16 +0200 Subject: [PATCH 2/5] #UTILS - SpawnFarp helper, build multiple pads as a single static group, not separate objects. --- Moose Development/Moose/Utilities/Utils.lua | 54 +++++++++++++++++++-- 1 file changed, 51 insertions(+), 3 deletions(-) diff --git a/Moose Development/Moose/Utilities/Utils.lua b/Moose Development/Moose/Utilities/Utils.lua index 9d52ee972..bd4f4390d 100644 --- a/Moose Development/Moose/Utilities/Utils.lua +++ b/Moose Development/Moose/Utilities/Utils.lua @@ -4255,9 +4255,33 @@ function UTILS.SpawnFARPAndFunctionalStatics(Name,Coordinate,FARPType,Coalition, local FarpVec2 = Coordinate:GetVec2() if NumberPads > 1 then - local Grid = UTILS.GenerateGridPoints(FarpVec2, NumberPads, SpacingX, SpacingY) + local Grid = UTILS.GenerateGridPoints(FarpVec2, NumberPads, SpacingX, SpacingY) + local groupData = { + ["visible"] = true, + ["hidden"] = false, + ["units"] = {}, + ["y"] = 0, -- Group center latitude + ["x"] = 0, -- Group center longitude + ["name"] = Name, + } + local unitData = { + ["category"] = "Heliports", + ["type"] = STypeName, -- FARP type + ["y"] = 0, -- Latitude coordinate (meters) + ["x"] = 0, -- Longitude coordinate (meters) + ["name"] = Name, + ["heading"] = 0, -- Heading in radians + ["heliport_modulation"] = mod, -- 0 = AM, 1 = FM + ["heliport_frequency"] = freq, -- Radio frequency in MHz + ["heliport_callsign_id"] = callsign, -- Callsign ID + ["dead"] = false, + ["shape_name"] = SShapeName, + ["dynamicSpawn"] = DynamicSpawns, + ["allowHotStart"] = HotStart, + } for id,gridpoint in ipairs(Grid) do -- Spawn FARP + --[[ local location = COORDINATE:NewFromVec2(gridpoint) local newfarp = SPAWNSTATIC:NewFromType(STypeName,"Heliports",Country) -- "Invisible FARP" "FARP" newfarp:InitShape(SShapeName) -- "invisiblefarp" "FARPS" @@ -4265,8 +4289,32 @@ function UTILS.SpawnFARPAndFunctionalStatics(Name,Coordinate,FARPType,Coalition, local spawnedfarp = newfarp:SpawnFromCoordinate(location,0,Name.."-"..id) table.insert(ReturnObjects,spawnedfarp) - PopulateStorage(Name.."-"..id,liquids,equip,airframes) - end + PopulateStorage(Name.."-"..id,liquids,equip,airframes) + --]] + local UnitTemplate = UTILS.DeepCopy(unitData) + UnitTemplate.x = gridpoint.x + UnitTemplate.y = gridpoint.y + UnitTemplate.name = Name.."-"..id + table.insert(groupData.units,UnitTemplate) + if id==1 then + groupData.x = gridpoint.x + groupData.y = gridpoint.y + end + end + --BASE:I("Spawning FARP") + --UTILS.PrintTableToLog(groupData,1) + local Static=coalition.addGroup(Country, -1, groupData) + -- Currently DCS >= 2.8 does not trigger birth events if FARPS are spawned! + -- We create such an event. The airbase is registered in Core.Event + local Event = { + id = EVENTS.Birth, + time = timer.getTime(), + initiator = Static + } + -- Create BIRTH event. + world.onEvent(Event) + + PopulateStorage(Name.."-1",liquids,equip,airframes) else -- Spawn FARP local newfarp = SPAWNSTATIC:NewFromType(STypeName,"Heliports",Country) -- "Invisible FARP" "FARP" From 2c5d9f043e808fc4c1036aab07f2549df2e2802d Mon Sep 17 00:00:00 2001 From: nasgroup94 Date: Sat, 25 Oct 2025 12:42:09 -0400 Subject: [PATCH 3/5] fixed TIG bug causing NG Removed old into wind function --- Moose Development/Moose/Ops/Airboss.lua | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Moose Development/Moose/Ops/Airboss.lua b/Moose Development/Moose/Ops/Airboss.lua index c4daaa574..0bdeadb80 100644 --- a/Moose Development/Moose/Ops/Airboss.lua +++ b/Moose Development/Moose/Ops/Airboss.lua @@ -12229,8 +12229,8 @@ function AIRBOSS:GetHeadingIntoWind_new( vdeck, magnetic, coord ) local magvar= magnetic and self.magvar or 0 -- Ship heading so cross wind is min for the given wind. - -- local intowind = (540 + (windto - magvar + math.deg(theta) )) % 360 -- VNAO Edit: Using old heading into wind algorithm - local intowind = self:GetHeadingIntoWind_old(vdeck,magnetic) -- VNAO Edit: Using old heading into wind algorithm + local intowind = (540 + (windto - magvar + math.deg(theta) )) % 360 + return intowind, v end @@ -12713,7 +12713,6 @@ function AIRBOSS:_LSOgrade( playerData ) else if vtol then - -- Add AV-8B Harrier devation allowances due to lower groundspeed and 3x conventional groove time, this allows to maintain LSO tolerances while respecting the deviations are not unsafe.--Pene testing -- Large devaitions still result in a No Grade, A Unicorn still requires a clean pass with no deviation. From 8392788cdb43295355f30deab0ad201d60edf061 Mon Sep 17 00:00:00 2001 From: Applevangelist Date: Sun, 26 Oct 2025 16:19:05 +0100 Subject: [PATCH 4/5] Minor fixes --- Moose Development/Moose/Core/Point.lua | 1 + Moose Development/Moose/Functional/Scoring.lua | 4 ++-- Moose Development/Moose/Utilities/Utils.lua | 12 +----------- 3 files changed, 4 insertions(+), 13 deletions(-) diff --git a/Moose Development/Moose/Core/Point.lua b/Moose Development/Moose/Core/Point.lua index b17e40f27..fcf67ca02 100644 --- a/Moose Development/Moose/Core/Point.lua +++ b/Moose Development/Moose/Core/Point.lua @@ -1637,6 +1637,7 @@ do -- COORDINATE if AirbaseCategory == Airbase.Category.SHIP or AirbaseCategory == Airbase.Category.HELIPAD then RoutePoint.linkUnit = AirbaseID RoutePoint.helipadId = AirbaseID + RoutePoint.airdromeId = airbase:IsAirdrome() and AirbaseID or nil elseif AirbaseCategory == Airbase.Category.AIRDROME then RoutePoint.airdromeId = AirbaseID else diff --git a/Moose Development/Moose/Functional/Scoring.lua b/Moose Development/Moose/Functional/Scoring.lua index 2c49243f8..d9427d279 100644 --- a/Moose Development/Moose/Functional/Scoring.lua +++ b/Moose Development/Moose/Functional/Scoring.lua @@ -320,8 +320,8 @@ function SCORING:New( GameName, SavePath, AutoSave ) -- Create the CSV file. self.AutoSavePath = SavePath - self.AutoSave = AutoSave or true - if self.AutoSave == true then + self.AutoSave = (AutoSave == nil or AutoSave == true) and true or false + if self.AutoSavePath and self.AutoSave == true then self:OpenCSV( GameName ) end diff --git a/Moose Development/Moose/Utilities/Utils.lua b/Moose Development/Moose/Utilities/Utils.lua index bd4f4390d..fa4ba7233 100644 --- a/Moose Development/Moose/Utilities/Utils.lua +++ b/Moose Development/Moose/Utilities/Utils.lua @@ -4281,20 +4281,10 @@ function UTILS.SpawnFARPAndFunctionalStatics(Name,Coordinate,FARPType,Coalition, } for id,gridpoint in ipairs(Grid) do -- Spawn FARP - --[[ - local location = COORDINATE:NewFromVec2(gridpoint) - local newfarp = SPAWNSTATIC:NewFromType(STypeName,"Heliports",Country) -- "Invisible FARP" "FARP" - newfarp:InitShape(SShapeName) -- "invisiblefarp" "FARPS" - newfarp:InitFARP(callsign,freq,mod,DynamicSpawns,HotStart) - local spawnedfarp = newfarp:SpawnFromCoordinate(location,0,Name.."-"..id) - table.insert(ReturnObjects,spawnedfarp) - - PopulateStorage(Name.."-"..id,liquids,equip,airframes) - --]] local UnitTemplate = UTILS.DeepCopy(unitData) UnitTemplate.x = gridpoint.x UnitTemplate.y = gridpoint.y - UnitTemplate.name = Name.."-"..id + if id > 1 then UnitTemplate.name = Name.."-"..id end table.insert(groupData.units,UnitTemplate) if id==1 then groupData.x = gridpoint.x From 479dfc28b9ea6b41a982c490557b45fe0cf68e66 Mon Sep 17 00:00:00 2001 From: Thomas <72444570+Applevangelist@users.noreply.github.com> Date: Wed, 29 Oct 2025 07:01:33 +0100 Subject: [PATCH 5/5] Update Positionable.lua --- Moose Development/Moose/Wrapper/Positionable.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/Moose Development/Moose/Wrapper/Positionable.lua b/Moose Development/Moose/Wrapper/Positionable.lua index 038eefe56..7be7ed135 100644 --- a/Moose Development/Moose/Wrapper/Positionable.lua +++ b/Moose Development/Moose/Wrapper/Positionable.lua @@ -1865,6 +1865,7 @@ do -- Cargo ["HL_DSHK"] = 6*POSITIONABLE.DefaultInfantryWeight, ["CCKW_353"] = 16*POSITIONABLE.DefaultInfantryWeight, --GMC CCKW 2½-ton 6×6 truck, estimating 16 soldiers, ["MaxxPro_MRAP"] = 7*POSITIONABLE.DefaultInfantryWeight, + ["Sd_Kfz_251"] = 10*POSITIONABLE.DefaultInfantryWeight, } }