ConstructionWand/src/main/java/thetadev/constructionwand/items/ItemWandInfinity.java
Theta-Dev 4212e7997c Port almost done.
Missing: Shift+Click / Scroll events
2020-11-07 02:07:43 +01:00

18 lines
499 B
Java

package thetadev.constructionwand.items;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.item.ItemStack;
import thetadev.constructionwand.ConstructionWand;
public class ItemWandInfinity extends ItemWand
{
public ItemWandInfinity(String name)
{
super(name, new Settings().maxCount(1).fireproof());
}
@Override
public int getLimit(PlayerEntity player, ItemStack stack) {
return player.isCreative() ? ConstructionWand.instance.config.LIMIT_CREATIVE : getLimit();
}
}