Thinking about improving my Routing / Logistics mod
Posted: Wed Apr 24, 2019 11:13 pm
Some time ago, I put together a mod that can be used to route items across a complex network of belts & inserters (general logistics for bot haters). It works off of circuit-network signals (inputs are signals repeesenting network topology, supplied items, requested items, and processing triggers, and outputs are signals representing how much ow which type of item needs to be transferred across each link). For some reason, this makes the mod a bit difficult and cumbersome to use. (https://mods.factorio.com/mod/EketechRouting)
So, with a fair amount of additional considerations, I have worked out a way to build a belt-based general logistics system which should be a lot more accessible.
The idea now is to provide buildable components for modular logistics hubs, consisting of:
floor - used to define a logistic hub, both visually and to inform the mod that all components built on top of the floor belong to the hub.
provider/receiver - a chest-type entity used to insert items into a hub or to receive items from other hubs
storage - extra storage space to divert items without a destination to (and to draw items from when new requests are made)
requester - destination to route items to which is configured just like a requester chest (doesn't have to be attached directly to a hub)
Hub Controller - center of the hub, used to trigger internal item transfers (hub storage or input -> hub output). Controllers might also have varying properties that the mod uses to determine maximum size, logistic capacity, and efficiency.
Item transfer would be a simple [but costly and restricted] transfer of objects from Storage or Provider entities to Link or Requester entities based on current routing data (which inserters can then grab from and transfer items to move items toward their destinations). Item transfer would be triggered by inserting or pumping a consumable resource into the hub controller.
The new mod would provide a few selectable complete routing modes which offer various benefits and drawbacks (the behavior which my earlier routing mod defers to combinator logic) Modes in mind would be:
move X items per second (resilient against theft and flow-based)
move X amount of items with minimal over-supply or bufferring (vulnerable to theft and quantity-based)
move X items and don't keep track of in-flight items (resilient against theft and quantity-based, but can buffer a lot)
The plan also calls for having the routing system automatically configure itself - rather than manually defining links, it would derive network topology by scanning belts, inserters, and stops with scheduled trains to determine what each logistics hub is linked to.
So, with a fair amount of additional considerations, I have worked out a way to build a belt-based general logistics system which should be a lot more accessible.
The idea now is to provide buildable components for modular logistics hubs, consisting of:
floor - used to define a logistic hub, both visually and to inform the mod that all components built on top of the floor belong to the hub.
provider/receiver - a chest-type entity used to insert items into a hub or to receive items from other hubs
storage - extra storage space to divert items without a destination to (and to draw items from when new requests are made)
requester - destination to route items to which is configured just like a requester chest (doesn't have to be attached directly to a hub)
Hub Controller - center of the hub, used to trigger internal item transfers (hub storage or input -> hub output). Controllers might also have varying properties that the mod uses to determine maximum size, logistic capacity, and efficiency.
Item transfer would be a simple [but costly and restricted] transfer of objects from Storage or Provider entities to Link or Requester entities based on current routing data (which inserters can then grab from and transfer items to move items toward their destinations). Item transfer would be triggered by inserting or pumping a consumable resource into the hub controller.
The new mod would provide a few selectable complete routing modes which offer various benefits and drawbacks (the behavior which my earlier routing mod defers to combinator logic) Modes in mind would be:
move X items per second (resilient against theft and flow-based)
move X amount of items with minimal over-supply or bufferring (vulnerable to theft and quantity-based)
move X items and don't keep track of in-flight items (resilient against theft and quantity-based, but can buffer a lot)
The plan also calls for having the routing system automatically configure itself - rather than manually defining links, it would derive network topology by scanning belts, inserters, and stops with scheduled trains to determine what each logistics hub is linked to.