public Piece(PieceType type, int size) { System.Diagnostics.Debug.Assert(type != null, "type cannot be null in piece!"); this.type = type; this.size = size; }
public bool Matches(PieceType other) { return((this != MatchNone && other != MatchNone) && ((this == MatchAll || other == MatchAll) || (index == other.index))); }