summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2019-05-24 15:45:24 +0200
committerGitHub <noreply@github.com>2019-05-24 15:45:24 +0200
commitd1b4b62eb576e2374af1446850d7ac54662fea58 (patch)
tree75e4db5451f4d21aae415ea50710af14c8ec6e54
parent8689af62385bbfd7494c534d26346e791d4c2017 (diff)
parent5e9400b2e3f4d54d1c8f7227c01580276de2bbdb (diff)
Merge pull request #29133 from KoBeWi/ninja_modulate
Don't modulate canvas on invisible color change
-rw-r--r--scene/2d/canvas_modulate.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/2d/canvas_modulate.cpp b/scene/2d/canvas_modulate.cpp
index bd7bb97b03..009d664462 100644
--- a/scene/2d/canvas_modulate.cpp
+++ b/scene/2d/canvas_modulate.cpp
@@ -70,7 +70,7 @@ void CanvasModulate::_bind_methods() {
void CanvasModulate::set_color(const Color &p_color) {
color = p_color;
- if (is_inside_tree()) {
+ if (is_visible_in_tree()) {
VS::get_singleton()->canvas_set_modulate(get_canvas(), color);
}
}