Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
plugins {
id 'fabric-loom' version '1.6-SNAPSHOT'
id 'fabric-loom' version '1.8-SNAPSHOT'
id 'maven-publish'
}

sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
sourceCompatibility = JavaVersion.VERSION_21
targetCompatibility = JavaVersion.VERSION_21

archivesBaseName = project.archives_base_name
version = "mc${project.minecraft_version}-${project.mod_version}"
Expand Down Expand Up @@ -54,7 +54,7 @@ processResources {
}

tasks.withType(JavaCompile).configureEach {
it.options.release = 17
it.options.release = 21
}

java {
Expand Down
10 changes: 5 additions & 5 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@ org.gradle.parallel=true

# Fabric Properties
# check these on https://fabricmc.net/develop
minecraft_version=1.21
yarn_mappings=1.21+build.2
loader_version=0.15.11
minecraft_version=1.21.3
yarn_mappings=1.21.3+build.2
loader_version=0.16.9

# Mod Properties
# x-release-please-start-version
mod_version=0.3.1
mod_version=0.3.3
# x-release-please-end
maven_group=io.nihlen.scriptschunkloaders
archives_base_name=scripts-chunk-loaders

# Dependencies
fabric_version=0.100.1+1.21
fabric_version=0.107.0+1.21.3
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.6-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@

@Mixin(AbstractMinecartEntity.class)
public abstract class AbstractMinecartEntityMixin extends Entity implements MinecartEntityExt {
@Shadow public abstract AbstractMinecartEntity.Type getMinecartType();

@Unique
private boolean isChunkLoader = false;
Expand Down Expand Up @@ -58,8 +57,9 @@ private void injectConstructor(CallbackInfo callbackInfo) {
}

public void scripts_chunk_loaders$setChunkLoaderNameFromInventory() {
var minecartType = this.getMinecartType();
if (minecartType == AbstractMinecartEntity.Type.CHEST) {
EntityType<?> minecartType = this.getType();

if (minecartType == EntityType.CHEST_MINECART) {
//noinspection DataFlowIssue - We're sure this is a chest because of the if statement.
var entity = (ChestMinecartEntity)(Object)this;
var firstSlot = entity.getInventory().get(0);
Expand Down
4 changes: 2 additions & 2 deletions src/main/resources/fabric.mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
"scripts-chunk-loaders.mixins.json"
],
"depends": {
"fabricloader": ">=0.15.11",
"minecraft": "1.21",
"fabricloader": ">=0.16.9",
"minecraft": "1.21.3",
"java": ">=21",
"fabric-api": "*"
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/scripts-chunk-loaders.mixins.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"required": true,
"minVersion": "0.8",
"package": "io.nihlen.scriptschunkloaders.mixin",
"compatibilityLevel": "JAVA_17",
"compatibilityLevel": "JAVA_21",
"mixins": [
],
"client": [
Expand Down