Actually raise ToolAct

This commit is contained in:
zumorica
2020-04-29 14:45:38 +02:00
parent 89e7ad4144
commit dd72f9d1a9

View File

@@ -694,6 +694,11 @@ namespace Content.Server.GameObjects.EntitySystems
// We handle specific tools AttackBy here.
if (weapon.TryGetComponent<ToolComponent>(out var tool))
{
if (attacked.GetAllComponents<IToolAct>().Any((act => act.ToolAct(new ToolActEventArgs()
{User = user, ClickLocation = clickLocation, AttackWith = weapon}))))
return;
switch (tool.Behavior)
{
case Tool.Wrench: