Split handleNetMessage into five smaller functions.
Besides improving the readability a bit, it allows adding new variables
without declaring them in the scope of other messagetypes.
This was SVN commit r17442.
Split the 280-line function initGUIObjects (former initMain) into
sixteen short functions.
Do not correct indentation in this commit in order to have the smallest
changeset possible, highlighting the actual changes
[the only logic change being mapTypes.selected and mapFilters.selected
being set one function (initMoreOptions) earlier].
This was SVN commit r17435.
Rename initMain to initGUIObjects to clarify what the function does.
While init() sets globals without touching the GUI, initGUIObjects
updates all GUI controls after the first tick.
Rename loadGameAttributes to loadPersistMatchSettings as that's more
specific as to where the attributes are loaded from.
Add some JSDoc comments and a TODO for an annoying old bug.
Simplifiy to-boolean conversions by negating twice (!!)
This was SVN commit r17433.
Don't define variables inside switch-statements.
Move chat-font to global.
Rename host and an i to guid, newPlayer to newGUID to be more coherent.
Do early continues when finding joinings/leavings and swapping players.
This was SVN commit r17432.
Doing so follows the principle of least exposure and means those
variables will be destroyed when leaving the block (i.e. memory being
freed up earlier).
The blocks affected by this commit are short (mostly 3-5 lines).
The variables are not referenced before or after the block, nor in their
temporal dead zones.
This was SVN commit r17424.
No effort was done to prevent players from accessing it since it's
impossible to prevent them from doing so anyway.
Fixes#3387 .
This was SVN commit r17423.
Do not focus the maplist when entering the singleplayer gamesetup as
that actually doesn't have an effect (you can't scroll the maplist with
arrow-keys).
This was SVN commit r17422.
This autodetection has a higer priority than default.cfg, but lower
priority than local changes.
Note that after enabling these features some get disabled later on on
some drivers (Intel, software renderers).
Also note that mesa drivers only expose core profile OpenGL, and 0 A.D.
reads compatibility profile, so that on mesa drivers OpenGL4 is never
detected and these features are never enabled by default.
This was SVN commit r17412.