예제 #1
0
        public void Setter()
        {
            INIFile tnIni = new INIFile(iniPath);

            Const.SetIniTimeStamp(tnIni);
            tnIni.SetValue(tnmtSec, tnS_tnmtName, tnmtName);
            tnIni.SetValue(tnmtSec, tnS_tnmtRunCnt, Convert.ToString(tnmtRunCnt));
        }
예제 #2
0
파일: Player.cs 프로젝트: dFlow3000/PW3000
        public void Setter()
        {
            INIFile pIni = new INIFile(iniPath);

            Const.SetIniTimeStamp(pIni);
            string strId = Convert.ToString(this.playerId);

            pIni.SetValue(playerSec + strId, pS_playerId, strId);
            pIni.SetValue(playerSec + strId, pS_firstname, this.playerFirstname);
            pIni.SetValue(playerSec + strId, pS_lastname, this.playerLastname);
            pIni.SetValue(playerSec + strId, pS_payed, Convert.ToString(this.payedStartFee));
        }
예제 #3
0
파일: Player.cs 프로젝트: dFlow3000/PW3000
        public void Setter(Player i_player)
        {
            INIFile pIni = new INIFile(iniPath);

            Const.SetIniTimeStamp(pIni);
            string strId = Convert.ToString(i_player.playerId);

            pIni.SetValue(playerSec + strId, pS_playerId, strId);
            pIni.SetValue(playerSec + strId, pS_firstname, i_player.playerFirstname);
            pIni.SetValue(playerSec + strId, pS_lastname, i_player.playerLastname);
            pIni.SetValue(playerSec + strId, pS_payed, pS_payed_def);
        }
예제 #4
0
        public static INIFile CreateIniFile(string i_iniPath)
        {
            INIFile newIniFile = new INIFile(i_iniPath, true);

            newIniFile.SetValue(Const.fileSec, Const.fs_InitState, Const.fs_InitState_def);
            Const.SetIniTimeStamp(newIniFile);

            #region Special Keys for specific ini-Files ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
            if (i_iniPath == Log.iniPath)
            {
                // For log ini-File
                newIniFile.SetValue(Const.fileSec, Log.fsX_logCnt, Log.fsX_logCnt_def);
            }
            else if (i_iniPath == Team.iniPath)
            {
                // For team ini-File
                newIniFile.SetValue(Const.fileSec, Team.fsX_teamCnt, Team.fsX_teamCnt_def);
            }
            else if (i_iniPath == Player.iniPath)
            {
                // For Player ini-File
                newIniFile.SetValue(Const.fileSec, Player.fsX_playerCnt, Player.fsX_playerCnt_def);
            }
            else if (i_iniPath == Game.iniPath)
            {
                // For Game ini-File
                newIniFile.SetValue(Const.fileSec, Game.fsX_gameCnt, Game.fsX_gameCnt_def);
            }
            else if (i_iniPath == Table.iniPath)
            {
                // For Table ini-File
                newIniFile.SetValue(Const.fileSec, Table.fsX_tableCnt, Table.fsX_tableCnt_def);
                newIniFile.SetValue(Const.fileSec, Table.fsX_tableSecCnt, Table.fsX_tableSecCnt_def);
            }
            else if (i_iniPath == Tournament.iniPath)
            {
                // For Tournament ini-File
                newIniFile.SetValue(Const.fileSec, Tournament.fsX_prepMode, Tournament.fsX_prepMode_def);
                newIniFile.SetValue(Const.fileSec, Tournament.fsX_SpecTnmtPath, Tournament.fsX_SpecTnmtPath_def);
                newIniFile.SetValue(Const.fileSec, Tournament.fsX_allKey, Tournament.fsX_allKey_def);
                newIniFile.SetValue(Const.fileSec, Tournament.fsX_ColorMode, Tournament.fsX_ColorMode_def);
            }
            else if (i_iniPath == SignedUpTeam.iniPath)
            {
                // For SignedUpTeam ini-File
                newIniFile.SetValue(Const.fileSec, SignedUpTeam.fsX_suTeamCnt, SignedUpTeam.fsX_suTeamCnt_def);
            }
            #endregion

            Log.Create(i_iniPath);
            return(newIniFile);
        }
예제 #5
0
        public void SetCompleteState(int i_runId, bool i_state)
        {
            INIFile tnIni = new INIFile(Tournament.iniPath);

            Const.SetIniTimeStamp(tnIni);
            if (Const.CheckIdInRange(tnIni, Tournament.tnmtSec, Tournament.tnS_tnmtRunCnt, i_runId))
            {
                string strId = Convert.ToString(i_runId);
                tnIni.SetValue(Tournament.runSec + strId, Tournament.rS_runComplete, Convert.ToString(i_state));
                Log.Info("Run " + Convert.ToString(i_runId) + " completed");
            }
            else
            {
                Log.Error("Run-SetCompleteState input Id " + i_runId + " out of Range!");
            }
        }