Only render shroud/ore that is in the current viewport

This commit is contained in:
Paul Chote
2010-09-19 18:33:47 +12:00
parent fef291a27e
commit 23da8a24bd
3 changed files with 12 additions and 1 deletions

View File

@@ -29,6 +29,8 @@ namespace OpenRA.Traits
var cliprect = Game.viewport.ShroudBounds().HasValue
? Rectangle.Intersect(Game.viewport.ShroudBounds().Value, world.Map.Bounds) : world.Map.Bounds;
cliprect = Rectangle.Intersect(Game.viewport.ViewBounds(), cliprect);
var minx = cliprect.Left;
var maxx = cliprect.Right;