From 4d382ffadfa8e04f96ad00c26a1bff6c0bbbcd7e Mon Sep 17 00:00:00 2001 From: Simon Wendsche Date: Tue, 27 Nov 2018 01:22:10 +0100 Subject: [PATCH] use object filtering in smoke data node --- nodes/textures/smoke.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/nodes/textures/smoke.py b/nodes/textures/smoke.py index e18cf108..4b9f79f7 100644 --- a/nodes/textures/smoke.py +++ b/nodes/textures/smoke.py @@ -14,8 +14,12 @@ class LuxCoreNodeTexSmoke(LuxCoreNodeTexture): bl_label = "Smoke" bl_width_default = 200 + + def poll_domain(self, obj): + # Only allow objects with a smoke modifier in domain mode to be picked + return utils.find_smoke_domain_modifier(obj) - domain = PointerProperty(name="Domain", type=bpy.types.Object) + domain = PointerProperty(name="Domain", type=bpy.types.Object, poll=poll_domain) def update_source(self, context): value_output = self.outputs["Value"]