Skip to content

Commit

Permalink
update ingame mod metadata
Browse files Browse the repository at this point in the history
  • Loading branch information
dphaldes committed Oct 28, 2023
1 parent 0603258 commit 694c09f
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 3 deletions.
13 changes: 13 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,19 @@ dependencies {
}


tasks.named('processResources', ProcessResources).configure {
var replaceProperties = [
mod_version: mod_version,
]
inputs.properties replaceProperties

filesMatching(['META-INF/mods.toml', 'pack.mcmeta']) {
expand replaceProperties + [project: project]
}
}



// Example for how to get properties into the manifest for reading by the runtime..
// Example for how to get properties into the manifest for reading at runtime.
tasks.named('jar', Jar).configure {
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
org.gradle.jvmargs=-Xmx4G
org.gradle.daemon=false
#
mod_version=0.2.1
mod_version=0.3.0
mod_id=tomeofblood
mod_authors=mystchonky
mod_group_id=com.mystchonky.tomeofblood
Expand Down
4 changes: 2 additions & 2 deletions src/main/resources/META-INF/mods.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ license = "GNU Lesser General Public License v3.0"
# The modid of the mod
modId = "tomeofblood" #mandatory
# The version number of the mod - there's a few well known ${} variables useable here or just hardcode it
version = "${file.jarVersion}" #mandatory
version = "${mod_version}" #mandatory
# A display name for the mod
displayName = "Tome of Blood: Rebirth" #mandatory
# A URL to query for updates for this mod. See the JSON update specification <here>
#updateJSONURL="http://myurl.me/" #optional
# A URL for the "homepage" for this mod, displayed in the mod UI
#displayURL="http://example.com/" #optional
# A file name (in the root of the mod JAR) containing a logo for display
#logoFile="examplemod.png" #optional
logoFile = "logo.png" #optional
# A text field displayed in the mod UI
credits = "Thanks to the original author of Tome of Blood SadieLuna" #optional
# A text field displayed in the mod UI
Expand Down
Binary file added src/main/resources/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 694c09f

Please sign in to comment.