HintMenu class | hintsys.t[462]

A hint menu. This same class can be used for the top-level hints menu and for sub-menus within the hints menu.

The typical hint menu system will be structured into a top-level hint menu that contains a set of sub-menus for the main areas of the game; each sub-menu will have a series of Goal items, each Goal providing a set of answers to a particular question. Something like this:

topHintMenu: TopHintMenu 'Hints';
+ HintMenu 'General Questions';
++ Goal 'What am I supposed to be doing?' [answer, answer, answer];
++ Goal 'Amusing things to try' [thing, thing, thing];
+ HintMenu 'First Area';
++ Goal 'How do I get past the shark?' [answer, answer, answer];
++ Goal 'How do I open the fish tank?' [answer, answer, answer];
+ HintMenu 'Second Area';
++ Goal 'Where is the gold key?' [answer, answer, answer];
++ Goal 'How do I unlock the gold door?' [answer, answer, answer];

Note that there's no requirement that the hint menu tree takes exactly this shape. A very small game could dispense with the submenus and simply put all of the goals directly in the top hint menu. A very large game with lots of goals could add more levels of sub-menus to make it easier to navigate the large number of topics.

`class HintMenu : MenuItem HintMenuObject`

Superclass Tree (in declaration order)

`HintMenu`
`MenuItem`
`MenuObject`
`object`
`HintMenuObject`
`object`

Subclass Tree

`HintMenu`
`TopHintMenu`

Global Objects

(none)

Summary of Properties

`allContents isActiveInMenu title`

Inherited from `MenuItem` :
`bgcolor curKeyList curMenu fgcolor fullScreenMode heading indent isOpen keyList prevMenuLink topbarbg topbarfg topMenu`

Inherited from `MenuObject` :
`contents menuOrder`

Inherited from `HintMenuObject` :
`topicOrder`

Summary of Methods

`addToContents initializeContents updateContents`

Inherited from `MenuItem` :
`display enterSubMenu formatXML getChildIndex getKeysXML getNextMenu getPrevMenu getXML refreshTopMenuBanner removeStatusLine removeTopMenuBanner showMenu showMenuHtml showMenuText showTopMenuBanner`

Inherited from `MenuObject` :
`compareForMenuSort execute initializeLocation`

Inherited from `HintMenuObject` :
`compareForTopicSort`

Properties

`allContents` | `hintsys.t[517]`

our list of all of our sub-items (some of which may not be active, in which case they'll appear in this list but not in our 'contents' list, which contains only active contents)

`isActiveInMenu` | `hintsys.t[492]`

we're active in a menu if we have any active contents

`title` OVERRIDDEN | `hintsys.t[464]`

the menu's title

Methods

`addToContents (obj)`OVERRIDDEN | `hintsys.t[495]`

add a sub-item to our contents

`initializeContents ( )`OVERRIDDEN | `hintsys.t[505]`

initialize our contents list

`updateContents ( )`OVERRIDDEN | `hintsys.t[467]`

update our contents

Adv3Lite Library Reference Manual
Generated on 02/05/2024 from adv3Lite version 2.0