Racetrack

   Racetrack is an awesome [1]minimalist [2]pen and paper mathematical
   [3]game in which one races a [4]car through track with the goal to finish
   it as quickly as possible. For PC gaymers we could describe it as "an
   extremely suckless version of [5]Trackmania" for which you don't even need
   a computer. It is similar to other pen and paper games such as [6]paper
   football. The basic idea is that of a car on a square grid that moves in
   steps -- in each step the player can adjust the car's current velocity a
   little bit (steer, accelerate, brake, ...) and so modify the velocity; the
   car must race to finish without crashing into walls, the tricky part is
   that one has to make predictions just like in real race, for example
   approaching a curve one must go to the right side of the road and brake a
   bit.

   Racetrack is one of the best examples of what good games should look like,
   mainly because:

     * It is extremely [7]suckless, it may be implemented and played with the
       use of a [8]computer but can also be played without it, i.e. it has
       practically no [9]dependencies. In theory it can only be played in
       one's brain, making it [10]brain software.
     * It is extremely [11]free (as in freedom): firstly no one legally owns
       it and secondly its simplicity makes it free practically, anyone can
       play it and modify it regardless of where he lives, how much money he
       has, whether he has a computer -- even if one has no eyes or hands the
       game can still probably be played.
     * It may easily be played by any number of players, even solo. If one
       plays alone, he simply tries to find the fastest solution for given
       track. If multiple players play, they compete who finds the best
       solution.
     * It is [12]simple yet deep, the rules are very simple but to find the
       optimal solution for given track may get very difficult, especially if
       the track is somewhat complex and employs e.g. a number of checkpoints
       that can be taken in any order. This is probably an [13]NP hard
       problem and finding a good solution may require a lot of experience,
       intuition, advanced programming techniques such as [14]machine
       learning etc.
     * It's not a mere game but a whole playground and "platform", for
       example it may be used to teach [15]vector mathematics, programming
       (path finding, heuristic search, [16]evolutionary programming, ...),
       test machine learning algorithms etcetc.
     * It can be very nicely implemented on computers, even on very simple
       ones such as [17]8bits, without bloat such as [18]floating point, and
       is friendly to e.g. implementing replays, artificial intelligence etc.
     * The base version is extremely simple but may be extended greatly in
       various way, for example adding more rules or creating "rich" computer
       frontends; one may imagine e.g. a 3D frontend for the game with
       features such as bots, demo recording, different car skins, online
       multiplayer and leaderboards, track editor etc.
     * ...

Rules

   There is no single rule set -- as no one owns the game, rules may be
   modified and adjusted, which is very good. However there exist core rules
   that basically make the game what it is -- let us describe those right
   now.

   The game takes place on a 2D square grid (e.g. squared sheet of paper);
   the car can only ever occupy [19]integer coordinates, i.e. its position
   cannot be e.g. a fraction of a square (however if e.g. in some computer
   implementation the grid is dense enough, it may in theory practically give
   an impression of continuous space). (Some modifications may perhaps try to
   utilize different kinds of grids of more than two dimensions.)

   The car has a [20]velocity [21]vector which is initially [0,0] (i.e. the
   car is at rest). This vector can also only ever have integer components.
   The velocity vector is added to the car's position in each game step so
   that the car moves. For example car with position [3,2] and velocity
   [1,-1] will move to [4,1].

   At each step the player can make a slight modification of the car's
   velocity, typically the player has to choose a vector from range [-1,-1]
   to [1,1] that's added to current velocity; in other words the player can
   modify current velocity by changing each of its two components by -1, 0 or
   1. This makes for 9 possible choices at each game step, so the branching
   factor of the game is 9. This can be represented as racer steering,
   accelerating and braking. Of course modified version of the game may play
   around with this, e.g. an oil puddle may make player unable to modify
   velocity for one round etc.

   Any specific track has a start (some versions of the game may just make
   player always start at [0,0]), finish (which may be a point, line, area
   etc.) and walls representing obstacles; modified versions of the game may
   also have other things such as checkpoints, items (nitro, time stop, ...)
   and other objects (jump ramps, oil puddles, teleports, ...). The player
   must race to the finish, usually without crashing into walls because a
   crash into wall means the car stops immediately (in some versions in may
   just mean the game ends). Implementation of walls and crashes may somewhat
   differ: in some versions walls are actually borders of "solid" areas to
   which the player must never enter, in other versions walls may be just
   lines the player must not touch or cross. In simple versions of the game
   walls are really line segments that go between given grid points (this is
   possible the more KISS variant as walls too are just defined with vectors
   and collision detection may be quite simple), more complex versions may
   allow non-integer coordinates for walls, curved walls etc. Walls may also
   be implemented just as "filled squares", i.e. just saying some grid points
   are solid and inaccessible. Crash usually means that a player would make
   such illegal move and so his current velocity is set to [0,0] as a
   consequence, but an advanced version may also make the player move as
   close to the crash point as possible to make the behavior closer to
   reality; however this may be very non-trivial to do while assuring the
   behavior can't be "abused". [22]Collision detection can be implemented
   e.g. by checking if two lines intersect (if walls are just lines), or if a
   point belongs to given area (if walls are edges of areas), using
   [23]analytic geometry).

   The goal is basically always to finish the track in as few steps as
   possible.

   TODO: example, pictures, ...

Links:
1. minimalism.md
2. pen_and_paper.md
3. game.md
4. car.md
5. trackmania.md
6. paper_football.md
7. suckless.md
8. computer.md
9. dependency.md
10. brain_software.md
11. free_software.md
12. easy_to_learn_hard_to_master.md
13. np_hard.md
14. machine_learning.md
15. vector.md
16. evolutionary_programming.md
17. 8bit.md
18. float.md
19. integer.md
20. velocity.md
21. vector.md
22. collision_detection.md
23. analytic_geometry.md