Un-hardcode production audio

This commit is contained in:
Paul Chote
2010-01-31 21:22:31 +13:00
parent 1038a9a7e8
commit ca8acee224
4 changed files with 29 additions and 8 deletions

View File

@@ -32,7 +32,8 @@ namespace OpenRa.Orders
if (!world.CanPlaceBuilding( Building, BuildingInfo, topLeft, null)
|| !world.IsCloseEnoughToBase(Producer.Owner, Building, BuildingInfo, topLeft))
{
Sound.Play("nodeply1.aud");
var queueInfo = world.LocalPlayer.PlayerActor.Info.Traits.Get<ProductionQueueInfo>();
Sound.Play(queueInfo.BuildingCannotPlaceAudio);
yield break;
}