Example #1
0
        private void BuildPlatformLists()
        {
            if (MissingPlatforms == null)
            {
                MissingPlatforms = new List <Platform>();
                ParentCandidates = new List <Platform>();

                Settings settings = target as Settings;

                settings.ForEachPlatform(platform =>
                {
                    if (!platform.Active)
                    {
                        MissingPlatforms.Add(platform);
                    }
                    else if (!platform.IsIntrinsic)
                    {
                        ParentCandidates.Add(platform);
                    }
                });

                MissingPlatforms.Sort(CompareDisplayNames);
                ParentCandidates.Sort(CompareDisplayNames);
            }
        }
Example #2
0
        private void ClearPlatformSettings()
        {
            RemovePlatformFromAsset(RuntimeSettings.DefaultPlatform);
            RemovePlatformFromAsset(RuntimeSettings.PlayInEditorPlatform);

            RuntimeSettings.ForEachPlatform(RemovePlatformFromAsset);

            foreach (Platform platform in Resources.LoadAll <Platform>(Settings.SettingsAssetName))
            {
                RemovePlatformFromAsset(platform);
            }

            RuntimeSettings.DefaultPlatform      = null;
            RuntimeSettings.PlayInEditorPlatform = null;

            RuntimeSettings.Platforms.Clear();
            PlatformForBuildTarget.Clear();
            RuntimeSettings.PlatformForRuntimePlatform.Clear();
        }