mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
#Airboss
This commit is contained in:
parent
379dd44c04
commit
d9c656f6d2
@ -2543,7 +2543,7 @@ function AIRBOSS:AddRecoveryWindow( starttime, stoptime, case, holdingoffset, tu
|
|||||||
return self
|
return self
|
||||||
end
|
end
|
||||||
if Tstop <= Tnow then
|
if Tstop <= Tnow then
|
||||||
self:I( string.format( "WARNING: Recovery stop time %s already over. Tnow=%s! Recovery window rejected.", UTILS.SecondsToClock( Tstop ), UTILS.SecondsToClock( Tnow ) ) )
|
string.format( "WARNING: Recovery stop time %s already over. Tnow=%s! Recovery window rejected.", UTILS.SecondsToClock( Tstop ), UTILS.SecondsToClock( Tnow ) )
|
||||||
return self
|
return self
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -3258,7 +3258,7 @@ function AIRBOSS:SoundCheckLSO( delay )
|
|||||||
end
|
end
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -3293,7 +3293,7 @@ function AIRBOSS:SoundCheckMarshal( delay )
|
|||||||
end
|
end
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -3684,7 +3684,7 @@ function AIRBOSS:onafterStatus( From, Event, To )
|
|||||||
if i == 0 then
|
if i == 0 then
|
||||||
text = text .. " none"
|
text = text .. " none"
|
||||||
end
|
end
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
-- Check for collision.
|
-- Check for collision.
|
||||||
if collision then
|
if collision then
|
||||||
@ -6960,7 +6960,7 @@ function AIRBOSS:_GetFreeStack( ai, case, empty )
|
|||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
self:I( self.lid .. string.format( "Returning free stack %s", tostring( nfree ) ) )
|
self:T( self.lid .. string.format( "Returning free stack %s", tostring( nfree ) ) )
|
||||||
return nfree
|
return nfree
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -7894,7 +7894,7 @@ function AIRBOSS:_RemoveFlight( flight, completely )
|
|||||||
-- Remove player from players table.
|
-- Remove player from players table.
|
||||||
local playerdata = self.players[flight.name]
|
local playerdata = self.players[flight.name]
|
||||||
if playerdata then
|
if playerdata then
|
||||||
self:I( self.lid .. string.format( "Removing player %s completely.", flight.name ) )
|
self:T( self.lid .. string.format( "Removing player %s completely.", flight.name ) )
|
||||||
self.players[flight.name] = nil
|
self.players[flight.name] = nil
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -11592,11 +11592,11 @@ function AIRBOSS:GetHeadingIntoWind( magnetic, coord )
|
|||||||
-- Get direction the wind is blowing from. This is where we want to go.
|
-- Get direction the wind is blowing from. This is where we want to go.
|
||||||
local windfrom, vwind = self:GetWind( nil, nil, coord )
|
local windfrom, vwind = self:GetWind( nil, nil, coord )
|
||||||
|
|
||||||
--self:I("windfrom="..windfrom.." vwind="..vwind)
|
--self:T("windfrom="..windfrom.." vwind="..vwind)
|
||||||
|
|
||||||
vwind = vwind + adjustDegreesForWindSpeed(vwind)
|
vwind = vwind + adjustDegreesForWindSpeed(vwind)
|
||||||
|
|
||||||
--self:I("windfrom="..windfrom.." (c)vwind="..vwind)
|
--self:T("windfrom="..windfrom.." (c)vwind="..vwind)
|
||||||
|
|
||||||
-- Actually, we want the runway in the wind.
|
-- Actually, we want the runway in the wind.
|
||||||
local intowind = windfrom - self.carrierparam.rwyangle
|
local intowind = windfrom - self.carrierparam.rwyangle
|
||||||
@ -14793,6 +14793,7 @@ function AIRBOSS:RadioTransmission( radio, call, loud, delay, interval, click, p
|
|||||||
|
|
||||||
else
|
else
|
||||||
-- SRS transmission
|
-- SRS transmission
|
||||||
|
if call.subtitle ~= nil and string.len(call.subtitle) > 1 then
|
||||||
|
|
||||||
local frequency = self.MarshalRadio.frequency
|
local frequency = self.MarshalRadio.frequency
|
||||||
local modulation = self.MarshalRadio.modulation
|
local modulation = self.MarshalRadio.modulation
|
||||||
@ -14849,6 +14850,7 @@ function AIRBOSS:RadioTransmission( radio, call, loud, delay, interval, click, p
|
|||||||
self.SRSQ:NewTransmission(srstext, call.duration, self.SRS, nil, 0.1, nil, call.subtitle, call.subduration, frequency, modulation, gender, culture, voice, volume, radio.alias)
|
self.SRSQ:NewTransmission(srstext, call.duration, self.SRS, nil, 0.1, nil, call.subtitle, call.subduration, frequency, modulation, gender, culture, voice, volume, radio.alias)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
--- Set SRS voice for the pilot calls.
|
--- Set SRS voice for the pilot calls.
|
||||||
-- @param #AIRBOSS self
|
-- @param #AIRBOSS self
|
||||||
@ -15158,7 +15160,7 @@ end
|
|||||||
-- @param #boolean clear If true, clear screen from previous messages.
|
-- @param #boolean clear If true, clear screen from previous messages.
|
||||||
-- @param #number delay Delay in seconds, before the message is displayed.
|
-- @param #number delay Delay in seconds, before the message is displayed.
|
||||||
function AIRBOSS:MessageToPlayer( playerData, message, sender, receiver, duration, clear, delay )
|
function AIRBOSS:MessageToPlayer( playerData, message, sender, receiver, duration, clear, delay )
|
||||||
self:I({sender,receiver,message})
|
self:T({sender,receiver,message})
|
||||||
if playerData and message and message ~= "" then
|
if playerData and message and message ~= "" then
|
||||||
|
|
||||||
-- Default duration.
|
-- Default duration.
|
||||||
@ -15634,7 +15636,7 @@ function AIRBOSS:_LSOCallAircraftBall( modex, nickname, fuelstate )
|
|||||||
local text = string.format( "%s Ball, %.1f.", nickname, fuelstate )
|
local text = string.format( "%s Ball, %.1f.", nickname, fuelstate )
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
-- Nickname UPPERCASE.
|
-- Nickname UPPERCASE.
|
||||||
local NICKNAME = nickname:upper()
|
local NICKNAME = nickname:upper()
|
||||||
@ -15670,7 +15672,7 @@ function AIRBOSS:_MarshalCallGasAtTanker( modex )
|
|||||||
local text = string.format( "Bingo fuel! Going for gas at the recovery tanker." )
|
local text = string.format( "Bingo fuel! Going for gas at the recovery tanker." )
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
|
|
||||||
-- Create new call to display complete subtitle.
|
-- Create new call to display complete subtitle.
|
||||||
@ -15694,7 +15696,7 @@ function AIRBOSS:_MarshalCallGasAtDivert( modex, divertname )
|
|||||||
local text = string.format( "Bingo fuel! Going for gas at divert field %s.", divertname )
|
local text = string.format( "Bingo fuel! Going for gas at divert field %s.", divertname )
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
-- Create new call to display complete subtitle.
|
-- Create new call to display complete subtitle.
|
||||||
local call = self:_NewRadioCall( self.PilotCall.BINGOFUEL, modex, text, self.Tmessage, nil, modex )
|
local call = self:_NewRadioCall( self.PilotCall.BINGOFUEL, modex, text, self.Tmessage, nil, modex )
|
||||||
@ -15716,7 +15718,7 @@ function AIRBOSS:_MarshalCallRecoveryStopped( case )
|
|||||||
local text = string.format( "Case %d recovery ops are stopped. Deck is closed.", case )
|
local text = string.format( "Case %d recovery ops are stopped. Deck is closed.", case )
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
-- Create new call to display complete subtitle.
|
-- Create new call to display complete subtitle.
|
||||||
local call = self:_NewRadioCall( self.MarshalCall.CASE, "AIRBOSS", text, self.Tmessage, "99" )
|
local call = self:_NewRadioCall( self.MarshalCall.CASE, "AIRBOSS", text, self.Tmessage, "99" )
|
||||||
@ -15757,7 +15759,7 @@ function AIRBOSS:_MarshalCallRecoveryPausedResumedAt( clock )
|
|||||||
local text = string.format( "aircraft recovery is paused and will be resumed at %s.", clock )
|
local text = string.format( "aircraft recovery is paused and will be resumed at %s.", clock )
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
-- Create new call with full subtitle.
|
-- Create new call with full subtitle.
|
||||||
local call = self:_NewRadioCall( self.MarshalCall.RECOVERYPAUSEDRESUMED, "AIRBOSS", text, self.Tmessage, "99" )
|
local call = self:_NewRadioCall( self.MarshalCall.RECOVERYPAUSEDRESUMED, "AIRBOSS", text, self.Tmessage, "99" )
|
||||||
@ -15784,7 +15786,7 @@ function AIRBOSS:_MarshalCallClearedForRecovery( modex, case )
|
|||||||
local text = string.format( "you're cleared for Case %d recovery.", case )
|
local text = string.format( "you're cleared for Case %d recovery.", case )
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
-- Create new call with full subtitle.
|
-- Create new call with full subtitle.
|
||||||
local call = self:_NewRadioCall( self.MarshalCall.CLEAREDFORRECOVERY, "MARSHAL", text, self.Tmessage, modex )
|
local call = self:_NewRadioCall( self.MarshalCall.CLEAREDFORRECOVERY, "MARSHAL", text, self.Tmessage, modex )
|
||||||
@ -15822,7 +15824,7 @@ function AIRBOSS:_MarshalCallNewFinalBearing( FB )
|
|||||||
local text = string.format( "new final bearing %03d°.", FB )
|
local text = string.format( "new final bearing %03d°.", FB )
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
-- Create new call with full subtitle.
|
-- Create new call with full subtitle.
|
||||||
local call = self:_NewRadioCall( self.MarshalCall.NEWFB, "AIRBOSS", text, self.Tmessage, "99" )
|
local call = self:_NewRadioCall( self.MarshalCall.NEWFB, "AIRBOSS", text, self.Tmessage, "99" )
|
||||||
@ -15845,7 +15847,7 @@ function AIRBOSS:_MarshalCallCarrierTurnTo( hdg )
|
|||||||
local text = string.format( "carrier is now starting turn to heading %03d°.", hdg )
|
local text = string.format( "carrier is now starting turn to heading %03d°.", hdg )
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
-- Create new call with full subtitle.
|
-- Create new call with full subtitle.
|
||||||
local call = self:_NewRadioCall( self.MarshalCall.CARRIERTURNTOHEADING, "AIRBOSS", text, self.Tmessage, "99" )
|
local call = self:_NewRadioCall( self.MarshalCall.CARRIERTURNTOHEADING, "AIRBOSS", text, self.Tmessage, "99" )
|
||||||
@ -15876,7 +15878,7 @@ function AIRBOSS:_MarshalCallStackFull( modex, nwaiting )
|
|||||||
end
|
end
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
-- Create new call with full subtitle.
|
-- Create new call with full subtitle.
|
||||||
local call = self:_NewRadioCall( self.MarshalCall.STACKFULL, "AIRBOSS", text, self.Tmessage, modex )
|
local call = self:_NewRadioCall( self.MarshalCall.STACKFULL, "AIRBOSS", text, self.Tmessage, modex )
|
||||||
@ -15947,7 +15949,7 @@ function AIRBOSS:_MarshalCallArrived( modex, case, brc, altitude, charlie, qfe )
|
|||||||
local text = string.format( "Case %d, expected BRC %03d°, hold at angels %d. Expected Charlie Time %s. Altimeter %.2f. Report see me.", case, brc, angels, charlie, qfe )
|
local text = string.format( "Case %d, expected BRC %03d°, hold at angels %d. Expected Charlie Time %s. Altimeter %.2f. Report see me.", case, brc, angels, charlie, qfe )
|
||||||
|
|
||||||
-- Debug message.
|
-- Debug message.
|
||||||
self:I( self.lid .. text )
|
self:T( self.lid .. text )
|
||||||
|
|
||||||
-- Create new call to display complete subtitle.
|
-- Create new call to display complete subtitle.
|
||||||
local casecall = self:_NewRadioCall( self.MarshalCall.CASE, "MARSHAL", text, self.Tmessage, modex )
|
local casecall = self:_NewRadioCall( self.MarshalCall.CASE, "MARSHAL", text, self.Tmessage, modex )
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user