bool LoadFile(string pathToFile) { if (!File.Exists(pathToFile)) { Debug.LogError("EgoXproject: Change file does not exist: " + pathToFile); return(false); } SavePath = pathToFile; PList p = new PList(); if (!p.Load(SavePath)) { return(false); } if (!Validate(p)) { return(false); } //set the platform. if non specified will default to ios BuildPlatform platform; if (p.Root.EnumValue(BUILD_PLATFORM_KEY, out platform)) { Platform = platform; } else { Platform = BuildPlatform.iOS; } //reset everything Frameworks.Clear(); FilesAndFolders.Clear(); BuildSettings.Clear(); Scripts.Clear(); Signing.Clear(); Capabilities.Clear(); //load everything InfoPlistChanges = p.Root.DictionaryValue(INFO_PLIST_KEY).Copy() as PListDictionary; AppConfig = p.Root.DictionaryValue(APP_CONFIG_KEY) != null?p.Root.DictionaryValue(APP_CONFIG_KEY).Copy() as PListDictionary : new PListDictionary(); AppConfigEnabled = p.Root.ArrayValue(APP_CONFIG_ENABLED_KEY) != null?p.Root.ArrayValue(APP_CONFIG_ENABLED_KEY).Copy() as PListArray : new PListArray(); ManualEntitlements = p.Root.DictionaryValue(MANUAL_ENTITLEMENTS) != null?p.Root.DictionaryValue(MANUAL_ENTITLEMENTS).Copy() as PListDictionary : new PListDictionary(); LoadFrameworks(p.Root.DictionaryValue(FRAMEWORKS_KEY)); LoadFilesAndFolders(p.Root.DictionaryValue(FILES_AND_FOLDERS_KEY)); LoadScripts(p.Root.ArrayValue(SCRIPTS_KEY)); LoadBuildSettings(p.Root.ArrayValue(BUILD_SETTINGS_KEY)); LoadSigning(p.Root.DictionaryValue(SIGNING_KEY)); LoadCapabilities(p.Root.DictionaryValue(CAPABILITIES_KEY)); IsDirty = false; return(true); }