Ammo consumption is not tracked correctly when "consumed by stacking"

Things that has been reported already before.
JonnyLucca
Manual Inserter
Manual Inserter
Posts: 1
Joined: Tue Jul 15, 2025 7:36 pm
Contact:

Ammo consumption is not tracked correctly when "consumed by stacking"

Post by JonnyLucca »

Hi,
When two Magazines with less than 100% fill level in sum are stacked together, one magazine is consumed without being tracked in the statistics menu.

I've recorded and attached a 1 min video of this behavior to better understand the situation, including a counter example where a magazine is consumed correctly under the same conditions.

I'm not sure what the expected behavior should be in this case, as the magazines are not really consumed in the moment they are stacked, they just get merged. Depending on the way the logic is implemented, either tracking a merged magazine as consumed or tracking a magazine "per bullet shot" might be the correct behavior. Changing the behavior of inserters to prefer full magazines might mitigate the problem into irrelevance.

This behavior actually screwed me over in game when the statistic menu of my space ship showed me an over production of ammunition, but the buffer still drained slowly because the magazine consumption wasn't tracked correctly. The ship had 16 turrets with only 2 of them grabbing magazines of a belt. This led to a lot of magazines merging together in flight. After trying out different test setups I got the idea that magazine merging might be the problem, which is true. I've attached a screenshot of the menu showing the situation as well.
Factorio Screenshot 2025.07.13 - 15.38.33.03.png
Factorio Screenshot 2025.07.13 - 15.38.33.03.png (1018.6 KiB) Viewed 61 times
Best regards,
JonnyLucca
User avatar
boskid
Factorio Staff
Factorio Staff
Posts: 4029
Joined: Thu Dec 14, 2017 6:56 pm
Contact:

Re: Ammo consumption is not tracked correctly when "consumed by stacking"

Post by boskid »

Items with fractional counts strike again. Related viewtopic.php?p=671626#p671626
Post Reply

Return to “Duplicates”