Fix multi-ghosts (#22964)

* Fix multi-ghosts

* Fix mind visits
This commit is contained in:
metalgearsloth
2023-12-26 00:19:12 +11:00
committed by GitHub
parent 724cde264c
commit c326e5d087
3 changed files with 22 additions and 3 deletions

View File

@@ -15,6 +15,7 @@ using Content.Shared.Mind.Components;
using Content.Shared.Mobs.Components;
using Content.Shared.Mobs.Systems;
using Content.Shared.Movement.Events;
using Content.Shared.Movement.Systems;
using Content.Shared.Storage.Components;
using Robust.Server.GameObjects;
using Robust.Server.Player;
@@ -116,6 +117,13 @@ namespace Content.Server.Ghost
private void OnRelayMoveInput(EntityUid uid, GhostOnMoveComponent component, ref MoveInputEvent args)
{
// If they haven't actually moved then ignore it.
if ((args.Component.HeldMoveButtons &
(MoveButtons.Down | MoveButtons.Left | MoveButtons.Up | MoveButtons.Right)) == 0x0)
{
return;
}
// Let's not ghost if our mind is visiting...
if (HasComp<VisitingMindComponent>(uid))
return;