0 votes

Hey, I am working on a game, where as the timer hits zero, the "light" or so to say (foreground), goes black(dark), except for a figure and a few buttons. How can i do that?

I tried,
var colorblack = Color(0,0,0,1)

but it only sets the back ground black.


in Engine by (73 points)

1 Answer

0 votes

Clear color is to set how the display manages the screen buffer (to say it short).

You can use a CanvasModulate node to tint everything in a CanvasLayer.

But if you have things on many layers or mixed in a single one, maybe a big white light in substract mode could be better (opacity can be animated too), just change the light item mask and node's light masks to keep visible the ones you want.

by (7,850 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.