Files
OldThink/Content.Server/Warps/WarpPointSystem.cs

23 lines
681 B
C#
Raw Normal View History

2022-02-01 17:15:58 +11:00
using Content.Shared.Examine;
2023-08-25 18:50:46 +10:00
using Content.Shared.Ghost;
2022-02-01 17:15:58 +11:00
namespace Content.Server.Warps;
public sealed class WarpPointSystem : EntitySystem
{
public override void Initialize()
{
base.Initialize();
SubscribeLocalEvent<WarpPointComponent, ExaminedEvent>(OnWarpPointExamine);
}
private void OnWarpPointExamine(EntityUid uid, WarpPointComponent component, ExaminedEvent args)
2022-02-01 17:15:58 +11:00
{
if (!HasComp<GhostComponent>(args.Examiner))
return;
2022-02-01 17:15:58 +11:00
var loc = component.Location == null ? "<null>" : $"'{component.Location}'";
args.PushText(Loc.GetString("warp-point-component-on-examine-success", ("location", loc)));
}
}