From: Nemanja <98561806+EmoGarbage404@users.noreply.github.com> Date: Sun, 18 May 2025 04:02:52 +0000 (-0400) Subject: Salvage Job Board (#37549) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=0d878751faf583dd253f97c40c7466374d8c9f8d;p=space-station-14.git Salvage Job Board (#37549) * Salvage Job Board * More development * Small boy * Computer yaml (partial) * UI * Rank unlock logic * Job label printing * appraisal tool integration * Jobs * add board to QM locker * boom! * command desc * mild rewording * ackh, mein pr ist brohken --- diff --git a/Content.Client/Cargo/BUI/CargoOrderConsoleBoundUserInterface.cs b/Content.Client/Cargo/BUI/CargoOrderConsoleBoundUserInterface.cs index 52846cefdb..3bd220bfad 100644 --- a/Content.Client/Cargo/BUI/CargoOrderConsoleBoundUserInterface.cs +++ b/Content.Client/Cargo/BUI/CargoOrderConsoleBoundUserInterface.cs @@ -138,6 +138,11 @@ namespace Content.Client.Cargo.BUI AccountName = cState.Name; + if (_menu == null) + return; + + _menu.ProductCatalogue = cState.Products; + _menu?.UpdateStation(station); Populate(cState.Orders); } diff --git a/Content.Client/Cargo/UI/CargoConsoleMenu.xaml.cs b/Content.Client/Cargo/UI/CargoConsoleMenu.xaml.cs index 4c729b795b..dfc61c0527 100644 --- a/Content.Client/Cargo/UI/CargoConsoleMenu.xaml.cs +++ b/Content.Client/Cargo/UI/CargoConsoleMenu.xaml.cs @@ -40,6 +40,8 @@ namespace Content.Client.Cargo.UI private readonly List _categoryStrings = new(); private string? _category; + public List> ProductCatalogue = new(); + public CargoConsoleMenu(EntityUid owner, IEntityManager entMan, IPrototypeManager protoManager, SpriteSystem spriteSystem) { RobustXamlLoader.Load(this); @@ -113,14 +115,16 @@ namespace Content.Client.Cargo.UI Categories.SelectId(id); } - public IEnumerable ProductPrototypes + private IEnumerable ProductPrototypes { get { var allowedGroups = _entityManager.GetComponentOrNull(_owner)?.AllowedGroups; - foreach (var cargoPrototype in _protoManager.EnumeratePrototypes()) + foreach (var cargoPrototypeId in ProductCatalogue) { + var cargoPrototype = _protoManager.Index(cargoPrototypeId); + if (!allowedGroups?.Contains(cargoPrototype.Group) ?? false) continue; diff --git a/Content.Client/Salvage/UI/JobEntry.xaml b/Content.Client/Salvage/UI/JobEntry.xaml new file mode 100644 index 0000000000..bad88f89b7 --- /dev/null +++ b/Content.Client/Salvage/UI/JobEntry.xaml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + +