#include <cursor.h>
Public Member Functions | |
| Cursor (AsylumEngine *engine) | |
| void | show () const |
| void | hide () const |
| bool | isHidden () const |
| void | set (ResourceId resourceId, int32 cnt=0, CursorAnimation anim=kCursorAnimationMirror, int32 frames=-1) |
| void | animate () |
| void | setForceHide (bool state) |
| ResourceId | getResourceId () |
| CursorAnimation | getAnimation () |
| const Common::Point | position () const |
Asylum cursors are GraphicResources, and are stored in ResourcePacks, as are all game assets.
| void Asylum::Cursor::show | ( | ) | const |
Show the current cursor
| void Asylum::Cursor::hide | ( | ) | const |
Hide the current cursor
| bool Asylum::Cursor::isHidden | ( | ) | const |
Query if the cursor is hidden.
| void Asylum::Cursor::set | ( | ResourceId | resourceId, |
| int32 | cnt = 0, |
||
| CursorAnimation | anim = kCursorAnimationMirror, |
||
| int32 | frames = -1 |
||
| ) |
Set the current cursor instance to the graphic resource provide. The frames parameter defaults to -1, which in this case means that the frame count should be derived from the graphic resource as opposed to being explicitly set.
| resourceId | Identifier for the resource. |
| cnt | The counter. |
| anim | The animation type |
| frames | The frames. |
| void Asylum::Cursor::animate | ( | ) |
Get the next logical frame from the currently loaded cursorResource and draw it
| const Common::Point Asylum::Cursor::position | ( | ) | const |
Return the cursor's position on the screen