mirror of
https://github.com/photonstorm/phaser
synced 2024-12-21 10:33:35 +00:00
1 line
7.8 KiB
JSON
1 line
7.8 KiB
JSON
|
{"class":{"name":"Phaser.State","extends":"","static":false,"constructor":true,"parameters":[],"help":"This is a base State class which can be extended if you are creating your own game.\\nIt provides quick access to common functions such as the camera, cache, input, match, sound and more."},"consts":[],"methods":{"public":[{"name":"create","static":false,"returns":null,"help":"create is called once preload has completed, this includes the loading of any assets from the Loader.\\nIf you don't have a preload method then create is the first method called in your State.","line":138,"public":true,"protected":false,"private":false,"parameters":[],"inherited":false,"inheritedFrom":""},{"name":"loadRender","static":false,"returns":null,"help":"loadRender is called during the Loader process. This only happens if you've set one or more assets to load in the preload method.\\nThe difference between loadRender and render is that any objects you render in this method you must be sure their assets exist.","line":129,"public":true,"protected":false,"private":false,"parameters":[],"inherited":false,"inheritedFrom":""},{"name":"loadUpdate","static":false,"returns":null,"help":"loadUpdate is called during the Loader process. This only happens if you've set one or more assets to load in the preload method.","line":120,"public":true,"protected":false,"private":false,"parameters":[],"inherited":false,"inheritedFrom":""},{"name":"pauseUpdate","static":false,"returns":null,"help":"pauseUpdate is called while the game is paused instead of preUpdate, update and postUpdate.","line":182,"public":true,"protected":false,"private":false,"parameters":[],"inherited":false,"inheritedFrom":""},{"name":"paused","static":false,"returns":null,"help":"This method will be called if the core game loop is paused.","line":174,"public":true,"protected":false,"private":false,"parameters":[],"inherited":false,"inheritedFrom":""},{"name":"preload","static":false,"returns":null,"help":"preload is called first. Normally you'd use this to load your game assets (or those needed for the current State)\\nYou shouldn't create any objects in this method that require assets that you're also loading in this method, as\\nthey won't yet be available.","line":112,"public":true,"protected":false,"private":false,"parameters":[],"inherited":false,"inheritedFrom":""},{"name":"render","static":false,"returns":null,"help":"Nearly all display objects in Phaser render automatically, you don't need to tell them to render.\\nHowever the render method is called AFTER the game renderer and plugins have rendered, so you're able to do any\\nfinal post-processing style effects here. Note that this happens before plugins postRender takes place.","line":158,"public":true,"protected":false,"private":false,"parameters":[],"inherited":false,"inheritedFrom":""},{"name":"resize","static":false,"returns":null,"help":"If your game is set to Scalemode RESIZE then each time the browser resizes it will call this function, passing in the new width and height.","line":166,"public":true,"protected":false,"private":false,"parameters":[],"inherited":false,"inheritedFrom":""},{"name":"shutdown","static":false,"returns":null,"help":"This method will be called when the State is shutdown (i.e. you switch to another state from this one).","line":190,"public":true,"protected":false,"private":false,"parameters":[],"inherited":false,"inheritedFrom":""},{"name":"update","static":false,"returns":null,"help":"The update method is left empty for your own use.\\nIt is called during the core game loop AFTER debug, physics, plugins and the Stage have had their preUpdate methods called.\\nIf is called BEFORE Stage, Tweens, Sounds, Input, Physics, Particles and Plugins have had their postUpdate methods called.","line":148,"public":true,"protected":false,"private":false,"parameters":[],"inherited":false,"inheritedFrom":""}],"protected":[],"private":[],"static":[]},"properties":{"public":[{"name":"add","type":["Phaser.GameObjectFactory"],"help":"","inlineHelp":"A reference to the GameObjectFactory which can be used to add new
|