From c8bc81903434dd4ea5d63f6ecbad13a9b12c9988 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 19 Jun 2016 18:43:27 +0200 Subject: [PATCH 01/10] Disable the trait instead of nulling the fields. --- mods/ts/rules/gdi-support.yaml | 4 +--- mods/ts/rules/nod-support.yaml | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/mods/ts/rules/gdi-support.yaml b/mods/ts/rules/gdi-support.yaml index bfe111b303..6def61f38b 100644 --- a/mods/ts/rules/gdi-support.yaml +++ b/mods/ts/rules/gdi-support.yaml @@ -4,9 +4,7 @@ GAWALL: Queue: Defense BuildPaletteOrder: 20 Prerequisites: ~structures.gdi - SoundOnDamageTransition: - DamagedSounds: - DestroyedSounds: + -SoundOnDamageTransition: Valued: Cost: 50 CustomSellValue: diff --git a/mods/ts/rules/nod-support.yaml b/mods/ts/rules/nod-support.yaml index 9ddc79e748..23e3493617 100644 --- a/mods/ts/rules/nod-support.yaml +++ b/mods/ts/rules/nod-support.yaml @@ -4,9 +4,7 @@ NAWALL: Queue: Defense BuildPaletteOrder: 1001 Prerequisites: ~structures.nod - SoundOnDamageTransition: - DamagedSounds: - DestroyedSounds: + -SoundOnDamageTransition: Valued: Cost: 50 CustomSellValue: From 4c3ff461d4a264a3dd24e245df8a704165db42b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 19 Jun 2016 18:43:42 +0200 Subject: [PATCH 02/10] Add a missing space. --- mods/d2k/audio/notifications.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mods/d2k/audio/notifications.yaml b/mods/d2k/audio/notifications.yaml index fe65053390..8253e86793 100644 --- a/mods/d2k/audio/notifications.yaml +++ b/mods/d2k/audio/notifications.yaml @@ -63,7 +63,7 @@ Sounds: DisablePower: POWRUP1 EnablePower: POWRDN1 CashTickUp: CASHTIK1 - CashTickDown:CASHTIK1 + CashTickDown: CASHTIK1 LevelUp: SCORTIK1 ChatLine: CHAT1 BuildPaletteOpen: BUTTON1 From 409fe9067ac93b47e5bbf38fe2d8d91f6122caf2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 19 Jun 2016 18:44:53 +0200 Subject: [PATCH 03/10] Add speech notification equivalents to support power sounds. --- .../Traits/SupportPowers/AirstrikePower.cs | 2 ++ OpenRA.Mods.Common/Traits/SupportPowers/NukePower.cs | 4 ++++ .../Traits/SupportPowers/SupportPower.cs | 10 ++++++++++ 3 files changed, 16 insertions(+) diff --git a/OpenRA.Mods.Common/Traits/SupportPowers/AirstrikePower.cs b/OpenRA.Mods.Common/Traits/SupportPowers/AirstrikePower.cs index 318576029b..212b29263d 100644 --- a/OpenRA.Mods.Common/Traits/SupportPowers/AirstrikePower.cs +++ b/OpenRA.Mods.Common/Traits/SupportPowers/AirstrikePower.cs @@ -129,6 +129,8 @@ namespace OpenRA.Mods.Common.Traits { var notification = self.Owner.IsAlliedWith(self.World.RenderPlayer) ? Info.LaunchSound : Info.IncomingSound; Game.Sound.Play(notification); + Game.Sound.PlayNotification(self.World.Map.Rules, self.Owner, "Speech", + Info.IncomingSpeechNotification, self.Owner.Faction.InternalName); Actor distanceTestActor = null; for (var i = -info.SquadSize / 2; i <= info.SquadSize / 2; i++) diff --git a/OpenRA.Mods.Common/Traits/SupportPowers/NukePower.cs b/OpenRA.Mods.Common/Traits/SupportPowers/NukePower.cs index b35e775a33..f2e8691238 100644 --- a/OpenRA.Mods.Common/Traits/SupportPowers/NukePower.cs +++ b/OpenRA.Mods.Common/Traits/SupportPowers/NukePower.cs @@ -96,7 +96,11 @@ namespace OpenRA.Mods.Common.Traits if (self.Owner.IsAlliedWith(self.World.RenderPlayer)) Game.Sound.Play(Info.LaunchSound); else + { Game.Sound.Play(Info.IncomingSound); + Game.Sound.PlayNotification(self.World.Map.Rules, self.Owner, "Speech", + Info.IncomingSpeechNotification, self.Owner.Faction.InternalName); + } if (!string.IsNullOrEmpty(info.ActivationSequence)) { diff --git a/OpenRA.Mods.Common/Traits/SupportPowers/SupportPower.cs b/OpenRA.Mods.Common/Traits/SupportPowers/SupportPower.cs index b5ccbc16b7..ed583cec29 100644 --- a/OpenRA.Mods.Common/Traits/SupportPowers/SupportPower.cs +++ b/OpenRA.Mods.Common/Traits/SupportPowers/SupportPower.cs @@ -32,11 +32,15 @@ namespace OpenRA.Mods.Common.Traits public readonly string[] Prerequisites = { }; public readonly string BeginChargeSound = null; + public readonly string BeginChargeSpeechNotification = null; public readonly string EndChargeSound = null; + public readonly string EndChargeSpeechNotification = null; public readonly string SelectTargetSound = null; + public readonly string SelectTargetSpeechNotification = null; public readonly string InsufficientPowerSound = null; public readonly string LaunchSound = null; public readonly string IncomingSound = null; + public readonly string IncomingSpeechNotification = null; public readonly bool DisplayTimer = false; @@ -83,16 +87,22 @@ namespace OpenRA.Mods.Common.Traits public virtual void Charging(Actor self, string key) { Game.Sound.PlayToPlayer(self.Owner, Info.BeginChargeSound); + Game.Sound.PlayNotification(self.World.Map.Rules, self.Owner, "Speech", + Info.BeginChargeSpeechNotification, self.Owner.Faction.InternalName); } public virtual void Charged(Actor self, string key) { Game.Sound.PlayToPlayer(self.Owner, Info.EndChargeSound); + Game.Sound.PlayNotification(self.World.Map.Rules, self.Owner, "Speech", + Info.EndChargeSpeechNotification, self.Owner.Faction.InternalName); } public virtual void SelectTarget(Actor self, string order, SupportPowerManager manager) { Game.Sound.PlayToPlayer(manager.Self.Owner, Info.SelectTargetSound); + Game.Sound.PlayNotification(self.World.Map.Rules, self.Owner, "Speech", + Info.SelectTargetSpeechNotification, self.Owner.Faction.InternalName); self.World.OrderGenerator = new SelectGenericPowerTarget(order, manager, info.Cursor, MouseButton.Left); } From 2f1169b54868477cd524ea44a358276bd02bc72e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 19 Jun 2016 18:47:29 +0200 Subject: [PATCH 04/10] Don't null unused fields as they default to null. --- mods/d2k/rules/structures.yaml | 4 ---- mods/ts/rules/gdi-structures.yaml | 3 --- mods/ts/rules/nod-support.yaml | 2 -- 3 files changed, 9 deletions(-) diff --git a/mods/d2k/rules/structures.yaml b/mods/d2k/rules/structures.yaml index b15f129683..6c7cef3423 100644 --- a/mods/d2k/rules/structures.yaml +++ b/mods/d2k/rules/structures.yaml @@ -838,7 +838,6 @@ high_tech_factory: SquadSize: 3 LongDesc: Ornithopters hit the target with bombs UnitType: ornithopter - SelectTargetSound: DisplayBeacon: True CameraActor: camera WithProductionOverlay@WELDING: @@ -953,9 +952,6 @@ palace: LongDesc: Launches an atomic missile at a target location BeginChargeSound: HI_PREP.AUD EndChargeSound: HI_DHRDY.AUD - SelectTargetSound: - LaunchSound: - IncomingSound: MissileWeapon: atomic SpawnOffset: -512,1c171,0 DisplayBeacon: True diff --git a/mods/ts/rules/gdi-structures.yaml b/mods/ts/rules/gdi-structures.yaml index 2508d7259c..8f8de69082 100644 --- a/mods/ts/rules/gdi-structures.yaml +++ b/mods/ts/rules/gdi-structures.yaml @@ -403,11 +403,8 @@ GAPLUG: ChargeTime: 180 Description: Ion Cannon LongDesc: Initiate an Ion Cannon strike.\nApplies instant damage to a small area. - BeginChargeSound: EndChargeSound: 00-i156.aud - LaunchSound: SelectTargetSound: - InsufficientPowerSound: DisplayRadarPing: True CameraActor: camera ProduceActorPower: diff --git a/mods/ts/rules/nod-support.yaml b/mods/ts/rules/nod-support.yaml index 23e3493617..e2f1721164 100644 --- a/mods/ts/rules/nod-support.yaml +++ b/mods/ts/rules/nod-support.yaml @@ -238,10 +238,8 @@ NAMISL: ChargeTime: 540 Description: Cluster Missile LongDesc: Launches a conventional warhead\nat a target location. - BeginChargeSound: EndChargeSound: 00-i154.aud SelectTargetSound: - InsufficientPowerSound: IncomingSound: 00-i150.aud LaunchSound: icbm1.aud MissileWeapon: ClusterMissile From 55ed5247cccdbe17d47c519a536342cb599104fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 19 Jun 2016 18:48:07 +0200 Subject: [PATCH 05/10] Replace Death Hand missile sounds with faction speech. --- mods/d2k/rules/structures.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/d2k/rules/structures.yaml b/mods/d2k/rules/structures.yaml index 6c7cef3423..d2e02c955e 100644 --- a/mods/d2k/rules/structures.yaml +++ b/mods/d2k/rules/structures.yaml @@ -950,8 +950,8 @@ palace: ChargeTime: 300 Description: Death Hand LongDesc: Launches an atomic missile at a target location - BeginChargeSound: HI_PREP.AUD - EndChargeSound: HI_DHRDY.AUD + BeginChargeSpeechNotification: DeathHandMissilePrepping + EndChargeSpeechNotification: DeathHandMissileReady MissileWeapon: atomic SpawnOffset: -512,1c171,0 DisplayBeacon: True From 5cffccb679388d084a72be78949bffcbdcb67489 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 19 Jun 2016 18:48:20 +0200 Subject: [PATCH 06/10] Add Death Hand missile launch detected. --- mods/d2k/rules/structures.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/mods/d2k/rules/structures.yaml b/mods/d2k/rules/structures.yaml index d2e02c955e..2b88b6d041 100644 --- a/mods/d2k/rules/structures.yaml +++ b/mods/d2k/rules/structures.yaml @@ -952,6 +952,7 @@ palace: LongDesc: Launches an atomic missile at a target location BeginChargeSpeechNotification: DeathHandMissilePrepping EndChargeSpeechNotification: DeathHandMissileReady + MissileLaunchDetected: MissileLaunchDetected MissileWeapon: atomic SpawnOffset: -512,1c171,0 DisplayBeacon: True From 4896f2deb71b2e0c6dc5fbb997b3da8581e3828b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 19 Jun 2016 18:49:23 +0200 Subject: [PATCH 07/10] Replace Ion Cannon sounds with faction speech. --- mods/ts/rules/gdi-structures.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mods/ts/rules/gdi-structures.yaml b/mods/ts/rules/gdi-structures.yaml index 8f8de69082..c75c1e9a81 100644 --- a/mods/ts/rules/gdi-structures.yaml +++ b/mods/ts/rules/gdi-structures.yaml @@ -403,8 +403,8 @@ GAPLUG: ChargeTime: 180 Description: Ion Cannon LongDesc: Initiate an Ion Cannon strike.\nApplies instant damage to a small area. - EndChargeSound: 00-i156.aud SelectTargetSound: + EndChargeSpeechNotification: IonCannonReady DisplayRadarPing: True CameraActor: camera ProduceActorPower: From 730b5ae2eb81abb9cf04e6a8a3ab9bcc83683a7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 19 Jun 2016 18:50:00 +0200 Subject: [PATCH 08/10] Replace cluster missile sounds with faction speech. --- mods/ts/rules/nod-support.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/ts/rules/nod-support.yaml b/mods/ts/rules/nod-support.yaml index e2f1721164..1f800f48bb 100644 --- a/mods/ts/rules/nod-support.yaml +++ b/mods/ts/rules/nod-support.yaml @@ -238,9 +238,9 @@ NAMISL: ChargeTime: 540 Description: Cluster Missile LongDesc: Launches a conventional warhead\nat a target location. - EndChargeSound: 00-i154.aud SelectTargetSound: - IncomingSound: 00-i150.aud + EndChargeSpeechNotification: ClusterMissileReady + IncomingSpeechNotification: MissileLaunchDetected LaunchSound: icbm1.aud MissileWeapon: ClusterMissile SpawnOffset: 0,427,0 From ad216ce05098975e80377959d6133b6bcd12e19d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 19 Jun 2016 18:50:31 +0200 Subject: [PATCH 09/10] Consolidate EMP attack order with faction speech notifications. --- mods/ts/rules/shared-support.yaml | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) diff --git a/mods/ts/rules/shared-support.yaml b/mods/ts/rules/shared-support.yaml index a15036d5aa..785a0be4af 100644 --- a/mods/ts/rules/shared-support.yaml +++ b/mods/ts/rules/shared-support.yaml @@ -43,30 +43,12 @@ NAPULS: gdi: napuls.gdi nod: napuls.nod ProvidesPrerequisite@gdi: - Prerequisite: emp.gdi - Factions: gdi ResetOnOwnerChange: true - ProvidesPrerequisite@nod: - Prerequisite: emp.nod - Factions: nod - ResetOnOwnerChange: true - AttackOrderPower@nod: + AttackOrderPower: Cursor: emp Icon: emp ChargeTime: 135 Description: E.M. Pulse LongDesc: Fires a pulse blast which disables\nall mechanical units in the area. - EndChargeSound: speech-nod|00-i158.aud - SelectTargetSound: speech-nod|00-i042.aud - Prerequisites: emp.nod - OrderName: Nodemp - AttackOrderPower@gdi: - Cursor: emp - Icon: emp - ChargeTime: 135 - Description: E.M. Pulse - LongDesc: Fires a pulse blast which disables\nall mechanical units in the area. - EndChargeSound: speech-gdi|00-i158.aud - SelectTargetSound: speech-gdi|00-i042.aud - Prerequisites: emp.gdi - OrderName: GDIemp + EndChargeSpeechNotification: EmPulseCannonReady + SelectTargetSpeechNotification: SelectTarget From aebd4a9fea20cdd7bed4b9b5a2edc681bc34a48f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sun, 19 Jun 2016 18:51:10 +0200 Subject: [PATCH 10/10] Add faction specific select target speech notifications to ion cannon and cluster missile. --- mods/ts/rules/gdi-structures.yaml | 2 +- mods/ts/rules/nod-support.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/ts/rules/gdi-structures.yaml b/mods/ts/rules/gdi-structures.yaml index c75c1e9a81..94fcc3e01a 100644 --- a/mods/ts/rules/gdi-structures.yaml +++ b/mods/ts/rules/gdi-structures.yaml @@ -403,8 +403,8 @@ GAPLUG: ChargeTime: 180 Description: Ion Cannon LongDesc: Initiate an Ion Cannon strike.\nApplies instant damage to a small area. - SelectTargetSound: EndChargeSpeechNotification: IonCannonReady + SelectTargetSpeechNotification: SelectTarget DisplayRadarPing: True CameraActor: camera ProduceActorPower: diff --git a/mods/ts/rules/nod-support.yaml b/mods/ts/rules/nod-support.yaml index 1f800f48bb..66a7e22668 100644 --- a/mods/ts/rules/nod-support.yaml +++ b/mods/ts/rules/nod-support.yaml @@ -238,8 +238,8 @@ NAMISL: ChargeTime: 540 Description: Cluster Missile LongDesc: Launches a conventional warhead\nat a target location. - SelectTargetSound: EndChargeSpeechNotification: ClusterMissileReady + SelectTargetSpeechNotification: SelectTarget IncomingSpeechNotification: MissileLaunchDetected LaunchSound: icbm1.aud MissileWeapon: ClusterMissile