Class R.struct.MouseInfo
Extends
R.engine.PooledObject.
An object which contains information about the mouse in relation to
a rendering context.
Defined in: mouseinfo.js.
Constructor Attributes | Constructor Name and Description |
---|---|
Creates a mouse data structure.
|
Field Attributes | Field Name and Description |
---|---|
The currently pressed mouse button.
|
|
The position at which a mouse button was pressed
|
|
A normalized vector indicating the direction of mouse movement after a
button was pressed and held.
|
|
The game object the mouse is currently over
|
|
The last mouse position
|
|
A vector indicating the direction and amount of mouse movement.
|
|
The current mouse position
|
Method Attributes | Method Name and Description |
---|---|
destroy()
Destroy the collision data object.
|
|
release()
Release the collision data object back into the pool for reuse.
|
- Methods borrowed from class R.engine.PooledObject:
- clearObjectDataModel, getId, getName, getObjectDataModel, getProperties, isDestroyed, setName, setObjectDataModel, toString, toXML
Field Detail
button
The currently pressed mouse button. See R.engine.Events
downPosition
The position at which a mouse button was pressed
dragVec
A normalized vector indicating the direction of mouse movement after a
button was pressed and held.
lastOver
The game object the mouse is currently over
lastPosition
The last mouse position
moveVec
A vector indicating the direction and amount of mouse movement.
position
The current mouse position
Method Detail
destroy()
Destroy the collision data object.
release()
Release the collision data object back into the pool for reuse.