Disentangling the role of connectivity, environmental filtering, and spatial structure on metacommunity dynamics