-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Initial working project with exposed logic classes for further implem…
…entation.
- Loading branch information
0 parents
commit ffee318
Showing
43 changed files
with
3,089 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,165 @@ | ||
buildscript { | ||
dependencies { | ||
classpath 'org.spongepowered:mixingradle:0.7-SNAPSHOT' | ||
} | ||
} | ||
|
||
plugins { | ||
id 'idea' | ||
id 'maven-publish' | ||
id 'net.neoforged.gradle' version '[6.0.18,6.2)' | ||
id 'org.spongepowered.mixin' version '0.7.+' | ||
id 'org.parchmentmc.librarian.forgegradle' version '1.+' | ||
} | ||
|
||
version = mod_version | ||
group = mod_group_id | ||
|
||
base { | ||
archivesName = mod_id | ||
} | ||
|
||
java.toolchain.languageVersion = JavaLanguageVersion.of(17) | ||
|
||
println "Java: ${System.getProperty 'java.version'}, JVM: ${System.getProperty 'java.vm.version'} (${System.getProperty 'java.vendor'}), Arch: ${System.getProperty 'os.arch'}" | ||
minecraft { | ||
mappings channel: mapping_channel, version: mapping_version | ||
copyIdeResources = true | ||
runs { | ||
configureEach { | ||
workingDirectory project.file('run') | ||
property 'forge.logging.markers', 'REGISTRIES' | ||
property 'forge.logging.console.level', 'debug' | ||
mods { | ||
"${mod_id}" { | ||
source sourceSets.main | ||
} | ||
} | ||
} | ||
|
||
client { | ||
property 'forge.enabledGameTestNamespaces', mod_id | ||
} | ||
|
||
server { | ||
property 'forge.enabledGameTestNamespaces', mod_id | ||
args '--nogui' | ||
} | ||
|
||
gameTestServer { | ||
property 'forge.enabledGameTestNamespaces', mod_id | ||
} | ||
|
||
data { | ||
workingDirectory project.file('run-data') | ||
args '--mod', mod_id, '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources/') | ||
} | ||
} | ||
} | ||
|
||
sourceSets.main.resources { srcDir 'src/generated/resources' } | ||
|
||
repositories { | ||
mavenLocal() | ||
mavenCentral() | ||
maven { | ||
url = "https://cursemaven.com" | ||
content { | ||
includeGroup "curse.maven" | ||
} | ||
} | ||
maven { | ||
url = "https://maven.blamejared.com/" | ||
} | ||
maven { | ||
url = "https://dvs1.progwml6.com/files/maven/" | ||
} | ||
maven { | ||
name = "Modmaven" | ||
url = "https://modmaven.dev/" | ||
} | ||
maven { | ||
url "https://maven.shedaniel.me/" | ||
content { | ||
includeGroup "me.shedaniel" | ||
includeGroup "me.shedaniel.cloth" | ||
includeGroup "dev.architectury" | ||
} | ||
} | ||
} | ||
|
||
dependencies { | ||
minecraft "net.neoforged:forge:${minecraft_version}-${forge_version}" | ||
implementation fg.deobf("curse.maven:glodium-957920:5006780") | ||
compileOnly fg.deobf("curse.maven:applied-energistics-2-wireless-terminals-459929:5162352") | ||
compileOnly fg.deobf("mezz.jei:jei-1.20.1-forge:15.0.0.12") | ||
compileOnly fg.deobf("curse.maven:applied-flux-965012:5329825") | ||
compileOnly fg.deobf("appeng:appliedenergistics2-forge:15.2.11") | ||
compileOnly fg.deobf("curse.maven:ex-pattern-provider-892005:5577174") | ||
compileOnly fg.deobf("curse.maven:jade-324717:4768593") | ||
// rei | ||
compileOnly "me.shedaniel.cloth:basic-math:0.6.1" | ||
compileOnly fg.deobf("dev.architectury:architectury-forge:7.0.66") | ||
compileOnly fg.deobf("me.shedaniel:RoughlyEnoughItems-forge:12.0.622") | ||
compileOnly fg.deobf("me.shedaniel.cloth:cloth-config-forge:9.0.94") | ||
// runtime test | ||
runtimeOnly fg.deobf("mezz.jei:jei-1.20.1-forge:15.0.0.12") | ||
runtimeOnly fg.deobf("curse.maven:applied-energistics-2-223794:5565729") | ||
runtimeOnly fg.deobf("curse.maven:ex-pattern-provider-892005:5577174") | ||
runtimeOnly fg.deobf("curse.maven:jade-324717:4768593") | ||
} | ||
|
||
tasks.named('processResources', ProcessResources).configure { | ||
var replaceProperties = [ | ||
minecraft_version: minecraft_version, minecraft_version_range: minecraft_version_range, | ||
neo_version: forge_version, forge_version_range: forge_version_range, | ||
loader_version_range: loader_version_range, | ||
mod_id: mod_id, mod_name: mod_name, mod_license: mod_license, mod_version: mod_version, | ||
mod_authors: mod_authors, mod_description: mod_description, | ||
] | ||
inputs.properties replaceProperties | ||
|
||
filesMatching(['META-INF/mods.toml', 'pack.mcmeta']) { | ||
expand replaceProperties + [project: project] | ||
} | ||
} | ||
|
||
tasks.named('jar', Jar).configure { | ||
manifest { | ||
attributes([ | ||
'Specification-Title' : mod_id, | ||
'Specification-Vendor' : mod_authors, | ||
'Specification-Version' : '1', | ||
'Implementation-Title' : project.name, | ||
'Implementation-Version' : project.jar.archiveVersion, | ||
'Implementation-Vendor' : mod_authors, | ||
'Implementation-Timestamp': new Date().format("yyyy-MM-dd'T'HH:mm:ssZ"), | ||
'TweakClass': "org.spongepowered.asm.launch.MixinTweaker", | ||
'TweakOrder': 0, | ||
'MixinConfigs': "mixins.epp.json" | ||
]) | ||
} | ||
finalizedBy 'reobfJar' | ||
} | ||
|
||
// Example configuration to allow publishing using the maven-publish plugin | ||
publishing { | ||
publications { | ||
register('mavenJava', MavenPublication) { | ||
artifact jar | ||
} | ||
} | ||
repositories { | ||
maven { | ||
url "file://${project.projectDir}/mcmodsrepo" | ||
} | ||
} | ||
} | ||
|
||
mixin { | ||
add sourceSets.main, "mixins.epp.refmap.json" | ||
} | ||
|
||
tasks.withType(JavaCompile).configureEach { | ||
options.encoding = 'UTF-8' // Use the UTF-8 charset for Java compilation | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Sets default memory used for gradle commands. Can be overridden by user or command line properties. | ||
# This is required to provide enough memory for the Minecraft decompilation process. | ||
org.gradle.jvmargs=-Xmx3G | ||
org.gradle.daemon=false | ||
|
||
## Environment Properties | ||
|
||
minecraft_version=1.20.1 | ||
minecraft_version_range=[1.20.1,1.20.2) | ||
forge_version=47.1.54 | ||
forge_version_range=[47,) | ||
loader_version_range=[47,) | ||
mapping_channel=parchment | ||
mapping_version=2023.09.03-1.20.1 | ||
|
||
## Mod Properties | ||
|
||
mod_id=advanced_ae | ||
mod_name=Advanced AE | ||
mod_license=LGPL-3.0 | ||
mod_version=0.1-1.20.1 | ||
mod_group_id=net.pedroksl.advanced_ae | ||
mod_authors=Pedroksl | ||
mod_description=This mod aims to expand on the added capabilities of Extended AE. |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip | ||
networkTimeout=10000 | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
Oops, something went wrong.