Add plumbing for custom movement layers.

This commit is contained in:
Paul Chote
2017-01-04 18:10:46 +00:00
parent 695a572dc3
commit 2bd5a392d1
12 changed files with 207 additions and 56 deletions

View File

@@ -233,4 +233,18 @@ namespace OpenRA.Mods.Common.Traits
[RequireExplicitImplementation]
public interface IGainsExperienceModifier { int GetGainsExperienceModifier(); }
[RequireExplicitImplementation]
public interface ICustomMovementLayer
{
byte Index { get; }
bool InteractsWithDefaultLayer { get; }
bool EnabledForActor(ActorInfo a, MobileInfo mi);
int EntryMovementCost(ActorInfo a, MobileInfo mi, CPos cell);
int ExitMovementCost(ActorInfo a, MobileInfo mi, CPos cell);
byte GetTerrainIndex(CPos cell);
WPos CenterOfCell(CPos cell);
}
}