ScummVM API documentation
Titanic::Events Class Reference

Public Member Functions

 Events (TitanicEngine *vm)
 
void addTarget (CEventTarget *target)
 
void removeTarget ()
 
void pollEvents ()
 
void pollEventsAndWait ()
 
uint32 getFrameCounter () const
 
uint32 getTicksCount () const
 
uint32 getTotalPlayTicks () const
 
void setTotalPlayTicks (uint frames)
 
void sleep (uint time)
 
bool waitForPress (uint expiry)
 
Common::Point getMousePos () const
 
void setMousePos (const Common::Point &pt)
 
bool isSpecialPressed (SpecialButtons btn) const
 
uint getSpecialButtons () const
 

Member Function Documentation

◆ addTarget()

void Titanic::Events::addTarget ( CEventTarget target)
inline

Adds a new event target to the top of the list. It will get all events generated until such time as another is pushed on top of it, or the removeTarget method is called

◆ removeTarget()

void Titanic::Events::removeTarget ( )
inline

Removes the currently active event target

◆ pollEvents()

void Titanic::Events::pollEvents ( )

Check for any pending events

◆ pollEventsAndWait()

void Titanic::Events::pollEventsAndWait ( )

Poll for events and introduce a small delay, to allow the system to yield to other running programs

◆ getFrameCounter()

uint32 Titanic::Events::getFrameCounter ( ) const
inline

Return the current game frame number

◆ getTicksCount()

uint32 Titanic::Events::getTicksCount ( ) const

Return the current game ticks

◆ getTotalPlayTicks()

uint32 Titanic::Events::getTotalPlayTicks ( ) const

Get the total number of playtime frames/ticks

◆ setTotalPlayTicks()

void Titanic::Events::setTotalPlayTicks ( uint  frames)

Set the total number of frames/ticks played

◆ sleep()

void Titanic::Events::sleep ( uint  time)

Sleep for a specified period of time

◆ waitForPress()

bool Titanic::Events::waitForPress ( uint  expiry)

Wait for a mouse or keypress

◆ getMousePos()

Common::Point Titanic::Events::getMousePos ( ) const
inline

Get the mouse position

◆ setMousePos()

void Titanic::Events::setMousePos ( const Common::Point pt)

Sets the mouse position

◆ getSpecialButtons()

uint Titanic::Events::getSpecialButtons ( ) const
inline

Returns the bitset of the currently pressed special buttons


The documentation for this class was generated from the following file: