2021-09-13 11:58:44 +02:00
|
|
|
|
using System;
|
|
|
|
|
|
using Content.Shared.Tabletop.Components;
|
|
|
|
|
|
using Robust.Shared.GameObjects;
|
|
|
|
|
|
using Robust.Shared.Map;
|
|
|
|
|
|
using Robust.Shared.Serialization;
|
|
|
|
|
|
|
|
|
|
|
|
namespace Content.Shared.Tabletop.Events
|
|
|
|
|
|
{
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// An event that is sent to the server every so often by the client to tell where an entity with a
|
|
|
|
|
|
/// <see cref="SharedTabletopDraggableComponent"/> has been moved.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
[Serializable, NetSerializable]
|
2022-02-16 00:23:23 -07:00
|
|
|
|
public sealed class TabletopMoveEvent : EntityEventArgs
|
2021-09-13 11:58:44 +02:00
|
|
|
|
{
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// The UID of the entity being moved.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
public EntityUid MovedEntityUid { get; }
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// The new coordinates of the entity being moved.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
public MapCoordinates Coordinates { get; }
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// The UID of the table the entity is being moved on.
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
public EntityUid TableUid { get; }
|
|
|
|
|
|
|
|
|
|
|
|
public TabletopMoveEvent(EntityUid movedEntityUid, MapCoordinates coordinates, EntityUid tableUid)
|
|
|
|
|
|
{
|
|
|
|
|
|
MovedEntityUid = movedEntityUid;
|
|
|
|
|
|
Coordinates = coordinates;
|
|
|
|
|
|
TableUid = tableUid;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|