summaryrefslogtreecommitdiffstats
path: root/scene/3d/fog_volume.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scene/3d/fog_volume.cpp')
-rw-r--r--scene/3d/fog_volume.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/scene/3d/fog_volume.cpp b/scene/3d/fog_volume.cpp
index 12ca1888c4..8af386f282 100644
--- a/scene/3d/fog_volume.cpp
+++ b/scene/3d/fog_volume.cpp
@@ -73,9 +73,7 @@ bool FogVolume::_get(const StringName &p_name, Variant &r_property) const {
void FogVolume::set_size(const Vector3 &p_size) {
size = p_size;
- size.x = MAX(0.0, size.x);
- size.y = MAX(0.0, size.y);
- size.z = MAX(0.0, size.z);
+ size = size.max(Vector3());
RS::get_singleton()->fog_volume_set_size(_get_volume(), size);
update_gizmos();
}