+using Content.Shared.Body.Events;
using Content.Shared.Damage.Events;
using Content.Shared.Mobs.Events;
using Content.Shared.Movement.Events;
SubscribeLocalEvent<StatusEffectContainerComponent, BeforeAlertSeverityCheckEvent>(RelayStatusEffectEvent);
SubscribeLocalEvent<StatusEffectContainerComponent, AccentGetEvent>(RelayStatusEffectEvent);
+
+ SubscribeLocalEvent<StatusEffectContainerComponent, BleedModifierEvent>(RefRelayStatusEffectEvent);
}
private void RefRelayStatusEffectEvent<T>(EntityUid uid, StatusEffectContainerComponent component, ref T args) where T : struct
+++ /dev/null
-using Robust.Shared.GameStates;
-
-namespace Content.Shared.Traits.Assorted;
-
-/// <summary>
-/// This component is used for the Hemophilia Trait, it reduces the passive bleed stack reduction amount so entities with it bleed for longer.
-/// </summary>
-[RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
-public sealed partial class HemophiliaComponent : Component
-{
- /// <summary>
- /// What multiplier should be applied to the BleedReduction when an entity bleeds?
- /// </summary>
- [DataField, AutoNetworkedField]
- public float HemophiliaBleedReductionMultiplier = 0.33f;
-}
--- /dev/null
+using Robust.Shared.GameStates;
+
+namespace Content.Shared.Traits.Assorted;
+
+/// <summary>
+/// This component is used for the Hemophilia Trait, it reduces the passive bleed stack reduction amount so entities with it bleed for longer.
+/// </summary>
+[RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
+public sealed partial class HemophiliaStatusEffectComponent : Component
+{
+ /// <summary>
+ /// Multiplier to use for the amount of bloodloss reduction during a bleed tick.
+ /// </summary>
+ [DataField, AutoNetworkedField]
+ public float BleedReductionMultiplier = 0.33f;
+
+ /// <summary>
+ /// Multiplier to use for the amount of blood lost during a bleed tick.
+ /// </summary>
+ [DataField, AutoNetworkedField]
+ public float BleedAmountMultiplier = 1f;
+}
using Content.Shared.Body.Events;
+using Content.Shared.StatusEffectNew;
namespace Content.Shared.Traits.Assorted;
{
public override void Initialize()
{
- SubscribeLocalEvent<HemophiliaComponent, BleedModifierEvent>(OnBleedModifier);
+ SubscribeLocalEvent<HemophiliaStatusEffectComponent, StatusEffectRelayedEvent<BleedModifierEvent>>(OnBleedModifier);
}
- private void OnBleedModifier(Entity<HemophiliaComponent> ent, ref BleedModifierEvent args)
+ private void OnBleedModifier(Entity<HemophiliaStatusEffectComponent> ent, ref StatusEffectRelayedEvent<BleedModifierEvent> args)
{
- args.BleedReductionAmount *= ent.Comp.HemophiliaBleedReductionMultiplier;
+ var ev = args.Args;
+ ev.BleedReductionAmount *= ent.Comp.BleedReductionMultiplier;
+ ev.BleedAmount *= ent.Comp.BleedAmountMultiplier;
+ args.Args = ev;
}
}
reagent-name-haloperidol = haloperidol
reagent-desc-haloperidol = Removes most stimulating and hallucinogenic drugs. Reduces druggy effects and jitteriness. Causes drowsiness.
+
+reagent-name-warfarin = warfarin
+reagent-desc-warfarin = Commonly used as an anticoagulant medication. Causes blood to have difficulty forming clots. Can cause internal bleeding when overdosed.
reagent-physical-desc-neural = neural
reagent-physical-desc-unidentifiable = unidentifiable
reagent-physical-desc-non-newtonian = non-newtonian
+reagent-physical-desc-thin = thin
reagent-name-toxintrash = reprocessed material
reagent-desc-toxintrash = An awful-smelling slurry efficiently refined from discarded matter. It represents a perfect, zero-waste conversion of salvage into Vox sustenance, though it is a violent poison to others.
+
+reagent-name-hemorrhinol = hemorrhinol
+reagent-desc-hemorrhinol = A toxin that causes severe damage to blood vessels, causing rapid bleeding.
# traits
- BlackAndWhiteOverlay
- Clumsy
- - Hemophilia
- ImpairedMobility
# - LegsParalyzed (you get healed)
- LightweightDrunk
- Bloodstream
- type: entity
- parent: [ BloodstreamStatusEffectBase ]
+ parent: BloodstreamStatusEffectBase
+ id: BloodstreamStatusEffectDebuff
+ abstract: true
+ components:
+ - type: RejuvenateRemovedStatusEffect
+
+- type: entity
+ parent: BloodstreamStatusEffectDebuff
id: StatusEffectBloodloss
name: bloodloss
components:
- type: StutteringAccent
- type: DrunkStatusEffect
- - type: RejuvenateRemovedStatusEffect
- type: entity
parent: MobStatusEffectBase
- type: PainNumbnessStatusEffect
- type: entity
- parent: PainNumbnessTraitStatusEffect
+ parent: BloodstreamStatusEffectBase
+ id: StatusEffectHemophiliaTrait
+ components:
+ - type: HemophiliaStatusEffect
+
+- type: entity
+ parent: BloodstreamStatusEffectDebuff
+ id: StatusEffectAnticoagulant # Decreases the amount of blood coagulation when bleeding.
+ name: thin blood
+ components:
+ - type: HemophiliaStatusEffect
+ bleedReductionMultiplier: 0.33
+ bleedAmountMultiplier: 1
+
+- type: entity
+ parent: BloodstreamStatusEffectDebuff
+ id: StatusEffectHemorrhage # Increases the amount of blood lost when bleeding.
+ name: hemorrhage
+ components:
+ - type: HemophiliaStatusEffect
+ bleedReductionMultiplier: 1 # We don't want it to also reduce coagulation, it would stack with Anticoagulant.
+ bleedAmountMultiplier: 1.33
+
+- type: entity
+ parent: [ PainNumbnessTraitStatusEffect, MobStatusEffectDebuff ]
id: StatusEffectPainNumbness
+ name: pain numbness
- !type:AdjustReagent
reagent: MindbreakerToxin
amount: -3.0
+
+- type: reagent
+ id: Warfarin
+ name: reagent-name-warfarin
+ group: Medicine
+ desc: reagent-desc-warfarin
+ physicalDesc: reagent-physical-desc-thin
+ allowedDepartments:
+ - Medical
+ flavor: medicine
+ color: "#d0e21b"
+ metabolisms:
+ Medicine:
+ effects: # One day this could be useful for treating blood clots, if we get those
+ - !type:ModifyStatusEffect
+ effectProto: StatusEffectAnticoagulant
+ time: 30 # 10 bleed ticks, you bleed every 3 seconds by default.
+ type: Update
+ - !type:ModifyBleed
+ conditions:
+ - !type:ReagentCondition
+ reagent: Warfarin
+ min: 15
+ amount: 0.25
conditions:
- !type:MetabolizerTypeCondition
type: [Vox]
+
+- type: reagent
+ id: Hemorrhinol
+ name: reagent-name-hemorrhinol
+ group: Toxins
+ desc: reagent-desc-hemorrhinol
+ physicalDesc: reagent-physical-desc-thin
+ contrabandSeverity: Major
+ flavor: sharp
+ color: "#96424f"
+ metabolisms:
+ Poison:
+ effects:
+ - !type:ModifyStatusEffect
+ effectProto: StatusEffectHemorrhage
+ time: 21 # 7 bleed ticks, you bleed every 3 seconds by default.
+ type: Update
+ - !type:ModifyBleed
+ amount: 0.5
amount: 1
products:
Haloperidol: 5
+
+- type: reaction
+ id: Warfarin
+ reactants:
+ SulfuricAcid:
+ amount: 1
+ Nitrogen:
+ amount: 1
+ Sodium:
+ amount: 1
+ products:
+ Warfarin: 2
+
+- type: reaction
+ id: Hemorrhinol
+ reactants:
+ Warfarin:
+ amount: 2
+ Razorium:
+ amount: 2
+ Plasma:
+ amount: 1
+ products:
+ Hemorrhinol: 2
name: trait-hemophilia-name
description: trait-hemophilia-desc
category: Disabilities
- components:
- - type: Hemophilia
+ specials:
+ - !type:ApplyStatusEffectSpecial
+ statusEffects:
+ - StatusEffectHemophiliaTrait
- type: trait
id: ImpairedMobility