Prevent clients from setting their species to whatever they want (#25535) (#134)

Prevent epic hack

Co-authored-by: Debug <49997488+DebugOk@users.noreply.github.com>
This commit is contained in:
Nair Sark
2024-02-28 00:09:39 +05:00
committed by GitHub
parent 367fd53f80
commit 9776dd7f11

View File

@@ -504,7 +504,7 @@ namespace Content.Shared.Preferences
{
var prototypeManager = IoCManager.Resolve<IPrototypeManager>();
if (!prototypeManager.TryIndex<SpeciesPrototype>(Species, out var speciesPrototype))
if (!prototypeManager.TryIndex<SpeciesPrototype>(Species, out var speciesPrototype) || speciesPrototype.RoundStart == false)
{
Species = SharedHumanoidAppearanceSystem.DefaultSpecies;
speciesPrototype = prototypeManager.Index<SpeciesPrototype>(Species);