mirror of
https://github.com/photonstorm/phaser
synced 2024-11-27 15:12:18 +00:00
- wrote dot-notated config properties as seperate typedefs
- add some missing properties
This commit is contained in:
parent
c94404986c
commit
fe748e9dc7
1 changed files with 84 additions and 36 deletions
|
@ -26,6 +26,50 @@ var ValueToColor = require('../display/color/ValueToColor');
|
||||||
* @param {Phaser.Game} game - [description]
|
* @param {Phaser.Game} game - [description]
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef {object} InputConfig
|
||||||
|
*
|
||||||
|
* @property {(boolean|KeyboardInputConfig)} [keyboard=true] - [description]
|
||||||
|
* @property {(boolean|MouseInputConfig)} [mouse=true] - [description]
|
||||||
|
* @property {(boolean|TouchInputConfig)} [touch=true] - [description]
|
||||||
|
* @property {(boolean|GamepadInputConfig)} [gamepad=false] - [description]
|
||||||
|
* @property {integer} [activePointers=1] - [description]
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef {object} MouseInputConfig
|
||||||
|
*
|
||||||
|
* @property {*} [target=null] - [description]
|
||||||
|
* @property {boolean} [capture=true] - [description]
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef {object} KeyboardInputConfig
|
||||||
|
*
|
||||||
|
* @property {*} [target=window] - [description]
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef {object} TouchInputConfig
|
||||||
|
*
|
||||||
|
* @property {*} [target=null] - [description]
|
||||||
|
* @property {boolean} [capture=true] - [description]
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef {object} GamepadInputConfig
|
||||||
|
*
|
||||||
|
* @property {*} [target=window] - [description]
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef {object} BannerConfig
|
||||||
|
*
|
||||||
|
* @property {boolean} [hidePhaser=false] - [description]
|
||||||
|
* @property {string} [text='#ffffff'] - [description]
|
||||||
|
* @property {string[]} [background] - [description]
|
||||||
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef {object} FPSConfig
|
* @typedef {object} FPSConfig
|
||||||
*
|
*
|
||||||
|
@ -36,6 +80,22 @@ var ValueToColor = require('../display/color/ValueToColor');
|
||||||
* @property {integer} [panicMax=120] - [description]
|
* @property {integer} [panicMax=120] - [description]
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef {object} RenderConfig
|
||||||
|
*
|
||||||
|
* @property {boolean} [antialias=true] - [description]
|
||||||
|
* @property {boolean} [pixelArt=false] - [description]
|
||||||
|
* @property {boolean} [autoResize=false] - [description]
|
||||||
|
* @property {boolean} [roundPixels=false] - [description]
|
||||||
|
* @property {boolean} [transparent=false] - [description]
|
||||||
|
* @property {boolean} [clearBeforeRender=true] - [description]
|
||||||
|
* @property {boolean} [premultipliedAlpha=true] - [description]
|
||||||
|
* @property {boolean} [preserveDrawingBuffer=false] - [description]
|
||||||
|
* @property {boolean} [failIfMajorPerformanceCaveat=false] - [description]
|
||||||
|
* @property {string} [powerPreference='default'] - "high-performance", "low-power" or "default"
|
||||||
|
* @property {integer} [batchSize=2000] - The default WebGL batch size.
|
||||||
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef {object} ScaleConfig
|
* @typedef {object} ScaleConfig
|
||||||
*
|
*
|
||||||
|
@ -51,6 +111,13 @@ var ValueToColor = require('../display/color/ValueToColor');
|
||||||
* @property {integer} [maxHeight] - The maximum height the canvas can be scaled up to.
|
* @property {integer} [maxHeight] - The maximum height the canvas can be scaled up to.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef {object} CallbacksConfig
|
||||||
|
*
|
||||||
|
* @property {BootCallback} [preBoot=NOOP] - [description]
|
||||||
|
* @property {BootCallback} [postBoot=NOOP] - [description]
|
||||||
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef {object} LoaderConfig
|
* @typedef {object} LoaderConfig
|
||||||
*
|
*
|
||||||
|
@ -72,6 +139,13 @@ var ValueToColor = require('../display/color/ValueToColor');
|
||||||
* @property {boolean} [behindCanvas=false] - Place the DOM Container behind the Phaser Canvas. The default is to place it over the Canvas.
|
* @property {boolean} [behindCanvas=false] - Place the DOM Container behind the Phaser Canvas. The default is to place it over the Canvas.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef {object} ImagesConfig
|
||||||
|
*
|
||||||
|
* @property {string} [default] - [description]
|
||||||
|
* @property {string} [missing] - [description]
|
||||||
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef {object} PluginObjectItem
|
* @typedef {object} PluginObjectItem
|
||||||
*
|
*
|
||||||
|
@ -110,42 +184,16 @@ var ValueToColor = require('../display/color/ValueToColor');
|
||||||
* @property {string} [url='http://phaser.io'] - [description]
|
* @property {string} [url='http://phaser.io'] - [description]
|
||||||
* @property {string} [version=''] - [description]
|
* @property {string} [version=''] - [description]
|
||||||
* @property {boolean} [autoFocus=true] - Automatically call window.focus() when the game boots.
|
* @property {boolean} [autoFocus=true] - Automatically call window.focus() when the game boots.
|
||||||
* @property {(boolean|object)} [input] - [description]
|
* @property {(boolean|InputConfig)} [input] - [description]
|
||||||
* @property {boolean} [input.keyboard=true] - [description]
|
|
||||||
* @property {*} [input.keyboard.target=window] - [description]
|
|
||||||
* @property {(boolean|object)} [input.mouse=true] - [description]
|
|
||||||
* @property {*} [input.mouse.target=null] - [description]
|
|
||||||
* @property {boolean} [input.touch=true] - [description]
|
|
||||||
* @property {integer} [input.activePointers=1] - [description]
|
|
||||||
* @property {*} [input.touch.target=null] - [description]
|
|
||||||
* @property {boolean} [input.touch.capture=true] - [description]
|
|
||||||
* @property {(boolean|object)} [input.gamepad=false] - [description]
|
|
||||||
* @property {boolean} [disableContextMenu=false] - [description]
|
* @property {boolean} [disableContextMenu=false] - [description]
|
||||||
* @property {(boolean|object)} [banner=false] - [description]
|
* @property {(boolean|BannerConfig)} [banner=false] - [description]
|
||||||
* @property {boolean} [banner.hidePhaser=false] - [description]
|
|
||||||
* @property {string} [banner.text='#ffffff'] - [description]
|
|
||||||
* @property {string[]} [banner.background] - [description]
|
|
||||||
* @property {DOMContainerConfig} [dom] - The DOM Container configuration object.
|
* @property {DOMContainerConfig} [dom] - The DOM Container configuration object.
|
||||||
* @property {FPSConfig} [fps] - [description]
|
* @property {FPSConfig} [fps] - [description]
|
||||||
* @property {boolean} [render.antialias=true] - [description]
|
* @property {RenderConfig} [render] - [description]
|
||||||
* @property {boolean} [render.pixelArt=false] - [description]
|
|
||||||
* @property {boolean} [render.autoResize=false] - [description]
|
|
||||||
* @property {boolean} [render.roundPixels=false] - [description]
|
|
||||||
* @property {boolean} [render.transparent=false] - [description]
|
|
||||||
* @property {boolean} [render.clearBeforeRender=true] - [description]
|
|
||||||
* @property {boolean} [render.premultipliedAlpha=true] - [description]
|
|
||||||
* @property {boolean} [render.preserveDrawingBuffer=false] - [description]
|
|
||||||
* @property {boolean} [render.failIfMajorPerformanceCaveat=false] - [description]
|
|
||||||
* @property {string} [render.powerPreference='default'] - "high-performance", "low-power" or "default"
|
|
||||||
* @property {integer} [render.batchSize=2000] - The default WebGL batch size.
|
|
||||||
* @property {(string|number)} [backgroundColor=0x000000] - [description]
|
* @property {(string|number)} [backgroundColor=0x000000] - [description]
|
||||||
* @property {object} [callbacks] - [description]
|
* @property {CallbacksConfig} [callbacks] - [description]
|
||||||
* @property {BootCallback} [callbacks.preBoot=NOOP] - [description]
|
|
||||||
* @property {BootCallback} [callbacks.postBoot=NOOP] - [description]
|
|
||||||
* @property {LoaderConfig} [loader] - [description]
|
* @property {LoaderConfig} [loader] - [description]
|
||||||
* @property {object} [images] - [description]
|
* @property {ImagesConfig} [images] - [description]
|
||||||
* @property {string} [images.default] - [description]
|
|
||||||
* @property {string} [images.missing] - [description]
|
|
||||||
* @property {object} [physics] - [description]
|
* @property {object} [physics] - [description]
|
||||||
* @property {PluginObject|PluginObjectItem[]} [plugins] - [description]
|
* @property {PluginObject|PluginObjectItem[]} [plugins] - [description]
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in a new issue