/*
 * Decompiled with CFR 0.152.
 * 
 * Could not load the following classes:
 *  com.llamalad7.mixinextras.injector.ModifyExpressionValue
 *  net.minecraft.class_1702
 *  org.spongepowered.asm.mixin.Mixin
 *  org.spongepowered.asm.mixin.injection.At
 */
package meteordevelopment.meteorclient.mixin;

import com.llamalad7.mixinextras.injector.ModifyExpressionValue;
import meteordevelopment.meteorclient.systems.modules.Modules;
import meteordevelopment.meteorclient.systems.modules.movement.NoSlow;
import net.minecraft.class_1702;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;

@Mixin(value={class_1702.class})
public class HungerManagerMixin {
    @ModifyExpressionValue(method={"method_75882()Z"}, at={@At(value="CONSTANT", args={"floatValue=6.0f"})})
    private float onHunger(float constant) {
        if (Modules.get().get(NoSlow.class).hunger()) {
            return -1.0f;
        }
        return constant;
    }
}

