Skip to content

Commit

Permalink
Master merge: Fix horrible lag in Zombies mode (space-wizards#33818) (s…
Browse files Browse the repository at this point in the history
  • Loading branch information
VasilisThePikachu authored Dec 17, 2024
2 parents 3fe576b + 59e955a commit 77a4cda
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions Content.Shared/Whitelist/EntityWhitelistSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,12 @@ public bool IsValid(EntityWhitelist list, EntityUid uid)
{
if (list.Components != null)
{
var regs = StringsToRegs(list.Components);

list.Registrations ??= new List<ComponentRegistration>();
list.Registrations.AddRange(regs);
if (list.Registrations == null)
{
var regs = StringsToRegs(list.Components);
list.Registrations = new List<ComponentRegistration>();
list.Registrations.AddRange(regs);
}
}

if (list.MindRoles != null)
Expand Down

0 comments on commit 77a4cda

Please sign in to comment.