SoulTicket internal implementation (#1372)
* Fix the Blood Tank BB * Add modid to command localizations to prevent conflicts * Fixed the items not being drawn on the right Y-level for the Sigil of Holding HUD Corrected localizations of other lang files * SoulTicket internal implementation * do what TehNut says * implement hashCode() * Fix toggleable sigils draining on r-click when it shouldn't Also moved the ItemSigil and ItemSigilToggleable to the sigil package (why wasn't it there???)
This commit is contained in:
parent
093cfb13ef
commit
b441e7fc1e
56 changed files with 210 additions and 147 deletions
|
@ -3,6 +3,7 @@ package WayofTime.bloodmagic.item;
|
|||
import WayofTime.bloodmagic.BloodMagic;
|
||||
import WayofTime.bloodmagic.client.IVariantProvider;
|
||||
import WayofTime.bloodmagic.core.data.Binding;
|
||||
import WayofTime.bloodmagic.core.data.SoulTicket;
|
||||
import WayofTime.bloodmagic.util.helper.NetworkHelper;
|
||||
import WayofTime.bloodmagic.util.helper.PlayerHelper;
|
||||
import it.unimi.dsi.fastutil.ints.Int2ObjectMap;
|
||||
|
@ -14,6 +15,7 @@ import net.minecraft.potion.PotionEffect;
|
|||
import javax.annotation.Nonnull;
|
||||
import javax.annotation.Nullable;
|
||||
|
||||
// TODO: Make some hook somewhere that attaches the pos to the ticket otherwise the tickets are basically useless lmao
|
||||
public class ItemLavaCrystal extends ItemBindableBase implements IVariantProvider {
|
||||
|
||||
public ItemLavaCrystal() {
|
||||
|
@ -25,7 +27,7 @@ public class ItemLavaCrystal extends ItemBindableBase implements IVariantProvide
|
|||
public ItemStack getContainerItem(ItemStack stack) {
|
||||
Binding binding = getBinding(stack);
|
||||
if (binding != null)
|
||||
NetworkHelper.getSoulNetwork(binding.getOwnerId()).syphon(25);
|
||||
NetworkHelper.getSoulNetwork(binding.getOwnerId()).syphon(SoulTicket.item(stack, 25));
|
||||
|
||||
ItemStack returnStack = new ItemStack(this);
|
||||
returnStack.setTagCompound(stack.getTagCompound());
|
||||
|
@ -43,7 +45,7 @@ public class ItemLavaCrystal extends ItemBindableBase implements IVariantProvide
|
|||
if (binding == null)
|
||||
return -1;
|
||||
|
||||
if (NetworkHelper.syphonFromContainer(stack, 25))
|
||||
if (NetworkHelper.syphonFromContainer(stack, SoulTicket.item(stack, 25)))
|
||||
return 200;
|
||||
else {
|
||||
EntityPlayer player = PlayerHelper.getPlayerFromUUID(binding.getOwnerId());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue