CatStation/Content.Shared/Warps/WarpPointSystem.cs
AsnDen b3cc7a5e54
WarpPoints are localizable now (#39319)
* WarpPoints locale

* string

* Revert "string"

This reverts commit 0148e4193dafce43f793da1f3306b6246d602824.

* Mothership Core

* fix

* merge fix

---------

Co-authored-by: Pok245 <113675512+Pok27@users.noreply.github.com>
2026-07-20 09:44:09 +00:00

22 lines
690 B
C#

using Content.Shared.Examine;
using Content.Shared.Ghost;
namespace Content.Shared.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)
{
if (!HasComp<GhostComponent>(args.Examiner))
return;
var loc = component.Location == null ? Name(uid) : Loc.GetString(component.Location);
args.PushText(Loc.GetString("warp-point-component-on-examine-success", ("location", loc)));
}
}