Remove Order.TargetLocation from Carryall.
This commit is contained in:
@@ -245,12 +245,11 @@ namespace OpenRA.Mods.Common.Traits
|
|||||||
{
|
{
|
||||||
if (order.OrderString == "DeliverUnit")
|
if (order.OrderString == "DeliverUnit")
|
||||||
{
|
{
|
||||||
var cell = self.World.Map.Clamp(order.TargetLocation);
|
var cell = self.World.Map.Clamp(self.World.Map.CellContaining(order.Target.CenterPosition));
|
||||||
|
|
||||||
if (!aircraftInfo.MoveIntoShroud && !self.Owner.Shroud.IsExplored(cell))
|
if (!aircraftInfo.MoveIntoShroud && !self.Owner.Shroud.IsExplored(cell))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
var targetLocation = move.NearestMoveableCell(order.TargetLocation);
|
var targetLocation = move.NearestMoveableCell(cell);
|
||||||
self.SetTargetLine(Target.FromCell(self.World, targetLocation), Color.Yellow);
|
self.SetTargetLine(Target.FromCell(self.World, targetLocation), Color.Yellow);
|
||||||
self.QueueActivity(order.Queued, new DeliverUnit(self, targetLocation));
|
self.QueueActivity(order.Queued, new DeliverUnit(self, targetLocation));
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user