Add Sound.Play overloads that play a random sound from a list
This commit is contained in:
@@ -94,7 +94,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
self.World.Add(projectile);
|
||||
|
||||
if (args.Weapon.Report != null && args.Weapon.Report.Any())
|
||||
Game.Sound.Play(SoundType.World, args.Weapon.Report.Random(self.World.SharedRandom), self.CenterPosition);
|
||||
Game.Sound.Play(SoundType.World, args.Weapon.Report, self.World, self.CenterPosition);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user