better logic for rotating pieces