예제 #1
0
        public static void Main(string[] args)
        {
            INinja ninja = new Model.Ninja("Akeno");

            ninja.ChangeWeapon(new Katana());
            ninja.HeavyAttack();
            ninja.SwiftAttack();

            ninja.ChangeWeapon(new Shuriken());
            ninja.HeavyAttack();
            ninja.SwiftAttack();

            Console.WriteLine();
            IMasterNinja masterNinja = new Model.MasterNinja("Mikasa");

            masterNinja.DeadlyAttack();
            masterNinja.ChangeWeapon(new Katana());
            masterNinja.DeadlyAttack();

            masterNinja.Rest();
            masterNinja.DeadlyAttack();
            masterNinja.SwiftAttack();
            masterNinja.Wake();
            masterNinja.DeadlyAttack();
        }
예제 #2
0
파일: Program.cs 프로젝트: LeonidasSG/Ninja
        public static void Main(string[] args)
        {
            INinja ninja = new Model.Ninja();

            ninja.ChangeWeapon(new Katana());
            ninja.DeliberateAttack();
            ninja.SwiftAttack();

            ninja.ChangeWeapon(new Shuriken());
            ninja.DeliberateAttack();
            ninja.SwiftAttack();

            IMasterNinja masterNinja = new MasterNinja();
            masterNinja.DeadlyAttack();

            masterNinja.ChangeWeapon(new Katana());
            masterNinja.DeadlyAttack();

            masterNinja.ChangeWeapon(new Shuriken());
            masterNinja.DeadlyAttack();

        }