Quantcast
Channel: Cocos中文社区 - 最新帖子
Viewing all articles
Browse latest Browse all 494966

ToggleParticle改写以后出现的一个问题

$
0
0
setInputControl: function(progressBar) {
   var self = this;
   this.node.on('mousedown', function(){
       console.log('mousedown');
       console.log(self); -->控制台里面打印出来是ParitcleControl这个节点
       console.log(this); -->***控制台里面打印出来居然是null,这是为什么啊?**
       self.toggleParticlePlay();
       self.progressBar.progress=0;
       }.bind(this.background));
    
},

Viewing all articles
Browse latest Browse all 494966

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>