Event documentation

This commit is contained in:
FlightControl
2017-02-07 13:46:52 +01:00
parent 1441d035d7
commit 20f8a98cf0
10 changed files with 1246 additions and 936 deletions

View File

@@ -262,6 +262,36 @@ It can be notified to go RTB through the <strong>RTB</strong> event.</p>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).Engage">AI_CAS_ZONE:Engage()</a></td>
<td class="summary">
<p>Synchronous Event Trigger for Event Engage.</p>
</td>
</tr>
<tr>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).EngageAltitude">AI_CAS_ZONE.EngageAltitude</a></td>
<td class="summary">
</td>
</tr>
<tr>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).EngageAttackQty">AI_CAS_ZONE.EngageAttackQty</a></td>
<td class="summary">
</td>
</tr>
<tr>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).EngageDirection">AI_CAS_ZONE.EngageDirection</a></td>
<td class="summary">
</td>
</tr>
<tr>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).EngageSpeed">AI_CAS_ZONE.EngageSpeed</a></td>
<td class="summary">
</td>
</tr>
<tr>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).EngageWeaponExpend">AI_CAS_ZONE.EngageWeaponExpend</a></td>
<td class="summary">
</td>
</tr>
<tr>
@@ -301,7 +331,7 @@ It can be notified to go RTB through the <strong>RTB</strong> event.</p>
</td>
</tr>
<tr>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).OnAfterEngage">AI_CAS_ZONE:OnAfterEngage(Controllable, From, Event, To)</a></td>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).OnAfterEngage">AI_CAS_ZONE:OnAfterEngage(Controllable, From, Event, To, EngageSpeed, EngageWeaponExpend, EngageAltitude, EngageAttackQty, EngageDirection)</a></td>
<td class="summary">
<p>OnAfter Transition Handler for Event Engage.</p>
</td>
@@ -331,7 +361,7 @@ It can be notified to go RTB through the <strong>RTB</strong> event.</p>
</td>
</tr>
<tr>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).OnBeforeEngage">AI_CAS_ZONE:OnBeforeEngage(Controllable, From, Event, To)</a></td>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).OnBeforeEngage">AI_CAS_ZONE:OnBeforeEngage(Controllable, From, Event, To, EngageSpeed, EngageWeaponExpend, EngageAltitude, EngageAttackQty, EngageDirection)</a></td>
<td class="summary">
<p>OnBefore Transition Handler for Event Engage.</p>
</td>
@@ -415,7 +445,7 @@ It can be notified to go RTB through the <strong>RTB</strong> event.</p>
</td>
</tr>
<tr>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).onafterEngage">AI_CAS_ZONE:onafterEngage(Controllable, From, Event, To)</a></td>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).onafterEngage">AI_CAS_ZONE:onafterEngage(Controllable, From, Event, To, EngageSpeed, EngageWeaponExpend, EngageAltitude, EngageAttackQty, EngageDirection)</a></td>
<td class="summary">
</td>
@@ -424,6 +454,12 @@ It can be notified to go RTB through the <strong>RTB</strong> event.</p>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).onafterStart">AI_CAS_ZONE:onafterStart(Controllable, From, Event, To)</a></td>
<td class="summary">
<p>onafter State Transition for Event Start.</p>
</td>
</tr>
<tr>
<td class="name" nowrap="nowrap"><a href="##(AI_CAS_ZONE).onafterTarget">AI_CAS_ZONE:onafterTarget(Controllable, From, Event, To)</a></td>
<td class="summary">
</td>
</tr>
<tr>
@@ -569,6 +605,74 @@ It can be notified to go RTB through the <strong>RTB</strong> event.</p>
<p>Synchronous Event Trigger for Event Engage.</p>
</dd>
</dl>
<dl class="function">
<dt>
<a id="#(AI_CAS_ZONE).EngageAltitude" >
<strong>AI_CAS_ZONE.EngageAltitude</strong>
</a>
</dt>
<dd>
</dd>
</dl>
<dl class="function">
<dt>
<em></em>
<a id="#(AI_CAS_ZONE).EngageAttackQty" >
<strong>AI_CAS_ZONE.EngageAttackQty</strong>
</a>
</dt>
<dd>
</dd>
</dl>
<dl class="function">
<dt>
<em></em>
<a id="#(AI_CAS_ZONE).EngageDirection" >
<strong>AI_CAS_ZONE.EngageDirection</strong>
</a>
</dt>
<dd>
</dd>
</dl>
<dl class="function">
<dt>
<a id="#(AI_CAS_ZONE).EngageSpeed" >
<strong>AI_CAS_ZONE.EngageSpeed</strong>
</a>
</dt>
<dd>
</dd>
</dl>
<dl class="function">
<dt>
<em></em>
<a id="#(AI_CAS_ZONE).EngageWeaponExpend" >
<strong>AI_CAS_ZONE.EngageWeaponExpend</strong>
</a>
</dt>
<dd>
</dd>
</dl>
<dl class="function">
@@ -784,7 +888,7 @@ The To State string.</p>
<dt>
<a id="#(AI_CAS_ZONE).OnAfterEngage" >
<strong>AI_CAS_ZONE:OnAfterEngage(Controllable, From, Event, To)</strong>
<strong>AI_CAS_ZONE:OnAfterEngage(Controllable, From, Event, To, EngageSpeed, EngageWeaponExpend, EngageAltitude, EngageAttackQty, EngageDirection)</strong>
</a>
</dt>
<dd>
@@ -816,6 +920,36 @@ The Event string.</p>
<p><code><em>#string To </em></code>:
The To State string.</p>
</li>
<li>
<p><code><em>#number EngageSpeed </em></code>:
(optional) The speed the Group will hold when engaging to the target zone.</p>
</li>
<li>
<p><code><em><a href="Dcs.DCSTypes.html##(AI.Task.WeaponExpend)">Dcs.DCSTypes#AI.Task.WeaponExpend</a> EngageWeaponExpend </em></code>:
(optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.</p>
</li>
<li>
<p><code><em><a href="Dcs.DCSTypes.html##(Distance)">Dcs.DCSTypes#Distance</a> EngageAltitude </em></code>:
(optional) Desired altitude to perform the unit engagement.</p>
</li>
<li>
<p><code><em>#number EngageAttackQty </em></code>:
(optional) This parameter limits maximal quantity of attack. The aicraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aicraft/controllable still have ammo. If not defined the aircraft/controllable will attack target until it will be destroyed or until the aircraft/controllable will run out of ammo.</p>
</li>
<li>
<p><code><em><a href="Dcs.DCSTypes.html##(Azimuth)">Dcs.DCSTypes#Azimuth</a> EngageDirection </em></code>:
(optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.</p>
</li>
</ul>
</dd>
@@ -999,7 +1133,7 @@ Return false to cancel Transition.</p>
<dt>
<a id="#(AI_CAS_ZONE).OnBeforeEngage" >
<strong>AI_CAS_ZONE:OnBeforeEngage(Controllable, From, Event, To)</strong>
<strong>AI_CAS_ZONE:OnBeforeEngage(Controllable, From, Event, To, EngageSpeed, EngageWeaponExpend, EngageAltitude, EngageAttackQty, EngageDirection)</strong>
</a>
</dt>
<dd>
@@ -1032,12 +1166,37 @@ The Event string.</p>
The To State string.</p>
</li>
</ul>
<h3>Return value</h3>
<li>
<p><em>#boolean:</em>
Return false to cancel Transition.</p>
<p><code><em>#number EngageSpeed </em></code>:
(optional) The speed the Group will hold when engaging to the target zone.</p>
</li>
<li>
<p><code><em><a href="Dcs.DCSTypes.html##(AI.Task.WeaponExpend)">Dcs.DCSTypes#AI.Task.WeaponExpend</a> EngageWeaponExpend </em></code>:
(optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.</p>
</li>
<li>
<p><code><em><a href="Dcs.DCSTypes.html##(Distance)">Dcs.DCSTypes#Distance</a> EngageAltitude </em></code>:
(optional) Desired altitude to perform the unit engagement.</p>
</li>
<li>
<p><code><em>#number EngageAttackQty </em></code>:
(optional) This parameter limits maximal quantity of attack. The aicraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aicraft/controllable still have ammo. If not defined the aircraft/controllable will attack target until it will be destroyed or until the aircraft/controllable will run out of ammo.</p>
</li>
<li>
<p><code><em><a href="Dcs.DCSTypes.html##(Azimuth)">Dcs.DCSTypes#Azimuth</a> EngageDirection </em></code>:
(optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.</p>
</li>
</ul>
</dd>
</dl>
<dl class="function">
@@ -1434,13 +1593,83 @@ The To State string.</p>
<dt>
<a id="#(AI_CAS_ZONE).onafterEngage" >
<strong>AI_CAS_ZONE:onafterEngage(Controllable, From, Event, To)</strong>
<strong>AI_CAS_ZONE:onafterEngage(Controllable, From, Event, To, EngageSpeed, EngageWeaponExpend, EngageAltitude, EngageAttackQty, EngageDirection)</strong>
</a>
</dt>
<dd>
<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>
<li>
<p><code><em>#number EngageSpeed </em></code>:
(optional) The speed the Group will hold when engaging to the target zone.</p>
</li>
<li>
<p><code><em><a href="Dcs.DCSTypes.html##(AI.Task.WeaponExpend)">Dcs.DCSTypes#AI.Task.WeaponExpend</a> EngageWeaponExpend </em></code>:
(optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.</p>
</li>
<li>
<p><code><em><a href="Dcs.DCSTypes.html##(Distance)">Dcs.DCSTypes#Distance</a> EngageAltitude </em></code>:
(optional) Desired altitude to perform the unit engagement.</p>
</li>
<li>
<p><code><em>#number EngageAttackQty </em></code>:
(optional) This parameter limits maximal quantity of attack. The aicraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aicraft/controllable still have ammo. If not defined the aircraft/controllable will attack target until it will be destroyed or until the aircraft/controllable will run out of ammo.</p>
</li>
<li>
<p><code><em><a href="Dcs.DCSTypes.html##(Azimuth)">Dcs.DCSTypes#Azimuth</a> EngageDirection </em></code>:
(optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.</p>
</li>
</ul>
</dd>
</dl>
<dl class="function">
<dt>
<a id="#(AI_CAS_ZONE).onafterStart" >
<strong>AI_CAS_ZONE:onafterStart(Controllable, From, Event, To)</strong>
</a>
</dt>
<dd>
<p>onafter State Transition for Event Start.</p>
<h3>Parameters</h3>
<ul>
<li>
@@ -1473,13 +1702,13 @@ The To State string.</p>
<dl class="function">
<dt>
<a id="#(AI_CAS_ZONE).onafterStart" >
<strong>AI_CAS_ZONE:onafterStart(Controllable, From, Event, To)</strong>
<a id="#(AI_CAS_ZONE).onafterTarget" >
<strong>AI_CAS_ZONE:onafterTarget(Controllable, From, Event, To)</strong>
</a>
</dt>
<dd>
<p>onafter State Transition for Event Start.</p>
<h3>Parameters</h3>
<ul>