fix case on WastedAfterwards
This commit is contained in:
@@ -43,7 +43,7 @@ namespace OpenRA.Mods.RA.Activities
|
|||||||
target.Trait<Capturable>().BeginCapture(target, self);
|
target.Trait<Capturable>().BeginCapture(target, self);
|
||||||
|
|
||||||
var capturesInfo = self.Info.Traits.Get<CapturesInfo>();
|
var capturesInfo = self.Info.Traits.Get<CapturesInfo>();
|
||||||
if (capturesInfo != null && capturesInfo.wastedAfterwards)
|
if (capturesInfo != null && capturesInfo.WastedAfterwards)
|
||||||
self.World.AddFrameEndTask(w => self.Destroy());
|
self.World.AddFrameEndTask(w => self.Destroy());
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ namespace OpenRA.Mods.RA
|
|||||||
class CapturesInfo : ITraitInfo
|
class CapturesInfo : ITraitInfo
|
||||||
{
|
{
|
||||||
public string[] CaptureTypes = {"building"};
|
public string[] CaptureTypes = {"building"};
|
||||||
public bool wastedAfterwards = true;
|
public bool WastedAfterwards = true;
|
||||||
public object Create(ActorInitializer init) { return new Captures(init.self, this); }
|
public object Create(ActorInitializer init) { return new Captures(init.self, this); }
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -108,7 +108,7 @@ namespace OpenRA.Mods.RA
|
|||||||
|
|
||||||
if (captureTypes.Contains(ci.Type))
|
if (captureTypes.Contains(ci.Type))
|
||||||
{
|
{
|
||||||
cursor = (Info.wastedAfterwards) ? (useEnterCursor(target) ? "enter" : "enter-blocked") : "attack";
|
cursor = (Info.WastedAfterwards) ? (useEnterCursor(target) ? "enter" : "enter-blocked") : "attack";
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user