Bandaid pullcontroller (#7176)

This commit is contained in:
metalgearsloth
2022-03-19 14:18:43 +11:00
committed by GitHub
parent 2e857824bc
commit e630deafe1
3 changed files with 19 additions and 4 deletions

View File

@@ -4,6 +4,7 @@ using System.Diagnostics.CodeAnalysis;
using Content.Shared.Alert;
using Content.Shared.GameTicking;
using Content.Shared.Input;
using Content.Shared.Movement.Components;
using Content.Shared.Physics.Pull;
using Content.Shared.Pulling.Components;
using Content.Shared.Rotatable;
@@ -106,7 +107,7 @@ namespace Content.Shared.Pulling
{
if (args.Pulled.Owner != uid)
return;
_alertsSystem.ShowAlert(component.Owner, AlertType.Pulled);
}
@@ -217,6 +218,10 @@ namespace Content.Shared.Pulling
return false;
}
if (_containerSystem.IsEntityInContainer(player) ||
player.IsWeightless(entityManager: EntityManager))
return false;
TryMoveTo(pullable, coords);
return false;