Skip to content

Commit

Permalink
Upload source code for v6.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Viola-Siemens committed Jan 9, 2023
0 parents commit d443b7e
Show file tree
Hide file tree
Showing 2,986 changed files with 70,256 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Disable autocrlf on generated files, they always generate with LF
# Add any extra files or paths here to make git stop saying they
# are changed when only line endings change.
src/generated/**/.cache/cache text eol=lf
src/generated/**/*.json text eol=lf
25 changes: 25 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# eclipse
bin
*.launch
.settings
.metadata
.classpath
.project

# idea
out
*.ipr
*.iws
*.iml
.idea

# gradle
build
.gradle

# other
eclipse
run

# Files from Forge MDK
forge*changelog.txt
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2022 刘冬煜

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# EmeraldCraftMod
A Minecraft Mod about more villager professions and crafting recipes.

## Wiki:
[mcmod(MC百科)](https://www.mcmod.cn/class/6322.html)

[Official (官方Wiki)](https://viola-siemens.github.io/pages/emeraldcraft/index.html)

## Download
[CurseForge](https://www.curseforge.com/minecraft/mc-mods/emerald-craft-mod)
178 changes: 178 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,178 @@
buildscript {
repositories {
maven { url = 'https://maven.minecraftforge.net' }
jcenter()
mavenCentral()
maven { name="sponge"; url 'https://repo.spongepowered.org/repository/maven-public/' }
}
dependencies {
classpath group: 'net.minecraftforge.gradle', name: 'ForgeGradle', version: '5.1.+', changing: true
classpath 'org.spongepowered:mixingradle:0.7.32'
}
}

plugins {
id 'eclipse'
id 'maven-publish'
id 'net.minecraftforge.gradle' version '5.1.+'
}
apply plugin: 'org.spongepowered.mixin'

version = '6.0'
group = 'com.hexagram2021.emeraldcraft'
archivesBaseName = 'emeraldcraft'

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: 'official', version: '1.19.2'

accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg')

runs {
client {
workingDirectory project.file('run')

property 'forge.logging.markers', 'REGISTRIES'
property 'mixin.env.remapRefMap', 'true'
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"

property 'forge.logging.console.level', 'debug'

property 'forge.enabledGameTestNamespaces', 'emeraldcraft'
arg "-mixin.config=emeraldcraft.mixins.json"

mods {
emeraldcraft {
source sourceSets.main
}
}
}

server {
workingDirectory project.file('run')

property 'forge.logging.markers', 'REGISTRIES'
property 'mixin.env.remapRefMap', 'true'
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"

property 'forge.logging.console.level', 'debug'

property 'forge.enabledGameTestNamespaces', 'emeraldcraft'
arg "-mixin.config=emeraldcraft.mixins.json"

mods {
emeraldcraft {
source sourceSets.main
}
}
}

gameTestServer {
workingDirectory project.file('run')

property 'forge.logging.markers', 'REGISTRIES'
property 'mixin.env.remapRefMap', 'true'
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"

property 'forge.logging.console.level', 'debug'

property 'forge.enabledGameTestNamespaces', 'emeraldcraft'
arg "-mixin.config=emeraldcraft.mixins.json"

mods {
emeraldcraft {
source sourceSets.main
}
}
}

data {
workingDirectory project.file('run')

property 'forge.logging.markers', 'REGISTRIES'
property 'mixin.env.remapRefMap', 'true'
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"

property 'forge.logging.console.level', 'debug'

args '--mod', 'emeraldcraft', '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources/')
arg "-mixin.config=emeraldcraft.mixins.json"

mods {
emeraldcraft {
source sourceSets.main
}
}
}
}
}

sourceSets.main.resources { srcDir 'src/generated/resources' }

repositories {
maven { // TOP
url "https://cursemaven.com"
}
maven { // JEI
name 'DVS1 Maven FS'
url 'https://dvs1.progwml6.com/files/maven'
}
maven { //mirror
name = "ModMaven"
url = "https://modmaven.dev"
}
}

dependencies {
minecraft 'net.minecraftforge:forge:1.19.2-43.2.0'

compileOnly fg.deobf("mezz.jei:jei-1.19.2-forge:11.5.0.297")

annotationProcessor 'org.spongepowered:mixin:0.8.5:processor'

implementation fg.deobf("com.github.glitchfiend:TerraBlender-forge:1.19.2-2.0.1.128") //TerraBlender
}

jar {
manifest {
attributes([
"Specification-Title" : "Emerald Craft Mod",
"Specification-Vendor" : "Hexagram",
"Specification-Version" : "1",
"Implementation-Title" : project.name,
"Implementation-Version" : project.jar.archiveVersion,
"Implementation-Vendor" : "Hexagram",
"Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ"),
'FMLCorePluginContainsFMLMod': 'true'
])
}
}

jar.finalizedBy('reobfJar')

publishing {
publications {
mavenJava(MavenPublication) {
artifact jar
}
}
repositories {
maven {
url "file://${project.projectDir}/mcmodsrepo"
}
}
}

mixin {
add sourceSets.main, 'emeraldcraft.refmap.json'
config 'emeraldcraft.mixins.json'

debug.verbose = true
debug.export = true
}

tasks.withType(JavaCompile).configureEach {
options.encoding = 'UTF-8'
}
4 changes: 4 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# 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
Binary file added gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
5 changes: 5 additions & 0 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading

0 comments on commit d443b7e

Please sign in to comment.