Move the IMove interface to Mods.Common.

This commit is contained in:
Paul Chote
2017-09-06 22:54:50 +01:00
committed by Oliver Brakmann
parent 0f6dda3f5f
commit e3212d1e64
6 changed files with 23 additions and 18 deletions

View File

@@ -288,24 +288,6 @@ namespace OpenRA.Traits
void SetVisualPosition(Actor self, WPos pos);
}
public interface IMoveInfo : ITraitInfoInterface { }
public interface IMove
{
Activity MoveTo(CPos cell, int nearEnough);
Activity MoveTo(CPos cell, Actor ignoreActor);
Activity MoveWithinRange(Target target, WDist range);
Activity MoveWithinRange(Target target, WDist minRange, WDist maxRange);
Activity MoveFollow(Actor self, Target target, WDist minRange, WDist maxRange);
Activity MoveIntoWorld(Actor self, CPos cell, SubCell subCell = SubCell.Any);
Activity MoveToTarget(Actor self, Target target);
Activity MoveIntoTarget(Actor self, Target target);
Activity VisualMove(Actor self, WPos fromPos, WPos toPos);
CPos NearestMoveableCell(CPos target);
bool IsMoving { get; set; }
bool IsMovingVertically { get; set; }
bool CanEnterTargetNow(Actor self, Target target);
}
[RequireExplicitImplementation]
public interface ITemporaryBlocker
{

View File

@@ -12,6 +12,7 @@
using System;
using System.Linq;
using OpenRA.Activities;
using OpenRA.Mods.Common.Traits;
using OpenRA.Traits;
namespace OpenRA.Mods.Common.Activities

View File

@@ -11,6 +11,7 @@
using System.Collections.Generic;
using OpenRA.Activities;
using OpenRA.Mods.Common.Traits;
using OpenRA.Traits;
namespace OpenRA.Mods.Common.Activities

View File

@@ -10,6 +10,7 @@
#endregion
using OpenRA.Activities;
using OpenRA.Mods.Common.Traits;
using OpenRA.Traits;
namespace OpenRA.Mods.Common.Activities

View File

@@ -10,6 +10,7 @@
#endregion
using OpenRA.Activities;
using OpenRA.Mods.Common.Traits;
using OpenRA.Traits;
namespace OpenRA.Mods.Common.Activities

View File

@@ -294,4 +294,23 @@ namespace OpenRA.Mods.Common.Traits
{
IEnumerable<object> ActorPreviewInits(ActorInfo ai, ActorPreviewType type);
}
public interface IMoveInfo : ITraitInfoInterface { }
public interface IMove
{
Activity MoveTo(CPos cell, int nearEnough);
Activity MoveTo(CPos cell, Actor ignoreActor);
Activity MoveWithinRange(Target target, WDist range);
Activity MoveWithinRange(Target target, WDist minRange, WDist maxRange);
Activity MoveFollow(Actor self, Target target, WDist minRange, WDist maxRange);
Activity MoveIntoWorld(Actor self, CPos cell, SubCell subCell = SubCell.Any);
Activity MoveToTarget(Actor self, Target target);
Activity MoveIntoTarget(Actor self, Target target);
Activity VisualMove(Actor self, WPos fromPos, WPos toPos);
CPos NearestMoveableCell(CPos target);
bool IsMoving { get; set; }
bool IsMovingVertically { get; set; }
bool CanEnterTargetNow(Actor self, Target target);
}
}