Skip to content

Commit

Permalink
feat: update to 1.20.4 (#164)
Browse files Browse the repository at this point in the history
* feat: update dependencies and versions

* chore: update publish action

* chore: set mc version in publish action

* chore: add neo classname/package remapper

* feat: apply neo classname/package remapper

Note: This had to be applied on 1.20.1 (ebceeb5) and copied over. It only works on a compiling workspace

* chore: rename tags to neoforge

* chore: delete disabled test recipe

* chore: update mods.toml

* chore: update ATs

* fix: config

* fix: networking

* fix: registries

* feat: update capabilities

* fix: main class

* fix: datagen

* fix: particles

* feat: update recipes

* fix: access to tags

* fix: various fixes

* fix: various fixes

* fix: various fixes

* fix: various fixes

* chore: run datagen

* chore: add REI as runtime helper

* fix: remove forge from publish workflow

* fix: crash when accessing sided caps

* chore: add rei for runtime help

* fix: sal ammoniac bucket

* chore: code cleanup

* fix: temp hack for fluid rendering

* fix: divination rod recipe loading

* chore: remove loading related code that no longer works on .4

* chore: format

* chore: add missing licensing info
  • Loading branch information
klikli-dev authored Jan 17, 2024
1 parent ebceeb5 commit 1f0caf5
Show file tree
Hide file tree
Showing 611 changed files with 4,174 additions and 4,911 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/build_and_publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,11 @@ jobs:
uses: stefanzweifel/git-auto-commit-action@v4
if: ${{ steps.get_release_type.outputs.result != 'test' }}
with:
branch: version/1.20.1
branch: version/1.20.4
commit_message: 'docs: update CHANGELOG.md for ${{ github.ref_name }} [skip ci]'
file_pattern: CHANGELOG.md
- name: Upload to Mod Platforms
uses: Kir-Antipov/[email protected]
uses: Kir-Antipov/[email protected].0
with:
modrinth-id: uOVMgoil
modrinth-token: ${{ secrets.MODRINTH_API_KEY }}
Expand All @@ -101,7 +101,6 @@ jobs:
version: ${{ steps.get_mc_version.outputs.result }}-${{ steps.get_version.outputs.result }}
version-type: ${{ steps.get_release_type.outputs.result }}
loaders: |
forge
neoforge
game-versions: |
${{ steps.get_mc_version.outputs.result }}
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ build
# other
eclipse
run
runs

# Files from Forge MDK
forge*changelog.txt
183 changes: 56 additions & 127 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,133 +1,61 @@
plugins {
id 'idea'
id 'maven-publish'
id 'net.minecraftforge.gradle' version '[6.0,6.2)'
id 'org.parchmentmc.librarian.forgegradle' version '1.+'
id 'net.neoforged.gradle.userdev' version "${neogradle_version}"
}

apply from: 'https://gist.githubusercontent.com/Technici4n/facbcdf18ce1a556b76e6027180c32ce/raw/059ab3d504a590461746fc6e3065159f4932a960/classremapper.gradle'

if (System.getenv('MOD_VERSION') != null) {
mod_version = System.getenv('MOD_VERSION')
}
version = mod_version

base {
archivesName = mod_id + "-" + minecraft_version
archivesName = "${mod_id}-${minecraft_version}-neoforge"
}

// Mojang ships Java 17 to end users in 1.18+, so your mod should target Java 17.
java.toolchain.languageVersion = JavaLanguageVersion.of(17)
java.withSourcesJar()

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

accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg')
// Currently, this location cannot be changed from the default.

// Default run configurations.
// These can be tweaked, removed, or duplicated as needed.
runs {
client {
workingDirectory project.file('run')

// Recommended logging data for a userdev environment
// The markers can be added/remove as needed separated by commas.
// "SCAN": For mods scan.
// "REGISTRIES": For firing of registry events.
// "REGISTRYDUMP": For getting the contents of all registries.
property 'forge.logging.markers', 'REGISTRIES'

// Recommended logging level for the console
// You can set various levels here.
// Please read: https://stackoverflow.com/questions/2031163/when-to-use-the-different-log-levels
property 'forge.logging.console.level', 'debug'

//Fix for mixin refmap crash (in our case for AU)
property 'mixin.env.remapRefMap', 'true'
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"

// Comma-separated list of namespaces to load gametests from. Empty = all namespaces.
property 'forge.enabledGameTestNamespaces', 'theurgy'

// enable using JBR to hotswap MOAR
// also ignore the option if someone isnt using JBR
jvmArgs '-XX:+AllowEnhancedClassRedefinition', '-XX:+IgnoreUnrecognizedVMOptions'

mods {
"${mod_id}" {
source sourceSets.main
}
}
}

server {
workingDirectory project.file('run')

property 'forge.logging.markers', 'REGISTRIES'

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

//Fix for mixin refmap crash (in our case for AU)
property 'mixin.env.remapRefMap', 'true'
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"

property 'forge.enabledGameTestNamespaces', 'theurgy'

// enable using JBR to hotswap MOAR
// also ignore the option if someone isnt using JBR
jvmArgs '-XX:+AllowEnhancedClassRedefinition', '-XX:+IgnoreUnrecognizedVMOptions'

mods {
"${mod_id}" {
source sourceSets.main
}
}
//TODO: re enable source sets once mods are updated
sourceSets {
main {
java {
exclude '**/integration/jei/**/*.java'
exclude '**/AlmostUnifiedIntegrationImpl.java'
exclude '**/jade/**/*.java'
}
}
}

// This run config launches GameTestServer and runs all registered gametests, then exits.
// By default, the server will crash when no gametests are provided.
// The gametest system is also enabled by default for other run configs under the /test command.
gameTestServer {
workingDirectory project.file('run')

property 'forge.logging.markers', 'REGISTRIES'

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

//Fix for mixin refmap crash (in our case for AU)
property 'mixin.env.remapRefMap', 'true'
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"

property 'forge.enabledGameTestNamespaces', 'theurgy'

mods {
"${mod_id}" {
source sourceSets.main
}
}
}
// Mojang ships Java 17 to end users in 1.18+, so your mod should target Java 17.
java.toolchain.languageVersion = JavaLanguageVersion.of(17)
java.withSourcesJar()

data {
workingDirectory project.file('run')

property 'forge.logging.markers', 'REGISTRIES'
if (file('src/main/resources/META-INF/accesstransformer.cfg').exists()) {
minecraft.accessTransformers.file file('src/main/resources/META-INF/accesstransformer.cfg')
}

property 'forge.logging.console.level', 'debug'
runs {
configureEach {
systemProperty 'forge.logging.markers', 'REGISTRIES'
systemProperty 'forge.logging.console.level', 'debug'
jvmArguments.addAll('-XX:+AllowEnhancedClassRedefinition', '-XX:+IgnoreUnrecognizedVMOptions')
modSource project.sourceSets.main
}

//Fix for mixin refmap crash (in our case for AU)
property 'mixin.env.remapRefMap', 'true'
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"
client {
systemProperty 'forge.enabledGameTestNamespaces', project.mod_id
programArgument "--username=Dev"
}

// Specify the modid for data generation, where to output the resulting resource, and where to look for existing resources.
args '--mod', 'theurgy', '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources/')
server {
systemProperty 'forge.enabledGameTestNamespaces', project.mod_id
// programArgument '--nogui'
}

mods {
"${mod_id}" {
source sourceSets.main
}
}
}
data {
programArguments.addAll '--mod', project.mod_id, '--all', '--output', file('src/generated/resources/').getAbsolutePath(), '--existing', file('src/main/resources/').getAbsolutePath()
}
}

Expand Down Expand Up @@ -172,30 +100,33 @@ repositories {
}

dependencies {
// Specify the version of Minecraft to use. If this is any group other than 'net.minecraft', it is assumed
// that the dep is a ForgeGradle 'patcher' dependency, and its patches will be applied.
// The userdev artifact is a special name and will get all sorts of transformations applied to it.
minecraft "net.minecraftforge:forge:${forge_version}"

//Jei
compileOnly fg.deobf("mezz.jei:jei-${minecraft_version}-common-api:${jei_version}")
compileOnly fg.deobf("mezz.jei:jei-${minecraft_version}-common:${jei_version}")
//we're using the vanilla recipe category rendering constants
compileOnly fg.deobf("mezz.jei:jei-${minecraft_version}-forge-api:${jei_version}")
runtimeOnly fg.deobf("mezz.jei:jei-${minecraft_version}-forge:${jei_version}")

implementation "net.neoforged:neoforge:${neo_version}"
//TODO: enable once available
// //Jei
// compileOnly "mezz.jei:jei-${minecraft_version}-common-api:${jei_version}"
// compileOnly "mezz.jei:jei-${minecraft_version}-common:${jei_version}"
// //we're using the vanilla recipe category rendering constants
// compileOnly "mezz.jei:jei-${minecraft_version}-neoforge-api:${jei_version}"
// runtimeOnly "mezz.jei:jei-${minecraft_version}-neoforge:${jei_version}"

//TODO: enable once available
//almostunified
implementation fg.deobf("com.almostreliable.mods:almostunified-forge:${minecraft_version}-${almost_unified_version}")
// implementation "com.almostreliable.mods:almostunified-forge:${minecraft_version}-${almost_unified_version}"

//Geckolib
implementation fg.deobf("software.bernie.geckolib:geckolib-forge-${geckolib_minecraft_version}:${geckolib_version}")
implementation "software.bernie.geckolib:geckolib-neoforge-${geckolib_minecraft_version}:${geckolib_version}"

//modonomicon
// compileOnly fg.deobf("com.klikli_dev:modonomicon-${minecraft_version}-common:${modonomicon_version}")
implementation fg.deobf("com.klikli_dev:modonomicon-${minecraft_version}-forge:${modonomicon_version}")
implementation "com.klikli_dev:modonomicon-${minecraft_version}-neoforge:${modonomicon_version}"

//Jade (Hwyla/Waila)
implementation fg.deobf("maven.modrinth:jade:${jade_version}")
//TODO: enable once available
// implementation "maven.modrinth:jade:${jade_version}"

//TODO: remove once jei is available
runtimeOnly "curse.maven:roughly-enough-items-310111:4973489"
runtimeOnly "curse.maven:cloth-config-348521:4973457"
runtimeOnly "curse.maven:architectury-api-419699:5020280"
}

processResources {
Expand All @@ -219,8 +150,6 @@ jar {
}
}

jar.finalizedBy('reobfJar')

publishing {
publications {
mavenJava(MavenPublication) {
Expand Down
41 changes: 23 additions & 18 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,26 @@ systemProp.net.minecraftforge.gradle.check.certs=false
## Environment Properties

# The Minecraft version must agree with the Forge version to get a valid artifact
minecraft_version=1.20.1
minecraft_version=1.20.4
# The Minecraft version range can use any release version of Minecraft as bounds.
# Snapshots, pre-releases, and release candidates are not guaranteed to sort properly
# as they do not follow standard versioning conventions.
minecraft_version_range=[1.20,1.21)
# The Forge version must agree with the Minecraft version to get a valid artifact
forge_version=1.20.1-47.1.3
# The Forge version range can use any version of Forge as bounds or match the loader version range
forge_version_range=[47,)
# The loader version range can only use the major version of Forge/FML as bounds
loader_version_range=[47,)
minecraft_version_range=[1.20.4,1.21)

mapping_channel=parchment
#postfix is target mc version, optional prefix is source parchment mc version
mapping_version=2023.06.26-1.20.1
## Neo
# The neo version must agree with the Minecraft version to get a valid artifact
neo_version=20.4.80-beta
# The neo version range can use any version of neo as bounds or match the loader version range
neo_version_range=[20.4.80-beta,)
# The loader version range can only use the major version of Neo/FML as bounds
neo_loader_version_range=[2,)
neogradle_version=7.0.80

# neo directly reads these properties
# the version the mappings were created for, does not need to match the current mc version
neogradle.subsystems.parchment.minecraftVersion=1.20.3
# the mapping version
neogradle.subsystems.parchment.mappingsVersion=2023.12.31

## Mod Properties
group=com.klikli_dev
Expand All @@ -34,15 +39,15 @@ mod_description=An open-source magic mod built around classical alchemy to repli

## Dependency Properties

jei_version=15.2.0.23
jei_version_range=[15.2.0.0,)
jei_version=16.0.0.28
jei_version_range=[16.0.0.28,)
modonomicon_version=1.54.4
modonomicon_version_range=[1.52.0,)
almost_unified_version=0.5.0
almost_unified_version_range=[0.5.0,)
# geckolib currently names their files after 1.20
geckolib_minecraft_version=1.20
geckolib_version=4.2
geckolib_version_range=[4.2,)
jade_version=11.6.4
jade_version_range=[11.0.0,)
geckolib_minecraft_version=1.20.4
geckolib_version=4.4.1
geckolib_version_range=[4.4.1,)
jade_version=13.2.2
jade_version_range=[13.2.2,)
11 changes: 4 additions & 7 deletions settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,13 @@ pluginManagement {
repositories {
gradlePluginPortal()
maven {
url = 'https://maven.minecraftforge.net/'
content {
includeGroup "net.minecraftforge.gradle"
includeGroup "net.minecraftforge"
}
url = 'https://maven.neoforged.net/releases/'
}
maven { url = 'https://maven.parchmentmc.org' }
}
}

plugins {
id 'org.gradle.toolchains.foojay-resolver-convention' version '0.5.0'
}
}

rootProject.name = 'Theurgy ' + minecraft_version
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// 1.20.1 2023-06-14T18:13:30.5425607 Registries
b9dc44db0143205750319e6a0e908376bc98d251 data/theurgy/forge/biome_modifier/add_sal_ammoniac_ore.json
// 1.20.4 2024-01-16T15:38:38.1742182 Registries
744153a8b0875b5e2ac142292159f46c322cf09c data/theurgy/neoforge/biome_modifier/add_sal_ammoniac_ore.json
eed8cd1911e09af63a869a86d83ab846401194f9 data/theurgy/worldgen/configured_feature/sal_ammoniac_ore.json
3983ae18720546d5efb83e7ac1aa81c774492d63 data/theurgy/worldgen/placed_feature/sal_ammoniac_ore.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// 1.20.1 2023-12-22T17:10:57.2437607 Multiblocks: theurgy
// 1.20.4 2024-01-16T15:38:38.1732174 Multiblocks: theurgy
063aa91958795c57f58083ca62e775e9476a9407 data/theurgy/modonomicon/multiblocks/placement/calcination_oven.json
c480adc4c7baf9ba5321c4ee48193369676f8762 data/theurgy/modonomicon/multiblocks/placement/distiller.json
b9d8372529ac674469f93113632ad36c34e3a053 data/theurgy/modonomicon/multiblocks/placement/incubator.json
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// 1.20.1 2024-01-14T17:14:30.6463442 Books: theurgy
// 1.20.4 2024-01-16T15:38:38.1572169 Books: theurgy
945f222b9db8c0781d05b5a13138c18620a0edc3 data/theurgy/modonomicon/books/the_hermetica/book.json
8d3e827b43dcc0cc2a98237a8dc202460d926fbb data/theurgy/modonomicon/books/the_hermetica/categories/apparatus.json
f8d69cb91187d2b3fe517c93941f1e546a1c7253 data/theurgy/modonomicon/books/the_hermetica/categories/getting_started.json
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
// 1.20.1 2023-08-09T18:51:43.548697 Calcination Recipes
a5756e1a31689ca8cae6437a484508ca55cf4fc4 data/theurgy/recipes/calcination/crops.json
a64dcbb8e53294baece161f35e3ffe6f955792c0 data/theurgy/recipes/calcination/mineral.json
649d4abafe0e54ff8687147e455e4397a4f24a81 data/theurgy/recipes/calcination/mineral_from_gems.json
a73d6746b9da21884b4bdbf049a305fd0eb0e352 data/theurgy/recipes/calcination/mineral_from_ingots.json
5b632c7dab106c7e08cedd112583127449d4214d data/theurgy/recipes/calcination/mineral_from_ores.json
11c275d2dbb36ddca5c1a9c5bd28b6417dbe6cf4 data/theurgy/recipes/calcination/mineral_from_other_minerals.json
c4f15d063ce4d40680e8dd35088edca3ed039b62 data/theurgy/recipes/calcination/mineral_from_raw_materials.json
bdf19939bbc758a7e2eea7e752297462e50ac223 data/theurgy/recipes/calcination/strata_from_clay.json
7f61c7ef364951fcef8fcef2ac37fe64b39f2864 data/theurgy/recipes/calcination/strata_from_clay_ball.json
cc788f9fc42a9517375a84f5f3370fc14bf54275 data/theurgy/recipes/calcination/strata_from_cobblestone.json
6f74b2a7ecb0829bf941a82b953d72caa6a62f75 data/theurgy/recipes/calcination/strata_from_dirt.json
efefd53deca4a6748ab4e12d49cc9bc4d5472918 data/theurgy/recipes/calcination/strata_from_gravel.json
bec049e7c8eb375d8aab3a215d2eb0fb830a948a data/theurgy/recipes/calcination/strata_from_sand.json
0ddcd5f65d8741d05b56ad2f6c16678713da6bef data/theurgy/recipes/calcination/strata_from_sandstone.json
11bfc21a42c3403e7eee808f37a52aed6e4d103c data/theurgy/recipes/calcination/strata_from_stone.json
// 1.20.4 2024-01-16T15:38:38.169219 Calcination Recipes
ce3b44af0f50b6c19befc1355a050c5eac500091 data/theurgy/recipes/calcination/crops.json
15b0bc231284fa27e47c3bb3108c2f6218748e21 data/theurgy/recipes/calcination/mineral.json
e2cd1c651633ebe9800f131ede02740faa314bb7 data/theurgy/recipes/calcination/mineral_from_gems.json
a2f1b1d53c8757e25ea2496daf83eef015f6c442 data/theurgy/recipes/calcination/mineral_from_ingots.json
84e23a3485fe68c745fc43b19858f4c57d7906be data/theurgy/recipes/calcination/mineral_from_ores.json
1d9f0a0b7d9d898b622c54f5179fbfffd98fc999 data/theurgy/recipes/calcination/mineral_from_other_minerals.json
2b5d9dc85ff5a1afe05d88e1f8190d041c18e498 data/theurgy/recipes/calcination/mineral_from_raw_materials.json
aa1410bfe3153eb4771c826d60a2bedf12321fb9 data/theurgy/recipes/calcination/strata_from_clay.json
52fa2c468144c8663fdb758092a92e9087686ce5 data/theurgy/recipes/calcination/strata_from_clay_ball.json
9ba4085be7dc415b190f000b787b9272e7d7d601 data/theurgy/recipes/calcination/strata_from_cobblestone.json
102ee2845def6d82af2185661fe603e5cf83939c data/theurgy/recipes/calcination/strata_from_dirt.json
f1003cfb6b2baa186452fb7f96c40417650f4951 data/theurgy/recipes/calcination/strata_from_gravel.json
ca74d63d2687fd0a4c11095ce17dae08b385ff9a data/theurgy/recipes/calcination/strata_from_sand.json
ae13ebdbaee5416d3077119fdc9fbccf34d2bf69 data/theurgy/recipes/calcination/strata_from_sandstone.json
4f1d59f3ca87eecb604cf6d341c1e2c525549ea2 data/theurgy/recipes/calcination/strata_from_stone.json
Loading

0 comments on commit 1f0caf5

Please sign in to comment.