Nope, because they'll just setup a load of shell companies.
Any entity that buys a house zoned as residential has to pay a tax of 100% of the value of the house.
Private citizens get an exemption on this tax, if their main residence of which you can only have one, and are 18 or older.
CGT is 100% (Deductions for home improvements could be added)
The municipality builds affordable housing
The tax would probably need to be gradually increased as it would likely cause a bit of crash on the housing market, say over 10 years.
There is an obvious lack of political will to carry out such a measure and I'm sure that there are loads of unintended consequences