aboutsummaryrefslogtreecommitdiff
path: root/src/client/sky.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/sky.h')
-rw-r--r--src/client/sky.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/client/sky.h b/src/client/sky.h
index 602876797..9102db4d4 100644
--- a/src/client/sky.h
+++ b/src/client/sky.h
@@ -98,7 +98,8 @@ public:
}
void setBodyOrbitTilt(float body_orbit_tilt)
{
- m_sky_params.body_orbit_tilt = body_orbit_tilt;
+ if (body_orbit_tilt != SkyboxParams::INVALID_SKYBOX_TILT)
+ m_sky_params.body_orbit_tilt = rangelim(body_orbit_tilt, -90.f, 90.f);
}
void overrideColors(video::SColor bgcolor, video::SColor skycolor)
{