Skip to content

Commit b5e5053

Browse files
committed
[Fix]: Fix a bug where Controller blocks would randomly stop inserting items
1 parent a30cb3a commit b5e5053

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/net/p3pp3rf1y/sophisticatedcore/controller/ControllerBlockEntityBase.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -706,7 +706,7 @@ public long insert(ItemVariant resource, long maxAmount, TransactionContext ctx,
706706
}
707707
}
708708

709-
return (insertIntoAnyEmpty ? insertIntoStorages(emptySlotsStorages, resource, remaining, ctx, false) : maxAmount - remaining);
709+
return (insertIntoAnyEmpty ? (maxAmount - remaining) + insertIntoStorages(emptySlotsStorages, resource, remaining, ctx, false) : maxAmount - remaining);
710710
}
711711

712712
private long insertIntoStoragesThatMatchStack(ItemVariant resource, long maxAmount, ItemStackKey stackKey, TransactionContext ctx) {

0 commit comments

Comments
 (0)