bodySizeIncrease() {
        const newSnakeBody = [snake.head()];
        let current_x = snake.head().x;
        let current_y = snake.head().y;
        for (let i = 1; i < this.snake_body.length; i++) {
            const this_tile = {
                x: this.snake_body[i].x,
                y: this.snake_body[i].y,
                col: this.snake_body[i].color
            }
            const prev_tile = {
                x: this.snake_body[i - 1].x,
                y: this.snake_body[i - 1].y
            }
            if (this_tile.x === prev_tile.x) {
                if (this_tile.y < prev_tile.y) {
                    current_y = prev_tile.y - this.snake_tile_size;
                } else {
                    current_y = prev_tile.y + this.snake_tile_size;
                }
            } else if (this_tile.y === prev_tile.y) {
                if (this_tile.x < prev_tile.x) {
                    current_x = prev_tile.x - this.snake_tile_size;
                } else {
                    current_x = prev_tile.x + this.snake_tile_size;
                }
            }
            newSnakeBody.push({
                x: current_x,
                y: current_y,
                color: this_tile.col
            })
        }
        return newSnakeBody;
    }
/**
     * Re-calculate snake tiles' positions when snake gains weight
     * @returns 
     */
Re-calculate snake tiles' positions when snake gains weight
@returns
Re - calculate snake tiles ' positions when snake gains weight @returns
bodySizeIncrease() {
        const newSnakeBody = [snake.head()];
        let current_x = snake.head().x;
        let current_y = snake.head().y;
        for (let i = 1; i < this.snake_body.length; i++) {
            const this_tile = {
                x: this.snake_body[i].x,
                y: this.snake_body[i].y,
                col: this.snake_body[i].color
            }
            const prev_tile = {
                x: this.snake_body[i - 1].x,
                y: this.snake_body[i - 1].y
            }
            if (this_tile.x === prev_tile.x) {
                if (this_tile.y < prev_tile.y) {
                    current_y = prev_tile.y - this.snake_tile_size;
                } else {
                    current_y = prev_tile.y + this.snake_tile_size;
                }
            } else if (this_tile.y === prev_tile.y) {
                if (this_tile.x < prev_tile.x) {
                    current_x = prev_tile.x - this.snake_tile_size;
                } else {
                    current_x = prev_tile.x + this.snake_tile_size;
                }
            }
            newSnakeBody.push({
                x: current_x,
                y: current_y,
                color: this_tile.col
            })
        }
        return newSnakeBody;
    }
bodySizeIncrease ( ) { const newSnakeBody = [ snake . head ( ) ] ; let current_x = snake . head ( ) . x ; let current_y = snake . head ( ) . y ; for ( let i = 1 ; i < this . snake_body . length ; i ++ ) { const this_tile = { x : this . snake_body [ i ] . x , y : this . snake_body [ i ] . y , col : this . snake_body [ i ] . color } const prev_tile = { x : this . snake_body [ i - 1 ] . x , y : this . snake_body [ i - 1 ] . y } if ( this_tile . x === prev_tile . x ) { if ( this_tile . y < prev_tile . y ) { current_y = prev_tile . y - this . snake_tile_size ; } else { current_y = prev_tile . y + this . snake_tile_size ; } } else if ( this_tile . y === prev_tile . y ) { if ( this_tile . x < prev_tile . x ) { current_x = prev_tile . x - this . snake_tile_size ; } else { current_x = prev_tile . x + this . snake_tile_size ; } } newSnakeBody . push ( { x : current_x , y : current_y , color : this_tile . col } ) } return newSnakeBody ; }
Re-calculate snake tiles' positions when snake gains weight
 @returns
Re - calculate snake tiles ' positions when snake gains weight @returns