Add plumbing for notifying traits of movement

More precisely, about start and stop of movement.
This commit is contained in:
reaperrr
2018-08-26 13:49:23 +02:00
committed by Paul Chote
parent 32ab822786
commit a10af382b4
15 changed files with 102 additions and 84 deletions

View File

@@ -33,7 +33,6 @@ namespace OpenRA.Mods.Common.Activities
protected override void OnFirstRun(Actor self)
{
targetStartPos = target.Positions.PositionClosestTo(self.CenterPosition);
mobile.IsMoving = true;
}
public override Activity Tick(Actor self)
@@ -84,11 +83,6 @@ namespace OpenRA.Mods.Common.Activities
return this;
}
protected override void OnLastRun(Actor self)
{
mobile.IsMoving = false;
}
public override IEnumerable<Target> GetTargets(Actor self)
{
yield return target;