Advanced Flow Management

If you liked this item, please rate it up on Steam Workshop page.

Author: Glampi

Last revision: 24 Nov, 2024 at 17:52 UTC

File size: 1.53 MB

On Steam Workshop

Description:
Latest version: v2.0.7.1
Translations: en, uk, ru, de, zh, es

Are you tired of using lots of bridges to make that damn liquid flow the right way? Do you want a more convenient way to manage where it flows and in what order? Then this mod is for you!

Advanced Flow Management(or AFM for short) gives you the ability to change the flow direction & priority in just one click. It also gives you a better understanding of the network’s state by visualising the flow directions in the overlay. It works for both liquid and gas conduits.


Features

• flow directions visualisation in liquid & gas overlays
• ability to switch flow directions
• ability to change flow priorities on junctions
• ability to change flow priorities of buildings’ endpoints
• ability to copy a junction’s flow settings to other junctions

Now in more detail:

All the changes to a network’s flow are done via interactions with junctions. By changing a flow direction of a certain junction’s direction you also change the flow direction of the whole pipe that is connected to the junction and leads to some ending: another junction, a building intake, a building’s output pipe or a dead end.

Some directions are called "Fixed Flow Directions"(those appear darker in the Flow Configuration screen). They can’t be changed for trivial reasons.

Illegal junctions(the ones that are marked red) are "unstable". This means that the game will try to rebuild the network in such a way that would make that junction legal by changing its flow directions. Each network is rebuilt every time a new conduit is built/an already existing one is destroyed.

By changing a junction’s flow priorities you change the order in which conduit contents enter/escape the junction. The direction with highest flow priority will be the first from which contents enter the junction/in which contents escape the junction; if multiple directions have same flow priority then the flow will be equally split between them.

You can also change flow priority of building’s endpoints if they are located right above a junction. For example, if a pump outputs water into a junction and you set the pump’s output flow priority to being the same as other junction’s inputs then the flow will be equally split between all the inputs and the pump’s output.

To make flow priorities of buildings’ endpoints work the junction requires a "Buffer" – you can see its contents(labeled "Buffer Contents") below the conduit’s contents. You can safely ignore it as it doesn’t influence the behavior of the conduit in any noticeable way.

You will only be able to copy a junction’s flow settings to other junctions if other junctions have the same connections as the junction you are copying the settings from. Copying the settings will copy both flow directions AND flow priorities.


Tips

Here are some tips that can help you use the mod correctly:

Do not build loops(= an arrangement of multiple junctions that lets the contents flow in circles). Just because this mod lets you do it doesn’t mean you should. If you do build them, then the flow of nearby conduits might behave strange and unintended.

Switch flow directions while the game is paused. This will assure that the game will not try to switch any flow directions that you are currently changing to the way they were before(in case you create any illegal junctions in the process).

Switch flow directions only in fully built networks. If you switch a flow direction of a junction that is part of an unfinished network, then that flow direction may get switched back while that network is being built.


Mod Compatibility

This mod influences conduits’ behavior on a pretty low level so it might conflict with other mods that do the same. However, among all the mods I tested(which were a lot of) practically none showed any significant compatibility issues.

In the following by partially compatible I mean that the two mods cause no crashes when being used together but their functionality might be limited/incorrect in some cases.

AFM is fully compatible with High Pressure Applications:
you can configure both flow directions and flow priorities of the modded conduits.

AFM is fully compatible with Pipe Flow Overlay.

AFM is fully compatible with all mods that add new buildings with custom endpoints/new bridges/new valves etc.:
you are fully able to configure the flow priority of any modded building’s endpoints; sometimes some minor visual issues with the endpoints’ icons occur where the icons are not changing their shape properly(from square to round and vice versa).


Special Thanks

Big thanks to Peter Han for his PLib!

Special thanks to the ONI discord community[discord.gg] for answering lots of my questions and helping create this mod!


Source Code, Feedback etc.

You can find the source code on my GitHub[github.com].

If you encounter any issues/bugs, please start an issue[github.com] with the error message(if present), the Player.log file and a description of how to reproduce the bug.

If you would like to provide a translation to this mod, feel free to send me the translation .po file via an issue or a pull request (on GitHub).

Do you like my mods and want to thank me? I would not mind if you would buy me a coffee[buymeacoffee.com] ;D