Duplicate code.
Merge origin/master
Remove warnings and use GTP.tiles.TOTAL_TILES for constants.