Commit 24b122e3 authored by zjz1994's avatar zjz1994

修改石门内河豚的问题

parent 213c27b0
...@@ -5,6 +5,7 @@ import { Tool } from "../something/Tool"; ...@@ -5,6 +5,7 @@ import { Tool } from "../something/Tool";
import { Lattice } from "../something/class/Lattice"; import { Lattice } from "../something/class/Lattice";
import { RecoverName } from "../something/enum/RecoverName"; import { RecoverName } from "../something/enum/RecoverName";
import { StateType } from "../something/enum/StateType"; import { StateType } from "../something/enum/StateType";
import Block from "../something/block/Block";
/** /**
* fish爆炸 * fish爆炸
*/ */
...@@ -15,9 +16,12 @@ export default async (thisObj: MainScene) => { ...@@ -15,9 +16,12 @@ export default async (thisObj: MainScene) => {
for (var i = 0; i < thisObj.lattices.length; i++) { for (var i = 0; i < thisObj.lattices.length; i++) {
const lattice = thisObj.lattices[i] const lattice = thisObj.lattices[i]
if (lattice && lattice.element && lattice.element.type == ElementType.FISH && lattice.element.isNeb) { if (lattice && lattice.element && lattice.element.type == ElementType.FISH && lattice.element.isNeb) {
lattice.element.fishCanEliFlag = true; // console.log("遗漏河豚---",lattice.element.hasState(StateType.BLOCK_LOCK));
indexs.push(lattice.index); if(!lattice.element.hasState(StateType.BLOCK_LOCK)){
thisObj.eliminatedElements.push(lattice.index); lattice.element.fishCanEliFlag = true;
indexs.push(lattice.index);
thisObj.eliminatedElements.push(lattice.index);
}
} }
} }
......
...@@ -72,9 +72,10 @@ export class Element extends eui.Component { ...@@ -72,9 +72,10 @@ export class Element extends eui.Component {
} }
} }
async nextFishState() { async nextFishState() {
// console.log("河豚充能"); // console.log("河豚充能",this.hasState(StateType.BLOCK_LOCK),this.index);
await wait(1000); await wait(1000);
this._fishState++; this._fishState++;
// console.log(this._fishState,this.index);
if (this._fishState == 1) { if (this._fishState == 1) {
this['fish'].toActive(); this['fish'].toActive();
} }
......
...@@ -60,7 +60,7 @@ export default class Food extends eui.Component{ ...@@ -60,7 +60,7 @@ export default class Food extends eui.Component{
var icol:number = [this.usecol,this.userow][inidx]; var icol:number = [this.usecol,this.userow][inidx];
//row和col反了 //row和col反了
console.log(this.type+'食物占位'+inidx+'row:'+irow+';col:'+icol); // console.log(this.type+'食物占位'+inidx+'row:'+irow+';col:'+icol);
this.lockidxs = new Array(); this.lockidxs = new Array();
this.freeidxs = new Array(); this.freeidxs = new Array();
for(var i=0;i<icol;i++){ for(var i=0;i<icol;i++){
...@@ -70,7 +70,7 @@ export default class Food extends eui.Component{ ...@@ -70,7 +70,7 @@ export default class Food extends eui.Component{
this.lockidxs.push(latidx); this.lockidxs.push(latidx);
} }
} }
console.log('解锁idxs',this.lockidxs); // console.log('解锁idxs',this.lockidxs);
this.showImage.rotation = roa; this.showImage.rotation = roa;
......
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