diff options
author | Alexander Gavrilov <angavrilov@gmail.com> | 2021-01-09 22:24:48 +0300 |
---|---|---|
committer | Alexander Gavrilov <angavrilov@gmail.com> | 2021-02-02 23:03:16 +0300 |
commit | 78ff8526808a4fbc3d261155b1e6f873247ff8ce (patch) | |
tree | e154dc0541c268c64947ddef87ae4a4f34ebf8ec /release/scripts/startup/bl_ui/properties_physics_field.py | |
parent | 64a963486f7b20f8db480be9cb894eb28e79ac57 (diff) |
Force Fields: implement early filtering by the Affect flags.
Most fields have Affect Location and Rotation options that switch
off their effect, but they are only checked as the last step after
the force is already computed. It is more efficient to check it
when building the list of field objects, just like zero weight.
It is also possible to check the strength-related fields for 0.
As an aside, this adds Location to Texture fields (they don't
handle rotation) and both Location & Rotation checkboxes to
Fluid Flow. Boid and Curve Guide remain without options for
now as they are completely different from others.
Differential Revision: https://developer.blender.org/D10087
Diffstat (limited to 'release/scripts/startup/bl_ui/properties_physics_field.py')
-rw-r--r-- | release/scripts/startup/bl_ui/properties_physics_field.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/release/scripts/startup/bl_ui/properties_physics_field.py b/release/scripts/startup/bl_ui/properties_physics_field.py index c8c49ee02b0..7e017b121b3 100644 --- a/release/scripts/startup/bl_ui/properties_physics_field.py +++ b/release/scripts/startup/bl_ui/properties_physics_field.py @@ -118,6 +118,9 @@ class PHYSICS_PT_field_settings(PhysicButtonsPanel, Panel): col.prop(field, "strength") + sub = col.column(heading="Affect") + sub.prop(field, "apply_to_location", text="Location") + col = flow.column() col.prop(field, "texture_nabla") col.prop(field, "use_object_coords") @@ -128,6 +131,10 @@ class PHYSICS_PT_field_settings(PhysicButtonsPanel, Panel): col.prop(field, "strength") col.prop(field, "flow") + sub = col.column(heading="Affect") + sub.prop(field, "apply_to_location", text="Location") + sub.prop(field, "apply_to_rotation", text="Rotation") + col = flow.column() col.prop(field, "source_object") col.prop(field, "use_smoke_density") |