From 55cbd24588db4df2696340760fc7a049b436cc07 Mon Sep 17 00:00:00 2001 From: Grey-Echo Date: Mon, 20 Mar 2017 13:51:00 +0100 Subject: [PATCH] LDoc final pass and HTML doc generation --- Moose Development/Moose/Core/Radio.lua | 102 ++- .../Moose/Wrapper/Positionable.lua | 2 +- docs/Documentation/AI_Balancer.html | 1 + docs/Documentation/AI_Cap.html | 1 + docs/Documentation/AI_Cas.html | 1 + docs/Documentation/AI_Patrol.html | 4 +- docs/Documentation/Account.html | 1 + docs/Documentation/Airbase.html | 1 + docs/Documentation/AirbasePolice.html | 1 + docs/Documentation/Assign.html | 1 + docs/Documentation/Base.html | 1 + docs/Documentation/Cargo.html | 2 +- docs/Documentation/CleanUp.html | 1 + docs/Documentation/Client.html | 1 + docs/Documentation/CommandCenter.html | 1 + docs/Documentation/Controllable.html | 1 + docs/Documentation/Database.html | 1 + docs/Documentation/Detection.html | 1 + docs/Documentation/DetectionManager.html | 1 + docs/Documentation/Escort.html | 1 + docs/Documentation/Event.html | 1 + docs/Documentation/Fsm.html | 1 + docs/Documentation/Group.html | 1 + docs/Documentation/Identifiable.html | 1 + docs/Documentation/MOVEMENT.html | 1 + docs/Documentation/Menu.html | 1 + docs/Documentation/Message.html | 1 + docs/Documentation/MissileTrainer.html | 1 + docs/Documentation/Mission.html | 1 + docs/Documentation/Object.html | 1 + docs/Documentation/Point.html | 2 +- docs/Documentation/Positionable.html | 30 + docs/Documentation/Process_JTAC.html | 1 + docs/Documentation/Process_Pickup.html | 1 + docs/Documentation/Radio.html | 833 ++++++++++++++++++ docs/Documentation/Route.html | 1 + docs/Documentation/Scenery.html | 1 + docs/Documentation/ScheduleDispatcher.html | 1 + docs/Documentation/Scheduler.html | 1 + docs/Documentation/Scoring.html | 1 + docs/Documentation/Sead.html | 1 + docs/Documentation/Set.html | 1 + docs/Documentation/Smoke.html | 1 + docs/Documentation/Spawn.html | 26 +- docs/Documentation/Static.html | 1 + docs/Documentation/Task.html | 1 + docs/Documentation/Task_A2G.html | 1 + docs/Documentation/Task_PICKUP.html | 1 + docs/Documentation/Task_SEAD.html | 1 + docs/Documentation/Unit.html | 1 + docs/Documentation/Utils.html | 1 + docs/Documentation/Zone.html | 1 + docs/Documentation/index.html | 7 + docs/Documentation/routines.html | 1 + 54 files changed, 1023 insertions(+), 30 deletions(-) create mode 100644 docs/Documentation/Radio.html diff --git a/Moose Development/Moose/Core/Radio.lua b/Moose Development/Moose/Core/Radio.lua index a9068274f..f50898918 100644 --- a/Moose Development/Moose/Core/Radio.lua +++ b/Moose Development/Moose/Core/Radio.lua @@ -1,22 +1,82 @@ ---- This module contains the RADIO class. +--- This module contains the **Core - RADIO** class. The RADIO class is responsible for **transmitting radio communications**. -- -- 1) @{Radio#RADIO} class, extends @{Base#BASE} -- ================================================= --- Radio system to manage radio communications --- Radio transmissions consist of sound files that are broadcasted on a specific channel and modulation --- If sent by a UNIT or a GROUP, Radio communications can be subtitled for a specific amount of time +-- +-- 1.1) General radio transmssion setup +-- ------------------------------------ -- --- 1.1) RADIO construction methods --- ------------------------------- --- RADIO is created with @{Radio#RADIO.New}. This doesn't broadcast a transmission, but only create a RADIO object --- It should only be used internally. To create a RADIO object, please use @{Positionable#POSITIONABLE.GetRadio} --- To actually broadcast your transmission, you need to use @{Radio#RADIO.Broadcast} +-- What are radio communications in DCS ? +-- +-- * Radio transmissions consist of **sound files** that are broadcasted on a specific **frequency** (e.g. 115MHz) and **modulation** (e.g. AM), +-- * They can be **subtitled** for a specific **duration**, the **power** in Watts of the transmiter's antenna can be set, and the transmission can be **looped**. +-- +-- How to supply DCS my own Sound Files ? +-- +-- * Your sound files need to be encoded in **.ogg** or .wav, +-- * Your sound files should be **as tiny as possible**. It is suggested you encode in .ogg with low bitrate and sampling settings, +-- * They need to be added in .\l10n\DEFAULT\ in you .miz file (wich can be decompressed like a .zip file), +-- * For simplicty sake, you can **let DCS' Mission Editor add the file** itself, by creating a new Trigger with the action "Sound to Country", and choosing your sound file and a country you don't use in your mission. +-- +-- Due to weird DCS quirks, **radio communications behave differently** if sent by a @{Unit#UNIT} or a @{Group#GROUP} or by any other @{Positionable#POSITIONABLE} +-- +-- * If the transmitter is a @{Unit#UNIT} or a @{Group#GROUP}, DCS will set the power of the transmission automatically, +-- * If the transmitter is any other @{Positionable#POSITIONABLE}, the transmisison can't be subtitled or looped. +-- +-- Note that obviously, the **frequency** and the **modulation** of the transmission are important only if the players are piloting an **Advanced System Modelling** enabled aircraft, +-- like the A10C or the Mirage 2000C. They will **hear the transmission** if they are tuned on the **right frequency and modulation** (and if they are close enough - more on that below). +-- If a FC3 airacraft is used, it will **hear every communication, whatever the frequency and the modulation** is set to. +-- +-- 1.2) @{Radio#RADIO} usage +-- ------------------------- +-- +-- There are 3 steps to a successful radio transmission +-- +-- * First, you need to **"add" a @{#RADIO} object** to your @{Positionable#POSITIONABLE}. This is done using the @{Positionable#POSITIONABLE.GetRadio}() function, +-- * Then, you will **set the relevant parameters** to the transmission (see below), +-- * When done, you can actually **broadcast the transmission** (i.e. play the sound) with the @{Positionable#POSITIONABLE.Broadcast}() function. +-- +-- Methods to set relevant parameters for both a @{Unit#UNIT} or a @{Group#GROUP} or any other @{Positionable#POSITIONABLE} +-- +-- * @{#RADIO.SetFileName}() : Sets the file name of your sound file (e.g. "Noise.ogg"), +-- * @{#RADIO.SetFrequency}() : Sets the frequency of your transmission, +-- * @{#RADIO.SetModulation}() : Sets the modulation of your transmission. +-- +-- Additional Methods to set relevant parameters if the transmiter is a @{Unit#UNIT} or a @{Group#GROUP} +-- +-- * @{#RADIO.SetLoop}() : Choose if you want the transmission to be looped, +-- * @{#RADIO.SetSubtitle}() : Set both the subtitle and its duration, +-- * @{#RADIO.NewUnitTransmission}() : Shortcut to set all the relevant parameters in one method call +-- +-- Additional Methods to set relevant parameters if the transmiter is any other @{Wrapper.Positionable#POSITIONABLE} +-- +-- * @{#RADIO.SetPower}() : Sets the power of the antenna in Watts +-- * @{#RADIO.NewGenericTransmission}() : Shortcut to set all the relevant parameters in one method call +-- +-- What is this power thing ? +-- +-- * If your transmission is sent by a @{Positionable#POSITIONABLE} other than a @{Unit#UNIT} or a @{Group#GROUP}, you can set the power of the antenna, +-- * Otherwise, DCS sets it automatically, depending on what's available on your Unit, +-- * If the player gets **too far** from the transmiter, or if the antenna is **too weak**, the transmission will **fade** and **become noisyer**, +-- * This an automated DCS calculation you have no say on, +-- * For reference, a standard VOR station has a 100W antenna, a standard AA TACAN has a 120W antenna, and civilian ATC's antenna usually range between 300 and 500W, +-- * Note that if the transmission has a subtitle, it will be readable, regardless of the quality of the transmission. +-- +--### Authors: Hugues "Grey_Echo" Bousquet -- -- @module Radio -- @author Grey-Echo --- The RADIO class -- @type RADIO +-- @field Wrapper.Positionable#POSITIONABLE Positionable The transmiter +-- @field #string FileName Name of the sound file +-- @field #number Frequency Frequency of the transmission in Hz +-- @field #number Modulation Modulation of the transmission (either radio.modulation.AM or radio.modulation.FM) +-- @field #string Subtitle Subtitle of the transmission +-- @field #number SubtitleDuration Duration of the Subtitle in seconds +-- @field #number Power Power of the antenna is Watts +-- @field #boolean Loop -- @extends Core.Base#BASE RADIO = { ClassName = "RADIO", @@ -35,7 +95,7 @@ RADIO = { -- @return #RADIO Radio -- @return #nil If Positionable is invalid -- @usage --- -- If you want to create a RADIO, you probably should use @{Wrapper.Positionable#POSITIONABLE.GetRadio} instead +-- -- If you want to create a RADIO, you probably should use @{Positionable#POSITIONABLE.GetRadio}() instead function RADIO:New(positionable) local self = BASE:Inherit( self, BASE:New() ) self:F(positionable) @@ -50,9 +110,8 @@ end --- Check validity of the filename passed and sets RADIO.FileName -- @param #RADIO self --- @param #string fileName of the sound +-- @param #string fileName File name of the sound file (i.e. "Noise.ogg") -- @return #RADIO self --- @usage function RADIO:SetFileName(filename) self:F2(filename) if type(filename) == "string" then @@ -70,9 +129,8 @@ end --- Check validity of the frequency passed and sets RADIO.Frequency -- @param #RADIO self --- @param #number frequency in MHz +-- @param #number frequency in MHz (Ranges allowed for radio transmissions in DCS : 30-88 / 108-152 / 225-400MHz) -- @return #RADIO self --- @usage function RADIO:SetFrequency(frequency) self:F2(frequency) if type(frequency) == "number" then @@ -98,9 +156,8 @@ end --- Check validity of the frequency passed and sets RADIO.Modulation -- @param #RADIO self --- @param #number modulation +-- @param #number modulation either radio.modulation.AM or radio.modulation.FM -- @return #RADIO self --- @usage function RADIO:SetModulation(modulation) self:F2(modulation) if type(modulation) == "number" then @@ -115,9 +172,8 @@ end --- Check validity of the power passed and sets RADIO.Power -- @param #RADIO self --- @param #number Power +-- @param #number Power in W -- @return #RADIO self --- @usage function RADIO:SetPower(power) self:F2(power) if type(power) == "number" then @@ -130,7 +186,7 @@ end --- Check validity of the loop passed and sets RADIO.Loop -- @param #RADIO self --- @param #bool Loop +-- @param #boolean Loop -- @return #RADIO self -- @usage function RADIO:SetLoop(loop) @@ -172,7 +228,7 @@ end -- @param #RADIO self -- @param #string Filename -- @param #number Frequency in MHz --- @param #number Modulation +-- @param #number Modulation either radio.modulation.AM or radio.modulation.FM -- @param #number Power in W -- @return #RADIO self -- @usage @@ -197,8 +253,8 @@ end -- @param #string Subtitle -- @param #number SubtitleDuration in s -- @param #number Frequency in MHz --- @param #number Modulation --- @param #bool Loop +-- @param #number Modulation either radio.modulation.AM or radio.modulation.FM +-- @param #boolean Loop -- @return #RADIO self -- @usage -- -- In this function the data is especially relevant if the broadcaster is a UNIT or a GROUP, @@ -222,7 +278,7 @@ end -- @return #RADIO self -- @usage -- -- The Radio has to be populated with the new transmission before broadcasting. --- Please use RADIO setters or either @{Radio#RADIO.NewGenericTransmission} or @{Radio#RADIO.NewUnitTransmission} +-- -- Please use RADIO setters or either @{Radio#RADIO.NewGenericTransmission} or @{Radio#RADIO.NewUnitTransmission} -- -- This class is in fact pretty smart, it determines the right DCS function to use depending on the type of POSITIONABLE -- -- If the POSITIONABLE is not a UNIT or a GROUP, we use the generic (but limited) trigger.action.radioTransmission() -- -- If the POSITIONABLE is a UNIT or a GROUP, we use the "TransmitMessage" Command diff --git a/Moose Development/Moose/Wrapper/Positionable.lua b/Moose Development/Moose/Wrapper/Positionable.lua index 537750cfe..e4cf24038 100644 --- a/Moose Development/Moose/Wrapper/Positionable.lua +++ b/Moose Development/Moose/Wrapper/Positionable.lua @@ -432,7 +432,7 @@ function POSITIONABLE:Message( Message, Duration, Name ) return nil end ---- Create a @{Radio#RADIO}, to allow radio transmission for this POSITIONABLE +--- Create a @{Radio#RADIO}, to allow radio transmission for this POSITIONABLE. -- Set parameters with the methods provided, then use RADIO:Broadcast() to actually broadcast the message -- @param #POSITIONABLE self -- @return #RADIO Radio diff --git a/docs/Documentation/AI_Balancer.html b/docs/Documentation/AI_Balancer.html index 4a168b45f..46e7074bf 100644 --- a/docs/Documentation/AI_Balancer.html +++ b/docs/Documentation/AI_Balancer.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/AI_Cap.html b/docs/Documentation/AI_Cap.html index 8751f3703..8b7cfde8d 100644 --- a/docs/Documentation/AI_Cap.html +++ b/docs/Documentation/AI_Cap.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/AI_Cas.html b/docs/Documentation/AI_Cas.html index d40e0f8d1..598819e4c 100644 --- a/docs/Documentation/AI_Cas.html +++ b/docs/Documentation/AI_Cas.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/AI_Patrol.html b/docs/Documentation/AI_Patrol.html index 14a6a30b6..21033a3ee 100644 --- a/docs/Documentation/AI_Patrol.html +++ b/docs/Documentation/AI_Patrol.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • @@ -920,9 +921,6 @@ Use the method AIPATROLZONE.M - -

    This table contains the targets detected during patrol.

    -
    diff --git a/docs/Documentation/Account.html b/docs/Documentation/Account.html index ca5687216..dd86b7919 100644 --- a/docs/Documentation/Account.html +++ b/docs/Documentation/Account.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Airbase.html b/docs/Documentation/Airbase.html index b1cb49a7f..42d89db6d 100644 --- a/docs/Documentation/Airbase.html +++ b/docs/Documentation/Airbase.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/AirbasePolice.html b/docs/Documentation/AirbasePolice.html index e80898903..74b4ed1b3 100644 --- a/docs/Documentation/AirbasePolice.html +++ b/docs/Documentation/AirbasePolice.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Assign.html b/docs/Documentation/Assign.html index fd741ec8a..2816bbdec 100644 --- a/docs/Documentation/Assign.html +++ b/docs/Documentation/Assign.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Base.html b/docs/Documentation/Base.html index 526210e42..6bf05d7e9 100644 --- a/docs/Documentation/Base.html +++ b/docs/Documentation/Base.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Cargo.html b/docs/Documentation/Cargo.html index efcd3f237..c27f94351 100644 --- a/docs/Documentation/Cargo.html +++ b/docs/Documentation/Cargo.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • @@ -2425,7 +2426,6 @@ The UNIT carrying the package.

    - AI_CARGO_UNIT.CargoCarrier diff --git a/docs/Documentation/CleanUp.html b/docs/Documentation/CleanUp.html index 0fc27c9c6..a7e24b4af 100644 --- a/docs/Documentation/CleanUp.html +++ b/docs/Documentation/CleanUp.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Client.html b/docs/Documentation/Client.html index 799a07533..829d048cd 100644 --- a/docs/Documentation/Client.html +++ b/docs/Documentation/Client.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/CommandCenter.html b/docs/Documentation/CommandCenter.html index 2dddeca01..b2ed82f34 100644 --- a/docs/Documentation/CommandCenter.html +++ b/docs/Documentation/CommandCenter.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Controllable.html b/docs/Documentation/Controllable.html index a21da9167..0ed39c937 100644 --- a/docs/Documentation/Controllable.html +++ b/docs/Documentation/Controllable.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Database.html b/docs/Documentation/Database.html index be41b649d..4fb699a46 100644 --- a/docs/Documentation/Database.html +++ b/docs/Documentation/Database.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Detection.html b/docs/Documentation/Detection.html index 4c3e89eab..3d5fe012d 100644 --- a/docs/Documentation/Detection.html +++ b/docs/Documentation/Detection.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/DetectionManager.html b/docs/Documentation/DetectionManager.html index 0c48152fb..1f9510fe4 100644 --- a/docs/Documentation/DetectionManager.html +++ b/docs/Documentation/DetectionManager.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Escort.html b/docs/Documentation/Escort.html index e2da40c9e..4161b4241 100644 --- a/docs/Documentation/Escort.html +++ b/docs/Documentation/Escort.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Event.html b/docs/Documentation/Event.html index d4bdd4c3d..77783424b 100644 --- a/docs/Documentation/Event.html +++ b/docs/Documentation/Event.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Fsm.html b/docs/Documentation/Fsm.html index 76ef8699c..a2c9ceef9 100644 --- a/docs/Documentation/Fsm.html +++ b/docs/Documentation/Fsm.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Group.html b/docs/Documentation/Group.html index eb3d67814..de4814bac 100644 --- a/docs/Documentation/Group.html +++ b/docs/Documentation/Group.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Identifiable.html b/docs/Documentation/Identifiable.html index 33086e9bf..ff6978ba6 100644 --- a/docs/Documentation/Identifiable.html +++ b/docs/Documentation/Identifiable.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/MOVEMENT.html b/docs/Documentation/MOVEMENT.html index aed446e5c..cefb7e4a0 100644 --- a/docs/Documentation/MOVEMENT.html +++ b/docs/Documentation/MOVEMENT.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Menu.html b/docs/Documentation/Menu.html index 453e33c66..919b0a24b 100644 --- a/docs/Documentation/Menu.html +++ b/docs/Documentation/Menu.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Message.html b/docs/Documentation/Message.html index 2da7809e7..5a7d60b69 100644 --- a/docs/Documentation/Message.html +++ b/docs/Documentation/Message.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/MissileTrainer.html b/docs/Documentation/MissileTrainer.html index b51e024ab..76cc5819b 100644 --- a/docs/Documentation/MissileTrainer.html +++ b/docs/Documentation/MissileTrainer.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Mission.html b/docs/Documentation/Mission.html index 1ad2c406d..4692cae3d 100644 --- a/docs/Documentation/Mission.html +++ b/docs/Documentation/Mission.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Object.html b/docs/Documentation/Object.html index 6be6e7aa6..f8ced6b6f 100644 --- a/docs/Documentation/Object.html +++ b/docs/Documentation/Object.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Point.html b/docs/Documentation/Point.html index 6dfc437e5..afa6045b6 100644 --- a/docs/Documentation/Point.html +++ b/docs/Documentation/Point.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • @@ -1226,7 +1227,6 @@ The new calculated POINT_VEC2.

    - POINT_VEC2.z diff --git a/docs/Documentation/Positionable.html b/docs/Documentation/Positionable.html index 0aeaabf15..1235202c2 100644 --- a/docs/Documentation/Positionable.html +++ b/docs/Documentation/Positionable.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • @@ -164,6 +165,12 @@ POSITIONABLE:GetPositionVec3()

    Returns the DCSTypes#Position3 position vectors indicating the point and direction vectors in 3D of the POSITIONABLE within the mission.

    + + + + POSITIONABLE:GetRadio() + +

    Create a Radio#RADIO, to allow radio transmission for this POSITIONABLE.

    @@ -491,6 +498,27 @@ The POSITIONABLE is not existing or alive.

    + +POSITIONABLE:GetRadio() + +
    +
    + +

    Create a Radio#RADIO, to allow radio transmission for this POSITIONABLE.

    + + +

    Set parameters with the methods provided, then use RADIO:Broadcast() to actually broadcast the message

    + +

    Return value

    + +

    #RADIO: +Radio

    + +
    +
    +
    +
    + POSITIONABLE:GetRandomVec3(Radius) @@ -1014,6 +1042,8 @@ self

    +

    Type RADIO

    + diff --git a/docs/Documentation/Process_JTAC.html b/docs/Documentation/Process_JTAC.html index 16ebd156c..a7c1c10e6 100644 --- a/docs/Documentation/Process_JTAC.html +++ b/docs/Documentation/Process_JTAC.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Process_Pickup.html b/docs/Documentation/Process_Pickup.html index c39875791..229374866 100644 --- a/docs/Documentation/Process_Pickup.html +++ b/docs/Documentation/Process_Pickup.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Radio.html b/docs/Documentation/Radio.html new file mode 100644 index 000000000..1d61a7f87 --- /dev/null +++ b/docs/Documentation/Radio.html @@ -0,0 +1,833 @@ + + + + + + +
    +
    + +
    +
    +
    +
    + +
    +

    Module Radio

    + +

    This module contains the Core - RADIO class.

    + + +

    The RADIO class is responsible for transmitting radio communications.

    + +

    1) Radio#RADIO class, extends Base#BASE

    + +

    1.1) General radio transmssion setup

    + +

    What are radio communications in DCS ?

    + +
      +
    • Radio transmissions consist of sound files that are broadcasted on a specific frequency (e.g. 115MHz) and modulation (e.g. AM),
    • +
    • They can be subtitled for a specific duration, the power in Watts of the transmiter's antenna can be set, and the transmission can be looped.
    • +
    + +

    How to supply DCS my own Sound Files ?

    + +
      +
    • Your sound files need to be encoded in .ogg or .wav,
    • +
    • Your sound files should be as tiny as possible. It is suggested you encode in .ogg with low bitrate and sampling settings,
    • +
    • They need to be added in .\l10n\DEFAULT\ in you .miz file (wich can be decompressed like a .zip file),
    • +
    • For simplicty sake, you can let DCS' Mission Editor add the file itself, by creating a new Trigger with the action "Sound to Country", and choosing your sound file and a country you don't use in your mission.
    • +
    + +

    Due to weird DCS quirks, radio communications behave differently if sent by a Unit#UNIT or a Group#GROUP or by any other Positionable#POSITIONABLE

    + + + +

    Note that obviously, the frequency and the modulation of the transmission are important only if the players are piloting an Advanced System Modelling enabled aircraft, +like the A10C or the Mirage 2000C. They will hear the transmission if they are tuned on the right frequency and modulation (and if they are close enough - more on that below). +If a FC3 airacraft is used, it will hear every communication, whatever the frequency and the modulation is set to.

    + +

    1.2) Radio#RADIO usage

    + +

    There are 3 steps to a successful radio transmission

    + + + +

    Methods to set relevant parameters for both a Unit#UNIT or a Group#GROUP or any other Positionable#POSITIONABLE

    + + + +

    Additional Methods to set relevant parameters if the transmiter is a Unit#UNIT or a Group#GROUP

    + + + +

    Additional Methods to set relevant parameters if the transmiter is any other Wrapper.Positionable#POSITIONABLE

    + + + +

    What is this power thing ?

    + +
      +
    • If your transmission is sent by a Positionable#POSITIONABLE other than a Unit#UNIT or a Group#GROUP, you can set the power of the antenna,
    • +
    • Otherwise, DCS sets it automatically, depending on what's available on your Unit,
    • +
    • If the player gets too far from the transmiter, or if the antenna is too weak, the transmission will fade and become noisyer,
    • +
    • This an automated DCS calculation you have no say on,
    • +
    • For reference, a standard VOR station has a 100W antenna, a standard AA TACAN has a 120W antenna, and civilian ATC's antenna usually range between 300 and 500W,
    • +
    • Note that if the transmission has a subtitle, it will be readable, regardless of the quality of the transmission.
    • +
    + +

    Authors: Hugues "Grey_Echo" Bousquet

    + + +

    Global(s)

    + + + + + +
    RADIO + +
    +

    Type RADIO

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    RADIO:Broadcast() +

    Actually Broadcast the transmission

    +
    RADIO.ClassName + +
    RADIO.FileName +

    Name of the sound file

    +
    RADIO.Frequency +

    Frequency of the transmission in Hz

    +
    RADIO.Loop + +
    RADIO.Modulation +

    Modulation of the transmission (either radio.modulation.AM or radio.modulation.FM)

    +
    RADIO.New(Positionable, self, positionable) +

    Create a new RADIO Object.

    +
    RADIO:NewGenericTransmission(Filename, Frequency, Modulation, Power, ...) +

    Create a new transmission, that is to say, populate the RADIO with relevant data

    +
    RADIO:NewUnitTransmission(Filename, Subtitle, SubtitleDuration, Frequency, Modulation, Loop, ...) +

    Create a new transmission, that is to say, populate the RADIO with relevant data

    +
    RADIO.Positionable +

    The transmiter

    +
    RADIO.Power +

    Power of the antenna is Watts

    +
    RADIO:SetFileName(fileName, filename) +

    Check validity of the filename passed and sets RADIO.FileName

    +
    RADIO:SetFrequency(frequency) +

    Check validity of the frequency passed and sets RADIO.Frequency

    +
    RADIO:SetLoop(Loop, loop) +

    Check validity of the loop passed and sets RADIO.Loop

    +
    RADIO:SetModulation(modulation) +

    Check validity of the frequency passed and sets RADIO.Modulation

    +
    RADIO:SetPower(Power, power) +

    Check validity of the power passed and sets RADIO.Power

    +
    RADIO:SetSubtitle(Subtitle, SubtitleDuration, subtitle, subtitleDuration) +

    Check validity of the subtitle and the subtitleDuration passed and sets RADIO.subtitle and RADIO.subtitleDuration

    +
    RADIO.Subtitle +

    Subtitle of the transmission

    +
    RADIO.SubtitleDuration +

    Duration of the Subtitle in seconds

    +
    + +

    Global(s)

    +
    +
    + + #RADIO + +RADIO + +
    +
    + + + +
    +
    +

    Type Radio

    + +

    Type RADIO

    + +

    The RADIO class

    + +

    Field(s)

    +
    +
    + + +RADIO:Broadcast() + +
    +
    + +

    Actually Broadcast the transmission

    + +

    Return value

    + +

    #RADIO: +self

    + +

    Usage:

    +
    -- The Radio has to be populated with the new transmission before broadcasting.
    +-- Please use RADIO setters or either @{Radio#RADIO.NewGenericTransmission} or @{Radio#RADIO.NewUnitTransmission}
    +-- This class is in fact pretty smart, it determines the right DCS function to use depending on the type of POSITIONABLE
    +-- If the POSITIONABLE is not a UNIT or a GROUP, we use the generic (but limited) trigger.action.radioTransmission()
    +-- If the POSITIONABLE is a UNIT or a GROUP, we use the "TransmitMessage" Command
    +-- If your POSITIONABLE is a UNIT or a GROUP, the Power is ignored.
    +-- If your POSITIONABLE is not a UNIT or a GROUP, the Subtitle, SubtitleDuration and Loop are ignored
    + +
    +
    +
    +
    + + #string + +RADIO.ClassName + +
    +
    + + + +
    +
    +
    +
    + + #string + +RADIO.FileName + +
    +
    + +

    Name of the sound file

    + +
    +
    +
    +
    + + #number + +RADIO.Frequency + +
    +
    + +

    Frequency of the transmission in Hz

    + +
    +
    +
    +
    + + #boolean + +RADIO.Loop + +
    +
    + + + +
    +
    +
    +
    + + #number + +RADIO.Modulation + +
    +
    + +

    Modulation of the transmission (either radio.modulation.AM or radio.modulation.FM)

    + +
    +
    +
    +
    + + +RADIO.New(Positionable, self, positionable) + +
    +
    + +

    Create a new RADIO Object.

    + + +

    This doesn't broadcast a transmission, though, use RADIO.Broadcast to actually broadcast

    + +

    Parameters

    + +

    Return values

    +
      +
    1. + +

      #RADIO: +Radio

      + +
    2. +
    3. + +

      #nil: +If Positionable is invalid

      + +
    4. +
    +

    Usage:

    +
    -- If you want to create a RADIO, you probably should use @{Positionable#POSITIONABLE.GetRadio}() instead
    + +
    +
    +
    +
    + + +RADIO:NewGenericTransmission(Filename, Frequency, Modulation, Power, ...) + +
    +
    + +

    Create a new transmission, that is to say, populate the RADIO with relevant data

    + +

    Parameters

    +
      +
    • + +

      #string Filename :

      + +
    • +
    • + +

      #number Frequency : +in MHz

      + +
    • +
    • + +

      #number Modulation : +either radio.modulation.AM or radio.modulation.FM

      + +
    • +
    • + +

      #number Power : +in W

      + +
    • +
    • + +

      ... :

      + +
    • +
    +

    Return value

    + +

    #RADIO: +self

    + +

    Usage:

    +
    -- In this function the data is especially relevant if the broadcaster is anything but a UNIT or a GROUP,
    +but it will work with a UNIT or a GROUP anyway
    +-- Only the RADIO and the Filename are mandatory
    + +
    +
    +
    +
    + + +RADIO:NewUnitTransmission(Filename, Subtitle, SubtitleDuration, Frequency, Modulation, Loop, ...) + +
    +
    + +

    Create a new transmission, that is to say, populate the RADIO with relevant data

    + +

    Parameters

    +
      +
    • + +

      #string Filename :

      + +
    • +
    • + +

      #string Subtitle :

      + +
    • +
    • + +

      #number SubtitleDuration : +in s

      + +
    • +
    • + +

      #number Frequency : +in MHz

      + +
    • +
    • + +

      #number Modulation : +either radio.modulation.AM or radio.modulation.FM

      + +
    • +
    • + +

      #boolean Loop :

      + +
    • +
    • + +

      ... :

      + +
    • +
    +

    Return value

    + +

    #RADIO: +self

    + +

    Usage:

    +
    -- In this function the data is especially relevant if the broadcaster is a UNIT or a GROUP,
    +but it will work for any POSITIONABLE
    +-- Only the RADIO and the Filename are mandatory
    + +
    +
    +
    +
    + + Wrapper.Positionable#POSITIONABLE + +RADIO.Positionable + +
    +
    + +

    The transmiter

    + +
    +
    +
    +
    + + #number + +RADIO.Power + +
    +
    + +

    Power of the antenna is Watts

    + +
    +
    +
    +
    + + +RADIO:SetFileName(fileName, filename) + +
    +
    + +

    Check validity of the filename passed and sets RADIO.FileName

    + +

    Parameters

    +
      +
    • + +

      #string fileName : +File name of the sound file (i.e. "Noise.ogg")

      + +
    • +
    • + +

      filename :

      + +
    • +
    +

    Return value

    + +

    #RADIO: +self

    + +
    +
    +
    +
    + + +RADIO:SetFrequency(frequency) + +
    +
    + +

    Check validity of the frequency passed and sets RADIO.Frequency

    + +

    Parameter

    +
      +
    • + +

      #number frequency : +in MHz (Ranges allowed for radio transmissions in DCS : 30-88 / 108-152 / 225-400MHz)

      + +
    • +
    +

    Return value

    + +

    #RADIO: +self

    + +
    +
    +
    +
    + + +RADIO:SetLoop(Loop, loop) + +
    +
    + +

    Check validity of the loop passed and sets RADIO.Loop

    + +

    Parameters

    +
      +
    • + +

      #boolean Loop :

      + +
    • +
    • + +

      loop :

      + +
    • +
    +

    Return value

    + +

    #RADIO: +self

    + +

    Usage:

    +
    + +
    +
    +
    +
    + + +RADIO:SetModulation(modulation) + +
    +
    + +

    Check validity of the frequency passed and sets RADIO.Modulation

    + +

    Parameter

    +
      +
    • + +

      #number modulation : +either radio.modulation.AM or radio.modulation.FM

      + +
    • +
    +

    Return value

    + +

    #RADIO: +self

    + +
    +
    +
    +
    + + +RADIO:SetPower(Power, power) + +
    +
    + +

    Check validity of the power passed and sets RADIO.Power

    + +

    Parameters

    +
      +
    • + +

      #number Power : +in W

      + +
    • +
    • + +

      power :

      + +
    • +
    +

    Return value

    + +

    #RADIO: +self

    + +
    +
    +
    +
    + + +RADIO:SetSubtitle(Subtitle, SubtitleDuration, subtitle, subtitleDuration) + +
    +
    + +

    Check validity of the subtitle and the subtitleDuration passed and sets RADIO.subtitle and RADIO.subtitleDuration

    + +

    Parameters

    +
      +
    • + +

      #string Subtitle :

      + +
    • +
    • + +

      #number SubtitleDuration : +in s

      + +
    • +
    • + +

      subtitle :

      + +
    • +
    • + +

      subtitleDuration :

      + +
    • +
    +

    Return value

    + +

    #RADIO: +self

    + +

    Usage:

    +
    -- Both parameters are mandatory, since it wouldn't make much sense to change the Subtitle and not its duration
    + +
    +
    +
    +
    + + #string + +RADIO.Subtitle + +
    +
    + +

    Subtitle of the transmission

    + +
    +
    +
    +
    + + #number + +RADIO.SubtitleDuration + +
    +
    + +

    Duration of the Subtitle in seconds

    + +
    +
    + +
    + +
    + + diff --git a/docs/Documentation/Route.html b/docs/Documentation/Route.html index 3425dc182..820011258 100644 --- a/docs/Documentation/Route.html +++ b/docs/Documentation/Route.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Scenery.html b/docs/Documentation/Scenery.html index f7258b5b4..7f3b7ec1c 100644 --- a/docs/Documentation/Scenery.html +++ b/docs/Documentation/Scenery.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/ScheduleDispatcher.html b/docs/Documentation/ScheduleDispatcher.html index df99aa154..de37a4eaf 100644 --- a/docs/Documentation/ScheduleDispatcher.html +++ b/docs/Documentation/ScheduleDispatcher.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Scheduler.html b/docs/Documentation/Scheduler.html index eb654041b..9bd1335c6 100644 --- a/docs/Documentation/Scheduler.html +++ b/docs/Documentation/Scheduler.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Scoring.html b/docs/Documentation/Scoring.html index 0ffe32d75..e78f285e9 100644 --- a/docs/Documentation/Scoring.html +++ b/docs/Documentation/Scoring.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Sead.html b/docs/Documentation/Sead.html index be4e3bf31..ca6b2af88 100644 --- a/docs/Documentation/Sead.html +++ b/docs/Documentation/Sead.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Set.html b/docs/Documentation/Set.html index 8c6884967..5b92a9341 100644 --- a/docs/Documentation/Set.html +++ b/docs/Documentation/Set.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Smoke.html b/docs/Documentation/Smoke.html index 0089621d3..636b84eeb 100644 --- a/docs/Documentation/Smoke.html +++ b/docs/Documentation/Smoke.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Spawn.html b/docs/Documentation/Spawn.html index 1fae53205..d9625fe95 100644 --- a/docs/Documentation/Spawn.html +++ b/docs/Documentation/Spawn.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • @@ -834,6 +835,12 @@ A coding example is provided at the description of the SPAWN:_TranslateRotate(SpawnIndex, SpawnRootX, SpawnRootY, SpawnX, SpawnY, SpawnAngle) + + + + SPAWN.uncontrolled + + @@ -1759,6 +1766,9 @@ The group that was spawned. You can use this group for further actions.

    + +

    Don't repeat the group from Take-Off till Landing and back Take-Off by ReSpawning.

    +
    @@ -2529,7 +2539,7 @@ Spawn_BE_KA50 = SPAWN:New( 'BE KA-50@RAMP-Ground Defense' ):Schedule( 600, 0.5 )
    - + #boolean SPAWN.SpawnUnControlled @@ -3192,6 +3202,20 @@ True = Continue Scheduler

    + +
    +
    +
    + + + +SPAWN.uncontrolled + +
    +
    + + +
    diff --git a/docs/Documentation/Static.html b/docs/Documentation/Static.html index cdcb75c70..d21b8ba46 100644 --- a/docs/Documentation/Static.html +++ b/docs/Documentation/Static.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Task.html b/docs/Documentation/Task.html index 9befab2b3..b7fbd93cf 100644 --- a/docs/Documentation/Task.html +++ b/docs/Documentation/Task.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Task_A2G.html b/docs/Documentation/Task_A2G.html index 97aa39bb4..75b9f1d69 100644 --- a/docs/Documentation/Task_A2G.html +++ b/docs/Documentation/Task_A2G.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Task_PICKUP.html b/docs/Documentation/Task_PICKUP.html index fd8241229..9a5346e10 100644 --- a/docs/Documentation/Task_PICKUP.html +++ b/docs/Documentation/Task_PICKUP.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Task_SEAD.html b/docs/Documentation/Task_SEAD.html index e443fdc31..93f5969bd 100644 --- a/docs/Documentation/Task_SEAD.html +++ b/docs/Documentation/Task_SEAD.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Unit.html b/docs/Documentation/Unit.html index 39cf4d1d7..11f937aa7 100644 --- a/docs/Documentation/Unit.html +++ b/docs/Documentation/Unit.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Utils.html b/docs/Documentation/Utils.html index 33c940e11..cccf34a6d 100644 --- a/docs/Documentation/Utils.html +++ b/docs/Documentation/Utils.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/Zone.html b/docs/Documentation/Zone.html index 9c92cf3da..3cddb721d 100644 --- a/docs/Documentation/Zone.html +++ b/docs/Documentation/Zone.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • diff --git a/docs/Documentation/index.html b/docs/Documentation/index.html index 124efee34..3ac55dfd9 100644 --- a/docs/Documentation/index.html +++ b/docs/Documentation/index.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher
  • @@ -312,6 +313,12 @@ are design patterns allowing efficient (long-lasting) processes and workflows.Process_Pickup + + + + Radio + +

    This module contains the Core - RADIO class.

    diff --git a/docs/Documentation/routines.html b/docs/Documentation/routines.html index 3c5b6891b..dac261086 100644 --- a/docs/Documentation/routines.html +++ b/docs/Documentation/routines.html @@ -49,6 +49,7 @@
  • Positionable
  • Process_JTAC
  • Process_Pickup
  • +
  • Radio
  • Route
  • Scenery
  • ScheduleDispatcher