Train Foundry


A large train foundry building that assembles complete trains from blueprint templates: import a train blueprint, queue it, feed the parts with inserters, and watch the finished train fuel up and drive off onto your rail network on its own.

Content
4 days ago
2.0 - 2.1
556
Trains

Changelog

Version: 1.3.0
Date: 2026-08-26
  Changes:
    - The "In progress" panel now says WHICH of the two departure conditions is holding the train:
      "Internal track occupied" or "Exit signal closed" -- the latter with a note that the exit block
      runs to the next signal on your network, so a train passing far from the foundry can hold it
      back. Both used to read "Waiting for clear track", which sent you looking at the wrong end.
      When neither holds the train, the panel says it is leaving instead of announcing a wait that
      isn't there.
  Bugfixes:
    - A build waiting for the internal track to clear showed no message at all.
Version: 1.2.0
Date: 2026-08-12
  Features:
    - Accepted fuels window. A new window (gear button in Configuration) lists every unlocked fuel a
      locomotive can burn, with one checkbox per quality; clicking a fuel icon ticks or unticks its
      whole row, and clicking a quality header does the same for its whole column. Only ticked fuels
      are burned and requested over the circuit, and the best one available in the buffer is picked
      -- highest fuel value first, then highest quality -- so "solid fuel legendary, otherwise rare,
      otherwise normal" just works. Left untouched, every fuel is accepted in normal quality,
      exactly as before.
  Changes:
    - Circuit rework. The circuit connector is now an electric pole, and the buffer contents and the
      missing components are two independent outputs: enable either or both, and pick the wire
      (red, green, or both) each one goes out on. The stock/requests radio is gone -- no more single
      mode to choose -- and the pole doubles as a power connection point for the building.
      Existing setups are migrated: whichever mode was selected stays enabled, on both wires, so a
      wire already plugged in keeps carrying exactly what it carried before.
Version: 1.1.0
Date: 2026-08-10
  Features:
    - Quality support. Rolling stock, item requests and equipment-grid gear are now tracked per
      quality: a blueprint made of legendary stock asks for legendary components and builds a
      legendary train. Quality is shown on the component and reserve slots, as a badge on the
      blueprint tiles, and on the per-plan stock counters.
    - The stock counters now use the plan's actual rolling stock icons instead of a generic
      locomotive and cargo wagon.
  Bugfixes:
    - Quality components in the reserve were counted as normal ones, so they could be consumed to
      build a normal train.
    - Equipment-grid gear was installed at the blueprint quality but only charged as normal.
    - Recycling a train refunded normal components regardless of the train quality.
    - Perishable items (pentapod and biter eggs, Gleba produce) are no longer offered as fuel.
    - Rolling stock whose placement item differs from its entity name is now resolved correctly.
  Changes:
    - In stock mode the circuit connector now emits one signal per item AND quality, instead of one
      signal per item with all qualities added together.
Version: 1.0.0
Date: 2026-08-07
  Info:
    - The mod now targets Factorio 2.1 only. Factorio 2.0 is no longer maintained (a 2.0 branch is
      kept for a possible crash-only hotfix).
    - Upgrading an existing save: the platform is rebuilt automatically. An extension placed before
      1.0.0 keeps the old adjacency spacing and may show a small gap at the junction with the main
      building — just re-place that extension flush against it to fix it.
  Features:
    - The building is now made of real entities: stone walls with gates around the perimeter, two
      internal tracks (assembly and recycling), and decorative bands (industrial top, scrap bottom).
    - Recycling track (optional, per-foundry): a dead-end second track with a "Train Recycle" stop.
      A train left on it is destroyed and fully refunded (vehicles, fuel and cargo) into the buffer.
    - Rich placement preview (2.1): while holding the foundry item (real or ghost), a full picture of
      the building follows the cursor in both the game view and the map, so you can see exactly where
      the tracks and walls will land before placing. It also shows on a placed ghost.
    - New look: overhead crane gantry over the tracks, a 1x2 reserve chest (tall-steel-chest sprite
      from the Wide Containers Assets mod by Lebothegizebo, MIT), and the platform elements spaced so
      inserters fit between the chests and the circuit connector.
  Changes:
    - Extensions only snap to a foundry placed at the exact adjacency distance; placing one too far is
      refused and refunded.
  Bugfixes:
    - Top and bottom walls of the enclosure no longer go missing on reload.
Version: 0.7.0
Date: 2026-07-25
  Features:
    - Generic fuel option (off by default) in the Configuration window: off keeps the fuel from the
      blueprint (as before); on fills every locomotive with the best unlocked compatible fuel
      available in the buffer and adds a refuel interrupt covering every fuel the locomotive can
      burn (trigger at 10% of full, refill to fuel_full). A blueprint that carries no fuel at all
      always uses this generic fuelling (nothing to honour).
    - New "clear stuck train" button: if a built train cannot leave and sits on the internal track,
      one click destroys it and refunds its cost.
    - Component and fuel slots now show the item name on hover and open Factoriopedia on click.
    - Component buffer enlarged from 20 to 100 stacks.
  Changes:
    - Train Foundry is now split into two independent mods. This one keeps the blueprint source
      (unchanged buildings, entities and saves). A separate mod, "Train Foundry for Smart Train
      Combinator", builds trains from Smart Train Combinator models instead. Install either or both;
      their buildings can coexist on the same surface.
  Bugfixes:
    - Removing extensions no longer leaves orphaned rails east of the shortened foundry.
Version: 0.5.2
Date: 2026-07-24
  Bugfixes:
    - Trains built from a blueprint with no base stops - driven only by a group and/or interrupts,
      as in a logistic-network setup - now leave the foundry in automatic mode instead of manual,
      and keep all their interrupts.
Version: 0.5.1
Date: 2026-07-22
  Bugfixes:
    - Hide the foundry's internal helper entities (circuit connector, input and blueprint chests,
      rails and signal) from Factoriopedia.
Version: 0.5.0
Date: 2026-07-19
  Features:
    - Optional right-side (east) exit: trains can now leave the foundry to the right as well as the
      left. Open the foundry window, click the panel button in the title bar, and tick "Right (east)"
      in the Configuration window to lay an east exit track and signal. Either or both sides can be
      open at once; the train picks the side its schedule reaches. On a chained foundry the east exit
      follows the far (east) end of the chain and re-anchors automatically when extensions are added
      or removed. New foundries default to left-only, so existing setups are unchanged.
  Changes:
    - Reworked foundry sprite: both side walls are now closed; the exit track is drawn over the wall
      only where a train actually leaves, so it reads as a clean gate on each open side.
    - The side panel is now titled "Configuration" (exit sides + circuit read mode).
    - Blueprints are no longer rejected for locomotive facing: a train facing any direction is
      accepted, since the foundry can now dispatch to either side.
    - Placing a foundry no longer requires a pre-existing rail under the exit: the building lays its
      own exit track. Just connect your network to it afterwards.
Version: 0.3.1
Date: 2026-07-19
  Bugfixes:
    - Belts, inserters and other entities placed on the free apron area next to the foundry can now
      be hovered, configured and removed again: the building no longer steals the mouse-over from
      them. The foundry can still be opened from its body, from the circuit connector, and with the
      Ctrl+Alt+F shortcut.
Version: 0.3.0
Date: 2026-07-18
  Features:
    - Longer trains: place another Train Foundry right against the east side of an existing one to
      chain it as an extension. Each module adds room for 5 more vehicles (5 alone, 10 with one
      extension, 15 with two, and so on). Extensions have no chests or signal of their own; the
      whole chain is driven from the master's window, and its stock and exit stay on the west end.
    - Dedicated blueprint chest (blue) on the west apron: drop your train blueprints there. The
      book in the main window mirrors it; click a plan to queue it.
    - Equipment grids on locomotives/wagons are now requested and consumed from the stock like
      fuel and ammo (no longer created for free), and refunded on cancel.
  Changes:
    - The main window is now a regular window: Escape closes it. Clicking the blueprint chest
      opens a floating management window (unaffected by the blueprint library shortcut).
    - Reworked window: blueprint library with per-plan locomotive/wagon counts, rejected plans
      flagged in red with the reason, available/required ratio on each component slot, and a
      Clear queue button.
    - The master cannot be mined while it still has extensions (remove them from the right first).
    - The blueprint length limit now follows the chain: a plan that was rejected as too long
      becomes valid on its own once you add an extension (and vice versa), no re-import needed.
  Bugfixes:
    - Blueprints are validated before building: a plan is rejected up front if it is not a pure
      train, is too long for the foundry, is not on a straight track, or has no locomotive facing
      the exit (west) - instead of failing mid-build.
    - The circuit "requests" mode no longer counts the components of a train already being built.
Version: 0.1.0
Date: 2026-07-17
  Info:
    - First release. Build complete trains from blueprint templates.
  Features:
    - A large foundry building placed on the end of a rail line. Import train blueprints as
      templates, queue them, and each train is assembled and sent off onto your network on its
      own (composition, colors, fuel, schedule, train group and blueprint parameters included).
    - Internal iron chest stock feeds the builds; feed it by hand or with inserters.
    - Circuit connector: broadcast the stock contents or the missing components (picked in the
      window).
    - Shortcut-bar button (and CTRL+ALT+F) opens the foundry's window from anywhere. One foundry
      per planet.
    - Vanilla, Space Age and Nullius compatible.