Skip to content

Commit

Permalink
feat: update to 1.20.4 (#1035)
Browse files Browse the repository at this point in the history
* chore: update workflow file

* feat: update code

* chore: fix versions of deps

* chore: various fixes

* fix: networking

* fix: registries

* fix: api

* fix: message imports

* fix: capabilities

* fix: integrations

* fix: various fixes

* fix: spirit fire and torches

* fix: recipes

* fix: capability use

* fix: various fixes

* fix: various fixes

* fix: ui

* fix: various fixes

* fix: various fixes

* fix: first successful build

* fix: first successful start - crashes due to curios being oudated vs neo

* fix: disable curious until updated

* chore: add runs to gitignore

* fix: accidentally registered theurgy networking

* fix: enable custom torches using a particle supplier

* fix: nbt init crash

* fix: was using theurgy message handler ...

* chore: fix ignore list

* fix: recipe deserialization

* fix: entity rider location

* fix: conditions, other data

* fix: entity loot tables

* fix: chimera jump

* feat: enable jei

* feat: update to neo screen changes

* chore: update to latest theurgy

* chore: set theurgy version range

* fix: crushing recipe provider conditions

* fix: network coded for crushing recipe

* chore: resolve todo comments
  • Loading branch information
klikli-dev authored Jan 19, 2024
1 parent ce705b0 commit 5458cfd
Show file tree
Hide file tree
Showing 749 changed files with 4,924 additions and 6,092 deletions.
15 changes: 7 additions & 8 deletions .github/workflows/build_and_publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,17 +63,17 @@ jobs:
with:
allowUpdates: true
draft: false
name: occultism-${{ steps.get_mc_version.outputs.result }}-${{ steps.get_version.outputs.result }}-${{ steps.get_release_type.outputs.result }}
name: occultism-${{ steps.get_mc_version.outputs.result }}-neoforge-${{ steps.get_version.outputs.result }}-${{ steps.get_release_type.outputs.result }}
body: ${{ steps.changelog.outputs.changes }}
token: ${{ github.token }}
tag: ${{ github.ref }}
artifacts: ./build/libs/occultism-${{ steps.get_mc_version.outputs.result }}-${{ steps.get_version.outputs.result }}.jar
artifacts: ./build/libs/occultism-${{ steps.get_mc_version.outputs.result }}-neoforge-${{ steps.get_version.outputs.result }}.jar
artifactContentType: application/java-archive
- name: Commit CHANGELOG.md
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
Expand All @@ -86,14 +86,13 @@ jobs:
curseforge-token: ${{ secrets.CURSEFORGE_API_KEY }}

files: |
build/libs/occultism-${{ steps.get_mc_version.outputs.result }}-${{ steps.get_version.outputs.result }}.jar
build/libs/occultism-${{ steps.get_mc_version.outputs.result }}-${{ steps.get_version.outputs.result }}-sources.jar
build/libs/occultism-${{ steps.get_mc_version.outputs.result }}-neoforge-${{ steps.get_version.outputs.result }}.jar
build/libs/occultism-${{ steps.get_mc_version.outputs.result }}-neoforge-${{ steps.get_version.outputs.result }}-sources.jar
name: occultism-${{ steps.get_mc_version.outputs.result }}-${{ steps.get_version.outputs.result }}.jar
version: ${{ steps.get_mc_version.outputs.result }}-${{ steps.get_version.outputs.result }}
name: occultism-${{ steps.get_mc_version.outputs.result }}-neoforge-${{ steps.get_version.outputs.result }}.jar
version: ${{ steps.get_mc_version.outputs.result }}-neoforge-${{ 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
Expand Down
157 changes: 49 additions & 108 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
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}"
}

if (System.getenv('MOD_VERSION') != null) {
Expand All @@ -11,96 +10,45 @@ if (System.getenv('MOD_VERSION') != null) {
version = mod_version

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

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')

// Default run configurations.
// These can be tweaked, removed, or duplicated as needed.
runs {
client {
workingDirectory project.file('run')
args '--username', 'Occultism'
// Recommended logging data for a userdev environment
property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'

// Recommended logging level for the console
property 'forge.logging.console.level', 'debug'

//Fix for patchouli mixin crash
property 'mixin.env.remapRefMap', 'true'
property 'mixin.env.refMapRemappingFile', "${projectDir}/build/createSrgToMcp/output.srg"

// 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
}
}
}

clientalt {
parent runs.client
//somehow doesnt replace the name but adds a new one, so we manually need remove
args '--username', 'Occultism2' //#s get replaced with random numbers when starting
}

server {
workingDirectory project.file('run')

// Recommended logging data for a userdev environment
property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'

// Recommended logging level for the console
property 'forge.logging.console.level', 'debug'

//Workaround for patchouli mixin crash
property 'mixin.env.disableRefMap', 'true'

// 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 '**/AlmostUnifiedIntegrationImpl.java'
}
}
}

data {
workingDirectory project.file('run')
java.toolchain.languageVersion = JavaLanguageVersion.of(17)
java.withSourcesJar()

// Recommended logging data for a userdev environment
property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'
if (file('src/main/resources/META-INF/accesstransformer.cfg').exists()) {
minecraft.accessTransformers.file file('src/main/resources/META-INF/accesstransformer.cfg')
}

// Recommended logging level for the console
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
}

//Workaround for patchouli mixin crash
property 'mixin.env.disableRefMap', 'true'
client {
systemProperty 'forge.enabledGameTestNamespaces', project.mod_id
programArgument "--username=Occultism"
}

// Specify the modid for data generation, where to output the resulting resource, and where to look for existing resources.
args '--mod', 'occultism', '--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 @@ -162,51 +110,46 @@ repositories {
}

dependencies {
// Specify the version of Minecraft to use, If this is any group other then 'net.minecraft' it is assumed
// that the dep is a ForgeGradle 'patcher' dependency. And it's 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}"
implementation "net.neoforged:neoforge:${neo_version}"

//Jei
compileOnly fg.deobf("mezz.jei:jei-${minecraft_version}-common-api:${jei_version}")
compileOnly fg.deobf("mezz.jei:jei-${minecraft_version}-forge-api:${jei_version}")
runtimeOnly fg.deobf("mezz.jei:jei-${minecraft_version}-forge:${jei_version}")
compileOnly "mezz.jei:jei-${minecraft_version}-common-api:${jei_version}"
compileOnly "mezz.jei:jei-${minecraft_version}-neoforge-api:${jei_version}"
runtimeOnly "mezz.jei:jei-${minecraft_version}-neoforge:${jei_version}"

//TODO: enable once available
//curios
compileOnly fg.deobf("top.theillusivec4.curios:curios-forge:${curios_version}+${minecraft_version}:api")
runtimeOnly fg.deobf("top.theillusivec4.curios:curios-forge:${curios_version}+${minecraft_version}")
// compileOnly "top.theillusivec4.curios:curios-neoforge:${curios_version}+${minecraft_version}:api"
// runtimeOnly "top.theillusivec4.curios:curios-neoforge:${curios_version}+${minecraft_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}"

//smartbrainlib
implementation fg.deobf("net.tslat.smartbrainlib:SmartBrainLib-forge-${smartbrainlib_minecraft_version}:${smartbrainlib_version}")
implementation "net.tslat.smartbrainlib:SmartBrainLib-neoforge-${smartbrainlib_minecraft_version}:${smartbrainlib_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}"

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

//theurgy
compileOnly fg.deobf("com.klikli_dev:theurgy-${minecraft_version}:${theurgy_version}"){transitive=false}
runtimeOnly fg.deobf("com.klikli_dev:theurgy-${minecraft_version}:${theurgy_version}"){transitive=false}
compileOnly "com.klikli_dev:theurgy-${minecraft_version}-neoforge:${theurgy_version}"
runtimeOnly "com.klikli_dev:theurgy-${minecraft_version}-neoforge:${theurgy_version}"

//runtime only helper mods for dev env, placed in ./runtime-mods, example: Hwyla-forge-1.10.11-B78_1.16.2.jar
//runtimeOnly fg.deobf("ignoredvalue:Hwyla:forge-1.10.11-B78_1.16.2")
//runtimeOnly "ignoredvalue:Hwyla:forge-1.10.11-B78_1.16.2"

//alltheores - for recipe testing
//enable once available for 1.20
//runtimeOnly fg.deobf("curse.maven:alltheores-405593:xyz") //

//Ma for crafting issue testing
// runtimeOnly fg.deobf("curse.maven:mysticalagriculture-246640:4399151") //MysticalAgriculture-1.19.3-6.1.4.jar
// runtimeOnly fg.deobf("curse.maven:cucumber-272335:4395466") //Cucumber-1.19.3-6.1.2.jar
//runtimeOnly "curse.maven:alltheores-405593:xyz" //

//PerViamInvenire - for AI integration testing
//runtimeOnly fg.deobf("curse.maven:perviaminvenire-449945:xyz") //
//runtimeOnly "curse.maven:perviaminvenire-449945:xyz" //
//enable once available for 1.20
//runtimeOnly fg.deobf("com.ldtteam:per_viam_invenire:1.19.3-XYZ-RELEASE:universal")
//runtimeOnly "com.ldtteam:per_viam_invenire:1.19.3-XYZ-RELEASE:universal"
}

processResources {
Expand All @@ -230,8 +173,6 @@ jar {
}
}

jar.finalizedBy('reobfJar')

publishing {
publications {
mavenJava(MavenPublication) {
Expand Down
56 changes: 29 additions & 27 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,25 @@ org.gradle.daemon=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,)

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.117-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 @@ -32,22 +36,20 @@ mod_authors=Kli Kli
mod_description=A magic mod inspired by the world of Jonathan Stroud's Bartimaeus. With the help of occult rituals players can summon entities from the "Other Side" to perform magic.

## Dependency Properties
jei_version=15.2.0.23
jei_version_range=[15.2.0.0,)
curios_version=5.2.0-beta.3
curios_version_range=[5.2.0-beta.1,)
# geckolib currently names their files after 1.20
geckolib_minecraft_version=1.20.1
geckolib_version=4.4
geckolib_version_range=[4.4,)
# smartbrainlib currently names their files after 1.20
smartbrainlib_minecraft_version=1.20
smartbrainlib_version=1.11
smartbrainlib_version_range=[1.11,)
jei_version=17.0.0.30
jei_version_range=[17.0.0.30,)
curios_version=7.0.0-beta.3
curios_version_range=[7.0.0-beta.3,)
geckolib_minecraft_version=1.20.4
geckolib_version=4.4.1
geckolib_version_range=[4.4.1,)
smartbrainlib_minecraft_version=1.20.4
smartbrainlib_version=1.13
smartbrainlib_version_range=[1.13,)
almost_unified_version=0.5.0
almost_unified_version_range=[0.5.0,)
modonomicon_version=1.51.0
modonomicon_version_range=[1.38.1,)
theurgy_version=1.8.0
theurgy_version_range=[1.6.3,)
modonomicon_version=1.54.4
modonomicon_version_range=[1.52.0,)
theurgy_version=1.13.0
theurgy_version_range=[1.11.0,)
per_viam_invenire_version_range=[0.1.57,)
13 changes: 4 additions & 9 deletions settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,13 @@ pluginManagement {
repositories {
gradlePluginPortal()
maven {
url = 'https://maven.minecraftforge.net/'
content {
includeGroup "net.minecraftforge.gradle"
includeGroup "net.minecraftforge"
}
}
maven {
url = 'https://maven.parchmentmc.org'
url = 'https://maven.neoforged.net/releases/'
}
}
}

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

rootProject.name = 'Occultism ' + minecraft_version
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,7 @@
"criteria": {
"craft_dimensional_matrix": {
"conditions": {
"ritual_predicate": {
"ritual_id": "occultism:ritual/craft_dimensional_matrix"
}
"ritual_id": "occultism:ritual/craft_dimensional_matrix"
},
"trigger": "occultism:ritual"
}
Expand All @@ -15,7 +13,6 @@
"description": {
"translate": "advancements.occultism.craft_dimensional_matrix.description"
},
"frame": "task",
"hidden": true,
"icon": {
"item": "occultism:jei_dummy/none"
Expand Down
Loading

0 comments on commit 5458cfd

Please sign in to comment.