Updated ContainerHelpers to use new extensions (#2530)
Co-authored-by: David Tan <>
This commit is contained in:
@@ -199,10 +199,10 @@ namespace Content.Server.GameObjects.Components.Buckle
|
||||
}
|
||||
|
||||
// If in a container
|
||||
if (ContainerHelpers.TryGetContainer(Owner, out var ownerContainer))
|
||||
if (Owner.TryGetContainer(out var ownerContainer))
|
||||
{
|
||||
// And not in the same container as the strap
|
||||
if (!ContainerHelpers.TryGetContainer(strap.Owner, out var strapContainer) ||
|
||||
if (!strap.Owner.TryGetContainer(out var strapContainer) ||
|
||||
ownerContainer != strapContainer)
|
||||
{
|
||||
return false;
|
||||
@@ -336,7 +336,7 @@ namespace Content.Server.GameObjects.Components.Buckle
|
||||
|
||||
if (Owner.Transform.Parent == oldBuckledTo.Owner.Transform)
|
||||
{
|
||||
ContainerHelpers.AttachParentToContainerOrGrid(Owner.Transform);
|
||||
Owner.Transform.AttachParentToContainerOrGrid();
|
||||
Owner.Transform.WorldRotation = oldBuckledTo.Owner.Transform.WorldRotation;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user