mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Fixes
-- when carrier containing cargo goes to spectators, it was not handled correctly. now it is -- removed "unassigned" message when task is cancelled from group. It is useless.
This commit is contained in:
@@ -1092,7 +1092,7 @@ function CARGO_GROUP:New( CargoGroup, Type, Name, ReportRadius )
|
|||||||
return self
|
return self
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param #CARGO Cargo
|
--- @param #CARGO_GROUP self
|
||||||
-- @param Core.Event#EVENTDATA EventData
|
-- @param Core.Event#EVENTDATA EventData
|
||||||
function CARGO_GROUP:OnEventCargoDead( EventData )
|
function CARGO_GROUP:OnEventCargoDead( EventData )
|
||||||
|
|
||||||
@@ -1109,7 +1109,9 @@ function CARGO_GROUP:OnEventCargoDead( EventData )
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
if self.CargoCarrier:GetName() == EventData.IniUnitName then
|
local CarrierName = self.CargoCarrier:GetName()
|
||||||
|
if CarrierName == EventData.IniDCSUnitName then
|
||||||
|
MESSAGE:New( "Cargo is lost from carrier " .. CarrierName, 15 ):ToAll()
|
||||||
Destroyed = true
|
Destroyed = true
|
||||||
self.CargoCarrier:ClearCargo()
|
self.CargoCarrier:ClearCargo()
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -479,9 +479,9 @@ do -- Group Assignment
|
|||||||
SetAssignedGroups:ForEachGroup(
|
SetAssignedGroups:ForEachGroup(
|
||||||
function( AssignedGroup )
|
function( AssignedGroup )
|
||||||
if self:IsGroupAssigned(AssignedGroup) then
|
if self:IsGroupAssigned(AssignedGroup) then
|
||||||
self:GetMission():GetCommandCenter():MessageToGroup( string.format( "Task %s is unassigned from group %s.", TaskName, TaskGroupName ), AssignedGroup )
|
--self:GetMission():GetCommandCenter():MessageToGroup( string.format( "Task %s is unassigned from group %s.", TaskName, TaskGroupName ), AssignedGroup )
|
||||||
else
|
else
|
||||||
self:GetMission():GetCommandCenter():MessageToGroup( string.format( "Task %s is unassigned from your group.", TaskName ), AssignedGroup )
|
--self:GetMission():GetCommandCenter():MessageToGroup( string.format( "Task %s is unassigned from your group.", TaskName ), AssignedGroup )
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user