mirror of
				https://github.com/SquidDev-CC/CC-Tweaked
				synced 2025-10-31 05:33:00 +00:00 
			
		
		
		
	Copy the item stack before merging
Otherwise we would mutate the stack, and so the current mount was considered empty. Closes #240 (though would be nice to improve this).
This commit is contained in:
		| @@ -63,7 +63,7 @@ public class ContainerDiskDrive extends Container | |||||||
|         Slot slot = inventorySlots.get( slotIndex ); |         Slot slot = inventorySlots.get( slotIndex ); | ||||||
|         if( slot == null || !slot.getHasStack() ) return ItemStack.EMPTY; |         if( slot == null || !slot.getHasStack() ) return ItemStack.EMPTY; | ||||||
|  |  | ||||||
|         ItemStack existing = slot.getStack(); |         ItemStack existing = slot.getStack().copy(); | ||||||
|         ItemStack result = existing.copy(); |         ItemStack result = existing.copy(); | ||||||
|         if( slotIndex == 0 ) |         if( slotIndex == 0 ) | ||||||
|         { |         { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 SquidDev
					SquidDev