예제 #1
0
 public PistonTile(Point triggerPosition, Point direction, bool isExtended = false)
     : base(isExtended ? Entity.None : new PistonEntity(direction))
 {
     TriggerPosition = triggerPosition;
     Direction = direction.EnsureDirection();
     IsExtended = isExtended;
 }
예제 #2
0
 public async Task<bool> MovePlayerAsync(Point direction)
 {
     direction.EnsureDirection();
     return await MoveAsync(PlayerPosition, PlayerPosition + direction);
 }