mirror of
https://gitlab.bixilon.de/bixilon/minosoft.git
synced 2025-09-16 19:05:02 -04:00
fullbright toggle key
This commit is contained in:
parent
797a293c27
commit
3ae19b2e1d
@ -21,7 +21,7 @@ import de.bixilon.minosoft.gui.rendering.world.light.updater.FullbrightLightUpda
|
||||
import de.bixilon.minosoft.gui.rendering.world.light.updater.LegacyLightmapUpdater
|
||||
import de.bixilon.minosoft.gui.rendering.world.light.updater.LightmapUpdater
|
||||
|
||||
class Lightmap(private val light: RenderLight) {
|
||||
class Lightmap(light: RenderLight) {
|
||||
private val profile = light.renderWindow.connection.profiles.rendering
|
||||
private val buffer = LightmapBuffer(light.renderWindow.renderSystem)
|
||||
private var updater: LightmapUpdater = FullbrightLightUpdater
|
||||
|
@ -41,6 +41,17 @@ class RenderLight(val renderWindow: RenderWindow) {
|
||||
connection.util.sendDebugMessage("Light recalculated and chunk cache cleared!")
|
||||
}
|
||||
}
|
||||
renderWindow.inputHandler.registerKeyCallback(
|
||||
"minosoft:toggle_fullbright".toResourceLocation(),
|
||||
KeyBinding(
|
||||
KeyActions.MODIFIER to setOf(KeyCodes.KEY_F4),
|
||||
KeyActions.CHANGE to setOf(KeyCodes.KEY_C),
|
||||
),
|
||||
defaultPressed = connection.profiles.rendering.light.fullbright,
|
||||
) {
|
||||
connection.profiles.rendering.light.fullbright = it
|
||||
connection.util.sendDebugMessage("Fullbright: $it")
|
||||
}
|
||||
}
|
||||
|
||||
fun updateAsync() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user