Emag nerf (#7689)
This commit is contained in:
@@ -17,7 +17,6 @@ using Robust.Shared.Audio;
|
|||||||
using Robust.Shared.Containers;
|
using Robust.Shared.Containers;
|
||||||
using Robust.Shared.Physics.Dynamics;
|
using Robust.Shared.Physics.Dynamics;
|
||||||
using Robust.Shared.Player;
|
using Robust.Shared.Player;
|
||||||
using Content.Shared.Hands.Components;
|
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using Content.Shared.Tools.Components;
|
using Content.Shared.Tools.Components;
|
||||||
|
|
||||||
@@ -294,6 +293,9 @@ public sealed class DoorSystem : SharedDoorSystem
|
|||||||
{
|
{
|
||||||
if(TryComp<AirlockComponent>(uid, out var airlockComponent))
|
if(TryComp<AirlockComponent>(uid, out var airlockComponent))
|
||||||
{
|
{
|
||||||
|
if (airlockComponent.BoltsDown || !airlockComponent.IsPowered())
|
||||||
|
return;
|
||||||
|
|
||||||
if (door.State == DoorState.Closed)
|
if (door.State == DoorState.Closed)
|
||||||
{
|
{
|
||||||
SetState(uid, DoorState.Emagging, door);
|
SetState(uid, DoorState.Emagging, door);
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ using Content.Shared.Emag.Components;
|
|||||||
using Content.Shared.Emag.Systems;
|
using Content.Shared.Emag.Systems;
|
||||||
using Content.Shared.Interaction;
|
using Content.Shared.Interaction;
|
||||||
using Content.Shared.Popups;
|
using Content.Shared.Popups;
|
||||||
|
using Content.Shared.Tag;
|
||||||
using Robust.Shared.Player;
|
using Robust.Shared.Player;
|
||||||
|
|
||||||
namespace Content.Server.Emag
|
namespace Content.Server.Emag
|
||||||
@@ -13,6 +14,8 @@ namespace Content.Server.Emag
|
|||||||
[Dependency] private readonly SharedPopupSystem _popupSystem = default!;
|
[Dependency] private readonly SharedPopupSystem _popupSystem = default!;
|
||||||
[Dependency] private readonly SharedAdminLogSystem _adminLog = default!;
|
[Dependency] private readonly SharedAdminLogSystem _adminLog = default!;
|
||||||
|
|
||||||
|
[Dependency] private readonly TagSystem _tagSystem = default!;
|
||||||
|
|
||||||
public override void Initialize()
|
public override void Initialize()
|
||||||
{
|
{
|
||||||
base.Initialize();
|
base.Initialize();
|
||||||
@@ -49,6 +52,9 @@ namespace Content.Server.Emag
|
|||||||
if (!args.CanReach || args.Target == null)
|
if (!args.CanReach || args.Target == null)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if (_tagSystem.HasTag(args.Target.Value, "EmagImmune"))
|
||||||
|
return;
|
||||||
|
|
||||||
if (component.Charges <= 0)
|
if (component.Charges <= 0)
|
||||||
{
|
{
|
||||||
_popupSystem.PopupEntity(Loc.GetString("emag-no-charges"), args.User, Filter.Entities(args.User));
|
_popupSystem.PopupEntity(Loc.GetString("emag-no-charges"), args.User, Filter.Entities(args.User));
|
||||||
|
|||||||
@@ -222,6 +222,9 @@
|
|||||||
radius: 1.5
|
radius: 1.5
|
||||||
energy: 1.6
|
energy: 1.6
|
||||||
color: "#3c5eb5"
|
color: "#3c5eb5"
|
||||||
|
- type: Tag
|
||||||
|
tags:
|
||||||
|
- EmagImmune
|
||||||
|
|
||||||
- type: entity
|
- type: entity
|
||||||
parent: ComputerBase
|
parent: ComputerBase
|
||||||
|
|||||||
@@ -129,6 +129,9 @@
|
|||||||
- type: Tag
|
- type: Tag
|
||||||
id: Egg
|
id: Egg
|
||||||
|
|
||||||
|
- type: Tag
|
||||||
|
id: EmagImmune
|
||||||
|
|
||||||
- type: Tag
|
- type: Tag
|
||||||
id: EmitterBolt
|
id: EmitterBolt
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user