diff --git a/OpenRA.Mods.Common/Activities/RepairBuilding.cs b/OpenRA.Mods.Common/Activities/RepairBuilding.cs index 361c920012..4b90049510 100644 --- a/OpenRA.Mods.Common/Activities/RepairBuilding.cs +++ b/OpenRA.Mods.Common/Activities/RepairBuilding.cs @@ -63,6 +63,8 @@ namespace OpenRA.Mods.Common.Activities return; enterActor.InflictDamage(self, new Damage(-enterHealth.MaxHP)); + if (!string.IsNullOrEmpty(info.RepairSound)) + Game.Sound.Play(SoundType.World, info.RepairSound, enterActor.CenterPosition); if (info.EnterBehaviour == EnterBehaviour.Dispose) self.Dispose(); diff --git a/OpenRA.Mods.Common/Traits/EngineerRepair.cs b/OpenRA.Mods.Common/Traits/EngineerRepair.cs index 302464a6a2..1499758a93 100644 --- a/OpenRA.Mods.Common/Traits/EngineerRepair.cs +++ b/OpenRA.Mods.Common/Traits/EngineerRepair.cs @@ -29,6 +29,9 @@ namespace OpenRA.Mods.Common.Traits [Desc("What diplomatic stances allow target to be repaired by this actor.")] public readonly Stance ValidStances = Stance.Ally; + [Desc("Sound to play when repairing is done.")] + public readonly string RepairSound = null; + [Desc("Cursor to show when hovering over a valid actor to repair.")] public readonly string Cursor = "goldwrench";