When starting the game, choose 1 key, the player snake delay just the same as the AI snake delay, therefore, the player snake would move very fast, it's very hard to operate the snake.
For this problem, we use the timer's built-in function setDelay() to reset the time delay after we choose the game mode.
Created attachment 102 [details] Code implementation