Exemplo n.º 1
0
        public override void AddRules()
        {
            base.AddRules();
            var elephantRule = new Rules.ExtraMovesForUnmovedPieceRule(Elephant, "elephants");

            elephantRule.AddMove(MoveCapability.Step(new Direction(2, 0)));
            elephantRule.AddMove(MoveCapability.Step(new Direction(2, 2)));
            elephantRule.AddMove(MoveCapability.Step(new Direction(2, -2)));
            AddRule(elephantRule);
        }
Exemplo n.º 2
0
        public static new void AddMoves(PieceType type)
        {
            Ferz.AddMoves(type);

            //	add the multi-path move
            MoveCapability move     = MoveCapability.Step(new Direction(2, 0));
            MovePathInfo   movePath = new MovePathInfo();

            movePath.AddPath(new List <Direction>()
            {
                new Direction(1, 1), new Direction(1, -1)
            });
            movePath.AddPath(new List <Direction>()
            {
                new Direction(1, -1), new Direction(1, 1)
            });
            move.PathInfo = movePath;
            type.AddMoveCapability(move);
        }