Skip to main content

Module produce

Module produce 

Source
Expand description

Workplace production: ResourceProduceComponent’s states and the ConsumeProduce work of ConsumeProduceComponent: the wood cutter, blacksmith, tailor, tavern, quarry and mine. See docs/JOBS.md “Production”.

A worker of the workplace’s profession takes the work at a free “use” point. In order it hauls goods the current recipe does not use out of the building, fetches missing inputs, hauls the workplace’s own output piles away while its “create” points are full, and otherwise works one cycle at its use point. Every cycles completed cycles the next cycle also consumes the inputs and leaves the output as a pile on a free create point.

Original: FUN_140130700.

Functions§

pick_recipe
The recipe a production cycle uses: the selected one; or, with the selector at −1 (any), one RandFloat over the weights, the first whose running sum passes the draw times their total; 0 for any other selector, or when no weight passes.
production_group
The stock-manager slot a raw material counts towards (production limits).