MovingBlocks/Terasology — pull request #1407 by emanuele3d (2014-11-27 23:39:12+00:00)
Title: TerasologyEngine, some refactoring

Some refactoring in TerasologyEngine class, everything else is a consequence.

* reordered initial variables in related clusters where possible
* three engine state boolean variables made into one EngineState enum and added corresponding accessor methods, updated GameEngine interface accordingly
* renderingConfig is now its own variable initialized once instead of calling config.getRendering() multiple times in the class
* moved init() method's code to the constructor, refactored it adding support methods, updated GameEngine interface accordingly
* edited TeraEd and PC Facade to remove calls to no longer existing engine.init()
* reordered constructor-supporting methods: they are now in order of appearance and the have all been placed immediately after the constructor.
* renamed stopwatch variable from "sw" to "totalInitTime" for readability
* added an issue-pointing TODO regarding the Advanced Monitor

Many changes to TerasologyEngine, including most of these ones, had been previously discussed in PR #1108. I included in this PR only the least controversial (I think!). I will include some other changes from #1108 (i.e. javadocs) in a different PR.