IngestionEvents.cs 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. namespace Content.Shared.Nutrition;
  2. /// <summary>
  3. /// Raised directed at the consumer when attempting to ingest something.
  4. /// </summary>
  5. public sealed class IngestionAttemptEvent : CancellableEntityEventArgs
  6. {
  7. /// <summary>
  8. /// The equipment that is blocking consumption. Should only be non-null if the event was canceled.
  9. /// </summary>
  10. public EntityUid? Blocker = null;
  11. }
  12. /// <summary>
  13. /// Raised directed at the food after finishing eating a food before it's deleted.
  14. /// Cancel this if you want to do something special before a food is deleted.
  15. /// </summary>
  16. public sealed class BeforeFullyEatenEvent : CancellableEntityEventArgs
  17. {
  18. /// <summary>
  19. /// The person that ate the food.
  20. /// </summary>
  21. public EntityUid User;
  22. }
  23. /// <summary>
  24. /// Raised directed at the food being sliced before it's deleted.
  25. /// Cancel this if you want to do something special before a food is deleted.
  26. /// </summary>
  27. public sealed class BeforeFullySlicedEvent : CancellableEntityEventArgs
  28. {
  29. /// <summary>
  30. /// The person slicing the food.
  31. /// </summary>
  32. public EntityUid User;
  33. }