1
0
Fork 0

Compare commits

...

3 Commits

Author SHA1 Message Date
chylex 7c2279b1d8
Release v1.2.3 for Minecraft 1.18+ 2021-12-13 19:50:09 +01:00
chylex 0814ddaedf
Update build.gradle and metadata files 2021-12-13 19:50:09 +01:00
chylex 0aed6282b4
Update Mod Menu API integration 2021-12-13 19:50:09 +01:00
10 changed files with 28 additions and 29 deletions

View File

@ -4,7 +4,7 @@ val fabricVersion: String by project
plugins {
idea
id("fabric-loom") version "0.9-SNAPSHOT"
id("fabric-loom") version "0.10-SNAPSHOT"
}
dependencies {
@ -42,7 +42,7 @@ tasks.processResources {
}
tasks.jar {
exclude("io/github/prospector/")
exclude("com/terraformersmc/modmenu/")
}
tasks.remapJar {

View File

@ -1,7 +1,7 @@
package chylex.bettercontrols.compatibility;
import chylex.bettercontrols.gui.BetterControlsScreen;
import io.github.prospector.modmenu.api.ConfigScreenFactory;
import io.github.prospector.modmenu.api.ModMenuApi;
import com.terraformersmc.modmenu.api.ConfigScreenFactory;
import com.terraformersmc.modmenu.api.ModMenuApi;
public class ModMenuSupport implements ModMenuApi {
@Override

View File

@ -1,8 +1,9 @@
package io.github.prospector.modmenu.api;
package com.terraformersmc.modmenu.api;
import net.minecraft.client.gui.screens.Screen;
@SuppressWarnings("unused")
@FunctionalInterface
public interface ConfigScreenFactory<S extends Screen> {
S create(Screen var1);
S create(Screen parent);
}

View File

@ -0,0 +1,8 @@
package com.terraformersmc.modmenu.api;
@SuppressWarnings("unused")
public interface ModMenuApi {
default ConfigScreenFactory<?> getModConfigScreenFactory() {
return screen -> null;
}
}

View File

@ -1,14 +0,0 @@
package io.github.prospector.modmenu.api;
import com.google.common.collect.ImmutableMap;
import java.util.Map;
@SuppressWarnings("unused")
public interface ModMenuApi {
default ConfigScreenFactory<?> getModConfigScreenFactory() {
return ignore -> null;
}
default Map<String, ConfigScreenFactory<?>> getProvidedConfigScreenFactories() {
return ImmutableMap.of();
}
}

View File

@ -1,6 +1,6 @@
{
"schemaVersion": 1,
"id": "bettercontrols",
"id": "${id}",
"name": "${name}",
"description": "${description}",
"version": "${version}",
@ -24,7 +24,7 @@
},
"mixins": [{
"config": "bettercontrols.mixins.json",
"config": "${id}.mixins.json",
"environment": "client"
}],

View File

@ -6,20 +6,20 @@ license = "${license}"
issueTrackerURL = "${issuesURL}"
[[mods]]
modId = "bettercontrols"
modId = "${id}"
version = "${version}"
displayName = "${name}"
description = "${description}"
logoFile = "icon.png"
[[dependencies.bettercontrols]]
[[dependencies.${id}]]
modId = "minecraft"
mandatory = true
versionRange = "[1.17.1,)"
ordering = "NONE"
side = "BOTH"
[[dependencies.bettercontrols]]
[[dependencies.${id}]]
modId = "forge"
mandatory = true
versionRange = "[37,)"

View File

@ -33,6 +33,7 @@ idea {
module {
excludeDirs.add(file("gradle"))
excludeDirs.add(file("run"))
excludeDirs.add(file("Fabric/run"))
if (findProject(":Forge") == null) {
excludeDirs.add(file("Forge"))
@ -101,8 +102,7 @@ subprojects {
}
tasks.processResources {
from(rootProject.sourceSets.main.get().resources)
inputs.property("id", modId)
inputs.property("name", modName)
inputs.property("description", modDescription)
inputs.property("version", modVersion)
@ -110,6 +110,10 @@ subprojects {
inputs.property("license", modLicense)
inputs.property("sourcesURL", modSourcesURL)
inputs.property("issuesURL", modIssuesURL)
from(rootProject.sourceSets.main.get().resources) {
expand(inputs.properties)
}
}
tasks.jar {

View File

@ -3,7 +3,7 @@ modId=bettercontrols
modName=Better Controls
modDescription=Adds many powerful key bindings and options to control your movement.\\n\\nThe features complement vanilla mechanics without giving unfair advantages, so server use should be fine.
modAuthor=chylex
modVersion=1.2.2
modVersion=1.2.3
modLicense=MPL-2.0
modSourcesURL=https://github.com/chylex/Better-Controls
modIssuesURL=https://github.com/chylex/Better-Controls/issues

View File

@ -1,6 +1,6 @@
{
"pack": {
"description": "Better Controls",
"description": "${name}",
"pack_format": 7,
"_comment": ""
}