mirror of
https://github.com/corvax-team/ss14-wl.git
synced 2026-02-15 03:31:38 +01:00
Clothing equipping doAfter tweak (#41732)
* clothing moving break * Rename EquipOnMoving to EquipWhileMoving * Update InventorySystem.Equip.cs
This commit is contained in:
@@ -87,6 +87,15 @@ public sealed partial class ClothingComponent : Component
|
||||
[DataField]
|
||||
public TimeSpan UnequipDelay = TimeSpan.Zero;
|
||||
|
||||
/// <summary>
|
||||
/// Only works when EquipDelay or UnequipDelay > 0.
|
||||
/// Prevents clothing from being put on or taken off while moving.
|
||||
/// Some clothing can logically be put on while running (hats),
|
||||
/// while other types of clothing may require stopping (shoes, hard suits).
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public bool EquipWhileMoving = false;
|
||||
|
||||
/// <summary>
|
||||
/// Offset for the strip time for an entity with this component.
|
||||
/// Only applied when it is being equipped or removed by another player.
|
||||
@@ -97,7 +106,6 @@ public sealed partial class ClothingComponent : Component
|
||||
/// <summary>
|
||||
/// A scale applied to all layers.
|
||||
/// </summary>
|
||||
///
|
||||
[DataField]
|
||||
public Vector2 Scale = Vector2.One;
|
||||
}
|
||||
|
||||
@@ -168,7 +168,7 @@ public abstract partial class InventorySystem
|
||||
target,
|
||||
itemUid)
|
||||
{
|
||||
BreakOnMove = true,
|
||||
BreakOnMove = !clothing.EquipWhileMoving,
|
||||
NeedHand = true,
|
||||
};
|
||||
|
||||
@@ -439,7 +439,7 @@ public abstract partial class InventorySystem
|
||||
target,
|
||||
removedItem.Value)
|
||||
{
|
||||
BreakOnMove = true,
|
||||
BreakOnMove = !clothing.EquipWhileMoving,
|
||||
NeedHand = true,
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user