|
| 1 | +# Documentation of PIXI Expansion |
| 2 | + |
| 3 | +## PIXI.input |
| 4 | + |
| 5 | +PIXI.input.getKeyFired(keyString): Returns boolean |
| 6 | + - Returns true if this is the first time it has been called since the key has been pressed. |
| 7 | + |
| 8 | +PIXI.input.getKeyDown(keyString): Returns boolean |
| 9 | + - Returns true if the key is actively pressed down. |
| 10 | + |
| 11 | +PIXI.input.mouseContainer: [DOM Element] |
| 12 | + - Is used to scale the mouse's coordinates to the desired element. |
| 13 | + - USAGE: PIXI.input.mouseContainer = [DOM Element]; |
| 14 | + |
| 15 | +PIXI.getMouseFired(mouseButton): Returns boolean |
| 16 | + - Returns true if this is the first time it has been called since the button has been pressed. |
| 17 | + - NOTE: Mouse buttons are integers 0 (primary, typically left) 1 (middle), and 2 (secondary, typically right). |
| 18 | + |
| 19 | +PIXI.getMouseDown(mouseButton): Returns boolean |
| 20 | + - Returns true if the button is actively pressed down. |
| 21 | + - NOTE: Mouse buttons are integers 0 (primary, typically left) 1 (middle), and 2 (secondary, typically right). |
| 22 | + |
| 23 | +PIXI.getMouseX(): Returns number |
| 24 | + - Returns the last seen mouse X coordinate, where 0.0-1.0 is within the scene horizontally from left to right. |
| 25 | + |
| 26 | +PIXI.getMouseY(): Returns number |
| 27 | + - Returns the last seen mouse Y coordinate, where 0.0-1.0 is within the scene vertically from top to bottom. |
| 28 | + |
| 29 | +## PIXI.collision |
| 30 | + |
| 31 | +PIXI.collision.aabb(a, b): Returns boolean |
| 32 | + - Checks if the two provided objects are colliding with the aabb algorithm |
| 33 | + - NOTE: Both a and b are formatted as a javascript object with x, y, width, and height where (x,y) is the top-leftmost point. |
| 34 | + |
| 35 | +## PIXI.utils |
| 36 | + |
| 37 | +PIXI.utils.openFullScreen(view) |
| 38 | + - The element passed in (typically use the Application view) will attempt to go fullscreen |
0 commit comments