diff --git a/OpenRA.Mods.Common/Scripting/Global/LightingGlobal.cs b/OpenRA.Mods.Common/Scripting/Global/LightingGlobal.cs index 4f237f6f77..e0d3c26b0f 100644 --- a/OpenRA.Mods.Common/Scripting/Global/LightingGlobal.cs +++ b/OpenRA.Mods.Common/Scripting/Global/LightingGlobal.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -30,7 +30,7 @@ namespace OpenRA.Mods.Common.Scripting hasLighting = lighting != null; } - [Desc("Controls the `FlashPaletteEffect` trait.")] + [Desc("Controls the `" + nameof(FlashPaletteEffect) + "` trait.")] public void Flash(string type = null, int ticks = -1) { foreach (var effect in flashPaletteEffects) diff --git a/OpenRA.Mods.Common/Traits/Buildings/FreeActorWithDelivery.cs b/OpenRA.Mods.Common/Traits/Buildings/FreeActorWithDelivery.cs index e4d7bed645..5f9238731a 100644 --- a/OpenRA.Mods.Common/Traits/Buildings/FreeActorWithDelivery.cs +++ b/OpenRA.Mods.Common/Traits/Buildings/FreeActorWithDelivery.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -21,7 +21,7 @@ namespace OpenRA.Mods.Common.Traits { [ActorReference] [FieldLoader.Require] - [Desc("Name of the delivering actor. This actor must have the `Carryall` trait")] + [Desc("Name of the delivering actor. This actor must have the `" + nameof(Carryall) + "` trait")] public readonly string DeliveringActor = null; [Desc("Cell coordinates for spawning the delivering actor. If left blank, the closest edge cell will be chosen.")] diff --git a/OpenRA.Mods.Common/Traits/Buildings/PrimaryBuilding.cs b/OpenRA.Mods.Common/Traits/Buildings/PrimaryBuilding.cs index c8e2f751d3..49cade1b2e 100644 --- a/OpenRA.Mods.Common/Traits/Buildings/PrimaryBuilding.cs +++ b/OpenRA.Mods.Common/Traits/Buildings/PrimaryBuilding.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -37,7 +37,7 @@ namespace OpenRA.Mods.Common.Traits public readonly string SelectionNotification = null; [Desc("List of production queues for which the primary flag should be set.", - "If empty, the list given in the `Produces` property of the `Production` trait will be used.")] + "If empty, the list given in the `Produces` property of the `" + nameof(Production) + "` trait will be used.")] public readonly string[] ProductionQueues = { }; [CursorReference] diff --git a/OpenRA.Mods.Common/Traits/Buildings/ProductionAirdrop.cs b/OpenRA.Mods.Common/Traits/Buildings/ProductionAirdrop.cs index d0faa087cd..376293f0bc 100644 --- a/OpenRA.Mods.Common/Traits/Buildings/ProductionAirdrop.cs +++ b/OpenRA.Mods.Common/Traits/Buildings/ProductionAirdrop.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -25,7 +25,7 @@ namespace OpenRA.Mods.Common.Traits [FieldLoader.Require] [ActorReference(typeof(AircraftInfo))] - [Desc("Cargo aircraft used for delivery. Must have the `Aircraft` trait.")] + [Desc("Cargo aircraft used for delivery. Must have the `" + nameof(Aircraft) + "` trait.")] public readonly string ActorType = null; [Desc("The cargo aircraft will spawn at the player baseline (map edge closest to the player spawn)")] diff --git a/OpenRA.Mods.Common/Traits/Carryable.cs b/OpenRA.Mods.Common/Traits/Carryable.cs index 552bc280ea..4d1ee30904 100644 --- a/OpenRA.Mods.Common/Traits/Carryable.cs +++ b/OpenRA.Mods.Common/Traits/Carryable.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -14,7 +14,7 @@ using OpenRA.Traits; namespace OpenRA.Mods.Common.Traits { - [Desc("Can be carried by actors with the `Carryall` trait.")] + [Desc("Can be carried by actors with the `" + nameof(Carryall) + "` trait.")] public class CarryableInfo : ConditionalTraitInfo { [GrantedConditionReference] diff --git a/OpenRA.Mods.Common/Traits/Carryall.cs b/OpenRA.Mods.Common/Traits/Carryall.cs index 75bc126054..5c9d2febe5 100644 --- a/OpenRA.Mods.Common/Traits/Carryall.cs +++ b/OpenRA.Mods.Common/Traits/Carryall.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -20,7 +20,7 @@ using OpenRA.Traits; namespace OpenRA.Mods.Common.Traits { - [Desc("Transports actors with the `Carryable` trait.")] + [Desc("Transports actors with the `" + nameof(Carryable) + "` trait.")] public class CarryallInfo : TraitInfo, Requires, Requires { [ActorReference(typeof(CarryableInfo))] diff --git a/OpenRA.Mods.Common/Traits/DeliversCash.cs b/OpenRA.Mods.Common/Traits/DeliversCash.cs index 15fca0ee56..1b73bab97a 100644 --- a/OpenRA.Mods.Common/Traits/DeliversCash.cs +++ b/OpenRA.Mods.Common/Traits/DeliversCash.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -17,7 +17,7 @@ using OpenRA.Traits; namespace OpenRA.Mods.Common.Traits { - [Desc("Donate money to actors with the `AcceptsDeliveredCash` trait.")] + [Desc("Donate money to actors with the `" + nameof(AcceptsDeliveredCash) + "` trait.")] class DeliversCashInfo : TraitInfo { [Desc("The amount of cash the owner receives.")] diff --git a/OpenRA.Mods.Common/Traits/DeliversExperience.cs b/OpenRA.Mods.Common/Traits/DeliversExperience.cs index 43574cb95f..2018ad1acf 100644 --- a/OpenRA.Mods.Common/Traits/DeliversExperience.cs +++ b/OpenRA.Mods.Common/Traits/DeliversExperience.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -17,7 +17,7 @@ using OpenRA.Traits; namespace OpenRA.Mods.Common.Traits { - [Desc("This actor can grant experience levels equal to it's own current level via entering to other actors with the `AcceptsDeliveredExperience` trait.")] + [Desc("This actor can grant experience levels equal to it's own current level via entering to other actors with the `" + nameof(AcceptsDeliveredExperience) + "` trait.")] class DeliversExperienceInfo : TraitInfo, Requires { [Desc("The amount of experience the donating player receives.")] diff --git a/OpenRA.Mods.Common/Traits/Player/PlayerExperience.cs b/OpenRA.Mods.Common/Traits/Player/PlayerExperience.cs index c75125fab2..a7dbbb6a5a 100644 --- a/OpenRA.Mods.Common/Traits/Player/PlayerExperience.cs +++ b/OpenRA.Mods.Common/Traits/Player/PlayerExperience.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -14,7 +14,7 @@ using OpenRA.Traits; namespace OpenRA.Mods.Common.Traits { [TraitLocation(SystemActors.Player)] - [Desc("This trait can be used to track player experience based on units killed with the `GivesExperience` trait.", + [Desc("This trait can be used to track player experience based on units killed with the `" + nameof(GivesExperience) + "` trait.", "It can also be used as a point score system in scripted maps, for example.", "Attach this to the player actor.")] public class PlayerExperienceInfo : TraitInfo diff --git a/OpenRA.Mods.Common/Traits/RevealOnDeath.cs b/OpenRA.Mods.Common/Traits/RevealOnDeath.cs index e60503a1e9..2d1405aa83 100644 --- a/OpenRA.Mods.Common/Traits/RevealOnDeath.cs +++ b/OpenRA.Mods.Common/Traits/RevealOnDeath.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -27,7 +27,7 @@ namespace OpenRA.Mods.Common.Traits [Desc("Radius of the reveal around this actor.")] public readonly WDist Radius = new WDist(1536); - [Desc("Can this actor be revealed through shroud generated by the CreatesShroud trait?")] + [Desc("Can this actor be revealed through shroud generated by the `" + nameof(CreatesShroud) + "` trait?")] public readonly bool RevealGeneratedShroud = true; [Desc("DeathTypes for which shroud will be revealed.", diff --git a/OpenRA.Mods.Common/Traits/RevealOnFire.cs b/OpenRA.Mods.Common/Traits/RevealOnFire.cs index d6cb9f6dc0..6f186f491e 100644 --- a/OpenRA.Mods.Common/Traits/RevealOnFire.cs +++ b/OpenRA.Mods.Common/Traits/RevealOnFire.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -30,7 +30,7 @@ namespace OpenRA.Mods.Common.Traits [Desc("Radius of the reveal around this actor.")] public readonly WDist Radius = new WDist(1536); - [Desc("Can this actor be revealed through shroud generated by the CreatesShroud trait?")] + [Desc("Can this actor be revealed through shroud generated by the `" + nameof(CreatesShroud) + "` trait?")] public readonly bool RevealGeneratedShroud = true; public override object Create(ActorInitializer init) { return new RevealOnFire(init.Self, this); } diff --git a/OpenRA.Mods.Common/Traits/RevealsMap.cs b/OpenRA.Mods.Common/Traits/RevealsMap.cs index 919f8e36a8..5ca22337e5 100644 --- a/OpenRA.Mods.Common/Traits/RevealsMap.cs +++ b/OpenRA.Mods.Common/Traits/RevealsMap.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -19,7 +19,7 @@ namespace OpenRA.Mods.Common.Traits [Desc("Relationships the watching player needs to see the shroud removed.")] public readonly PlayerRelationship ValidRelationships = PlayerRelationship.Ally; - [Desc("Can this actor reveal shroud generated by the `CreatesShroud` trait?")] + [Desc("Can this actor reveal shroud generated by the `" + nameof(CreatesShroud) + "` trait?")] public readonly bool RevealGeneratedShroud = true; public override object Create(ActorInitializer init) { return new RevealsMap(this); } diff --git a/OpenRA.Mods.Common/Traits/RevealsShroud.cs b/OpenRA.Mods.Common/Traits/RevealsShroud.cs index f7c6c49475..adad126e64 100644 --- a/OpenRA.Mods.Common/Traits/RevealsShroud.cs +++ b/OpenRA.Mods.Common/Traits/RevealsShroud.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -20,7 +20,7 @@ namespace OpenRA.Mods.Common.Traits [Desc("Relationships the watching player needs to see the shroud removed.")] public readonly PlayerRelationship ValidRelationships = PlayerRelationship.Ally; - [Desc("Can this actor reveal shroud generated by the CreatesShroud trait?")] + [Desc("Can this actor reveal shroud generated by the `" + nameof(CreatesShroud) + "` trait?")] public readonly bool RevealGeneratedShroud = true; public override object Create(ActorInitializer init) { return new RevealsShroud(init.Self, this); } diff --git a/OpenRA.Mods.Common/Traits/SupportPowers/NukePower.cs b/OpenRA.Mods.Common/Traits/SupportPowers/NukePower.cs index 91ef6d12fc..9e4da97ead 100644 --- a/OpenRA.Mods.Common/Traits/SupportPowers/NukePower.cs +++ b/OpenRA.Mods.Common/Traits/SupportPowers/NukePower.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -91,7 +91,7 @@ namespace OpenRA.Mods.Common.Traits [Desc("Range of cells the camera should reveal around target cell.")] public readonly WDist CameraRange = WDist.Zero; - [Desc("Can the camera reveal shroud generated by the CreatesShroud trait?")] + [Desc("Can the camera reveal shroud generated by the `" + nameof(CreatesShroud) + "` trait?")] public readonly bool RevealGeneratedShroud = true; [Desc("Reveal cells to players with these relationships only.")] diff --git a/OpenRA.Mods.Common/Traits/World/WarheadDebugOverlay.cs b/OpenRA.Mods.Common/Traits/World/WarheadDebugOverlay.cs index b9643da4e2..0d482ad5bf 100644 --- a/OpenRA.Mods.Common/Traits/World/WarheadDebugOverlay.cs +++ b/OpenRA.Mods.Common/Traits/World/WarheadDebugOverlay.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -18,7 +18,7 @@ using OpenRA.Traits; namespace OpenRA.Mods.Common.Traits { [TraitLocation(SystemActors.World)] - [Desc("Part of the combat overlay from DeveloperMode. Attach this to the world actor.")] + [Desc("Part of the combat overlay from `" + nameof(DeveloperMode) + "`. Attach this to the world actor.")] public class WarheadDebugOverlayInfo : TraitInfo { public readonly int DisplayDuration = 25; diff --git a/OpenRA.Mods.Common/Warheads/Warhead.cs b/OpenRA.Mods.Common/Warheads/Warhead.cs index 743e86274b..c2667e0213 100644 --- a/OpenRA.Mods.Common/Warheads/Warhead.cs +++ b/OpenRA.Mods.Common/Warheads/Warhead.cs @@ -1,6 +1,6 @@ #region Copyright & License Information /* - * Copyright 2007-2020 The OpenRA Developers (see AUTHORS) + * Copyright 2007-2021 The OpenRA Developers (see AUTHORS) * This file is part of OpenRA, which is free software. It is made * available to you under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of @@ -10,6 +10,7 @@ #endregion using OpenRA.GameRules; +using OpenRA.Mods.Common.Traits; using OpenRA.Primitives; using OpenRA.Traits; @@ -45,7 +46,7 @@ namespace OpenRA.Mods.Common.Warheads int IWarhead.Delay => Delay; - [Desc("The color used for this warhead's visualization in the world's `WarheadDebugOverlay` trait.")] + [Desc("The color used for this warhead's visualization in the world's `" + nameof(WarheadDebugOverlay) + "` trait.")] public readonly Color DebugOverlayColor = Color.Red; protected bool IsValidTarget(BitSet targetTypes)