mirror of
https://github.com/FlightControl-Master/MOOSE_DOCS.git
synced 2025-08-15 10:37:49 +00:00
Auto commit by GitHub Actions Workflow
This commit is contained in:
@@ -1693,7 +1693,7 @@
|
||||
|
||||
<hr/>
|
||||
|
||||
<h3>Features:</h3>
|
||||
<h2>Features:</h2>
|
||||
|
||||
<ul>
|
||||
<li>Setup mission sub menus.</li>
|
||||
@@ -1717,12 +1717,12 @@
|
||||
<li>Provide a great tool to manage menus in your code.</li>
|
||||
</ul>
|
||||
|
||||
<p>DCS Menus can be managed using the MENU classes.
|
||||
The advantage of using MENU classes is that it hides the complexity of dealing with menu management in more advanced scenarios where you need to
|
||||
<p>DCS Menus can be managed using the MENU classes.
|
||||
The advantage of using MENU classes is that it hides the complexity of dealing with menu management in more advanced scenarios where you need to
|
||||
set menus and later remove them, and later set them again. You'll find while using use normal DCS scripting functions, that setting and removing
|
||||
menus is not a easy feat if you have complex menu hierarchies defined.
|
||||
menus is not a easy feat if you have complex menu hierarchies defined.
|
||||
Using the MOOSE menu classes, the removal and refreshing of menus are nicely being handled within these classes, and becomes much more easy.
|
||||
On top, MOOSE implements <strong>variable parameter</strong> passing for command menus. </p>
|
||||
On top, MOOSE implements <strong>variable parameter</strong> passing for command menus.</p>
|
||||
|
||||
<p>There are basically two different MENU class types that you need to use:</p>
|
||||
|
||||
@@ -1743,12 +1743,16 @@ On top, MOOSE implements <strong>variable parameter</strong> passing for command
|
||||
</ul>
|
||||
|
||||
<hr/>
|
||||
<p>- </p>
|
||||
|
||||
<h3><a href="https://github.com/FlightControl-Master/MOOSE_Demos/tree/master/Core/Menu">Demo Missions</a></h3>
|
||||
|
||||
<hr/>
|
||||
|
||||
<h3>Author: <strong>FlightControl</strong></h3>
|
||||
<h3>Contributions:</h3>
|
||||
|
||||
<hr/>
|
||||
<p> </p>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="w3-container w3-theme-d2"><h2><strong>Global(s)</strong></h2></div>
|
||||
@@ -1826,7 +1830,7 @@ Using this object reference, you can then remove ALL the menus and submenus unde
|
||||
end
|
||||
|
||||
local function AddStatusMenu()
|
||||
|
||||
|
||||
-- This would create a menu for the red coalition under the MenuCoalitionRed menu object.
|
||||
MenuStatus = MENU_COALITION:New( coalition.side.RED, "Status for Planes" )
|
||||
MenuStatusShow = MENU_COALITION_COMMAND:New( coalition.side.RED, "Show Status", MenuStatus, ShowStatus, "Status of planes is ok!", "Message to Red Coalition" )
|
||||
@@ -1834,7 +1838,7 @@ Using this object reference, you can then remove ALL the menus and submenus unde
|
||||
|
||||
local MenuAdd = MENU_COALITION_COMMAND:New( coalition.side.RED, "Add Status Menu", MenuCoalitionRed, AddStatusMenu )
|
||||
local MenuRemove = MENU_COALITION_COMMAND:New( coalition.side.RED, "Remove Status Menu", MenuCoalitionRed, RemoveStatusMenu )
|
||||
</code></pre>
|
||||
</code></pre>
|
||||
|
||||
</div>
|
||||
|
||||
@@ -1871,7 +1875,7 @@ Using this object reference, you can then remove ALL the menus and submenus unde
|
||||
<tr>
|
||||
<td class="style="width:40%;"><p><h2>Global <strong>MENU_COMMAND_BASE</strong></h2></p></td>
|
||||
<td class="style="width:60%;">
|
||||
<p>Defines the main MENU class where other MENU COMMAND_
|
||||
<p>Defines the main MENU class where other MENU COMMAND_
|
||||
classes are derived from, in order to set commands.</p>
|
||||
|
||||
</td>
|
||||
@@ -1884,7 +1888,7 @@ classes are derived from, in order to set commands.</p>
|
||||
<a href="##(MENU_COMMAND_BASE)">#MENU_COMMAND_BASE</a>
|
||||
<a id="MENU_COMMAND_BASE" ><strong>MENU_COMMAND_BASE</strong></a>
|
||||
|
||||
<p>Defines the main MENU class where other MENU COMMAND_
|
||||
<p>Defines the main MENU class where other MENU COMMAND_
|
||||
classes are derived from, in order to set commands.</p>
|
||||
|
||||
|
||||
@@ -1921,7 +1925,7 @@ Using this object reference, you can then remove ALL the menus and submenus unde
|
||||
-- To test, join the planes, then look at the other radio menus (Option F10).
|
||||
-- Then switch planes and check if the menu is still there.
|
||||
-- And play with the Add and Remove menu options.
|
||||
|
||||
|
||||
-- Note that in multi player, this will only work after the DCS groups bug is solved.
|
||||
|
||||
local function ShowStatus( PlaneGroup, StatusText, Coalition )
|
||||
@@ -2247,7 +2251,7 @@ Using this object reference, you can then remove ALL the menus and submenus unde
|
||||
<tr class="w3-border">
|
||||
<td class="name w3-half w3-container" style="word-wrap: break-word"><p><a href="##(MENU_COALITION_COMMAND).SetCommandMenuArguments">MENU_COALITION_COMMAND:SetCommandMenuArguments(CommandMenuArguments)</a></p></td>
|
||||
<td class="summary w3-half w3-container" style="word-wrap: break-word">
|
||||
<p>This sets the new command arguments of a menu,
|
||||
<p>This sets the new command arguments of a menu,
|
||||
so that if a menu is regenerated, or if command arguments change,
|
||||
that the arguments set for the menu are loosely coupled with the menu itself!!!
|
||||
If the arguments change, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -2256,7 +2260,7 @@ If the arguments change, no new menu needs to be generated if the menu text is t
|
||||
<tr class="w3-border">
|
||||
<td class="name w3-half w3-container" style="word-wrap: break-word"><p><a href="##(MENU_COALITION_COMMAND).SetCommandMenuFunction">MENU_COALITION_COMMAND:SetCommandMenuFunction(CommandMenuFunction)</a></p></td>
|
||||
<td class="summary w3-half w3-container" style="word-wrap: break-word">
|
||||
<p>This sets the new command function of a menu,
|
||||
<p>This sets the new command function of a menu,
|
||||
so that if a menu is regenerated, or if command function changes,
|
||||
that the function set for the menu is loosely coupled with the menu itself!!!
|
||||
If the function changes, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -2290,7 +2294,7 @@ If the function changes, no new menu needs to be generated if the menu text is t
|
||||
<tr class="w3-border">
|
||||
<td class="name w3-half w3-container" style="word-wrap: break-word"><p><a href="##(MENU_COMMAND_BASE).SetCommandMenuArguments">MENU_COMMAND_BASE:SetCommandMenuArguments(CommandMenuArguments)</a></p></td>
|
||||
<td class="summary w3-half w3-container" style="word-wrap: break-word">
|
||||
<p>This sets the new command arguments of a menu,
|
||||
<p>This sets the new command arguments of a menu,
|
||||
so that if a menu is regenerated, or if command arguments change,
|
||||
that the arguments set for the menu are loosely coupled with the menu itself!!!
|
||||
If the arguments change, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -2299,7 +2303,7 @@ If the arguments change, no new menu needs to be generated if the menu text is t
|
||||
<tr class="w3-border">
|
||||
<td class="name w3-half w3-container" style="word-wrap: break-word"><p><a href="##(MENU_COMMAND_BASE).SetCommandMenuFunction">MENU_COMMAND_BASE:SetCommandMenuFunction(CommandMenuFunction)</a></p></td>
|
||||
<td class="summary w3-half w3-container" style="word-wrap: break-word">
|
||||
<p>This sets the new command function of a menu,
|
||||
<p>This sets the new command function of a menu,
|
||||
so that if a menu is regenerated, or if command function changes,
|
||||
that the function set for the menu is loosely coupled with the menu itself!!!
|
||||
If the function changes, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -2472,7 +2476,7 @@ If the function changes, no new menu needs to be generated if the menu text is t
|
||||
<tr class="w3-border">
|
||||
<td class="name w3-half w3-container" style="word-wrap: break-word"><p><a href="##(MENU_GROUP_COMMAND).SetCommandMenuArguments">MENU_GROUP_COMMAND:SetCommandMenuArguments(CommandMenuArguments)</a></p></td>
|
||||
<td class="summary w3-half w3-container" style="word-wrap: break-word">
|
||||
<p>This sets the new command arguments of a menu,
|
||||
<p>This sets the new command arguments of a menu,
|
||||
so that if a menu is regenerated, or if command arguments change,
|
||||
that the arguments set for the menu are loosely coupled with the menu itself!!!
|
||||
If the arguments change, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -2481,7 +2485,7 @@ If the arguments change, no new menu needs to be generated if the menu text is t
|
||||
<tr class="w3-border">
|
||||
<td class="name w3-half w3-container" style="word-wrap: break-word"><p><a href="##(MENU_GROUP_COMMAND).SetCommandMenuFunction">MENU_GROUP_COMMAND:SetCommandMenuFunction(CommandMenuFunction)</a></p></td>
|
||||
<td class="summary w3-half w3-container" style="word-wrap: break-word">
|
||||
<p>This sets the new command function of a menu,
|
||||
<p>This sets the new command function of a menu,
|
||||
so that if a menu is regenerated, or if command function changes,
|
||||
that the function set for the menu is loosely coupled with the menu itself!!!
|
||||
If the function changes, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -2572,7 +2576,7 @@ If the function changes, no new menu needs to be generated if the menu text is t
|
||||
<tr class="w3-border">
|
||||
<td class="name w3-half w3-container" style="word-wrap: break-word"><p><a href="##(MENU_GROUP_COMMAND_DELAYED).SetCommandMenuArguments">MENU_GROUP_COMMAND_DELAYED:SetCommandMenuArguments(CommandMenuArguments)</a></p></td>
|
||||
<td class="summary w3-half w3-container" style="word-wrap: break-word">
|
||||
<p>This sets the new command arguments of a menu,
|
||||
<p>This sets the new command arguments of a menu,
|
||||
so that if a menu is regenerated, or if command arguments change,
|
||||
that the arguments set for the menu are loosely coupled with the menu itself!!!
|
||||
If the arguments change, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -2581,7 +2585,7 @@ If the arguments change, no new menu needs to be generated if the menu text is t
|
||||
<tr class="w3-border">
|
||||
<td class="name w3-half w3-container" style="word-wrap: break-word"><p><a href="##(MENU_GROUP_COMMAND_DELAYED).SetCommandMenuFunction">MENU_GROUP_COMMAND_DELAYED:SetCommandMenuFunction(CommandMenuFunction)</a></p></td>
|
||||
<td class="summary w3-half w3-container" style="word-wrap: break-word">
|
||||
<p>This sets the new command function of a menu,
|
||||
<p>This sets the new command function of a menu,
|
||||
so that if a menu is regenerated, or if command function changes,
|
||||
that the function set for the menu is loosely coupled with the menu itself!!!
|
||||
If the function changes, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -2767,7 +2771,7 @@ If the function changes, no new menu needs to be generated if the menu text is t
|
||||
<tr class="w3-border">
|
||||
<td class="name w3-half w3-container" style="word-wrap: break-word"><p><a href="##(MENU_MISSION_COMMAND).SetCommandMenuArguments">MENU_MISSION_COMMAND:SetCommandMenuArguments(CommandMenuArguments)</a></p></td>
|
||||
<td class="summary w3-half w3-container" style="word-wrap: break-word">
|
||||
<p>This sets the new command arguments of a menu,
|
||||
<p>This sets the new command arguments of a menu,
|
||||
so that if a menu is regenerated, or if command arguments change,
|
||||
that the arguments set for the menu are loosely coupled with the menu itself!!!
|
||||
If the arguments change, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -2776,7 +2780,7 @@ If the arguments change, no new menu needs to be generated if the menu text is t
|
||||
<tr class="w3-border">
|
||||
<td class="name w3-half w3-container" style="word-wrap: break-word"><p><a href="##(MENU_MISSION_COMMAND).SetCommandMenuFunction">MENU_MISSION_COMMAND:SetCommandMenuFunction(CommandMenuFunction)</a></p></td>
|
||||
<td class="summary w3-half w3-container" style="word-wrap: break-word">
|
||||
<p>This sets the new command function of a menu,
|
||||
<p>This sets the new command function of a menu,
|
||||
so that if a menu is regenerated, or if command function changes,
|
||||
that the function set for the menu is loosely coupled with the menu itself!!!
|
||||
If the function changes, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -3337,7 +3341,7 @@ If the function changes, no new menu needs to be generated if the menu text is t
|
||||
<h2><a id="#(MENU_COALITION_COMMAND).SetCommandMenuArguments" ><strong>MENU_COALITION_COMMAND:SetCommandMenuArguments(CommandMenuArguments)</strong></a></h2>
|
||||
</div>
|
||||
|
||||
<p>This sets the new command arguments of a menu,
|
||||
<p>This sets the new command arguments of a menu,
|
||||
so that if a menu is regenerated, or if command arguments change,
|
||||
that the arguments set for the menu are loosely coupled with the menu itself!!!
|
||||
If the arguments change, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -3381,7 +3385,7 @@ If the arguments change, no new menu needs to be generated if the menu text is t
|
||||
<h2><a id="#(MENU_COALITION_COMMAND).SetCommandMenuFunction" ><strong>MENU_COALITION_COMMAND:SetCommandMenuFunction(CommandMenuFunction)</strong></a></h2>
|
||||
</div>
|
||||
|
||||
<p>This sets the new command function of a menu,
|
||||
<p>This sets the new command function of a menu,
|
||||
so that if a menu is regenerated, or if command function changes,
|
||||
that the function set for the menu is loosely coupled with the menu itself!!!
|
||||
If the function changes, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -3527,7 +3531,7 @@ If the function changes, no new menu needs to be generated if the menu text is t
|
||||
<h2><a id="#(MENU_COMMAND_BASE).SetCommandMenuArguments" ><strong>MENU_COMMAND_BASE:SetCommandMenuArguments(CommandMenuArguments)</strong></a></h2>
|
||||
</div>
|
||||
|
||||
<p>This sets the new command arguments of a menu,
|
||||
<p>This sets the new command arguments of a menu,
|
||||
so that if a menu is regenerated, or if command arguments change,
|
||||
that the arguments set for the menu are loosely coupled with the menu itself!!!
|
||||
If the arguments change, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -3571,7 +3575,7 @@ If the arguments change, no new menu needs to be generated if the menu text is t
|
||||
<h2><a id="#(MENU_COMMAND_BASE).SetCommandMenuFunction" ><strong>MENU_COMMAND_BASE:SetCommandMenuFunction(CommandMenuFunction)</strong></a></h2>
|
||||
</div>
|
||||
|
||||
<p>This sets the new command function of a menu,
|
||||
<p>This sets the new command function of a menu,
|
||||
so that if a menu is regenerated, or if command function changes,
|
||||
that the function set for the menu is loosely coupled with the menu itself!!!
|
||||
If the function changes, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -4297,7 +4301,7 @@ If the function changes, no new menu needs to be generated if the menu text is t
|
||||
<h2><a id="#(MENU_GROUP_COMMAND).SetCommandMenuArguments" ><strong>MENU_GROUP_COMMAND:SetCommandMenuArguments(CommandMenuArguments)</strong></a></h2>
|
||||
</div>
|
||||
|
||||
<p>This sets the new command arguments of a menu,
|
||||
<p>This sets the new command arguments of a menu,
|
||||
so that if a menu is regenerated, or if command arguments change,
|
||||
that the arguments set for the menu are loosely coupled with the menu itself!!!
|
||||
If the arguments change, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -4341,7 +4345,7 @@ If the arguments change, no new menu needs to be generated if the menu text is t
|
||||
<h2><a id="#(MENU_GROUP_COMMAND).SetCommandMenuFunction" ><strong>MENU_GROUP_COMMAND:SetCommandMenuFunction(CommandMenuFunction)</strong></a></h2>
|
||||
</div>
|
||||
|
||||
<p>This sets the new command function of a menu,
|
||||
<p>This sets the new command function of a menu,
|
||||
so that if a menu is regenerated, or if command function changes,
|
||||
that the function set for the menu is loosely coupled with the menu itself!!!
|
||||
If the function changes, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -4796,7 +4800,7 @@ If the function changes, no new menu needs to be generated if the menu text is t
|
||||
<h2><a id="#(MENU_GROUP_COMMAND_DELAYED).SetCommandMenuArguments" ><strong>MENU_GROUP_COMMAND_DELAYED:SetCommandMenuArguments(CommandMenuArguments)</strong></a></h2>
|
||||
</div>
|
||||
|
||||
<p>This sets the new command arguments of a menu,
|
||||
<p>This sets the new command arguments of a menu,
|
||||
so that if a menu is regenerated, or if command arguments change,
|
||||
that the arguments set for the menu are loosely coupled with the menu itself!!!
|
||||
If the arguments change, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -4840,7 +4844,7 @@ If the arguments change, no new menu needs to be generated if the menu text is t
|
||||
<h2><a id="#(MENU_GROUP_COMMAND_DELAYED).SetCommandMenuFunction" ><strong>MENU_GROUP_COMMAND_DELAYED:SetCommandMenuFunction(CommandMenuFunction)</strong></a></h2>
|
||||
</div>
|
||||
|
||||
<p>This sets the new command function of a menu,
|
||||
<p>This sets the new command function of a menu,
|
||||
so that if a menu is regenerated, or if command function changes,
|
||||
that the function set for the menu is loosely coupled with the menu itself!!!
|
||||
If the function changes, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -5514,7 +5518,7 @@ If the function changes, no new menu needs to be generated if the menu text is t
|
||||
<h2><a id="#(MENU_MISSION_COMMAND).SetCommandMenuArguments" ><strong>MENU_MISSION_COMMAND:SetCommandMenuArguments(CommandMenuArguments)</strong></a></h2>
|
||||
</div>
|
||||
|
||||
<p>This sets the new command arguments of a menu,
|
||||
<p>This sets the new command arguments of a menu,
|
||||
so that if a menu is regenerated, or if command arguments change,
|
||||
that the arguments set for the menu are loosely coupled with the menu itself!!!
|
||||
If the arguments change, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
@@ -5558,7 +5562,7 @@ If the arguments change, no new menu needs to be generated if the menu text is t
|
||||
<h2><a id="#(MENU_MISSION_COMMAND).SetCommandMenuFunction" ><strong>MENU_MISSION_COMMAND:SetCommandMenuFunction(CommandMenuFunction)</strong></a></h2>
|
||||
</div>
|
||||
|
||||
<p>This sets the new command function of a menu,
|
||||
<p>This sets the new command function of a menu,
|
||||
so that if a menu is regenerated, or if command function changes,
|
||||
that the function set for the menu is loosely coupled with the menu itself!!!
|
||||
If the function changes, no new menu needs to be generated if the menu text is the same!!!</p>
|
||||
|
||||
Reference in New Issue
Block a user