Redundant adjacent update
This commit is contained in:
@@ -185,6 +185,8 @@ namespace Content.Server.GameObjects.Components.Atmos
|
|||||||
{
|
{
|
||||||
if(!Tiles.ContainsKey(tile.GridIndices))
|
if(!Tiles.ContainsKey(tile.GridIndices))
|
||||||
Tiles.Add(tile.GridIndices, new TileAtmosphere(this, tile.GridIndex, tile.GridIndices, new GasMixture(GetVolumeForCells(1)){Temperature = Atmospherics.T20C}));
|
Tiles.Add(tile.GridIndices, new TileAtmosphere(this, tile.GridIndex, tile.GridIndices, new GasMixture(GetVolumeForCells(1)){Temperature = Atmospherics.T20C}));
|
||||||
|
|
||||||
|
Invalidate(tile.GridIndices);
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach (var (_, tile) in Tiles.ToArray())
|
foreach (var (_, tile) in Tiles.ToArray())
|
||||||
@@ -246,7 +248,6 @@ namespace Content.Server.GameObjects.Components.Atmos
|
|||||||
var otherIndices = indices.Offset(direction.ToDirection());
|
var otherIndices = indices.Offset(direction.ToDirection());
|
||||||
var otherTile = GetTile(otherIndices);
|
var otherTile = GetTile(otherIndices);
|
||||||
AddActiveTile(otherTile);
|
AddActiveTile(otherTile);
|
||||||
otherTile?.UpdateAdjacent(direction.GetOpposite());
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user