Remove transform methods from mapgrid (#12233)

This commit is contained in:
metalgearsloth
2022-11-01 11:27:18 +11:00
committed by GitHub
parent 297686c4ff
commit c9a2ab1cee
25 changed files with 144 additions and 78 deletions

View File

@@ -90,9 +90,12 @@ public sealed partial class ShuttleSystem
reason = null;
if (!TryComp<IMapGridComponent>(uid, out var grid) ||
!Resolve(uid.Value, ref xform)) return true;
!Resolve(uid.Value, ref xform))
{
return true;
}
var bounds = grid.Grid.WorldAABB.Enlarged(ShuttleFTLRange);
var bounds = xform.WorldMatrix.TransformBox(grid.Grid.LocalAABB).Enlarged(ShuttleFTLRange);
var bodyQuery = GetEntityQuery<PhysicsComponent>();
foreach (var other in _mapManager.FindGridsIntersecting(xform.MapID, bounds))