Miners that are direct-mining into trains don't go inactive when there is no train present

Bugs that are actually features.
Post Reply
knightelite
Fast Inserter
Fast Inserter
Posts: 132
Joined: Fri Oct 05, 2018 3:49 pm
Contact:

Miners that are direct-mining into trains don't go inactive when there is no train present

Post by knightelite »

Image

As can be seen in the above screenshot, inserters ready to load into a train go inactive when there isn't a train present. Depleted miners go into inactive state. However the mining drills (that still have ore) that are ready to direct-load into the train do not go inactive when there is no train present. Seems like this is a potential UPS drain that could get the same optimization as the inserters for this case.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13171
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by Rseding91 »

Thanks for the report however I don't consider this worth changing. Mining drills are virtually never setup to mine directly into trains and as such don't have logic to sleep in rails. Adding that logic would slow down every mining drill that exists just for the off chance someone sets one up to mine into rails.
If you want to get ahold of me I'm almost always on Discord.


Pi-C
Smart Inserter
Smart Inserter
Posts: 1639
Joined: Sun Oct 14, 2018 8:13 am
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by Pi-C »

knightelite wrote: ↑
Wed Nov 14, 2018 9:33 pm
As can be seen in the above screenshot, inserters ready to load into a train go inactive when there isn't a train present. Depleted miners go into inactive state. However the mining drills (that still have ore) that are ready to direct-load into the train do not go inactive when there is no train present. Seems like this is a potential UPS drain that could get the same optimization as the inserters for this case.
You have train stations and power lines running from the station to the miners. Couldn't you just insert a power switch that turns on power when a train is at the station?
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!

knightelite
Fast Inserter
Fast Inserter
Posts: 132
Joined: Fri Oct 05, 2018 3:49 pm
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by knightelite »

Pi-C wrote: ↑
Sun Jan 06, 2019 11:04 am
You have train stations and power lines running from the station to the miners. Couldn't you just insert a power switch that turns on power when a train is at the station?
From what I've read elsewhere unpowered buildings consume more update time than active but idle ones.

Pi-C
Smart Inserter
Smart Inserter
Posts: 1639
Joined: Sun Oct 14, 2018 8:13 am
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by Pi-C »

knightelite wrote: ↑
Sun Jan 06, 2019 1:23 pm
From what I've read elsewhere unpowered buildings consume more update time than active but idle ones.
I guess you're referring to this post?
Rseding91 wrote: ↑
Thu Jan 19, 2017 6:55 pm
"Powering down" things is one of the worse ways you can stop a factory. Simply not giving it any resources to consume/use is the ideal way.

The problem is: "powering down" an entity means the normal update logic on the entity can't run because there's no power to do things like "move the inserter arm". The entity has no update notification when power is restored so it can't disable itself.

Adding such a notification would be a gigantic waste of CPU time because 99% + of the time the entity has power or will have power next tick.
That makes me wonder what legitimate (in the sense of having no negative effects like UPS penalties) use there is for the power switch -- mind you, I don't want to instigate an "axe the power switch" debate! :-)

Previously, I used power switches mainly in far-away mining outposts that were not connected to the main grid, but powered by a local solar farm. These outposts were protected by alternating gun and laser turrets, and when accumulator charge dropped below a certain threshold because of a biter attack, all miners were switched off so all power would go to the laser turrets and roboports (for repair work). That seemed to make sense, but after reading Rseding91's post I wonder whether it really is the proper thing to do …
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!

quyxkh
Smart Inserter
Smart Inserter
Posts: 1027
Joined: Sun May 08, 2016 9:01 am
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by quyxkh »

Turns out the best way is to shut off the supplies, wait for everything to go inactive, then shut off the power. I don't remember the figures but cutting the power saves like half the overhead in beaconed layouts.

For miners you can't do that, and anyway direct-insertion into buffer chests (or even better, smelters then chests, that works _awesome_ if you're willing to build enough outposts) works well with beacons, which also help a lot.

Serenity
Smart Inserter
Smart Inserter
Posts: 1000
Joined: Fri Apr 15, 2016 6:16 am
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by Serenity »

Pi-C wrote: ↑
Sun Jan 06, 2019 3:56 pm
That makes me wonder what legitimate (in the sense of having no negative effects like UPS penalties) use there is for the power switch
Start by not thinking of everything in terms of UPS. With more entities being connectable to the circuit network now there is a bit less need for a power switch (for example for steam engines you can just switch off the water pump), but there is still situations where you may want to just save power

Pi-C
Smart Inserter
Smart Inserter
Posts: 1639
Joined: Sun Oct 14, 2018 8:13 am
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by Pi-C »

Sorry for the delay!
Serenity wrote: ↑
Sun Jan 06, 2019 8:15 pm
Pi-C wrote: ↑
Sun Jan 06, 2019 3:56 pm
That makes me wonder what legitimate (in the sense of having no negative effects like UPS penalties) use there is for the power switch
Start by not thinking of everything in terms of UPS. With more entities being connectable to the circuit network now there is a bit less need for a power switch (for example for steam engines you can just switch off the water pump), but there is still situations where you may want to just save power
Well, UPS unfortunately matters. My first games (unmodded) went alright UPS wise. It was a fluid game -- kind of. :-) Then I started playing with mods: On the first game, both FPS and UPS started to drop considerably whenever I came close to my wind park (that could be an effect of wind generators using fluid consumption internally); on the last game I started, UPS dropped in to the 20s/30s whenever I zoomed out, even though I hadn't built much yet apart from a few miners and stone furnaces.

Admittedly, my computer is what I've seen people in the forum call a "potato": six or seven years old, 8GB of RAM, graphics card with 512MB, i5-2500 CPU @ 3.30GHz. I'm not much of a gamer, and the games I have played last year were rather dated (5 years or older), so my old "potato" was/is still enough for my needs. Nevertheless, playing Factorio on it has been a PITA lately because of low UPS, so if I can avoid things that are known to have a negative effect on UPS it could improve my game experience tremendously. :-)
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!

User avatar
BlueTemplar
Smart Inserter
Smart Inserter
Posts: 2420
Joined: Fri Jun 08, 2018 2:16 pm
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by BlueTemplar »

"Lower UPS when coming closer" sounds like a radically different (graphics, not game-logic related) issue than the one in the OP ?
(It hopefully got/will get better for you with 0.17 ?)
BobDiggity (mod-scenario-pack)

billbo99
Fast Inserter
Fast Inserter
Posts: 131
Joined: Fri Nov 02, 2018 9:19 am
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by billbo99 »

Would using some "Accumulators" on the miner side of the power switch allow the miners power down gracefully into an inactive state ?

knightelite
Fast Inserter
Fast Inserter
Posts: 132
Joined: Fri Oct 05, 2018 3:49 pm
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by knightelite »

billbo99 wrote: ↑
Wed Mar 06, 2019 1:50 pm
Would using some "Accumulators" on the miner side of the power switch allow the miners power down gracefully into an inactive state ?
Seems unlikely, given that as shown in the screenshot the miners don't go into inactive state when there is no train present, and there isn't any way to force them to do so. Having an accumulator would just give them power for a bit longer, shouldn't make any difference regarding their final state.

Pi-C
Smart Inserter
Smart Inserter
Posts: 1639
Joined: Sun Oct 14, 2018 8:13 am
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by Pi-C »

BlueTemplar wrote: ↑
Tue Mar 05, 2019 1:25 pm
"Lower UPS when coming closer" sounds like a radically different (graphics, not game-logic related) issue than the one in the OP ?
(It hopefully got/will get better for you with 0.17 ?)
Well, I first noticed such delays when I installed Texugo Wind Generator and built a wind park with 160 or so wind generators. That mod internally uses wind power as a fluid, so it was UPS heavy. However, given my setup I've been quite eager to avoid anything that would impact UPS. The information that using the power switch to turn off a part of the factory was, hence, relevant.

Fortunately, I could get a new graphics card
(Well, most gamers would consider it weak and old. It's a Geforce GTX 1050, which is just perfect because I can use it with my 200W or 250W -- not quite sure -- power supply.)
and a memory update from 8GB to 16GB in February, so currently I can run the game at 60FPS/60UPS without any problems! :-)
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!

User avatar
BlueTemplar
Smart Inserter
Smart Inserter
Posts: 2420
Joined: Fri Jun 08, 2018 2:16 pm
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by BlueTemplar »

Eh, its performance is fine
(come on, that's mid-range, not "weak" ! You might even be able to do VR on it...),
I'd be more worried about not having at least 4GB of VRAM these days,
at least if you want to not have to upgrade again in a few years...
not sure what is available considering your power ?
BobDiggity (mod-scenario-pack)

User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3699
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by DaveMcW »

I tested in Factorio 0.17.38 and it seems to be fixed. :)

knightelite
Fast Inserter
Fast Inserter
Posts: 132
Joined: Fri Oct 05, 2018 3:49 pm
Contact:

Re: Miners that are direct-mining into trains don't go inactive when there is no train present

Post by knightelite »

Yeah, I think the change was stealth merged in 4 or 5 releases ago :).

Post Reply

Return to β€œNot a bug”