Sure! Here's an example of a simple soccer game implemented in a single HTML file using JavaScript:
This code creates a simple soccer game where you control a player represented by a rectangle at the bottom of the field. The objective is to prevent the ball, represented by a circle, from reaching the top or bottom walls. You can use the left and right arrow keys to move the player horizontally. If the ball reaches the top or bottom wall, a goal is scored, and the game restarts.