fixing bug with tile position