var starObj = function() {this.x;this.y;}
starObj.prototype.init = function() {this.x = 300;this.y = 400;}
starObj.prototype.draw = function() {
console.log(this.x);}
那是没有定义的啊!你没有new 实例化啊