Pass WorldRenderer to IRenderModifiers and replace more palette lookups.
This commit is contained in:
@@ -243,7 +243,7 @@ namespace OpenRA.Mods.RA
|
||||
{
|
||||
if (manager.self.Owner.Shroud.IsTargetable(unit)) {
|
||||
var targetCell = unit.Location + (xy - sourceLocation);
|
||||
foreach (var r in unit.Render())
|
||||
foreach (var r in unit.Render(wr))
|
||||
r.Sprite.DrawAt(r.Pos - Traits.Util.CenterOfCell(unit.Location).ToFloat2() + Traits.Util.CenterOfCell(targetCell).ToFloat2(),
|
||||
r.Palette.RowIndex(wr),
|
||||
r.Scale*r.Sprite.size);
|
||||
|
||||
Reference in New Issue
Block a user