Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicholas Bishop <nicholasbishop@gmail.com>2009-01-02 05:37:54 +0300
committerNicholas Bishop <nicholasbishop@gmail.com>2009-01-02 05:37:54 +0300
commitada3868efdfb49bc24c4ee789aa53d66383d4658 (patch)
tree52051afe20b81307ed5a2cecf2f191a5dae1ed6a
parentd812fc0bd0fc4414ab18e5a9eeb4a5caec7680a6 (diff)
Added RNA for Hook modifier.
-rw-r--r--source/blender/makesrna/intern/rna_modifier.c19
1 files changed, 18 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/rna_modifier.c b/source/blender/makesrna/intern/rna_modifier.c
index d3818aa9aa7..4de2b411d93 100644
--- a/source/blender/makesrna/intern/rna_modifier.c
+++ b/source/blender/makesrna/intern/rna_modifier.c
@@ -454,11 +454,28 @@ static void rna_def_modifier_armature(BlenderRNA *brna)
static void rna_def_modifier_hook(BlenderRNA *brna)
{
StructRNA *srna;
- PropertyRNA *property;
+ PropertyRNA *prop;
srna= RNA_def_struct(brna, "HookModifier", "Modifier");
RNA_def_struct_ui_text(srna, "Hook Modifier", "Hook Modifier.");
RNA_def_struct_sdna(srna, "HookModifierData");
+
+ prop= RNA_def_property(srna, "falloff", PROP_FLOAT, PROP_NONE);
+ RNA_def_property_range(prop, 0, FLT_MAX);
+ RNA_def_property_ui_range(prop, 0, 100, 100, 2);
+ RNA_def_property_ui_text(prop, "Falloff", "If not zero, the distance from the hook where influence ends.");
+
+ prop= RNA_def_property(srna, "force", PROP_FLOAT, PROP_NONE);
+ RNA_def_property_range(prop, 0, 1);
+ RNA_def_property_ui_text(prop, "Force", "Relative force of the hook.");
+
+ prop= RNA_def_property(srna, "object", PROP_POINTER, PROP_NONE);
+ RNA_def_property_struct_type(prop, "ID");
+ RNA_def_property_ui_text(prop, "Object", "Parent Object for hook, also recalculates and clears offset");
+
+ prop= RNA_def_property(srna, "vertex_group", PROP_STRING, PROP_NONE);
+ RNA_def_property_string_sdna(prop, NULL, "name");
+ RNA_def_property_ui_text(prop, "Vertex Group", "Vertex group name.");
}
static void rna_def_modifier_softbody(BlenderRNA *brna)