From 0411719e5fa99fa3755343ea33a2b87efb3bd699 Mon Sep 17 00:00:00 2001 From: AfterRebelion <559819+AfterRebelion@users.noreply.github.com> Date: Sat, 27 Jun 2020 04:00:58 +0200 Subject: [PATCH] 1.16 update Fixed mixin Increase version to 1.4.0 --- gradle.properties | 8 ++++---- .../smokeextender/mixin/SmokeExtenderMixin.java | 12 ++++++------ src/main/resources/fabric.mod.json | 2 +- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/gradle.properties b/gradle.properties index 0bbadf8..1e120e3 100644 --- a/gradle.properties +++ b/gradle.properties @@ -4,15 +4,15 @@ org.gradle.daemon=false # Fabric Properties # check these on https://fabricmc.net/use - minecraft_version=1.15.2 - yarn_mappings=1.15.2+build.17 + minecraft_version=1.16.1 + yarn_mappings=1.16.1+build.9 loader_version=0.8.8+build.202 # Mod Properties - mod_version = 1.3.0 + mod_version = 1.4.0 maven_group = net.afterrebelion archives_base_name = smokeextender # Dependencies # currently not on the main fabric site, check on the maven: https://maven.fabricmc.net/net/fabricmc/fabric-api/fabric-api - fabric_api_version=0.14.0+build.317-1.15 + fabric_api_version=0.14.0+build.371-1.16 diff --git a/src/main/java/net/afterrebelion/smokeextender/mixin/SmokeExtenderMixin.java b/src/main/java/net/afterrebelion/smokeextender/mixin/SmokeExtenderMixin.java index 20557cd..f659766 100644 --- a/src/main/java/net/afterrebelion/smokeextender/mixin/SmokeExtenderMixin.java +++ b/src/main/java/net/afterrebelion/smokeextender/mixin/SmokeExtenderMixin.java @@ -4,7 +4,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.particle.SpriteBillboardParticle; -import net.minecraft.world.World; +import net.minecraft.client.world.ClientWorld; import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.injection.At; import org.spongepowered.asm.mixin.injection.Inject; @@ -13,13 +13,13 @@ @Environment(EnvType.CLIENT) @Mixin(net.minecraft.client.particle.CampfireSmokeParticle.class) public abstract class SmokeExtenderMixin extends SpriteBillboardParticle { - public SmokeExtenderMixin(World world_1, double double_1, double double_2, double double_3, double double_4, double double_5, double double_6) { - super(world_1, double_1, double_2, double_3, double_4, double_5, double_6); + public SmokeExtenderMixin(ClientWorld world, double x, double y, double z, double velocityX, double velocityY, double velocityZ) { + super(world, x, y, z, velocityX, velocityY, velocityZ); } - @Inject(at = @At("RETURN"), method = "(Lnet/minecraft/world/World;DDDDDDZ)V") - private void CampfireSmokeParticle (World world, double x, double y, double z, double velocityX, double velocityY, double velocityZ, boolean bl, CallbackInfo info) { - if (bl) { + @Inject(at = @At("RETURN"), method = "(Lnet/minecraft/client/world/ClientWorld;DDDDDDZ)V") + private void CampfireSmokeParticle (ClientWorld world, double x, double y, double z, double velocityX, double velocityY, double velocityZ, boolean signalFire, CallbackInfo info) { + if (signalFire) { // System.out.println("Injecting on the smoke constructor!"); this.maxAge += 560; } diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json index 2eefb01..5196fb5 100644 --- a/src/main/resources/fabric.mod.json +++ b/src/main/resources/fabric.mod.json @@ -32,6 +32,6 @@ "depends": { "fabricloader": ">=0.8.8", - "minecraft": "1.15.x" + "minecraft": "1.16.x" } }