Compare commits

...

3 Commits

Author SHA1 Message Date
f7fc0b5a11
Bump version to 0.4.4
Signed-off-by: Username404-59 <w.iron.zombie@gmail.com>
2026-04-16 16:30:59 +02:00
f19244a51b
Fix crash in the SnowyConfigScreen
Signed-off-by: Username404-59 <w.iron.zombie@gmail.com>
2026-04-16 16:20:04 +02:00
740ccace0c
Update to 26.2-snapshot-1
Signed-off-by: Username404-59 <w.iron.zombie@gmail.com>
2026-04-16 16:13:02 +02:00
6 changed files with 15 additions and 12 deletions

View File

@ -23,7 +23,7 @@ plugins {
} }
group = "fr.username404" group = "fr.username404"
version = "0.4.3" version = "0.4.4"
val groupAndName = "${rootProject.group}.${rootProject.name.lowercase()}" val groupAndName = "${rootProject.group}.${rootProject.name.lowercase()}"
val javaVer: String = "25" val javaVer: String = "25"
@ -196,7 +196,7 @@ allprojects {
} }
val modProperties = mapOf( val modProperties = mapOf(
"mod_version" to (rootProject.version as String), "mod_version" to (rootProject.version as String),
"minecraft_version" to minecraftVersion, "minecraft_version" to minecraftVersion.replace("snapshot-", "alpha."),
"java_version" to javaVer, "java_version" to javaVer,
"mod_group" to this@allprojects.group, "mod_group" to this@allprojects.group,
"fabric_kotlin" to rootProject.property("fabric_language_kotlin"), "fabric_kotlin" to rootProject.property("fabric_language_kotlin"),

View File

@ -24,13 +24,12 @@ private fun supplyComponent(string: String?): Optional<Component> = string?.run
val SnowyConfigScreen: Screen = object: Screen(translationComponent) { val SnowyConfigScreen: Screen = object: Screen(translationComponent) {
override fun isPauseScreen(): Boolean = false override fun isPauseScreen(): Boolean = false
override fun extractRenderState(guiGraphics: GuiGraphics, mouseX: Int, mouseY: Int, pTick: Float) { override fun extractRenderState(guiGraphics: GuiGraphics, mouseX: Int, mouseY: Int, pTick: Float) {
super.extractBackground(guiGraphics, mouseX, mouseY, pTick)
FontUtil.drawScaled(guiGraphics, FontUtil.drawScaled(guiGraphics,
text = "An appropriate version of the Cloth Config mod is required for the configuration of snowygui.", 16.0, 16.0, text = "An appropriate version of the Cloth Config mod is required for the configuration of snowygui.", 16.0, 16.0,
color = Colors.WHITE, scaleFactor = 0.85F color = Colors.WHITE, scaleFactor = 0.85F
) )
} }
override fun onClose() { minecraft?.screen = configScreenParent } override fun onClose() = minecraft.gui.setScreen(configScreenParent)
}; get() = try { }; get() = try {
Class.forName("me.shedaniel.clothconfig2.api.ConfigBuilder") Class.forName("me.shedaniel.clothconfig2.api.ConfigBuilder")
val macrosBox: ClickBox? = ClickGui.components.find { val macrosBox: ClickBox? = ClickGui.components.find {

View File

@ -9,7 +9,7 @@ import net.minecraft.client.gui.GuiGraphicsExtractor as GuiGraphics
sealed class ButtonImplWithHud: ButtonImpl() { sealed class ButtonImplWithHud: ButtonImpl() {
protected abstract val hudRenderLambda: Renderable protected abstract val hudRenderLambda: Renderable
private val generatedLambda: argsLambda = { private val generatedLambda: argsLambda = {
if (!Minecraft.getInstance().options.hideGui) { if (!Minecraft.getInstance().gui.hud.isHidden) {
hudRenderLambda.render(it.first() as GuiGraphics?) hudRenderLambda.render(it.first() as GuiGraphics?)
} }
} }

View File

@ -29,8 +29,11 @@ object AddKeyMaps {
) to lambda ) to lambda
val list: MutableMap<KeyMapping, privateLambda> = with(Minecraft.getInstance()) { val list: MutableMap<KeyMapping, privateLambda> = with(Minecraft.getInstance()) {
mutableMapOf( mutableMapOf(
mkMap("opengui", GLFW_KEY_Y) { setScreen(ClickGui) }, mkMap("opengui", GLFW_KEY_Y) { Minecraft.getInstance().setScreenAndShow(ClickGui) },
mkMap("configkey", GLFW_KEY_U) { setScreen(run { configScreenParent = null; SnowyConfigScreen }) } mkMap("configkey", GLFW_KEY_U) {
configScreenParent = null
Minecraft.getInstance().setScreenAndShow(SnowyConfigScreen)
}
) )
} }
} }

View File

@ -7,7 +7,8 @@ org.gradle.parallel=true
org.gradle.unsafe.configuration-cache=on org.gradle.unsafe.configuration-cache=on
org.gradle.vfs.watch=true org.gradle.vfs.watch=true
minecraft=26.1 minecraft=26.2-snapshot-1
# TODO: 26.2.0.1-beta
forge_version=26.1.0.19-beta forge_version=26.1.0.19-beta
kotlinforforge=6.2.0 kotlinforforge=6.2.0
kotlinVer=2.3.10 kotlinVer=2.3.10
@ -15,8 +16,8 @@ kotlin_coroutines_version=1.10.2
serializationVer=1.10.0 serializationVer=1.10.0
fabric_loader_version=0.19.1 fabric_loader_version=0.19.1
fabric_language_kotlin=1.13.9+kotlin.2.3.10 fabric_language_kotlin=1.13.9+kotlin.2.3.10
fabric_resource_loader_version=3.3.16+4fc5413f59 fabric_resource_loader_version=3.3.16+4fc5413f92
fabric_rendering_api_version=23.0.3+2fb0624759 fabric_rendering_api_version=23.0.5+086d547a92
fabric_api_base_version=2.0.3+ece0632359 fabric_api_base_version=2.0.3+ece0632392
clothconfig_version=26.1.154 clothconfig_version=26.1.154
modmenu_version=18.0.0-alpha.8 modmenu_version=18.0.0-alpha.8

View File

@ -11,7 +11,7 @@ pluginManagement {
include("common") include("common")
include("fabric") include("fabric")
include("neoforge") //include("neoforge")
rootProject.name = "SnowyGUI" rootProject.name = "SnowyGUI"