Sure! Here's an example of a simple text-based game where you rob a bank implemented in a single HTML file using JavaScript:
To play the game, simply open the HTML file in a web browser, and follow the prompts to enter your player name and choose a weapon. Then, try to enter the correct vault code within 3 attempts to successfully rob the bank. Good luck!