voicemask can select speech verb (#25768)

* add Name field to SpeechVerbPrototype

* extra locale for voice mask ui

* SpeechVerb ui and handling

* raaaaaaaaa

* reeeeeeeeal

Co-authored-by: Tayrtahn <tayrtahn@gmail.com>

* fix sort

* did you hear john syndicate died of ligma

* Update Content.Client/VoiceMask/VoiceMaskNameChangeWindow.xaml

---------

Co-authored-by: deltanedas <@deltanedas:kde.org>
Co-authored-by: Tayrtahn <tayrtahn@gmail.com>
Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
This commit is contained in:
deltanedas
2024-03-28 06:36:43 +00:00
committed by GitHub
parent df7f2a1276
commit d13da2837d
11 changed files with 200 additions and 31 deletions

View File

@@ -1,10 +1,13 @@
using Content.Shared.VoiceMask;
using Robust.Client.GameObjects;
using Robust.Shared.Prototypes;
namespace Content.Client.VoiceMask;
public sealed class VoiceMaskBoundUserInterface : BoundUserInterface
{
[Dependency] private readonly IPrototypeManager _proto = default!;
[ViewVariables]
private VoiceMaskNameChangeWindow? _window;
@@ -16,10 +19,11 @@ public sealed class VoiceMaskBoundUserInterface : BoundUserInterface
{
base.Open();
_window = new();
_window = new(_proto);
_window.OpenCentered();
_window.OnNameChange += OnNameSelected;
_window.OnVerbChange += verb => SendMessage(new VoiceMaskChangeVerbMessage(verb));
_window.OnClose += Close;
}
@@ -35,7 +39,7 @@ public sealed class VoiceMaskBoundUserInterface : BoundUserInterface
return;
}
_window.UpdateState(cast.Name);
_window.UpdateState(cast.Name, cast.Verb);
}
protected override void Dispose(bool disposing)