Make fluid flow "even" with rotating update order

Post your ideas and suggestions how to improve the game.

Moderator: ickputzdirwech

Post Reply
farcast
Long Handed Inserter
Long Handed Inserter
Posts: 86
Joined: Fri Jul 06, 2018 8:25 am
Contact:

Make fluid flow "even" with rotating update order

Post by farcast »

My current understanding is that fluid flow is uneven because one connection gets a bigger chunk of fluid than the others due to it always being first to update. My suggestion is to rotate which connection gets the bigger chunk on each tick, so if the normal update order for connections is N>E>S>W, the next tick it'll be W>N>E>S, then S>W>N>E and so on. The purpose being to evenly distribute the uneven distribution, making fluid flow (hopefully) close enough to even.

Would this be feasible? Would it even be effective?
Efficient inefficient design.

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Make fluid flow "even" with rotating update order

Post by ssilk »

farcast wrote:
Tue Nov 30, 2021 3:46 am
Would this be feasible? Would it even be effective?
Feasible: yes. Effective: no. Or maybe.

The logic for turning the algorithm would be quite complicated, so that it will slow down the calculations much.

Maybe like this: implement the algorithm four times. One implementation per preferred direction. And then change every tick which one is taken.

I see this meanwhile as a part of the gameplay. It’s quite ugly, but it could be seen like that.

For example how this could be simply played out:

This kind of “all or nothing” happens only, if the pipes are empty. It’s much easier to make just so much fluids of each type, that this flaw doesn’t matter. How? By letting only so much fluid through the refineries, that the tanks don’t run empty; they an distribute fluid at any time, but only for very short time, until the tank runs below the minimal level. Quite simple trick but quite effective.

Or use other tricks to guarantee a kind of equal split.
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

Post Reply

Return to “Ideas and Suggestions”