SuicideEvent.cs 990 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. using Content.Shared.Damage;
  2. using Content.Shared.Damage.Prototypes;
  3. using Robust.Shared.Prototypes;
  4. namespace Content.Shared.Interaction.Events;
  5. /// <summary>
  6. /// Raised Directed at an entity to check whether they will handle the suicide.
  7. /// </summary>
  8. public sealed class SuicideEvent : HandledEntityEventArgs
  9. {
  10. public SuicideEvent(EntityUid victim)
  11. {
  12. Victim = victim;
  13. }
  14. public DamageSpecifier? DamageSpecifier;
  15. public ProtoId<DamageTypePrototype>? DamageType;
  16. public EntityUid Victim { get; private set; }
  17. }
  18. public sealed class SuicideByEnvironmentEvent : HandledEntityEventArgs
  19. {
  20. public SuicideByEnvironmentEvent(EntityUid victim)
  21. {
  22. Victim = victim;
  23. }
  24. public EntityUid Victim { get; set; }
  25. }
  26. public sealed class SuicideGhostEvent : HandledEntityEventArgs
  27. {
  28. public SuicideGhostEvent(EntityUid victim)
  29. {
  30. Victim = victim;
  31. }
  32. public EntityUid Victim { get; set; }
  33. public bool CanReturnToBody;
  34. }