mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
AB 0.9.8w
This commit is contained in:
@@ -150,6 +150,7 @@
|
||||
-- @field #number parkingscanradius Radius in meters until which parking spots are scanned for obstacles like other units, statics or scenery.
|
||||
-- @field #boolean parkingscanscenery If true, area around parking spots is scanned for scenery objects. Default is false.
|
||||
-- @field #boolean parkingverysafe If true, parking spots are considered as non-free until a possible aircraft has left and taken off. Default false.
|
||||
-- @field #boolean despawnair If true, aircraft are despawned when they reach their destination zone. Default.
|
||||
-- @extends Core.Spawn#SPAWN
|
||||
|
||||
--- Implements an easy to use way to randomly fill your map with AI aircraft.
|
||||
@@ -428,6 +429,7 @@ RAT={
|
||||
parkingscanradius=40, -- Scan radius.
|
||||
parkingscanscenery=false, -- Scan parking spots for scenery obstacles.
|
||||
parkingverysafe=false, -- Very safe option.
|
||||
despawnair=true,
|
||||
}
|
||||
|
||||
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
@@ -546,7 +548,7 @@ RAT.id="RAT | "
|
||||
--- RAT version.
|
||||
-- @list version
|
||||
RAT.version={
|
||||
version = "2.3.5",
|
||||
version = "2.3.6",
|
||||
print = true,
|
||||
}
|
||||
|
||||
@@ -1098,6 +1100,14 @@ function RAT:SetParkingSpotSafeOFF()
|
||||
return self
|
||||
end
|
||||
|
||||
--- Aircraft that reach their destination zone are not despawned. They will probably go the the nearest airbase and try to land.
|
||||
-- @param #RAT self
|
||||
-- @return #RAT RAT self object.
|
||||
function RAT:SetDespawnAirOFF()
|
||||
self.despawnair=false
|
||||
return self
|
||||
end
|
||||
|
||||
--- Set takeoff type. Starting cold at airport, starting hot at airport, starting at runway, starting in the air.
|
||||
-- Default is "takeoff-coldorhot". So there is a 50% chance that the aircraft starts with cold engines and 50% that it starts with hot engines.
|
||||
-- @param #RAT self
|
||||
@@ -3604,13 +3614,18 @@ function RAT:Status(message, forID)
|
||||
|
||||
local text=string.format("Flight %s will be despawned NOW!", self.alias)
|
||||
self:T(RAT.id..text)
|
||||
-- Despawn old group.
|
||||
|
||||
-- Respawn group
|
||||
if (not self.norespawn) and (not self.respawn_after_takeoff) then
|
||||
local idx=self:GetSpawnIndexFromGroup(group)
|
||||
local coord=group:GetCoordinate()
|
||||
self:_Respawn(idx, coord, 0)
|
||||
end
|
||||
self:_Despawn(group, 0)
|
||||
|
||||
-- Despawn old group.
|
||||
if self.despawnair then
|
||||
self:_Despawn(group, 0)
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user