- User Interface
- Status Bar
- Game Link
- Export Data
- Built-in Scripts
- API Reference
- Standard Library
- Interface Toolkit
- Technical Reference
This helper class adds support for a text mode mouse cursor.
Create the singleton instance of the
UITextCursor class. During creation the number of display columns will be stored, so make sure to set the correct display mode prior to calling.
Destroy the singleton instance of the
Hide the cursor. Always call this when drawing to the display to prevent graphical corruption.
true if the cursor has moved (or left/entered the screen) since the last call to
Show the cursor again if it's hidden.
Returns the state of the cursor. If the cursor is off-screen or hidden the class method returns
null, otherwise it returns a table with the following slots:
||The x position of the cursor in characters (relative to the top-left of the console)
Note: Manual scrolling of the console is ignored. Using
||The y position of the cursor in characters (relative to the top-left of the console).|
||If the left mouse button is pressed/held, bit 0 is set.
If the right mouse button is pressed/held, bit 1 is set.
If the middle mouse button is pressed/held, bit 2 is set.
||Trigger bits for mouse buttons. Will set bits corresponding to the mouse button that was just clicked.|
||Release trigger bits for mouse buttons. Will set bits corresponding to the mouse button that was just released.|
Update the text cursor internal state and draw it on the screen.