// 移动结束回调 protected void onMoveEndHandle(NumAniSeqBase dispObj) { if (m_ptList.Count() > 0 && !m_bDiePt) // 说明还有 WayPoint 可以走 { MazePtBase pt = m_ptList[0]; m_ptList.RemoveAt(0); pt.moveToDestPos(m_mazePlayer); } else // 如果运行到终点位置 { m_ptList.Clear(); if (m_BDiedPlayEffect) { playDieAniAndSound(); } //bool bChangeScene = false; if (!m_bBombPt && !m_bDiePt) // 如果胜利 { //Ctx.m_instance.m_maze.mazeData.mazeScene.show(); //bChangeScene = true; if (Ctx.m_instance.m_maze.mazeData.curSceneIdx == (int)eSceneIndex.eSecond) { Ctx.m_instance.m_maze.mazeData.roomInfo.showLightWin(); Ctx.m_instance.m_maze.mazeData.mazePlayer.hide(); } else { Ctx.m_instance.m_maze.mazeData.mazeScene.showStar(); } } m_bBombPt = false; m_bDiePt = false; m_BDiedPlayEffect = false; Ctx.m_instance.m_uiMgr.loadAndShow(UIFormID.eUIMaze); UIMaze uiMaze = Ctx.m_instance.m_uiMgr.getForm(UIFormID.eUIMaze) as UIMaze; if (uiMaze != null) { uiMaze.toggleResetBtn(true); } string path = ""; path = Path.Combine(Ctx.m_instance.m_cfg.m_pathLst[(int)ResPathType.ePathAudio], "Ground.mp3"); Ctx.m_instance.m_soundMgr.stop(path); path = Path.Combine(Ctx.m_instance.m_cfg.m_pathLst[(int)ResPathType.ePathAudio], "GameOver.mp3"); Ctx.m_instance.m_soundMgr.play(path, false); //if(bChangeScene) //{ // if (Ctx.m_instance.m_maze.mazeData.curSceneIdx == (int)eSceneIndex.eFirst) // { // Ctx.m_instance.m_maze.mazeData.mazeScene.loadSecondScene(); // } //} } }
protected void onAddingEnd(NumAniSeqBase ani) { m_addedList.Add(m_addingItem); adjustPos(); if(m_waitlist.Count > 0) { nextAddingItem(); } else { m_addingItem = null; } }
protected void onAddingEnd(NumAniSeqBase ani) { m_addedList.Add(m_addingItem); adjustPos(); if (m_waitlist.Count > 0) { nextAddingItem(); } else { m_addingItem = null; } }
protected void onMoveEndHandle(NumAniSeqBase dispObj) { // 只要一动结束,就开启动画 if (m_startAni != null) { m_startAni.enable(); } enableWindowTitle(); }
protected void onDownEnd(NumAniSeqBase ani) { }
// 移动结束回调 protected void onMoveEndHandle(NumAniSeqBase dispObj) { if (m_ptList.Count() > 0 && !m_bDiePt) // 说明还有 WayPoint 可以走 { MazePtBase pt = m_ptList[0]; m_ptList.RemoveAt(0); pt.moveToDestPos(m_mazePlayer); } else // 如果运行到终点位置 { m_ptList.Clear(); if(m_BDiedPlayEffect) { playDieAniAndSound(); } //bool bChangeScene = false; if(!m_bBombPt && !m_bDiePt) // 如果胜利 { //Ctx.m_instance.m_maze.mazeData.mazeScene.show(); //bChangeScene = true; if (Ctx.m_instance.m_maze.mazeData.curSceneIdx == (int)eSceneIndex.eSecond) { Ctx.m_instance.m_maze.mazeData.roomInfo.showLightWin(); Ctx.m_instance.m_maze.mazeData.mazePlayer.hide(); } else { Ctx.m_instance.m_maze.mazeData.mazeScene.showStar(); } } m_bBombPt = false; m_bDiePt = false; m_BDiedPlayEffect = false; Ctx.m_instance.m_uiMgr.loadAndShow(UIFormID.eUIMaze); UIMaze uiMaze = Ctx.m_instance.m_uiMgr.getForm(UIFormID.eUIMaze) as UIMaze; if (uiMaze != null) { uiMaze.toggleResetBtn(true); } string path = ""; path = Path.Combine(Ctx.m_instance.m_cfg.m_pathLst[(int)ResPathType.ePathAudio], "Ground.mp3"); Ctx.m_instance.m_soundMgr.stop(path); path = Path.Combine(Ctx.m_instance.m_cfg.m_pathLst[(int)ResPathType.ePathAudio], "GameOver.mp3"); Ctx.m_instance.m_soundMgr.play(path, false); //if(bChangeScene) //{ // if (Ctx.m_instance.m_maze.mazeData.curSceneIdx == (int)eSceneIndex.eFirst) // { // Ctx.m_instance.m_maze.mazeData.mazeScene.loadSecondScene(); // } //} } }