Make magnet ring respect pickup delays and tweak blacklist (#2799)

* Items with pickup delay >40 ticks will be ignored
* Ignore AE2 seeds with their changed name
* Make the blacklist actually usable and not crash when added to with IMC
This commit is contained in:
Hubry authored and Vasco Lavos committed 2019-02-01 16:44:00 +00:00
1 parent b9e169fff1
commit cff5edcd21
1 file changed
+3 -3
@@ -12,7 +12,7 @@ package vazkii.botania.common.item.equipment.bauble;
import baubles.api.BaubleType;
import baubles.api.BaublesApi;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.Lists;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.item.EntityItem;
import net.minecraft.item.Item;
@@ -41,7 +41,7 @@ public class ItemMagnetRing extends ItemBauble {
private static final String TAG_COOLDOWN = "cooldown";
private static final List<ResourceLocation> BLACKLIST = ImmutableList.of(new ResourceLocation("appliedenergistics2", "item.ItemCrystalSeed"));
private static final List<ResourceLocation> BLACKLIST = Lists.newArrayList(new ResourceLocation("appliedenergistics2", "crystal_seed"));
private final int range;
@@ -105,7 +105,7 @@ public class ItemMagnetRing extends ItemBauble {
}
private boolean canPullItem(EntityItem item) {
if(item.isDead || SubTileSolegnolia.hasSolegnoliaAround(item))
if(item.isDead || item.pickupDelay >= 40 || SubTileSolegnolia.hasSolegnoliaAround(item))
return false;
ItemStack stack = item.getItem();