Fix verb sub (#30667)
* Fix verb sub Mapping casualty, verbs are weird. * also this
This commit is contained in:
parent
c1eb319bda
commit
f7d8b4e7d4
2 changed files with 5 additions and 3 deletions
|
|
@ -47,6 +47,7 @@ namespace Content.Client.Verbs.UI
|
|||
{
|
||||
_context.OnContextKeyEvent += OnKeyBindDown;
|
||||
_context.OnContextClosed += Close;
|
||||
_verbSystem.OnVerbsResponse += HandleVerbsResponse;
|
||||
}
|
||||
|
||||
public void OnStateExited(GameplayState state)
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ using Content.Server.Traitor.Components;
|
|||
using Robust.Shared.Random;
|
||||
using Robust.Shared.Utility;
|
||||
using System.Linq;
|
||||
using Content.Shared.Paper;
|
||||
|
||||
namespace Content.Server.Traitor.Systems;
|
||||
|
||||
|
|
@ -33,11 +34,11 @@ public sealed class TraitorCodePaperSystem : EntitySystem
|
|||
if (!Resolve(uid, ref component))
|
||||
return;
|
||||
|
||||
if (HasComp<PaperComponent>(uid))
|
||||
if (TryComp(uid, out PaperComponent? paperComp))
|
||||
{
|
||||
if (TryGetTraitorCode(out var paperContent, component))
|
||||
{
|
||||
_paper.SetContent(uid, paperContent);
|
||||
_paper.SetContent((uid, paperComp), paperContent);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -83,7 +84,7 @@ public sealed class TraitorCodePaperSystem : EntitySystem
|
|||
|
||||
if (!codesMessage.IsEmpty)
|
||||
{
|
||||
if (i == 1)
|
||||
if (i == 1)
|
||||
traitorCode = Loc.GetString("traitor-codes-message-singular") + codesMessage;
|
||||
else
|
||||
traitorCode = Loc.GetString("traitor-codes-message-plural") + codesMessage;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue