* Fixes for AI_A2A_GCICAP, tracing the setup information.

* Fixed Spawning in air bug, Takeoff event generation parameters mismatch solved.
This commit is contained in:
FlightControl_Master
2017-10-18 09:03:13 +02:00
parent c27197500c
commit d3b5c77e5c
3 changed files with 16 additions and 6 deletions

View File

@@ -744,13 +744,15 @@ function EVENT:onEvent( Event )
local EventMeta = _EVENTMETA[Event.id]
--self:E( { EventMeta.Text, Event } ) -- Activate the see all incoming events ...
if self and
self.Events and
self.Events[Event.id] and
( Event.initiator ~= nil or ( Event.initiator == nil and Event.id ~= EVENTS.PlayerLeaveUnit ) ) then
if Event.initiator then
Event.IniObjectCategory = Event.initiator:getCategory()
if Event.IniObjectCategory == Object.Category.UNIT then

View File

@@ -1191,7 +1191,7 @@ function SPAWN:SpawnAtAirbase( SpawnAirbase, Takeoff, TakeoffAltitude ) -- R2.2
if Takeoff == GROUP.Takeoff.Air then
for UnitID, UnitSpawned in pairs( GroupSpawned:GetUnits() ) do
SCHEDULER:New( nil, BASE.CreateEventTakeoff, { GroupSpawned, timer.getTime(), UnitSpawned:GetDCSObject() } , 1 )
SCHEDULER:New( nil, BASE.CreateEventTakeoff, { timer.getTime(), UnitSpawned:GetDCSObject() } , 1 )
end
end