Chest aura improvements (#208)

This commit is contained in:
Soda5601
2023-01-22 01:29:36 +08:00
committed by GitHub
parent 704b7989f1
commit 6a3a8b6d58
4 changed files with 135 additions and 159 deletions

View File

@@ -0,0 +1,27 @@
package anticope.rejects.mixin.meteor.modules;
import anticope.rejects.mixininterface.IInventoryTweaks;
import meteordevelopment.meteorclient.systems.modules.misc.InventoryTweaks;
import net.minecraft.screen.ScreenHandler;
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(value = InventoryTweaks.class, remap = false)
public abstract class InventoryTweaksMixin implements IInventoryTweaks {
private Runnable callback;
@Inject(method = "lambda$steal$3", at = @At("RETURN"))
private void afterSteal(ScreenHandler handler, CallbackInfo info) {
if (callback != null) {
callback.run();
callback = null;
}
}
@Inject(method = "lambda$new$1", at = @At("HEAD"))
private void onStealChanged(Boolean b, CallbackInfo info) {
callback = null;
}
}