Remove Order.TargetLocation from beacons.
This commit is contained in:
@@ -53,7 +53,7 @@ namespace OpenRA.Mods.Cnc.Traits
|
||||
if (order.OrderString != "PlaceBeacon")
|
||||
return;
|
||||
|
||||
var pos = self.World.Map.CenterOfCell(order.TargetLocation);
|
||||
var pos = order.Target.CenterPosition;
|
||||
|
||||
self.World.AddFrameEndTask(w =>
|
||||
{
|
||||
|
||||
@@ -53,14 +53,13 @@ namespace OpenRA.Mods.Common.Traits
|
||||
if (order.OrderString != "PlaceBeacon")
|
||||
return;
|
||||
|
||||
var pos = self.World.Map.CenterOfCell(order.TargetLocation);
|
||||
|
||||
self.World.AddFrameEndTask(w =>
|
||||
{
|
||||
if (playerBeacon != null)
|
||||
self.World.Remove(playerBeacon);
|
||||
|
||||
playerBeacon = new Beacon(self.Owner, pos, info.Duration, info.Palette, info.IsPlayerPalette, info.BeaconImage, info.ArrowSequence, info.CircleSequence);
|
||||
playerBeacon = new Beacon(self.Owner, order.Target.CenterPosition, info.Duration,
|
||||
info.Palette, info.IsPlayerPalette, info.BeaconImage, info.ArrowSequence, info.CircleSequence);
|
||||
|
||||
self.World.Add(playerBeacon);
|
||||
|
||||
@@ -75,7 +74,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
playerRadarPing = radarPings.Add(
|
||||
() => self.Owner.IsAlliedWith(self.World.RenderPlayer),
|
||||
pos,
|
||||
order.Target.CenterPosition,
|
||||
self.Owner.Color.RGB,
|
||||
info.Duration);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user