Zombies can no longer Suicide take 2 (#36453)

* I did it right

* Update Content.Server/Zombies/ZombieSystem.Transform.cs

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

---------

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
This commit is contained in:
Ethan_k
2025-04-10 18:12:13 -07:00
committed by GitHub
parent 55bc0058f4
commit 0977b74294

View File

@@ -63,7 +63,7 @@ public sealed partial class ZombieSystem
[Dependency] private readonly NameModifierSystem _nameMod = default!; [Dependency] private readonly NameModifierSystem _nameMod = default!;
private static readonly ProtoId<TagPrototype> InvalidForGlobalSpawnSpellTag = "InvalidForGlobalSpawnSpell"; private static readonly ProtoId<TagPrototype> InvalidForGlobalSpawnSpellTag = "InvalidForGlobalSpawnSpell";
private static readonly ProtoId<TagPrototype> CannotSuicideTag = "CannotSuicide";
/// <summary> /// <summary>
/// Handles an entity turning into a zombie when they die or go into crit /// Handles an entity turning into a zombie when they die or go into crit
/// </summary> /// </summary>
@@ -294,5 +294,6 @@ public sealed partial class ZombieSystem
//Need to prevent them from getting an item, they have no hands. //Need to prevent them from getting an item, they have no hands.
// Also prevents them from becoming a Survivor. They're undead. // Also prevents them from becoming a Survivor. They're undead.
_tag.AddTag(target, InvalidForGlobalSpawnSpellTag); _tag.AddTag(target, InvalidForGlobalSpawnSpellTag);
_tag.AddTag(target, CannotSuicideTag);
} }
} }