diff options
author | tpart <tpart120@proton.me> | 2024-08-19 22:18:57 +0200 |
---|---|---|
committer | tpart <tpart120@proton.me> | 2024-08-19 22:18:57 +0200 |
commit | 312f5e017163b2622b3ea328cd44fc946d0efe8e (patch) | |
tree | 77431d983b4ee90f5160b77a099c5328e91d4cac /client/map/auto_setup/light_setup.gd | |
parent | 6e6c02c03a4c3a3cbc26e7c98436fd38c5a3931b (diff) | |
download | hurrycurry-312f5e017163b2622b3ea328cd44fc946d0efe8e.tar hurrycurry-312f5e017163b2622b3ea328cd44fc946d0efe8e.tar.bz2 hurrycurry-312f5e017163b2622b3ea328cd44fc946d0efe8e.tar.zst |
Completely disable freezer and oven lights when shadows are disabled
Diffstat (limited to 'client/map/auto_setup/light_setup.gd')
-rw-r--r-- | client/map/auto_setup/light_setup.gd | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/client/map/auto_setup/light_setup.gd b/client/map/auto_setup/light_setup.gd index f583b6a5..1e256dae 100644 --- a/client/map/auto_setup/light_setup.gd +++ b/client/map/auto_setup/light_setup.gd @@ -13,14 +13,18 @@ # You should have received a copy of the GNU Affero General Public License # along with this program. If not, see <https://www.gnu.org/licenses/>. # -extends DirectionalLight3D +extends Light3D class_name LightSetup +@export var completely_disable_light_if_shadows_disabled := false + func _ready(): apply_settings() Global.settings_changed.connect(apply_settings) func apply_settings(): + if completely_disable_light_if_shadows_disabled: + visible = Global.get_setting("shadows") shadow_enabled = Global.get_setting("shadows") func set_sky(sky_name: String): |