Game engine

* general cleanup
* Restructure: EngineQuery and query methods