<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: HowardPeter</title>
    <description>The latest articles on Forem by HowardPeter (@howardpeter).</description>
    <link>https://forem.com/howardpeter</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3263937%2F61f7c669-91f0-441a-86c5-70c5e04db06f.jpeg</url>
      <title>Forem: HowardPeter</title>
      <link>https://forem.com/howardpeter</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/howardpeter"/>
    <language>en</language>
    <item>
      <title>🚀 Building a Space Shooter Game with Amazon Q CLI</title>
      <dc:creator>HowardPeter</dc:creator>
      <pubDate>Fri, 13 Jun 2025 14:51:19 +0000</pubDate>
      <link>https://forem.com/howardpeter/building-a-space-shooter-game-with-amazon-q-cli-41eb</link>
      <guid>https://forem.com/howardpeter/building-a-space-shooter-game-with-amazon-q-cli-41eb</guid>
      <description>&lt;h2&gt;
  
  
  🧠 Overview
&lt;/h2&gt;

&lt;p&gt;As part of the "Build Games with Amazon Q CLI" challenge by the AWS Community, I decided to bring a classic arcade-style game to life: a Space Shooter built with Python and Pygame. With the help of Amazon Q CLI, I was able to rapidly prototype, refactor, and build a modular game with surprising ease – and yes, all while scoring a cool T-shirt!&lt;/p&gt;

&lt;h3&gt;
  
  
  💡 Why Amazon Q CLI?
&lt;/h3&gt;

&lt;p&gt;Amazon Q CLI is more than just a chatbot in your terminal — it's like pairing with a senior developer. Here's why I found it so useful for this project:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Fast prototyping&lt;/strong&gt;: I could describe game logic or a mechanic and get all the Python code files.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Instant debugging&lt;/strong&gt;: AI spotted logic errors and suggested fixes right away.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Context-aware&lt;/strong&gt;: It understood the structure of my project and improved it over time.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Documentation help&lt;/strong&gt;: Even helped me generate docstrings and README content.
This was my first time using Q CLI in a full-cycle project, and the experience was seamless.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  ⚙️ Installation
&lt;/h2&gt;

&lt;p&gt;I followed the instructions in &lt;a href="https://docs.aws.amazon.com/amazonq/latest/qdeveloper-ug/command-line-installing.html" rel="noopener noreferrer"&gt;Install Amazon Q CLI guide&lt;/a&gt;. And this is what I have after installation:&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fv7hmm9u21w6qqdf3oy8z.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fv7hmm9u21w6qqdf3oy8z.png" alt="Image description" width="800" height="509"&gt;&lt;/a&gt;&lt;br&gt;
You can use the &lt;a href="https://marketplace.visualstudio.com/items?itemName=AmazonWebServices.amazon-q-vscode&amp;amp;refid=6eb5b981-4304-4ec8-9caa-6f159b2ee54f" rel="noopener noreferrer"&gt;Amazon Q Extension&lt;/a&gt; instead :&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwz371orglz5dnc0ddga0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwz371orglz5dnc0ddga0.png" alt="Image description" width="588" height="1410"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  🎮 The Making
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🎯 Why a Space Shooter?
&lt;/h3&gt;

&lt;p&gt;I wanted something:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Visually interactive&lt;/li&gt;
&lt;li&gt;Simple enough to build in a short time&lt;/li&gt;
&lt;li&gt;Nostalgic&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🏗️ My Development Process with Amazon Q CLI
&lt;/h3&gt;

&lt;p&gt;I started with a single high-level prompt asking Amazon Q CLI to build a basic space shooter with a player, enemies, and bullet mechanics. This gave me a great initial structure to work from.&lt;br&gt;
From there, I followed an iterative approach:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I added individual features one by one through separate prompts (e.g., health bar, score system, shooting cooldown).&lt;/li&gt;
&lt;li&gt;After each new piece of code was generated, I tested the game immediately.&lt;/li&gt;
&lt;li&gt;This prompt → test → refine cycle helped me build and polish the game smoothly.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🔍 Prompting Techniques that Worked
&lt;/h3&gt;

&lt;p&gt;Here are some prompt patterns that got great results:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;"Write a Pygame space shooting game, using images in @Assets. The player can move horizontally by arrow buttons, press the spacebar to shoot, and the enemy is spawned in a rectangular block."&lt;/li&gt;
&lt;li&gt;"Add a healthbar for player (max=100, min=0), health minus 30 when player gets hit by enemy bullet"&lt;/li&gt;
&lt;li&gt;"Make enemies shoot at randomized intervals every 5 seconds, and enemies can move automatically in a horizontal direction."&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  🖼️ Screenshots
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnfx8hlxo7we6vh6qouzi.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnfx8hlxo7we6vh6qouzi.jpg" alt="Image description" width="800" height="599"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fb343k7nhzv83hr39ytqh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fb343k7nhzv83hr39ytqh.png" alt="Image description" width="800" height="593"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6wt3mq0hfjo7ihtsy2vn.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6wt3mq0hfjo7ihtsy2vn.jpg" alt="Image description" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  📝 Summary
&lt;/h2&gt;

&lt;p&gt;Amazon Q CLI significantly sped up my game development process and helped tackle classic Pygame challenges. I highly recommend it to any solo devs or learners who want a smart assistant in their terminal.&lt;br&gt;
This Space Shooter was a fun, nostalgic build — and more importantly, it reminded me how AI can help us be more creative, not less.&lt;br&gt;
Feel free to check out the &lt;a href="https://github.com/HowardPeter/amazon-q-shooting-game.git" rel="noopener noreferrer"&gt;GitHub repo&lt;/a&gt; and try the game yourself!&lt;br&gt;
And don't forget to join the challenge with #AmazonQCLI 🚀&lt;/p&gt;

</description>
      <category>amazonqcli</category>
      <category>awscommunity</category>
      <category>awschallenge</category>
      <category>gamechallenge</category>
    </item>
  </channel>
</rss>
