Sure! Here's an example of a game about a fancy block shooting other blocks using JavaScript in a single HTML file:
This is a simple game where you control a fancy block at the bottom of the canvas to shoot down other random blocks falling from the top. The objective is to avoid the collision and survive as long as possible. Player movement is controlled using the left and right arrow keys. Whenever a block collides with the player, the game ends, and an alert is displayed. To restart the game, simply reload the page.
Please note that this is a basic implementation to give you an idea of how to create a game using HTML, CSS, and JavaScript. You can customize and enhance it further based on your desired features and gameplay mechanics.