Jump to content

CircuitManager assigns Wire Bridges to circuits they cross over


rezecib
  • Branch: Live Branch Version: Steam Fixed

When a circuit overloads, the bridges are targeted first. However, CircuitManager assigns wire bridges to the circuit they cross over, rather than the circuit they are linked to. This means that wire bridges don't overload if there's no circuit under them, and overload at the wrong time.

I've attached a save demonstrating this. It consists of a heavi-watt circuit and a normal circuit, each with more than 1 kW power drain. The wire bridge on the left should be part of the heavi-watt circuit, but overloads when the normal circuit is powered. If it's removed, the two wire bridges on the right do not overload, but a wire does instead.

20170711130926_1.jpg

I believe this is due to the following part of CircuitManager.Rebuild:

		HashSet<UtilityNetworkLink>.Enumerator enumerator3 = this.bridges.GetEnumerator();
		while (enumerator3.MoveNext())
		{
			UtilityNetworkLink current3 = enumerator3.Current;
			int cell = Grid.PosToCell(current3.transform.position);
			ushort circuitID3 = this.GetCircuitID(cell);
			if (circuitID3 != 65535)
			{
				this.circuitInfo[(int)circuitID3].bridges.Add(current3);
			}
		}

It uses the center cell of the wire bridge to determine which circuit it's attached to. Instead it could use UtilityNetworkLink.GetCells() to get the cells the bridge is actually linked to, and use one/both of those to determine the circuit.

WireBridgeBug.sav


Steps to Reproduce
Build normal circuit, with too much power drain Put wire bridge over the normal circuit (doesn't need to be connected to anything) Observe wire bridge overloading even though it doesn't carry any power



User Feedback


A developer has marked this issue as fixed. This means that the issue has been addressed in the current development build and will likely be in the next update.

The current version is 232512, the wire bridges continue to randomly heat up, the connection of 1 carbon generator through the bridge to 1 device 240W causes after some time bridging the bridge and its damage, it happens after some time spent in the game and can overheat the wires to nothing not connected.

Share this comment


Link to comment
Share on other sites

Hi, especially today I was paying attention to the overload of wires and after a day spent playing (6 hours) I have dozens of overloaded errors in illogical places, unconnected wires, unplugged live plugs, bulb wires (single bulb) . It looks as though the game counts the installation as a whole and then overloads the wires in random places.

Share this comment


Link to comment
Share on other sites



Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
  • Create New...