Esempio n. 1
0
        /// <summary>
        /// リーチのシナリオを新規作成
        /// </summary>
        /// <param name="reachedRoleSet">リーチになっているセット</param>
        /// <param name="finally">リーチ再抽選後にキーとなるリールが示すRole</param>
        private Scenario(RoleSet reachedRoleSet, RoleValue @finally)
        {
            if (!reachedRoleSet.IsReach)
            {
                throw new InvalidOperationException("入力されたセットはリーチではありません");
            }

            this.First = reachedRoleSet;
            switch (First.ReachStatus.Value.ReachReelPos)
            {
            case ReelPos.Left:
                Left    = ReelScenario.ReachKey(reachedRoleSet.Left, @finally);
                Middle  = ReelScenario.Normal(reachedRoleSet.Middle);
                Right   = ReelScenario.Normal(reachedRoleSet.Right);
                Finally = new RoleSet(@finally, reachedRoleSet.Middle, reachedRoleSet.Right);
                break;

            case ReelPos.Middle:
                Left    = ReelScenario.Normal(reachedRoleSet.Left);
                Middle  = ReelScenario.ReachKey(reachedRoleSet.Middle, @finally);
                Right   = ReelScenario.Normal(reachedRoleSet.Right);
                Finally = new RoleSet(reachedRoleSet.Left, @finally, reachedRoleSet.Right);
                break;

            case ReelPos.Right:
                Left    = ReelScenario.Normal(reachedRoleSet.Left);
                Middle  = ReelScenario.Normal(reachedRoleSet.Middle);
                Right   = ReelScenario.ReachKey(reachedRoleSet.Right, @finally);
                Finally = new RoleSet(reachedRoleSet.Left, reachedRoleSet.Middle, @finally);
                break;

            default:
                throw new InvalidEnumArgumentException();
            }
        }
Esempio n. 2
0
 /// <summary>
 /// ダイレクトで当たるシナリオを作成
 /// </summary>
 /// <param name="winRole"></param>
 /// <returns></returns>
 public static Scenario DirectWin(RoleValue winRole)
 {
     return(new Scenario(new RoleSet(winRole, winRole, winRole)));
 }
Esempio n. 3
0
 /// <summary>
 /// リーチのシナリオを作成
 /// </summary>
 /// <param name="reachedRoleSet">リーチのRoleset</param>
 /// <param name="afterReachRole">リーチ再抽選後にキーとなるリールが示すRole</param>
 /// <returns></returns>
 public static Scenario Reach(RoleSet reachedRoleSet, RoleValue afterReachRole)
 {
     return(new Scenario(reachedRoleSet, afterReachRole));
 }
Esempio n. 4
0
 public static ReelScenario ReachKey(RoleValue first, RoleValue @finally)
 {
     return(new ReelScenario(first, @finally, true));
 }
Esempio n. 5
0
 /// <summary>
 /// 1回の抽選で終わる通常のシナリオを作成
 /// </summary>
 /// <param name="toValue">表示する出目</param>
 /// <returns></returns>
 public static ReelScenario Normal(RoleValue toValue)
 {
     return(new ReelScenario(toValue, toValue, false));
 }
Esempio n. 6
0
 private ReelScenario(RoleValue first, RoleValue @finally, bool isReachKey)
 {
     this.First      = first;
     this.Finally    = @finally;
     this.IsReachKey = isReachKey;
 }
Esempio n. 7
0
 public ReachInfo(RoleValue reachRole, ReelPos reachPos)
 {
     this.ReachedRole  = reachRole;
     this.ReachReelPos = reachPos;
 }
Esempio n. 8
0
 public RoleSet(RoleValue left, RoleValue middle, RoleValue right)
 {
     this.Left   = left;
     this.Middle = middle;
     this.Right  = right;
 }