When ever I run the code below in Cocos 2D HTML or with bindings it seems to not add any of my functions but will add my Variables.
So:
cc.Class.extend({
init: function(isDancing){
this.dancing = isDancing;
},
age : 5,
dance: function(){
return this.dancing;
}
});
becomes :
function anonymous() {
this._super=null;this.age=this.age;
}
Which I will get a undefined error when I try to call, dance().
constructor function is 'ctor'(not 'init')
undefined
undefined
22