diff --git a/forge-1.13.2/build.gradle b/forge-1.13.2/build.gradle index 0e58496d..2a66e841 100644 --- a/forge-1.13.2/build.gradle +++ b/forge-1.13.2/build.gradle @@ -25,8 +25,8 @@ targetCompatibility = 1.8 ext.buildNumber = System.getenv().BUILD_NUMBER ?: "Dev" minecraft { - mappings channel: 'stable', version: '47-1.13.2' - runs { + mappings channel: 'stable', version: '47-1.13.2' + runs { server { workingDirectory project.file('run').canonicalPath } @@ -44,12 +44,15 @@ processResources include 'META-INF/mods.toml' // replace version and mcversion - expand version: project.version + '-' + project.ext.buildNumber + expand( + version: project.version + '-' + project.ext.buildNumber, + mcversion: "1.13.2" + ) } // copy everything else, thats not the mcmod.info from(sourceSets.main.resources.srcDirs) { - include 'META-INF/mods.toml' + exclude 'META-INF/mods.toml' } } diff --git a/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/DynmapMod.java b/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/DynmapMod.java index 02e16d3a..6acd451a 100644 --- a/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/DynmapMod.java +++ b/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/DynmapMod.java @@ -31,6 +31,7 @@ public class DynmapMod public static DynmapPlugin plugin; public static File jarfile; + public static String ver; public static boolean useforcedchunks; public class APICallback extends DynmapCommonAPIListener { @@ -73,6 +74,9 @@ public class DynmapMod { //TOOO jarfile = ModList.get().getModFileById("dynmap").getFile().getFilePath().toFile(); + + ver = ModList.get().getModContainerById("dynmap").get().getModInfo().getVersion().toString(); + //// Load configuration file - use suggested (config/WesterosBlocks.cfg) //Configuration cfg = new Configuration(event.getSuggestedConfigurationFile()); //try { diff --git a/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/DynmapPlugin.java b/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/DynmapPlugin.java index 4f5f39ab..370a3d6e 100644 --- a/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/DynmapPlugin.java +++ b/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/DynmapPlugin.java @@ -1430,7 +1430,7 @@ public class DynmapPlugin /* Inject dependencies */ core.setPluginJarFile(DynmapMod.jarfile); - core.setPluginVersion(Version.VER); + core.setPluginVersion(DynmapMod.ver); core.setMinecraftVersion(mcver); core.setDataFolder(dataDirectory); core.setServer(fserver); diff --git a/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/Version.java b/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/Version.java deleted file mode 100644 index 5b08ebb7..00000000 --- a/forge-1.13.2/src/main/java/org/dynmap/forge_1_13_2/Version.java +++ /dev/null @@ -1,7 +0,0 @@ -package org.dynmap.forge_1_13_2; - -public class Version { - public static final String VER = "@VERSION@"; - public static final String BUILD_NUMBER = "@BUILD_NUMBER@"; -} - diff --git a/forge-1.13.2/src/main/resources/META-INF/mods.toml b/forge-1.13.2/src/main/resources/META-INF/mods.toml index bd638a88..4291d005 100644 --- a/forge-1.13.2/src/main/resources/META-INF/mods.toml +++ b/forge-1.13.2/src/main/resources/META-INF/mods.toml @@ -5,12 +5,7 @@ issueTrackerURL="https://github.com/webbukkit/dynmap/issues" modId="dynmap" version="${version}" displayName="Dynmap" -#updateJSONURL="http://myurl.me/" #optional -#displayURL="http://example.com/" #optional -#logoFile="examplemod.png" #optional -#credits="Thanks for this example mod goes to Java" #optional authors="mikeprimm" -# The description text for the mod (multi line!) (#mandatory) description=''' Dynamic, Google-maps style rendered maps for your Minecraft server ''' diff --git a/forge-1.13.2/src/main/resources/mcmod.info b/forge-1.13.2/src/main/resources/mcmod.info deleted file mode 100644 index e7ce7144..00000000 --- a/forge-1.13.2/src/main/resources/mcmod.info +++ /dev/null @@ -1,18 +0,0 @@ -[ -{ - "modid": "Dynmap", - "name": "Dynmap", - "description": "Dynamic, Google Maps style web maps for Minecraft Servers", - "version": "${version}", - "mcversion": "${mcversion}", - "url": "https://www.reddit.com/r/Dynmap/", - "updateUrl": "", - "authors": [ - "mikeprimm" - ], - "credits": "Authored by mikeprimm", - "logoFile": "", - "screenshots": [ ], - "dependencies": [] -} -]