c99.Game在这个javascript代码中是什么意思?

c99.Game在这个javascript代码中是什么意思?,javascript,Javascript,这是html5游戏教程的一部分。有人能解释一下c99.Game在这种情况下的含义吗 var c99 = {}; c99.Game = (function(){ function Count99Game() { console.log("Starting"); this.canvas = document.getElementById("game-canvas"); this.stage = new createjs.Stage(this.

这是html5游戏教程的一部分。有人能解释一下c99.Game在这种情况下的含义吗

var c99 = {};

c99.Game = (function(){
    function Count99Game() {
        console.log("Starting");
        this.canvas = document.getElementById("game-canvas");
        this.stage = new createjs.Stage(this.canvas);
        this.stage.update();
    }

    return Count99Game;
})();

window.onload = function(){
    var game = new c99.Game()
};
这将设置一个空对象。。。在此上下文中,提供了一种设置排序名称空间的方法

c99.Game = (function(){
这将向c99对象的游戏属性添加一个函数。类似的方法如下:

var c99 = {
    Game: function () {
        /* etc */
    }
};

首先创建一个空对象c99:

var c99 = {}
然后将属性添加到该对象:

c99.Game = ...

它声明为objectit意味着c99的游戏属性?如果你不能说出{}的作用,你应该在教程中退后一点…
c99.Game = ...