Merged 'develop'.

# Conflicts:
#	Moose Development/Moose/Core/Cargo.lua
This commit is contained in:
FlightControl_Master
2018-03-28 13:49:57 +02:00
7 changed files with 647 additions and 269 deletions

View File

@@ -1908,6 +1908,28 @@ function CONTROLLABLE:Route( Route, DelaySeconds )
end
--- Stops the movement of the vehicle on the route.
-- @param #CONTROLLABLE self
-- @return #CONTROLLABLE
function CONTROLLABLE:RouteStop()
self:F2()
local CommandStop = self:CommandStopRoute( true )
self:SetCommand( CommandStop )
end
--- Resumes the movement of the vehicle on the route.
-- @param #CONTROLLABLE self
-- @return #CONTROLLABLE
function CONTROLLABLE:RouteResume()
self:F2()
local CommandResume = self:CommandStopRoute( false )
self:SetCommand( CommandResume )
end
--- Make the GROUND Controllable to drive towards a specific point.
-- @param #CONTROLLABLE self
-- @param Core.Point#COORDINATE ToCoordinate A Coordinate to drive to.

View File

@@ -224,6 +224,7 @@ function UNIT:ReSpawn( SpawnVec3, Heading )
for UnitTemplateID, UnitTemplateData in pairs( SpawnGroupTemplate.units ) do
self:T( { UnitTemplateData.name, self:Name() } )
SpawnGroupTemplate.units[UnitTemplateID].unitId = nil
if UnitTemplateData.name == self:Name() then
self:T("Adjusting")
SpawnGroupTemplate.units[UnitTemplateID].alt = SpawnVec3.y
@@ -264,6 +265,8 @@ function UNIT:ReSpawn( SpawnVec3, Heading )
end
end
SpawnGroupTemplate.groupId = nil
self:T( SpawnGroupTemplate )
_DATABASE:Spawn( SpawnGroupTemplate )
@@ -383,7 +386,7 @@ function UNIT:GetGroup()
local DCSUnit = self:GetDCSObject()
if DCSUnit then
local UnitGroup = GROUP:Find( DCSUnit:getGroup() )
local UnitGroup = GROUP:FindByName( DCSUnit:getGroup():getName() )
return UnitGroup
end