
Anyone can participate and most of the steps are simple…most of them. This particular dance has been keeping people on their toes, novice or expert, for decades now and with good reason it’s one of the most fun dances there is. jQuery is a library used extensively in this project to easily create and modify HTML DOM nodes in the web page.Even if, by some strange chance, you have no idea of what the ‘Git Up’ dance challenge is, you are almost sure to know about the glory that is line dancing.Allow users of the the site create their own dancers on the fly by picking dancing behaviors from a list and uploading their own dancer image!.Use HTML5 tags to add some hot beats for your dancers to move and groove to.Trig class was a waste of time, right? WRONG! Use polar coordinates to trace out some sweet paths for your dancers to follow across the floor.Make your dancers break out in a moving conga line after having them line up.Try creating multiple dance floors with their own unique properties for the dancers to inherit.Try using some CSS3 transitions to do cool special effects with your dancers.Make a dancer that reacts to the mouse (use jQuery to add a mouseover handler). For example, by iterating across the array window.dancers and using the Pythagorean Theorem to calculate your distance from each other dancer, you can have a dancer find its n closest neighbors and do something based on their positions. Make dancers that interact with other dancers. Use an image ( tag or CSS background-image) instead of plain-jane RGB to add some pizzazz! You'll need to add a lineUp method to each of your dancer types - they don't all have to do exactly the same thing. Remember you've got a global array of all created dancers (it's defined in src/init.js) so you can loop through that array and tell each object to lineUp. Make a button that, when clicked, tells all the dancers to line up against one side of the dance floor. Make your dancers visually distinct and adorable with CSS and JS! Dancer > SuperHeroDancer > BatmanDancer.Dancer > FightingDancer > ZangiefDancer.Having trouble coming up ideas? Here are some example hierarchies: Use spec/blinkyDancerSpec.js as a template for new test files, and make sure to include them in SpecRunner.html. Add a link in the top bar of dancefloor.html to create a dancer of each new type you create.This will require creating a new factory function for each one (and making sure that your new javascript files are included in dancefloor.html).
#The git up dance code#

How dancefloor.html, src/init.js, src/dancer.js, and src/blinkyDancer.js relate.


spec contains a few tests-you'll be adding more.src contains dancer.js and blinkyDancer.js with some code that you'll refactor and then extend with new types of dancers.dancefloor.html a dancer-indiscriminate stage.This ability of the Dancer class to manifest in various subclass forms is polymorphism.

By creating dancers that are subclasses of a Dancer class, you can exhibit individuality while allowing your dancers to inherit useful methods from their superclass. Dancers, for example, all display individual unique traits, however they also share the ability to dance, to stop dancing, and to line up. When constructing applications, it is often the case that you will need to construct objects that share common methods or traits. An exploration in polymorphism and inheritance.
