Initial commit
This commit is contained in:
commit
76d4b44153
24 changed files with 787 additions and 0 deletions
84
forge/build.gradle
Normal file
84
forge/build.gradle
Normal file
|
@ -0,0 +1,84 @@
|
|||
plugins {
|
||||
id "com.github.johnrengelman.shadow" version "7.1.2"
|
||||
}
|
||||
|
||||
architectury {
|
||||
platformSetupLoomIde()
|
||||
forge()
|
||||
}
|
||||
|
||||
loom {
|
||||
accessWidenerPath = project(":common").loom.accessWidenerPath
|
||||
|
||||
forge {
|
||||
convertAccessWideners = true
|
||||
extraAccessWideners.add loom.accessWidenerPath.get().asFile.name
|
||||
|
||||
mixinConfig "knockdowns-common.mixins.json"
|
||||
mixinConfig "knockdowns.mixins.json"
|
||||
}
|
||||
}
|
||||
|
||||
configurations {
|
||||
common
|
||||
shadowCommon // Don't use shadow from the shadow plugin since it *excludes* files.
|
||||
compileClasspath.extendsFrom common
|
||||
runtimeClasspath.extendsFrom common
|
||||
developmentForge.extendsFrom common
|
||||
}
|
||||
|
||||
dependencies {
|
||||
forge "net.minecraftforge:forge:${rootProject.forge_version}"
|
||||
// Remove the next line if you don't want to depend on the API
|
||||
modApi "dev.architectury:architectury-forge:${rootProject.architectury_version}"
|
||||
|
||||
common(project(path: ":common", configuration: "namedElements")) { transitive false }
|
||||
shadowCommon(project(path: ":common", configuration: "transformProductionForge")) { transitive = false }
|
||||
}
|
||||
|
||||
processResources {
|
||||
inputs.property "version", project.version
|
||||
|
||||
filesMatching("META-INF/mods.toml") {
|
||||
expand "version": project.version
|
||||
}
|
||||
}
|
||||
|
||||
shadowJar {
|
||||
exclude "fabric.mod.json"
|
||||
exclude "architectury.common.json"
|
||||
|
||||
configurations = [project.configurations.shadowCommon]
|
||||
archiveClassifier = "dev-shadow"
|
||||
}
|
||||
|
||||
remapJar {
|
||||
input.set shadowJar.archiveFile
|
||||
dependsOn shadowJar
|
||||
}
|
||||
|
||||
sourcesJar {
|
||||
def commonSources = project(":common").sourcesJar
|
||||
dependsOn commonSources
|
||||
from commonSources.archiveFile.map { zipTree(it) }
|
||||
}
|
||||
|
||||
components.java {
|
||||
withVariantsFromConfiguration(project.configurations.shadowRuntimeElements) {
|
||||
skip()
|
||||
}
|
||||
}
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
mavenForge(MavenPublication) {
|
||||
artifactId = rootProject.archives_base_name + "-" + project.name
|
||||
from components.java
|
||||
}
|
||||
}
|
||||
|
||||
// See https://docs.gradle.org/current/userguide/publishing_maven.html for information on how to set up publishing.
|
||||
repositories {
|
||||
// Add repositories to publish to here.
|
||||
}
|
||||
}
|
1
forge/gradle.properties
Normal file
1
forge/gradle.properties
Normal file
|
@ -0,0 +1 @@
|
|||
loom.platform=forge
|
|
@ -0,0 +1,15 @@
|
|||
package ru.octol1ttle.knockdowns.forge;
|
||||
|
||||
import dev.architectury.platform.forge.EventBuses;
|
||||
import ru.octol1ttle.knockdowns.common.KnockdownsCommon;
|
||||
import net.minecraftforge.fml.common.Mod;
|
||||
import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;
|
||||
|
||||
@Mod(KnockdownsCommon.MOD_ID)
|
||||
public class KnockdownsForge {
|
||||
public KnockdownsForge() {
|
||||
// Submit our event bus to let architectury register our content on the right time
|
||||
EventBuses.registerModEventBus(KnockdownsCommon.MOD_ID, FMLJavaModLoadingContext.get().getModEventBus());
|
||||
KnockdownsCommon.init();
|
||||
}
|
||||
}
|
35
forge/src/main/resources/META-INF/mods.toml
Normal file
35
forge/src/main/resources/META-INF/mods.toml
Normal file
|
@ -0,0 +1,35 @@
|
|||
modLoader = "javafml"
|
||||
loaderVersion = "[47,)"
|
||||
#issueTrackerURL = ""
|
||||
license = "ARR"
|
||||
|
||||
[[mods]]
|
||||
modId = "knockdowns"
|
||||
version = "${version}"
|
||||
displayName = "Knockdowns"
|
||||
authors = "Octol1ttle"
|
||||
description = '''
|
||||
DNBO mechanic from Fortnite, ported to Minecraft
|
||||
'''
|
||||
#logoFile = ""
|
||||
|
||||
[[dependencies.knockdowns]]
|
||||
modId = "forge"
|
||||
mandatory = true
|
||||
versionRange = "[47,)"
|
||||
ordering = "NONE"
|
||||
side = "BOTH"
|
||||
|
||||
[[dependencies.knockdowns]]
|
||||
modId = "minecraft"
|
||||
mandatory = true
|
||||
versionRange = "[1.20.1,)"
|
||||
ordering = "NONE"
|
||||
side = "BOTH"
|
||||
|
||||
[[dependencies.knockdowns]]
|
||||
modId = "architectury"
|
||||
mandatory = true
|
||||
versionRange = "[9.1.12,)"
|
||||
ordering = "AFTER"
|
||||
side = "BOTH"
|
13
forge/src/main/resources/knockdowns.mixins.json
Normal file
13
forge/src/main/resources/knockdowns.mixins.json
Normal file
|
@ -0,0 +1,13 @@
|
|||
{
|
||||
"required": true,
|
||||
"package": "net.knockdowns.mixin.forge",
|
||||
"compatibilityLevel": "JAVA_17",
|
||||
"minVersion": "0.8",
|
||||
"client": [
|
||||
],
|
||||
"mixins": [
|
||||
],
|
||||
"injectors": {
|
||||
"defaultRequire": 1
|
||||
}
|
||||
}
|
6
forge/src/main/resources/pack.mcmeta
Normal file
6
forge/src/main/resources/pack.mcmeta
Normal file
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"pack": {
|
||||
"description": "Knockdowns",
|
||||
"pack_format": 15
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue