Difference between revisions of "AGI Command Reference - Menu Management Commands"

From AGI Wiki
Jump to navigationJump to search
(Blanked the page)
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
[[Tutorials and Guides|Tutorials and Guides Table of Contents]]<br />
 
[[AGI Command Reference|AGI Command Reference Index]]<br />
 
  
<div align="center">
 
Page:
 
[[AGI Command Reference - Arithmetic Commands|1]] |
 
[[AGI Command Reference - Commands to Load and unLoad Resources|2]] |
 
[[AGI Command Reference - Program Control Commands|3]] |
 
[[AGI Command Reference - Object Control Commands|4]] |
 
[[AGI Command Reference - Object Description Commands|5]] |
 
[[AGI Command Reference - Object Motion Control Commands|6]] |
 
[[AGI Command Reference - Inventory Item Management Commands|7]] |
 
[[AGI Command Reference - PIC Resource Management Commands|8]] |
 
[[AGI Command Reference - Sound Resource Management Commands|9]] |
 
[[AGI Command Reference - Text Management Commands|10]] |
 
[[AGI Command Reference - String Management Commands|11]] |
 
[[AGI Command Reference - Initialization Commands|12]] |
 
[[AGI Command Reference - Menu Management Commands|13]] |
 
[[AGI Command Reference - Test Commands|14]] |
 
[[AGI Command Reference - Other Commands|15]] |
 
[[AGI Command Reference - Unknown Commands|16]]
 
</div><br />
 
 
<div align="center"><span style="font-size: 22pt">Menu Management Commands</span><br />
 
''By [[Chris Cromer]]''</div>
 
 
&nbsp;
 
 
Creating your program, you can offer the player a choice using a system of menus. These may be short one-line questions (menu header) with several answers (menu elements), or a prompt to change some of the system parameters, for example, object movement speed. Let us consider these commands.
 
 
&nbsp;
 
 
== set.menu(n); ==
 
 
<blockquote>Message n is used as the header of the menu elements which follow.</blockquote>
 
 
== set.menu.item(n, c); ==
 
 
<blockquote>Message n is used as a menu element, where c is this element's code (a number between 0 and 255).</blockquote>
 
 
== submit.menu(); ==
 
 
<blockquote>Ends menu creation.</blockquote>
 
 
== enable.item(c); disable.item(c); ==
 
 
<blockquote>Enables or disables a menu item with the code c.
 
 
{|
 
|<pre>
 
              |-------- heading
 
              v
 
          -------------------------------
 
          | File                        |
 
          -------------------------------
 
Menu  -- >| Save      |
 
Element    |------------|
 
          | Restore    |
 
          |------------|
 
          |XXXXXXXXXXXX| < - menu element disabled
 
          |------------|  using disable.item
 
          | Quit      |
 
          --------------
 
</pre>
 
|}</blockquote>
 
 
== menu.input(); ==
 
 
<blockquote>If Flag(14) = 1, a menu system is shown on the screen, allowing the user to choose an item. Whether an item with the code c has been chosen can be tested using a command 'controller (c)', where c is the code assigned to the menu item.</blockquote>
 
 
&nbsp;
 
 
<div align="center">
 
Page:
 
[[AGI Command Reference - Arithmetic Commands|1]] |
 
[[AGI Command Reference - Commands to Load and unLoad Resources|2]] |
 
[[AGI Command Reference - Program Control Commands|3]] |
 
[[AGI Command Reference - Object Control Commands|4]] |
 
[[AGI Command Reference - Object Description Commands|5]] |
 
[[AGI Command Reference - Object Motion Control Commands|6]] |
 
[[AGI Command Reference - Inventory Item Management Commands|7]] |
 
[[AGI Command Reference - PIC Resource Management Commands|8]] |
 
[[AGI Command Reference - Sound Resource Management Commands|9]] |
 
[[AGI Command Reference - Text Management Commands|10]] |
 
[[AGI Command Reference - String Management Commands|11]] |
 
[[AGI Command Reference - Initialization Commands|12]] |
 
[[AGI Command Reference - Menu Management Commands|13]] |
 
[[AGI Command Reference - Test Commands|14]] |
 
[[AGI Command Reference - Other Commands|15]] |
 
[[AGI Command Reference - Unknown Commands|16]]
 
</div><br />
 
 
[[Tutorials and Guides|Tutorials and Guides Table of Contents]]<br />
 
[[AGI Command Reference|AGI Command Reference Index]]
 
 
<span style="float: left">[[AGI Command Reference - Initialization Commands|&lt; Previous: Initialization Commands]]</span><span style="float: right">[[AGI Command Reference - Test Commands|Next: Test Commands &gt;]]</span>
 
 
&nbsp;
 
 
[[Category:Logic]]
 
[[Category:Commands]]
 
[[Category:References]]
 
[[Category:Tutorials]]
 
[[Category:Menus]]
 

Latest revision as of 19:53, 22 March 2019