PlantAdjustMutationMod.cs 557 B

12345678910111213141516171819
  1. using Content.Shared.EntityEffects;
  2. using JetBrains.Annotations;
  3. namespace Content.Server.EntityEffects.Effects.PlantMetabolism;
  4. [UsedImplicitly]
  5. public sealed partial class PlantAdjustMutationMod : PlantAdjustAttribute
  6. {
  7. public override string GuidebookAttributeName { get; set; } = "plant-attribute-mutation-mod";
  8. public override void Effect(EntityEffectBaseArgs args)
  9. {
  10. if (!CanMetabolize(args.TargetEntity, out var plantHolderComp, args.EntityManager))
  11. return;
  12. plantHolderComp.MutationMod += Amount;
  13. }
  14. }