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