Shirkit / AdditionalPasteSettings

Factorio mod for paste settings that should be added to the game.
https://mods.factorio.com/mods/SHiRKiT/additional-paste-settings/
MIT License
0 stars 2 forks source link

Protect update_stack and fix rounding to 0 items with "per-time-size" setting #4

Closed doktorstick closed 4 years ago

doktorstick commented 4 years ago

When the recipe.energy was high enough, it could make the result from update_stack < 1.0. This would have the effect of adding the item to the logistics but with no count (a count of 0, effectively). The main point of this change is to address that.

The other change in update_stack ensures that the stack is an item_prototype. I had a paste crash when it tried pasting a fluid. This might be a result of my own personal change that adds a setting which allows the user to decide on the behavior of pasting to a buffer chest (a00cd38), but I thought it a good guard regardless for the mainline.

Shirkit commented 4 years ago

It's now merged, releasing 0.9.0 right now.

Thanks for your contribution @doktorstick !