refactoring to Tmx and Tmx.Server