From 1fdbf9403a6d28ffefc867aeb21db3db017a6404 Mon Sep 17 00:00:00 2001 From: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com> Date: Sun, 9 Jun 2024 04:43:21 +1000 Subject: [PATCH] Don't use invalid defaults for loadouts (#28729) At the time it made more sense but now with species specific stuff it's better to have nothing. --- Content.Shared/Preferences/Loadouts/RoleLoadout.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Content.Shared/Preferences/Loadouts/RoleLoadout.cs b/Content.Shared/Preferences/Loadouts/RoleLoadout.cs index b9d3a88338..18c3501ea6 100644 --- a/Content.Shared/Preferences/Loadouts/RoleLoadout.cs +++ b/Content.Shared/Preferences/Loadouts/RoleLoadout.cs @@ -127,7 +127,10 @@ public sealed partial class RoleLoadout : IEquatable if (loadouts.Contains(defaultLoadout)) continue; - // Still need to apply the effects even if validation is ignored. + // Not valid so don't default to it anyway. + if (!IsValid(profile, session, defaultLoadout.Prototype, collection, out _)) + continue; + loadouts.Add(defaultLoadout); Apply(loadoutProto); }