Add DynamicFacingInit.

This commit is contained in:
teees
2016-06-05 11:44:19 +01:00
committed by Paul Chote
parent 8724ed29bc
commit 4fa3ecfafb
10 changed files with 110 additions and 34 deletions

View File

@@ -11,6 +11,13 @@ namespace OpenRA.Mods.Common
public int Value(World world) { return value; }
}
public class DynamicFacingInit : IActorInit<Func<int>>
{
readonly Func<int> func;
public DynamicFacingInit(Func<int> func) { this.func = func; }
public Func<int> Value(World world) { return func; }
}
public class SubCellInit : IActorInit<SubCell>
{
[FieldFromYamlKey] readonly int value = (int)SubCell.FullCell;