I think the biggest trick is to actually get the "safe and healthy" regulations right, particularly when it comes to ongoing enforcement. There are cities where known unsafe apartment buildings just decay for years because there's no political will to hold the landlords accountable (unsurprisingly, tenants of these buildings tend to be poor and socially marginalized people).
There's also an issue (perhaps encompassing the above) of attracting real estate developers without selling out local government to them. As far as I can tell, they will fight tooth-and-nail for every regulatory concession, tax incentive and taxpayer infrastructure dollar they can possibly get, to the point of funding their buddies' campaigns for mayor/council. I doubt that there's any regulatory regime that's favorable enough to avoid this fight; it's not a matter of giving them enough, it's a matter of what they think they can extract.
Part of that is often rent control, which as a price ceiling directly causes quality drops beyond what people are generally willing to tolerate in exchange for a discount.
Even if rent control raises the risk, it's far from a requirement. These things also happen in cities whose state governments have banned rent control.
There's also an issue (perhaps encompassing the above) of attracting real estate developers without selling out local government to them. As far as I can tell, they will fight tooth-and-nail for every regulatory concession, tax incentive and taxpayer infrastructure dollar they can possibly get, to the point of funding their buddies' campaigns for mayor/council. I doubt that there's any regulatory regime that's favorable enough to avoid this fight; it's not a matter of giving them enough, it's a matter of what they think they can extract.