* лежать * лучше так сделать * - remove: Gravity is fine. * - add: Hit moving lying targets. * - tweak: Lie down insted of stun on FTL. * - fix: Fix double component. * - remove: Disable recoil. --------- Co-authored-by: Aviu00 <aviu00@protonmail.com>
31 lines
904 B
C#
31 lines
904 B
C#
using Content.Shared.Standing;
|
|
using Content.Shared.Standing.Systems;
|
|
using Robust.Shared.Containers;
|
|
|
|
namespace Content.Shared.Medical.Cryogenics;
|
|
|
|
public abstract partial class SharedCryoPodSystem
|
|
{
|
|
public virtual void InitializeInsideCryoPod()
|
|
{
|
|
SubscribeLocalEvent<InsideCryoPodComponent, DownAttemptEvent>(HandleDown);
|
|
SubscribeLocalEvent<InsideCryoPodComponent, EntGotRemovedFromContainerMessage>(OnEntGotRemovedFromContainer);
|
|
}
|
|
|
|
// Must stand in the cryo pod
|
|
private void HandleDown(EntityUid uid, InsideCryoPodComponent component, DownAttemptEvent args)
|
|
{
|
|
args.Cancel();
|
|
}
|
|
|
|
private void OnEntGotRemovedFromContainer(EntityUid uid, InsideCryoPodComponent component, EntGotRemovedFromContainerMessage args)
|
|
{
|
|
if (Terminating(uid))
|
|
{
|
|
return;
|
|
}
|
|
|
|
RemComp<InsideCryoPodComponent>(uid);
|
|
}
|
|
}
|