Files
tbd-station-14/Content.Shared/Zombies/ZombieComponent.cs
Tom Leys 878272ecf3 Zombie disease is easier to spread and deadly in minutes. Zombies heal over time. (#16235)
* Nerf Space zombies, get DoT in space (barotrauma) and spawn stunned.

- Also discard any helmet or mask you might be wearing.

* Zombies have heal over time, infection far more fatal

- Stun time reduced to 2 seconds

* Zombification occurs after you die, rather than after you crit.

- Zombies cannot inflict Zombification DoT on other zombies.

* Heal shock damage, space zombies are back.

* Lower the chance of infection per hit

* Removed the stun, reduced zombification virus slightly
2023-05-08 22:24:40 -04:00

109 lines
3.9 KiB
C#

using Content.Shared.Chat.Prototypes;
using Content.Shared.Damage;
using Content.Shared.Roles;
using Content.Shared.Humanoid;
using Robust.Shared.GameStates;
using Robust.Shared.Prototypes;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype;
using static Content.Shared.Humanoid.HumanoidAppearanceState;
namespace Content.Shared.Zombies
{
[RegisterComponent, NetworkedComponent]
public sealed class ZombieComponent : Component
{
/// <summary>
/// The coefficient of the damage reduction applied when a zombie
/// attacks another zombie. longe name
/// </summary>
[ViewVariables]
public float OtherZombieDamageCoefficient = 0.25f;
/// <summary>
/// The baseline infection chance you have if you are completely nude
/// </summary>
[ViewVariables(VVAccess.ReadWrite)]
public float MaxZombieInfectionChance = 0.40f;
/// <summary>
/// The minimum infection chance possible. This is simply to prevent
/// being invincible by bundling up.
/// </summary>
[ViewVariables(VVAccess.ReadWrite)]
public float MinZombieInfectionChance = 0.10f;
[ViewVariables(VVAccess.ReadWrite)]
public float ZombieMovementSpeedDebuff = 0.75f;
/// <summary>
/// The skin color of the zombie
/// </summary>
[DataField("skinColor")]
public Color SkinColor = new(0.45f, 0.51f, 0.29f);
/// <summary>
/// The eye color of the zombie
/// </summary>
[DataField("eyeColor")]
public Color EyeColor = new(0.96f, 0.13f, 0.24f);
/// <summary>
/// The base layer to apply to any 'external' humanoid layers upon zombification.
/// </summary>
[DataField("baseLayerExternal")]
public string BaseLayerExternal = "MobHumanoidMarkingMatchSkin";
/// <summary>
/// The attack arc of the zombie
/// </summary>
[DataField("attackArc", customTypeSerializer: typeof(PrototypeIdSerializer<EntityPrototype>))]
public string AttackAnimation = "WeaponArcBite";
/// <summary>
/// The role prototype of the zombie antag role
/// </summary>
[DataField("zombieRoleId", customTypeSerializer: typeof(PrototypeIdSerializer<AntagPrototype>))]
public readonly string ZombieRoleId = "Zombie";
/// <summary>
/// The EntityName of the humanoid to restore in case of cloning
/// </summary>
[DataField("beforeZombifiedEntityName"), ViewVariables(VVAccess.ReadOnly)]
public string BeforeZombifiedEntityName = String.Empty;
/// <summary>
/// The CustomBaseLayers of the humanoid to restore in case of cloning
/// </summary>
[DataField("beforeZombifiedCustomBaseLayers")]
public Dictionary<HumanoidVisualLayers, CustomBaseLayerInfo> BeforeZombifiedCustomBaseLayers = new ();
/// <summary>
/// The skin color of the humanoid to restore in case of cloning
/// </summary>
[DataField("beforeZombifiedSkinColor")]
public Color BeforeZombifiedSkinColor;
[DataField("emoteId", customTypeSerializer: typeof(PrototypeIdSerializer<EmoteSoundsPrototype>))]
public string? EmoteSoundsId = "Zombie";
public EmoteSoundsPrototype? EmoteSounds;
// Heal on tick
[DataField("nextTick", customTypeSerializer:typeof(TimeOffsetSerializer))]
public TimeSpan NextTick;
[DataField("damage")] public DamageSpecifier Damage = new()
{
DamageDict = new ()
{
{ "Blunt", -0.3 },
{ "Slash", -0.2 },
{ "Heat", -0.2 },
{ "Cold", -0.2 },
{ "Shock", -0.2 },
}
};
}
}