mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Set the new spawn altitude
This commit is contained in:
@@ -989,9 +989,10 @@ end
|
||||
-- @param #SPAWN self
|
||||
-- @param Wrapper.Airbase#AIRBASE Airbase The @{Airbase} where to spawn the group.
|
||||
-- @param #SPAWN.Takeoff Takeoff (optional) The location and takeoff method. Default is Hot.
|
||||
-- @param #number TakeoffAltitude (optional) The altitude above the ground.
|
||||
-- @return Wrapper.Group#GROUP that was spawned.
|
||||
-- @return #nil Nothing was spawned.
|
||||
function SPAWN:SpawnAtAirbase( Airbase, Takeoff ) -- R2.2
|
||||
function SPAWN:SpawnAtAirbase( Airbase, Takeoff, TakeoffAltitude ) -- R2.2
|
||||
self:F( { self.SpawnTemplatePrefix, Airbase } )
|
||||
|
||||
local PointVec3 = Airbase:GetPointVec3()
|
||||
@@ -1025,7 +1026,7 @@ function SPAWN:SpawnAtAirbase( Airbase, Takeoff ) -- R2.2
|
||||
|
||||
SpawnTemplate.route.points[1].x = PointVec3.x
|
||||
SpawnTemplate.route.points[1].y = PointVec3.z
|
||||
SpawnTemplate.route.points[1].alt = PointVec3.y + 200
|
||||
SpawnTemplate.route.points[1].alt = PointVec3.y + TakeoffAltitude
|
||||
SpawnTemplate.route.points[1].type = GROUPTEMPLATE.Takeoff[Takeoff]
|
||||
SpawnTemplate.route.points[1].airdromeId = Airbase:GetID()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user