Code Monkey home page Code Monkey logo

break-out's Introduction

#break-out check it out (work in progress)

##Tests

  • npm run test (run all tests)
  • npm run test:watch (run all tests and check for changes in files)

##Log

###2015-12-01

  • npm install --save-dev babel-core babel-cli babel-preset-es2015
  • npm install --save-dev mocha chai
  • run tests with: ./node_modules/mocha/bin/mocha --compilers js:babel-core/register --recursive
  • added npm scripts (test & test:watch)
  • npm install --save immutable
  • npm install --save-dev chai-immutable
  • created test/setup.js

(see http://teropa.info/blog/2015/09/10/full-stack-redux-tutorial.html for project setup )

  • implementend first tests and functions for scenes
  • added a scene reducer. possible changes between states need some rethinking, especially the initial state - but it's enough for today

###2015-12-02

  • used reducer function with array.reduce in a test just to make it clear why it's called a reducer function :-)
  • npm install --save redux
  • implemented the store with tests
  • added index.html
  • npm install --save-dev webpack webpack-dev-server
  • setup index.js and webpack config
  • npm install --save-dev babel-loader
  • added npm task to serve application: npm run serve
  • application is accessible at http://localhost:8080/webpack-dev-server/index.html
  • implemented very simple frontend. it just writes the current scene as text. Actions can be dispatched with simple mouse clicks. Press ESC while GAME is the current scene to GAME_OVER...

###2015-12-03

  • render scenes to canvas (with very nice colors)
  • added functions and reducer for paddle movement
  • created gh-pages branch for this repo.

###2015-12-04

  • major refactorings to be able to combine reducers - lesson learned...
  • ... and it moves! implementing paddle movement was a breeze...

###2015-12-05

  • adding a moving ball
  • collision detection and game over...

###2015-12-6 - 2015-12-15

  • removed reducers. theres only one reducer left - because it does not make sense to split them yet (yagni?)
  • added bricks, collision detection
  • the state tree is now visible when playing the game
  • i was not fully aware that you're able to mutate an object inside an immutable list - using Object.assign() solved the problem. I'll implement my next project without Immutable.js jus t to practice ES2015 features.

###2015-12-16/17

  • extract key codes to constants in separate file. Are there any open source key code modules yet?
  • extract rendering functions from main application file
  • action creators

###2015-12-18

  • fixed a small bug where the speed of the paddle was updated while not in game scene

##TODOs constants for key codes

extract render functions from index.js

constants for action types

  • use ball radius in collision detection

set speed only when in game scene

  • fancy gh-page and reasonable build/ deploy

break-out's People

Contributors

mburri avatar

Stargazers

 avatar

Watchers

 avatar  avatar  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.