Unstable v0.1300.0.2
This commit is contained in:
@@ -251,8 +251,8 @@ namespace Barotrauma.Items.Components
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void SendSignal(int stepsTaken, string signal, Item source, Character sender, float power, float signalStrength = 1.0f)
|
||||
|
||||
public void SendSignal(Signal signal)
|
||||
{
|
||||
for (int i = 0; i < MaxWires; i++)
|
||||
{
|
||||
@@ -260,16 +260,18 @@ namespace Barotrauma.Items.Components
|
||||
|
||||
Connection recipient = wires[i].OtherConnection(this);
|
||||
if (recipient == null) { continue; }
|
||||
if (recipient.item == this.item || recipient.item == source) { continue; }
|
||||
if (recipient.item == this.item || signal.source?.LastSentSignalRecipients.LastOrDefault() == recipient.item) { continue; }
|
||||
|
||||
source?.LastSentSignalRecipients.Add(recipient.item);
|
||||
signal.source?.LastSentSignalRecipients.Add(recipient.item);
|
||||
|
||||
Connection connection = recipient;
|
||||
|
||||
foreach (ItemComponent ic in recipient.item.Components)
|
||||
{
|
||||
ic.ReceiveSignal(stepsTaken, signal, recipient, source, sender, power, signalStrength);
|
||||
ic.ReceiveSignal(signal, connection);
|
||||
}
|
||||
|
||||
if (signal != "0")
|
||||
if (signal.value != "0")
|
||||
{
|
||||
foreach (StatusEffect effect in recipient.Effects)
|
||||
{
|
||||
@@ -278,7 +280,7 @@ namespace Barotrauma.Items.Components
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void SendPowerProbeSignal(Item source, float power)
|
||||
{
|
||||
for (int i = 0; i < MaxWires; i++)
|
||||
|
||||
Reference in New Issue
Block a user