Swap the API packages

The new one is now built for the api jar and the old one is now internal.
It will slowly be moved around to sane places within the internal code. Most
of the features provided in the old "api" are addon specific features which
will generally rely on the main jar anyways. The new API will be specific
to compatibility features, such as blacklists, recipes, and value modification.
This commit is contained in:
Nicholas Ignoffo 2018-02-05 17:04:38 -08:00
parent 4fbcac6aa2
commit ddaadfbe52
421 changed files with 1006 additions and 999 deletions

View file

@ -0,0 +1,48 @@
package WayofTime.bloodmagic.apibutnotreally.impl;
import WayofTime.bloodmagic.apibutnotreally.Constants;
import WayofTime.bloodmagic.apibutnotreally.iface.ISigil;
import WayofTime.bloodmagic.apibutnotreally.util.helper.NBTHelper;
import net.minecraft.item.ItemStack;
import net.minecraft.util.math.BlockPos;
import net.minecraft.world.World;
/**
* Base class for all (static) sigils.
*/
public class ItemSigil extends ItemBindable implements ISigil {
private int lpUsed;
public ItemSigil(int lpUsed) {
super();
this.lpUsed = lpUsed;
}
public boolean isUnusable(ItemStack stack) {
NBTHelper.checkNBT(stack);
return stack.getTagCompound().getBoolean(Constants.NBT.UNUSABLE);
}
public ItemStack setUnusable(ItemStack stack, boolean unusable) {
NBTHelper.checkNBT(stack);
stack.getTagCompound().setBoolean(Constants.NBT.UNUSABLE, unusable);
return stack;
}
@Override
public boolean performArrayEffect(World world, BlockPos pos) {
return false;
}
@Override
public boolean hasArrayEffect() {
return false;
}
public int getLpUsed() {
return lpUsed;
}
}