public void SetAddMode(ModuleWaterfallFX fxModule)
        {
            showWindow        = true;
            module            = fxModule;
            windowMode        = ModifierPopupMode.Add;
            parentErrorString = "";

            workflowOptions = Enum.GetNames(typeof(AssetWorkflow)).ToArray();
            workflowFlag    = 0;
            var modelOpts = new List <string>();

            models = WaterfallAssets.GetModels((AssetWorkflow)Enum.Parse(typeof(AssetWorkflow), workflowOptions[workflowFlag]));
            foreach (var w in models)
            {
                modelOpts.Add($"<b>{w.Name}</b>\n{w.Description}\n{w.Path}");
            }

            modelOptions = modelOpts.ToArray();

            var shaderOpts = new List <string>();

            shaders = WaterfallAssets.GetShaders((AssetWorkflow)Enum.Parse(typeof(AssetWorkflow), workflowOptions[workflowFlag]));
            foreach (var w in shaders)
            {
                shaderOpts.Add($"<b>{w.Name}</b>\n{w.Description}");
            }

            shaderOptions  = shaderOpts.ToArray();
            WindowPosition = new(Screen.width / 2, Screen.height / 2f, 750, 400);
        }
 public void SetDeleteMode(ModuleWaterfallFX fxModule, WaterfallEffect fx)
 {
     showWindow     = true;
     module         = fxModule;
     effect         = fx;
     windowMode     = ModifierPopupMode.Delete;
     WindowPosition = new(Screen.width / 2 - 100, Screen.height / 2f - 50, 200, 100);
 }
예제 #3
0
 public void SetDeleteMode(WaterfallEffect fx, EffectModifier mod)
 {
     showWindow = true;
     modifier   = mod;
     effect     = fx;
     windowMode = ModifierPopupMode.Delete;
     GUI.BringWindowToFront(windowID);
 }
예제 #4
0
 public void SetDeleteMode(WaterfallEffect fx, EffectModifier mod)
 {
     showWindow     = true;
     modifier       = mod;
     effect         = fx;
     windowMode     = ModifierPopupMode.Delete;
     WindowPosition = new Rect(Screen.width / 2 - 100, Screen.height / 2f - 50, 200, 100);
 }
예제 #5
0
        public void SetAddMode(ModuleWaterfallFX fxModule)
        {
            showWindow = true;
            module     = fxModule;
            windowMode = ModifierPopupMode.Add;

            modelOptions   = WaterfallAssets.Models.Keys.ToArray();
            shaderOptions  = ShaderLoader.GetAllShadersNames().ToArray();
            WindowPosition = new Rect(Screen.width / 2, Screen.height / 2f, 750, 400);
        }
예제 #6
0
        public void SetAddMode(WaterfallEffect fx)
        {
            showWindow      = true;
            effect          = fx;
            windowMode      = ModifierPopupMode.Add;
            controllerTypes = fx.parentModule.GetControllerNames().ToArray();

            List <Transform> xFormOptions = fx.GetModelTransforms()[0].GetComponentsInChildren <Transform>().ToList();

            transformOptions = new string[xFormOptions.Count];
            for (int i = 0; i < xFormOptions.Count; i++)
            {
                transformOptions[i] = xFormOptions[i].name;
            }
            WindowPosition = new Rect(Screen.width / 2, Screen.height / 2f, 750, 400);
        }
예제 #7
0
        public void SetAddMode(WaterfallEffect fx)
        {
            showWindow      = true;
            effect          = fx;
            windowMode      = ModifierPopupMode.Add;
            controllerTypes = fx.parentModule.GetControllerNames().ToArray();

            var xFormOptions = fx.GetModelTransforms()[0].GetComponentsInChildren <Transform>().ToList();

            modifierFlag     = 0;
            transformOptions = new string[xFormOptions.Count];
            for (int i = 0; i < xFormOptions.Count; i++)
            {
                transformOptions[i] = xFormOptions[i].name;
            }

            GUI.BringWindowToFront(windowID);
        }