---
id: automation-programming
status: active
supersededBy: []
lang: en
title: Automation and programming
description: >-
  Automation moves repeated work into a system; the player builds connections
  and identifies the limiting stage.
intro: >-
  Automation moves repeated work into a system; the player builds connections
  and identifies the limiting stage. Each overview separates player actions,
  state changes and alternative rules. Examples are hypothetical design
  scenarios, not claims about a named game. A prototype check states an
  observable question for the next iteration. Existing detailed references
  remain separately linked from the direction map.
updatedAt: '2026-10-21'
sources:
  - title: 'Factorio: Content'
    url: 'https://www.factorio.com/game/content'
    description: >-
      Developer overview of production, transport and circuit networks as
      connected gameplay systems.
counts:
  families: 9
  branches: 9
  variants: 36
url: 'https://gamemechanics.pro/en/mechanics/automation-programming/'
markdownUrl: 'https://gamemechanics.pro/content/mechanics/en/automation-programming.md'
license: CC-BY-4.0
codeLicense: MIT
attribution: gamemechanics.pro contributors
provenance: >-
  Original bilingual editorial overviews authored for gamemechanics.pro on
  2026-10-20 and reviewed on 2026-10-21. Scenarios are hypothetical design
  examples; prototype checks describe work to perform, not completed playtests.
  Primary sources support the stated techniques and implementation context, not
  every proposed variant.
---
# Automation and programming

Automation moves repeated work into a system; the player builds connections and identifies the limiting stage. Each overview separates player actions, state changes and alternative rules. Examples are hypothetical design scenarios, not claims about a named game. A prototype check states an observable question for the next iteration. Existing detailed references remain separately linked from the direction map.

## Mechanics and variants

<a id="mechanics"></a>

### 1. Production chains and factories

<a id="t107"></a>
id: t107
canonicalId: automation-programming--t107
url: https://gamemechanics.pro/en/mechanics/automation-programming/#t107

A factory connects recipes so one stage's output becomes another's input and constrains total production.

#### Mechanic variants

<a id="t107-variants"></a>
- Recipe ratios determine parallel machine counts. <a id="t107-v1"></a>
- Byproducts require a separate output line. <a id="t107-v2"></a>
- Modular cells simplify capacity expansion. <a id="t107-v3"></a>
- Recycling returns part of the raw materials. <a id="t107-v4"></a>

Design example: Three furnaces feed two assemblers until one missing reagent stalls the whole chain.

Prototype check: Measure sustained output over a long interval rather than only with fully stocked input buffers.

- [Factorio: Content](https://www.factorio.com/game/content)

### 2. Conveyors, pipes and flow distribution

<a id="t108"></a>
id: t108
canonicalId: automation-programming--t108
url: https://gamemechanics.pro/en/mechanics/automation-programming/#t108

Transport lines carry limited-rate flows while junctions distribute them among consumers.

#### Mechanic variants

<a id="t108-variants"></a>
- Splitters set output shares or priorities. <a id="t108-v1"></a>
- Mergers need rules for competing flows. <a id="t108-v2"></a>
- Filters separate a selected material type. <a id="t108-v3"></a>
- Bypasses preserve operation when a branch blocks. <a id="t108-v4"></a>

Design example: A priority branch first supplies repairs and sends surplus metal to sales.

Prototype check: Test blocked outputs and restarting so material is neither lost nor permanently stuck at a junction.

- [Factorio: Content](https://www.factorio.com/game/content)

### 3. Storage, buffers and throughput

<a id="t109"></a>
id: t109
canonicalId: automation-programming--t109
url: https://gamemechanics.pro/en/mechanics/automation-programming/#t109

Buffers store differences between arrivals and consumption, absorbing brief disruptions without raising sustained line capacity.

#### Mechanic variants

<a id="t109-variants"></a>
- Storage limits stop an upstream stage. <a id="t109-v1"></a>
- Inventory smooths irregular deliveries. <a id="t109-v2"></a>
- Batch thresholds combine small arrivals. <a id="t109-v3"></a>
- Overflow redirects surplus to an alternate output. <a id="t109-v4"></a>

Design example: Storage absorbs a brief delivery gap but drains under a persistently undersized extractor.

Prototype check: Test that indicators distinguish temporary inventory from the actual throughput of the limiting stage.

- [Factorio: Content](https://www.factorio.com/game/content)

### 4. Railways and dispatching

<a id="t110"></a>
id: t110
canonicalId: automation-programming--t110
url: https://gamemechanics.pro/en/mechanics/automation-programming/#t110

Railways share track between trains; schedules and signals coordinate access to limited sections.

#### Mechanic variants

<a id="t110-variants"></a>
- Block control prevents shared section occupancy. <a id="t110-v1"></a>
- Passing loops allow opposing trains to pass. <a id="t110-v2"></a>
- Conditional orders change stations with cargo levels. <a id="t110-v3"></a>
- Platform length limits the serviceable train size. <a id="t110-v4"></a>

Design example: An empty train waits in a loop while a loaded train reaches the single unloading platform.

Prototype check: Test circular deadlocks and explanations for the occupied section preventing movement.

- [Factorio: Content](https://www.factorio.com/game/content)

### 5. Robots, drones and autonomous delivery

<a id="t111"></a>
id: t111
canonicalId: automation-programming--t111
url: https://gamemechanics.pro/en/mechanics/automation-programming/#t111

Autonomous delivery assigns carriers to requests using capacity, routes and available energy.

#### Mechanic variants

<a id="t111-variants"></a>
- Requests set a desired item stock level. <a id="t111-v1"></a>
- Batching combines compatible deliveries. <a id="t111-v2"></a>
- Charging creates a robot service queue. <a id="t111-v3"></a>
- Fallback routes avoid an inaccessible region. <a id="t111-v4"></a>

Design example: Drones stop serving a distant depot when their remaining charge cannot cover the return trip.

Prototype check: Test deliveries when recipients disappear and the return rule for cargo already picked up.

- [Factorio: Content](https://www.factorio.com/game/content)

### 6. Power grids and load management

<a id="t112"></a>
id: t112
canonicalId: automation-programming--t112
url: https://gamemechanics.pro/en/mechanics/automation-programming/#t112

Power grids split limited generation among consumers, storage and losses, requiring load priorities.

#### Mechanic variants

<a id="t112-variants"></a>
- Storage shifts surplus to another time period. <a id="t112-v1"></a>
- Peak demand needs a temporary reserve. <a id="t112-v2"></a>
- Load shedding preserves a critical service. <a id="t112-v3"></a>
- Network separation contains a spreading failure. <a id="t112-v4"></a>

Design example: A night factory uses stored energy and cuts advertising before water pumps when reserves run low.

Prototype check: Test simultaneous consumer startup and prevent energy creation through charging cycles.

- [Factorio: Content](https://www.factorio.com/game/content)

### 7. Logic circuits, signals and feedback

<a id="t113"></a>
id: t113
canonicalId: automation-programming--t113
url: https://gamemechanics.pro/en/mechanics/automation-programming/#t113

Signals measure state, conditions select responses and feedback repeats control based on the result.

#### Mechanic variants

<a id="t113-variants"></a>
- Thresholds start a pump at low inventory. <a id="t113-v1"></a>
- Hysteresis prevents repeated rapid switching. <a id="t113-v2"></a>
- Delays separate commands from their results. <a id="t113-v3"></a>
- Logical AND combines several permission conditions. <a id="t113-v4"></a>

Design example: A pump starts below one-third storage and stops above two-thirds to avoid command chatter.

Prototype check: Test threshold noise and measurement delay so control avoids unintended oscillation.

- [Factorio: Content](https://www.factorio.com/game/content)

### 8. Programming as a gameplay challenge

<a id="t115"></a>
id: t115
canonicalId: automation-programming--t115
url: https://gamemechanics.pro/en/mechanics/automation-programming/#t115

A program solves a task by transforming specified inputs into outputs with limited instructions and memory.

#### Mechanic variants

<a id="t115-variants"></a>
- Sequences order a set of simple instructions. <a id="t115-v1"></a>
- Loops repeat actions until a stopping condition. <a id="t115-v2"></a>
- Branches choose responses from input values. <a id="t115-v3"></a>
- Memory limits require reusing stored data. <a id="t115-v4"></a>

Design example: A robot sorts labeled parcels with one sensor and only two available memory cells.

Prototype check: Test unseen inputs so a valid program does not merely memorize the displayed tutorial example.

- [Factorio: Content](https://www.factorio.com/game/content)

### 9. Optimizing a production or automation system

<a id="t116"></a>
id: t116
canonicalId: automation-programming--t116
url: https://gamemechanics.pro/en/mechanics/automation-programming/#t116

Optimization improves a working system's measurable result by comparing speed, cost, space and resilience.

#### Mechanic variants

<a id="t116-variants"></a>
- Time measures completed-task latency. <a id="t116-v1"></a>
- Cost counts components used by the solution. <a id="t116-v2"></a>
- Area limits the footprint of a design. <a id="t116-v3"></a>
- Reliability tests operation under changed inputs. <a id="t116-v4"></a>

Design example: A compact line produces fewer parts per minute but leaves room for another product.

Prototype check: Test independent metrics and expose tradeoffs rather than declaring one solution universally best.

- [Factorio: Content](https://www.factorio.com/game/content)

## Sources and examples

Sources support particular techniques or methodology, not every family variant. Design examples and mechanic combinations are illustrative.

- [Factorio: Content](https://www.factorio.com/game/content): Developer overview of production, transport and circuit networks as connected gameplay systems.
