Introduce SoundType enum.

This commit is contained in:
Paul Chote
2016-12-10 17:38:44 +00:00
parent 28182ddc36
commit 9ddfdc45b3
48 changed files with 83 additions and 80 deletions

View File

@@ -53,7 +53,7 @@ namespace OpenRA.Mods.Common.Traits
public override void SelectTarget(Actor self, string order, SupportPowerManager manager)
{
Game.Sound.PlayToPlayer(manager.Self.Owner, Info.SelectTargetSound);
Game.Sound.PlayToPlayer(SoundType.World, manager.Self.Owner, Info.SelectTargetSound);
self.World.OrderGenerator = new SelectUpgradeTarget(Self.World, order, manager, this);
}
@@ -65,7 +65,7 @@ namespace OpenRA.Mods.Common.Traits
if (wsb != null && wsb.DefaultAnimation.HasSequence(info.Sequence))
wsb.PlayCustomAnimation(self, info.Sequence, () => wsb.CancelCustomAnimation(self));
Game.Sound.Play(info.OnFireSound, self.World.Map.CenterOfCell(order.TargetLocation));
Game.Sound.Play(SoundType.World, info.OnFireSound, self.World.Map.CenterOfCell(order.TargetLocation));
foreach (var a in UnitsInRange(order.TargetLocation))
{