clouds: maximum offset

This commit is contained in:
Moritz Zwerger 2023-12-15 12:24:36 +01:00
parent 5cc1daabd9
commit 5a816d1403
No known key found for this signature in database
GPG Key ID: 5CAD791931B09AC4

View File

@ -165,6 +165,9 @@ class CloudRenderer(
val over = (baseHeight - y)
if (over > 0.0f) {
yOffset = -(over / 15.0f).pow(2)
if (yOffset < -100.0f) {
yOffset = -100.0f
}
}
shader.yOffset = yOffset
}