Skip to content

Commit 305b296

Browse files
committed
Improve some documentations
1 parent dc3134a commit 305b296

File tree

1 file changed

+36
-46
lines changed

1 file changed

+36
-46
lines changed

CCBoot.js

+36-46
Original file line numberDiff line numberDiff line change
@@ -2081,46 +2081,46 @@ cc.initEngine = function (config, cb) {
20812081
*
20822082
*/
20832083
cc.game = /** @lends cc.game# */{
2084-
/**
2085-
* Debug mode: No debugging. {@static}
2086-
* @const {Number}
2087-
* @static
2088-
*/
2084+
/**
2085+
* Debug mode: No debugging. {@static}
2086+
* @const {Number}
2087+
* @static
2088+
*/
20892089
DEBUG_MODE_NONE: 0,
2090-
/**
2091-
* Debug mode: Info to console.
2092-
* @const {Number}
2093-
* @static
2090+
/**
2091+
* Debug mode: Info, warning, error to console.
2092+
* @const {Number}
2093+
* @static
20942094
*/
20952095
DEBUG_MODE_INFO: 1,
2096-
/**
2097-
* Debug mode: Warning to console.
2098-
* @const {Number}
2099-
* @static
2096+
/**
2097+
* Debug mode: Warning, error to console.
2098+
* @const {Number}
2099+
* @static
21002100
*/
21012101
DEBUG_MODE_WARN: 2,
2102-
/**
2102+
/**
21032103
* Debug mode: Error to console.
2104-
* @const {Number}
2105-
* @static
2104+
* @const {Number}
2105+
* @static
21062106
*/
21072107
DEBUG_MODE_ERROR: 3,
2108-
/**
2109-
* Debug mode: Info to web page.
2110-
* @const {Number}
2111-
* @static
2108+
/**
2109+
* Debug mode: Info, warning, error to web page.
2110+
* @const {Number}
2111+
* @static
21122112
*/
21132113
DEBUG_MODE_INFO_FOR_WEB_PAGE: 4,
2114-
/**
2115-
* Debug mode: Warning to web page.
2116-
* @const {Number}
2117-
* @static
2114+
/**
2115+
* Debug mode: Warning, error to web page.
2116+
* @const {Number}
2117+
* @static
21182118
*/
21192119
DEBUG_MODE_WARN_FOR_WEB_PAGE: 5,
2120-
/**
2120+
/**
21212121
* Debug mode: Error to web page.
2122-
* @const {Number}
2123-
* @static
2122+
* @const {Number}
2123+
* @static
21242124
*/
21252125
DEBUG_MODE_ERROR_FOR_WEB_PAGE: 6,
21262126

@@ -2156,21 +2156,19 @@ cc.game = /** @lends cc.game# */{
21562156
_eventShow: null,
21572157

21582158
/**
2159-
* Keys found in config.json.
2159+
* Keys found in project.json.
21602160
*
21612161
* @constant
21622162
* @type {Object}
21632163
*
2164-
* @prop {String} width
2165-
* @prop {String} height
2166-
* @prop {String} engineDir
2167-
* @prop {String} modules
2168-
* @prop {String} debugMode
2169-
* @prop {String} showFPS
2170-
* @prop {String} frameRate
2171-
* @prop {String} id
2172-
* @prop {String} renderMode
2173-
* @prop {String} jsList
2164+
* @prop {String} engineDir - In debug mode, if you use the whole engine to develop your game, you should specify its relative path with "engineDir".
2165+
* @prop {String} modules - Defines which modules you will need in your game, it's useful only on web
2166+
* @prop {String} debugMode - Debug mode, see DEBUG_MODE_XXX constant definitions.
2167+
* @prop {String} showFPS - Left bottom corner fps information will show when "showFPS" equals true, otherwise it will be hide.
2168+
* @prop {String} frameRate - Sets the wanted frame rate for your game, but the real fps depends on your game implementation and the running environment.
2169+
* @prop {String} id - Sets the id of your canvas element on the web page, it's useful only on web.
2170+
* @prop {String} renderMode - Sets the renderer type, only useful on web, 0: Automatic, 1: Canvas, 2: WebGL
2171+
* @prop {String} jsList - Sets the list of js files in your game.
21742172
*/
21752173
CONFIG_KEY: {
21762174
width: "width",
@@ -2232,14 +2230,6 @@ cc.game = /** @lends cc.game# */{
22322230
*/
22332231
onStop: null,
22342232

2235-
/**
2236-
* Callback when game frame has been sized or resized. called
2237-
* once on game startup.
2238-
*
2239-
* @type {Function|null}
2240-
*/
2241-
onResize: null,
2242-
22432233
//@Public Methods
22442234

22452235
// @Game play control

0 commit comments

Comments
 (0)