// Learn TypeScript: // - https://docs.cocos.com/creator/2.4/manual/en/scripting/typescript.html // Learn Attribute: // - https://docs.cocos.com/creator/2.4/manual/en/scripting/reference/attributes.html // Learn life-cycle callbacks: // - https://docs.cocos.com/creator/2.4/manual/en/scripting/life-cycle-callbacks.html import { ryw_Event } from "../../FrameWork/Event/EventEnum"; import EventMgr from "../../FrameWork/Event/EventMgr"; import User from "../../FrameWork/User/User"; import Common5 from "../../Platform/th/Common5"; import JuQingManager from "../JuQingChat/JuQingManager"; import TaskManager, { MainTaskIdEnum } from "../JuQingChat/TaskManager"; const {ccclass, property} = cc._decorator; @ccclass export default class WuXingYuanShi extends cc.Component { @property(cc.Node) chadianIcon:cc.Node[] = [] // LIFE-CYCLE CALLBACKS: // onLoad () {} iconArray = ['金','木','水','火','土'] nanzhuSpine:cc.Node = null dazuoSpine:cc.Node = null longzhennanSpine:cc.Node = null rongheSpine:cc.Node = null yuanshiNode:cc.Node = null chooseIndex = 0 start () { this.nanzhuSpine = this.node.getChildByName('男主') this.dazuoSpine = this.node.getChildByName('打坐') this.longzhennanSpine = this.node.getChildByName('龙镇南') // 待机 进场 this.rongheSpine = this.node.getChildByName('融合spine') this.yuanshiNode = this.node.getChildByName('原石背景') EventMgr.onEvent_custom(ryw_Event.RefreshJuQingDuiHua,()=>{ this.scheduleOnce(()=>{ this.endGame() },2.0) },this) EventMgr.onEvent_custom(ryw_Event.NormalTouchMoveCheck,(obj)=>{ this.checkTouchMove(obj) },this) for(let i= 0; i{ this.scheduleOnce(()=>{ this.rongheSpine.active = false this.nanzhuSpine.active = true this.dazuoSpine.active = false Common5.playRemoteSpine( this.nanzhuSpine, 'Spine/roomSpine','男主','男主') this.scheduleOnce(()=>{ this.longzhennanSpine.active = true Common5.playRemoteSpine( this.longzhennanSpine, 'Spine/WuXingYuanShi','龙镇南','进场',false) this.scheduleOnce(()=>{ Common5.playRemoteSpine( this.longzhennanSpine, 'Spine/WuXingYuanShi','龙镇南','待机') JuQingManager.unLockNewJuQing('DH_17') },0.5) },0.5) },1.0) }) } } // update (dt) {} }