From 08cb26dbf08417af7a32c64c0f31c3588a0208cf Mon Sep 17 00:00:00 2001
From: SlamBamActionman <83650252+SlamBamActionman@users.noreply.github.com>
Date: Sun, 2 Mar 2025 20:40:57 +0100
Subject: [PATCH 1/3] Hotfix: Fix uplinks allowing buying conditionally
restricted items (#35334)
* Initial commit
* I just compressed the code
* Actually address review
---
.../Store/Systems/StoreSystem.Listings.cs | 16 +++++++++++++++-
Content.Server/Store/Systems/StoreSystem.Ui.cs | 2 +-
2 files changed, 16 insertions(+), 2 deletions(-)
diff --git a/Content.Server/Store/Systems/StoreSystem.Listings.cs b/Content.Server/Store/Systems/StoreSystem.Listings.cs
index 4699ec7b66..412114ce03 100644
--- a/Content.Server/Store/Systems/StoreSystem.Listings.cs
+++ b/Content.Server/Store/Systems/StoreSystem.Listings.cs
@@ -1,4 +1,5 @@
using System.Diagnostics.CodeAnalysis;
+using Content.Shared.Mind;
using Content.Shared.Store;
using Content.Shared.Store.Components;
using Robust.Shared.Prototypes;
@@ -117,7 +118,7 @@ public sealed partial class StoreSystem
if (listing.Conditions != null)
{
- var args = new ListingConditionArgs(buyer, storeEntity, listing, EntityManager);
+ var args = new ListingConditionArgs(GetBuyerMind(buyer), storeEntity, listing, EntityManager);
var conditionsMet = true;
foreach (var condition in listing.Conditions)
@@ -137,6 +138,19 @@ public sealed partial class StoreSystem
}
}
+ ///
+ /// Returns the entity's mind entity, if it has one, to be used for listing conditions.
+ /// If it doesn't have one, or is a mind entity already, it returns itself.
+ ///
+ /// The buying entity.
+ public EntityUid GetBuyerMind(EntityUid buyer)
+ {
+ if (!HasComp(buyer) && _mind.TryGetMind(buyer, out var buyerMind, out var _))
+ return buyerMind;
+
+ return buyer;
+ }
+
///
/// Checks if a listing appears in a list of given categories
///
diff --git a/Content.Server/Store/Systems/StoreSystem.Ui.cs b/Content.Server/Store/Systems/StoreSystem.Ui.cs
index 3f4ccf696d..93bbd3bd96 100644
--- a/Content.Server/Store/Systems/StoreSystem.Ui.cs
+++ b/Content.Server/Store/Systems/StoreSystem.Ui.cs
@@ -146,7 +146,7 @@ public sealed partial class StoreSystem
//condition checking because why not
if (listing.Conditions != null)
{
- var args = new ListingConditionArgs(component.AccountOwner ?? buyer, uid, listing, EntityManager);
+ var args = new ListingConditionArgs(component.AccountOwner ?? GetBuyerMind(buyer), uid, listing, EntityManager);
var conditionsMet = listing.Conditions.All(condition => condition.Condition(args));
if (!conditionsMet)
From 7bf09bfdb534cf4740da27cd5472c22b9b6d7ef3 Mon Sep 17 00:00:00 2001
From: Errant <35878406+Errant-4@users.noreply.github.com>
Date: Sun, 2 Mar 2025 20:41:07 +0100
Subject: [PATCH 2/3] add altered silicon to rules (#35455)
* add altered silicon to rules
* skreee
Co-authored-by: crazybrain23 <44417085+crazybrain23@users.noreply.github.com>
---------
Co-authored-by: crazybrain23 <44417085+crazybrain23@users.noreply.github.com>
---
Resources/ServerInfo/Guidebook/ServerRules/RoleTypes.xml | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/Resources/ServerInfo/Guidebook/ServerRules/RoleTypes.xml b/Resources/ServerInfo/Guidebook/ServerRules/RoleTypes.xml
index 67a05f516c..b21e97c4e0 100644
--- a/Resources/ServerInfo/Guidebook/ServerRules/RoleTypes.xml
+++ b/Resources/ServerInfo/Guidebook/ServerRules/RoleTypes.xml
@@ -16,6 +16,7 @@
## Familiar
Familiars are considered non-antagonists, but have instructions to obey someone. They must obey this person even if it causes them to violate roleplay rules or die. You are only a familiar if the game clearly and explicitly tells you that you are a familiar. You are only the familiar of the person the game tells you.
- ## Silicon
+ ## Silicon / Altered Silicon
Silicons have a set of laws that they must follow above all else except the core rules. You are only silicon if the game clearly and explicitly tells you that you are a silicon.
+ Altered Silicons are functionally identical, this role is used to highlight law-sets that have been hacked, corrupted or are otherwise considered non-standard or dangerous.
From 4dfd3e5740d316d1c37d38623b8266333bef0945 Mon Sep 17 00:00:00 2001
From: beck-thompson <107373427+beck-thompson@users.noreply.github.com>
Date: Sun, 2 Mar 2025 11:45:54 -0800
Subject: [PATCH 3/3] [HOTFIX] - Players with unknown playtimes now are tagged
as new players (#35564)
* Players with unknown playtimes now are tagged as new players
* Fix
* I'm silly it was in the same file
* Cavar update
---
.../Administration/UI/Bwoink/BwoinkControl.xaml.cs | 5 ++++-
.../Administration/UI/Bwoink/BwoinkWindow.xaml.cs | 7 ++-----
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/Content.Client/Administration/UI/Bwoink/BwoinkControl.xaml.cs b/Content.Client/Administration/UI/Bwoink/BwoinkControl.xaml.cs
index 3e05018c10..932b08e1a6 100644
--- a/Content.Client/Administration/UI/Bwoink/BwoinkControl.xaml.cs
+++ b/Content.Client/Administration/UI/Bwoink/BwoinkControl.xaml.cs
@@ -36,6 +36,9 @@ namespace Content.Client.Administration.UI.Bwoink
RobustXamlLoader.Load(this);
IoCManager.InjectDependencies(this);
+ var newPlayerThreshold = 0;
+ _cfg.OnValueChanged(CCVars.NewPlayerThreshold, (val) => { newPlayerThreshold = val; }, true);
+
var uiController = _ui.GetUIController();
if (uiController.UIHelper is not AdminAHelpUIHandler helper)
return;
@@ -76,7 +79,7 @@ namespace Content.Client.Administration.UI.Bwoink
if (info.Antag && info.ActiveThisRound)
sb.Append(new Rune(0x1F5E1)); // 🗡
- if (info.OverallPlaytime <= TimeSpan.FromMinutes(_cfg.GetCVar(CCVars.NewPlayerThreshold)))
+ if (newPlayerThreshold != 0 && (info.OverallPlaytime == null || info.OverallPlaytime <= TimeSpan.FromMinutes(newPlayerThreshold)))
sb.Append(new Rune(0x23F2)); // ⏲
sb.AppendFormat("\"{0}\"", text);
diff --git a/Content.Client/Administration/UI/Bwoink/BwoinkWindow.xaml.cs b/Content.Client/Administration/UI/Bwoink/BwoinkWindow.xaml.cs
index e8653843c7..e6cd4942a6 100644
--- a/Content.Client/Administration/UI/Bwoink/BwoinkWindow.xaml.cs
+++ b/Content.Client/Administration/UI/Bwoink/BwoinkWindow.xaml.cs
@@ -22,12 +22,9 @@ namespace Content.Client.Administration.UI.Bwoink
return;
}
- Title = $"{sel.CharacterName} / {sel.Username}";
+ Title = $"{sel.CharacterName} / {sel.Username} | {Loc.GetString("generic-playtime-title")}: ";
- if (sel.OverallPlaytime != null)
- {
- Title += $" | {Loc.GetString("generic-playtime-title")}: {sel.PlaytimeString}";
- }
+ Title += sel.OverallPlaytime != null ? sel.PlaytimeString : Loc.GetString("generic-unknown-title");
};
OnOpen += () =>