Predict inventory slot interactions. (#6033)
This commit is contained in:
@@ -1,26 +0,0 @@
|
||||
using System;
|
||||
using Robust.Shared.GameObjects;
|
||||
using Robust.Shared.Serialization;
|
||||
|
||||
namespace Content.Shared.Inventory.Events;
|
||||
|
||||
[NetSerializable, Serializable]
|
||||
public class TryEquipNetworkMessage : EntityEventArgs
|
||||
{
|
||||
public readonly EntityUid Actor;
|
||||
public readonly EntityUid Target;
|
||||
public readonly EntityUid ItemUid;
|
||||
public readonly string Slot;
|
||||
public readonly bool Silent;
|
||||
public readonly bool Force;
|
||||
|
||||
public TryEquipNetworkMessage(EntityUid actor, EntityUid target, EntityUid itemUid, string slot, bool silent, bool force)
|
||||
{
|
||||
Actor = actor;
|
||||
Target = target;
|
||||
ItemUid = itemUid;
|
||||
Slot = slot;
|
||||
Silent = silent;
|
||||
Force = force;
|
||||
}
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
using System;
|
||||
using Robust.Shared.GameObjects;
|
||||
using Robust.Shared.Serialization;
|
||||
|
||||
namespace Content.Shared.Inventory.Events;
|
||||
|
||||
[NetSerializable, Serializable]
|
||||
public class TryUnequipNetworkMessage : EntityEventArgs
|
||||
{
|
||||
public readonly EntityUid Actor;
|
||||
public readonly EntityUid Target;
|
||||
public readonly string Slot;
|
||||
public readonly bool Silent;
|
||||
public readonly bool Force;
|
||||
|
||||
public TryUnequipNetworkMessage(EntityUid actor, EntityUid target, string slot, bool silent, bool force)
|
||||
{
|
||||
Actor = actor;
|
||||
Target = target;
|
||||
Slot = slot;
|
||||
Silent = silent;
|
||||
Force = force;
|
||||
}
|
||||
}
|
||||
@@ -7,12 +7,12 @@ namespace Content.Shared.Inventory.Events;
|
||||
[NetSerializable, Serializable]
|
||||
public class UseSlotNetworkMessage : EntityEventArgs
|
||||
{
|
||||
public readonly EntityUid Uid;
|
||||
// The slot-owner is implicitly the client that is sending this message.
|
||||
// Otherwise clients could start forcefully undressing other clients.
|
||||
public readonly string Slot;
|
||||
|
||||
public UseSlotNetworkMessage(EntityUid uid, string slot)
|
||||
public UseSlotNetworkMessage(string slot)
|
||||
{
|
||||
Uid = uid;
|
||||
Slot = slot;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user