/// <summary> /// 默认配置初始化 /// </summary> public void initDefCfg(string[] keys, string[] values) { GETAssert.isTrue(keys != null && values != null, "初始化参数不能为空"); GETAssert.isTrue(keys.Length == values.Length, "key,value需要一一对应!"); cfgMap.Clear(); for (int i = 0; i < keys.Length; i++) { cfgMap[keys[i]] = values[i]; } }
private void checkShowMain() { if (ui_MainUI) { ui_MainUI.SetActive(!ui_MainUI.IsActive()); } else { //创建控件 AssetsMgr.A.LoadAsync(typeof(GameObject), "get/TMainUI", false, (o, p) => { if (ui_MainUI) { return; } GameObject root = GoTools.AddForever(o as GameObject); ui_MainUI = root.transform.FindChild("GETLevels").gameObject; GETAssert.notNull(ui_MainUI, "没有找到预设:GETLevels"); }); } }
public GETConfig(string fileName) { GETAssert.isTrue(fileName != null && !"".Equals(fileName), "配置文件不能为空对象"); mFileName = fileName; }