mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-10-25 20:22:33 +00:00
Fix Ring of Mantle re-applying Haste every tick (#133)
Co-authored-by: guneykabel <guneykabel@users.noreply.github.com>
This commit is contained in:
1 parent
0852f91ba7
commit
9d677e7734
1 file changed
+3
-4
@@ -36,10 +36,9 @@ public class ItemMiningRing extends ItemBauble implements IManaUsingItem {
|
||||
if(!hasMana)
|
||||
onUnequipped(stack, player);
|
||||
else {
|
||||
if(player.getActivePotionEffect(Potion.digSpeed) != null)
|
||||
player.removePotionEffect(Potion.digSpeed.id);
|
||||
|
||||
player.addPotionEffect(new PotionEffect(Potion.digSpeed.id, Integer.MAX_VALUE, 1, true));
|
||||
PotionEffect currentEffect = player.getActivePotionEffect(Potion.digSpeed);
|
||||
if(currentEffect == null || currentEffect.getAmplifier() < 1)
|
||||
player.addPotionEffect(new PotionEffect(Potion.digSpeed.id, Integer.MAX_VALUE, 1, true));
|
||||
}
|
||||
|
||||
if(player.swingProgress == 0.25F)
|
||||
|
||||
Reference in new issue
Block a user