|
@@ -135,23 +135,23 @@ export default class Game_b04_u04_g04 extends GameBase {
|
|
|
/** 开始游戏 */
|
|
|
async startGame() {
|
|
|
// 角色动作
|
|
|
- // let heroId = 0;
|
|
|
- // let dataHero = this.dataQues.dataHero[heroId];
|
|
|
- // let skeHero1 = this.nodeHero.getChildByName('spine' + heroId).getComponent(sp.Skeleton);
|
|
|
- // Tools.playAniArray(skeHero1, [dataHero.task_0, dataHero.task_1, dataHero.idle]);
|
|
|
- // // 音频播放
|
|
|
- // await Tools.playEffect(this.arrAudioTask[0]);
|
|
|
- // // 提示
|
|
|
- // let script = this.nodeTip.getComponent(TipHand);
|
|
|
- // cc.tween(this.node).call(() => {
|
|
|
- // let pStart = Tools.getLocalPos(this.nodeTotal.getChildByName("pStart"), script.nodeTip.parent);
|
|
|
- // script.touchCycleByTimes(pStart, 2);
|
|
|
- // }).delay(2.0).call(() => {
|
|
|
- // let pStart = Tools.getLocalPos(this.nodeTotal.getChildByName("pFinish"), script.nodeTip.parent);
|
|
|
- // script.touchCycleByTimes(pStart, 2);
|
|
|
- // }).start();
|
|
|
- // // 音频播放
|
|
|
- // await Tools.playEffect(this.arrAudioTask[1]);
|
|
|
+ let heroId = 0;
|
|
|
+ let dataHero = this.dataQues.dataHero[heroId];
|
|
|
+ let skeHero1 = this.nodeHero.getChildByName('spine' + heroId).getComponent(sp.Skeleton);
|
|
|
+ Tools.playAniArray(skeHero1, [dataHero.task_0, dataHero.task_1, dataHero.idle]);
|
|
|
+ // 音频播放
|
|
|
+ await Tools.playEffect(this.arrAudioTask[0]);
|
|
|
+ // 提示
|
|
|
+ let script = this.nodeTip.getComponent(TipHand);
|
|
|
+ cc.tween(this.node).call(() => {
|
|
|
+ let pStart = Tools.getLocalPos(this.nodeTotal.getChildByName("pStart"), script.nodeTip.parent);
|
|
|
+ script.touchCycleByTimes(pStart, 2);
|
|
|
+ }).delay(2.0).call(() => {
|
|
|
+ let pStart = Tools.getLocalPos(this.nodeTotal.getChildByName("pFinish"), script.nodeTip.parent);
|
|
|
+ script.touchCycleByTimes(pStart, 2);
|
|
|
+ }).start();
|
|
|
+ // 音频播放
|
|
|
+ await Tools.playEffect(this.arrAudioTask[1]);
|
|
|
this.tipCycleShow();
|
|
|
this.countLunch();
|
|
|
this.nextQuestion();
|