[Bf-blender-cvs] [9263098] fracture_modifier: fix: set cutter axis correctly (RNA called a different function there)

Martin Felke noreply at git.blender.org
Thu Aug 6 19:33:14 CEST 2015


Commit: 9263098a7f1f6d29f8d033fb214a74abfb7492ca
Author: Martin Felke
Date:   Thu Aug 6 19:33:05 2015 +0200
Branches: fracture_modifier
https://developer.blender.org/rB9263098a7f1f6d29f8d033fb214a74abfb7492ca

fix: set cutter axis correctly (RNA called a different function there)

===================================================================

M	source/blender/makesrna/intern/rna_modifier.c

===================================================================

diff --git a/source/blender/makesrna/intern/rna_modifier.c b/source/blender/makesrna/intern/rna_modifier.c
index 87fe822..65d5581 100644
--- a/source/blender/makesrna/intern/rna_modifier.c
+++ b/source/blender/makesrna/intern/rna_modifier.c
@@ -1028,6 +1028,13 @@ static void rna_FractureModifier_splinter_axis_set(PointerRNA* ptr, int value)
 	rmd->reset_shards = true;
 }
 
+static void rna_FractureModifier_cutter_axis_set(PointerRNA* ptr, int value)
+{
+	FractureModifierData *rmd = (FractureModifierData*)ptr->data;
+	rmd->cutter_axis = value;
+	rmd->reset_shards = true;
+}
+
 static void rna_FractureModifier_nor_range_set(PointerRNA* ptr, float value)
 {
 	FractureModifierData *rmd = (FractureModifierData*)ptr->data;
@@ -5045,7 +5052,7 @@ static void rna_def_modifier_fracture(BlenderRNA *brna)
 	prop = RNA_def_property(srna, "cutter_axis", PROP_ENUM, PROP_NONE);
 	RNA_def_property_enum_items(prop, prop_cutter_axises);
 	RNA_def_property_enum_default(prop, MOD_FRACTURE_CUTTER_Z);
-	RNA_def_property_enum_funcs(prop, NULL, "rna_FractureModifier_point_seed_set", NULL);
+	RNA_def_property_enum_funcs(prop, NULL, "rna_FractureModifier_cutter_axis_set", NULL);
 	RNA_def_property_ui_text(prop, "Cutter Axis", "Global direction of cutters");
 	RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
 	RNA_def_property_update(prop, 0, "rna_Modifier_update");




More information about the Bf-blender-cvs mailing list