mirror of
https://gitlab.bixilon.de/bixilon/minosoft.git
synced 2025-09-17 11:24:56 -04:00
improve multi layer clouds
This commit is contained in:
parent
61e382f693
commit
0096711844
@ -39,7 +39,7 @@ class CloudArray(
|
|||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
val start = (this.offset * ARRAY_SIZE + Vec2i(x, z) + layer.index) * CLOUD_SIZE
|
val start = (this.offset * ARRAY_SIZE + Vec2i(x, z) + (layer.index * ARRAY_SIZE)) * CLOUD_SIZE
|
||||||
|
|
||||||
val cull = booleanArrayOf(
|
val cull = booleanArrayOf(
|
||||||
matrix[matrixX + 0, matrixZ - 1], // NORTH
|
matrix[matrixX + 0, matrixZ - 1], // NORTH
|
||||||
|
@ -115,7 +115,7 @@ class CloudsLayer(
|
|||||||
val day = sky.time.day
|
val day = sky.time.day
|
||||||
if (day != this.day) {
|
if (day != this.day) {
|
||||||
this.day = day
|
this.day = day
|
||||||
randomSpeed = Random(index.toLong().murmur64() * sky.time.age.murmur64()).nextFloat(0.0f, 0.1f)
|
randomSpeed = Random(index.toLong().murmur64() * (sky.time.age + 1000L).murmur64()).nextFloat(0.0f, 0.1f)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -125,7 +125,7 @@ class CloudsLayer(
|
|||||||
}
|
}
|
||||||
|
|
||||||
private fun getCloudSpeed(): Float {
|
private fun getCloudSpeed(): Float {
|
||||||
return randomSpeed + 0.1f
|
return randomSpeed + 0.05f
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun updateOffset() {
|
private fun updateOffset() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user