Events.cs 983 B

123456789101112131415161718192021222324252627282930313233
  1. // SPDX-FileCopyrightText: 2024 Piras314 <p1r4s@proton.me>
  2. // SPDX-FileCopyrightText: 2024 gluesniffler <159397573+gluesniffler@users.noreply.github.com>
  3. // SPDX-FileCopyrightText: 2025 Aiden <28298836+Aidenkrz@users.noreply.github.com>
  4. //
  5. // SPDX-License-Identifier: AGPL-3.0-or-later
  6. using Robust.Shared.Serialization;
  7. namespace Content.Shared._Shitmed.Targeting.Events;
  8. [Serializable, NetSerializable]
  9. public sealed class TargetChangeEvent : EntityEventArgs
  10. {
  11. public NetEntity Uid { get; }
  12. public TargetBodyPart BodyPart { get; }
  13. public TargetChangeEvent(NetEntity uid, TargetBodyPart bodyPart)
  14. {
  15. Uid = uid;
  16. BodyPart = bodyPart;
  17. }
  18. }
  19. [Serializable, NetSerializable]
  20. public sealed class TargetIntegrityChangeEvent : EntityEventArgs
  21. {
  22. public NetEntity Uid { get; }
  23. public bool RefreshUi { get; }
  24. public TargetIntegrityChangeEvent(NetEntity uid, bool refreshUi = true)
  25. {
  26. Uid = uid;
  27. RefreshUi = refreshUi;
  28. }
  29. }