Zombie Fixes and Tweaks (#9940)

This commit is contained in:
Nemanja
2022-07-26 20:35:34 -04:00
committed by GitHub
parent e795e5b5e1
commit 6276bda4f4
7 changed files with 47 additions and 19 deletions

View File

@@ -99,11 +99,14 @@ namespace Content.Server.Atmos.Miasma
EnsureComp<FliesComponent>(perishable.Owner);
DamageSpecifier damage = new();
damage.DamageDict.Add("Blunt", 0.3); // Slowly accumulate enough to gib after like half an hour
damage.DamageDict.Add("Cellular", 0.3); // Cloning rework might use this eventually
if (rotting.DealDamage)
{
DamageSpecifier damage = new();
damage.DamageDict.Add("Blunt", 0.3); // Slowly accumulate enough to gib after like half an hour
damage.DamageDict.Add("Cellular", 0.3); // Cloning rework might use this eventually
_damageableSystem.TryChangeDamage(perishable.Owner, damage, true, true);
_damageableSystem.TryChangeDamage(perishable.Owner, damage, true, true);
}
if (!TryComp<PhysicsComponent>(perishable.Owner, out var physics))
continue;

View File

@@ -5,5 +5,11 @@ namespace Content.Server.Atmos.Miasma
/// Tracking component for stuff that has started to rot.
/// </summary>
public sealed class RottingComponent : Component
{}
{
/// <summary>
/// Whether or not the rotting should deal damage
/// </summary>
[ViewVariables(VVAccess.ReadWrite)]
public bool DealDamage = true;
}
}