fiixes in tile, update funcs, added tests in main