mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Update Auftrag.lua
This commit is contained in:
parent
c3ffffbb52
commit
a9b51cca93
@ -5579,7 +5579,13 @@ function AUFTRAG:GetMissionWaypointCoord(group, randomradius, surfacetypes)
|
|||||||
end
|
end
|
||||||
|
|
||||||
-- Create waypoint coordinate half way between us and the target.
|
-- Create waypoint coordinate half way between us and the target.
|
||||||
local waypointcoord=group:GetCoordinate():GetIntermediateCoordinate(self:GetTargetCoordinate(), self.missionFraction)
|
local waypointcoord=COORDINATE:New(0,0,0)
|
||||||
|
local coord=group:GetCoordinate()
|
||||||
|
if coord then
|
||||||
|
waypointcoord=coord:GetIntermediateCoordinate(self:GetTargetCoordinate(), self.missionFraction)
|
||||||
|
else
|
||||||
|
self:E(self.lid..string.format("ERROR: Cannot get coordinate of group %s (alive=%s)!", tostring(group:GetName()), tostring(group:IsAlive())))
|
||||||
|
end
|
||||||
local alt=waypointcoord.y
|
local alt=waypointcoord.y
|
||||||
|
|
||||||
-- Add some randomization.
|
-- Add some randomization.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user