How did the involvement of Communist China affect the course of the Korean war?