Fix/cas mission2 (#44)
* changed from only units to also statics in targets for CAS * added statics and update docs * optimised hull creation and did not group by group * added cas_mission.png --------- Co-authored-by: dutchie032 <dutchie032> Co-authored-by: ex61wi <tim.rorije@ing.com>
This commit is contained in:
committed by
GitHub
co-authored by
dutchie032 <dutchie032>
ex61wi
parent
74e7d1ca7a
commit
90c8d113fd
@@ -156,7 +156,6 @@ function SpearheadGroup:GetObjects()
|
||||
return result
|
||||
end
|
||||
|
||||
|
||||
---comment
|
||||
---@return Array<Unit> result list of objects
|
||||
function SpearheadGroup:GetAsUnits()
|
||||
@@ -195,15 +194,21 @@ end
|
||||
|
||||
function SpearheadGroup:SetInvisible()
|
||||
|
||||
local group = Group.getByName(self.groupName)
|
||||
if group then
|
||||
local setInvisible = {
|
||||
id = 'SetInvisible',
|
||||
params = {
|
||||
value = true
|
||||
if self._isStatic == true then
|
||||
local country = Spearhead.DcsUtil.GetNeutralCountry()
|
||||
Spearhead.DcsUtil.SpawnGroupTemplate(self.groupName, nil, nil, nil, country)
|
||||
else
|
||||
local group = Group.getByName(self.groupName)
|
||||
if group then
|
||||
local setInvisible = {
|
||||
id = 'SetInvisible',
|
||||
params = {
|
||||
value = true
|
||||
}
|
||||
}
|
||||
}
|
||||
group:getController():setCommand(setInvisible)
|
||||
group:getController():setCommand(setInvisible)
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user