Put the base minecraft version in mod files during processing
This commit is contained in:
parent
9dbe16748f
commit
6175158225
|
@ -86,6 +86,7 @@ subprojects {
|
|||
}
|
||||
}
|
||||
|
||||
val mcBase: String = rootProject.architectury.minecraft.dropLast(2)
|
||||
allprojects {
|
||||
apply(plugin = "java")
|
||||
apply(plugin = "architectury-plugin")
|
||||
|
@ -137,9 +138,13 @@ allprojects {
|
|||
from(this)
|
||||
}
|
||||
}
|
||||
val modVersionPair: Pair<String, String> = "mod_version" to (rootProject.version as String)
|
||||
filesNotMatching(listOf("*.png", "*/*.ttf")) {
|
||||
expand(mutableMapOf(modVersionPair))
|
||||
val ModProperties = mapOf<String, String>(
|
||||
"mod_version" to (rootProject.version as String),
|
||||
"minecraft_version" to mcBase
|
||||
)
|
||||
inputs.properties(ModProperties)
|
||||
filesNotMatching(listOf("*.png")) {
|
||||
expand(ModProperties)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -156,7 +161,7 @@ tasks {
|
|||
versionNumber = version.toString()
|
||||
projectId = "OuGyGg6A"
|
||||
token = envStr
|
||||
addGameVersion(architectury.minecraft.dropLast(2))
|
||||
addGameVersion(mcBase)
|
||||
versionType = VersionType.ALPHA
|
||||
detectLoaders = false
|
||||
versionName = "${project.name} $versionNumber for Minecraft $gameVersions and higher"
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
"depends": {
|
||||
"fabricloader": ">=0.9.3",
|
||||
"fabric-resource-loader-v0": "*",
|
||||
"minecraft": ">=1.16"
|
||||
"minecraft": ">=${minecraft_version}"
|
||||
},
|
||||
"breaks": {
|
||||
"modmenu": "<1.15.0"
|
||||
|
|
|
@ -23,6 +23,6 @@ side = "BOTH"
|
|||
[[dependencies.snowygui]]
|
||||
modId = "minecraft"
|
||||
mandatory = true
|
||||
versionRange = "[1.16.1,)"
|
||||
versionRange = "[${minecraft_version},)"
|
||||
ordering = "NONE"
|
||||
side = "BOTH"
|
Loading…
Reference in New Issue