Add read-only property to check if any duplis are used. Without this, ob.create_dupli...
authorDaniel Genrich <daniel.genrich@gmx.net>
Sun, 2 May 2010 13:48:32 +0000 (13:48 +0000)
committerDaniel Genrich <daniel.genrich@gmx.net>
Sun, 2 May 2010 13:48:32 +0000 (13:48 +0000)
source/blender/makesrna/intern/rna_object.c

index 2ffab29862854c3576c8b9940144b7a6ebba1602..7a253ce85449c58f45fd6660d8a846f8daf25085 100644 (file)
@@ -1846,6 +1846,10 @@ static void rna_def_object(BlenderRNA *brna)
        RNA_def_property_struct_type(prop, "DupliObject");
        RNA_def_property_ui_text(prop, "Dupli list", "Object duplis");
 
+       prop= RNA_def_property(srna, "duplis_used", PROP_BOOLEAN, PROP_NONE);
+       RNA_def_property_boolean_sdna(prop, NULL, "transflag", OB_DUPLI);
+       RNA_def_property_clear_flag(prop, PROP_EDITABLE);
+
        /* time offset */
        prop= RNA_def_property(srna, "time_offset", PROP_FLOAT, PROP_NONE|PROP_UNIT_TIME);
        RNA_def_property_float_sdna(prop, NULL, "sf");