mirror of
https://gitlab.bixilon.de/bixilon/minosoft.git
synced 2025-09-16 10:55:01 -04:00
fix moon phase calculation on very very very (fake) old worlds
This commit is contained in:
parent
51d4a31e6c
commit
18798f6de6
@ -25,7 +25,7 @@ class WorldTime(
|
|||||||
|
|
||||||
val age = abs(age)
|
val age = abs(age)
|
||||||
|
|
||||||
val moonPhase = MoonPhases[this.age.toInt() / ProtocolDefinition.TICKS_PER_DAY % MoonPhases.VALUES.size] // ToDo: Verify
|
val moonPhase = MoonPhases[(this.age / ProtocolDefinition.TICKS_PER_DAY % MoonPhases.VALUES.size).toInt()] // ToDo: Verify
|
||||||
val phase = DayPhases.of(this.time)
|
val phase = DayPhases.of(this.time)
|
||||||
val progress = phase.getProgress(this.time)
|
val progress = phase.getProgress(this.time)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user