js版继承的layer运行时未定义undefined

cityui = cc.Layer.extend({
tableView: null,

ctor: function () {
    //1. call super class's ctor function
    this._super();
    this.init();
},


init: function () {
    this._super();

。。。。。。。。

var CityLayer = cc.Layer.extend({
_ctui:null,
coins:0,

ctor: function () {
    //1. call super class's ctor function
    this._super();
},


init: function () {
    this._super();
    var size = cc.winSize;
    this._ctui = new cityui();
    this.addChild(this._ctui);

。。。。
_onTouchBegan: function (touch, event)
{
if(this._ctui) 这里报错 显示 未定义,求解, undefined

    this._ctui = new cityui();
    this.addChild(this._ctui);   这里可以正常显示

_onTouchBegan: function (touch, event)
{
if(this._ctui)

这里的this不是 你layer。

额 懂了 。