Added workaround for sorting items on amount with fake amount when showing crafting label

This commit is contained in:
Gunther De Wachter 2017-08-16 02:25:53 +02:00
parent e65083b045
commit b5b8050c4c

View file

@ -80,9 +80,9 @@ public class ItemSorters
{
if( getDirection() == SortDir.ASCENDING )
{
return compareLong( o2.getStackSize(), o1.getStackSize() );
return compareLong( o2.getStackSize() - ( o2.getShowCraftingLabel() ? 1 : 0 ), o1.getStackSize() - ( o1.getShowCraftingLabel() ? 1 : 0 ) );
}
return compareLong( o1.getStackSize(), o2.getStackSize() );
return compareLong( o1.getStackSize() - ( o1.getShowCraftingLabel() ? 1 : 0 ), o2.getStackSize() - ( o2.getShowCraftingLabel() ? 1 : 0 ) );
}
};
private static IInvTweaks api;