Interface_Active.js 1016 B

12345678910111213141516171819202122232425262728293031323334353637
  1. // Learn cc.Class:
  2. // - https://docs.cocos.com/creator/manual/en/scripting/class.html
  3. // Learn Attribute:
  4. // - https://docs.cocos.com/creator/manual/en/scripting/reference/attributes.html
  5. // Learn life-cycle callbacks:
  6. // - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html
  7. cc.Class({
  8. extends: cc.Component,
  9. properties: {
  10. Click_node: cc.Node,
  11. },
  12. // LIFE-CYCLE CALLBACKS:
  13. onLoad() {},
  14. start() {
  15. this.init();
  16. // this.Click_node.on(cc.Node.EventType.TOUCH_START, function() {
  17. // cc.audioEngine.playEffect(this.UiController.audioArr[0]);
  18. // this.UiController.change_interface(this.UiController.interfacaArr, 0);
  19. // console.log("点击活动");
  20. // this.game.removeAllChildren();
  21. // }, this);
  22. },
  23. // update (dt) {},
  24. init() {
  25. this.game = cc.find("Canvas/Game");
  26. this.UiController = cc.find("Canvas/UiController").getComponent('UiController');
  27. },
  28. });