var MTKonamicode=new Class({Implements:[Options,Events],options:{keys:["up","up","down","down","left","right","left","right","b","a"]},enteredCode:[],initialize:function(a){this.setOptions(a);keyboardEvent=new Keyboard({caseSensitive:true,events:(function(){events={};this.options.keys.each(function(b){if(events[b]){return}events[b]=this.checkKonami.bindWithEvent(this)}.bind(this));return events}.bind(this))()}).activate()},checkKonami:function(c){if(c.key){var a=c.key}else{return}this.enteredCode.push(a);var b=this.options.keys.slice(0,this.enteredCode.length);if(this.enteredCode.join(",")!=b.join(",")){this.enteredCode=[]}else{this.fireEvent("keyup",[a,this.enteredCode]);if(this.enteredCode.join(",")==this.options.keys.join(",")){this.fireEvent("win");this.enteredCode=[]}}}});