Swap the position of two objects