Merge Rearm and Repair into Resupply activity

Allows parallel rearming and repairing.
This commit is contained in:
reaperrr
2019-03-24 16:26:14 +01:00
committed by Paul Chote
parent 123b3f054f
commit ba4b5738d7
9 changed files with 109 additions and 169 deletions

View File

@@ -61,8 +61,7 @@ namespace OpenRA.Mods.Cnc.Activities
// Add a CloseEnough range of 512 to the Rearm/Repair activities in order to ensure that we're at the host actor
QueueChild(self, new MoveAdjacentTo(self, Target.FromActor(rearmTarget)), true);
QueueChild(self, movement.MoveTo(self.World.Map.CellContaining(rearmTarget.CenterPosition), rearmTarget));
QueueChild(self, new Rearm(self, rearmTarget, new WDist(512)));
QueueChild(self, new Repair(self, rearmTarget, new WDist(512)));
QueueChild(self, new Resupply(self, rearmTarget, new WDist(512)));
return this;
}