CenterLocation.ToCPos() -> CenterPosition.ToCPos().
This commit is contained in:
@@ -33,7 +33,7 @@ namespace OpenRA.Mods.RA.Activities
|
||||
if (IsCanceled) return NextActivity;
|
||||
if (!Target.IsValid) return NextActivity;
|
||||
|
||||
var inRange = ( Target.CenterLocation.ToCPos() - self.Location ).LengthSquared < Range * Range;
|
||||
var inRange = ( Target.CenterPosition.ToCPos() - self.Location ).LengthSquared < Range * Range;
|
||||
|
||||
if( inRange ) return this;
|
||||
if (--nextPathTime > 0) return this;
|
||||
|
||||
@@ -38,7 +38,7 @@ namespace OpenRA.Mods.RA.Activities
|
||||
|
||||
return Util.SequenceActivities(
|
||||
new MoveAdjacentTo(Target.FromActor(rearmTarget)),
|
||||
mobile.MoveTo(rearmTarget.CenterLocation.ToCPos(), rearmTarget),
|
||||
mobile.MoveTo(rearmTarget.CenterPosition.ToCPos(), rearmTarget),
|
||||
new Rearm(self),
|
||||
new Repair(rearmTarget),
|
||||
this );
|
||||
|
||||
@@ -41,7 +41,7 @@ namespace OpenRA.Mods.RA.Activities
|
||||
}
|
||||
|
||||
ps1.heuristic = PathSearch.DefaultEstimator(mobile.toCell);
|
||||
var ps2 = PathSearch.FromPoint(self.World, mobile.Info, self, mobile.toCell, target.CenterLocation.ToCPos(), true);
|
||||
var ps2 = PathSearch.FromPoint(self.World, mobile.Info, self, mobile.toCell, target.CenterPosition.ToCPos(), true);
|
||||
var ret = self.World.WorldActor.Trait<PathFinder>().FindBidiPath(ps1, ps2);
|
||||
|
||||
return Util.SequenceActivities(mobile.MoveTo(() => ret), this);
|
||||
|
||||
Reference in New Issue
Block a user