Account for damage state in ActorPreviews.

This commit is contained in:
Paul Chote
2015-04-03 20:50:47 +01:00
parent ef55cb6528
commit 09bad3f0ef
11 changed files with 39 additions and 10 deletions

View File

@@ -26,7 +26,7 @@ namespace OpenRA.Mods.Common.Traits
{
// Show a static frame instead of animating all of the wall states
var anim = new Animation(init.World, image, () => 0);
anim.PlayFetchIndex(Sequence, () => 0);
anim.PlayFetchIndex(RenderSprites.NormalizeSequence(anim, init.GetDamageState(), Sequence), () => 0);
yield return new SpriteActorPreview(anim, WVec.Zero, 0, p, rs.Scale);
}