Fixed wires disconnecting when dragging them outside the sub, larger range of wifi channels

This commit is contained in:
Regalis
2016-07-18 20:35:38 +03:00
parent a4ad91da44
commit c4cc19ea4f
2 changed files with 2 additions and 2 deletions

View File

@@ -27,7 +27,7 @@ namespace Barotrauma.Items.Components
get { return channel; }
set
{
channel = MathHelper.Clamp(value, 0, 100);
channel = MathHelper.Clamp(value, 0, 10000);
}
}

View File

@@ -209,7 +209,7 @@ namespace Barotrauma.Items.Components
if (connections[0] != null && connections[0].Item.Submarine != null) sub = connections[0].Item.Submarine;
if (connections[1] != null && connections[1].Item.Submarine != null) sub = connections[1].Item.Submarine;
if (item.Submarine != sub)
if (item.Submarine != null && item.Submarine != sub)
{
ClearConnections();
Nodes.Clear();