Skip to content

Commit

Permalink
Move tags update mixin to ClientCommonPacketListenerImpl
Browse files Browse the repository at this point in the history
  • Loading branch information
embeddedt committed Aug 3, 2023
1 parent 7fcaf71 commit 23b473f
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 5 deletions.
@@ -0,0 +1,16 @@
package org.embeddedt.modernfix.fabric.mixin.core;

import net.minecraft.client.multiplayer.ClientCommonPacketListenerImpl;
import org.embeddedt.modernfix.ModernFixClientFabric;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;

@Mixin(ClientCommonPacketListenerImpl.class)
public class ClientCommonPacketListenerImplMixin {
@Inject(method = "handleUpdateTags", at = @At("RETURN"))
private void signalTags(CallbackInfo ci) {
ModernFixClientFabric.commonMod.onTagsUpdated();
}
}
Expand Up @@ -13,9 +13,4 @@ public class ClientPlayNetHandlerMixin {
private void signalRecipes(CallbackInfo ci) {
ModernFixClientFabric.commonMod.onRecipesUpdated();
}

@Inject(method = "handleUpdateTags", at = @At("RETURN"))
private void signalTags(CallbackInfo ci) {
ModernFixClientFabric.commonMod.onTagsUpdated();
}
}

0 comments on commit 23b473f

Please sign in to comment.