mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-22 04:52:25 +00:00
more !isEmpty checks to validate ItemStacks
This commit is contained in:
1 parent
785cb2c683
commit
f3cd020a31
4 files changed
+5
-5
No files matched your search
@@ -63,7 +63,7 @@ public class GlowPanelModel extends OBJBakedModelBase
|
||||
|
||||
public EnumColor getColor()
|
||||
{
|
||||
if(tempStack != null)
|
||||
if(tempStack != null && !tempStack.isEmpty())
|
||||
{
|
||||
return EnumColor.DYES[tempStack.getItemDamage()];
|
||||
}
|
||||
|
||||
@@ -410,7 +410,7 @@ public abstract class BlockBasic extends Block implements ICTMBlock
|
||||
|
||||
if(mop != null && mop.sideHit == bin.facing)
|
||||
{
|
||||
if(bin.bottomStack != null)
|
||||
if(bin.bottomStack != null && !bin.bottomStack.isEmpty())
|
||||
{
|
||||
if(!player.isSneaking())
|
||||
{
|
||||
|
||||
@@ -53,7 +53,7 @@ public class InfusionInput extends MachineInput<InfusionInput>
|
||||
@Override
|
||||
public boolean isValid()
|
||||
{
|
||||
return infuse.type != null && inputStack != null;
|
||||
return infuse.type != null && inputStack != null && !inputStack.isEmpty();
|
||||
}
|
||||
|
||||
public boolean use(NonNullList<ItemStack> inventory, int index, InfuseStorage infuseStorage, boolean deplete)
|
||||
|
||||
Reference in new issue
Block a user