public void DirectionInput(int tick, GameObject SourceInstance, IElectricityIO ComingFrom, IElectricityIO PassOn = null) { //Logger.Log(SourceInstance.ToString() + " < SourceInstance " + ComingFrom.ToString() + " < ComingFrom " + this.name + " < this " ); if (connections.Count > 2) { ElectricityFunctions.DirectionInput(tick, SourceInstance, ComingFrom, this); FirstPresentInspector = FirstPresent; } else { int SourceInstanceID = SourceInstance.GetInstanceID(); if (!(Upstream.ContainsKey(SourceInstanceID))) { Upstream [SourceInstanceID] = new HashSet <IElectricityIO> (); } if (!(Downstream.ContainsKey(SourceInstanceID))) { Downstream [SourceInstanceID] = new HashSet <IElectricityIO> (); } if (FirstPresent == 0) { //Logger.Log ("to It's been claimed", Category.Electrical); FirstPresent = SourceInstanceID; //Thiswire.FirstPresentInspector = SourceInstanceID; } if (ComingFrom != null) { Upstream [SourceInstanceID].Add(ComingFrom); } CameFromMemory = PassOn; SourceInstance.GetComponent <IProvidePower> ().DirectionWorkOnNextList.Add(this); } }
public void DirectionInput(int tick, GameObject SourceInstance, IElectricityIO ComingFrom, IElectricityIO PassOn = null) { ElectricityFunctions.DirectionInput(tick, SourceInstance, ComingFrom, this); FirstPresentInspector = FirstPresent; }
public void DirectionInput(int tick, GameObject SourceInstance, IElectricityIO ComingFrom, IElectricityIO PassOn = null) { //Logger.Log ("rfsdjhgkbedhgjasdgjyhsajkuhert"); ElectricityFunctions.DirectionInput(tick, SourceInstance, ComingFrom, this); FirstPresentInspector = FirstPresent; }