Skip to content

Commit

Permalink
Merge branch 'DeltaV-Station:master' into conflict2
Browse files Browse the repository at this point in the history
  • Loading branch information
GeneralGaws authored May 8, 2024
2 parents fd3e763 + 8a15020 commit 840064c
Show file tree
Hide file tree
Showing 1,452 changed files with 20,915 additions and 10,090 deletions.
39 changes: 27 additions & 12 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1,24 +1,39 @@
"Changes: C#":
- "**/*.cs"
"Changes: C#":
- changed-files:
- any-glob-to-any-file: "**/*.cs"

"Changes: Documentation":
- "**/*.xml"
- "**/*.md"
- changed-files:
- any-glob-to-any-file:
- "**/*.xml"
- "**/*.md"

"Changes: Localization":
- 'Resources/Locale/**/*.ftl'
- changed-files:
- any-glob-to-any-file:
- 'Resources/Locale/**/*.ftl'

"Changes: Map":
- "Resources/Maps/**/*.yml"
- "Resources/Prototypes/Maps/**/*.yml"
- changed-files:
- any-glob-to-any-file:
- "Resources/Maps/**/*.yml"
- "Resources/Prototypes/Maps/**/*.yml"

"Changes: Sprite":
- "**/*.rsi/*.png"
- "**/*.rsi/*.json"
- changed-files:
- any-glob-to-any-file:
- "**/*.rsi/*.png"
- "**/*.rsi/*.json"

"Changes: UI":
- "**/*.xaml*"
- changed-files:
- any-glob-to-any-file:
- "**/*.xaml*"

"Changes: YML":
- any: ["**/*.yml"]
all: ["!Resources/Maps/**/*.yml", "!Resources/Prototypes/Maps/**/*.yml"]
- changed-files:
- any-glob-to-any-file:
- "**/*.yml"
- all-globs-to-all-files:
- "!Resources/Maps/**/*.yml"
- "!Resources/Prototypes/Maps/**/*.yml"
12 changes: 7 additions & 5 deletions .github/workflows/conflict-labeler.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
name: Check Merge Conflicts

on:
push:
branches:
- master
pull_request_target:
types:
- opened
- synchronize
- reopened
- ready_for_review

jobs:
Label:
if: github.actor != 'PJBot' && github.actor != 'DeltaV-Bot'
if: ( github.event.pull_request.draft == false ) && ( github.actor != 'PJBot' ) && ( github.actor != 'DeltaV-Bot' )
runs-on: ubuntu-latest
steps:
- name: Check for Merge Conflicts
uses: ike709/actions-label-merge-conflict@9eefdd17e10566023c46d2dc6dc04fcb8ec76142
uses: eps1lon/actions-label-merge-conflict@v3.0.0
with:
dirtyLabel: "Status: Merge Conflict"
repoToken: "${{ secrets.GITHUB_TOKEN }}"
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/labeler-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ on:
jobs:
labeler:
if: github.actor != 'PJBot' && github.actor != 'DeltaV-Bot'
permissions:
contents: read
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@v3
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
- uses: actions/labeler@v5
3 changes: 2 additions & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
[submodule "RobustToolbox"]
path = RobustToolbox
url = https://github.com/space-wizards/RobustToolbox.git
branch = master
branch = master
ignore = dirty
4 changes: 1 addition & 3 deletions Content.Client/Access/IdCardSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,4 @@

namespace Content.Client.Access;

public sealed class IdCardSystem : SharedIdCardSystem
{
}
public sealed class IdCardSystem : SharedIdCardSystem;
6 changes: 3 additions & 3 deletions Content.Client/Access/UI/AgentIDCardBoundUserInterface.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ private void OnJobChanged(string newJob)
SendMessage(new AgentIDCardJobChangedMessage(newJob));
}

public void OnJobIconChanged(string newJobIcon)
public void OnJobIconChanged(string newJobIconId)
{
SendMessage(new AgentIDCardJobIconChangedMessage(newJobIcon));
SendMessage(new AgentIDCardJobIconChangedMessage(newJobIconId));
}

/// <summary>
Expand All @@ -57,7 +57,7 @@ protected override void UpdateState(BoundUserInterfaceState state)

_window.SetCurrentName(cast.CurrentName);
_window.SetCurrentJob(cast.CurrentJob);
_window.SetAllowedIcons(cast.Icons);
_window.SetAllowedIcons(cast.Icons, cast.CurrentJobIconId);
}

protected override void Dispose(bool disposing)
Expand Down
6 changes: 5 additions & 1 deletion Content.Client/Access/UI/AgentIDCardWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public AgentIDCardWindow(AgentIDCardBoundUserInterface bui)
JobLineEdit.OnFocusExit += e => OnJobChanged?.Invoke(e.Text);
}

public void SetAllowedIcons(HashSet<string> icons)
public void SetAllowedIcons(HashSet<string> icons, string currentJobIconId)
{
IconGrid.DisposeAllChildren();

Expand Down Expand Up @@ -79,6 +79,10 @@ public void SetAllowedIcons(HashSet<string> icons)
jobIconButton.AddChild(jobIconTexture);
jobIconButton.OnPressed += _ => _bui.OnJobIconChanged(jobIcon.ID);
IconGrid.AddChild(jobIconButton);

if (jobIconId.Equals(currentJobIconId))
jobIconButton.Pressed = true;

i++;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Content.Client.Administration.Components;

[RegisterComponent, NetworkedComponent]
[RegisterComponent]
public sealed partial class HeadstandComponent : SharedHeadstandComponent
{

Expand Down
5 changes: 2 additions & 3 deletions Content.Client/Administration/Components/KillSignComponent.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,5 @@

namespace Content.Client.Administration.Components;

[NetworkedComponent, RegisterComponent]
public sealed partial class KillSignComponent : SharedKillSignComponent
{ }
[RegisterComponent]
public sealed partial class KillSignComponent : SharedKillSignComponent;
23 changes: 23 additions & 0 deletions Content.Client/Administration/Systems/AdminVerbSystem.cs
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
using Content.Shared.Administration;
using Content.Shared.Administration.Managers;
using Content.Shared.Mind.Components;
using Content.Shared.Verbs;
using Robust.Client.Console;
using Robust.Shared.Utility;
Expand All @@ -11,10 +14,12 @@ sealed class AdminVerbSystem : EntitySystem
{
[Dependency] private readonly IClientConGroupController _clientConGroupController = default!;
[Dependency] private readonly IClientConsoleHost _clientConsoleHost = default!;
[Dependency] private readonly ISharedAdminManager _admin = default!;

public override void Initialize()
{
SubscribeLocalEvent<GetVerbsEvent<Verb>>(AddAdminVerbs);

}

private void AddAdminVerbs(GetVerbsEvent<Verb> args)
Expand All @@ -33,6 +38,24 @@ private void AddAdminVerbs(GetVerbsEvent<Verb> args)
};
args.Verbs.Add(verb);
}

if (!_admin.IsAdmin(args.User))
return;

if (_admin.HasAdminFlag(args.User, AdminFlags.Admin))
args.ExtraCategories.Add(VerbCategory.Admin);

if (_admin.HasAdminFlag(args.User, AdminFlags.Fun) && HasComp<MindContainerComponent>(args.Target))
args.ExtraCategories.Add(VerbCategory.Antag);

if (_admin.HasAdminFlag(args.User, AdminFlags.Debug))
args.ExtraCategories.Add(VerbCategory.Debug);

if (_admin.HasAdminFlag(args.User, AdminFlags.Fun))
args.ExtraCategories.Add(VerbCategory.Smite);

if (_admin.HasAdminFlag(args.User, AdminFlags.Admin))
args.ExtraCategories.Add(VerbCategory.Tricks);
}
}
}
17 changes: 17 additions & 0 deletions Content.Client/Animations/TrackUserComponent.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
using System.Numerics;

namespace Content.Client.Animations;

/// <summary>
/// Entities with this component tracks the user's world position every frame.
/// </summary>
[RegisterComponent]
public sealed partial class TrackUserComponent : Component
{
public EntityUid? User;

/// <summary>
/// Offset in the direction of the entity's rotation.
/// </summary>
public Vector2 Offset = Vector2.Zero;
}
16 changes: 4 additions & 12 deletions Content.Client/Audio/Jukebox/JukeboxSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ public sealed class JukeboxSystem : SharedJukeboxSystem
[Dependency] private readonly IPrototypeManager _protoManager = default!;
[Dependency] private readonly AnimationPlayerSystem _animationPlayer = default!;
[Dependency] private readonly SharedAppearanceSystem _appearanceSystem = default!;
[Dependency] private readonly SharedUserInterfaceSystem _uiSystem = default!;

public override void Initialize()
{
Expand All @@ -35,29 +36,20 @@ private void OnProtoReload(PrototypesReloadedEventArgs obj)

var query = AllEntityQuery<JukeboxComponent, UserInterfaceComponent>();

while (query.MoveNext(out _, out var ui))
while (query.MoveNext(out var uid, out _, out var ui))
{
if (!ui.OpenInterfaces.TryGetValue(JukeboxUiKey.Key, out var baseBui) ||
baseBui is not JukeboxBoundUserInterface bui)
{
if (!_uiSystem.TryGetOpenUi<JukeboxBoundUserInterface>((uid, ui), JukeboxUiKey.Key, out var bui))
continue;
}

bui.PopulateMusic();
}
}

private void OnJukeboxAfterState(Entity<JukeboxComponent> ent, ref AfterAutoHandleStateEvent args)
{
if (!TryComp(ent, out UserInterfaceComponent? ui))
if (!_uiSystem.TryGetOpenUi<JukeboxBoundUserInterface>(ent.Owner, JukeboxUiKey.Key, out var bui))
return;

if (!ui.OpenInterfaces.TryGetValue(JukeboxUiKey.Key, out var baseBui) ||
baseBui is not JukeboxBoundUserInterface bui)
{
return;
}

bui.Reload();
}

Expand Down
31 changes: 31 additions & 0 deletions Content.Client/Chat/UI/EmotesMenu.xaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<ui:RadialMenu xmlns="https://spacestation14.io"
xmlns:ui="clr-namespace:Content.Client.UserInterface.Controls"
BackButtonStyleClass="RadialMenuBackButton"
CloseButtonStyleClass="RadialMenuCloseButton"
VerticalExpand="True"
HorizontalExpand="True"
MinSize="450 450">

<!-- Main -->
<ui:RadialContainer Name="Main" VerticalExpand="True" HorizontalExpand="True" Radius="64" ReserveSpaceForHiddenChildren="False">
<ui:RadialMenuTextureButton StyleClasses="RadialMenuButton" SetSize="64 64" ToolTip="{Loc 'emote-menu-category-general'}" TargetLayer="General" Visible="False">
<TextureRect VerticalAlignment="Center" HorizontalAlignment="Center" TextureScale="2 2" TexturePath="/Textures/Clothing/Head/Soft/mimesoft.rsi/icon.png"/>
</ui:RadialMenuTextureButton>
<ui:RadialMenuTextureButton StyleClasses="RadialMenuButton" SetSize="64 64" ToolTip="{Loc 'emote-menu-category-vocal'}" TargetLayer="Vocal" Visible="False">
<TextureRect VerticalAlignment="Center" HorizontalAlignment="Center" TextureScale="2 2" TexturePath="/Textures/Interface/Emotes/vocal.png"/>
</ui:RadialMenuTextureButton>
<ui:RadialMenuTextureButton StyleClasses="RadialMenuButton" SetSize="64 64" ToolTip="{Loc 'emote-menu-category-hands'}" TargetLayer="Hands" Visible="False">
<TextureRect VerticalAlignment="Center" HorizontalAlignment="Center" TextureScale="2 2" TexturePath="/Textures/Clothing/Hands/Gloves/latex.rsi/icon.png"/>
</ui:RadialMenuTextureButton>
</ui:RadialContainer>

<!-- General -->
<ui:RadialContainer Name="General" VerticalExpand="True" HorizontalExpand="True" Radius="64"/>

<!-- Vocal -->
<ui:RadialContainer Name="Vocal" VerticalExpand="True" HorizontalExpand="True" Radius="64"/>

<!-- Hands -->
<ui:RadialContainer Name="Hands" VerticalExpand="True" HorizontalExpand="True" Radius="64"/>

</ui:RadialMenu>
Loading

0 comments on commit 840064c

Please sign in to comment.