mirror of
https://github.com/space-wizards/space-station-14.git
synced 2026-02-15 03:31:30 +01:00
* feat: TriggerOn(Un)Embed * feat: StopEmbedEvent * fix: forgot initialize * chore: better naming * chore: oops * Update Content.Shared/Trigger/Components/Triggers/TriggerOnUnembedComponent.cs Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com> * Update Content.Shared/Projectiles/EmbedEvents.cs Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com> * review im lazy Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com> * Update Content.Shared/Trigger/Components/Triggers/TriggerOnEmbedComponent.cs * chore: docs * comment change --------- Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com> Co-authored-by: iaada <iaada@users.noreply.github.com>
21 lines
803 B
C#
21 lines
803 B
C#
using Content.Shared.Trigger.Systems;
|
|
using Robust.Shared.GameStates;
|
|
|
|
namespace Content.Shared.Trigger.Components.Triggers;
|
|
|
|
/// <summary>
|
|
/// Triggers when this entity gets un-embedded from something.
|
|
/// User is the item that was embedded or the actual embed depending on <see cref="UserIsEmbed"/>
|
|
/// Handled by <seealso cref="TriggerOnEmbedSystem"/>
|
|
/// </summary>
|
|
[RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
|
|
public sealed partial class TriggerOnUnembedComponent : BaseTriggerOnXComponent
|
|
{
|
|
/// <summary>
|
|
/// If false the trigger user will be the one that detaches the embedded entity.
|
|
/// If true, the trigger user will be the entity the projectile was embedded into.
|
|
/// </summary>
|
|
[DataField, AutoNetworkedField]
|
|
public bool UserIsEmbeddedInto;
|
|
}
|