Adapt structree for changes from the balancing branch. This was SVN commit r16308.
Taken from https://github.com/s0600204/0ad-structree-mod with some improvements from my fork. On small resolutions some buildings might not be fully visible (see #3038). This was SVN commit r16276.