mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Merge remote-tracking branch 'refs/remotes/origin/master' into FlightControl
# Conflicts: # Moose Development/Moose/Core/Event.lua # Moose Development/Moose/Functional/Scoring.lua # Moose Development/Moose/Wrapper/Controllable.lua # Moose Mission Setup/Moose Mission Update/l10n/DEFAULT/Moose.lua # Moose Mission Setup/Moose.lua # Moose Test Missions/EVT - Event Handling/EVT-100 - OnEventShot Example/EVT-100 - OnEventShot Example.miz # Moose Test Missions/EVT - Event Handling/EVT-101 - OnEventHit Example/EVT-101 - OnEventHit Example.miz # Moose Test Missions/EVT - Event Handling/EVT-102 - OnEventTakeoff Example/EVT-102 - OnEventTakeoff Example.miz # Moose Test Missions/EVT - Event Handling/EVT-103 - OnEventLand Example/EVT-103 - OnEventLand Example.miz # Moose Test Missions/EVT - Event Handling/EVT-104 - OnEventCrash Example/EVT-104 - OnEventCrash Example.miz # Moose Test Missions/SCO - Scoring/SCO-100 - Scoring of Statics/SCO-100 - Scoring of Statics.miz # Moose Test Missions/SCO - Scoring/SCO-101 - Scoring Client to Client/SCO-101 - Scoring Client to Client.miz # docs/Documentation/Controllable.html # docs/Documentation/Event.html # docs/Documentation/Point.html # docs/Documentation/Zone.html
This commit is contained in:
@@ -129,13 +129,16 @@ When the fuel treshold has been reached, the airplane will fly towards the neare
|
||||
<ul>
|
||||
<li><strong>None</strong> ( Group ): The process is not started yet.</li>
|
||||
<li><strong>Patrolling</strong> ( Group ): The AI is patrolling the Patrol Zone.</li>
|
||||
<li><strong>Returning</strong> ( Group ): The AI is returning to Base..</li>
|
||||
<li><strong>Returning</strong> ( Group ): The AI is returning to Base.</li>
|
||||
<li><strong>Stopped</strong> ( Group ): The process is stopped.</li>
|
||||
<li><strong>Crashed</strong> ( Group ): The AI has crashed or is dead.</li>
|
||||
</ul>
|
||||
|
||||
<h3>1.2.2) AI<em>PATROL</em>ZONE Events</h3>
|
||||
|
||||
<ul>
|
||||
<li><strong>Start</strong> ( Group ): Start the process.</li>
|
||||
<li><strong>Stop</strong> ( Group ): Stop the process.</li>
|
||||
<li><strong>Route</strong> ( Group ): Route the AI to a new random 3D point within the Patrol Zone.</li>
|
||||
<li><strong>RTB</strong> ( Group ): Route the AI to the home base.</li>
|
||||
<li><strong>Detect</strong> ( Group ): The AI is detecting targets.</li>
|
||||
@@ -380,6 +383,12 @@ Use the method <a href="##(AI_PATROL_ZONE).ManageDamage">AI<em>PATROL</em>ZONE.M
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).OnAfterStatus">AI_PATROL_ZONE:OnAfterStatus(Controllable, From, Event, To)</a></td>
|
||||
<td class="summary">
|
||||
<p>OnAfter Transition Handler for Event Status.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).OnAfterStop">AI_PATROL_ZONE:OnAfterStop(Controllable, From, Event, To)</a></td>
|
||||
<td class="summary">
|
||||
<p>OnAfter Transition Handler for Event Stop.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -416,6 +425,12 @@ Use the method <a href="##(AI_PATROL_ZONE).ManageDamage">AI<em>PATROL</em>ZONE.M
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).OnBeforeStatus">AI_PATROL_ZONE:OnBeforeStatus(Controllable, From, Event, To)</a></td>
|
||||
<td class="summary">
|
||||
<p>OnBefore Transition Handler for Event Status.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).OnBeforeStop">AI_PATROL_ZONE:OnBeforeStop(Controllable, From, Event, To)</a></td>
|
||||
<td class="summary">
|
||||
<p>OnBefore Transition Handler for Event Stop.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -440,6 +455,12 @@ Use the method <a href="##(AI_PATROL_ZONE).ManageDamage">AI<em>PATROL</em>ZONE.M
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).OnEnterReturning">AI_PATROL_ZONE:OnEnterReturning(Controllable, From, Event, To)</a></td>
|
||||
<td class="summary">
|
||||
<p>OnEnter Transition Handler for State Returning.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).OnEnterStopped">AI_PATROL_ZONE:OnEnterStopped(Controllable, From, Event, To)</a></td>
|
||||
<td class="summary">
|
||||
<p>OnEnter Transition Handler for State Stopped.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -452,6 +473,12 @@ Use the method <a href="##(AI_PATROL_ZONE).ManageDamage">AI<em>PATROL</em>ZONE.M
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).OnLeaveReturning">AI_PATROL_ZONE:OnLeaveReturning(Controllable, From, Event, To)</a></td>
|
||||
<td class="summary">
|
||||
<p>OnLeave Transition Handler for State Returning.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).OnLeaveStopped">AI_PATROL_ZONE:OnLeaveStopped(Controllable, From, Event, To)</a></td>
|
||||
<td class="summary">
|
||||
<p>OnLeave Transition Handler for State Stopped.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -602,6 +629,12 @@ Use the method <a href="##(AI_PATROL_ZONE).ManageDamage">AI<em>PATROL</em>ZONE.M
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).Status">AI_PATROL_ZONE:Status()</a></td>
|
||||
<td class="summary">
|
||||
<p>Synchronous Event Trigger for Event Status.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).Stop">AI_PATROL_ZONE:Stop()</a></td>
|
||||
<td class="summary">
|
||||
<p>Synchronous Event Trigger for Event Stop.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -644,6 +677,12 @@ Use the method <a href="##(AI_PATROL_ZONE).ManageDamage">AI<em>PATROL</em>ZONE.M
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).__Status">AI_PATROL_ZONE:__Status(Delay)</a></td>
|
||||
<td class="summary">
|
||||
<p>Asynchronous Event Trigger for Event Status.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(AI_PATROL_ZONE).__Stop">AI_PATROL_ZONE:__Stop(Delay)</a></td>
|
||||
<td class="summary">
|
||||
<p>Asynchronous Event Trigger for Event Stop.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -1286,6 +1325,46 @@ The To State string.</p>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).OnAfterStop" >
|
||||
<strong>AI_PATROL_ZONE:OnAfterStop(Controllable, From, Event, To)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>OnAfter Transition Handler for Event Stop.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Wrapper.Controllable.html##(CONTROLLABLE)">Wrapper.Controllable#CONTROLLABLE</a> Controllable </em></code>:
|
||||
The Controllable Object managed by the FSM.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string From </em></code>:
|
||||
The From State string.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Event </em></code>:
|
||||
The Event string.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string To </em></code>:
|
||||
The To State string.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).OnBeforeDetect" >
|
||||
<strong>AI_PATROL_ZONE:OnBeforeDetect(Controllable, From, Event, To)</strong>
|
||||
</a>
|
||||
@@ -1556,6 +1635,51 @@ Return false to cancel Transition.</p>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).OnBeforeStop" >
|
||||
<strong>AI_PATROL_ZONE:OnBeforeStop(Controllable, From, Event, To)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>OnBefore Transition Handler for Event Stop.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Wrapper.Controllable.html##(CONTROLLABLE)">Wrapper.Controllable#CONTROLLABLE</a> Controllable </em></code>:
|
||||
The Controllable Object managed by the FSM.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string From </em></code>:
|
||||
The From State string.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Event </em></code>:
|
||||
The Event string.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string To </em></code>:
|
||||
The To State string.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em>#boolean:</em>
|
||||
Return false to cancel Transition.</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).OnCrash" >
|
||||
<strong>AI_PATROL_ZONE:OnCrash(EventData)</strong>
|
||||
</a>
|
||||
@@ -1678,6 +1802,46 @@ The To State string.</p>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).OnEnterStopped" >
|
||||
<strong>AI_PATROL_ZONE:OnEnterStopped(Controllable, From, Event, To)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>OnEnter Transition Handler for State Stopped.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Wrapper.Controllable.html##(CONTROLLABLE)">Wrapper.Controllable#CONTROLLABLE</a> Controllable </em></code>:
|
||||
The Controllable Object managed by the FSM.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string From </em></code>:
|
||||
The From State string.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Event </em></code>:
|
||||
The Event string.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string To </em></code>:
|
||||
The To State string.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).OnLeavePatrolling" >
|
||||
<strong>AI_PATROL_ZONE:OnLeavePatrolling(Controllable, From, Event, To)</strong>
|
||||
</a>
|
||||
@@ -1768,6 +1932,51 @@ Return false to cancel Transition.</p>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).OnLeaveStopped" >
|
||||
<strong>AI_PATROL_ZONE:OnLeaveStopped(Controllable, From, Event, To)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>OnLeave Transition Handler for State Stopped.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Wrapper.Controllable.html##(CONTROLLABLE)">Wrapper.Controllable#CONTROLLABLE</a> Controllable </em></code>:
|
||||
The Controllable Object managed by the FSM.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string From </em></code>:
|
||||
The From State string.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Event </em></code>:
|
||||
The Event string.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string To </em></code>:
|
||||
The To State string.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em>#boolean:</em>
|
||||
Return false to cancel Transition.</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).OnPilotDead" >
|
||||
<strong>AI_PATROL_ZONE:OnPilotDead(EventData)</strong>
|
||||
</a>
|
||||
@@ -2226,6 +2435,19 @@ self</p>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).Stop" >
|
||||
<strong>AI_PATROL_ZONE:Stop()</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Synchronous Event Trigger for Event Stop.</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE)._NewPatrolRoute" >
|
||||
<strong>AI_PATROL_ZONE._NewPatrolRoute(AIControllable, self)</strong>
|
||||
</a>
|
||||
@@ -2386,6 +2608,28 @@ The delay in seconds.</p>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).__Stop" >
|
||||
<strong>AI_PATROL_ZONE:__Stop(Delay)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Asynchronous Event Trigger for Event Stop.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#number Delay </em></code>:
|
||||
The delay in seconds.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(AI_PATROL_ZONE).onafterDead" >
|
||||
<strong>AI_PATROL_ZONE:onafterDead()</strong>
|
||||
</a>
|
||||
|
||||
@@ -72,40 +72,79 @@
|
||||
<div id="content">
|
||||
<h1>Module <code>Base</code></h1>
|
||||
|
||||
<p>This module contains the BASE class.</p>
|
||||
<p><strong>Core</strong> - BASE forms <strong>the basis of the MOOSE framework</strong>.</p>
|
||||
|
||||
|
||||
<p>Each class within the MOOSE framework derives from BASE.</p>
|
||||
|
||||
<p><img src="..\Presentations\BASE\Dia1.JPG" alt="Banner Image"/></p>
|
||||
|
||||
<hr/>
|
||||
|
||||
<h1>1) <a href="##(BASE)">#BASE</a> class</h1>
|
||||
<p>The <a href="##(BASE)">#BASE</a> class is the super class for all the classes defined within MOOSE.</p>
|
||||
|
||||
<p>It handles:</p>
|
||||
<p>All classes within the MOOSE framework are derived from the <a href="##(BASE)">#BASE</a> class. </p>
|
||||
|
||||
<p>BASE provides facilities for :</p>
|
||||
|
||||
<ul>
|
||||
<li>The construction and inheritance of child classes.</li>
|
||||
<li>The tracing of objects during mission execution within the <strong>DCS.log</strong> file, under the <strong>"Saved Games\DCS\Logs"</strong> folder.</li>
|
||||
<li>The construction and inheritance of MOOSE classes.</li>
|
||||
<li>The class naming and numbering system.</li>
|
||||
<li>The class hierarchy search system.</li>
|
||||
<li>The tracing of information or objects during mission execution for debuggin purposes.</li>
|
||||
<li>The subscription to DCS events for event handling in MOOSE objects.</li>
|
||||
</ul>
|
||||
|
||||
<p>Note: Normally you would not use the BASE class unless you are extending the MOOSE framework with new classes.</p>
|
||||
<p>Note: The BASE class is an abstract class and is not meant to be used directly.</p>
|
||||
|
||||
<h2>1.1) BASE constructor</h2>
|
||||
|
||||
<p>Any class derived from BASE, must use the <a href="Base.html##(BASE).New">Base#BASE.New</a> method how this is done.</p>
|
||||
<p>Any class derived from BASE, will use the <a href="Base.html##(BASE).New">Base#BASE.New</a> constructor embedded in the <a href="Base.html##(BASE).Inherit">Base#BASE.Inherit</a> method.
|
||||
See an example at the <a href="Base.html##(BASE).New">Base#BASE.New</a> method how this is done.</p>
|
||||
|
||||
<h2>1.2) BASE Trace functionality</h2>
|
||||
<h2>1.2) Trace information for debugging</h2>
|
||||
|
||||
<p>The BASE class contains trace methods to trace progress within a mission execution of a certain object.
|
||||
Note that these trace methods are inherited by each MOOSE class interiting BASE.
|
||||
As such, each object created from derived class from BASE can use the tracing functions to trace its execution.</p>
|
||||
These trace methods are inherited by each MOOSE class interiting BASE, soeach object created from derived class from BASE can use the tracing methods to trace its execution.</p>
|
||||
|
||||
<h3>1.2.1) Tracing functions</h3>
|
||||
<p>Any type of information can be passed to these tracing methods. See the following examples:</p>
|
||||
|
||||
<p>There are basically 3 types of tracing methods available within BASE:</p>
|
||||
<pre><code>self:E( "Hello" )
|
||||
</code></pre>
|
||||
|
||||
<p>Result in the word "Hello" in the dcs.log.</p>
|
||||
|
||||
<pre><code>local Array = { 1, nil, "h", { "a","b" }, "x" }
|
||||
self:E( Array )
|
||||
</code></pre>
|
||||
|
||||
<p>Results with the text [1]=1,[3]="h",[4]={[1]="a",[2]="b"},[5]="x"} in the dcs.log. </p>
|
||||
|
||||
<pre><code>local Object1 = "Object1"
|
||||
local Object2 = 3
|
||||
local Object3 = { Object 1, Object 2 }
|
||||
self:E( { Object1, Object2, Object3 } )
|
||||
</code></pre>
|
||||
|
||||
<p>Results with the text [1]={[1]="Object",[2]=3,[3]={[1]="Object",[2]=3}} in the dcs.log.</p>
|
||||
|
||||
<pre><code>local SpawnObject = SPAWN:New( "Plane" )
|
||||
local GroupObject = GROUP:FindByName( "Group" )
|
||||
self:E( { Spawn = SpawnObject, Group = GroupObject } )
|
||||
</code></pre>
|
||||
|
||||
<p>Results with the text [1]={Spawn={....),Group={...}} in the dcs.log. </p>
|
||||
|
||||
<p>Below a more detailed explanation of the different method types for tracing.</p>
|
||||
|
||||
<h3>1.2.1) Tracing methods categories</h3>
|
||||
|
||||
<p>There are basically 3 types of tracing methods available:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(BASE).F">BASE.F</a>: Trace the beginning of a function and its given parameters. An F is indicated at column 44 in the DCS.log file.</li>
|
||||
<li><a href="##(BASE).T">BASE.T</a>: Trace further logic within a function giving optional variables or parameters. A T is indicated at column 44 in the DCS.log file.</li>
|
||||
<li><a href="##(BASE).E">BASE.E</a>: Trace an exception within a function giving optional variables or parameters. An E is indicated at column 44 in the DCS.log file. An exception will always be traced.</li>
|
||||
<li><a href="##(BASE).F">BASE.F</a>: Used to trace the entrance of a function and its given parameters. An F is indicated at column 44 in the DCS.log file.</li>
|
||||
<li><a href="##(BASE).T">BASE.T</a>: Used to trace further logic within a function giving optional variables or parameters. A T is indicated at column 44 in the DCS.log file.</li>
|
||||
<li><a href="##(BASE).E">BASE.E</a>: Used to always trace information giving optional variables or parameters. An E is indicated at column 44 in the DCS.log file.</li>
|
||||
</ul>
|
||||
|
||||
<h3>1.2.2) Tracing levels</h3>
|
||||
@@ -131,10 +170,11 @@ These tracing levels were defined to avoid bulks of tracing to be generated by l
|
||||
<li>Activate all tracing through the <a href="##(BASE).TraceAll">BASE.TraceAll</a>() method.</li>
|
||||
<li>Activate only the tracing of a certain class (name) through the <a href="##(BASE).TraceClass">BASE.TraceClass</a>() method.</li>
|
||||
<li>Activate only the tracing of a certain method of a certain class through the <a href="##(BASE).TraceClassMethod">BASE.TraceClassMethod</a>() method.</li>
|
||||
<li>Activate only the tracing of a certain level through the <a href="##(BASE).TraceLevel">BASE.TraceLevel</a>() method.
|
||||
<h3>1.2.4) Check if tracing is on.</h3></li>
|
||||
<li>Activate only the tracing of a certain level through the <a href="##(BASE).TraceLevel">BASE.TraceLevel</a>() method.</li>
|
||||
</ul>
|
||||
|
||||
<h3>1.2.4) Check if tracing is on.</h3>
|
||||
|
||||
<p>The method <a href="##(BASE).IsTrace">BASE.IsTrace</a>() will validate if tracing is activated or not.</p>
|
||||
|
||||
<h2>1.3 DCS simulator Event Handling</h2>
|
||||
@@ -146,7 +186,7 @@ and handled through lua scripting. MOOSE provides an encapsulation to handle the
|
||||
|
||||
<p>At first, the mission designer will need to <strong>Subscribe</strong> to a specific DCS event for the class.
|
||||
So, when the DCS event occurs, the class will be notified of that event.
|
||||
There are two functions which you use to subscribe to or unsubscribe from an event.</p>
|
||||
There are two methods which you use to subscribe to or unsubscribe from an event.</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(BASE).HandleEvent">BASE.HandleEvent</a>(): Subscribe to a DCS Event.</li>
|
||||
@@ -201,20 +241,22 @@ about the event that occurred.</p>
|
||||
|
||||
<h2>1.5) All objects derived from BASE can have "States"</h2>
|
||||
|
||||
<p>A mechanism is in place in MOOSE, that allows to let the objects administer <strong>states</strong>.
|
||||
States are essentially properties of objects, which are identified by a <strong>Key</strong> and a <strong>Value</strong>.
|
||||
The method <a href="##(BASE).SetState">BASE.SetState</a>() can be used to set a Value with a reference Key to the object.
|
||||
To <strong>read or retrieve</strong> a state Value based on a Key, use the <a href="##(BASE).GetState">BASE.GetState</a> method.
|
||||
These two methods provide a very handy way to keep state at long lasting processes.
|
||||
<p>A mechanism is in place in MOOSE, that allows to let the objects administer <strong>states</strong>. <br/>
|
||||
States are essentially properties of objects, which are identified by a <strong>Key</strong> and a <strong>Value</strong>. </p>
|
||||
|
||||
<p>The method <a href="##(BASE).SetState">BASE.SetState</a>() can be used to set a Value with a reference Key to the object. <br/>
|
||||
To <strong>read or retrieve</strong> a state Value based on a Key, use the <a href="##(BASE).GetState">BASE.GetState</a> method. </p>
|
||||
|
||||
<p>These two methods provide a very handy way to keep state at long lasting processes.
|
||||
Values can be stored within the objects, and later retrieved or changed when needed.
|
||||
There is one other important thing to note, the <a href="##(BASE).SetState">BASE.SetState</a>() and <a href="##(BASE).GetState">BASE.GetState</a> methods
|
||||
receive as the <strong>first parameter the object for which the state needs to be set</strong>.
|
||||
Thus, if the state is to be set for the same object as the object for which the method is used, then provide the same
|
||||
object name to the method.</p>
|
||||
|
||||
<h2>1.10) BASE Inheritance (tree) support</h2>
|
||||
<h2>1.10) Inheritance</h2>
|
||||
|
||||
<p>The following methods are available to support inheritance:</p>
|
||||
<p>The following methods are available to implement inheritance</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(BASE).Inherit">BASE.Inherit</a>: Inherits from a class.</li>
|
||||
@@ -406,7 +448,7 @@ YYYY-MM-DD: CLASS:<strong>NewFunction( Params )</strong> added</p>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(BASE).New">BASE:New()</a></td>
|
||||
<td class="summary">
|
||||
|
||||
<p>BASE constructor.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -1073,6 +1115,14 @@ The <a href="Event.html">Event</a> processing Priority.</p>
|
||||
|
||||
<p>This is the worker method to retrieve the Parent class.</p>
|
||||
|
||||
|
||||
<p>Note that the Parent class must be passed to call the parent class method.</p>
|
||||
|
||||
<pre><code>self:GetParent(self):ParentMethod()
|
||||
|
||||
|
||||
</code></pre>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
@@ -1223,10 +1273,23 @@ Child</p>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
<p>BASE constructor.</p>
|
||||
|
||||
|
||||
<p> @todo need to investigate if the deepCopy is really needed... Don't think so.</p>
|
||||
|
||||
<p>This is an example how to use the BASE:New() constructor in a new class definition when inheriting from BASE.</p>
|
||||
|
||||
<pre><code>function EVENT:New()
|
||||
local self = BASE:Inherit( self, BASE:New() ) -- #EVENT
|
||||
return self
|
||||
end
|
||||
|
||||
</code></pre>
|
||||
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(BASE)">#BASE</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
@@ -108,7 +108,7 @@ This is different from the EnRoute tasks, where the targets of the task need to
|
||||
<p>Find below a list of the <strong>assigned task</strong> methods:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(CONTROLLABLE).TaskAttackControllable">CONTROLLABLE.TaskAttackControllable</a>: (AIR) Attack a Controllable.</li>
|
||||
<li><a href="##(CONTROLLABLE).TaskAttackGroup">CONTROLLABLE.TaskAttackGroup</a>: (AIR) Attack a Controllable.</li>
|
||||
<li><a href="##(CONTROLLABLE).TaskAttackMapObject">CONTROLLABLE.TaskAttackMapObject</a>: (AIR) Attacking the map object (building, structure, e.t.c).</li>
|
||||
<li><a href="##(CONTROLLABLE).TaskAttackUnit">CONTROLLABLE.TaskAttackUnit</a>: (AIR) Attack the Unit.</li>
|
||||
<li><a href="##(CONTROLLABLE).TaskBombing">CONTROLLABLE.TaskBombing</a>: (AIR) Delivering weapon at the point on the ground.</li>
|
||||
@@ -116,7 +116,7 @@ This is different from the EnRoute tasks, where the targets of the task need to
|
||||
<li><a href="##(CONTROLLABLE).TaskEmbarking">CONTROLLABLE.TaskEmbarking</a>: (AIR) Move the controllable to a Vec2 Point, wait for a defined duration and embark a controllable.</li>
|
||||
<li><a href="##(CONTROLLABLE).TaskEmbarkToTransport">CONTROLLABLE.TaskEmbarkToTransport</a>: (GROUND) Embark to a Transport landed at a location.</li>
|
||||
<li><a href="##(CONTROLLABLE).TaskEscort">CONTROLLABLE.TaskEscort</a>: (AIR) Escort another airborne controllable. </li>
|
||||
<li><a href="##(CONTROLLABLE).TaskFAC_AttackControllable">CONTROLLABLE.TaskFAC_AttackControllable</a>: (AIR + GROUND) The task makes the controllable/unit a FAC and orders the FAC to control the target (enemy ground controllable) destruction.</li>
|
||||
<li><a href="##(CONTROLLABLE).TaskFAC_AttackGroup">CONTROLLABLE.TaskFAC_AttackGroup</a>: (AIR + GROUND) The task makes the controllable/unit a FAC and orders the FAC to control the target (enemy ground controllable) destruction.</li>
|
||||
<li><a href="##(CONTROLLABLE).TaskFireAtPoint">CONTROLLABLE.TaskFireAtPoint</a>: (GROUND) Fire some or all ammunition at a VEC2 point.</li>
|
||||
<li><a href="##(CONTROLLABLE).TaskFollow">CONTROLLABLE.TaskFollow</a>: (AIR) Following another airborne controllable.</li>
|
||||
<li><a href="##(CONTROLLABLE).TaskHold">CONTROLLABLE.TaskHold</a>: (GROUND) Hold ground controllable from moving.</li>
|
||||
@@ -1011,7 +1011,7 @@ All en-route tasks have the priority parameter. This is a number (less value - h
|
||||
<li>
|
||||
|
||||
<p><code><em>#boolean AttackQtyLimit </em></code>:
|
||||
(optional) The flag determines how to interpret attackQty parameter. If the flag is true then attackQty is a limit on maximal attack quantity for "AttackControllable" and "AttackUnit" tasks. If the flag is false then attackQty is a desired attack quantity for "Bombing" and "BombingRunway" tasks.</p>
|
||||
(optional) The flag determines how to interpret attackQty parameter. If the flag is true then attackQty is a limit on maximal attack quantity for "AttackGroup" and "AttackUnit" tasks. If the flag is false then attackQty is a desired attack quantity for "Bombing" and "BombingRunway" tasks.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
@@ -2038,7 +2038,7 @@ The Controllable to be attacked.</p>
|
||||
<li>
|
||||
|
||||
<p><code><em>#boolean AttackQtyLimit </em></code>:
|
||||
(optional) The flag determines how to interpret attackQty parameter. If the flag is true then attackQty is a limit on maximal attack quantity for "AttackControllable" and "AttackUnit" tasks. If the flag is false then attackQty is a desired attack quantity for "Bombing" and "BombingRunway" tasks.</p>
|
||||
(optional) The flag determines how to interpret attackQty parameter. If the flag is true then attackQty is a limit on maximal attack quantity for "AttackGroup" and "AttackUnit" tasks. If the flag is false then attackQty is a desired attack quantity for "Bombing" and "BombingRunway" tasks.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
@@ -2151,6 +2151,7 @@ The UNIT.</p>
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<<<<<<< HEAD
|
||||
<p><code><em><a href="Dcs.DCSTypes.html##(Distance)">Dcs.DCSTypes#Distance</a> Altitude </em></code>:
|
||||
(optional) Desired altitude to perform the unit engagement.</p>
|
||||
|
||||
@@ -2159,6 +2160,10 @@ The UNIT.</p>
|
||||
|
||||
<p><code><em>#boolean Visible </em></code>:
|
||||
(optional) Unit must be visible.</p>
|
||||
=======
|
||||
<p><code><em>#boolean AttackQtyLimit </em></code>:
|
||||
(optional) The flag determines how to interpret attackQty parameter. If the flag is true then attackQty is a limit on maximal attack quantity for "AttackGroup" and "AttackUnit" tasks. If the flag is false then attackQty is a desired attack quantity for "Bombing" and "BombingRunway" tasks.</p>
|
||||
>>>>>>> refs/remotes/origin/master
|
||||
|
||||
</li>
|
||||
<li>
|
||||
@@ -2209,7 +2214,7 @@ The DCS task structure.</p>
|
||||
<li>
|
||||
|
||||
<p><code><em>#number AttackQty </em></code>:
|
||||
(optional) Desired quantity of passes. The parameter is not the same in AttackControllable and AttackUnit tasks. </p>
|
||||
(optional) Desired quantity of passes. The parameter is not the same in AttackGroup and AttackUnit tasks. </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
@@ -72,8 +72,7 @@
|
||||
<div id="content">
|
||||
<h1>Module <code>Event</code></h1>
|
||||
|
||||
<p>This core module models the dispatching of DCS Events to subscribed MOOSE classes,
|
||||
following a given priority.</p>
|
||||
<p><strong>Core</strong> - EVENT models DCS <strong>event dispatching</strong> using a <strong>publish-subscribe</strong> model.</p>
|
||||
|
||||
|
||||
|
||||
@@ -145,6 +144,13 @@ There are two functions which you use to subscribe to or unsubscribe from an eve
|
||||
<li><a href="Base.html##(BASE).UnHandleEvent">Base#BASE.UnHandleEvent</a>(): Unsubscribe from a DCS Event.</li>
|
||||
</ul>
|
||||
|
||||
<p>Note that for a UNIT, the event will be handled <strong>for that UNIT only</strong>!
|
||||
Note that for a GROUP, the event will be handled <strong>for all the UNITs in that GROUP only</strong>!</p>
|
||||
|
||||
<p>For all objects of other classes, the subscribed events will be handled for <strong>all UNITs within the Mission</strong>!
|
||||
So if a UNIT within the mission has the subscribed event for that object,
|
||||
then the object event handler will receive the event for that UNIT!</p>
|
||||
|
||||
<h3>1.3.2 Event Handling of DCS Events</h3>
|
||||
|
||||
<p>Once the class is subscribed to the event, an <strong>Event Handling</strong> method on the object or class needs to be written that will be called
|
||||
@@ -241,7 +247,8 @@ YYYY-MM-DD: CLASS:<strong>NewFunction( Params )</strong> added</p>
|
||||
<p>Hereby the change log:</p>
|
||||
|
||||
<ul>
|
||||
<li>2016-02-07: Did a complete revision of the Event Handing API and underlying mechanisms.</li>
|
||||
<li><p>2017-03-07: Added the correct event dispatching in case the event is subscribed by a GROUP.</p></li>
|
||||
<li><p>2017-02-07: Did a complete revision of the Event Handing API and underlying mechanisms.</p></li>
|
||||
</ul>
|
||||
|
||||
<hr/>
|
||||
@@ -341,15 +348,49 @@ YYYY-MM-DD: CLASS:<strong>NewFunction( Params )</strong> added</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<<<<<<< HEAD
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).OnEventForTemplate">EVENT:OnEventForTemplate(EventTemplate, EventFunction, EventClass, OnEventFunction, EventID)</a></td>
|
||||
=======
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).OnEngineShutDownForUnit">EVENT:OnEngineShutDownForUnit(EventDCSUnitName, EventFunction, EventClass)</a></td>
|
||||
<td class="summary">
|
||||
<p>Set a new listener for an S<em>EVENT</em>ENGINE_SHUTDOWN event.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).OnEngineShutDownRemove">EVENT:OnEngineShutDownRemove(EventClass)</a></td>
|
||||
<td class="summary">
|
||||
<p>Stop listening to S<em>EVENT</em>ENGINE_SHUTDOWN event.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).OnEngineStartUpForUnit">EVENT:OnEngineStartUpForUnit(EventDCSUnitName, EventFunction, EventClass)</a></td>
|
||||
<td class="summary">
|
||||
<p>Set a new listener for an S<em>EVENT</em>ENGINE_STARTUP event.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).OnEngineStartUpRemove">EVENT:OnEngineStartUpRemove(EventClass)</a></td>
|
||||
<td class="summary">
|
||||
<p>Stop listening to S<em>EVENT</em>ENGINE_STARTUP event.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).OnEventForGroup">EVENT:OnEventForGroup(GroupName, EventFunction, EventClass, EventID)</a></td>
|
||||
<td class="summary">
|
||||
<p>Set a new listener for an S<em>EVENT</em>X event for a GROUP.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).OnEventForTemplate">EVENT:OnEventForTemplate(EventTemplate, EventFunction, EventClass, OnEventFunction)</a></td>
|
||||
>>>>>>> refs/remotes/origin/master
|
||||
<td class="summary">
|
||||
<p>Create an OnDead event handler for a group</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).OnEventForUnit">EVENT:OnEventForUnit(EventDCSUnitName, EventFunction, EventClass, EventID)</a></td>
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).OnEventForUnit">EVENT:OnEventForUnit(UnitName, EventFunction, EventClass, EventID)</a></td>
|
||||
<td class="summary">
|
||||
<p>Set a new listener for an S<em>EVENT</em>X event</p>
|
||||
<p>Set a new listener for an S<em>EVENT</em>X event for a UNIT.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -383,9 +424,15 @@ YYYY-MM-DD: CLASS:<strong>NewFunction( Params )</strong> added</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).RemoveForUnit">EVENT:RemoveForUnit(EventClass, EventID, UnitName)</a></td>
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).RemoveForGroup">EVENT:RemoveForGroup(GroupName, EventClass, EventID)</a></td>
|
||||
<td class="summary">
|
||||
<p>Removes an Events entry for a Unit</p>
|
||||
<p>Removes an Events entry for a GROUP.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(EVENT).RemoveForUnit">EVENT:RemoveForUnit(UnitName, EventClass, EventID)</a></td>
|
||||
<td class="summary">
|
||||
<p>Removes an Events entry for a UNIT.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -1254,8 +1301,828 @@ The self instance of the class for which the event is captured. When the event h
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<<<<<<< HEAD
|
||||
<a id="#(EVENT).OnLandForTemplate" >
|
||||
<strong>EVENT:OnLandForTemplate(EventTemplate, EventFunction, EventClass)</strong>
|
||||
=======
|
||||
<a id="#(EVENT).OnDeadForTemplate" >
|
||||
<strong>EVENT:OnDeadForTemplate(EventGroup, EventFunction, EventClass, EventTemplate)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Create an OnDead event handler for a group</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Wrapper.Group.html##(GROUP)">Wrapper.Group#GROUP</a> EventGroup </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> EventTemplate </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnDeadForUnit" >
|
||||
<strong>EVENT:OnDeadForUnit(EventDCSUnitName, EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>DEAD event.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string EventDCSUnitName </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnDeadRemove" >
|
||||
<strong>EVENT:OnDeadRemove(EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Stop listening to S<em>EVENT</em>DEAD event.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnEngineShutDownForTemplate" >
|
||||
<strong>EVENT:OnEngineShutDownForTemplate(EventTemplate, EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Create an OnDead event handler for a group</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#table EventTemplate </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnEngineShutDownForUnit" >
|
||||
<strong>EVENT:OnEngineShutDownForUnit(EventDCSUnitName, EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>ENGINE_SHUTDOWN event.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string EventDCSUnitName </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnEngineShutDownRemove" >
|
||||
<strong>EVENT:OnEngineShutDownRemove(EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Stop listening to S<em>EVENT</em>ENGINE_SHUTDOWN event.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnEngineStartUpForUnit" >
|
||||
<strong>EVENT:OnEngineStartUpForUnit(EventDCSUnitName, EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>ENGINE_STARTUP event.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string EventDCSUnitName </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnEngineStartUpRemove" >
|
||||
<strong>EVENT:OnEngineStartUpRemove(EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Stop listening to S<em>EVENT</em>ENGINE_STARTUP event.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnEventForGroup" >
|
||||
<strong>EVENT:OnEventForGroup(GroupName, EventFunction, EventClass, EventID)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>X event for a GROUP.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string GroupName </em></code>:
|
||||
The name of the GROUP.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the GROUP.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Core.Base.html##(BASE)">Core.Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> EventID </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnEventForTemplate" >
|
||||
<strong>EVENT:OnEventForTemplate(EventTemplate, EventFunction, EventClass, OnEventFunction)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Create an OnDead event handler for a group</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#table EventTemplate </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> EventClass </em></code>:
|
||||
The instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function OnEventFunction </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnEventForUnit" >
|
||||
<strong>EVENT:OnEventForUnit(UnitName, EventFunction, EventClass, EventID)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>X event for a UNIT.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string UnitName </em></code>:
|
||||
The name of the UNIT.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the GROUP.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Core.Base.html##(BASE)">Core.Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> EventID </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnEventGeneric" >
|
||||
<strong>EVENT:OnEventGeneric(EventFunction, EventClass, EventID)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>X event independent from a unit or a weapon.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Core.Base.html##(BASE)">Core.Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is captured. When the event happens, the event process will be called in this class provided.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> EventID </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnHit" >
|
||||
<strong>EVENT:OnHit(EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>HIT event.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnHitForUnit" >
|
||||
<strong>EVENT:OnHitForUnit(EventDCSUnitName, EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>HIT event.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string EventDCSUnitName </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnHitRemove" >
|
||||
<strong>EVENT:OnHitRemove(EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Stop listening to S<em>EVENT</em>HIT event.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnLandForTemplate" >
|
||||
<strong>EVENT:OnLandForTemplate(EventTemplate, EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em> EventTemplate </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> EventFunction </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> EventClass </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnLandForUnit" >
|
||||
<strong>EVENT:OnLandForUnit(EventDCSUnitName, EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>LAND event.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string EventDCSUnitName </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnLandRemove" >
|
||||
<strong>EVENT:OnLandRemove(EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Stop listening to S<em>EVENT</em>LAND event.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnPilotDead" >
|
||||
<strong>EVENT:OnPilotDead(EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>PILOT_DEAD event.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnPilotDeadForUnit" >
|
||||
<strong>EVENT:OnPilotDeadForUnit(EventDCSUnitName, EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>PILOT_DEAD event.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string EventDCSUnitName </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnPilotDeadRemove" >
|
||||
<strong>EVENT:OnPilotDeadRemove(EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Stop listening to S<em>EVENT</em>PILOT_DEAD event.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnPlayerEnterRemove" >
|
||||
<strong>EVENT:OnPlayerEnterRemove(EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Stop listening to S<em>EVENT</em>PLAYER<em>ENTER</em>UNIT event.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnPlayerEnterUnit" >
|
||||
<strong>EVENT:OnPlayerEnterUnit(EventFunction, EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Set a new listener for an S<em>EVENT</em>PLAYER<em>ENTER</em>UNIT event.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
The function to be called when the event occurs for the unit.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnPlayerLeaveRemove" >
|
||||
<strong>EVENT:OnPlayerLeaveRemove(EventClass)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Stop listening to S<em>EVENT</em>PLAYER<em>LEAVE</em>UNIT event.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Base.html##(BASE)">Base#BASE</a> EventClass </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT)">#EVENT</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).OnPlayerLeaveUnit" >
|
||||
<strong>EVENT:OnPlayerLeaveUnit(EventFunction, EventClass)</strong>
|
||||
>>>>>>> refs/remotes/origin/master
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
@@ -1369,18 +2236,24 @@ The self instance of the class for which the event is.</p>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).RemoveForUnit" >
|
||||
<strong>EVENT:RemoveForUnit(EventClass, EventID, UnitName)</strong>
|
||||
<a id="#(EVENT).RemoveForGroup" >
|
||||
<strong>EVENT:RemoveForGroup(GroupName, EventClass, EventID)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Removes an Events entry for a Unit</p>
|
||||
<p>Removes an Events entry for a GROUP.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string GroupName </em></code>:
|
||||
The name of the GROUP.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Core.Base.html##(BASE)">Core.Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
@@ -1390,9 +2263,42 @@ The self instance of the class for which the event is.</p>
|
||||
<p><code><em><a href="Dcs.DCSWorld.html##(world.event)">Dcs.DCSWorld#world.event</a> EventID </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(EVENT.Events)">#EVENT.Events</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(EVENT).RemoveForUnit" >
|
||||
<strong>EVENT:RemoveForUnit(UnitName, EventClass, EventID)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Removes an Events entry for a UNIT.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em> UnitName </em></code>: </p>
|
||||
<p><code><em>#string UnitName </em></code>:
|
||||
The name of the UNIT.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Core.Base.html##(BASE)">Core.Base#BASE</a> EventClass </em></code>:
|
||||
The self instance of the class for which the event is.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Dcs.DCSWorld.html##(world.event)">Dcs.DCSWorld#world.event</a> EventID </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
@@ -72,10 +72,10 @@
|
||||
<div id="content">
|
||||
<h1>Module <code>Fsm</code></h1>
|
||||
|
||||
<p>This module contains the <strong>FSM</strong> (<strong>F</strong>inite <strong>S</strong>tate <strong>M</strong>achine) class and derived <strong>FSM_</strong> classes.</p>
|
||||
<p><strong>Core</strong> - The <strong>FSM</strong> (<strong>F</strong>inite <strong>S</strong>tate <strong>M</strong>achine) class and derived <strong>FSM_</strong> classes
|
||||
are design patterns allowing efficient (long-lasting) processes and workflows.</p>
|
||||
|
||||
|
||||
<h2>Finite State Machines (FSM) are design patterns allowing efficient (long-lasting) processes and workflows.</h2>
|
||||
|
||||
<p><img src="..\Presentations\FSM\Dia1.JPG" alt="Banner Image"/></p>
|
||||
|
||||
|
||||
@@ -162,6 +162,9 @@ Use the following Zone validation methods on the group:</p>
|
||||
|
||||
<p>Hereby the change log:</p>
|
||||
|
||||
<p>2017-03-07: GROUP:<strong>HandleEvent( Event, EventFunction )</strong> added. <br/>
|
||||
2017-03-07: GROUP:<strong>UnHandleEvent( Event )</strong> added.</p>
|
||||
|
||||
<p>2017-01-24: GROUP:<strong>SetAIOnOff( AIOnOff )</strong> added. </p>
|
||||
|
||||
<p>2017-01-24: GROUP:<strong>SetAIOn()</strong> added. </p>
|
||||
@@ -376,6 +379,12 @@ Use the following Zone validation methods on the group:</p>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUP).GroupName">GROUP.GroupName</a></td>
|
||||
<td class="summary">
|
||||
<p>The name of the group.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUP).HandleEvent">GROUP:HandleEvent(Event, EventFunction)</a></td>
|
||||
<td class="summary">
|
||||
<p>Subscribe to a DCS Event.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -490,6 +499,12 @@ Use the following Zone validation methods on the group:</p>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUP).SetTemplateCountry">GROUP:SetTemplateCountry(CountryID, Template)</a></td>
|
||||
<td class="summary">
|
||||
<p>Sets the CountryID of the group in a Template.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUP).UnHandleEvent">GROUP:UnHandleEvent(Event)</a></td>
|
||||
<td class="summary">
|
||||
<p>UnSubscribe to a DCS event.</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@@ -1139,6 +1154,38 @@ Current Vec3 of the first DCS Unit of the GROUP.</p>
|
||||
|
||||
<p>The name of the group.</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUP).HandleEvent" >
|
||||
<strong>GROUP:HandleEvent(Event, EventFunction)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Subscribe to a DCS Event.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Core.Event.html##(EVENTS)">Core.Event#EVENTS</a> Event </em></code>: </p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function EventFunction </em></code>:
|
||||
(optional) The function to be called when the event occurs for the GROUP.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(GROUP)">#GROUP</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
@@ -1613,6 +1660,32 @@ The country ID.</p>
|
||||
<p><em>#table:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUP).UnHandleEvent" >
|
||||
<strong>GROUP:UnHandleEvent(Event)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>UnSubscribe to a DCS event.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Core.Event.html##(EVENTS)">Core.Event#EVENTS</a> Event </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(GROUP)">#GROUP</a>:</em></p>
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
<div id="content">
|
||||
<h1>Module <code>Menu</code></h1>
|
||||
|
||||
<p>This module contains the MENU classes.</p>
|
||||
<p><strong>Core</strong> -- MENU_ classes model the definition of <strong>hierarchical menu structures</strong> and <strong>commands for players</strong> within a mission.</p>
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -72,29 +72,49 @@
|
||||
<div id="content">
|
||||
<h1>Module <code>Message</code></h1>
|
||||
|
||||
<p>This module contains the MESSAGE class.</p>
|
||||
<p><strong>Core</strong> - MESSAGE class takes are of the <strong>real-time notifications</strong> and <strong>messages to players</strong> during a simulation.</p>
|
||||
|
||||
|
||||
|
||||
<p><img src="..\Presentations\MESSAGE\Dia1.JPG" alt="Banner Image"/></p>
|
||||
|
||||
<hr/>
|
||||
|
||||
<h1>1) <a href="Message.html##(MESSAGE)">Message#MESSAGE</a> class, extends <a href="Base.html##(BASE)">Base#BASE</a></h1>
|
||||
|
||||
<p>Message System to display Messages to Clients, Coalitions or All.
|
||||
Messages are shown on the display panel for an amount of seconds, and will then disappear.
|
||||
Messages can contain a category which is indicating the category of the message.</p>
|
||||
|
||||
<h2>1.1) MESSAGE construction methods</h2>
|
||||
<h2>1.1) MESSAGE construction</h2>
|
||||
|
||||
<p>Messages are created with <a href="Message.html##(MESSAGE).New">Message#MESSAGE.New</a>. Note that when the MESSAGE object is created, no message is sent yet.
|
||||
To send messages, you need to use the To functions.</p>
|
||||
|
||||
<h2>1.2) Send messages with MESSAGE To methods</h2>
|
||||
<p>Messages are sent to:</p>
|
||||
<h2>1.2) Send messages to an audience</h2>
|
||||
|
||||
<p>Messages are sent:</p>
|
||||
|
||||
<ul>
|
||||
<li>Clients with <a href="Message.html##(MESSAGE).ToClient">Message#MESSAGE.ToClient</a>.</li>
|
||||
<li>Coalitions with <a href="Message.html##(MESSAGE).ToCoalition">Message#MESSAGE.ToCoalition</a>.</li>
|
||||
<li>All Players with <a href="Message.html##(MESSAGE).ToAll">Message#MESSAGE.ToAll</a>.
|
||||
</li>
|
||||
<li>To a <a href="Client.html">Client</a> using <a href="Message.html##(MESSAGE).ToClient">Message#MESSAGE.ToClient</a>().</li>
|
||||
<li>To a <a href="Group.html">Group</a> using <a href="Message.html##(MESSAGE).ToGroup">Message#MESSAGE.ToGroup</a>()</li>
|
||||
<li>To a coalition using <a href="Message.html##(MESSAGE).ToCoalition">Message#MESSAGE.ToCoalition</a>().</li>
|
||||
<li>To the red coalition using <a href="Message.html##(MESSAGE).ToRed">Message#MESSAGE.ToRed</a>().</li>
|
||||
<li>To the blue coalition using <a href="Message.html##(MESSAGE).ToBlue">Message#MESSAGE.ToBlue</a>().</li>
|
||||
<li>To all Players using <a href="Message.html##(MESSAGE).ToAll">Message#MESSAGE.ToAll</a>().</li>
|
||||
</ul>
|
||||
|
||||
<h2>1.3) Send conditionally to an audience</h2>
|
||||
|
||||
<p>Messages can be sent conditionally to an audience (when a condition is true):</p>
|
||||
|
||||
<ul>
|
||||
<li>To all players using <a href="Message.html##(MESSAGE).ToAllIf">Message#MESSAGE.ToAllIf</a>().</li>
|
||||
<li>To a coalition using <a href="Message.html##(MESSAGE).ToCoalitionIf">Message#MESSAGE.ToCoalitionIf</a>().</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
<h2>Global(s)</h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
<div id="content">
|
||||
<h1>Module <code>Point</code></h1>
|
||||
|
||||
<p>This module contains the POINT classes.</p>
|
||||
<p><strong>Core</strong> - <strong>POINT_VEC</strong> classes define an <strong>extensive API</strong> to <strong>manage 3D points</strong> in the simulation space.</p>
|
||||
|
||||
|
||||
|
||||
@@ -1034,6 +1034,22 @@ The new calculated POINT_VEC2.</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(POINT_VEC2).z" >
|
||||
<strong>POINT_VEC2.z</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
>>>>>>> refs/remotes/origin/master
|
||||
|
||||
<h2><a id="#(POINT_VEC3)" >Type <code>POINT_VEC3</code></a></h2>
|
||||
|
||||
|
||||
@@ -544,7 +544,7 @@ Various methods exist to configure:</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(SCORING).ScoreCSV">SCORING:ScoreCSV(PlayerName, ScoreType, ScoreTimes, ScoreAmount, PlayerUnitName, PlayerUnitCoalition, PlayerUnitCategory, PlayerUnitType, TargetUnitName, TargetUnitCoalition, TargetUnitCategory, TargetUnitType)</a></td>
|
||||
<td class="name" nowrap="nowrap"><a href="##(SCORING).ScoreCSV">SCORING:ScoreCSV(PlayerName, TargetPlayerName, ScoreType, ScoreTimes, ScoreAmount, PlayerUnitName, PlayerUnitCoalition, PlayerUnitCategory, PlayerUnitType, TargetUnitName, TargetUnitCoalition, TargetUnitCategory, TargetUnitType)</a></td>
|
||||
<td class="summary">
|
||||
<p>Registers a score for a player.</p>
|
||||
</td>
|
||||
@@ -1604,7 +1604,7 @@ The player group.</p>
|
||||
<dt>
|
||||
|
||||
<a id="#(SCORING).ScoreCSV" >
|
||||
<strong>SCORING:ScoreCSV(PlayerName, ScoreType, ScoreTimes, ScoreAmount, PlayerUnitName, PlayerUnitCoalition, PlayerUnitCategory, PlayerUnitType, TargetUnitName, TargetUnitCoalition, TargetUnitCategory, TargetUnitType)</strong>
|
||||
<strong>SCORING:ScoreCSV(PlayerName, TargetPlayerName, ScoreType, ScoreTimes, ScoreAmount, PlayerUnitName, PlayerUnitCoalition, PlayerUnitCategory, PlayerUnitType, TargetUnitName, TargetUnitCoalition, TargetUnitCategory, TargetUnitType)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
@@ -1621,6 +1621,12 @@ The name of the player.</p>
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string TargetPlayerName </em></code>:
|
||||
The name of the target player.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string ScoreType </em></code>:
|
||||
The type of the score.</p>
|
||||
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
<div id="content">
|
||||
<h1>Module <code>Set</code></h1>
|
||||
|
||||
<p>This module contains the SET classes.</p>
|
||||
<p><strong>Core</strong> - SET classes define <strong>collections</strong> of objects to perform <strong>bulk actions</strong> and logically <strong>group</strong> objects.</p>
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -834,6 +834,12 @@ A coding example is provided at the description of the <a href="##(SPAWN).OnSpaw
|
||||
<td class="name" nowrap="nowrap"><a href="##(SPAWN)._TranslateRotate">SPAWN:_TranslateRotate(SpawnIndex, SpawnRootX, SpawnRootY, SpawnX, SpawnY, SpawnAngle)</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(SPAWN).uncontrolled">SPAWN.uncontrolled</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@@ -2236,7 +2242,7 @@ when nothing was spawned.</p>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em>#number</em>
|
||||
<em></em>
|
||||
<a id="#(SPAWN).SpawnMaxGroups" >
|
||||
<strong>SPAWN.SpawnMaxGroups</strong>
|
||||
</a>
|
||||
@@ -2253,7 +2259,7 @@ when nothing was spawned.</p>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em>#number</em>
|
||||
<em></em>
|
||||
<a id="#(SPAWN).SpawnMaxUnitsAlive" >
|
||||
<strong>SPAWN.SpawnMaxUnitsAlive</strong>
|
||||
</a>
|
||||
@@ -3195,6 +3201,20 @@ True = Continue Scheduler</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em></em>
|
||||
<a id="#(SPAWN).uncontrolled" >
|
||||
<strong>SPAWN.uncontrolled</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
|
||||
@@ -71,9 +71,18 @@
|
||||
<div id="content">
|
||||
<h1>Module <code>Zone</code></h1>
|
||||
|
||||
<<<<<<< HEAD
|
||||
<p>This module contains the ZONE classes, inherited from <a href="Zone.html##(ZONE_BASE)">Zone#ZONE_BASE</a>.</p>
|
||||
|
||||
|
||||
=======
|
||||
<p><strong>Core</strong> - ZONE classes define <strong>zones</strong> within your mission of <strong>various forms</strong>, with <strong>various capabilities</strong>.</p>
|
||||
|
||||
|
||||
|
||||
<hr/>
|
||||
|
||||
>>>>>>> refs/remotes/origin/master
|
||||
<p>There are essentially two core functions that zones accomodate:</p>
|
||||
|
||||
<ul>
|
||||
|
||||
@@ -161,7 +161,7 @@ and automatically engage any airborne enemies that are within a certain range or
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="Base.html">Base</a></td>
|
||||
<td class="summary">
|
||||
<p>This module contains the BASE class.</p>
|
||||
<p><strong>Core</strong> - BASE forms <strong>the basis of the MOOSE framework</strong>.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -232,14 +232,14 @@ and automatically engage any airborne enemies that are within a certain range or
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="Event.html">Event</a></td>
|
||||
<td class="summary">
|
||||
<p>This core module models the dispatching of DCS Events to subscribed MOOSE classes,
|
||||
following a given priority.</p>
|
||||
<p><strong>Core</strong> - EVENT models DCS <strong>event dispatching</strong> using a <strong>publish-subscribe</strong> model.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="Fsm.html">Fsm</a></td>
|
||||
<td class="summary">
|
||||
<p>This module contains the <strong>FSM</strong> (<strong>F</strong>inite <strong>S</strong>tate <strong>M</strong>achine) class and derived <strong>FSM_</strong> classes.</p>
|
||||
<p><strong>Core</strong> - The <strong>FSM</strong> (<strong>F</strong>inite <strong>S</strong>tate <strong>M</strong>achine) class and derived <strong>FSM_</strong> classes
|
||||
are design patterns allowing efficient (long-lasting) processes and workflows.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -257,13 +257,13 @@ following a given priority.</p>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="Menu.html">Menu</a></td>
|
||||
<td class="summary">
|
||||
<p>This module contains the MENU classes.</p>
|
||||
<p><strong>Core</strong> -- MENU_ classes model the definition of <strong>hierarchical menu structures</strong> and <strong>commands for players</strong> within a mission.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="Message.html">Message</a></td>
|
||||
<td class="summary">
|
||||
<p>This module contains the MESSAGE class.</p>
|
||||
<p><strong>Core</strong> - MESSAGE class takes are of the <strong>real-time notifications</strong> and <strong>messages to players</strong> during a simulation.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -293,7 +293,7 @@ following a given priority.</p>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="Point.html">Point</a></td>
|
||||
<td class="summary">
|
||||
<p>This module contains the POINT classes.</p>
|
||||
<p><strong>Core</strong> - <strong>POINT_VEC</strong> classes define an <strong>extensive API</strong> to <strong>manage 3D points</strong> in the simulation space.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -363,7 +363,7 @@ and creates a CSV file logging the scoring events and results for use at team or
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="Set.html">Set</a></td>
|
||||
<td class="summary">
|
||||
<p>This module contains the SET classes.</p>
|
||||
<p><strong>Core</strong> - SET classes define <strong>collections</strong> of objects to perform <strong>bulk actions</strong> and logically <strong>group</strong> objects.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -433,7 +433,7 @@ which are excellent tools to be reused in an OO environment!.</p>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="Zone.html">Zone</a></td>
|
||||
<td class="summary">
|
||||
<p>This core module contains the ZONE classes, inherited from <a href="Zone.html##(ZONE_BASE)">Zone#ZONE_BASE</a>.</p>
|
||||
<p><strong>Core</strong> - ZONE classes define <strong>zones</strong> within your mission of <strong>various forms</strong>, with <strong>various capabilities</strong>.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
||||
BIN
docs/Presentations/BASE/Dia1.JPG
Normal file
BIN
docs/Presentations/BASE/Dia1.JPG
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 216 KiB |
BIN
docs/Presentations/MESSAGE/Dia1.JPG
Normal file
BIN
docs/Presentations/MESSAGE/Dia1.JPG
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 202 KiB |
Reference in New Issue
Block a user