Remove Explicit GridId References (#8315)
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
This commit is contained in:
@@ -79,7 +79,7 @@ namespace Content.Shared.SubFloor
|
||||
if (args.NewTile.Tile.IsEmpty)
|
||||
return; // Anything that was here will be unanchored anyways.
|
||||
|
||||
UpdateTile(MapManager.GetGrid(args.NewTile.GridIndex), args.NewTile.GridIndices);
|
||||
UpdateTile(MapManager.GetGrid(args.NewTile.GridUid), args.NewTile.GridIndices);
|
||||
}
|
||||
|
||||
private void OnGridChanged(GridModifiedEvent args)
|
||||
@@ -98,7 +98,7 @@ namespace Content.Shared.SubFloor
|
||||
if (!Resolve(uid, ref component, ref xform))
|
||||
return;
|
||||
|
||||
if (xform.Anchored && MapManager.TryGetGrid(xform.GridID, out var grid))
|
||||
if (xform.Anchored && MapManager.TryGetGrid(xform.GridEntityId, out var grid))
|
||||
component.IsUnderCover = HasFloorCover(grid, grid.TileIndicesFor(xform.Coordinates));
|
||||
else
|
||||
component.IsUnderCover = false;
|
||||
|
||||
@@ -208,7 +208,7 @@ public sealed class TrayScannerSystem : EntitySystem
|
||||
|
||||
// For now, limiting to the scanner's own grid. We could do a grid-lookup, but then what do we do if one grid
|
||||
// flies away, while the scanner's local-position remains unchanged?
|
||||
if (_mapManager.TryGetGrid(transform.GridID, out var grid))
|
||||
if (_mapManager.TryGetGrid(transform.GridEntityId, out var grid))
|
||||
{
|
||||
foreach (var entity in grid.GetAnchoredEntities(worldBox))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user