Fix explosion overlay bounds (#11074)
This commit is contained in:
@@ -74,7 +74,7 @@ public sealed class ExplosionOverlay : Overlay
|
||||
var xform = xforms.GetComponent(grid.GridEntityId);
|
||||
var (_, _, worldMatrix, invWorldMatrix) = xform.GetWorldPositionRotationMatrixWithInv(xforms);
|
||||
|
||||
gridBounds = invWorldMatrix.TransformBox(worldBounds);
|
||||
gridBounds = invWorldMatrix.TransformBox(worldBounds).Enlarged(grid.TileSize * 2);
|
||||
drawHandle.SetTransform(worldMatrix);
|
||||
|
||||
DrawTiles(drawHandle, gridBounds, index, tiles, exp, grid.TileSize);
|
||||
@@ -83,7 +83,7 @@ public sealed class ExplosionOverlay : Overlay
|
||||
if (exp.SpaceTiles == null)
|
||||
return;
|
||||
|
||||
gridBounds = Matrix3.Invert(exp.SpaceMatrix).TransformBox(worldBounds);
|
||||
gridBounds = Matrix3.Invert(exp.SpaceMatrix).TransformBox(worldBounds).Enlarged(2);
|
||||
drawHandle.SetTransform(exp.SpaceMatrix);
|
||||
|
||||
DrawTiles(drawHandle, gridBounds, index, exp.SpaceTiles, exp, exp.SpaceTileSize);
|
||||
|
||||
Reference in New Issue
Block a user