Merge remote-tracking branch 'origin/1.20' into 1.20.6
This commit is contained in:
commit
57af3c6491
|
|
@ -2,16 +2,15 @@ ModernFix is a standard Minecraft-style Gradle project powered by Architectury L
|
||||||
run the `build` task (e.g. via `./gradlew build`). You can also use `./gradlew forge:build` or `./gradlew fabric:build`
|
run the `build` task (e.g. via `./gradlew build`). You can also use `./gradlew forge:build` or `./gradlew fabric:build`
|
||||||
to build for just one loader (e.g. when debugging and wanting to rebuild quickly).
|
to build for just one loader (e.g. when debugging and wanting to rebuild quickly).
|
||||||
|
|
||||||
You must use Java 17 to develop ModernFix as the toolchain requires it. Nonetheless, the 1.16 mod JARs will work on
|
You must use Java 21 to develop ModernFix as the toolchain requires it. Nonetheless, the built 1.20.1 JAR is still
|
||||||
a Minecraft instance with Java 8.
|
compatible with Java 17.
|
||||||
|
|
||||||
## Submitting pull requests
|
## Submitting pull requests
|
||||||
|
|
||||||
Code or documentation contributions are welcome. Please keep the following points in mind:
|
Code or documentation contributions are welcome. Please keep the following points in mind:
|
||||||
|
|
||||||
* This project supports many Minecraft versions. Ideally, contributions should be made to the oldest relevant MC version.
|
* This project supports many Minecraft versions. Ideally, contributions should be made to the oldest relevant MC version (currently 1.20)
|
||||||
For instance, a PR optimizing new worldgen should be made to 1.18 (not 1.19 or 1.20) while a PR optimizing something
|
and then they will be ported forward.
|
||||||
like recipes should be made to 1.16 (the oldest supported version).
|
|
||||||
|
|
||||||
This somewhat unconventional policy ensures that all supported versions are treated equal when it comes to development,
|
This somewhat unconventional policy ensures that all supported versions are treated equal when it comes to development,
|
||||||
rather than the onus being on other modders and players to backport changes that are needed. Changes to older versions are
|
rather than the onus being on other modders and players to backport changes that are needed. Changes to older versions are
|
||||||
|
|
|
||||||
|
|
@ -43,6 +43,7 @@ shadowJar {
|
||||||
// shadowJar bug
|
// shadowJar bug
|
||||||
include '*.jar'
|
include '*.jar'
|
||||||
include 'META-INF/services/javax.annotation.processing.Processor'
|
include 'META-INF/services/javax.annotation.processing.Processor'
|
||||||
|
include 'META-INF/gradle/incremental.annotation.processors'
|
||||||
include 'org/spongepowered/asm/mixin/Mixin.class'
|
include 'org/spongepowered/asm/mixin/Mixin.class'
|
||||||
include 'org/fury_phoenix/**/*'
|
include 'org/fury_phoenix/**/*'
|
||||||
include {it.getName() == 'OnlyIn.class'}
|
include {it.getName() == 'OnlyIn.class'}
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,6 @@ import javax.annotation.processing.Processor;
|
||||||
import javax.annotation.processing.RoundEnvironment;
|
import javax.annotation.processing.RoundEnvironment;
|
||||||
import javax.annotation.processing.SupportedAnnotationTypes;
|
import javax.annotation.processing.SupportedAnnotationTypes;
|
||||||
import javax.annotation.processing.SupportedOptions;
|
import javax.annotation.processing.SupportedOptions;
|
||||||
import javax.annotation.processing.SupportedSourceVersion;
|
|
||||||
import javax.lang.model.SourceVersion;
|
import javax.lang.model.SourceVersion;
|
||||||
import javax.lang.model.element.Element;
|
import javax.lang.model.element.Element;
|
||||||
import javax.lang.model.element.TypeElement;
|
import javax.lang.model.element.TypeElement;
|
||||||
|
|
@ -26,7 +25,6 @@ import org.fury_phoenix.mixinAp.config.MixinConfig;
|
||||||
|
|
||||||
@SupportedAnnotationTypes({"org.spongepowered.asm.mixin.Mixin", "org.embeddedt.modernfix.annotation.ClientOnlyMixin"})
|
@SupportedAnnotationTypes({"org.spongepowered.asm.mixin.Mixin", "org.embeddedt.modernfix.annotation.ClientOnlyMixin"})
|
||||||
@SupportedOptions({"rootProject.name", "project.name", "org.fury_phoenix.mixinAp.validator.debug"})
|
@SupportedOptions({"rootProject.name", "project.name", "org.fury_phoenix.mixinAp.validator.debug"})
|
||||||
@SupportedSourceVersion(SourceVersion.RELEASE_17)
|
|
||||||
@AutoService(Processor.class)
|
@AutoService(Processor.class)
|
||||||
public class MixinProcessor extends AbstractProcessor {
|
public class MixinProcessor extends AbstractProcessor {
|
||||||
|
|
||||||
|
|
@ -38,6 +36,11 @@ public class MixinProcessor extends AbstractProcessor {
|
||||||
|
|
||||||
private final Map<String, List<String>> mixinConfigList = new HashMap<>();
|
private final Map<String, List<String>> mixinConfigList = new HashMap<>();
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public SourceVersion getSupportedSourceVersion() {
|
||||||
|
return SourceVersion.latest();
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean process(Set<? extends TypeElement> annotations, RoundEnvironment roundEnv) {
|
public boolean process(Set<? extends TypeElement> annotations, RoundEnvironment roundEnv) {
|
||||||
try {
|
try {
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1 @@
|
||||||
|
org.fury_phoenix.mixinAp.annotation.MixinProcessor,aggregating
|
||||||
|
|
@ -6,6 +6,9 @@ plugins {
|
||||||
loom {
|
loom {
|
||||||
silentMojangMappingsLicense()
|
silentMojangMappingsLicense()
|
||||||
accessWidenerPath = file("${rootDir}/common/src/main/resources/modernfix.accesswidener")
|
accessWidenerPath = file("${rootDir}/common/src/main/resources/modernfix.accesswidener")
|
||||||
|
mixin {
|
||||||
|
useLegacyMixinAp = false
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
|
|
@ -31,7 +34,6 @@ tasks {
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.withType(JavaCompile) {
|
tasks.withType(JavaCompile) {
|
||||||
options.fork = true
|
|
||||||
configure(options) {
|
configure(options) {
|
||||||
if (!name.toLowerCase().contains('test')) {
|
if (!name.toLowerCase().contains('test')) {
|
||||||
options.compilerArgs << "-ArootProject.name=${rootProject.name}" << "-Aproject.name=${project.name}"
|
options.compilerArgs << "-ArootProject.name=${rootProject.name}" << "-Aproject.name=${project.name}"
|
||||||
|
|
|
||||||
|
|
@ -26,18 +26,6 @@ configurations {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO remove
|
|
||||||
|
|
||||||
repositories {
|
|
||||||
maven {
|
|
||||||
name = "Technici4n"
|
|
||||||
url = "https://raw.githubusercontent.com/Technici4n/Technici4n-maven/master/"
|
|
||||||
content {
|
|
||||||
includeGroup "net.fabricmc.fabric-api"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
modImplementation "net.fabricmc:fabric-loader:${rootProject.fabric_loader_version}"
|
modImplementation "net.fabricmc:fabric-loader:${rootProject.fabric_loader_version}"
|
||||||
testImplementation "net.fabricmc:fabric-loader-junit:${rootProject.fabric_loader_version}"
|
testImplementation "net.fabricmc:fabric-loader-junit:${rootProject.fabric_loader_version}"
|
||||||
|
|
@ -77,7 +65,7 @@ dependencies {
|
||||||
testAgent(project("path": ":test_agent", "configuration": "agentJar"))
|
testAgent(project("path": ":test_agent", "configuration": "agentJar"))
|
||||||
}
|
}
|
||||||
|
|
||||||
test {
|
tasks.named("test") {
|
||||||
useJUnitPlatform()
|
useJUnitPlatform()
|
||||||
def runDir = file('test_run')
|
def runDir = file('test_run')
|
||||||
doFirst() {
|
doFirst() {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user