This commit is contained in:
Applevangelist 2024-08-17 11:37:26 +02:00
parent 1aca716431
commit cf322c121e
2 changed files with 5 additions and 1 deletions

View File

@ -27,7 +27,7 @@
-- * @{#SET_CARGO}: Defines a collection of @{Cargo.Cargo}s filtered by filter criteria. -- * @{#SET_CARGO}: Defines a collection of @{Cargo.Cargo}s filtered by filter criteria.
-- * @{#SET_ZONE}: Defines a collection of @{Core.Zone}s filtered by filter criteria. -- * @{#SET_ZONE}: Defines a collection of @{Core.Zone}s filtered by filter criteria.
-- * @{#SET_SCENERY}: Defines a collection of @{Wrapper.Scenery}s added via a filtered @{#SET_ZONE}. -- * @{#SET_SCENERY}: Defines a collection of @{Wrapper.Scenery}s added via a filtered @{#SET_ZONE}.
-- * @{#SET_DYNAMICCARGO}: Defines a collection of @{Wrapper.DynamicCargo}s added via a filtered @{#SET_ZONE}. -- * @{#SET_DYNAMICCARGO}: Defines a collection of @{Wrapper.DynamicCargo}s filtered by filter criteria.
-- --
-- These classes are derived from @{#SET_BASE}, which contains the main methods to manage the collections. -- These classes are derived from @{#SET_BASE}, which contains the main methods to manage the collections.
-- --

View File

@ -801,6 +801,7 @@ do
-- my_ctld.enableChinookGCLoading = true -- will effectively suppress the crate load and drop menus for CTLD for the Chinook -- my_ctld.enableChinookGCLoading = true -- will effectively suppress the crate load and drop menus for CTLD for the Chinook
-- my_ctld.movecratesbeforebuild = false -- cannot detect movement of crates at the moment -- my_ctld.movecratesbeforebuild = false -- cannot detect movement of crates at the moment
-- my_ctld.nobuildinloadzones = true -- don't build where you load. -- my_ctld.nobuildinloadzones = true -- don't build where you load.
-- my_ctld.ChinookTroopCircleRadius = 5 -- Radius for troops dropping in a nice circle. Adjust to your planned squad size for the Chinook.
-- --
-- ## 2.2 User functions -- ## 2.2 User functions
-- --
@ -1206,6 +1207,7 @@ CTLD = {
dropOffZones = {}, dropOffZones = {},
pickupZones = {}, pickupZones = {},
DynamicCargo = {}, DynamicCargo = {},
ChinookTroopCircleRadius = 5,
} }
------------------------------ ------------------------------
@ -3434,6 +3436,8 @@ function CTLD:_UnloadTroops(Group, Unit)
randomcoord:Translate(offset,Angle,nil,true) randomcoord:Translate(offset,Angle,nil,true)
end end
local tempcount = 0 local tempcount = 0
local ishook = self:IsHook(Unit)
if ishook then tempcount = self.ChinookTroopCircleRadius or 5 end -- 10m circle for the Chinook
for _,_template in pairs(temptable) do for _,_template in pairs(temptable) do
self.TroopCounter = self.TroopCounter + 1 self.TroopCounter = self.TroopCounter + 1
tempcount = tempcount+1 tempcount = tempcount+1