GithubHelp home page GithubHelp logo

deck-of-cards's Introduction

To the Magician's amongst you...

Set up

Once you've pulled the files down a simple

npm update

followed by

bower install

will pull down the appropriate dependancies

Then to run the projects

gulp serve

This will kick off a local server and start the app.

Interacting

Hit the Shuffle Deck button to scramble the initial deck of cards. This will activate the number stepper which can be used to select the number of cards you wish to withdraw.

Hitting Draw Cards will then extract the cards and display them in their unsorted order. To correctly order these according to required suits hit the Sort Cards buttons

Other Considerations

1 - All JS is documented inline. To generate a web version of this documentation run gulp dog-generation which will create a microsite in /app/docs/

2 - JS code is passing eslint tests bar a few warnings

3 - Code is being tested using QUnit with a test runner wrapper set up in /app/test-runner.html. Which can be browsed to when gulp serve is running

4 - Easter egg feature, allows for easy configuration of the suit ordering. in the app/data/data.json_ file simply edit the order of the characters in the suit_order node and the app will match this ruling at runtime. note Dont confuse this with the suite_graphic_order node which should not be edited as this is a permanent map to the order in which the grpaihcs for each suit are ordered in the card graphic sprite sheet

Revision History

Love git I do. But sometimes it just goes south. I'm not great at wrestling with exporting repos from one server to the other. So bummer - lost my revision history

Basic process followed: 1 - Inital project scaffolding 2 - Structured MVC framework to create model, control and view type classes 3 - Rolled in configuration and other vanity elements 4 - Worked up deck shuffle and retival logic 5 - Worked in resorting mechanism 6 - Connected app to UI and added pretty card graphics 7 - tidied up some eslint errors 8 - Documentation

Deck of Cards Artwork

Artwork credit - http://sourceforge.net/projects/vector-cards/

deck-of-cards's People

Contributors

pete-hotchkiss avatar

Watchers

 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.