Revert "Remove most usages of obsolete TransformComponent methods (#1… (#19714)
This commit is contained in:
@@ -85,7 +85,7 @@ namespace Content.Shared.Interaction
|
||||
if (!Resolve(user, ref xform))
|
||||
return false;
|
||||
|
||||
_transform.SetWorldRotation(xform, diffAngle);
|
||||
xform.WorldRotation = diffAngle;
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -101,7 +101,7 @@ namespace Content.Shared.Interaction
|
||||
// (Since the user being buckled to it holds it down with their weight.)
|
||||
// This is logically equivalent to RotateWhileAnchored.
|
||||
// Barstools and office chairs have independent wheels, while regular chairs don't.
|
||||
_transform.SetWorldRotation(suid.Value, diffAngle);
|
||||
Transform(rotatable.Owner).WorldRotation = diffAngle;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -593,7 +593,7 @@ namespace Content.Shared.Interaction
|
||||
fixtureB.FixtureCount > 0 &&
|
||||
TryComp<TransformComponent>(origin, out var xformA))
|
||||
{
|
||||
var (worldPosA, worldRotA) = _transform.GetWorldPositionRotation(xformA);
|
||||
var (worldPosA, worldRotA) = xformA.GetWorldPositionRotation();
|
||||
var xfA = new Transform(worldPosA, worldRotA);
|
||||
var parentRotB = _transform.GetWorldRotation(otherCoordinates.EntityId);
|
||||
var xfB = new Transform(targetPos.Position, parentRotB + otherAngle);
|
||||
@@ -659,7 +659,7 @@ namespace Content.Shared.Interaction
|
||||
Ignored? predicate = null)
|
||||
{
|
||||
var transform = Transform(target);
|
||||
var (position, rotation) = _transform.GetWorldPositionRotation(transform);
|
||||
var (position, rotation) = transform.GetWorldPositionRotation();
|
||||
var mapPos = new MapCoordinates(position, transform.MapID);
|
||||
var combinedPredicate = GetPredicate(origin, target, mapPos, rotation, collisionMask, predicate);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user