Space Invaders Game with GPT-4 and AI Textures
From Wikiprompt, the free prompt encyclopedia
Space Invaders Game with GPT-4 and AI Textures A step-by-step tutorial with prompts to build a Space Invaders game using GPT-4 for code and Midjourney for textures, including prompts for learning programming concepts.
Prompt ContentSave
π
1. Write this prompt in GPT-4: "write p5.js code of space invaders with my own textures"
2. Go to https://t.co/heHT5jdB9o create and save sketch (you'll need to save it before uploading any texture files). Copy paste code from GPT-4
3. Ask GPT-4 to generate textures by writing this prompt "Provide prompts so I can use those to generate images in Midjourney image generator for a ship, a bullet and an alien"
Use https://t.co/AWQgekBRul to remove backgrounds before uploading images to OpenProcessing
4. Replace the names of files with your filenames
5. Run the program
6. If something doesn't work ask GPT-4 to fix it (you can copy an error and paste into GPT-4) like you would ask a human programmer. If after many attempts you can't fix all the problems with the code, ask it to "forget everything and start over"
7. To learn a bit of programming write these prompts to GPT-4: "Act as my programming teacher. Tell me an algorithm of Asteroids game in detail and make names of functions and explain what each of these functions will do. Don't write the code just yet." and then "Can you describe the algorithm overall for a 10-year-old child"
Sign in to see the full prompt
Continue with:
By logging in, you agree to our Terms of Use and Privacy Policy
Usage
This prompt is designed for use with coding. Copy the prompt content above and paste it into your preferred AI tool.
For best results, you may customize the placeholders (indicated by square brackets or capital letters) with your specific requirements.
References
- Category: coding Prompts
- Source: https://x.com/icreatelife/status/1656040361540632584
Talk
0 comments