Changed route layer to graphics layer. Some other refactoring of entity code.