move() {
        if (this.pause) {
            return;
        }
        const head = { x: this.snake_body[0].x + this.dx * this.step(), y: this.snake_body[0].y + this.dy * this.step(), color: this.snake_body[0].color };
        for (var i = 0; i < this.snake_body.length - 1; i++) {
            this.snake_body[i].color = this.snake_body[i + 1].color;
        }
        this.snake_body.unshift(head);
        this.snake_body.pop();
    }
/**
     * Re-calculate snake tiles' positions at each move while preserving the order of tiles' colors
     * @returns 
     */
Re-calculate snake tiles' positions at each move while preserving the order of tiles' colors
@returns
Re - calculate snake tiles ' positions at each move while preserving the order of tiles ' colors @returns
move() {
        if (this.pause) {
            return;
        }
        const head = { x: this.snake_body[0].x + this.dx * this.step(), y: this.snake_body[0].y + this.dy * this.step(), color: this.snake_body[0].color };
        for (var i = 0; i < this.snake_body.length - 1; i++) {
            this.snake_body[i].color = this.snake_body[i + 1].color;
        }
        this.snake_body.unshift(head);
        this.snake_body.pop();
    }
move ( ) { if ( this . pause ) { return ; } const head = { x : this . snake_body [ 0 ] . x + this . dx * this . step ( ) , y : this . snake_body [ 0 ] . y + this . dy * this . step ( ) , color : this . snake_body [ 0 ] . color } ; for ( var i = 0 ; i < this . snake_body . length - 1 ; i ++ ) { this . snake_body [ i ] . color = this . snake_body [ i + 1 ] . color ; } this . snake_body . unshift ( head ) ; this . snake_body . pop ( ) ; }
Re-calculate snake tiles' positions at each move while preserving the order of tiles' colors
 @returns
Re - calculate snake tiles ' positions at each move while preserving the order of tiles ' colors @returns