BuildingCapture, ActorLost now use notifications.yaml
less redundancy, aggregates notification audio files
This commit is contained in:
@@ -14,8 +14,7 @@ namespace OpenRA.Mods.RA
|
||||
{
|
||||
class CaptureNotificationInfo : ITraitInfo
|
||||
{
|
||||
public readonly string Race = null;
|
||||
public readonly string Notification = null;
|
||||
public readonly string Notification = "BuildingCaptured";
|
||||
|
||||
public object Create(ActorInitializer init) { return new CaptureNotification(this); }
|
||||
}
|
||||
@@ -33,10 +32,7 @@ namespace OpenRA.Mods.RA
|
||||
if (captor.World.LocalPlayer != captor.Owner)
|
||||
return;
|
||||
|
||||
if (Info.Race != null && Info.Race != newOwner.Country.Race)
|
||||
return;
|
||||
|
||||
Sound.PlayToPlayer(captor.World.LocalPlayer, Info.Notification);
|
||||
Sound.PlayNotification(captor.World.LocalPlayer, "Speech", Info.Notification, newOwner.Country.Race);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,8 +14,7 @@ namespace OpenRA.Mods.RA
|
||||
{
|
||||
class ActorLostNotificationInfo : ITraitInfo
|
||||
{
|
||||
public readonly string Race = null;
|
||||
public readonly string Notification = null;
|
||||
public readonly string Notification = "UnitLost";
|
||||
public readonly bool NotifyAll = false;
|
||||
|
||||
public object Create(ActorInitializer init) { return new ActorLostNotification(this); }
|
||||
@@ -32,9 +31,7 @@ namespace OpenRA.Mods.RA
|
||||
public void Killed(Actor self, AttackInfo e)
|
||||
{
|
||||
var player = (Info.NotifyAll) ? self.World.LocalPlayer : self.Owner;
|
||||
if (Info.Race != null && Info.Race != self.Owner.Country.Race)
|
||||
return;
|
||||
Sound.PlayToPlayer(player, Info.Notification);
|
||||
Sound.PlayNotification(player, "Speech", Info.Notification, self.Owner.Country.Race);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,8 +14,7 @@ namespace OpenRA.Mods.RA
|
||||
{
|
||||
class CaptureNotificationInfo : ITraitInfo
|
||||
{
|
||||
public readonly string Race = null;
|
||||
public readonly string Notification = null;
|
||||
public readonly string Notification = "BuildingCaptured";
|
||||
|
||||
public object Create(ActorInitializer init) { return new CaptureNotification(this); }
|
||||
}
|
||||
@@ -33,10 +32,7 @@ namespace OpenRA.Mods.RA
|
||||
if (captor.World.LocalPlayer != captor.Owner)
|
||||
return;
|
||||
|
||||
if (Info.Race != null && Info.Race != oldOwner.Country.Race)
|
||||
return;
|
||||
|
||||
Sound.PlayToPlayer(captor.World.LocalPlayer, Info.Notification);
|
||||
Sound.PlayNotification(captor.World.LocalPlayer, "Speech", Info.Notification, oldOwner.Country.Race);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
Speech:
|
||||
Prefixes:
|
||||
gdi: gdi
|
||||
nod: nod
|
||||
Notifications:
|
||||
Repairing: repair1
|
||||
LowPower: lopower1
|
||||
@@ -21,6 +24,11 @@ Speech:
|
||||
Building: bldging1
|
||||
ConstructionComplete: constru1
|
||||
Reinforce: reinfor1
|
||||
UnitLost: unitlost
|
||||
BuildingLost: strclost
|
||||
CivilianKilled: civdead1
|
||||
BuildingCaptured: capt1
|
||||
DisablePrefixes: Repairing, LowPower, SilosNeeded, PrimaryBuildingSelected, BuildingCannotPlaceAudio, NewOptions, AbilityInsufficientPower, Win, Lose, BaseAttack, HarvesterAttack, Leave, UnitReady, NoBuild, Training, OnHold, Cancelled, Building, ConstructionComplete, Reinforce, UnitLost, BuildingLost, CivilianKilled
|
||||
|
||||
Sounds:
|
||||
Notifications:
|
||||
|
||||
@@ -27,7 +27,6 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: unitlost.aud
|
||||
AttackMove:
|
||||
AcceptsCloakCrate:
|
||||
WithSmoke:
|
||||
@@ -62,7 +61,6 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: unitlost.aud
|
||||
AttackMove:
|
||||
AcceptsCloakCrate:
|
||||
WithSmoke:
|
||||
@@ -91,7 +89,6 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: unitlost.aud
|
||||
Explodes:
|
||||
Weapon: HeliExplode
|
||||
EmptyWeapon: HeliExplode
|
||||
@@ -139,7 +136,6 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: unitlost.aud
|
||||
SpawnViceroid:
|
||||
Probability: 2
|
||||
CrushableInfantry:
|
||||
@@ -175,7 +171,7 @@
|
||||
Weapon: Pistol
|
||||
AttackFrontal:
|
||||
ActorLostNotification:
|
||||
Notification: civdead1.aud
|
||||
Notification: CivilianKilled
|
||||
NotifyAll: true
|
||||
ScaredyCat:
|
||||
RenderInfantryPanic:
|
||||
@@ -196,7 +192,6 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: unitlost.aud
|
||||
DebugMuzzlePositions:
|
||||
|
||||
^Ship:
|
||||
@@ -215,7 +210,6 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: unitlost.aud
|
||||
AttackMove:
|
||||
DebugMuzzlePositions:
|
||||
|
||||
@@ -252,14 +246,10 @@
|
||||
ActorTypes: e6,e1
|
||||
MustBeDestroyed:
|
||||
GivesExperience:
|
||||
CaptureNotification@GDI:
|
||||
Race: gdi
|
||||
Notification: gdicapt1.aud
|
||||
CaptureNotification@NOD:
|
||||
Race: nod
|
||||
Notification: nodcapt1.aud
|
||||
CaptureNotification:
|
||||
Notification: BuildingCaptured
|
||||
ActorLostNotification:
|
||||
Notification: strclost.aud
|
||||
Notification: BuildingLost
|
||||
EditorAppearance:
|
||||
RelativeToTopLeft: yes
|
||||
AutoTargetIgnore:
|
||||
|
||||
@@ -223,7 +223,6 @@ PVICE:
|
||||
Queue: Biolab
|
||||
BuildPaletteOrder: 40
|
||||
Owner: gdi, nod
|
||||
# Prerequisites: bio
|
||||
Tooltip:
|
||||
Description: Mutated abomination that spits liquid tiberium.\n Strong vs Infantry, Buildings\n Weak vs Aircraft
|
||||
Icon: viceicnh
|
||||
@@ -232,4 +231,3 @@ PVICE:
|
||||
Voice: DinoVoice
|
||||
SelectionDecorations:
|
||||
ActorLostNotification:
|
||||
Notification: unitlost.aud
|
||||
|
||||
@@ -29,6 +29,9 @@ Speech:
|
||||
BuildingReady: BDRDY
|
||||
OrderPlaced: ORDER
|
||||
Reinforce: REINF
|
||||
UnitLost: ULOST
|
||||
BuildingLost: BLOST
|
||||
BuildingCaptured: CAPT
|
||||
|
||||
Sounds:
|
||||
Notifications:
|
||||
|
||||
@@ -23,15 +23,7 @@
|
||||
GainsExperience:
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification@Atreides:
|
||||
Race: atreides
|
||||
Notification: AI_ULOST.AUD
|
||||
ActorLostNotification@Harkonnen:
|
||||
Race: harkonnen
|
||||
Notification: HI_ULOST.AUD
|
||||
ActorLostNotification@Ordos:
|
||||
Race: ordos
|
||||
Notification: OI_ULOST.AUD
|
||||
ActorLostNotification:
|
||||
ProximityCaptor:
|
||||
Types:Vehicle
|
||||
GivesBounty:
|
||||
@@ -67,15 +59,7 @@
|
||||
GainsExperience:
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification@Atreides:
|
||||
Race: atreides
|
||||
Notification: AI_ULOST.AUD
|
||||
ActorLostNotification@Harkonnen:
|
||||
Race: harkonnen
|
||||
Notification: HI_ULOST.AUD
|
||||
ActorLostNotification@Ordos:
|
||||
Race: ordos
|
||||
Notification: OI_ULOST.AUD
|
||||
ActorLostNotification:
|
||||
ProximityCaptor:
|
||||
Types:Tank
|
||||
GivesBounty:
|
||||
@@ -154,15 +138,7 @@
|
||||
GainsExperience:
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification@Atreides:
|
||||
Race: atreides
|
||||
Notification: AI_ULOST.AUD
|
||||
ActorLostNotification@Harkonnen:
|
||||
Race: harkonnen
|
||||
Notification: HI_ULOST.AUD
|
||||
ActorLostNotification@Ordos:
|
||||
Race: ordos
|
||||
Notification: OI_ULOST.AUD
|
||||
ActorLostNotification:
|
||||
ProximityCaptor:
|
||||
Types:Infantry
|
||||
GivesBounty:
|
||||
@@ -188,15 +164,7 @@
|
||||
GainsExperience:
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification@Atreides:
|
||||
Race: atreides
|
||||
Notification: AI_ULOST.AUD
|
||||
ActorLostNotification@Harkonnen:
|
||||
Race: harkonnen
|
||||
Notification: HI_ULOST.AUD
|
||||
ActorLostNotification@Ordos:
|
||||
Race: ordos
|
||||
Notification: OI_ULOST.AUD
|
||||
ActorLostNotification:
|
||||
DebugAircraftFacing:
|
||||
DebugAircraftSubPxX:
|
||||
DebugAircraftSubPxY:
|
||||
@@ -236,25 +204,11 @@
|
||||
ActorTypes: rifle,rifle,rifle,rifle,rifle,bazooka,bazooka,bazooka,engineer
|
||||
MustBeDestroyed:
|
||||
GivesExperience:
|
||||
|
||||
FrozenUnderFog:
|
||||
CaptureNotification@Atreides:
|
||||
Race: atreides
|
||||
Notification: AI_CAPT.AUD
|
||||
CaptureNotification@Harkonnen:
|
||||
Race: harkonnen
|
||||
Notification: HI_CAPT.AUD
|
||||
CaptureNotification@Ordos:
|
||||
Race: ordos
|
||||
Notification: OI_CAPT.AUD
|
||||
ActorLostNotification@Atreides:
|
||||
Race: atreides
|
||||
Notification: AI_BLOST.AUD
|
||||
ActorLostNotification@Harkonnen:
|
||||
Race: harkonnen
|
||||
Notification: HI_BLOST.AUD
|
||||
ActorLostNotification@Ordos:
|
||||
Race: ordos
|
||||
Notification: OI_BLOST.AUD
|
||||
CaptureNotification:
|
||||
ActorLostNotification:
|
||||
Notification: BuildingLost
|
||||
EditorAppearance:
|
||||
RelativeToTopLeft: yes
|
||||
AutoTargetIgnore:
|
||||
|
||||
@@ -20,6 +20,11 @@ Speech:
|
||||
Cancelled: cancld1
|
||||
Building: abldgin1
|
||||
ConstructionComplete: conscmp1
|
||||
UnitLost: unitlst1
|
||||
NavalUnitLost: navylst1
|
||||
AirUnitLost: aunitl1
|
||||
BuildingCaptured: strucap1
|
||||
|
||||
|
||||
Sounds:
|
||||
Notifications:
|
||||
|
||||
@@ -26,7 +26,6 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: unitlst1.aud
|
||||
ProximityCaptor:
|
||||
Types:Vehicle
|
||||
GivesBounty:
|
||||
@@ -64,7 +63,6 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: unitlst1.aud
|
||||
ProximityCaptor:
|
||||
Types:Tank
|
||||
GivesBounty:
|
||||
@@ -110,7 +108,6 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: unitlst1.aud
|
||||
ProximityCaptor:
|
||||
Types:Infantry
|
||||
GivesBounty:
|
||||
@@ -145,7 +142,7 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: navylst1.aud
|
||||
Notification: NavalUnitLost
|
||||
ProximityCaptor:
|
||||
Types:Ship
|
||||
GivesBounty:
|
||||
@@ -169,7 +166,7 @@
|
||||
GivesExperience:
|
||||
DrawLineToTarget:
|
||||
ActorLostNotification:
|
||||
Notification: aunitl1.aud
|
||||
Notification: AirUnitLost
|
||||
DebugAircraftFacing:
|
||||
DebugAircraftSubPxX:
|
||||
DebugAircraftSubPxY:
|
||||
@@ -217,7 +214,6 @@
|
||||
GivesExperience:
|
||||
# FrozenUnderFog:
|
||||
CaptureNotification:
|
||||
Notification: strucap1.aud
|
||||
EditorAppearance:
|
||||
RelativeToTopLeft: yes
|
||||
ShakeOnDeath:
|
||||
|
||||
Reference in New Issue
Block a user