Commit e4fededc authored by zjz1994's avatar zjz1994

解决石头阻挡横纵向消除影响的bug

parent ea080f98
...@@ -2288,7 +2288,6 @@ export default class MainScene extends Scene { ...@@ -2288,7 +2288,6 @@ export default class MainScene extends Scene {
this.score += scoreAll; this.score += scoreAll;
this.oneStepScore += scoreAll; this.oneStepScore += scoreAll;
// console.log(this.score) // console.log(this.score)
//this.eliminatedElements已为0;对有特效的特殊处理,又会添加进eliminatedElements, //this.eliminatedElements已为0;对有特效的特殊处理,又会添加进eliminatedElements,
//必须在上面得分动效后,因为下面这波重新出现的元素要在下一次出现 //必须在上面得分动效后,因为下面这波重新出现的元素要在下一次出现
this.effectEliminate(effectIndexs); this.effectEliminate(effectIndexs);
...@@ -3100,8 +3099,8 @@ export default class MainScene extends Scene { ...@@ -3100,8 +3099,8 @@ export default class MainScene extends Scene {
// } // }
//新增石头阻挡 //新增石头阻挡
var elimitarr = this.getEliHorPassCannoStone(row,lat.column); var elimitarr = this.getEliHorPassCannoStone(row,lat.column);
for(var j=0;j<elimitarr.length;j++){ for(var j1=0;j1<elimitarr.length;j1++){
var jelidx = elimitarr[j]; var jelidx = elimitarr[j1];
var jlat = this.lattices[jelidx]; var jlat = this.lattices[jelidx];
if(this.eliminatedElements.indexOf(jelidx)==-1&&effectIndexs.indexOf(jelidx)==-1){ if(this.eliminatedElements.indexOf(jelidx)==-1&&effectIndexs.indexOf(jelidx)==-1){
this.eliminatedElements.push(jelidx); this.eliminatedElements.push(jelidx);
...@@ -3136,8 +3135,8 @@ export default class MainScene extends Scene { ...@@ -3136,8 +3135,8 @@ export default class MainScene extends Scene {
// } // }
// } // }
var elimitarr = this.getEliVerPassCannoStone(lat.row,col); var elimitarr = this.getEliVerPassCannoStone(lat.row,col);
for(var j=0;j<elimitarr.length;j++){ for(var j1=0;j1<elimitarr.length;j1++){
var jelidx = elimitarr[j]; var jelidx = elimitarr[j1];
var jlat = this.lattices[jelidx]; var jlat = this.lattices[jelidx];
if(this.eliminatedElements.indexOf(jelidx)==-1&&effectIndexs.indexOf(jelidx)==-1){ if(this.eliminatedElements.indexOf(jelidx)==-1&&effectIndexs.indexOf(jelidx)==-1){
this.eliminatedElements.push(jelidx); this.eliminatedElements.push(jelidx);
......
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