예제 #1
0
        public static CampInfo InitInfo(int campID)
        {
            CampInfo info  = new CampInfo();
            var      _meta = CampModule.GetCampDataByKey(campID);

            if (_meta != null)
            {
                info.CampID   = _meta.CampID;
                info.campName = MultiLanguage.Instance.GetTextValue(_meta.CampName);
                info.campDesc = MultiLanguage.Instance.GetTextValue(_meta.CampDesc);

                info.campIconPath    = _meta.CampIcon;
                info.campBGSmallPath = _meta.CampBGSmall;

                info.hardLevel             = _meta.HardLevel;
                info.defualtHardLevelValue = _meta.DefaultHardLevel;

                info.creedInfo     = CampCreedInfo.InitInfo(_meta.CreedID);
                info.attributeInfo = CampModule.GetCampAttribueInfoList(_meta.CampID);

                ///Init DefaultLeader
                info.campLeaderList = CampModule.GetCampDefaultLeaderList(_meta.CampID);

                return(info);
            }
            DebugPlus.LogError("[CampInfo] : Init Fail! campID=" + campID);
            return(null);
        }
예제 #2
0
파일: GameManager.cs 프로젝트: EpicProj/RPG
        public CampInfo GetCampInfoData(int campID)
        {
            CampInfo result = null;

            result = campPrepareInfoList.Find(x => x.CampID == campID);
            if (result == null)
            {
                DebugPlus.LogError("GetCampData Info Null!  campID=" + campID);
            }
            return(result);
        }
예제 #3
0
        public static List <CampInfo> GetAllCampInfo()
        {
            List <CampInfo> result = new List <CampInfo>();

            foreach (var item in campDataDic.Values)
            {
                if (item.CampType == 1)
                {
                    CampInfo campInfo = CampInfo.InitInfo(item.CampID);
                    result.Add(campInfo);
                }
            }
            return(result);
        }
예제 #4
0
파일: PlayerData.cs 프로젝트: EpicProj/RPG
 public void ClearData()
 {
     currentCampInfo       = null;
     currentLeaderInfoList = null;
     hardLevelValue        = 0;
     prepareAIDataList.Clear();
     prepareAIDataList.Clear();
     GamePrepare_AI_Maintenance       = 0;
     GamePrepare_AI_Builder           = 0;
     GamePrepare_AI_Operator          = 0;
     GamePrepare_ResourceRichness     = 0;
     GamePrepare_Currency             = 0;
     GamePrepare_EnemyHardLevel       = 0;
     GamePrepare_Research_Coefficient = 0;
     GamePrepare_RoCore = 0;
 }
예제 #5
0
파일: DataManager.cs 프로젝트: EpicProj/RPG
 public void ChangeSelectCamp(CampInfo info)
 {
     gamePrepareData.currentCampInfo = info;
 }