public static Tetrimino ByPosition(TetriminoKind kind, Position position, Direction facingDirection) { return(new Tetrimino(kind, position, TetriminoHelper.GetFirstBlockPositionByPosition(position, kind, facingDirection), facingDirection)); }
private Tetrimino(TetriminoKind kind, Position position, Position firstBlockPosition, Direction facingDirection) { Kind = kind; Position = position; FacingDirection = facingDirection; FirstBlockPosition = firstBlockPosition; Blocks = TetriminoHelper.CreateOffsetedBlocks(kind, Position, facingDirection); }