protected override void Moving() { this.neutlal = this.Motion == NaviBase.MOTION.neutral; switch (this.Motion) { case NaviBase.MOTION.neutral: if (this.moveflame) { ++this.waittime; } if (this.moveflame) { this.animationpoint = this.AnimeNeutral(this.waittime); if (this.waittime >= 16 / version || this.atack) { this.waittime = 0; ++this.roopneutral; if (this.roopneutral >= 1 && this.parent.nowscene != SceneBattle.BATTLESCENE.end) { this.roopneutral = 0; if (this.roopmove > this.moveroop && !this.badstatus[4]) { this.roopmove = this.version > 3 ? this.Random.Next(-1, 1) : 0; ++this.atackroop; if (this.parent.player.invincibility || this.parent.player.barrierType != CharacterBase.BARRIER.None || this.parent.player.nohit) { this.atack = true; } if (!this.atack) { this.attack = (Youmu.ATTACK) this.pattern[this.action]; if (this.attack == Youmu.ATTACK.RoukanRenzan) { this.powerPlus = this.powers[this.pattern[this.action]] - this.power; } else { this.powerPlus = this.powers[this.pattern[this.action]]; } ++this.action; if (this.action >= this.pattern.Length) { this.action = 0; } this.attackProcess = 0; } else { this.attack = Youmu.ATTACK.Hakurouken; this.powerPlus = this.powers[(int)this.attack]; this.atack = false; } this.waittime = 0; this.Motion = NaviBase.MOTION.attack; } else { this.waittime = 0; if (this.atack) { this.roopmove = this.moveroop + 1; } this.Motion = NaviBase.MOTION.move; } } } break; } break; case NaviBase.MOTION.attack: if (this.moveflame) { ++this.waittime; if (this.moveflame) { switch (this.attack) { case Youmu.ATTACK.RoukanRenzan: switch (this.attackProcess) { case 0: this.animationpoint = this.AnimeSlashUP(0); switch (this.waittime) { case 1: this.target = this.RandomTarget(this.union); this.parent.attacks.Add(new Dummy(this.sound, this.parent, this.target.X, this.target.Y - 1, this.union, new Point(0, 2), 30, true)); break; case 4: this.counterTiming = true; break; case 8: ++this.attackProcess; this.waittime = 0; break; } break; case 1: this.animationpoint = this.AnimeSlashUP(this.waittime); switch (this.waittime) { case 2: this.sound.PlaySE(SoundEffect.sword); SwordAttack swordAttack1 = new SwordAttack(this.sound, this.parent, this.target.X, this.target.Y, this.union, this.Power, 2, ChipBase.ELEMENT.normal, true, true) { invincibility = false }; this.parent.attacks.Add(swordAttack1); this.target = this.RandomTarget(this.union); this.parent.attacks.Add(new Dummy(this.sound, this.parent, this.target.X, this.target.Y - 1, this.union, new Point(0, 2), 30, true)); break; case 4: this.counterTiming = false; break; case 8: ++this.attackProcess; this.waittime = 0; break; } break; case 2: this.animationpoint = this.AnimeSlashDOWN(this.waittime); switch (this.waittime) { case 2: this.sound.PlaySE(SoundEffect.sword); SwordAttack swordAttack2 = new SwordAttack(this.sound, this.parent, this.target.X, this.target.Y, this.union, this.Power, 2, ChipBase.ELEMENT.normal, true, true) { invincibility = false }; this.parent.attacks.Add(swordAttack2); if (this.version > 1) { this.target = this.RandomTarget(this.union); this.parent.attacks.Add(new Dummy(this.sound, this.parent, this.target.X, this.target.Y - 1, this.union, new Point(0, 2), 30, true)); break; } break; case 8: if (this.version > 1) { ++this.attackProcess; this.waittime = 0; break; } this.speed = this.nspeed; this.SoulAttack(); this.motion = NaviBase.MOTION.move; this.waittime = 0; break; } break; case 3: this.animationpoint = this.AnimeSlashUP(this.waittime); switch (this.waittime) { case 2: this.sound.PlaySE(SoundEffect.sword); SwordAttack swordAttack3 = new SwordAttack(this.sound, this.parent, this.target.X, this.target.Y, this.union, this.Power, 2, ChipBase.ELEMENT.normal, true, true) { invincibility = false }; this.parent.attacks.Add(swordAttack3); break; case 5: this.speed = this.nspeed; this.SoulAttack(); this.motion = NaviBase.MOTION.move; this.waittime = 0; break; } break; } break; case Youmu.ATTACK.NishinIttaiken: this.animationpoint = this.AnimeSlashNishin(this.waittime); switch (this.waittime) { case 1: this.soul.LostFlag(true); this.guard = CharacterBase.GUARD.none; this.counterTiming = true; this.speed += 2; this.sound.PlaySE(SoundEffect.charge); break; case 10: this.counterTiming = false; this.sound.PlaySE(SoundEffect.sword); int s = 4; AttackBase attackBase1 = new BombWave(this.sound, this.parent, this.position.X + this.UnionRebirth(this.union), 0, this.union, this.Power, s, this.element); attackBase1.invincibility = false; this.parent.attacks.Add(attackBase1); AttackBase attackBase2 = new BombWave(this.sound, this.parent, this.position.X + this.UnionRebirth(this.union), 1, this.union, this.Power, s, this.element); attackBase2.invincibility = false; this.parent.attacks.Add(attackBase2); AttackBase attackBase3 = new BombWave(this.sound, this.parent, this.position.X + this.UnionRebirth(this.union), 2, this.union, this.Power, s, this.element); attackBase3.invincibility = false; this.parent.attacks.Add(attackBase3); break; case 25: this.speed = this.nspeed; this.guard = CharacterBase.GUARD.noDamage; this.motion = NaviBase.MOTION.move; this.waittime = 0; this.soul.LostFlag(false); break; } break; case Youmu.ATTACK.IaiJuujizan: if (this.attackProcess == 0) { this.animationpoint = this.AnimeIai(this.waittime); switch (this.waittime) { case 1: this.counterTiming = true; this.parent.effects.Add(new Flash(this.sound, this.parent, this.positionDirect, this.position)); this.sound.PlaySE(SoundEffect.pikin); this.speed += 2; break; case 2: this.target = this.RandomTarget(this.union); this.effecting = true; this.positionReserved = this.position; this.positionre = new Point(this.union == Panel.COLOR.blue ? 0 : 5, this.target.Y); this.position = this.positionre; this.PositionDirectSet(); break; case 6: this.counterTiming = false; this.sound.PlaySE(SoundEffect.sword); SwordCloss swordCloss = new SwordCloss(this.sound, this.parent, this.target.X, this.target.Y, this.union, this.Power, 2, ChipBase.ELEMENT.normal, true) { invincibility = false }; this.parent.attacks.Add(swordCloss); break; case 25: this.positionReserved = null; this.speed = this.nspeed; this.motion = NaviBase.MOTION.move; this.effecting = false; this.speed = this.nspeed; this.waittime = 0; break; } } break; case Youmu.ATTACK.Hakurouken: this.animationpoint = this.AnimeSlashHakurou(this.waittime); switch (this.waittime) { case 1: this.counterTiming = true; break; case 2: this.sound.PlaySE(SoundEffect.sword); foreach (CharacterBase characterBase in this.parent.AllChara()) { if (characterBase.union == this.UnionEnemy && (characterBase.guard != CharacterBase.GUARD.none || characterBase.invincibilitytime > 0 || characterBase.nohit || (uint)characterBase.barrierType > 0U)) { characterBase.Hp -= this.Power; characterBase.invincibilitytime = 0; characterBase.barrierType = CharacterBase.BARRIER.None; this.sound.PlaySE(SoundEffect.damageenemy); } } break; case 4: this.counterTiming = false; break; case 8: this.speed = this.nspeed; this.motion = NaviBase.MOTION.move; this.waittime = 0; break; } break; } } break; } break; case NaviBase.MOTION.move: this.animationpoint = this.AnimeMove(this.waittime); if (this.moveflame) { switch (this.waittime) { case 0: this.MoveRandom(false, false); if (this.position == this.positionre) { this.Motion = NaviBase.MOTION.neutral; this.frame = 0; this.roopneutral = 0; ++this.roopmove; break; } break; case 3: this.position = this.positionre; this.PositionDirectSet(); break; case 5: this.Motion = NaviBase.MOTION.neutral; this.frame = 0; this.roopneutral = 0; ++this.roopmove; break; } ++this.waittime; break; } break; case NaviBase.MOTION.knockback: switch (this.waittime) { case 2: this.guard = CharacterBase.GUARD.noDamage; if (this.soul.motion == HalfSoul.MOTION.lost) { this.soul.LostFlag(false); } this.NockMotion(); this.counterTiming = false; this.effecting = false; this.PositionDirectSet(); break; case 3: this.NockMotion(); break; case 15: this.animationpoint = new Point(0, 1); this.PositionDirectSet(); break; case 21: this.animationpoint = new Point(0, 0); this.waittime = 0; this.Motion = NaviBase.MOTION.neutral; break; } if (this.waittime >= 2 && this.waittime <= 6) { this.positionDirect.X -= this.UnionRebirth(this.union); } ++this.waittime; break; } if (this.effecting) { this.AttackMake(this.Power, 0, 0); } this.FlameControl(); this.MoveAftar(); }
public override void Action(CharacterBase character, SceneBattle battle) { if (!this.BlackOut(character, battle, this.name, this.Power(character).ToString())) { return; } if (character is Player) { Player player = (Player)character; if (this.nowmotion == 0 && this.frame < 3 && (Input.IsPush(Button._A) && this.command == 0) && this.commandTime < 60) { this.CommandInput("上下左右B", player); if (this.CommandCheck("下左上右下")) { this.command = 4; } else if (this.CommandCheck("左B右B")) { this.command = 5; } } } if (this.moveflame) { switch (this.nowmotion) { case 0: this.animePoint.X = this.AnimeMove(this.frame).X; switch (this.frame) { case 1: character.animationpoint.X = -1; this.xPosition = character.position.X; this.sound.PlaySE(SoundEffect.warp); break; case 2: if (character is Player && (Input.IsPush(Button._A) && this.command == 0 && this.commandTime < 60)) { this.frame = 1; break; } break; case 3: if (this.CommandCheck("下左上右下")) { this.sound.PlaySE(SoundEffect.CommandSuccess); this.command = 4; } else if (this.CommandCheck("左B右B")) { this.sound.PlaySE(SoundEffect.CommandSuccess); this.command = 5; } if (this.command == 5) { this.xPosition = character.position.X; ++this.nowmotion; this.frame = 0; break; } break; case 5: this.xPosition = this.TargetX(character, battle); if (this.xPosition < 0) { this.xPosition = 0; } if (this.xPosition > 5) { this.xPosition = 5; break; } break; case 9: ++this.nowmotion; this.frame = 0; break; } break; case 1: this.animePoint.X = this.AnimeSlash1(this.frame).X; switch (this.frame) { case 5: if (character is Player && this.command == 0) { Player player = (Player)character; if (Input.IsPush(Button.Right)) { this.sound.PlaySE(SoundEffect.CommandSuccess); this.command = 1; } else if (Input.IsPush(Button.Up)) { this.sound.PlaySE(SoundEffect.CommandSuccess); this.command = 2; } else if (Input.IsPush(Button.Left)) { this.sound.PlaySE(SoundEffect.CommandSuccess); this.command = 3; } break; } break; case 6: this.sound.PlaySE(SoundEffect.sword); AttackBase a1 = new SwordAttack(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false, false); switch (this.command) { case 1: a1 = new FighterSword(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element); break; case 2: a1 = new SwordAttack(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false, false); break; case 3: a1 = new SwordCloss(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character) / 2, 4, this.element, false); break; case 4: a1 = new Halberd(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false); break; case 5: a1 = new SonicBoom(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 8, this.element, false); break; } a1.invincibility = false; battle.attacks.Add(this.Paralyze(a1)); break; case 10: ++this.nowmotion; this.frame = 0; break; } break; case 2: this.animePoint.X = this.AnimeSlash2(this.frame).X; switch (this.frame) { case 6: this.sound.PlaySE(SoundEffect.sword); AttackBase a2 = new SwordAttack(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false, false); switch (this.command) { case 1: a2 = new FighterSword(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element); break; case 2: a2 = new SwordAttack(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false, false); break; case 3: a2 = new SwordCloss(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character) / 2, 4, this.element, false); break; case 4: a2 = new Halberd(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false); break; case 5: a2 = new SonicBoom(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 8, this.element, false); break; } a2.invincibility = false; battle.attacks.Add(this.Paralyze(a2)); break; case 10: ++this.nowmotion; this.frame = 0; break; } break; case 3: this.animePoint.X = this.AnimeSlash3(this.frame).X; switch (this.frame) { case 6: this.sound.PlaySE(SoundEffect.sword); AttackBase a3 = new SwordCloss(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character) / 2, 4, this.element, false); switch (this.command) { case 1: a3 = new FighterSword(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element); break; case 2: a3 = new SwordAttack(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false, false); break; case 3: a3 = new SwordCloss(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character) / 2, 4, this.element, false); break; case 4: a3 = new Halberd(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false); break; case 5: a3 = new SonicBoom(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 8, this.element, false); break; } a3.invincibility = false; battle.attacks.Add(this.Paralyze(a3)); break; case 10: ++this.nowmotion; this.frame = 0; break; } break; case 4: this.animePoint.X = this.AnimeSlash2(this.frame).X; switch (this.frame) { case 6: this.sound.PlaySE(SoundEffect.sword); AttackBase a4 = new Halberd(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false); switch (this.command) { case 1: a4 = new FighterSword(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element); break; case 2: a4 = new SwordAttack(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false, false); break; case 3: a4 = new SwordCloss(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character) / 2, 4, this.element, false); break; case 4: a4 = new Halberd(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false); break; case 5: a4 = new SonicBoom(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 8, this.element, false); break; } a4.invincibility = false; battle.attacks.Add(this.Paralyze(a4)); break; case 10: ++this.nowmotion; this.frame = 0; break; } break; case 5: this.animePoint.X = this.AnimeSlash1(this.frame).X; switch (this.frame) { case 6: this.sound.PlaySE(SoundEffect.sword); AttackBase a5 = new SonicBoom(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 8, this.element, true); switch (this.command) { case 1: a5 = new FighterSword(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element); break; case 2: a5 = new SwordAttack(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false, false); break; case 3: a5 = new SwordCloss(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character) / 2, 4, this.element, false); break; case 4: a5 = new Halberd(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 4, this.element, false); break; case 5: a5 = new SonicBoom(this.sound, battle, this.xPosition + this.UnionRebirth(character.union), character.position.Y, character.union, this.Power(character), 8, this.element, false); break; } a5.invincibility = true; battle.attacks.Add(this.Paralyze(a5)); break; case 30: character.parent.effects.Add(new MoveEnemy(this.sound, character.parent, this.xPosition, character.position.Y)); this.end = true; ++this.nowmotion; this.frame = 0; break; } break; } } if (this.end && this.BlackOutEnd(character, battle)) { base.Action(character, battle); } this.FlameControl(2); }
public override void Action(CharacterBase character, SceneBattle battle) { if (!this.BlackOut(character, battle, this.name, this.Power(character).ToString())) { return; } if (this.moveflame && this.nowmotion == 0) { switch (this.frame) { case 1: character.animationpoint.X = -1; this.xPosition = character.position.X; this.sound.PlaySE(SoundEffect.warp); this.animePoint = new Point(2, 0); break; case 2: this.animePoint = new Point(1, 0); break; case 3: this.animePoint = new Point(0, 0); this.target = new Point(character.position.X, character.position.Y); this.target.X = this.TargetX(character, battle) + this.UnionRebirth(character.union); if (this.target.X < 0) { this.target.X = 0; } if (this.target.X > 5) { this.target.X = 5; break; } break; case 15: this.sound.PlaySE(SoundEffect.pikin); battle.effects.Add(new Flash(this.sound, battle, character.positionDirect, character.position)); this.animePoint = new Point(0, 4); break; case 18: this.animePoint = new Point(1, 4); break; case 19: this.xPosition = character.union == Panel.COLOR.red ? 5 : 0; this.animePoint = new Point(2, 4); break; case 20: this.animePoint = new Point(3, 4); break; case 25: this.sound.PlaySE(SoundEffect.breakObject); SwordCloss swordCloss = new SwordCloss(this.sound, battle, this.target.X, this.target.Y, character.union, this.Power(character), 2, this.element, false); swordCloss.breakinvi = true; battle.attacks.Add(this.Paralyze(swordCloss)); break; case 51: this.animePoint = new Point(2, 4); break; case 52: this.animePoint = new Point(2, 0); break; case 53: this.animePoint = new Point(-1, 0); character.animationpoint.X = 0; this.end = true; break; } } if (this.end && this.BlackOutEnd(character, battle)) { base.Action(character, battle); } this.FlameControl(2); }