Scale recipe cost+output when crafting speed exceeds 1 craft per tick

Moderator: ickputzdirwech

Post Reply
BLucky
Manual Inserter
Manual Inserter
Posts: 3
Joined: Tue Jan 16, 2024 3:52 pm
Contact:

Scale recipe cost+output when crafting speed exceeds 1 craft per tick

Post by BLucky »

TL;DR
Make multiple crafts' worth of products in a single tick if the crafting speed exceeds 1 craft per tick

What ?
Right now, if you have a high crafting speed (beacons/modded entities/etc), the rate at which crafts complete is 1 time per tick. There are recipe compression mods that address that, but it's manual, clutters the recipe list, increases load time, and those mods may not be compatible with other mods. My idea is to calculate the speed at which one craft would complete (which is being done already), and if it's less than 1 tick, scale the recipe's cost and yield by the excess speed, with the scaling factor probably rounded towards zero to not deal with fractional outputs/inputs.
Why ?
This would improve UPS by letting fast crafters do cheap recipes in bulk, reducing the amount of entities in the world, especially in megabases with beaconed crafters and modded bases with modded crafters that are potentially faster. This shouldn't incur a performance hit since the scaling factor can be saved and only recalculated on crafting speed/recipe change, and it most probably either too much work to add

Rseding91
Factorio Staff
Factorio Staff
Posts: 13223
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Scale recipe cost+output when crafting speed exceeds 1 craft per tick

Post by Rseding91 »

As part of work on 2.0/Space Age we ran into the "> 1 crafts per tick" limit in base game and re-worked crafting machines so they are able to handle it correctly.

So this idea will be obsolete when 2.0/Space Age is released and > 1 crafts per tick "just works".
If you want to get ahold of me I'm almost always on Discord.

Koub
Global Moderator
Global Moderator
Posts: 7223
Joined: Fri May 30, 2014 8:54 am
Contact:

Re: Scale recipe cost+output when crafting speed exceeds 1 craft per tick

Post by Koub »

[Koub] OK I'll move this to Implemented for 2.0 then.
Koub - Please consider English is not my native language.

Post Reply

Return to “Implemented in 2.0”