Pakistan is playing with fire. It can’t realistically win a full scale war without China’s help.
And China’s famously conservative leadership is not going to do much other than the usual diplomatic call for peace. And yet it will be blamed in the end anyway.
To win a protracted war, China needs to help Pakistan like how U.S. helped Israel.
China never backed off from a war near its border (see past history of 1951 Korean War, 1962 Indian war, and 1979 Vietnam war) as long as it happens near the border, outside of its territory. I am not saying China will invade India on Pakistan's behalf, however, some sort of actual military operation can not be ruled out.
It's naive to always think China will be peaceful. Yes China had been advocating for peace, but China will fight wars if it's near border for its national interests.