Files
tbd-station-14/Content.Server/Chemistry/ReagentEffects/CauseZombieInfection.cs
LankLTE 89ca105e7c Fixes Romerol & Corpium, Small Zombie Tweaks (#17784)
* Fixed romerol and corpium.

* Tweaked zombie values.

* Change guidebook descriptions.

* Fixed corpium, added reagent requirements.

* Readded zombie bundle to uplink.

* Edited description
2023-07-06 20:55:00 -06:00

24 lines
803 B
C#

using Content.Shared.Chemistry.Reagent;
using Robust.Shared.Prototypes;
using Robust.Shared.Configuration;
using Content.Server.Zombies;
namespace Content.Server.Chemistry.ReagentEffects;
public sealed class CauseZombieInfection : ReagentEffect
{
protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys)
=> Loc.GetString("reagent-effect-guidebook-cause-zombie-infection", ("chance", Probability));
// Adds the Zombie Infection Components
public override void Effect(ReagentEffectArgs args)
{
var entityManager = args.EntityManager;
entityManager.EnsureComponent<ZombifyOnDeathComponent>(args.SolutionEntity);
entityManager.EnsureComponent<PendingZombieComponent>(args.SolutionEntity);
}
}