Reduce door hacking time (#8852)
This commit is contained in:
@@ -34,8 +34,8 @@ public sealed class WiresSystem : EntitySystem
|
||||
// This is where all the wire layouts are stored.
|
||||
[ViewVariables] private readonly Dictionary<string, WireLayout> _layouts = new();
|
||||
|
||||
private const float ScrewTime = 2.5f;
|
||||
private const float ToolTime = 1f;
|
||||
private const float ScrewTime = 1f;
|
||||
private float _toolTime = 0f;
|
||||
|
||||
private static DummyWireAction _dummyWire = new DummyWireAction();
|
||||
|
||||
@@ -649,7 +649,9 @@ public sealed class WiresSystem : EntitySystem
|
||||
break;
|
||||
}
|
||||
|
||||
var args = new DoAfterEventArgs(user, ToolTime, default, used)
|
||||
if (_toolTime > 0f)
|
||||
{
|
||||
var args = new DoAfterEventArgs(user, _toolTime, default, used)
|
||||
{
|
||||
NeedHand = true,
|
||||
BreakOnStun = true,
|
||||
@@ -668,10 +670,16 @@ public sealed class WiresSystem : EntitySystem
|
||||
Id = id
|
||||
}
|
||||
};
|
||||
|
||||
_doAfter.DoAfter(args);
|
||||
|
||||
wires.WiresQueue.Add(id);
|
||||
}
|
||||
else
|
||||
{
|
||||
UpdateWires(used, user, toolEntity, id, action, wires);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user