|
| 1 | +declare const DebugPanelPlugin_base: any; |
| 2 | +/** |
| 3 | + * @classdesc |
| 4 | + * a simple debug panel plugin <br> |
| 5 | + * <img src="images/debugPanel.png"/> <br> |
| 6 | + * <b>usage : </b><br> |
| 7 | + * • upon loading the debug panel, it will be automatically registered under me.plugins.debugPanel <br> |
| 8 | + * • you can then press the default "s" key to show or hide the panel, or use me.plugins.debugPanel.show() and me.plugins.debugPanel.show(), or add #debug as a parameter to your URL e.g. http://myURL/index.html#debug <br> |
| 9 | + * • default key can be configured using the following parameters in the url : e.g. http://myURL/index.html#debugToggleKey=d <br> |
| 10 | + * <b>the debug panel provides the following information : </b><br> |
| 11 | + * • amount of total objects currently active in the current stage <br> |
| 12 | + * • amount of draws operation <br> |
| 13 | + * • amount of body shape (for collision) <br> |
| 14 | + * • amount of bounding box <br> |
| 15 | + * • amount of sprites objects <br> |
| 16 | + * • amount of objects currently inactive in the the object pool <br> |
| 17 | + * • memory usage (Heap Memory information is only available under Chrome) <br> |
| 18 | + * • frame update time (in ms) <br> |
| 19 | + * • frame draw time (in ms) <br> |
| 20 | + * • current fps rate vs target fps <br> |
| 21 | + * additionally, using the checkbox in the panel it is also possible to display : <br> |
| 22 | + * • the hitbox or bounding box for all objects <br> |
| 23 | + * • current velocity vector <br> |
| 24 | + * • quadtree spatial visualization <br> |
| 25 | + * @augments plugin.Base |
| 26 | + */ |
| 27 | +export class DebugPanelPlugin extends DebugPanelPlugin_base { |
| 28 | + [x: string]: any; |
| 29 | + constructor(debugToggle: any); |
| 30 | + version: string; |
| 31 | + panel: DebugPanel; |
| 32 | + /** |
| 33 | + * show the debug panel |
| 34 | + */ |
| 35 | + show(): void; |
| 36 | + /** |
| 37 | + * hide the debug panel |
| 38 | + */ |
| 39 | + hide(): void; |
| 40 | + /** |
| 41 | + * toggle the debug panel visibility state |
| 42 | + */ |
| 43 | + toggle(): void; |
| 44 | +} |
| 45 | +import DebugPanel from "./debugPanel"; |
| 46 | +export {}; |
0 commit comments