Extract ++ and -- from expressions

This commit is contained in:
thatsIch
2015-03-26 11:07:26 +01:00
parent b31f2df58d
commit 9bf8b4388f
26 changed files with 89 additions and 40 deletions
@@ -45,7 +45,9 @@ public class AEInvIterator implements Iterator<IAEItemStack>
@Override
public IAEItemStack next()
{
return this.inv.getAEStackInSlot( this.x++ );
IAEItemStack result = this.inv.getAEStackInSlot( this.x );
this.x++;
return result;
}
@Override
@@ -39,7 +39,9 @@ public class ChainedIterator<T> implements Iterator<T>
@Override
public T next()
{
return this.list[this.offset++];
T result = this.list[this.offset];
this.offset++;
return result;
}
@Override
@@ -45,7 +45,9 @@ public class InvIterator implements Iterator<ItemStack>
@Override
public ItemStack next()
{
return this.inv.getStackInSlot( this.x++ );
ItemStack result = this.inv.getStackInSlot( this.x );
this.x++;
return result;
}
@Override
@@ -44,7 +44,8 @@ public class StackToSlotIterator implements Iterator<ItemSlot>
@Override
public ItemSlot next()
{
this.iss.slot = this.x++;
this.iss.slot = this.x;
this.x++;
this.iss.setItemStack( this.is.next() );
return this.iss;
}