Files
tbd-station-14/Content.Shared/Throwing/ThrowAttemptEvent.cs
DrSmugleaf 297baaca23 Add user to AttemptMeleeEvent, add ThrowItemAttemptEvent (#30193)
* Add user to AttemptMeleeEvent, add ThrowItemAttemptEvent

* Add xmldoc
2024-07-20 18:06:52 +10:00

29 lines
881 B
C#

namespace Content.Shared.Throwing
{
public sealed class ThrowAttemptEvent : CancellableEntityEventArgs
{
public ThrowAttemptEvent(EntityUid uid, EntityUid itemUid)
{
Uid = uid;
ItemUid = itemUid;
}
public EntityUid Uid { get; }
public EntityUid ItemUid { get; }
}
/// <summary>
/// Raised on the item entity that is thrown.
/// </summary>
/// <param name="User">The user that threw this entity.</param>
/// <param name="Cancelled">Whether or not the throw should be cancelled.</param>
[ByRefEvent]
public record struct ThrowItemAttemptEvent(EntityUid User, bool Cancelled = false);
/// <summary>
/// Raised when we try to pushback an entity from throwing
/// </summary>
public sealed class ThrowPushbackAttemptEvent : CancellableEntityEventArgs {}
}