Skip to main content

A simple framework for Terminal-based games

Project description

Retro

A simple framework for Terminal-based games.

╔════════════════════════════════╗
║                                ║
║                                ║
║                                ║
║      *************             ║
║      *                         ║
║      *                         ║
║      **>                       ║
║             @                  ║
║                                ║
║                                ║
╠════════════════════════════════╣
║score: 153                      ║
║                                ║
╚════════════════════════════════╝

Layout

  • There are two panes, a fixed-size play area at the top and a state window at the bottom. When enabled, a sidebar containing debug messages is also shown.

Concepts and skills needed

  • We need to discuss immutability, and the difference between mutable objects and immutable values.

    • Specifically, we care about the difference between tuples and lists.
    • State must be immutable!
    • Objects are only ever equal to themselves.
  • The game is structured as a collection of agents which interact.

Design/pedagogical criteria

  • Make thinking visible.
    • Avoid subclasses; they require interaction with invisible parent attributes.
    • Instead, compose functionality from other classes which might be somewhat black-boxed.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

retro_games-2.5.0.tar.gz (21.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

retro_games-2.5.0-py3-none-any.whl (34.9 kB view details)

Uploaded Python 3

File details

Details for the file retro_games-2.5.0.tar.gz.

File metadata

  • Download URL: retro_games-2.5.0.tar.gz
  • Upload date:
  • Size: 21.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.4 {"installer":{"name":"uv","version":"0.11.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for retro_games-2.5.0.tar.gz
Algorithm Hash digest
SHA256 d2d0f38b284677af6e22cdb169581331134ea27cb7068accc4c07493c5f3e499
MD5 2695700879e77aefb2fde16be535b0a1
BLAKE2b-256 cf2a2b2bc3895e4b8984bddc770d02eab5ae888120aea2b2d40d524670194db4

See more details on using hashes here.

File details

Details for the file retro_games-2.5.0-py3-none-any.whl.

File metadata

  • Download URL: retro_games-2.5.0-py3-none-any.whl
  • Upload date:
  • Size: 34.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.4 {"installer":{"name":"uv","version":"0.11.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for retro_games-2.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2c390bccc98fc08276dd413fff0cf8b659682582e693abf2890ce772379d04d4
MD5 88ff1fd84dcc40d370747c88af3b6e36
BLAKE2b-256 a9a7f9aab0d792c41773b7fc2c66a6d0324f0c93e1cef214d4f26fcaec22c026

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page