Blindness refactor (#15705)
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
This commit is contained in:
@@ -1,27 +1,28 @@
|
||||
using Content.Shared.Chemistry.Reagent;
|
||||
using Content.Shared.Eye.Blinding;
|
||||
using Content.Shared.Eye.Blinding.Systems;
|
||||
using JetBrains.Annotations;
|
||||
|
||||
namespace Content.Server.Chemistry.ReagentEffects
|
||||
{
|
||||
/// <summary>
|
||||
/// Heal eye damage (or deal)
|
||||
/// Heal or apply eye damage
|
||||
/// </summary>
|
||||
[UsedImplicitly]
|
||||
public sealed class ChemHealEyeDamage : ReagentEffect
|
||||
{
|
||||
/// <summary>
|
||||
/// How much eye damage to remove.
|
||||
/// How much eye damage to add.
|
||||
/// </summary>
|
||||
[DataField("amount")]
|
||||
public int Amount = -1;
|
||||
|
||||
public override void Effect(ReagentEffectArgs args)
|
||||
{
|
||||
if (args.Scale != 1f)
|
||||
if (args.Scale != 1f) // huh?
|
||||
return;
|
||||
|
||||
args.EntityManager.EntitySysManager.GetEntitySystem<SharedBlindingSystem>().AdjustEyeDamage(args.SolutionEntity, Amount);
|
||||
args.EntityManager.EntitySysManager.GetEntitySystem<BlindableSystem>().AdjustEyeDamage(args.SolutionEntity, Amount);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user