예제 #1
0
        public void UnLoad()
        {
            if (tKinConfig != null)
            {
                tKinConfig = null;
            }

            if (tKinLevelMap != null)
            {
                tKinLevelMap.Clear();
                tKinLevelMap = null;
            }

            singleton = null;
        }
예제 #2
0
        // 初始化csv表
        protected void InitKinConfigCsv(string stPath)
        {
            // string stSchemeAllText = File.ReadAllText(stPath);
            ScpReader reader = new ScpReader(stPath, true, 2);

            tKinConfig = new SSchemeKinConfig();

            for (int i = 0; i < (int)KinConfigRow.EMT_ROW_MAX; i++)
            {
                switch (i)
                {
                case (int)KinConfigRow.EMT_ROW_CRETE_NEED_LEVEL:     // 创建战队需要的等级
                {
                    tKinConfig.nCreateNeedLevel = reader.GetInt(i, 1, 0);
                }
                break;

                case (int)KinConfigRow.EMT_ROW_CRETE_NEED_MONEY:       // 创建需要的金币
                {
                    tKinConfig.nCreateNeedMoney = reader.GetInt(i, 1, 0);
                }
                break;

                case (int)KinConfigRow.EMT_ROW_APPLY_NEED_LEVEL:       // 申请加入需要的等级
                {
                    tKinConfig.nApplyNeedLevel = reader.GetInt(i, 1, 0);
                }
                break;

                case (int)KinConfigRow.EMT_ROW_JOIN_KIN_FREEZE:       // 加入战队冷却
                {
                    tKinConfig.nJoinKinFreeze = reader.GetInt(i, 1, 0);
                }
                break;

                case (int)KinConfigRow.EMT_ROW_KIN_DETAIL_DES:       // 战队详细说明
                {
                    tKinConfig.sKinDetailDes = reader.GetString(i, 1, string.Empty);
                }
                break;

                default:
                    break;
                }
            }
        }