Added HitAnimPalette trait to LaserZap projectile, LaserZap HitAnim can now use other palettes than the default effect palette.

This commit is contained in:
reaperrr
2014-01-06 18:14:19 +01:00
parent 26013c21f9
commit 0763fc0167

View File

@@ -27,6 +27,7 @@ namespace OpenRA.Mods.RA.Effects
public readonly Color Color = Color.Red;
[Desc("Impact animation. Requires a regular animation with idle: sequence instead of explosion special case.")]
public readonly string HitAnim = null;
public readonly string HitAnimPalette = "effect";
public IEffect Create(ProjectileArgs args)
{
@@ -88,7 +89,7 @@ namespace OpenRA.Mods.RA.Effects
}
if (hitanim != null)
foreach (var r in hitanim.Render(target, wr.Palette("effect")))
foreach (var r in hitanim.Render(target, wr.Palette(info.HitAnimPalette)))
yield return r;
}
}