更新修复底板下 方块的状态
This commit is contained in:
parent
07b5355d08
commit
477bc72780
|
|
@ -59,6 +59,11 @@ export default class Boom extends cc.Component {
|
||||||
updateTime() {
|
updateTime() {
|
||||||
if (MapConroler._instance.iceTrue() == true) return;
|
if (MapConroler._instance.iceTrue() == true) return;
|
||||||
if (MapConroler._instance.pause == true) return;
|
if (MapConroler._instance.pause == true) return;
|
||||||
|
if (this.node.parent) {
|
||||||
|
if (this.node.parent.getComponent("Block").block_Info.floor) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
this.time--;
|
this.time--;
|
||||||
NumberToImage.numberToImageNodes(this.time, 20, 8, "lock_", this.node.getChildByName("time"), false);
|
NumberToImage.numberToImageNodes(this.time, 20, 8, "lock_", this.node.getChildByName("time"), false);
|
||||||
if (this.time <= 0) {
|
if (this.time <= 0) {
|
||||||
|
|
|
||||||
|
|
@ -42,6 +42,11 @@ export default class Freeze extends cc.Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
reduce(number) {
|
reduce(number) {
|
||||||
|
if (this.node.parent) {
|
||||||
|
if (this.node.parent.getComponent("Block").block_Info.floor) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
this.time -= number;
|
this.time -= number;
|
||||||
if (this.time <= 0) this.time = 0
|
if (this.time <= 0) this.time = 0
|
||||||
NumberToImage.numberToImageNodes(this.time, 40, 25, "ice_", this.node.getChildByName("time"), false);
|
NumberToImage.numberToImageNodes(this.time, 40, 25, "ice_", this.node.getChildByName("time"), false);
|
||||||
|
|
|
||||||
|
|
@ -109,12 +109,13 @@
|
||||||
{
|
{
|
||||||
"block": 3,
|
"block": 3,
|
||||||
"color": 6,
|
"color": 6,
|
||||||
"type": 0,
|
"type": 6,
|
||||||
"position": {
|
"position": {
|
||||||
"x": 60,
|
"x": 60,
|
||||||
"y": -180,
|
"y": -180,
|
||||||
"z": 0
|
"z": 0
|
||||||
},
|
},
|
||||||
|
"boomTime": 15,
|
||||||
"floor": 2,
|
"floor": 2,
|
||||||
"floorTime": 10,
|
"floorTime": 10,
|
||||||
"id": 270
|
"id": 270
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user