Changed 'UpgradeOverlay' to 'WithColoredOverlay'
This commit is contained in:
@@ -355,7 +355,7 @@
|
||||
<Compile Include="Traits\Modifiers\DisabledOverlay.cs" />
|
||||
<Compile Include="Traits\Modifiers\FrozenUnderFog.cs" />
|
||||
<Compile Include="Traits\Modifiers\HiddenUnderFog.cs" />
|
||||
<Compile Include="Traits\Modifiers\UpgradeOverlay.cs" />
|
||||
<Compile Include="Traits\Modifiers\WithColoredOverlay.cs" />
|
||||
<Compile Include="Traits\MustBeDestroyed.cs" />
|
||||
<Compile Include="Traits\Parachutable.cs" />
|
||||
<Compile Include="Traits\ParaDrop.cs" />
|
||||
|
||||
@@ -15,18 +15,18 @@ using OpenRA.Traits;
|
||||
|
||||
namespace OpenRA.Mods.Common.Traits
|
||||
{
|
||||
[Desc("Display a colored overlay when a timed upgrade is active.")]
|
||||
public class UpgradeOverlayInfo : ConditionalTraitInfo
|
||||
[Desc("Display a colored overlay when a timed condition is active.")]
|
||||
public class WithColoredOverlayInfo : ConditionalTraitInfo
|
||||
{
|
||||
[Desc("Palette to use when rendering the overlay")]
|
||||
[PaletteReference] public readonly string Palette = "invuln";
|
||||
|
||||
public override object Create(ActorInitializer init) { return new UpgradeOverlay(this); }
|
||||
public override object Create(ActorInitializer init) { return new WithColoredOverlay(this); }
|
||||
}
|
||||
|
||||
public class UpgradeOverlay : ConditionalTrait<UpgradeOverlayInfo>, IRenderModifier
|
||||
public class WithColoredOverlay : ConditionalTrait<WithColoredOverlayInfo>, IRenderModifier
|
||||
{
|
||||
public UpgradeOverlay(UpgradeOverlayInfo info)
|
||||
public WithColoredOverlay(WithColoredOverlayInfo info)
|
||||
: base(info) { }
|
||||
|
||||
public IEnumerable<IRenderable> ModifyRender(Actor self, WorldRenderer wr, IEnumerable<IRenderable> r)
|
||||
@@ -776,6 +776,11 @@ namespace OpenRA.Mods.Common.UtilityCommands
|
||||
}
|
||||
}
|
||||
|
||||
// Rename UpgradeOverlay to WithColoredOverlay
|
||||
if (engineVersion < 20170201)
|
||||
if (node.Key.StartsWith("UpgradeOverlay", StringComparison.Ordinal))
|
||||
RenameNodeKey(node, "WithColoredOverlay" + node.Key.Substring(14));
|
||||
|
||||
UpgradeActorRules(modData, engineVersion, ref node.Value.Nodes, node, depth + 1);
|
||||
}
|
||||
|
||||
|
||||
@@ -116,7 +116,7 @@
|
||||
ZOffset: 256
|
||||
|
||||
^IronCurtainable:
|
||||
UpgradeOverlay@IRONCURTAIN:
|
||||
WithColoredOverlay@IRONCURTAIN:
|
||||
RequiresCondition: invulnerability
|
||||
DamageMultiplier@IRONCURTAIN:
|
||||
RequiresCondition: invulnerability
|
||||
|
||||
@@ -79,7 +79,7 @@
|
||||
Conditions: crate-firepower, crate-damage, crate-speed
|
||||
|
||||
^EmpDisable:
|
||||
UpgradeOverlay@EMPDISABLE:
|
||||
WithColoredOverlay@EMPDISABLE:
|
||||
RequiresCondition: empdisable
|
||||
Palette: disabled
|
||||
DisableOnCondition@EMPDISABLE:
|
||||
|
||||
Reference in New Issue
Block a user