packages/app/keyboardCannon
k

keyboardCannon

v4bd72ebapp

A simple game built with Odin to teach my kids to use the keyboard

0 stars0 forksUnknownupdated 5 hours ago
Open repo

Keyboard Cannon - built with Odin!

A simple game built with Odin to teach my kids to use the keyboard. Boulders fall from the top of the screen and you destroy them by typing the letters shown in your ammo bank to load your cannon, then firing. The cannon always auto-aims at the current boulder — the goal is typing speed and accuracy, not aiming. You have 3 lives; a boulder that reaches the bottom costs one.

Cannon and boulder art is pixel art you can redraw yourself (or let your kids draw!) from the Settings menu — see "Customize Art" below.

Build & run

Requires the Odin compiler on your PATH.

.\build.ps1        # build KeyboardCannon.exe
.\build.ps1 -Run   # build and launch immediately

or directly:

odin build src -out:KeyboardCannon.exe -subsystem:windows -resource:icon.rc
.\KeyboardCannon.exe

Controls

Settings Menu

  • UP / DOWN — select a row
  • LEFT / RIGHT — change the selected setting
  • ENTER / SPACE — start playing, or open the selected row's screen

Playing

  • Type the highlighted letter in the ammo bank to load it into the cannon
  • SPACE — fire once enough letters are loaded
  • ESC — pause (Resume / Quit to Menu)

Name Entry

  • Type your name, ENTER to save, ESC to skip

Customize Art (pixel editor, reached from Settings)

  • LEFT / RIGHT / TAB — switch between editing the Cannon and the Boulder
  • Click a palette swatch to select a color (the first swatch is the eraser)
  • Left-click/drag on the canvas to paint, right-click/drag to erase
  • On-screen buttons (or C / R / Enter / Esc): Clear, Reset to Default, Save & Back, Cancel

Project layout

  • src/ — game source, one package main split across files by concern: main.odin (init + loop), types.odin (shared data), theme.odin (palette/typography), background.odin (sky + clouds), gameplay.odin (Playing screen logic), render.odin (Playing screen drawing), menu.odin (Settings/Name Entry drawing), sprites.odin (pixel art data + default art), sprite_editor.odin (the in-game pixel editor), audio.odin (procedural sound effects), highscores.odin (score persistence)
  • assets/RobotoMono-Bold.ttf — UI font, embedded into the exe at compile time (not needed alongside the built exe)
  • assets/default_cannon.png — the built-in default cannon art, also embedded into the exe at compile time
  • assets/sprites/ — saved custom cannon/boulder art (created the first time you save in the editor; overrides the embedded default when present, but isn't required)
  • design/ — source art not needed to build or run the game (e.g. the original SVG the default cannon art and exe icon were derived from)
  • icon.ico / icon.rc — the exe's file/taskbar icon, embedded at build time via -resource:
  • highscores.txt — local high-score file (not tracked in git)

License

Licensed under PolyForm Noncommercial 1.0.0 — free to play, modify, and share for any noncommercial purpose. Selling this game or using it commercially is not permitted without permission from the author.

Package Info
Version
v4bd72eb
License
Unknown
Author
@leePounds
Type
app
Forks
0
Created
9 hours ago
Updated
5 hours ago
Health
maintained
has releases
has readme
has license
Activity
last 56 weeks