Page 1 of 1

Revesible pump

Posted: Thu Sep 24, 2026 6:00 pm
by i-make-robots
Hey, gang!

You might know me from such creations as image2blueprint.

I'm trying to make a reversible pump to solve a problem with stations that load many fluids onto a single vehicle. The pain point until now has been cleaning out the last pump before the next train arrives. A set of reversible pumps would switch direction when T=0 (no train in station), forcing the fluid back into the appropriate storage, like so:
09-24-2026, 10-26-51.png
09-24-2026, 10-26-51.png (170.27 KiB) Viewed 112 times
Now that machines can accept signals from two different wires, I'd like one wire to be the on/off and one to be direction. It seems I can't easily emulate this part
09-24-2026, 10-29-44.png
09-24-2026, 10-29-44.png (11.57 KiB) Viewed 112 times
In a perfect world it would be like this:
09-24-2026, 10-49-15.png
09-24-2026, 10-49-15.png (19.22 KiB) Viewed 112 times
Now on to the issues I'm facing.

The tidy GUI we're used to doesn't appear to be accessible in the API. A custom GUI is clunky and inelegant - the user has to choose a toggle for signal or constant and the fill in the value.

The pump itself is a very dirty set of hacks that don't quite work. The visuals should stay the same while the flow direction arrow changes. The pump code itself doesn't allow for negative flow so I tried a hidden second pump under the visuals of the first. Kinda works until the user flips the pump direction and now I have flow direction arrows. It also seems I can't just flip the hidden pump, I have to destroy and recreate it. That's probably bad for UPS and it's tricky to do without causing the tiniest leak of disappearing fluid.

I also tried adding a value to remember the original direction the user placed the pump and then flip would be relative to original. Again, problems when the user flips the original while the hidden pump is flipped.

In either case when the hidden pump works the original doesn't extend and connect to the train. DOH!

In conclusion, I beseech the mod gods for mercy. I haven't shared the repo because i'm too ashamed of the mess.

If you think you can make it work or help in some way, please lmk.