Skip to content
Achtung, die Kurve! in JavaScript
Branch: develop
Clone or download
SimonAlling Remove erroneous localStorage error message
The message would always appear on the first visit, even though nothing
was actually wrong.

Plan is to use the ts-preferences library instead of this ad-hoc system.
Latest commit 28a4e51 Apr 18, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information.
dev Fix scaling on HiDPI screens May 12, 2018
js Improve JS support check May 20, 2017
resources Fix PNG color issue Mar 27, 2017
screenshots Add screenshots Apr 17, 2019
src Remove erroneous localStorage error message Apr 18, 2019
CNAME Add CNAME file Mar 12, 2017
LICENSE Add AGPLv3 license Apr 6, 2019 Update readme to reflect recent changes Apr 6, 2017
ZATACKA.html Fix popup/history issues Apr 18, 2019
browserconfig.xml Add favicons May 29, 2016
favicon.ico Add favicons May 29, 2016
index.html Fix popup/history issues Apr 18, 2019
manifest.json Add favicons May 29, 2016
package-lock.json Fix some vulnerabilities Apr 7, 2019
package.json Add webpack-dev-server as dev dependency Mar 31, 2017
webpack.config.js Fix dev-server bug in webpack.config.js Apr 6, 2017

Achtung, die Kurve! in JavaScript

The aim of this project is to create an HTML5/JS remake of the original Achtung, die Kurve! from 1995.


The game will automatically scale itself up as much as possible; fullscreen is recommended for the best experience.



We use Webpack with Babel to transpile and pack all JS into one single file, zatacka.min.js.

To install the necessary software, first install Node and then run

npm install

in the root directory of this repo. This will install all the Node packages you need.


To build, run

npm run build

in the root of this repo.

To run a development server:

npm run watch

The difference is that build will write compiled JS files to disk, and you can see your changes simply by opening ZATACKA.html or index.html.

watch, on the other hand, does not write to disk, and you must visit localhost:8080 in your browser to see your changes. The advantage is that everything (both JS and CSS) is recompiled automatically when a file is modified.

Code structure

All JavaScript source files can be found in src/js/; SASS in src/css/.

js/ (in the root) contains compiled JS.

The main JS file is Main.js. It is responsible for creating a Game and supplying a config, a Renderer and a GUIController to it. It also adds Players to the Game and forwards key events to it.

Game.js controls the game logic. It knows which Players are in the game and handles their interaction with eachother and the playing field, and it controls progress throughout the individual rounds. The Game constructor must be passed a config object, a Renderer, and a GUIController.

Player.js describes a single player. It knows whether it is alive, where it is, where and how fast it is going, its score, and what Game it is attached to.

Renderer.js does all the drawing on the actual playing field. Game.js does not draw anything; it just calls upon its Renderer to do that.

GUIController.js controls the scoreboard and additional GUI features, such as hiding the lobby and showing the results when the game ends. When a player's score is changed, the Game will tell its GUIController to update the scoreboard entry of that player.

src/js/lib/ contains general libraries and help functions.

dev/ may only contain development tools that are not needed at runtime, such as test suites or code generators.

You can’t perform that action at this time.