Replace dynamic Actor.Bounds with the (unchanging) relative rect.

This commit is contained in:
Paul Chote
2013-09-21 17:15:46 +12:00
parent 3f8d75a1ac
commit ad44610e5a
6 changed files with 77 additions and 78 deletions

View File

@@ -117,9 +117,12 @@ namespace OpenRA.Mods.RA
if (self.World.FogObscures(self))
yield break;
var pos = wr.ScreenPxPosition(self.CenterPosition);
var bounds = self.Bounds.Value;
var pos = new PPos(bounds.Right, bounds.Bottom - 2).ToWPos(0);
yield return new SpriteRenderable(RankAnim.Image, pos, WVec.Zero, 0, wr.Palette("effect"), 1f, true);
bounds.Offset(pos.X, pos.Y);
var effectPos = new PPos(bounds.Right, bounds.Bottom - 2).ToWPos(0);
yield return new SpriteRenderable(RankAnim.Image, effectPos, WVec.Zero, 0, wr.Palette("effect"), 1f, true);
}
}