Git Product home page Git Product logo

pacman-kata's Introduction

Build Status Codacy Badge Sonar Badge

pacman-kata

This kata is designed to make some interesting game mechanics, parsing and rendering, and behaviours, by addressing the feature files one at a time.

Building and Testing

To build and test a particular language version, using your own platform's dev environment, type:

make {lang}

where {lang} can be java, node, go, python.

To build and test using docker containers to encapsulate the dev environment (in case you don't have a particular language installed) type:

make {lang}-docker

where {lang} can be java, node, go, python.

The root Makefile delegates the the language-specific Makefile in each language sub directory. If you look at the language-specific Makefile you'll see you can target specific steps of clean, deps, build,test, coverage and deploy for each language. What these steps mean is specific to each language.

The output of the docker builds means you can run your game implementation as a docker container, like this: docker run --rm -it {lang}-pacman where {lang} can be java, node, go, python.

Getting started with developing a solution

If you set the ENVIRONMENT variable BDD to anything, then make will switch off running tests against all features and only run those matching the tag.

e.g.

export BDD=@1
make test

will only test the java implementation with the first feature.

unset BDD
make test

will test the java implementation with all features.

See below for more info...

Developing using BDD

The features are tagged, to enable a way to incrementally add features to test. The first feature is tagged @test.

The order that I recommend in developing this implementation of the kata, are as follows:

  • Parsing
  • Rendering
  • Movement
  • Pills
  • Collision
  • Panic
  • Control
  • Gate
  • Level
  • WrapAround
  • Display
  • LevelMaps
  • Animation

The structure of this repo is described in more detail [here] (ReposStructure.md)

Once the basic features were implemented, I then focused on refactoring extensively to clean the code.

pacman

I also added colour support in, just for fun!

pacman-colour

for finding better chars to use for the maps, and designing a much more accurate sample maze!

pacman3

pacman-kata's People

Contributors

chrisesharp avatar iainduncani avatar

Watchers

Mike Cobbett avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.