From 707aaba0d9c21073a1d60b99d5beb72a3298e4c8 Mon Sep 17 00:00:00 2001 From: xlzv <96470093+xlzv@users.noreply.github.com> Date: Thu, 10 Oct 2024 03:12:05 +0900 Subject: [PATCH] Fix infinite effect false warning (#59) --- src/main/java/fi/dy/masa/tweakeroo/tweaks/MiscTweaks.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/fi/dy/masa/tweakeroo/tweaks/MiscTweaks.java b/src/main/java/fi/dy/masa/tweakeroo/tweaks/MiscTweaks.java index 1f5893768..76ab66618 100644 --- a/src/main/java/fi/dy/masa/tweakeroo/tweaks/MiscTweaks.java +++ b/src/main/java/fi/dy/masa/tweakeroo/tweaks/MiscTweaks.java @@ -249,6 +249,7 @@ private static boolean potionWarningShouldInclude(StatusEffectInstance effect) (effect.getEffectType().value().isBeneficial() || Configs.Generic.POTION_WARNING_BENEFICIAL_ONLY.getBooleanValue() == false) && effect.getDuration() <= Configs.Generic.POTION_WARNING_THRESHOLD.getIntegerValue() && + effect.getDuration() >= 0 && POTION_RESTRICTION.isAllowed(effect.getEffectType().value()); }