Commit 75521c9a authored by zjz1994's avatar zjz1994

游戏结束不动

parent 466a18aa
...@@ -3119,6 +3119,7 @@ export default class MainScene extends Scene { ...@@ -3119,6 +3119,7 @@ export default class MainScene extends Scene {
//如果早已通关,正在结算 //如果早已通关,正在结算
if(this.hasPassed) { if(this.hasPassed) {
console.log("结算检测---------------------弹窗检测3");
//如果原先特效还有, //如果原先特效还有,
if(!this.isCountingTime) { if(!this.isCountingTime) {
this.terminateSteps(); this.terminateSteps();
...@@ -3127,6 +3128,7 @@ export default class MainScene extends Scene { ...@@ -3127,6 +3128,7 @@ export default class MainScene extends Scene {
else { else {
//通关了 //通关了
//提交分数等 //提交分数等
console.log("结算检测---------------------弹窗检测4");
var json = this.getSubmitJson() var json = this.getSubmitJson()
this.submit(json) this.submit(json)
} }
...@@ -3171,6 +3173,7 @@ export default class MainScene extends Scene { ...@@ -3171,6 +3173,7 @@ export default class MainScene extends Scene {
this.effectContinuityTimes = 0; this.effectContinuityTimes = 0;
//判断步数是否为0; //判断步数是否为0;
if(this.steps == 0) { if(this.steps == 0) {
console.log("结算检测---------------------失败弹窗检测1");
//失败弹框 //失败弹框
// playSound(SoundType.fail); // playSound(SoundType.fail);
var panelsDatas = this.returnPanels("failed", {level: this.chapter}) var panelsDatas = this.returnPanels("failed", {level: this.chapter})
...@@ -3183,14 +3186,18 @@ export default class MainScene extends Scene { ...@@ -3183,14 +3186,18 @@ export default class MainScene extends Scene {
//额外加一步ai果冻的操作,考虑和气泡一起改变,然后再执行检查死图 //额外加一步ai果冻的操作,考虑和气泡一起改变,然后再执行检查死图
let count = 0; let count = 0;
let countAll = 2;//和操作步数一致 let countAll = 2;//和操作步数一致
if(!this._checkMtag.jellymo){
countAll -= 1;
}
if(!this._checkMtag.bubble){
countAll -= 1;
}
if(this._checkMtag.jellymo){ if(this._checkMtag.jellymo){
this._checkMtag.jellymo = false; this._checkMtag.jellymo = false;
//果冻的先执行,因为有元素类型的改变,会影响变色气泡的动画 //果冻的先执行,因为有元素类型的改变,会影响变色气泡的动画
AiControl.ins.jellyMotion(this, () => { AiControl.ins.jellyMotion(this, () => {
if(++count === countAll) this.aiMotionCheckDieMap() if(++count === countAll) this.aiMotionCheckDieMap()
}) })
}else{
countAll -= 1;
} }
//然后执行气泡 //然后执行气泡
...@@ -3199,8 +3206,6 @@ export default class MainScene extends Scene { ...@@ -3199,8 +3206,6 @@ export default class MainScene extends Scene {
AiControl.ins.bubbleMotion(this, () => { AiControl.ins.bubbleMotion(this, () => {
if(++count === countAll) this.aiMotionCheckDieMap() if(++count === countAll) this.aiMotionCheckDieMap()
}) })
}else{
countAll -= 1;
} }
if(countAll==0){ if(countAll==0){
...@@ -3488,6 +3493,7 @@ export default class MainScene extends Scene { ...@@ -3488,6 +3493,7 @@ export default class MainScene extends Scene {
showToast("元素已无法消除") showToast("元素已无法消除")
setTimeout(() => { setTimeout(() => {
// playSound(SoundType.fail); // playSound(SoundType.fail);
console.log("结算检测---------------------失败弹窗检测2");
var panelsDatas = this.returnPanels("failed", {level: this.chapter}) var panelsDatas = this.returnPanels("failed", {level: this.chapter})
PanelCtrl.instance.showPanels(panelsDatas[0], panelsDatas[1], () => { PanelCtrl.instance.showPanels(panelsDatas[0], panelsDatas[1], () => {
}); });
...@@ -4311,6 +4317,7 @@ export default class MainScene extends Scene { ...@@ -4311,6 +4317,7 @@ export default class MainScene extends Scene {
this.score += 1000 * this.steps; this.score += 1000 * this.steps;
this.steps = 0; this.steps = 0;
var json = this.getSubmitJson() var json = this.getSubmitJson()
console.log("结算检测---------------------弹窗检测5");
this.submit(json) this.submit(json)
return return
} }
......
...@@ -146,4 +146,43 @@ export const Chapters26: ChapterData[] = [ ...@@ -146,4 +146,43 @@ export const Chapters26: ChapterData[] = [
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0 0, 0, 0, 0, 0, 0, 0, 0, 0
], recycles: [], generateLats: [ { index: 0, type: null }, { index: 1, type: null }, { index: 2, type: null }, { index: 3, type: null }, { index: 4, type: null }, { index: 5, type: null }, { index: 6, type: null }, { index: 7, type: null }, { index: 8, type: null } ] } }, ], recycles: [], generateLats: [ { index: 0, type: null }, { index: 1, type: null }, { index: 2, type: null }, { index: 3, type: null }, { index: 4, type: null }, { index: 5, type: null }, { index: 6, type: null }, { index: 7, type: null }, { index: 8, type: null } ] } },
]
//671
{ baseElementTypes: [ 1, 2, 3, 4 ], bubbleProbability: 0,
stepCount: 24, passTarget: { type: 1, elements: [ { type: 9, count: 73 }, { type: 1, count: 99 } ] }, starScores: [ 15000, 20000, 25000 ], map: {
lattices: [
3, 3, 3, 3, 3, 3, 3, 3, 3,
3, 3, 3, 3, 3, 3, 3, 3, 3,
0, 1, 3, 1, 3, 1, 3, 1, 0,
0, 3, 3, 3, 3, 3, 3, 3, 0,
6, 3, 6, 3, 6, 3, 6, 3, 6,
3, 3, 3, 3, 3, 3, 3, 3, 3,
3, 3, 3, 3, 3, 3, 3, 3, 3,
3, 61, 3, 61, 3, 61, 3, 61, 3,
3, 3, 3, 3, 3, 3, 3, 3, 3
], connectedLats: [], conveyor: [],
conveyorConnectedLats: [], WORMHOLE: [
[ 19, 21, 23, 25 ] ],
elements: [
1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 13, 1, 1, 1, 13, 1, 1, 1,
1, 22, 1, 22, 1, 22, 1, 22, 1,
1, 22, 1, 22, 1, 22, 1, 22, 1,
1, 23, 23, 1, 1, 1, 23, 23, 1,
1, 23, 23, 1, 1, 1, 23, 23, 1,
1, 1, 2, 2, 2, 2, 2, 1, 1,
2, 2, 2, 2, 2, 2, 2, 2, 2 ],
baseElements: [
0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0
], recycles: [], generateLats: [ { index: 0, type: null }, { index: 1, type: null }, { index: 2, type: null }, { index: 3, type: null }, { index: 4, type: null }, { index: 5, type: null }, { index: 6, type: null }, { index: 7, type: null }, { index: 8, type: null }, { index: 36, type: null }, { index: 44, type: null } ] } },
]
...@@ -112,11 +112,11 @@ export class Element extends eui.Component { ...@@ -112,11 +112,11 @@ export class Element extends eui.Component {
const mv: any = initSvga(getFireworksVideoItem()); const mv: any = initSvga(getFireworksVideoItem());
this._fireworks = mv; this._fireworks = mv;
mv.anchorOffsetX = 340 / 2; mv.anchorOffsetX = 340 / 2;
mv.anchorOffsetY = 500; mv.anchorOffsetY = 540;
} }
this._fireworks.x = this.x; this._fireworks.x = this.x;
this._fireworks.y = this.y - 38; this._fireworks.y = this.y + 12;
thisobj.addChild(this._fireworks); thisobj.addChild(this._fireworks);
this._fireworks.gotoAndStop(1); this._fireworks.gotoAndStop(1);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment