From what I observe, the amount of cases could have dropped down because many people choose to not buy or somehow shield their property (sometimes just filling windows with bricks, for example, which looks weird). So I'm not sure it's because the okupas/govt/police somehow changed the direction, it's just like the people get better at protecting themselves.
Btw, bying an apartment in Barcelona costs you 10% tax already, that probably discourages most speculation (and the prices have been stagnant for a couple of years).