Remove most usages of obsolete TransformComponent methods (#19571)

This commit is contained in:
Visne
2023-08-30 04:05:19 +02:00
committed by GitHub
parent 3ba60835ec
commit 1416942bea
91 changed files with 312 additions and 221 deletions

View File

@@ -593,7 +593,7 @@ namespace Content.Shared.Interaction
fixtureB.FixtureCount > 0 &&
TryComp<TransformComponent>(origin, out var xformA))
{
var (worldPosA, worldRotA) = xformA.GetWorldPositionRotation();
var (worldPosA, worldRotA) = _transform.GetWorldPositionRotation(xformA);
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();
var (position, rotation) = _transform.GetWorldPositionRotation(transform);
var mapPos = new MapCoordinates(position, transform.MapID);
var combinedPredicate = GetPredicate(origin, target, mapPos, rotation, collisionMask, predicate);