Viewport improvements (#3765)

This commit is contained in:
Pieter-Jan Briers
2021-04-19 09:52:40 +02:00
committed by GitHub
parent 8e2fc49357
commit 147a54c642
40 changed files with 1173 additions and 418 deletions

View File

@@ -25,9 +25,9 @@ namespace Content.Client.Atmos
_gasTileOverlaySystem = EntitySystem.Get<GasTileOverlaySystem>();
}
protected override void Draw(DrawingHandleBase handle, OverlaySpace overlay)
protected override void Draw(in OverlayDrawArgs args)
{
var drawHandle = (DrawingHandleWorld) handle;
var drawHandle = args.WorldHandle;
var mapId = _eyeManager.CurrentMap;
var eye = _eyeManager.CurrentEye;
@@ -41,7 +41,7 @@ namespace Content.Client.Atmos
continue;
var gridBounds = new Box2(mapGrid.WorldToLocal(worldBounds.BottomLeft), mapGrid.WorldToLocal(worldBounds.TopRight));
foreach (var tile in mapGrid.GetTilesIntersecting(gridBounds))
{
foreach (var (texture, color) in _gasTileOverlaySystem.GetOverlays(mapGrid.Index, tile.GridIndices))