Added mouse functions to doc/api.md

This commit is contained in:
rxi
2016-09-24 11:47:23 +01:00
parent 10bdc31e00
commit 203639380d

View File

@@ -6,6 +6,7 @@
* [love.graphics](#lovegraphics)
* [love.timer](#lovetimer)
* [love.keyboard](#lovekeyboard)
* [love.mouse](#lovemouse)
##### [Objects](#objects-1)
* [Image](#image)
@@ -179,6 +180,21 @@ callbacks are called.
Returns true if the key of the given scancode is currently down.
### love.mouse
##### love.mouse.getPosition()
Returns 2 values: the current horizontal and vertical position of the mouse.
##### love.mouse.getX()
Returns the horizontal position of the mouse.
##### love.mouse.getY()
Returns the vertical position of the mouse.
##### love.mouse.isDown(button, ...)
Returns true if any of the given mouse buttons are currently pressed. `button`
should be the value `1` (left), `2` (right) or `3` (middle).
## Objects
### Image
A loaded image or canvas which can be drawn.