diff --git a/game/images/Card/Plants/MagneticmuShroom.png b/game/images/Card/Plants/MagnetShroom.png similarity index 100% rename from game/images/Card/Plants/MagneticmuShroom.png rename to game/images/Card/Plants/MagnetShroom.png diff --git a/game/images/Card/Zombies/IDiggerzombie.png b/game/images/Card/Zombies/IDiggerzombie.png new file mode 100644 index 00000000..c2a477b3 Binary files /dev/null and b/game/images/Card/Zombies/IDiggerzombie.png differ diff --git a/game/images/Plants/MagneticmuShroom/0.gif b/game/images/Plants/MagnetShroomOld/0.gif similarity index 100% rename from game/images/Plants/MagneticmuShroom/0.gif rename to game/images/Plants/MagnetShroomOld/0.gif diff --git a/game/images/Plants/MagneticmuShroom/Shrubbery.gif b/game/images/Plants/MagnetShroomOld/Shrubbery.gif similarity index 100% rename from game/images/Plants/MagneticmuShroom/Shrubbery.gif rename to game/images/Plants/MagnetShroomOld/Shrubbery.gif diff --git a/game/images/Plants/MagneticmuShroom/ShrubberyBoom.gif b/game/images/Plants/MagnetShroomOld/ShrubberyBoom.gif similarity index 100% rename from game/images/Plants/MagneticmuShroom/ShrubberyBoom.gif rename to game/images/Plants/MagnetShroomOld/ShrubberyBoom.gif diff --git a/game/images/Plants/Ms/Ms.gif b/game/images/Plants/Ms/Ms.gif new file mode 100644 index 00000000..a7ceb473 Binary files /dev/null and b/game/images/Plants/Ms/Ms.gif differ diff --git a/game/images/Plants/Ms/attack.gif b/game/images/Plants/Ms/attack.gif new file mode 100644 index 00000000..20d948e4 Binary files /dev/null and b/game/images/Plants/Ms/attack.gif differ diff --git a/game/images/Plants/Ms/sle.gif b/game/images/Plants/Ms/sle.gif new file mode 100644 index 00000000..0cb0b019 Binary files /dev/null and b/game/images/Plants/Ms/sle.gif differ diff --git a/game/images/Plants/Ms/sleep.gif b/game/images/Plants/Ms/sleep.gif new file mode 100644 index 00000000..670207e6 Binary files /dev/null and b/game/images/Plants/Ms/sleep.gif differ diff --git a/game/images/Zombies/Diggerzombie/0.gif b/game/images/Zombies/Diggerzombie/0.gif new file mode 100644 index 00000000..25880112 Binary files /dev/null and b/game/images/Zombies/Diggerzombie/0.gif differ diff --git a/game/images/Zombies/Diggerzombie/Attack1.gif b/game/images/Zombies/Diggerzombie/Attack1.gif new file mode 100644 index 00000000..dc2c27f7 Binary files /dev/null and b/game/images/Zombies/Diggerzombie/Attack1.gif differ diff --git a/game/images/Zombies/Diggerzombie/Attack2.gif b/game/images/Zombies/Diggerzombie/Attack2.gif new file mode 100644 index 00000000..c57f4517 Binary files /dev/null and b/game/images/Zombies/Diggerzombie/Attack2.gif differ diff --git a/game/images/Zombies/Diggerzombie/BoomDie.gif b/game/images/Zombies/Diggerzombie/BoomDie.gif new file mode 100644 index 00000000..0f28c40b Binary files /dev/null and b/game/images/Zombies/Diggerzombie/BoomDie.gif differ diff --git a/game/images/Zombies/Diggerzombie/Die.gif b/game/images/Zombies/Diggerzombie/Die.gif new file mode 100644 index 00000000..c1d2e0d2 Binary files /dev/null and b/game/images/Zombies/Diggerzombie/Die.gif differ diff --git a/game/images/Zombies/Diggerzombie/DiggerZombie.gif b/game/images/Zombies/Diggerzombie/DiggerZombie.gif new file mode 100644 index 00000000..25880112 Binary files /dev/null and b/game/images/Zombies/Diggerzombie/DiggerZombie.gif differ diff --git a/game/images/Zombies/Diggerzombie/Down.gif b/game/images/Zombies/Diggerzombie/Down.gif new file mode 100644 index 00000000..97117ebc Binary files /dev/null and b/game/images/Zombies/Diggerzombie/Down.gif differ diff --git a/game/images/Zombies/Diggerzombie/Down1.gif b/game/images/Zombies/Diggerzombie/Down1.gif new file mode 100644 index 00000000..a20f2abe Binary files /dev/null and b/game/images/Zombies/Diggerzombie/Down1.gif differ diff --git a/game/images/Zombies/Diggerzombie/Up.gif b/game/images/Zombies/Diggerzombie/Up.gif new file mode 100644 index 00000000..f4c584d0 Binary files /dev/null and b/game/images/Zombies/Diggerzombie/Up.gif differ diff --git a/game/images/Zombies/Diggerzombie/Walk1.gif b/game/images/Zombies/Diggerzombie/Walk1.gif new file mode 100644 index 00000000..126c8f7f Binary files /dev/null and b/game/images/Zombies/Diggerzombie/Walk1.gif differ diff --git a/game/images/Zombies/Diggerzombie/Walk2.gif b/game/images/Zombies/Diggerzombie/Walk2.gif new file mode 100644 index 00000000..715a8ab5 Binary files /dev/null and b/game/images/Zombies/Diggerzombie/Walk2.gif differ diff --git a/game/images/Zombies/Diggerzombie/Walk3.gif b/game/images/Zombies/Diggerzombie/Walk3.gif new file mode 100644 index 00000000..1e1b4f67 Binary files /dev/null and b/game/images/Zombies/Diggerzombie/Walk3.gif differ diff --git a/game/js/CPlants.js b/game/js/CPlants.js index 1dbdbf81..7840c0fa 100644 --- a/game/js/CPlants.js +++ b/game/js/CPlants.js @@ -10255,3 +10255,172 @@ oFlowerVase = InheritO(CPlants, { return true; }, }); +(oMagnetShroom = InheritO(CPlants, { + EName: "oMagnetShroom", + CName: "MagnetShroom", + width: 102, + beAttackedPointR: 98, + height: 90, + target: -1, + SunNum: 100, + BookHandBack: 2, + SleepGif: 3, + cd: 15, + cotcd: 1000, + night: true, + Tooltip: "可以用磁力吸取僵尸的头盔", + Produce: '磁力菇可以用磁力吸取僵尸的头盔等其它金属物品。

范围:靠近的僵尸
特点:移除僵尸们所有的金属物品
白天睡觉

磁力是一种强大的力量,非常强大,强大到有时都吓到磁力菇自己了。能力越大,责任越大,他不知道自己能否肩负得起这责任。', + InitTrigger: function() {}, + PicArr: [ + "images/Card/Plants/MagnetShroom.png", + "images/Plants/Ms/Ms.gif", + "images/Plants/Ms/Ms.gif", + "images/Plants/Ms/sleep.gif", + ], + getTriggerRange: (R, LX, RX) => [ + [0, oS.W, 0] + ], + AudioArr: ["blover"], + BirthStyle: function(c, d, b, a) { + oS.DKind && + ((c.canTrigger = 0), + (c.Sleep = 1), + (b.childNodes[1].src = c.PicArr[c.SleepGif])); + oSym.addTask( + 1, + function(self) { + self.NormalAttack(); + oSym.addTask(1, arguments.callee, [self]); + }, + [c] + ); + EditEle( + b, { + id: d, + }, + a, + EDPZ + ); + }, + Die: function(a) { + var b = this, + c = b.id; + b.cd = 0; + ClearChild(b.imgnn); + b.target = "die"; + b.oTrigger && oT.delP(b); + b.HP = 0; + delete $P[c]; + delete oGd.$[b.R + "_" + b.C + "_" + b.PKind]; + $P.length -= 1; + !a && ClearChild($(c)); + b.PrivateDie(b); + }, + getTriggerR: (selfR) => [ + selfR - 2 < 1 ? 1 : selfR - 2, + selfR + 2 > oS.R ? oS.R : selfR + 2, + ], + PrivateBirth: function() {}, + Plength: function(pid, zid) { + //判断僵尸是否在磁力菇的攻击范围内 + if (zid.Ifgc != 0 || zid.OrnHP == 0) return 0; + //alert(123); + if ( + zid.EName != "oScreenDoorZombie" && + zid.EName != "oDuckyTubeZombie4" && + zid.EName != "oSmallFootballZombie" && + zid.EName != "oFootballZombie" && + zid.EName != "oDuckyTubeZombie3" && + zid.EName != "oJackinTheBoxZombie" && + zid.EName != "oBucketheadZombie" && + zid.EName != "oDiggerZombie" && + zid.EName != "oIScreenDoorZombie" && + zid.EName != "oIDuckyTubeZombie4" && + zid.EName != "oISmallFootballZombie" && + zid.EName != "oIFootballZombie" && + zid.EName != "oIDuckyTubeZombie3" && + zid.EName != "oIJackinTheBoxZombie" && + zid.EName != "oIBucketheadZombie" && + zid.EName != "oIDiggerZombie" + ) + return 0; + if (Math.abs(zid.R - pid.R) > 2) return 0; + if (Math.abs(zid.X - pid.pixelLeft) > 200) return 0; + return 1; + }, + Plength1: function(pid, zid) { + //计算僵尸和磁力菇之间的距离 + var chang = Math.abs(zid.R - pid.R) * 100; + var kuan = Math.abs(zid.X - GetX(pid.C)); + return Math.sqrt(chang * chang + kuan * kuan); + }, + AttackCheckZ: function() { + //查找僵尸 + var self = this, + z, + otarget, + llen, + lastx; + var Target = -1; + for (z in $Z) { + otarget = $Z[z]; + if (!self.Plength(self, otarget) || otarget.PZ == 0) continue; + if (Target == -1) { + Target = $Z[z]; + continue; + } + llen = self.Plength1(self, otarget); + if (llen < self.Plength1(self, Target)) { + Target = otarget; + } + } + self.target = Target; + if (self.target == -1) return 0; + return 1; + }, + Yesgif: function() { + try { + if (this.cd && $(this.id).childNodes[1].src != "images/Plants/Ms/Ms.gif") + $(this.id).childNodes[1].src = "images/Plants/Ms/Ms.gif"; + } catch (arr) {} + }, + attackzombiest: function(zid) { + if (zid.CName == "矿工僵尸") { + //alert(1); + zid.Stone_of_Sinan_Up(); + } else { + zid.OrnHP = 0; + zid.getHit0(zid, 0, 0); + } + }, + NormalAttack: function() { + //alert(this.canTrigger); + //alert(1); + if (this.AttackCheckZ() && this.cd) { + var self = this; + var id = self.id; + var zid = self.target; + if (zid.Ifgc == 1) return; + zid.Ifgc = 1; + $(id).childNodes[1].src = + "images/Plants/Ms/attack.gif" + "?" + Date.now() + Math.random(); + oSym.addTask( + 80, + function(zid, self) { + self.attackzombiest(zid); + }, + [zid, self] + ); + self.cd = 0; + oSym.addTask( + self.cotcd, + function(id) { + self.target = -1; + self.cd = 1; + self.Yesgif(); + }, + [id] + ); + } + }, + })) diff --git a/game/js/CZombie.js b/game/js/CZombie.js index 694591f2..f9269b49 100644 --- a/game/js/CZombie.js +++ b/game/js/CZombie.js @@ -14066,3 +14066,483 @@ oCBucketheadZombie = InheritO( }, }); })()); + oDiggerZombie = InheritO(OrnNoneZombies, { + EName: "oDiggerZombie", + CName: "Digger Zombie", + Lvl: 4, + SunNum: 125, + HP: 500, + BreakPoint: 70, + width: 167, + height: 170, + GetDTop: 20, + beAttackedPointL: 65, + beAttackedPointR: 90, + OrnHP: 100, + OSpeed: 6, + Speed: 6, + Altitude: 0, // 挖矿 + CardGif: 0, + StandGif: 1, + StaticGif: 2, + NormalGif: 3, + WalkGif0: 3, + WalkGif1: 4, + WalkGif2: 5, + AttackGif: 3, + AttackGif_Up0: 6, + AttackGif_Up1: 7, + HeadGif: 8, + DieGif: 9, + UpGif: 10, + DownGif: 11, + BoomDieGif: 8, + LostHeadGif: 5, + LostHeadAttackGif: 5, + + Produce: '这种僵尸通过挖地来绕过防线。

韧性:
速度:快,而后慢
特点:挖地道,然后在草地的左侧现身
弱点:分裂射手,磁力菇

最近,他一直在听奥特曼的主题曲,据他所述,他好像是在某一处听到这首歌,觉得很好听,于是他现在也不挖土了,天天循环播放这首歌', + BirthCallBack: function(f) { + var e = f.delayT, + d = f.id, + c = (f.Ele = $(d)); + (f.EleShadow = c.firstChild), + (f.EleBody = c.childNodes[1]), + SetHidden(f.EleShadow); + e + ? + oSym.addTask( + e, + function(h, g) { + var i = $Z[h]; + i && ((i.FreeSetbodyTime = 0), SetBlock(g)); + }, + [d, c] + ) : + SetBlock(c); + }, + HeadPosition: [{ + x: 42, + y: 146 + }, { + x: 40, + y: 147 + }, ], + getShadow: function(a) { + return "left:" + a.beAttackedPointL + "px;top:" + (a.height - 20) + "px"; + }, + isUp: 0, + JudgeLR: function(f, d, e, c, g) { + return e > 10 || e < 1 ? + false : + (function() { + d += --e + "_"; + var h = 3, + i; + while (h--) { + if ((i = g[d + h]) && i.canEat) { + return i.AttackedRX >= c && i.AttackedLX <= c ? + [f.id, i.id] : + false; + } + } + })(); + }, + JudgeSR: function(f, d, e, c, g) { + return e > 9 ? + false : + (function() { + d += e + "_"; + var h = 3, + i; + while (h--) { + if ((i = g[d + h]) && i.canEat) { + return i.AttackedRX >= c && i.AttackedLX <= c ? + [f.id, i.id] : + false; + } + } + })(); + }, + PicArr: (function() { + var a = "images/Zombies/Diggerzombie/"; + return [ + "images/Card/Zombies/Diggerzombie.png", + a + "0.gif", + a + "DiggerZombie.gif", + a + "Walk1.gif", + a + "Walk2.gif", + a + "Walk3.gif", + a + "Attack1.gif", + a + "Attack2.gif", + "images/Plants/Peashooter/NonePeashooter.gif" + $Random, + a + "Die.gif" + $Random, + a + "Up.gif" + $Random, + a + "Down.gif" + $Random, + a + "BoomDie.gif" + $Random, + ]; + })(), + AudioArr: ["zombie_entering_water"], + Go_Up: function(a, WD) { + // WD: 方向,1右0左 + a.isUp = 1; //a.Ifgc=0; + a.beAttacked && + ((a.WalkDirection = WD), + (a.BoomDieGif = 12), + PlayAudio("zombie_entering_water"), + (a.Altitude = 4), + SetVisible(a.EleShadow), + (a.EleBody.src = a.PicArr[a.UpGif] + Math.random()), + (a.OSpeed = a.Speed = 0)), + (a.ChkActs = function() { + return 1; + }); // 跳起来 + oSym.addTask( + 100, + function(c, b) { + WD + ? + ((b.AttackGif = b.AttackGif_Up0), + (b.AttackedRX += 30), + (b.beAttackedPointL = 70), + (b.beAttackedPointR = 130), + (b.Ele.lastChild.style.left = "40px"), + (b.JudgeAttack = b.JudgeAttack_Up1)) : + (b.AttackGif = b.AttackGif_Up1); // GIF + $Z[c] && + b.beAttacked && + (WD && b.ExchangeLR(b, WD), + (b.Altitude = 1), + (b.isAttacking = 0), + (b.EleBody.src = b.PicArr[(b.NormalGif = b.DownGif)])); // 眩晕 + $Z[c] && + b.beAttacked && + oSym.addTask( + WD ? 400 : 0, + function(c, b) { + // 行走 + (b.EleBody.src = + b.PicArr[(b.NormalGif = WD ? b.WalkGif1 : b.WalkGif2)]), + (b.OSpeed = b.Speed = 1.6), + (b.ChkActs = + OrnNoneZombies["prototype"][WD ? "ChkActs1" : "ChkActs"]); + }, + [c, b] + ); + }, + [a.id, a] + ); + }, + ChkActs: function(f, d, g, c) { + // 到了左边自己钻出来 + if (f.Altitude == 0 && f.AttackedRX < GetX(1) - 40) return f.Go_Up(f, 1), 1; + + var b, a, e; + !(f.FreeFreezeTime || f.FreeSetbodyTime) ? + (f.beAttacked && !f.isAttacking && f.JudgeAttack_Dig(), + !f.isAttacking ? + (a = f.AttackedRX -= b = f.Speed) < -50 ? + (g.splice(c, 1), f.DisappearDie(), (e = 0)) : + (a < 80 && + !f.PointZombie && + ((f.PointZombie = 1), + !oS.CardKind && (StopMusic(), PlayAudio("losemusic", false)), + f.ChangeR({ + R: d, + ar: [oS.R - 1], + CustomTop: 400 - f.height + f.GetDY(), + })), + (f.ZX = f.AttackedLX -= b), + (f.Ele.style.left = Math.floor((f.X -= b)) + "px"), + (e = 1)) : + (e = 1)) : + (e = 1); + return e; + }, + CanDig: { + oPotatoMine: true + }, + JudgeAttack_Dig: function() { + var g = this, + d = g.ZX, + e = g.R + "_", + f = GetC(d), + h = oGd.$, + c; + (c = g.JudgeLR(g, e, f, d, h) || g.JudgeSR(g, e, f, d, h)) && + g.CanDig[$P[c[1]]["EName"]] ? + (!g.isAttacking && + ((g.isAttacking = 1), (g.EleBody.src = g.PicArr[g.AttackGif])), + g.NormalAttack(c[0], c[1])) : + g.isAttacking && + ((g.isAttacking = 0), (g.EleBody.src = g.PicArr[g.NormalGif])); + }, + JudgeAttack_Up1: function() { + var g = this, + d = g.AttackedRX, + e = g.R + "_", + f = GetC(d), + h = oGd.$, + c; + (c = g.JudgeSR(g, e, f, d, h) || g.JudgeLR(g, e, f, d, h)) ? + (!g.isAttacking && + ((g.isAttacking = 1), (g.EleBody.src = g.PicArr[g.AttackGif])), + g.NormalAttack(c[0], c[1])) : + g.isAttacking && + ((g.isAttacking = 0), (g.EleBody.src = g.PicArr[g.NormalGif])); + }, + Stone_of_Sinan_Up: function() { + // 被磁铁吸了镐子调用的函数 + var g = this; //alert(1); + if (g.isUp) { + g.EleBody.src = + g.PicArr[ + g.isAttacking ? + (g.AttackGif = g.AttackGif_Up1) : + (g.NormalGif = g.WalkGif2) + ]; + } else { + g.Go_Up(g, 0); + } + g.Stone_of_Sinan_Up = function() {}; + }, + }); + oIDiggerZombie = InheritO(OrnNoneZombies, { + EName: "oIDiggerZombie", + CName: "Digger Zombie", + Lvl: 4, + SunNum: 125, + HP: 500, + BreakPoint: 70, + width: 167, + height: 170, + GetDTop: 20, + beAttackedPointL: 65, + beAttackedPointR: 90, + OrnHP: 100, + OSpeed: 7.8, + Speed: 7.8, + Altitude: 0, // 挖矿 + CardGif: 0, + StandGif: 1, + StaticGif: 2, + NormalGif: 3, + WalkGif0: 3, + WalkGif1: 4, + WalkGif2: 5, + AttackGif: 3, + AttackGif_Up0: 6, + AttackGif_Up1: 7, + HeadGif: 8, + DieGif: 9, + UpGif: 10, + DownGif: 11, + BoomDieGif: 8, + LostHeadGif: 5, + LostHeadAttackGif: 5, + + Produce: '这种僵尸通过挖地来绕过防线。

韧性:
速度:快,而后慢
特点:挖地道,然后在草地的左侧现身
弱点:分裂射手,磁力菇

最近,他一直在听奥特曼的主题曲,据他所述,他好像是在某一处听到这首歌,觉得很好听,于是他现在也不挖土了,天天循环播放这首歌', + BirthCallBack: function(f) { + var e = f.delayT, + d = f.id, + c = (f.Ele = $(d)); + (f.EleShadow = c.firstChild), + (f.EleBody = c.childNodes[1]), + SetHidden(f.EleShadow); + e + ? + oSym.addTask( + e, + function(h, g) { + var i = $Z[h]; + i && ((i.FreeSetbodyTime = 0), SetBlock(g)); + }, + [d, c] + ) : + SetBlock(c); + }, + HeadPosition: [{ + x: 42, + y: 146 + }, { + x: 40, + y: 147 + }, ], + getShadow: function(a) { + return "left:" + a.beAttackedPointL + "px;top:" + (a.height - 20) + "px"; + }, + isUp: 0, + JudgeLR: function(f, d, e, c, g) { + return e > 10 || e < 1 ? + false : + (function() { + d += --e + "_"; + var h = 3, + i; + while (h--) { + if ((i = g[d + h]) && i.canEat) { + return i.AttackedRX >= c && i.AttackedLX <= c ? + [f.id, i.id] : + false; + } + } + })(); + }, + JudgeSR: function(f, d, e, c, g) { + return e > 9 ? + false : + (function() { + d += e + "_"; + var h = 3, + i; + while (h--) { + if ((i = g[d + h]) && i.canEat) { + return i.AttackedRX >= c && i.AttackedLX <= c ? + [f.id, i.id] : + false; + } + } + })(); + }, + PicArr: (function() { + var a = "images/Zombies/Diggerzombie/"; + return [ + "images/Card/Zombies/IDiggerzombie.png", + a + "0.gif", + a + "DiggerZombie.gif", + a + "Walk1.gif", + a + "Walk2.gif", + a + "Walk3.gif", + a + "Attack1.gif", + a + "Attack2.gif", + "images/Plants/Peashooter/NonePeashooter.gif" + $Random, + a + "Die.gif" + $Random, + a + "Up.gif" + $Random, + a + "Down.gif" + $Random, + a + "BoomDie.gif" + $Random, + ]; + })(), + AudioArr: ["zombie_entering_water"], + Go_Up: function(a, WD) { + // WD: 方向,1右0左 + a.isUp = 1; //a.Ifgc=0; + a.beAttacked && + ((a.WalkDirection = WD), + (a.BoomDieGif = 12), + PlayAudio("zombie_entering_water"), + (a.Altitude = 4), + SetVisible(a.EleShadow), + (a.EleBody.src = a.PicArr[a.UpGif] + Math.random()), + (a.OSpeed = a.Speed = 0)), + (a.ChkActs = function() { + return 1; + }); // 跳起来 + oSym.addTask( + 100, + function(c, b) { + WD + ? + ((b.AttackGif = b.AttackGif_Up0), + (b.AttackedRX += 30), + (b.beAttackedPointL = 70), + (b.beAttackedPointR = 130), + (b.Ele.lastChild.style.left = "40px"), + (b.JudgeAttack = b.JudgeAttack_Up1)) : + (b.AttackGif = b.AttackGif_Up1); // GIF + $Z[c] && + b.beAttacked && + (WD && b.ExchangeLR(b, WD), + (b.Altitude = 1), + (b.isAttacking = 0), + (b.EleBody.src = b.PicArr[(b.NormalGif = b.DownGif)])); // 眩晕 + $Z[c] && + b.beAttacked && + oSym.addTask( + WD ? 400 : 0, + function(c, b) { + // 行走 + (b.EleBody.src = + b.PicArr[(b.NormalGif = WD ? b.WalkGif1 : b.WalkGif2)]), + (b.OSpeed = b.Speed = 1.6), + (b.ChkActs = + OrnNoneZombies["prototype"][WD ? "ChkActs1" : "ChkActs"]); + }, + [c, b] + ); + }, + [a.id, a] + ); + }, + ChkActs: function(f, d, g, c) { + // 到了左边自己钻出来 + if (f.Altitude == 0 && f.AttackedRX < GetX(1) - 40) return f.Go_Up(f, 1), 1; + + var b, a, e; + !(f.FreeFreezeTime || f.FreeSetbodyTime) ? + (f.beAttacked && !f.isAttacking && f.JudgeAttack_Dig(), + !f.isAttacking ? + (a = f.AttackedRX -= b = f.Speed) < -50 ? + (g.splice(c, 1), f.DisappearDie(), (e = 0)) : + (a < 80 && + !f.PointZombie && + ((f.PointZombie = 1), + !oS.CardKind && (StopMusic(), PlayAudio("losemusic", false)), + f.ChangeR({ + R: d, + ar: [oS.R - 1], + CustomTop: 400 - f.height + f.GetDY(), + })), + (f.ZX = f.AttackedLX -= b), + (f.Ele.style.left = Math.floor((f.X -= b)) + "px"), + (e = 1)) : + (e = 1)) : + (e = 1); + return e; + }, + CanDig: { + oPotatoMine: true + }, + JudgeAttack_Dig: function() { + var g = this, + d = g.ZX, + e = g.R + "_", + f = GetC(d), + h = oGd.$, + c; + (c = g.JudgeLR(g, e, f, d, h) || g.JudgeSR(g, e, f, d, h)) && + g.CanDig[$P[c[1]]["EName"]] ? + (!g.isAttacking && + ((g.isAttacking = 1), (g.EleBody.src = g.PicArr[g.AttackGif])), + g.NormalAttack(c[0], c[1])) : + g.isAttacking && + ((g.isAttacking = 0), (g.EleBody.src = g.PicArr[g.NormalGif])); + }, + JudgeAttack_Up1: function() { + var g = this, + d = g.AttackedRX, + e = g.R + "_", + f = GetC(d), + h = oGd.$, + c; + (c = g.JudgeSR(g, e, f, d, h) || g.JudgeLR(g, e, f, d, h)) ? + (!g.isAttacking && + ((g.isAttacking = 1), (g.EleBody.src = g.PicArr[g.AttackGif])), + g.NormalAttack(c[0], c[1])) : + g.isAttacking && + ((g.isAttacking = 0), (g.EleBody.src = g.PicArr[g.NormalGif])); + }, + Stone_of_Sinan_Up: function() { + // 被磁铁吸了镐子调用的函数 + var g = this; //alert(1); + if (g.isUp) { + g.EleBody.src = + g.PicArr[ + g.isAttacking ? + (g.AttackGif = g.AttackGif_Up1) : + (g.NormalGif = g.WalkGif2) + ]; + } else { + g.Go_Up(g, 0); + } + g.Stone_of_Sinan_Up = function() {}; + }, + }); diff --git a/game/level/izombie3.js b/game/level/izombie3.js index 1a3a76d5..5a057e5d 100644 --- a/game/level/izombie3.js +++ b/game/level/izombie3.js @@ -1,6 +1,6 @@ oS.Init({ PName: [oPeashooter, oSunFlower, oTorchwood, oIPotatoMine, oSplitPea], - ZName: [oIZombie, oIBucketheadZombie, oIJackinTheBoxZombie], + ZName: [oIZombie, oIBucketheadZombie, oIDiggerZombie], PicArr: [ "images/interface/background2.jpg", "images/interface/trophy.png", diff --git a/game/level/izombie4.js b/game/level/izombie4.js index 0162c06a..4c5831ba 100644 --- a/game/level/izombie4.js +++ b/game/level/izombie4.js @@ -25,13 +25,7 @@ oS.Init({ ArC: [1, 4], ArR: [1, 5], Auto: 1, - P: [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 2, 2, 4, 4, 3, 3, 3, 3, 3], - }, - ArPN: { - ArNC: [4, 4], - ArNR: [1, 5], - Auto: 1, - PN: [3, 3, 3, 3, 3], + P: [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 2, 2, 4, 4], }, RiddleAutoGrow: function () { var k = oS.ArP, @@ -41,24 +35,14 @@ oS.Init({ d = oS.PName, c, g = f[0], - b = f[1], + b = f[1] - 1, i = j[0], h = j[1], a; - var nk = oS.ArPN, - nf = nk.ArNC, - nj = nk.ArNR, - ne = nk.PN, - nd = oS.PName, - nc, - ng = nf[0], - nb = nf[1], - ni = nj[0], - nh = nj[1], - na; if (k.Auto) { while (i <= h) { CustomSpecial(oBrains, i, 0); + CustomSpecial(oWallNut, i, 4); for (a = g; a <= b; a++) { CustomSpecial( d[e[(c = Math.floor(Math.random() * e.length))]], @@ -78,38 +62,9 @@ oS.Init({ ); }, StartGame: function () { - SetVisible($("dSunNum")); - SetBlock($("dTop")); - NewEle("DivTeach", "div", 0, 0, EDAll); - oP.Monitor({ - ar: [0], - f: function (d) { - var b = oS.Chose, - a = arguments.callee, - c = $("DivTeach"); - switch (d) { - case 0: - BeginCool(); - c.onclick = null; - oSym.addTask( - 500, - function () { - SetNone(c); - }, - [] - ); - (function () { - SetVisible($("dFlagMeter"), $("dFlagMeterContent")); - ClearChild($("oEmbed")); - StopMusic(); - PlayMusic((oS.LoadMusic = "Cerebrawl")); - BeginCool(); - oP.Monitor(); - })(); - } - }, - }); - SetVisible($("dFlagMeter")); + oP.Monitor(); + BeginCool(); + SetVisible($("dFlagMeter"), $("dTop")); oS.RiddleAutoGrow(); }, }); diff --git a/game/level/izombie8.js b/game/level/izombie8.js index 40f9856e..c56847e0 100644 --- a/game/level/izombie8.js +++ b/game/level/izombie8.js @@ -1,11 +1,11 @@ oS.Init({ - PName: [oPeashooter, oSunFlower, oWallNut, oIPotatoMine, oSquash], + PName: [oPeashooter, oSunFlower, oWallNut, oIPotatoMine, oSquash, oMagnetShroom], ZName: [ oIImp, oIConeheadZombie, oIBucketheadZombie, oIJackinTheBoxZombie, - oIPoleVaultingZombie, + oIDiggerZombie, oIScreenDoorZombie, ], PicArr: [ @@ -33,7 +33,7 @@ oS.Init({ ArR: [1, 5], Auto: 1, P: [ - 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 3, 3, + 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 5, 5, 3, 3, 4, 4, ], }, diff --git a/game/level/izombie9.js b/game/level/izombie9.js index 72f4651c..5c543970 100644 --- a/game/level/izombie9.js +++ b/game/level/izombie9.js @@ -21,7 +21,7 @@ oS.Init({ oIPoleVaultingZombie, oIBucketheadZombie, oIFootballZombie, - oIJackinTheBoxZombie, + oIDiggerZombie, oIScreenDoorZombie, ], PicArr: [