trying to make the move function work