mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-25 22:44:23 +00:00
quick fix : Redundant 'if' statement
This commit is contained in:
1 parent
ce3ee201a3
commit
d0c3b57e22
29 files changed
+48
-130
No files matched your search
@@ -20,18 +20,12 @@ public class SlotBehavedOnly extends Slot {
|
||||
|
||||
int stackL = b.getStackLimit(par1ItemStack);
|
||||
|
||||
if (b != null
|
||||
&& this.inventory.getStackInSlot(this.slotNumber) != null
|
||||
&& !this.inventory.getStackInSlot(this.slotNumber).isItemEqual(par1ItemStack)) {
|
||||
if (this.inventory.getStackInSlot(this.slotNumber) != null && !this.inventory.getStackInSlot(this.slotNumber).isItemEqual(par1ItemStack)) {
|
||||
ItemStack is = this.inventory.getStackInSlot(this.slotNumber);
|
||||
if (is.stackSize + par1ItemStack.stackSize <= stackL) {
|
||||
return true;
|
||||
}
|
||||
return is.stackSize + par1ItemStack.stackSize <= stackL;
|
||||
} else {
|
||||
return par1ItemStack.stackSize <= stackL;
|
||||
}
|
||||
|
||||
return false;
|
||||
// return b != null;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user