functions to determine how a piece can move added