summaryrefslogtreecommitdiff
path: root/effects_constructors.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'effects_constructors.cpp')
-rw-r--r--effects_constructors.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/effects_constructors.cpp b/effects_constructors.cpp
index 04594b6..13fec9a 100644
--- a/effects_constructors.cpp
+++ b/effects_constructors.cpp
@@ -20,13 +20,14 @@ Effect_EndEntry(project_state *State)
}
static void
-Effect_AddProperty_Real(project_state *State, char *Name, real32 DefaultValue, real32 MinVal = -999999, real32 MaxVal = 999999)
+Effect_AddProperty_Real(project_state *State, char *Name, real32 DefaultValue, real32 MinVal = -999999, real32 MaxVal = 999999, property_display_type DisplayType = property_display_type_standard)
{
header_effect *Effect = &State->Effect[State->Playhead_Effect];
Effect->Property_Count++;
header_property *Property = &State->Property[State->Playhead_Property++];
Property->Name = Name;
Property->DefaultValue = DefaultValue;
+ Property->DisplayType = DisplayType;
Property->MinVal = MinVal;
Property->MaxVal = MaxVal;
}
@@ -34,10 +35,10 @@ Effect_AddProperty_Real(project_state *State, char *Name, real32 DefaultValue, r
static void
Effect_AddProperty_Col(project_state *State, char *Name, v4 DefaultValue)
{
- Effect_AddProperty_Real(State, "r", DefaultValue.r, 0, 1);
- Effect_AddProperty_Real(State, "g", DefaultValue.r, 0, 1);
- Effect_AddProperty_Real(State, "b", DefaultValue.r, 0, 1);
- Effect_AddProperty_Real(State, "a", DefaultValue.r, 0, 1);
+ Effect_AddProperty_Real(State, "r", DefaultValue.r, 0, 1, property_display_type_color);
+ Effect_AddProperty_Real(State, "g", DefaultValue.g, 0, 1, property_display_type_color);
+ Effect_AddProperty_Real(State, "b", DefaultValue.b, 0, 1, property_display_type_color);
+ Effect_AddProperty_Real(State, "a", DefaultValue.a, 0, 1, property_display_type_color);
}
static void