Add UpgradeUsedReferenceAttribute
This commit is contained in:
@@ -40,4 +40,7 @@ namespace OpenRA.Traits
|
||||
|
||||
[AttributeUsage(AttributeTargets.Field)]
|
||||
public sealed class UpgradeGrantedReferenceAttribute : Attribute { }
|
||||
|
||||
[AttributeUsage(AttributeTargets.Field)]
|
||||
public sealed class UpgradeUsedReferenceAttribute : Attribute { }
|
||||
}
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
* see COPYING.
|
||||
*/
|
||||
#endregion
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using OpenRA.Traits;
|
||||
@@ -16,6 +17,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
/// <summary>Use as base class for *Info to subclass of UpgradableTrait. (See UpgradableTrait.)</summary>
|
||||
public abstract class UpgradableTraitInfo
|
||||
{
|
||||
[UpgradeUsedReference]
|
||||
[Desc("The upgrade types which can enable or disable this trait.")]
|
||||
public readonly string[] UpgradeTypes = { };
|
||||
|
||||
|
||||
Reference in New Issue
Block a user