How malte9799/factoriotools works
FactorioTools is a client-side blueprint editor and production-analysis app, with a separate live map seed viewer. The main workflow mounts the editor, loads blueprint/game data, renders and edits the layout, then calculates rates and simulates belts/circuits for bottleneck analysis and export. The graph includes documented map-generation, overlay, and game-art capabilities; the excerpts do not expose every internal call, so uncertain links are omitted rather than inferred.
Main entry points: index.ts Blueprint Editing · controller.ts Rate Overlay · render.ts Canvas Renderer · app.ts App Router
Components 22
Blueprint Editor
- App Router
apps/site/src/app.ts - Blueprint Editing
apps/site/src/tools/blueprint-editor/index.ts - Floating Windows
apps/site/src/window-manager.ts
Production Analysis
- Rate Overlay
apps/site/src/rate-overlay/controller.ts - Analysis Panels
apps/site/src/rate-overlay/panels.ts - Bottleneck Detection
apps/site/src/rate-overlay/issues.ts - Simulation Factory
apps/site/src/rate-overlay/factory.ts - Overlay Lab
apps/site/src/tools/overlay-lab/index.ts
Game Rendering
- Canvas Renderer
packages/renderer/src/render.ts - Draw Collection
packages/renderer/src/draw/collect.ts - Draw Commands
packages/renderer/src/draw/commands.ts - Canvas Painting
packages/renderer/src/draw/paint.ts - Sprite Atlas
packages/renderer/src/spriteAtlas.ts - Render Catalog
packages/data-pipeline/src/render-catalog.ts
Engine and Simulation
- Blueprint and Rates
packages/engine/src/blueprint.ts - Rate Calculation
packages/engine/src/calc/throughput.ts - Belt Simulation
packages/sim/src/beltSim.ts - Circuit Simulation
packages/sim/src/circuit.ts
Seed Viewer
- Seed Viewer
apps/site/src/tools/seed-viewer/index.ts - Map Worker
apps/site/src/tools/seed-viewer/worker.ts - Map Generation
packages/mapgen/src/surface.ts
Other components
- Player
Connections 29
- Player → App Router: opens tool
apps/site/src/app.ts - App Router → Blueprint Editing: mounts editor
apps/site/src/app.ts - App Router → Overlay Lab: routes to
apps/site/src/app.ts - App Router → Seed Viewer: routes to
apps/site/src/app.ts - Blueprint Editing → Floating Windows: creates windows
apps/site/src/tools/blueprint-editor/index.ts - Blueprint Editing → Blueprint and Rates: imports and exports
apps/site/src/tools/blueprint-editor/index.ts - Blueprint Editing → Canvas Renderer: renders layout
- Blueprint Editing → Rate Overlay: attaches analysis
apps/site/src/tools/blueprint-editor/index.ts - Rate Overlay → Blueprint and Rates: loads data
apps/site/src/rate-overlay/controller.ts - Rate Overlay → Simulation Factory: builds simulation
apps/site/src/rate-overlay/controller.ts - Rate Overlay → Bottleneck Detection: detects issues
apps/site/src/rate-overlay/controller.ts - Rate Overlay → Analysis Panels: updates panels
apps/site/src/rate-overlay/controller.ts - Analysis Panels → Rate Overlay: reads settings
apps/site/src/rate-overlay/panels.ts - Simulation Factory → Belt Simulation: steps simulation
- Simulation Factory → Circuit Simulation: runs circuits
- Blueprint and Rates → Rate Calculation: calculates throughput
packages/engine/src/calc/throughput.ts - Canvas Renderer → Draw Collection: collects draw data
packages/renderer/src/render.ts - Draw Collection → Draw Commands: emits commands
packages/renderer/src/draw/collect.ts - Canvas Renderer → Canvas Painting: paints frame
packages/renderer/src/render.ts - Canvas Painting → Draw Commands: consumes commands
packages/renderer/src/draw/paint.ts - Canvas Painting → Sprite Atlas: loads sprites
packages/renderer/src/draw/paint.ts - Overlay Lab → Rate Overlay: configures overlay
apps/site/src/tools/overlay-lab/index.ts - Player → Seed Viewer: enters seed
README.md - Seed Viewer → Map Worker: requests generation
apps/site/src/tools/seed-viewer/worker.ts - Map Worker → Map Generation: generates map
apps/site/src/tools/seed-viewer/worker.ts - Player → Blueprint Editing: imports blueprint
README.md - Player → Blueprint Editing: exports blueprint
README.md - Player → Canvas Renderer: views game art
- Render Catalog → Canvas Renderer: supplies drawing data