Skip to content

Commit

Permalink
fix sky color and block color when fog color is set
Browse files Browse the repository at this point in the history
  • Loading branch information
Bixilon committed Feb 29, 2024
1 parent 51993e1 commit 3fada12
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class FogManager(
private val player = context.connection.player

private var interpolation = FogInterpolationStart()
private val state = FogState()
val state = FogState()
private var options: FogOptions? = null


Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Minosoft
* Copyright (C) 2020-2023 Moritz Zwerger
* Copyright (C) 2020-2024 Moritz Zwerger
*
* This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
*
Expand Down Expand Up @@ -202,6 +202,7 @@ class SkyboxColor(


fun calculate(): RGBColor? {
sky.context.camera.fogManager.state.color?.let { return it }
val properties = sky.effects
val time = sky.time
if (properties.fixedTexture != null) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,6 @@ out vec4 foutColor;
#include "minosoft:animation"

void main() {
applyTexel();
applyTint();
applyTexel();
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,6 @@ out vec4 foutColor;
#include "minosoft:animation"

void main() {
applyTexel();
applyTint();
applyTexel();
}

0 comments on commit 3fada12

Please sign in to comment.