This content is provided AS IS for archive purposes only. Content may be out of date with no guarantee of correctness.

HagUpdate... - Main Functions - Hag GUI for Cobra - Static

Main Article

HagUpdate... - Main Functions - Hag GUI for Cobra

This page covers the following procedures: HagUpdateOnce, HagUpdateAll_AutoKeys, HagUpdateAll.

Procedure HagUpdateOnce()

Updates hag logic and forces a render operation on all elements, ensuring they are fully updated and redrawn with any changes.

Procedure HagUpdateAll_AutoKeys()

Calls the procedure HagUpdateAll (see below), automatically supplying the correct key states. Use this instead of HagUpdateAll if you have no wish to selectively deny any input that can apply to the hag GUI.

Procedure HagUpdateAll(leftMouseDown: Boolean, rightMouseClicked: Boolean, returnKeyDown: Boolean, tabKeyHit: Boolean, shiftKeyDown: Boolean, ctrlKeyDown: Boolean, [renderAll: Boolean=False])

HagUpdateAll should be called once every main-loop, before Flip and after any logic such as checking for button presses.

This procedure loops through every visible and enabled gui element, updating them to respond to user input.

Set renderAll to TRUE to force every element to be redrawn (or use HagUpdateOnce - see above).

Example usage:

HagUpdateAll(MouseDown(0), MouseHits(1)>0, KeyDown(VK_RETURN), KeyHits(VK_TAB)>0, KeyDown(VK_LSHIFT) or KeyDown(VK_RSHIFT), KeyDown(VK_LCONTROL) or KeyDown(VK_RCONTROL))

Stay Subscribed

@golightlyb, subscribe to the RSS feed or get updates by e-mail.

You can also contact me directly - I make an effort to reply to every e-mail.