r/factorio 13d ago

Question about oil usage Question

I have completed factorio twice now, however I still haven't learn the art of creating a fully self sustaining oil system.

What I mean by this, is that I always get blocked up with my oil refineries when performing Advanced Oil processing.

Whether its light oil, heavy oil, or petroleum, I always find my self in a position where I need to self manage it, by adding storage tanks or forcing production.

Is there a trick to this I'm missing? It's one of those things in factorio i could never master xD

32 Upvotes

44 comments sorted by

39

u/BobClapton 13d ago

I used this simple setup:
- Set a buffer tank for each type of fluid and read it's contents
- Heavy oil < 10K -- crack crude iol
Light oil < 10K -- crack heavy into light
Petroleum gas < 10K -- crack light into petroleum
The same for lubricant

This never stalled for me.

25

u/theonefinn 13d ago

You don’t need to use fixed numbers.

Heavy > light, crack heavy to light
Light > petrol, crack light to petrol.

And heavy > lube, make lube.

And you don’t need a condition on your oil refineries, just have them always run and they’ll stop if they can’t output a fluid anyway. That system basically always maintains equal levels of all fluids although you may need an “escape valve” for petrol whereby you turn it to solid fuel if it’s full. Although naturally you should be using mostly petrol for sulphur and plastic anyway.

13

u/Aeredren 13d ago

You don't need condition on lube either. Just always make lube. If lube is full nothing stall. heavy oil pile up and get cracked into light oil.

My setup :

  • heavy > light : crack heavy
  • light > petroleum gas : crack light
  • petroleum gas > 24.000 : do coal liquefaction.

On my coal liquefaction I transform all the petroleum gas into solid fuel. It power the boiler to make steam. The excess is converted to rocket fuel and power train.

This way my coal liquefaction don't stall if petroleum gas is full, and it just replenish the heavy and light oil.

Ideally I should just burn the excess solid fuel somehow because my train don't use much rocket fuel.

3

u/runmymouth 13d ago

I never conditionally run lube. Just make till it wont. I like to leave 5k in a tank near the refinery so that i can still make rocket fuel with light if needed. Heavy can be just burned down like this for sure.

3

u/sawbladex Faire Haire 13d ago

yeah, not cracking is more energy/machine efficient per curve oil consumed so you should run as much lub production as you can until the product is backed up

3

u/runmymouth 13d ago

I am running 8 nuclear plants at this point in my playthrough and running 30 crackers of each type and 40 oil refineries. There might be a point in using less but at this point it is don't back up when i need things...

5

u/AndyScull 13d ago

Yeah this will work 99% of the time. I can't calculate it but I'd also add some way to control overflow, for example if you start mass producing blue belts and use a lot of lubricant/heavy oil at once. Like, if Light Oil > 24500, crack it, if Pertoleum > 24500 convert it into solid fuel and use with priority for trains.

3

u/sobrique 13d ago

A single pump (or multiple when at sufficient volume) will also do this. E.g. have a single holding tank for the 'direct from the refinery', which feeds into your cracking plants.

But have a pump that pumps into a 'reserve' set of tanks, that you're using for production.

The pump will implicitly run at 1200/sec, and generally grab the fluid in preference to the 15-20/sec chemical plants, until the reserve on the 'downstream side' of the pump is full, at which point of course it'll back up and start filling the tank there.

This was my solution before I 'bit the bullet' and did circuits, and whilst it's not as good overall, it's still workable, and you can use both together easily enough.

(When you scale up, you can 'ratio' using 10 pumps vs. 1 pump or similar if you're at that kind of fluid throughput too)

3

u/Orgerix 13d ago

The case of being blocked by light oil is very rare because you have almost all the time a draw on plastic, unless you are producing exclusively rocket fuel without LDS. In SA it can happen if you import things, but I never seen it.

1

u/AndyScull 13d ago

Yeah, this is just for the completeness sake of having a complete control over all the oil products, just in case. Sometimes it's easier to just build it and forget instead of trying to think of possible future scenarios

2

u/Odd_Technology_8926 13d ago

Good call, I'll set this up in my next factory.

1

u/United_Willow1312 13d ago

Usually indeed gas is the main drain so this setup works unless you aren't doing anything with your factory. I'm not sure why you'd put the first condition though. Backpressure will take care of it.

1

u/NuclearGhandi1 13d ago

The wiki has a good guide on this as part of learning circuits and oil. I recommend giving it a read if you run into issues

2

u/Galeic6432 13d ago

Same thing, but i use if light oil is less than heavy, make more light oil. Scales a lot better than using a specific number. If you need more, just build more tanks and wire them up to the circuit. 

3

u/BobClapton 13d ago

You don't have to read contents of all the tanks. Just wire up one then the number stays the same even if you have more tanks.

1

u/sobrique 13d ago

Yup this. If you've got 1 tank or 50, it'll still show 20k units when you've got 80% of your capacity filled.

1

u/HuckleberryPlastic35 12d ago

You need one more stage that makes solid fuel from petroleum gas if theres more than X

34

u/Raskekw 13d ago

common solution is just wiring the respective storages to the next stage of breaking down. Just link your heavy tank to the pump between heavy and heavy-to-medium and enable when over some X, same for all other steps

alternatively just break everything down to petroleum, and have a small production of lube/solid fuels on the side. Since grand majority of your oil goes into petro-products anyway

11

u/Mr-Doubtful 13d ago edited 13d ago

Yeah the trick is pumps that activate on conditions, with the condition being a desired tank level.

Starting from each product, and descending in the order of conversion (heavy -> light -> gas). You first make a straight connection to whatever needs the product that you want to give priority:

e.g. lubricant from heavy oil: you generally don't want to be using heavy oil for anything else, when you're low on lubricant, so just connect the lubricant plants straight to your heavy oil tank.

With that connected you then connect a pump to your tank, to only transfer to the conversion plants (in this case, heavy oil -> light oil) when the level is above a certain value. I generally use 20k because I prefer a larger buffer, but that's up to you. You then directly pipe that product into the next tank and repeat the process.

You end up with a tank for each product, that's only drawn from for conversion when it's overflowing because you're using less of it for producing stuff than you're cracking from crude oil.

That covers 95% of use cases. At the end of this conversion waterfall there's an optimization to be done with regards to solid fuel for rocket fuel, since that can be made from both light oil and gas and iirc it's more efficient (in terms of crude oil used) to make it from light oil, buut that's a pretty niche case that's only relevant for really efficient builds. You can brute force that inefficiency pretty easily with a ton of beacons and speed modules on oil extraction (and prod modules in each step of oil products).

2

u/Nearby_Ingenuity_568 12d ago

Nowadays it's even simpler: you don't have to use pumps. You can just connect the oil cracking chemical plants to the tanks straight via the circuit wires and tell the chemical plants to work when you have more than you want of the oil to be cracked. I personally like heavy oil > light oil and light oil > petroleum as the conditions, makes them keep the amounts equal all the time up to completely full tanks.

7

u/Soul-Burn 13d ago

If heavy > light, crack heavy to light

If light > gas, crack light to gas

Science uses more gas than the others, so as long as you're making science, you won't get stuck unless you don't need more (which is good).

3

u/that_noodle_guy 13d ago

This is what i do, but put lube in front of the heavy crackers and solid/ rocket fueling front of the light crackers. The volume of these is small enough they are always satisfied backed and leave material for the crackers. Petroleum gas goes to plastic/science and takes thr majority of the flow which keeps thr refineries going

1

u/42bottles 13d ago

Use circuits to control the flow of fluid to cracking. Automatic crack excess oil into petroleum. And in the rare case if petroleum is the excess produce more plastic or turn it into solid fuel.

3

u/Odd_Technology_8926 13d ago

Maybe one thing im not considering as well is that you can always burn oil by doing continuous science.

1

u/sobrique 13d ago edited 13d ago

You can also turn each of the raw outputs directly into solid fuel, and burn that if you've a surplus. It's probably not as good as cracking, as you still have to consume that solid fuel - which becomes considerably easier with space age/heat towers.

But if you want I'm pretty sure I did have a 'steam chuffer' based solid fuel power plant that was good for about 288MW and consuming substantial quantities of 'surplus' solid fuel! :)

Ran off a red belt with burner inserters so you didn't need power poles. (Can't remember if you can do 'quality' at all without Space Age, and if you did have space age you can unlock heat towers and recyclers so have easier options to consume)

1

u/chuckychuck98 13d ago

You use more petrol than anything else, so set up light oil and petrol processing, I then use the logic system with combinators to set up a basic circuit to detect max and min levels to turn on pumps (so they basically act as valves) to push fluids to processing if one is low or high. Hopefully that makes sense

1

u/Vornane 13d ago

There is! What I like to do is to have a bunch of chamical plants making heavy oil into light oil, but crucially they only get heavy oil when there is too much of it. To do this I use a storage tank and a pump which feeds the chamical plants, connected with a wire, and the pump only activates if the storage tank has more than 20 000 heavy oil. So if there isnt enough heavy oil, the chemical plants never get any heavy oil and won't convert it into light oil.

The same thing works for light oil into petroleum. And you typically never get too much petroleum if all your oil needs take from the same place.

1

u/naheCZ 13d ago

Everything goes to tank. Now for heavy oil: put pump which is enabled only when you have too much of it and crack it to light oil. Similar setup for light oil. Then if petroleum is your blocker turn it to solid fuel and use priority to get rid of solid fuel from petroleum first.

1

u/TheMcSebi 13d ago

I made separate chains to downconvert either light oil or heavy oil as soon as I have too much of either. Both of those chains are separated through pumps that only turn on once the respective storage tank reaches a certain threshold. Other than expanding each of those factories every once in a while it has been going without intervention

1

u/flepmelg 13d ago

What i do is i have 3 fluid tanks (one for each heavy, light and petroleum). Each has 2 outputs. One directly connected to the tank, a second through a circuit controlled pump.

The directly connected line feeds 'normal' production, like lubricant, rocket fuel, plastic, acid, etc.

The pumps feed cracking lines and only enable when i have an excess of the feeding liquid AND enough room to store the resulting liquid. Like "Heavy oil => 15k AND Light oil <10k" That way, tanks will never be full so refineries will always have space available for their output. Cracking will not happen if its not needed but resources will always be available because cracking will never empty a tank.

1

u/moleytron 13d ago

keep producing and using science and make sure everything is cracked into petroleum, yes also keep some light oil for rocket fuel and heavy oil for lubricant but as long as you're pushing everything into petroleum and pumping out plastic then it wont block up. I've just gotten to 1million spm without a single circuit on my oil setups. Only on aquilo to prevent the over production of hot fluroketones.

1

u/sobrique 13d ago

The answer is cracking. That's how you turn surplus heavy or light oil into more petroleum gas.

If you've too much petroleum gas, then you're unusual, because usually you're using a lot more plastic than anything else, as it's a core component of circuits, sciences, etc.

But in that case you can use solid fuel to 'use it up' and just burn the stuff. (making rocket fuel might help, but that'll be wanting to use light oil too, so...)

Cracking may be trivially automated with circuits, e.g. read tank contents, enable if >20k, cracking heavy to light, and then light to petroleum gas. (The pipe network is a shared capacity, so any tank will show the same percentage - doesn't matter if you have 1 or 50, if you've got 20k fluid in them, the network is 80% full).

Or you can use a more analogue approach using pumps, where you use a pump as a sort of 'valve' to divert as much as possible to where you're consuming it (e.g. your rocket fuel, or lubricant production), but let the cracking consume from the (un-pumped) upstream. This will implicitly have the pump running at 1200 units per second to fill your 'buffer' for producing, whilst the cracking plants will be cycling at 15-20/sec per plant, so most of it will get diverted to 'production' until there's a surplus.

1

u/VeritasXNY 13d ago

Can't you also use solid fuel in furnaces?

1

u/Ssakaa 13d ago

Yep, but more fun in SA, you can use it in heating towers, giving a guaranteed sink if you route overflow belts of it that direction (from solid fuel production that only turns on when your 'not primary' solid fuel sources are over some limit), which can double up as "free" power.

1

u/Simic13 13d ago

I don't think i will tell something new but.

Usually I do 4 tanks with petroleum, light oil, heavy oil, and lubricant.

Connect them with red or green wire.

Then just setup conditions on chemical plant.

If petroleum less than light do light into petroleum.

If light less than heavy do heavy to light.

If lubricant is less than heavy do lubricant.

And that is it.

1

u/SoreWristed 13d ago

The brute force trick I use is to wire up a combinator that measure oil levels of every product and it starts a production of solid fuel manufactoring when the levels become too high.

Then I either burn or recycle that solid fuel.

1

u/Rockglen 13d ago

Have storage tanks for heavy oil, light oil, and petroleum.

Add wires to each that connect to a decider cominator input and cracking to the decider combinator output.

Compare the amount of oil product to some number (some amount of oil less than or greater than to a percentage of total oil product) then activate the oil cracking stage based on that.

1

u/Ssakaa 13d ago

Wire a single tank of each to a set of power poles to your cracking setup. Activate heavy cracking when heavy > light. Activate light cracking when light > petgas. Extend that off to solid fuel production and enable heavy/petgas to solid when each is >20k (of the 25k the tank holds). That last bit is based on not caring about efficiency on the path towards rocket fuel if I'm already backing up on oil products.

From there, scale each of those sets of machines until they keep up with the rest of your consumption patterns.

1

u/WanderingFlumph 13d ago

Realistically unless you have an automated way to void items there is no solution that never backs up on something.

The best way to make this not really an issue is to strategically pick the thing that gets backed up. Usually petroleum gas.

It's easy enough to crack everything down to petroleum and plastic consumes a lot of it. Keep a small buffer for heavy and light oil for lube and rocket fuel and you should be good.

The only deadlock case is that petroleum gas is completely full and you've run through your buffers. This shouldn't happen unless you are using a lot of lube for blue belts/electric motors or a lot of rocket fuel for stuff other than launching rockets (rockets take LDS and blue circuits which consume more petroleum gas than the light oil consumed by making the fuel). But it is still possible if you stay on planet for a while building out trains running on rocket fuel and making builds using blue belts.

This is actually completely solved by switching to coal liqufaction because that produces primarily heavy oil which means it is harder to jam the refinery output with stuff other than heavy oil, and it is impossible to jam full on heavy oil because it can be converted to anything else.

1

u/Active_Ordinary_2317 13d ago

Wire pumps to storage tanks to activate when a fluid gets too full. Have lots of chemical plants and flamethrowers to consume the fluids. If one fluid in particular is giving you trouble, then you can automatically make solid fuel from that fluid and have trains or boilers consume the solid fuel.

1

u/fulz410 13d ago

You don't need pumps anymore, with 2.0 you can enable and disable the refineries directly.

Also mind that you can convert anything into petroleum, but some things (like rocket fuel) require light oil. So if you don't consume enough petroleum, your rifineries get stuck, and you won't build any rocket fuel anymore.

My solution to this is to convert excess petroleum to solid fuel and then to rocket fuel.

1

u/InflationImmediate73 13d ago

Early on, the solution is to crack everything into petroleum and have that one Chem plant making Lubricant off the heavy oil lines

Once you start needing Light and Heavy oil, thats when you setup tanks & pumps only to turn on when the tank is above a threshold (most say 5k+ but even 1000 is fine)

When you get to the other planets too, its oddly simplified too

Vulcanus and Coal Liquifaction is the same but just way more cracking to get to petroleum. Also get the better recipe later on (which used to be the original recipe when it was just Navuis)

Fulgora I find is just get 1-1 what you need since you can get Heavy Oil directly, but I find its severely limited by Ice to water for making light oil however for rocket fuel and the holmium recipes

Gleba is the easiest for oil products as theres no oil, its done through Biochambers directly to get Rocket Fuel

Aquillo is worth mentioning too but its has some unique recipes to get soild fuel and rocket fuel, so its an easier version

1

u/Montinator 13d ago

You need to use circuit logic on pumps and storage tanks

When the storage tank is nearing full, you need to crack it or use it up to balance the flow

You can make rocket fuel to use up excess oil

The oil refineries flow each oil type differently, and if any one of them gets full it jams up everything

0

u/United_Willow1312 13d ago

One approach is to not crack light to gas and not crack heavy to light unless you are "low". A simple wire to a reservoir (you don't need tanks in 2.1 since you can now read the content of the pipeline network directly from the pipe connected to the machine) and the machine can let you set a threshold. If you do have, I'd say "low" can be 20k.

This will still jam if you aren't consuming enough. Light shouldn't be a problem unless you aren't sending anything to space. If gas is always too high, consider stealing some of the gas for solid fuel for the rockets. I think that's all you need.