Skip to content
Lutz Dornbusch edited this page Apr 6, 2022 · 3 revisions

FAQ

Why Qix?

Qix is a fascinating game, if you dive deeper into it. It was not as popular as PacMan or Donkey Kong but it has for learners some great advantages:

  • it is abstract (you do not need an Pixelartist.. Developerart for the win!)
  • it is simple (it has only 3 different opponents and a single playmode)
  • it is clever (the design, while simple shows all important aspects of an arcade game)

Why is everything in a single file?

This tutorial just want to get you started: so the easiest is open a (single) file and let the code run. I did not want to explain how import command work and the python concept of modules. In the end the source code has a lot of functions and (too much) global variables. But during the 10 days you see how you slowly sink into the chaos. What started as a nice clean single file solution gets messier as you are adding functions. This is a learning in this course: That you need to design your code even in small projects after some time.

Why are you not using OOP?

OOP is a strategy to model your software and to organize your source code. It uses classes and objects to separate data and routines into different domains. For a beginner a class model is very difficult to grasp and for a tutorial it is very difficult to understand unless you have some hundred lines of code and really search all over the place. Also the original code was (most probably) written in assembler and OOP was not a thing then. Last but least reason: Classes in Python are rather clumsy for beginners: you need to understand the module and import logic, you need to understand and remember to add self in front of each class member, etc. For a beginner these are difficulties which can be avoided.

What are the prerequisites for the game?

  • You need a python 3.x version and pygame

Clone this wiki locally