+++ /dev/null
-using Content.Shared.Administration;
-
-namespace Content.Server.Administration.Systems;
-
-public sealed class AdminFrozenSystem : SharedAdminFrozenSystem
-{
- /// <summary>
- /// Freezes and mutes the given entity.
- /// </summary>
- public void FreezeAndMute(EntityUid uid)
- {
- var comp = EnsureComp<AdminFrozenComponent>(uid);
- comp.Muted = true;
- Dirty(uid, comp);
- }
-}
namespace Content.Shared.Administration;
-[RegisterComponent, Access(typeof(SharedAdminFrozenSystem))]
+[RegisterComponent, Access(typeof(AdminFrozenSystem))]
[NetworkedComponent, AutoGenerateComponentState]
public sealed partial class AdminFrozenComponent : Component
{
namespace Content.Shared.Administration;
// TODO deduplicate with BlockMovementComponent
-public abstract class SharedAdminFrozenSystem : EntitySystem
+public sealed class AdminFrozenSystem : EntitySystem
{
[Dependency] private readonly ActionBlockerSystem _blocker = default!;
[Dependency] private readonly PullingSystem _pulling = default!;
public override void Initialize()
{
- base.Initialize();
-
SubscribeLocalEvent<AdminFrozenComponent, UseAttemptEvent>(OnAttempt);
SubscribeLocalEvent<AdminFrozenComponent, PickupAttemptEvent>(OnAttempt);
SubscribeLocalEvent<AdminFrozenComponent, ThrowAttemptEvent>(OnAttempt);
SubscribeLocalEvent<AdminFrozenComponent, SpeakAttemptEvent>(OnSpeakAttempt);
}
+ /// <summary>
+ /// Freezes and mutes the given entity.
+ /// </summary>
+ public void FreezeAndMute(EntityUid uid)
+ {
+ var comp = EnsureComp<AdminFrozenComponent>(uid);
+ comp.Muted = true;
+ Dirty(uid, comp);
+ }
+
private void OnInteractAttempt(Entity<AdminFrozenComponent> ent, ref InteractionAttemptEvent args)
{
args.Cancelled = true;