added indexposition and middle tile position to tile