private void DorillChange() { if (this.DorillSearch()) { this.parent.effects.Add(new MoveEnemy(this.sound, this.parent, this.position.X, this.position.Y)); this.position = this.positionre; this.PositionDirectSet(); this.Motion = NaviBase.MOTION.attack; this.waittime = 0; int index = 2; this.speed = Math.Max(3, 4 - version / 2); this.attack = (Iku.ATTACK)index; this.powerPlus = this.powers[index]; } else { ++this.cancelCount; if (this.cancelCount >= 5) { int pX = Eriabash.SteelX(this, this.parent); if (pX != 99) { for (int pY = 0; pY < this.parent.panel.GetLength(1); ++pY) { this.parent.attacks.Add(new EriaSteel(this.sound, this.parent, pX, pY, this.union, 10, this.element)); } } this.cancelCount = 0; } this.motion = NaviBase.MOTION.move; this.waittime = 0; if (!this.atack) { this.speed = 8; } } }
protected override void Moving() { this.neutlal = this.Motion == NaviBase.MOTION.neutral; switch (this.Motion) { case NaviBase.MOTION.neutral: if (this.moveflame) { ++this.waittime; } ++this.movetime; if (!this.HeviSand && this.SlideMove(1f / movespeed, this.UpDown ? 2 : 3)) { int num = this.UpDown ? -1 : 1; Point position = this.position; position.Y += num; ++this.roopmove; if (!this.Canmove(position, this.number)) { this.UpDown = !this.UpDown; } if (this.roopmove == this.moveroop && (this.ballShot || this.Hp >= this.HpMax / 2)) { this.powerPlus = this.powers[5] * version; this.sound.PlaySE(SoundEffect.eriasteal2); this.parent.attacks.Add(new SlowThunder(this.sound, this.parent, this.position.X + this.UnionRebirth(this.union), this.position.Y, this.union, this.Power, ChipBase.ELEMENT.eleki, 1, 1, true)); } } if (this.moveflame) { this.animationpoint = this.AnimeNeutral(this.waittime); } if (this.waittime >= 4 || this.atack) { this.waittime = 0; } if (this.parent.nowscene != SceneBattle.BATTLESCENE.end && ((this.roopmove > this.moveroop || this.HeviSand) && !this.badstatus[4])) { ++this.atackroop; this.roopneutral = 0; this.roopmove = 0; this.speed = Math.Max(2, 4 - version / 2); if (!this.atack) { int index = this.Random.Next(this.Hp >= this.HpMax / 2 ? 2 : 8); if (index >= 2) { index = 3; } if (index == 3) { this.speed = Math.Max(2, 3); } this.frame = 0; this.attack = (Iku.ATTACK)index; this.powerPlus = this.powers[index]; } this.waittime = 0; this.positionre = this.position; this.PositionDirectSet(); this.Motion = NaviBase.MOTION.attack; this.counterTiming = true; break; } break; case NaviBase.MOTION.attack: if (this.moveflame) { ++this.waittime; } if (this.moveflame) { switch (this.attack) { case Iku.ATTACK.lineThunder: this.animationpoint = this.AnimeFever(this.waittime); switch (this.waittime) { case 1: this.target = this.RandomTarget(); this.target.Y = 0; this.parent.attacks.Add(new Dummy(this.sound, this.parent, this.target.X, 0, this.union, new Point(), 13, true)); this.parent.attacks.Add(new Dummy(this.sound, this.parent, this.target.X, 1, this.union, new Point(), 16, true)); this.parent.attacks.Add(new Dummy(this.sound, this.parent, this.target.X, 2, this.union, new Point(), 19, true)); break; case 6: this.counterTiming = false; if (7 - (version - 1) * 3 <= 0) { break; } break; case 13: this.target.Y = 0; this.parent.attacks.Add(new CrackThunder(this.sound, this.parent, this.target.X, this.target.Y, this.union, this.Power, false)); break; case 16: this.target.Y = 1; this.parent.attacks.Add(new CrackThunder(this.sound, this.parent, this.target.X, this.target.Y, this.union, this.Power, false)); break; case 19: this.target.Y = 2; this.parent.attacks.Add(new CrackThunder(this.sound, this.parent, this.target.X, this.target.Y, this.union, this.Power, false)); break; case 20: this.roopneutral = 0; this.DorillChange(); break; } break; case Iku.ATTACK.searchThunder: this.animationpoint = this.AnimeThunder(this.waittime); switch (this.waittime) { case 1: this.attackCount = 0; break; case 6: this.counterTiming = false; break; } if (this.waittime >= 5 && this.waittime % 5 == 0) { if (this.attackCount > 0) { this.parent.attacks.Add(new CrackThunder(this.sound, this.parent, this.target.X, this.target.Y, this.union, this.Power, false)); } if (this.attackCount < Math.Min(version + 2, 5)) { this.target = this.RandomTarget(); this.parent.attacks.Add(new Dummy(this.sound, this.parent, this.target.X, this.target.Y, this.union, new Point(), 13, true)); } else { this.roopneutral = 0; this.parent.attacks.Add(new CrackThunder(this.sound, this.parent, this.target.X, this.target.Y, this.union, this.Power, false)); this.DorillChange(); } ++this.attackCount; break; } break; case Iku.ATTACK.drillArm: this.animationpoint = this.AnimeThunder(this.waittime); switch (this.waittime) { case 7: DrillAttack drillAttack1 = new DrillAttack(this.sound, this.parent, this.position.X + this.UnionRebirth(this.union), this.position.Y, this.union, this.Power, 1, ChipBase.ELEMENT.eleki) { invincibility = false, breaking = true }; this.parent.attacks.Add(drillAttack1); this.sound.PlaySE(SoundEffect.drill2); break; case 10: DrillAttack drillAttack2 = new DrillAttack(this.sound, this.parent, this.position.X + this.UnionRebirth(this.union), this.position.Y, this.union, this.Power, 1, ChipBase.ELEMENT.eleki) { invincibility = false, breaking = true }; this.parent.attacks.Add(drillAttack2); break; case 13: DrillAttack drillAttack3 = new DrillAttack(this.sound, this.parent, this.position.X + this.UnionRebirth(this.union), this.position.Y, this.union, this.Power, 1, ChipBase.ELEMENT.eleki) { invincibility = false, breaking = true }; this.parent.attacks.Add(drillAttack3); break; case 16: this.waittime = 0; this.speed = 8; this.motion = NaviBase.MOTION.move; break; } break; case Iku.ATTACK.drillBreak: this.animationpoint.X = 7; int speed = 5; if (this.version >= 3) { speed = 10; this.speed = 3; } else { this.speed = 6; } switch (this.frame) { case 1: this.Noslip = true; this.drilinvi = true; this.nohit = true; this.parent.effects.Add(new MoveEnemy(this.sound, this.parent, this.position.X, this.position.Y)); switch (this.position.Y) { case 0: this.drillY[0] = 1; this.drillY[1] = 2; break; case 1: this.drillY[0] = 2; this.drillY[1] = 0; break; case 2: this.drillY[0] = 1; this.drillY[1] = 0; break; } this.sound.PlaySE(SoundEffect.drill1); this.parent.objects.Add(new MetalDorill(this.sound, this.parent, this.position.X, this.drillY[0], this.Power, this.version <= 3, speed, this.union)); break; case 6: this.sound.PlaySE(SoundEffect.drill1); this.parent.objects.Add(new MetalDorill(this.sound, this.parent, this.position.X, this.drillY[1], this.Power, this.version <= 3, speed, this.union)); break; case 11: this.drilinvi = false; this.nohit = false; this.sound.PlaySE(SoundEffect.drill1); this.drillBreak = new MetalDorill(this.sound, this.parent, this.position.X + this.UnionRebirth(this.union), this.position.Y, this.Power, this.version <= 3, speed, this.union); this.drillBreak.positionDirect.X -= 16 * this.UnionRebirth(this.union); this.drillBreak.positionDirect.Y -= 8f; this.parent.objects.Add(drillBreak); this.speed = 8; this.effecting = true; this.counterTiming = false; break; } break; } break; } break; case NaviBase.MOTION.move: if (this.moveflame) { ++this.waittime; } ++this.roopmove; this.Motion = NaviBase.MOTION.neutral; this.positionre = this.position; if (this.position.X != (this.union == Panel.COLOR.blue ? 5 : 0)) { this.positionre.X = this.union == Panel.COLOR.blue ? 5 : 0; if (this.Canmove(this.positionre)) { this.parent.effects.Add(new MoveEnemy(this.sound, this.parent, this.position.X, this.position.Y)); this.position = this.positionre; this.PositionDirectSet(); this.frame = 0; this.roopneutral = 0; } else { this.positionre.Y = 0; if (this.Canmove(this.positionre, this.number)) { this.parent.effects.Add(new MoveEnemy(this.sound, this.parent, this.position.X, this.position.Y)); this.position = this.positionre; this.PositionDirectSet(); } else { this.positionre.Y = 1; if (this.Canmove(this.positionre, this.number)) { this.parent.effects.Add(new MoveEnemy(this.sound, this.parent, this.position.X, this.position.Y)); this.position = this.positionre; this.PositionDirectSet(); } else { this.positionre.Y = 2; if (this.Canmove(this.positionre, this.number)) { this.parent.effects.Add(new MoveEnemy(this.sound, this.parent, this.position.X, this.position.Y)); this.position = this.positionre; this.PositionDirectSet(); } else { this.Motion = NaviBase.MOTION.neutral; this.PositionDirectSet(); } } } } this.frame = 0; this.roopneutral = 0; this.roopmove = 0; } if (this.position.Y == 0) { this.UpDown = false; break; } if (this.position.Y == 2) { this.UpDown = true; break; } break; case NaviBase.MOTION.knockback: switch (this.waittime) { case 1: if (this.drillBreak != null) { this.drillBreak.flag = false; break; } break; case 2: this.movelong = 24; this.effecting = false; this.animationpoint = new Point(3, 0); this.counterTiming = false; this.effecting = false; this.PositionDirectSet(); this.Noslip = false; break; case 3: this.animationpoint = new Point(3, 0); break; case 15: this.animationpoint = new Point(8, 0); this.PositionDirectSet(); break; case 21: this.animationpoint = new Point(0, 0); this.waittime = 0; if (!this.atack) { this.speed = 8; } this.Motion = NaviBase.MOTION.move; break; } if (this.waittime >= 2 && this.waittime <= 6) { this.positionDirect.X -= this.UnionRebirth(this.union); } ++this.waittime; break; } if (this.effecting && !this.nohit) { this.AttackMake(this.Power, 0, 0); } if (this.motion == NaviBase.MOTION.attack && this.attack == Iku.ATTACK.drillBreak && this.frame >= 11 && this.drillBreak != null) { if (!this.drillBreak.flag && this.drillBreak.speednow == 0) { this.drillBreak.speednow = 3; } if (this.drillBreak.flag) { this.positionDirect.X = this.drillBreak.positionDirect.X - 24 * this.UnionRebirth(this.union); } else { this.positionDirect.X += this.drillBreak.speednow * this.UnionRebirth(this.union); } this.position.X = this.Calcposition(this.positionDirect, 72, false).X; if (this.union == Panel.COLOR.blue && this.position.X <= 0 && !this.drillBreak.flag || this.union == Panel.COLOR.red && this.position.X >= 6 && !this.drillBreak.flag) { this.Noslip = false; this.speed = 8; this.motion = NaviBase.MOTION.move; this.effecting = false; } } this.FlameControl(); this.MoveAftar(); }