Пример #1
0
            public static WorkSaverSettings Apply(WorkSaverSettings settings)
            {
                settings.blinkCurve = BlinkCurve;

                settings.startBlinkColor = StartBlinkColor;
                settings.endBlinkColor   = EndBlinkColor;

                settings.minBlinkSpeed = MinBlinkSpeed;
                settings.maxBlinkSpeed = MaxBlinkSpeed;

                settings.timeForReachMaxBlinkSpeed = TimeForReachMaxBlinkSpeed;
                settings.timeBetweenSaves          = TimeBetweenSaves;

                return(settings);
            }
Пример #2
0
        public static WorkSaverSettings Create()
        {
            if (!Directory.Exists(FolderFullPath))
            {
                Directory.CreateDirectory(FolderFullPath);
            }

            WorkSaverSettings data = CreateInstance <WorkSaverSettings> ();

            data = Defaults.Apply(data);

            AssetDatabase.CreateAsset(data, DataFullPath);

            AssetDatabase.SaveAssets();
            AssetDatabase.Refresh();

            return(data);
        }