Add liquids to pipe connectable

JamesOFarrell
Filter Inserter
Filter Inserter
Posts: 402
Joined: Fri May 23, 2014 8:54 am
Contact:

Add liquids to pipe connectable

Post by JamesOFarrell »

I am looking for an interface for inserting liquids into a pipeconnectable. Maybe insertliquid({type,amount,temperature})? Thoughts?
Rahjital
Filter Inserter
Filter Inserter
Posts: 435
Joined: Thu May 29, 2014 10:44 am
Contact:

Re: Add liquids to pipe connectable

Post by Rahjital »

What PipeConnectable should have is a read/write liquid property, where the type, amount and temperature fields would be editable. This alone would be enough to make pretty much anything possible, from train liquid carriages to water-cooled nuclear powerplants and such.

It's probably too late to see it in 10.0, but I really hope it can be included in one of the later bugfix versions. I'm not sure what the codebase of the game looks like, but hopefully it wouldn't require too much changing to implement this.
nullvoid
Burner Inserter
Burner Inserter
Posts: 16
Joined: Sat May 03, 2014 9:53 pm
Contact:

Re: Add liquids to pipe connectable

Post by nullvoid »

shouldn't this go on the fluid box(es) rather than the pipeconnectable itself? (Not that we have access to the fluid box either.)
This would allow proper querying of liquids in things like assemblers as well as plain old pipes.
JamesOFarrell
Filter Inserter
Filter Inserter
Posts: 402
Joined: Fri May 23, 2014 8:54 am
Contact:

Re: Add liquids to pipe connectable

Post by JamesOFarrell »

That makes more sense. Maybe adding a function getfluidbox(number) to the entity abstract class that errors when there is no fluidbox supported, just like the inventory. Then the fluidbox object can have functions for dealing with liquid.
Rahjital
Filter Inserter
Filter Inserter
Posts: 435
Joined: Thu May 29, 2014 10:44 am
Contact:

Re: Add liquids to pipe connectable

Post by Rahjital »

There are quite a few changes required in the entire liquid and item handling, including things like allowing burners to use liquids and so on. That's likely to take some time, though. The proposed setLiquid method or a read/write liquid property for PipeConnectable would be much quicker to implement and would give modders the ability to work with liquids without having to wait ages for a version of the game where the liquid handling is more refined.
Post Reply

Return to “Implemented mod requests”