Who pays for real property in condo when condo association performs demolition of roof and walls?

Read your governing documents to determine ownership. There is a line between what a unit owner owns and what all unit owners own in common with all other owners.

Ownership may determine who pays, and it may not, depending on the motivation to perform demolition of roof and walls. As well, and again this is an ownership issue: which roof(s) and which wall(s) -- interior or exterior, building envelope or not?