mirror of
https://github.com/space-wizards/RobustToolbox.git
synced 2026-09-15 14:52:35 +02:00
31 lines
922 B
C#
31 lines
922 B
C#
namespace Robust.Shared.GameObjects
|
|
{
|
|
/// <summary>
|
|
/// Raised when an entity parent is changed.
|
|
/// </summary>
|
|
[ByRefEvent]
|
|
public readonly struct EntParentChangedMessage
|
|
{
|
|
/// <summary>
|
|
/// Entity that was adopted. The transform component has a property with the new parent.
|
|
/// </summary>
|
|
public EntityUid Entity { get; }
|
|
|
|
/// <summary>
|
|
/// Old parent that abandoned the Entity.
|
|
/// </summary>
|
|
public EntityUid? OldParent { get; }
|
|
|
|
/// <summary>
|
|
/// Creates a new instance of <see cref="EntParentChangedMessage"/>.
|
|
/// </summary>
|
|
/// <param name="entity"></param>
|
|
/// <param name="oldParent"></param>
|
|
public EntParentChangedMessage(EntityUid entity, EntityUid? oldParent)
|
|
{
|
|
Entity = entity;
|
|
OldParent = oldParent;
|
|
}
|
|
}
|
|
}
|