Exemplo n.º 1
0
        /// <summary>
        /// 合法手レベル1
        /// </summary>
        /// <returns></returns>
        public static SySet <SyElement> Create_08Kaku(Playerside pside, SyElement masu_ji)
        {
            SySet_Default <SyElement> dst = new SySet_Default <SyElement>("角の移動先");

            if (Okiba.ShogiBan == Util_Masu.Masu_ToOkiba(masu_ji))
            {
                dst.AddSupersets(KomanoKidou.DstKantu_昇(pside, masu_ji));
                dst.AddSupersets(KomanoKidou.DstKantu_沈(pside, masu_ji));
                dst.AddSupersets(KomanoKidou.DstKantu_降(pside, masu_ji));
                dst.AddSupersets(KomanoKidou.DstKantu_浮(pside, masu_ji));
            }
            else if ((Okiba.Sente_Komadai | Okiba.Gote_Komadai).HasFlag(
                         Util_Masu.Masu_ToOkiba(masu_ji)))
            {
                dst.AddSupersets(KomanoKidou.Dst_全打面(pside));
            }

            return(dst);
        }
Exemplo n.º 2
0
        /// <summary>
        /// 合法手レベル1
        /// </summary>
        /// <returns></returns>
        public static SySet <SyElement> Create_10Uma(Playerside pside, SyElement masu_ji)
        {
            SySet_Default <SyElement> dst = new SySet_Default <SyElement>("馬の移動先");

            if (Okiba.ShogiBan == Conv_SyElement.ToOkiba(masu_ji))
            {
                dst.AddSupersets(KomanoKidou.DstIppo_上(pside, masu_ji));
                dst.AddSupersets(KomanoKidou.DstKantu_昇(pside, masu_ji));
                dst.AddSupersets(KomanoKidou.DstIppo_射(pside, masu_ji));
                dst.AddSupersets(KomanoKidou.DstKantu_沈(pside, masu_ji));
                dst.AddSupersets(KomanoKidou.DstIppo_引(pside, masu_ji));
                dst.AddSupersets(KomanoKidou.DstKantu_降(pside, masu_ji));
                dst.AddSupersets(KomanoKidou.DstIppo_滑(pside, masu_ji));
                dst.AddSupersets(KomanoKidou.DstKantu_浮(pside, masu_ji));
            }
            else if ((Okiba.Sente_Komadai | Okiba.Gote_Komadai).HasFlag(
                         Conv_SyElement.ToOkiba(masu_ji)))
            {
                dst.AddSupersets(KomanoKidou.Dst_全打面(pside));
            }

            return(dst);
        }