Fixes#2514 by only rendering individual unit icons when zoomed in and only rendering the units currently within the screen bounds.
Behaves as expected, but whether or not it has a significant performance increase under scaled up testing conditions remains to be seen.
Previously they were only hidden, but this didn't account for the annoying audio they play so now they're entirely staged like a spectator unit would be.
Adds an optional boolean paremeter to the setSpectator function for forcing the interface. It is forced by default, so if `false` is passed as the value the spectator will be able to close the interface with the escape button.
When the value of respawn delay is 0 the timing of the killed and respawn events can be a little strange and result in spectator being entered but never exited. The respawn template should just do nothing when the delay is so small.
Changes the position calculation of the external spectator camera to correctly retain the pan and tilt of the free camera. Makes transitioning between the two less disorienting for the user.
Using the "external" view is limited by the server difficulty setting. Instead the spectator external camera has been replaced with an oribtal camera as was originally planned to be added alongside the default views.
- Use a display rather than a dialog (contextually makes more sense).
- Move the entry/exit functionality to the setSpectator function. Preserves the handleInterface function for purely display related events and makes more sense.
- Fix missing semi-colon
A public API system to allow external systems to interrupt and resume the spectator interface. Also made use of it for the escape menu and zeus support.
If the spectator camera unit was set before the camera had ever opened then the unit list wouldn't be populated and as such the camera would automatically abort to free mode since the unit wasn't available to spectate.
So now I'm running the updateUnits function before opening the camera to pre-populate the list.
Type 0 worked, but the mission didn't end when all players were killed.
Type 1 didn't work because isPlayer isn't true for seagulls. So spectator virtual state is now entirely unassociated from objects in the game.