コード例 #1
0
        public virtual void RecoverFreeSpin(Dictionary <string, string> dataList, int iBetAmount = 0)
        {
            m_Stage = STAGE.STAGE_FREESPIN;
            int      id           = int.Parse(dataList["SLOTID"]);
            SlotReel FreespinReel = m_SlotReels[id];

            if (dataList.ContainsKey("FGRS") && !string.IsNullOrEmpty(dataList["FGRS"].Trim()))
            {
                m_SpinResult = m_SlotReels[0].PlayGame(iBetAmount);
                int[] reelstops = StringUtility.StringToIntArray(dataList["FGRS"], ' ');
                FreespinReel.Recover(reelstops, iBetAmount);

                int iCurrentSpin = int.Parse(dataList["CURRENTSPIN"]);
                int iFSTotalWin  = int.Parse(dataList["FSTOTALWIN"]);
                int iTotalSpin   = int.Parse(dataList["TOTALSPIN"]);
                m_SpinResult.ClearTiggerLine();
                m_SpinResult.ReadyForSpin = true;
                m_SpinResult.setBonusId(0, 0, 0);
                m_SpinResult.FreePlay      = true;
                m_SpinResult.BaseWinAmount = int.Parse(dataList["BGWINAMOUNT"]);
                FreespinReel.RestoreFreeSpinProperties(iCurrentSpin, iTotalSpin, iFSTotalWin);
                m_SpinResult.FreeSpinProp = FreespinReel.getFreeSpinProperties();
            }
            else
            {
                m_bRecover = true;
                int[] reelstops = StringUtility.StringToIntArray(dataList["BGRS"], ' ');
                m_SlotReels[0].Recover(reelstops, iBetAmount);
                m_Stage = STAGE.STAGE_IDLE;
            }
        }
コード例 #2
0
        private void EvaluateTriggerLines()
        {
            for (int triggerSymIndex = 0; triggerSymIndex < m_TriggerSymbols.Count; triggerSymIndex++)
            {
                int symCount = 0;
                // bool bSymbolFound = false;

                for (int i = 0; i < m_SlotColumns.Count; i++)
                {
                    //bSymbolFound = false;
                    for (int j = 0; j < m_SlotColumns[i].Length; j++)
                    {
                        if (m_SlotColumns[i][j] == m_TriggerSymbols[triggerSymIndex].iSymbolId)
                        {
                            //bSymbolFound = true;
                            symCount++;
                        }
                    }
                }
                if (symCount == m_TriggerSymbols[triggerSymIndex].iNumOfSymbols)
                {
                    m_SpinResult.ClearTiggerLine();
                    m_SpinResult.AddTriggerLine(m_TriggerSymbols[triggerSymIndex]);
                }
            }
        }
コード例 #3
0
        public virtual void PlayGameSimulator(int betAmount = 1)
        {
            m_iBetLevel = 1;
            if (m_Stage == STAGE.STAGE_IDLE || m_Stage == STAGE.STAGE_IDLE)
            {
                //m_FSReelStops.Clear();
                m_SpinResult.ClearTiggerLine();
                m_TriggeredSlotFeatures.Clear();
                m_SpinResult.ResetFlags();

                if (m_sForceStop != "" && m_bForceSpin)
                {
                    try
                    {
                        m_CurrentSlotReel.SetForceSpin(m_sForceStop, true);
                    }
                    catch (Exception e)
                    {
                        ThrowError("GAME ENGINE ERROR! Force Ticket ");
                        Log("GameEngine Error! SlotEngine::PlayThread() - Parse ticket error " + e.Message);
                    }
                }

                else if (m_sFSForceStop != "" && m_bFSForceSpin)
                {
                    try
                    {
                        m_CurrentSlotReel.SetForceSpin(m_sFSForceStop, true);
                    }
                    catch (Exception e)
                    {
                        ThrowError("GAME ENGINE ERROR! Force Ticket ");
                        Log("GameEngine Error! SlotEngine::PlayThread() - Parse ticket error " + e.Message);
                    }
                }

                m_SpinResult = m_CurrentSlotReel.PlayGame(betAmount);
                int[] spinResults = m_SpinResult.getReelStops();

                m_Stage = STAGE.STAGE_STARTGAME;
                m_SpinResult.BaseWinAmount = m_SpinResult.getWinAmount();
                // m_iBaseWinAmount = m_SpinResult.BaseWinAmount;
                m_Stage = STAGE.STAGE_IDLE;
                if (!m_SpinResult.FreePlay)
                {
                    m_Stage = STAGE.STAGE_IDLE;
                    m_SpinResult.FreePlay = false;
                }
                else
                {
                    m_Stage = STAGE.STAGE_FREESPIN;
                }
                m_SpinResult.ReadyForSpin = true;


                PlaySlotFeatures();
                PlayBonusGame();

                GameResults(m_SpinResult);
#if _SIMULATOR
                m_CurrentSlotReel.CollectStatistics();  //NEED TO RECHECK THIS
#endif
            }

            /*       else if (m_Stage == STAGE.STAGE_FREESPIN)
             *     {
             *         m_SpinResult = m_FreespinSlot.PlayGame((int)betAmount, true);
             *         List<int> reelStops = new List<int>();
             *
             *         if (!m_SpinResult.FreePlay)
             *         {
             *             m_Stage = STAGE.STAGE_IDLE;
             *             m_SpinResult.FreePlay = false;
             *         }
             *         m_SpinResult.ReadyForSpin = true;
             *         GameResults(m_SpinResult);
             *     }*/
        }