Fix being able to trap aghosts in lockers.

This ain't an ideal fix, I'll admit. But it's better than nothing.
Fixes #4767
This commit is contained in:
Vera Aguilera Puerto
2021-10-06 11:45:52 +02:00
parent d16c299af1
commit 94a29978b5
2 changed files with 9 additions and 0 deletions

View File

@@ -2,6 +2,7 @@ using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq; using System.Linq;
using System.Threading.Tasks; using System.Threading.Tasks;
using Content.Server.Ghost.Components;
using Content.Server.Tools.Components; using Content.Server.Tools.Components;
using Content.Shared.ActionBlocker; using Content.Shared.ActionBlocker;
using Content.Shared.Acts; using Content.Shared.Acts;
@@ -209,6 +210,10 @@ namespace Content.Server.Storage.Components
!entity.HasComponent<SharedBodyComponent>()) !entity.HasComponent<SharedBodyComponent>())
continue; continue;
// Let's not insert admin ghosts, yeah? This is really a a hack and should be replaced by attempt events
if (entity.HasComponent<GhostComponent>())
continue;
if (!AddToContents(entity)) if (!AddToContents(entity))
{ {
continue; continue;

View File

@@ -0,0 +1,4 @@
author: Zumorica
changes:
- type: Fix # One of the following: Add, Remove, Tweak, Fix
message: Fix being able to trap admin ghosts on lockers.