31 lines
573 B
JavaScript
31 lines
573 B
JavaScript
Box = function(){//构造方法
|
|
this.state = -1; //方格状态
|
|
this.sp = -1; //精灵号
|
|
}
|
|
if(typeof(Box.prototype.create) == "undefined"){
|
|
Box.prototype.create = function(sp){//创建方格
|
|
|
|
};
|
|
}
|
|
if(typeof(Box.prototype.init) == "undefined"){
|
|
Box.prototype.init = function(){//初始化方格
|
|
|
|
};
|
|
}
|
|
if(typeof(Box.prototype.clear) == "undefined"){
|
|
Box.prototype.clear = function(){//消除方格
|
|
this.state = -1;
|
|
};
|
|
}
|
|
if(typeof(Box.prototype.change) == "undefined"){
|
|
Box.prototype.change = function(st){//更改方格
|
|
this.state = st;
|
|
};
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|