public override void OnInspectorGUI(ParticleSystem s)
 {
   if (SizeByVelocityModuleUI.s_Texts == null)
     SizeByVelocityModuleUI.s_Texts = new SizeByVelocityModuleUI.Texts();
   ModuleUI.GUIMinMaxCurve(SizeByVelocityModuleUI.s_Texts.size, this.m_Curve);
   ModuleUI.GUIMinMaxRange(SizeByVelocityModuleUI.s_Texts.velocityRange, this.m_Range);
 }
Exemplo n.º 2
0
 public override void OnInspectorGUI(ParticleSystem s)
 {
     if (SizeByVelocityModuleUI.s_Texts == null)
     {
         SizeByVelocityModuleUI.s_Texts = new SizeByVelocityModuleUI.Texts();
     }
     ModuleUI.GUIMinMaxCurve(SizeByVelocityModuleUI.s_Texts.size, this.m_Curve);
     ModuleUI.GUIMinMaxRange(SizeByVelocityModuleUI.s_Texts.velocityRange, this.m_Range);
 }
 protected override void Init()
 {
   if (this.m_Curve != null)
     return;
   if (SizeByVelocityModuleUI.s_Texts == null)
     SizeByVelocityModuleUI.s_Texts = new SizeByVelocityModuleUI.Texts();
   this.m_Curve = new SerializedMinMaxCurve((ModuleUI) this, SizeByVelocityModuleUI.s_Texts.size);
   this.m_Curve.m_AllowConstant = false;
   this.m_Range = this.GetProperty("range");
 }
Exemplo n.º 4
0
 protected override void Init()
 {
     if (this.m_Curve != null)
     {
         return;
     }
     if (SizeByVelocityModuleUI.s_Texts == null)
     {
         SizeByVelocityModuleUI.s_Texts = new SizeByVelocityModuleUI.Texts();
     }
     this.m_Curve = new SerializedMinMaxCurve(this, SizeByVelocityModuleUI.s_Texts.size);
     this.m_Curve.m_AllowConstant = false;
     this.m_Range = base.GetProperty("range");
 }
Exemplo n.º 5
0
 protected override void Init()
 {
     if (this.m_X == null)
     {
         if (SizeByVelocityModuleUI.s_Texts == null)
         {
             SizeByVelocityModuleUI.s_Texts = new SizeByVelocityModuleUI.Texts();
         }
         this.m_X = new SerializedMinMaxCurve(this, SizeByVelocityModuleUI.s_Texts.x, "curve");
         this.m_X.m_AllowConstant = false;
         this.m_Y = new SerializedMinMaxCurve(this, SizeByVelocityModuleUI.s_Texts.y, "y");
         this.m_Y.m_AllowConstant = false;
         this.m_Z = new SerializedMinMaxCurve(this, SizeByVelocityModuleUI.s_Texts.z, "z");
         this.m_Z.m_AllowConstant = false;
         this.m_SeparateAxes      = base.GetProperty("separateAxes");
         this.m_Range             = base.GetProperty("range");
     }
 }
Exemplo n.º 6
0
        public override void OnInspectorGUI(ParticleSystem s)
        {
            if (SizeByVelocityModuleUI.s_Texts == null)
            {
                SizeByVelocityModuleUI.s_Texts = new SizeByVelocityModuleUI.Texts();
            }
            EditorGUI.BeginChangeCheck();
            bool flag = ModuleUI.GUIToggle(SizeByVelocityModuleUI.s_Texts.separateAxes, this.m_SeparateAxes, new GUILayoutOption[0]);

            if (EditorGUI.EndChangeCheck())
            {
                if (flag)
                {
                    this.m_X.RemoveCurveFromEditor();
                }
                else
                {
                    this.m_X.RemoveCurveFromEditor();
                    this.m_Y.RemoveCurveFromEditor();
                    this.m_Z.RemoveCurveFromEditor();
                }
            }
            SerializedMinMaxCurve arg_9C_0 = this.m_Z;
            MinMaxCurveState      state    = this.m_X.state;

            this.m_Y.state = state;
            arg_9C_0.state = state;
            MinMaxCurveState state2 = this.m_Z.state;

            if (flag)
            {
                this.m_X.m_DisplayName = SizeByVelocityModuleUI.s_Texts.x;
                base.GUITripleMinMaxCurve(GUIContent.none, SizeByVelocityModuleUI.s_Texts.x, this.m_X, SizeByVelocityModuleUI.s_Texts.y, this.m_Y, SizeByVelocityModuleUI.s_Texts.z, this.m_Z, null, new GUILayoutOption[0]);
            }
            else
            {
                this.m_X.m_DisplayName = SizeByVelocityModuleUI.s_Texts.size;
                ModuleUI.GUIMinMaxCurve(SizeByVelocityModuleUI.s_Texts.size, this.m_X, new GUILayoutOption[0]);
            }
            using (new EditorGUI.DisabledScope(state2 == MinMaxCurveState.k_Scalar || state2 == MinMaxCurveState.k_TwoScalars))
            {
                ModuleUI.GUIMinMaxRange(SizeByVelocityModuleUI.s_Texts.velocityRange, this.m_Range, new GUILayoutOption[0]);
            }
        }
Exemplo n.º 7
0
        public override void OnInspectorGUI(InitialModuleUI initial)
        {
            if (SizeByVelocityModuleUI.s_Texts == null)
            {
                SizeByVelocityModuleUI.s_Texts = new SizeByVelocityModuleUI.Texts();
            }
            EditorGUI.BeginChangeCheck();
            bool flag = ModuleUI.GUIToggle(SizeByVelocityModuleUI.s_Texts.separateAxes, this.m_SeparateAxes, new GUILayoutOption[0]);

            if (EditorGUI.EndChangeCheck())
            {
                if (flag)
                {
                    this.m_X.RemoveCurveFromEditor();
                }
                else
                {
                    this.m_X.RemoveCurveFromEditor();
                    this.m_Y.RemoveCurveFromEditor();
                    this.m_Z.RemoveCurveFromEditor();
                }
            }
            if (!this.m_X.stateHasMultipleDifferentValues)
            {
                this.m_Z.SetMinMaxState(this.m_X.state, flag);
                this.m_Y.SetMinMaxState(this.m_X.state, flag);
            }
            MinMaxCurveState state = this.m_Z.state;

            if (flag)
            {
                this.m_X.m_DisplayName = SizeByVelocityModuleUI.s_Texts.x;
                base.GUITripleMinMaxCurve(GUIContent.none, SizeByVelocityModuleUI.s_Texts.x, this.m_X, SizeByVelocityModuleUI.s_Texts.y, this.m_Y, SizeByVelocityModuleUI.s_Texts.z, this.m_Z, null, new GUILayoutOption[0]);
            }
            else
            {
                this.m_X.m_DisplayName = SizeByVelocityModuleUI.s_Texts.size;
                ModuleUI.GUIMinMaxCurve(SizeByVelocityModuleUI.s_Texts.size, this.m_X, new GUILayoutOption[0]);
            }
            using (new EditorGUI.DisabledScope(state == MinMaxCurveState.k_Scalar || state == MinMaxCurveState.k_TwoScalars))
            {
                ModuleUI.GUIMinMaxRange(SizeByVelocityModuleUI.s_Texts.velocityRange, this.m_Range, new GUILayoutOption[0]);
            }
        }