exposed GetDamageState(); fixed TSLA anim to use it

This commit is contained in:
Chris Forbes
2009-12-31 13:11:00 +13:00
parent b1f7aea1ca
commit c11c4eb4a0
4 changed files with 5 additions and 8 deletions

View File

@@ -15,9 +15,9 @@ namespace OpenRa.Game.Traits
public void Attacking(Actor self)
{
var prev = anim.CurrentSequence.Name;
var prefix = self.GetDamageState() == DamageState.Half ? "damaged-" : "";
Sound.Play("tslachg2.aud");
anim.PlayThen("active", () => anim.PlayRepeating(prev));
anim.PlayThen(prefix + "active", () => anim.PlayRepeating(prefix + "idle"));
}
}
}