From feef4792f2ec7175e0ac191a04e3e04eeed5f7d7 Mon Sep 17 00:00:00 2001 From: luboslenco Date: Fri, 9 Aug 2019 11:30:41 +0200 Subject: [PATCH] Update fill layers --- Sources/arm/ui/UITrait.hx | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/Sources/arm/ui/UITrait.hx b/Sources/arm/ui/UITrait.hx index 22fc60f8..d4650427 100644 --- a/Sources/arm/ui/UITrait.hx +++ b/Sources/arm/ui/UITrait.hx @@ -983,11 +983,19 @@ class UITrait { RenderUtil.makeDecalPreview(); ui.g.begin(false); } + if (Context.layer.material_mask != null) { + Layers.updateFillLayers(); + } } var brushRotHandle = Id.handle({value: brushRot}); brushRot = ui.slider(brushRotHandle, "UV Rotate", 0.0, 360.0, true, 1); - if (brushRotHandle.changed) MaterialParser.parsePaintMaterial(); + if (brushRotHandle.changed) { + MaterialParser.parsePaintMaterial(); + if (Context.layer.material_mask != null) { + Layers.updateFillLayers(); + } + } } brushOpacity = ui.slider(brushOpacityHandle, "Opacity", 0.0, 1.0, true); @@ -1003,6 +1011,9 @@ class UITrait { brushPaint = ui.combo(paintHandle, ["UV Map", "Project", "Triplanar"], "TexCoord"); if (paintHandle.changed) { MaterialParser.parsePaintMaterial(); + if (Context.layer.material_mask != null) { + Layers.updateFillLayers(); + } } } if (Context.tool == ToolDecal) {