Overview
This prompt aims to guide a language model in creating a complete HTML game project based on user input. Programmers and game developers will benefit by receiving ready-to-use code for their game ideas.
Prompt Overview
Purpose: This system prompt aims to guide a language model in generating a complete HTML game project based on user input.
Audience: The intended users are developers or hobbyists looking to create simple web-based games without extensive coding knowledge.
Distinctive Feature: The generated game will be fully functional, optimized, and contained within a single HTML file, ensuring ease of use.
Outcome: Users will receive a playable game along with a clear structure and comments for better understanding and customization.
Quick Specs
- Media: Text
- Use case: HTML game project generation
- Techniques: Code generation, Optimization, Planning
- Models: GPT-3.5
- Estimated time: Instant
- Skill level: Intermediate
Variables to Fill
No inputs required — just copy and use the prompt.
Example Variables Block
No example values needed for this prompt.
The Prompt
Create a detailed system prompt for a language model to generate a complete HTML game project based on a user-supplied text prompt.
The project must include fully runnable HTML code that integrates CSS and JavaScript to implement the entire game. The user will provide a description of the game they want, and the model will output all necessary code for that game.
**Requirements:**
– The output must consist of a complete game contained entirely within HTML, CSS, and JavaScript files.
– The game should be minimal, optimized, and under 20 MB when packaged.
– Include comments in the code where helpful for clarity.
– The generated game must be fully functional and playable in modern web browsers without external dependencies.
– When requested, provide a brief explanation of the structure of the generated code or any key features.
**# Steps**
1. Receive the user prompt describing the desired game.
2. Plan the structure of the game:
– HTML layout
– CSS styling
– JavaScript logic
3. Generate the full HTML file embedding CSS and JavaScript.
4. Ensure the code is minimal and efficient to maintain a size under 20 MB.
5. Provide the complete code as output.
**# Output Format**
– Provide a single complete HTML file that includes embedded CSS and JavaScript.
– Enclose the code in markdown triple backticks with the language identifier `html`.
– Optionally, include a brief explanation in plain text before or after the code block.
**# Notes**
– Avoid large external libraries or assets to maintain minimal size.
– Optimize images and assets using base64 or inline methods where necessary to keep size minimal.
– The game can be simple but must effectively showcase core gameplay as requested by the user.
– Reason carefully about performance and size constraints before generating the code.
Screenshot Examples
How to Use This Prompt
- Copy the prompt provided above.
- Paste the prompt into your language model interface.
- Provide a description of your desired game.
- Request the model to generate the complete HTML code.
- Review the generated code for functionality and clarity.
- Test the game in a modern web browser.
Tips for Best Results
- Keep it Simple: Start with a minimal game concept to ensure feasibility.
- Optimize Assets: Use base64 encoding for images to reduce file size.
- Comment Your Code: Include comments in HTML, CSS, and JavaScript for clarity.
- Test Across Browsers: Ensure the game runs smoothly in all modern web browsers.
FAQ
- What is the purpose of the system prompt?
To guide a language model in generating a complete HTML game project based on user input. - What should the generated game include?
Fully runnable HTML code with integrated CSS and JavaScript, ensuring functionality in modern browsers. - How should the code be structured?
The code must have a clear HTML layout, CSS styling, and JavaScript logic, with comments for clarity. - What are the size constraints for the game?
The game must be minimal and optimized, remaining under 20 MB when packaged.
Compliance and Best Practices
- Best Practice: Review AI output for accuracy and relevance before use.
- Privacy: Avoid sharing personal, financial, or confidential data in prompts.
- Platform Policy: Your use of AI tools must comply with their terms and your local laws.
Revision History
- Version 1.0 (February 2026): Initial release.


