Dragging power poles should connect power networks

Post your ideas and suggestions how to improve the game.

Moderator: ickputzdirwech

Post Reply
thuejk
Fast Inserter
Fast Inserter
Posts: 113
Joined: Fri Feb 13, 2015 8:41 pm
Contact:

Dragging power poles should connect power networks

Post by thuejk »

When dragging autoplacing power poles to power stuff, you basically always want to connect to an existing power network.

Example of the current logic being inconvenient: https://www.thuejk.dk/factorio_drag_power.flv

However, the current power pole dragging will often detect that all entities (e.g. miners) are covered by at least one power pole, and then not place a last power pole to connect the new unpowered network to the old powered network.

My suggestion for an improvement: drag-place a power pole in the last position which will connect two power networks, in addition to the current power miners logic.

Cribbit
Fast Inserter
Fast Inserter
Posts: 199
Joined: Mon Oct 09, 2017 9:35 pm
Contact:

Re: Dragging power poles should connect power networks

Post by Cribbit »

https://youtu.be/oq2wEZS120c for easier viewing

The issue isn't that it thinks the miners already have power.

Dragging is pretty simple logic - as soon as you're at edge of range of all power poles, drop another pole.

Unfortunately this edge case is impossible to fix without breaking it entirely. You're always going to have to place the last pole in a situation like this manually.

daniel34
Global Moderator
Global Moderator
Posts: 2761
Joined: Thu Dec 25, 2014 7:30 am
Contact:

Re: Dragging power poles should connect power networks

Post by daniel34 »

Cribbit wrote:The issue isn't that it thinks the miners already have power.

Dragging is pretty simple logic - as soon as you're at edge of range of all power poles, drop another pole.
Dragging was changed a while ago to make sure all entities in the area are connected, e.g. if you run along a row of inserters and drop medium power poles then they will be all covered without a gap.

Code: Select all

Version: 0.15.0 (24. 04. 2017)
  Minor Features:
    - Build-by-moving for electric poles now accounts for covering all unpowered entities on the way.
This has been suggested a few times already, even has its own Frequently Suggested topic: viewtopic.php?f=80&t=35838
quick links: log file | graphical issues | wiki

thuejk
Fast Inserter
Fast Inserter
Posts: 113
Joined: Fri Feb 13, 2015 8:41 pm
Contact:

Re: Dragging power poles should connect power networks

Post by thuejk »

Cribbit wrote: Unfortunately this edge case is impossible to fix without breaking it entirely. You're always going to have to place the last pole in a situation like this manually.
No, it is not impossible to fix. I outlined in my post how to fix it.

thuejk
Fast Inserter
Fast Inserter
Posts: 113
Joined: Fri Feb 13, 2015 8:41 pm
Contact:

Re: Dragging power poles should connect power networks

Post by thuejk »

daniel34 wrote:
Cribbit wrote: This has been suggested a few times already, even has its own Frequently Suggested topic: viewtopic.php?f=80&t=35838
I like my suggested implementation better.

Cribbit
Fast Inserter
Fast Inserter
Posts: 199
Joined: Mon Oct 09, 2017 9:35 pm
Contact:

Re: Dragging power poles should connect power networks

Post by Cribbit »

thuejk wrote:
Cribbit wrote: Unfortunately this edge case is impossible to fix without breaking it entirely. You're always going to have to place the last pole in a situation like this manually.
No, it is not impossible to fix. I outlined in my post how to fix it.
You wrote sentences in english. There is a wide gap between that and actual code logic to have it happen. That is what "edge case" implies here. Your suggested solution does not account for how you actually detect the situation you want to fix.

thuejk
Fast Inserter
Fast Inserter
Posts: 113
Joined: Fri Feb 13, 2015 8:41 pm
Contact:

Re: Dragging power poles should connect power networks

Post by thuejk »

I am actually a programmer. What I wrote was something I had already made sure could be implemented, basically using the existing logic.

Cribbit
Fast Inserter
Fast Inserter
Posts: 199
Joined: Mon Oct 09, 2017 9:35 pm
Contact:

Re: Dragging power poles should connect power networks

Post by Cribbit »

thuejk wrote:I am actually a programmer. What I wrote was something I had already made sure could be implemented, basically using the existing logic.
Can you articulate that logic?

I don't want dragged poles dropping in random locations because it happens to be near an existing network and would cover an entity.

I don't want it to place a pole when I end the drag.

ratchetfreak
Filter Inserter
Filter Inserter
Posts: 950
Joined: Sat May 23, 2015 12:10 pm
Contact:

Re: Dragging power poles should connect power networks

Post by ratchetfreak »

It sounds like the logic should be something like
  1. if cursor no longer in range of any network, place pole in last valid location.
  2. if cursor is in range of network with different ID place pole connecting the networks
  3. otherwise don't place pole
condition 2 can be refined to avoid placing poles with maximum stretch to the next network and instead try to add some tiles of slack. for example by using the leaving the network as trigger and placing the pole in the spot where the cable lengths are minimized.

Cribbit
Fast Inserter
Fast Inserter
Posts: 199
Joined: Mon Oct 09, 2017 9:35 pm
Contact:

Re: Dragging power poles should connect power networks

Post by Cribbit »

What if I don't want to connect those networks? What if I plan on turning another direction and just slightly overshot? There's going to be a wide variety of valid spots since it's no longer the edge of a circle but an area of its own - what if I I want to place it somewhere specific?

It seems much easier to leave this as is and let users manually place the pole. I understand the frustration of this specific case but there are many other cases besides this.

thuejk
Fast Inserter
Fast Inserter
Posts: 113
Joined: Fri Feb 13, 2015 8:41 pm
Contact:

Re: Dragging power poles should connect power networks

Post by thuejk »

ratchetfreak has it right.
What if I don't want to connect those networks?
I have never, ever wanted that. While I have been annoyed at power pole dragging not connecting networks *every* *single* *time*.

If you have some insanely specific power setup that requires separate power networks, then simply don't use power pole dragging.

Post Reply

Return to “Ideas and Suggestions”