mirror of
https://github.com/space-syndicate/space-station-14.git
synced 2026-10-09 10:21:18 +03:00
Bugfix: Station AI's Comms Console UI is missing a screen (#45663)
* Add a default screen to the comms console BUI * Return to Screen, ScreenDummy is dead * margin adjustment
This commit is contained in:
parent
196167622e
commit
0b2245ff2c
4 changed files with 13 additions and 15 deletions
|
|
@ -15,5 +15,5 @@ public sealed partial class CommunicationsConsoleComponent : SharedCommunication
|
|||
/// If this isn't true, create a dummy entity or adjust the margins/scale in MessagingControls.xaml.
|
||||
/// </remarks>
|
||||
[DataField]
|
||||
public EntProtoId ScreenDisplayId = "ScreenDummy";
|
||||
public EntProtoId ScreenDisplayId = "Screen";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,6 +24,8 @@ public sealed partial class CommunicationsConsoleBoundUserInterface(EntityUid ow
|
|||
[ViewVariables]
|
||||
private CommunicationsConsoleMenu? _menu;
|
||||
|
||||
private static readonly EntProtoId FallbackScreen = "Screen";
|
||||
|
||||
/// <inheritdoc/>
|
||||
protected override void Open()
|
||||
{
|
||||
|
|
@ -38,6 +40,8 @@ public sealed partial class CommunicationsConsoleBoundUserInterface(EntityUid ow
|
|||
|
||||
if (EntMan.TryGetComponent<CommunicationsConsoleComponent>(Owner, out var console))
|
||||
_menu.SetBroadcastDisplayEntity(console.ScreenDisplayId);
|
||||
else
|
||||
_menu.SetBroadcastDisplayEntity(FallbackScreen);
|
||||
}
|
||||
|
||||
public void AlertLevelSelected(ProtoId<AlertLevelPrototype> level)
|
||||
|
|
|
|||
|
|
@ -25,12 +25,14 @@
|
|||
<Label StyleClasses="StatusFieldTitle" Align="Center" VAlign="Top"
|
||||
VerticalAlignment="Top"
|
||||
Text="{Loc 'comms-console-station-broadcast-header'}" />
|
||||
<Label Name="BroadcastTopCharLimitLabel"
|
||||
StyleClasses="CommsConsoleCharLimit" HorizontalAlignment="Center" Margin="0 10 0 0" />
|
||||
<SpriteView Name="BroadcastEntityDisplay" Scale="8 8" SpriteOffset="True"
|
||||
VerticalExpand="True" Margin="0 -124 0 -112" /> <!-- Forgive me for negamargin but there's just too much goddamn space - whatstone -->
|
||||
<Label Name="BroadcastBottomCharLimitLabel"
|
||||
StyleClasses="CommsConsoleCharLimit" HorizontalAlignment="Center" />
|
||||
<BoxContainer Orientation="Vertical" VerticalExpand="True" VerticalAlignment="Center">
|
||||
<Label Name="BroadcastTopCharLimitLabel"
|
||||
StyleClasses="CommsConsoleCharLimit" HorizontalAlignment="Center" Margin="0 10 0 0" />
|
||||
<SpriteView Name="BroadcastEntityDisplay" Scale="8 8" SpriteOffset="True"
|
||||
Margin="0 -56 0 -56" /> <!-- Forgive me for negamargin but there's just too much goddamn space - whatstone -->
|
||||
<Label Name="BroadcastBottomCharLimitLabel"
|
||||
StyleClasses="CommsConsoleCharLimit" HorizontalAlignment="Center" />
|
||||
</BoxContainer>
|
||||
<PanelContainer StyleClasses="BackgroundDark" Margin="10 6 6 6"
|
||||
HorizontalExpand="True" VerticalExpand="True">
|
||||
<TextEdit Name="ScreenMessageInput" MinHeight="40"
|
||||
|
|
|
|||
|
|
@ -39,14 +39,6 @@
|
|||
deviceNetId: Wireless
|
||||
receiveFrequencyId: ShuttleTimer
|
||||
|
||||
# Dummy screen for comms console
|
||||
- type: entity
|
||||
parent: Screen
|
||||
id: ScreenDummy
|
||||
categories: [HideSpawnMenu]
|
||||
components:
|
||||
- type: Sprite
|
||||
|
||||
- type: entity
|
||||
id: ArrivalsShuttleTimer
|
||||
parent: Screen
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue