Fix (unreported) LibOverride: hair cache settings not working.

Thanks to that same point cache being exposed in **four** different RNA
paths (twice in particle system, and twice in its embedded cloth
simulation settings).

Only way is to also make particle system overridable.
This commit is contained in:
Bastien Montagne 2021-01-22 11:39:56 +01:00
parent 0373d1b09f
commit cd8893d446
Notes: blender-bot 2023-02-14 09:48:25 +01:00
Referenced by issue #82503, Add Support of PointCaches to Library Overrides
1 changed files with 4 additions and 1 deletions

View File

@ -3656,6 +3656,8 @@ static void rna_def_particle_system(BlenderRNA *brna)
RNA_def_property_string_funcs(prop, NULL, NULL, "rna_ParticleSystem_name_set");
RNA_def_struct_name_property(srna, prop);
RNA_define_lib_overridable(true);
/* access to particle settings is redirected through functions */
/* to allow proper id-buttons functionality */
prop = RNA_def_property(srna, "settings", PROP_POINTER, PROP_NONE);
@ -3715,7 +3717,6 @@ static void rna_def_particle_system(BlenderRNA *brna)
prop = RNA_def_property(srna, "reactor_target_object", PROP_POINTER, PROP_NONE);
RNA_def_property_pointer_sdna(prop, NULL, "target_ob");
RNA_def_property_flag(prop, PROP_EDITABLE);
RNA_def_property_override_flag(prop, PROPOVERRIDE_OVERRIDABLE_LIBRARY);
RNA_def_property_ui_text(prop,
"Reactor Target Object",
"For reactor systems, the object that has the target particle system "
@ -3993,6 +3994,8 @@ static void rna_def_particle_system(BlenderRNA *brna)
prop, "Timestep", "The current simulation time step size, as a fraction of a frame");
RNA_def_property_clear_flag(prop, PROP_EDITABLE);
RNA_define_lib_overridable(false);
RNA_def_struct_path_func(srna, "rna_ParticleSystem_path");
/* extract cached hair location data */