// Copyright 2009-2011 AbsoluteVisions.net.  All rights reserved.
//
// This is the new "Catch Me Widget" in action!  Just wait for the page to
// load, and a race car or two should slide out.  Move the cars around by
// hovering the mouse near them.  If you are fast enough, you can click on
// a car, and make it race off the page!  Or, you may wind up clicking on
// a page link, which resets everything, or sends you to one of our sponsors!
// Tip: Approach the car from the front.
//
// How's that for a clever way to get people to visit the sponsor pages!?
//
// Design notes:
//
// The cars were created using Google Sketchup, and the free models available
// there.  In fact, one of the cars came from the "MonsterGoogle" model!
//
// This is written entirely in JavaScript, and it works with IE and FireFox.
// Except for the sound effects, NO FLASH CODE IS USED.  To make the cars
// move around the page, it's all JavaScript, div tags, Events, and Math!
//
// This source code was developed by Joe Eakin, at AbsoluteVisions.net.
// It may NOT be copied or reused in any manner, without written permission
// from Joe Eakin.
//
// To contact me, please go to:
//
//    http://absolutevisions.net/contact-us.html

var soundManager=null;function SoundManager(aa,ba){this.flashVersion=8;this.debugMode=true;this.useConsole=true;this.consoleOnly=false;this.waitForWindowLoad=false;this.nullURL='null.mp3';this.allowPolling=true;this.useFastPolling=false;this.useMovieStar=false;this.bgColor='#ffffff';this.useHighPerformance=false;this.flashLoadTimeout=1000;this.wmode=null;this.allowFullScreen=true;this.defaultOptions={'autoLoad':false,'stream':true,'autoPlay':false,'onid3':null,'onload':null,'whileloading':null,'onplay':null,'onpause':null,'onresume':null,'whileplaying':null,'onstop':null,'onfinish':null,'onbeforefinish':null,'onbeforefinishtime':5000,'onbeforefinishcomplete':null,'onjustbeforefinish':null,'onjustbeforefinishtime':200,'multiShot':true,'multiShotEvents':false,'position':null,'pan':0,'volume':100};this.flash9Options={'isMovieStar':null,'usePeakData':false,'useWaveformData':false,'useEQData':false,'onbufferchange':null,'ondataerror':null};this.movieStarOptions={'onmetadata':null,'useVideo':false,'bufferTime':null};var ca=null;var _s=this;this.version=null;this.versionNumber='V2.95a.20090717';this.movieURL=null;this.url=null;this.altURL=null;this.swfLoaded=false;this.enabled=false;this.o=null;this.id=(ba||'sm2movie');this.oMC=null;this.sounds={};this.soundIDs=[];this.muted=false;this.isFullScreen=false;this.isIE=(navigator.userAgent.match(/MSIE/i));this.isSafari=(navigator.userAgent.match(/safari/i));this.debugID='soundmanager-debug';this.debugURLParam=/([#?&])debug=1/i;this.specialWmodeCase=false;this._onready=[];this._debugOpen=true;this._didAppend=false;this._appendSuccess=false;this._didInit=false;this._disabled=false;this._windowLoaded=false;this._hasConsole=(typeof console!='undefined'&&typeof console.log!='undefined');this._debugLevels=['log','info','warn','error'];this._defaultFlashVersion=8;this._oRemoved=null;this._oRemovedHTML=null;var _$=function(da){return document.getElementById(da);};this.filePatterns={flash8:/\.mp3(\?.*)?$/i,flash9:/\.mp3(\?.*)?$/i};this.netStreamTypes=['aac','flv','mov','mp4','m4v','f4v','m4a','mp4v','3gp','3g2'];this.netStreamPattern=new RegExp('\\.('+this.netStreamTypes.join('|')+')(\\?.*)?$','i');this.filePattern=null;this.features={buffering:false,peakData:false,waveformData:false,eqData:false,movieStar:false};this.sandbox={'type':null,'types':{'remote':'remote (domain-based) rules','localWithFile':'local with file access (no internet access)','localWithNetwork':'local with network (internet access only, no local access)','localTrusted':'local, trusted (local + internet access)'},'description':null,'noRemote':null,'noLocal':null};this._setVersionInfo=function(){if(_s.flashVersion!=8&&_s.flashVersion!=9){alert('soundManager.flashVersion must be 8 or 9. "'+_s.flashVersion+'" is invalid. Reverting to '+_s._defaultFlashVersion+'.');_s.flashVersion=_s._defaultFlashVersion;}
_s.version=_s.versionNumber+(_s.flashVersion==9?' (AS3/Flash 9)':' (AS2/Flash 8)');if(_s.flashVersion>8){_s.defaultOptions=_s._mergeObjects(_s.defaultOptions,_s.flash9Options);_s.features.buffering=true;}
if(_s.flashVersion>8&&_s.useMovieStar){_s.defaultOptions=_s._mergeObjects(_s.defaultOptions,_s.movieStarOptions);_s.filePatterns.flash9=new RegExp('\\.(mp3|'+_s.netStreamTypes.join('|')+')(\\?.*)?$','i');_s.features.movieStar=true;}
else{_s.useMovieStar=false;_s.features.movieStar=false;}
_s.filePattern=_s.filePatterns[(_s.flashVersion!=8?'flash9':'flash8')];_s.movieURL=(_s.flashVersion==8?'soundmanager2.swf':'soundmanager2_flash9.swf');_s.features.peakData=_s.features.waveformData=_s.features.eqData=(_s.flashVersion>8);};this._overHTTP=(document.location?document.location.protocol.match(/http/i):null);this._waitingforEI=false;this._initPending=false;this._tryInitOnFocus=(this.isSafari&&typeof document.hasFocus=='undefined');this._isFocused=(typeof document.hasFocus!='undefined'?document.hasFocus():null);this._okToDisable=!this._tryInitOnFocus;this.useAltURL=!this._overHTTP;var ea='http://www.macromedia.com/support/documentation/en/flashplayer/help/settings_manager04.html';this.strings={notReady:'Not loaded yet - wait for soundManager.onload() before calling sound-related methods',appXHTML:'soundManager._createMovie(): appendChild/innerHTML set failed. May be app/xhtml+xml DOM-related.',localFail:'soundManager: Loading this page from local/network file system (not over HTTP?) Flash security likely restricting JS-Flash access. Consider adding current URL to "trusted locations" in the Flash player security settings manager at '+ea+', or simply serve this content over HTTP.',waitFocus:'soundManager: Special case: Waiting for focus-related event..',waitImpatient:'soundManager: Getting impatient, still waiting for Flash.. ;)',waitForever:'soundManager: Waiting indefinitely for Flash...',needFunction:'soundManager.onready(): Function object expected'};this.supported=function(){return(_s._didInit&&!_s._disabled);};this.getMovie=function(ba){return _s.isIE?window[ba]:(_s.isSafari?_$(ba)||document[ba]:_$(ba));};this.loadFromXML=function(fa){try{_s.o._loadFromXML(fa);}
catch(e){_s._failSafely();return true;}};this.createSound=function(ga){var ha='soundManager.createSound(): ';if(!_s._didInit){throw _s._complain(ha+_s.strings.notReady,arguments.callee.caller);}
if(arguments.length==2){ga={'id':arguments[0],'url':arguments[1]};}
var ia=_s._mergeObjects(ga);var ja=ia;if(ja.id.toString().charAt(0).match(/^[0-9]$/)){var ka=ha+'Warning: Sound ID "'+ja.id+'" should be a string, starting with a non-numeric character';_s._wD(ka,2);}
_s._wD(ha+ja.id+' ('+ja.url+')',1);if(_s._idCheck(ja.id,true)){_s._wD(ha+ja.id+' exists',1);return _s.sounds[ja.id];}
if(_s.flashVersion>8&&_s.useMovieStar){if(ja.isMovieStar===null){ja.isMovieStar=(ja.url.match(_s.netStreamPattern)?true:false);}
if(ja.isMovieStar){_s._wD(ha+'using MovieStar handling');}
if(ja.isMovieStar&&(ja.usePeakData||ja.useWaveformData||ja.useEQData)){_s._wD('Warning: peak/waveform/eqData features unsupported for non-MP3 formats');ja.usePeakData=false;ja.useWaveformData=false;ja.useEQData=false;}}
_s.sounds[ja.id]=new ca(ja);_s.soundIDs[_s.soundIDs.length]=ja.id;if(_s.flashVersion==8){_s.o._createSound(ja.id,ja.onjustbeforefinishtime);}
else{_s.o._createSound(ja.id,ja.url,ja.onjustbeforefinishtime,ja.usePeakData,ja.useWaveformData,ja.useEQData,ja.isMovieStar,(ja.isMovieStar?ja.useVideo:false),(ja.isMovieStar?ja.bufferTime:false));}
if(ja.autoLoad||ja.autoPlay){if(_s.sounds[ja.id]){_s.sounds[ja.id].load(ja);}}
if(ja.autoPlay){_s.sounds[ja.id].play();}
return _s.sounds[ja.id];};this.createVideo=function(la){if(arguments.length==2){la={'id':arguments[0],'url':arguments[1]};}
if(_s.flashVersion>=9){la.isMovieStar=true;la.useVideo=true;}
else{_s._wD('soundManager.createVideo(): flash 9 required for video. Exiting.',2);return false;}
if(!_s.useMovieStar){_s._wD('soundManager.createVideo(): MovieStar mode not enabled. Exiting.',2);}
return _s.createSound(la);};this.destroySound=function(ma,na){if(!_s._idCheck(ma)){return false;}
for(var i=0;i<_s.soundIDs.length;i++){if(_s.soundIDs[i]==ma){_s.soundIDs.splice(i,1);continue;}}
_s.sounds[ma].unload();if(!na){_s.sounds[ma].destruct();}
delete _s.sounds[ma];};this.destroyVideo=this.destroySound;this.load=function(oa,pa){if(!_s._idCheck(oa)){return false;}
_s.sounds[oa].load(pa);};this.unload=function(qa){if(!_s._idCheck(qa)){return false;}
_s.sounds[qa].unload();};this.play=function(ra,sa){if(!_s._didInit){throw _s._complain('soundManager.play(): '+_s.strings.notReady,arguments.callee.caller);}
if(!_s._idCheck(ra)){if(typeof sa!='Object'){sa={url:sa};}
if(sa&&sa.url){_s._wD('soundController.play(): attempting to create "'+ra+'"',1);sa.id=ra;_s.createSound(sa);}
else{return false;}}
_s.sounds[ra].play(sa);};this.start=this.play;this.setPosition=function(ta,ua){if(!_s._idCheck(ta)){return false;}
_s.sounds[ta].setPosition(ua);};this.stop=function(va){if(!_s._idCheck(va)){return false;}
_s._wD('soundManager.stop('+va+')',1);_s.sounds[va].stop();};this.stopAll=function(){_s._wD('soundManager.stopAll()',1);for(var wa in _s.sounds){if(_s.sounds[wa]
instanceof ca){_s.sounds[wa].stop();}}};this.pause=function(xa){if(!_s._idCheck(xa)){return false;}
_s.sounds[xa].pause();};this.pauseAll=function(){for(var i=_s.soundIDs.length;i--;){_s.sounds[_s.soundIDs[i]].pause();}};this.resume=function(ya){if(!_s._idCheck(ya)){return false;}
_s.sounds[ya].resume();};this.resumeAll=function(){for(var i=_s.soundIDs.length;i--;){_s.sounds[_s.soundIDs[i]].resume();}};this.togglePause=function(za){if(!_s._idCheck(za)){return false;}
_s.sounds[za].togglePause();};this.setPan=function(Aa,Ba){if(!_s._idCheck(Aa)){return false;}
_s.sounds[Aa].setPan(Ba);};this.setVolume=function(Ca,Da){if(!_s._idCheck(Ca)){return false;}
_s.sounds[Ca].setVolume(Da);};this.mute=function(Ea){if(typeof Ea!='string'){Ea=null;}
if(!Ea){_s._wD('soundManager.mute(): Muting all sounds');for(var i=_s.soundIDs.length;i--;){_s.sounds[_s.soundIDs[i]].mute();}
_s.muted=true;}
else{if(!_s._idCheck(Ea)){return false;}
_s._wD('soundManager.mute(): Muting "'+Ea+'"');_s.sounds[Ea].mute();}};this.muteAll=function(){_s.mute();};this.unmute=function(Fa){if(typeof Fa!='string'){Fa=null;}
if(!Fa){_s._wD('soundManager.unmute(): Unmuting all sounds');for(var i=_s.soundIDs.length;i--;){_s.sounds[_s.soundIDs[i]].unmute();}
_s.muted=false;}
else{if(!_s._idCheck(Fa)){return false;}
_s._wD('soundManager.unmute(): Unmuting "'+Fa+'"');_s.sounds[Fa].unmute();}};this.unmuteAll=function(){_s.unmute();};this.toggleMute=function(Ga){if(!_s._idCheck(Ga)){return false;}
_s.sounds[Ga].toggleMute();};this.getMemoryUse=function(){if(_s.flashVersion==8){return 0;}
if(_s.o){return parseInt(_s.o._getMemoryUse(),10);}};this.disable=function(Ha){if(typeof Ha=='undefined'){Ha=false;}
if(_s._disabled){return false;}
_s._disabled=true;_s._wD('soundManager.disable(): Shutting down',1);for(var i=_s.soundIDs.length;i--;){_s._disableObject(_s.sounds[_s.soundIDs[i]]);}
_s.initComplete(Ha);};this.canPlayURL=function(Ia){return(Ia?(Ia.match(_s.filePattern)?true:false):null);};this.getSoundById=function(Ja,Ka){if(!Ja){throw new Error('SoundManager.getSoundById(): sID is null/undefined');}
var La=_s.sounds[Ja];if(!La&&!Ka){_s._wD('"'+Ja+'" is an invalid sound ID.',2);}
return La;};this.onready=function(Ma,Na){if(Ma&&Ma instanceof Function){if(_s._didInit){_s._wD('soundManager.onready(): Queueing handler');}
if(!Na){Na=window;}
_s._addOnReady(Ma,Na);_s._processOnReady();return true;}
else{throw _s.strings.needFunction;}};this.oninitmovie=function(){};this.onload=function(){soundManager._wD('soundManager.onload()',1);};this.onerror=function(){};this._idCheck=this.getSoundById;this._complain=function(Oa,Pa){var Qa='Error: ';if(!Pa){return new Error(Qa+Oa);}
var e=new Error('');var Ra=null;if(e.stack){try{var Sa='@';var Ta=e.stack.split(Sa);Ra=Ta[4];}
catch(ee){Ra=e.stack;}}
if(typeof console!='undefined'&&typeof console.trace!='undefined'){console.trace();}
var Ua=Qa+Oa+'. \nCaller: '+Pa.toString()+(e.stack?' \nTop of stacktrace: '+stackMsg:(e.message?' \nMessage: '+e.message:''));return new Error(Ua);};var Va=function(){return false;};Va._protected=true;this._disableObject=function(o){for(var Wa in o){if(typeof o[Wa]=='function'&&typeof o[Wa]._protected=='undefined'){o[Wa]=Va;}}
Wa=null;};this._failSafely=function(Xa){if(typeof Xa=='undefined'){Xa=false;}
if(!_s._disabled||Xa){_s._wD('soundManager: Failed to initialise.',2);_s.disable(Xa);}};this._normalizeMovieURL=function(aa){var Ya=null;if(aa){if(aa.match(/\.swf(\?.*)?$/i)){Ya=aa.substr(aa.toLowerCase().lastIndexOf('.swf?')+4);if(Ya){return aa;}}
else if(aa.lastIndexOf('/')!=aa.length-1){aa=aa+'/';}}
return(aa&&aa.lastIndexOf('/')!=-1?aa.substr(0,aa.lastIndexOf('/')+1):'./')+_s.movieURL;};this._getDocument=function(){return(document.body?document.body:(document.documentElement?document.documentElement:document.getElementsByTagName('div')[0]));};this._getDocument._protected=true;this._setPolling=function(Za,$a){if(!_s.o||!_s.allowPolling){return false;}
_s.o._setPolling(Za,$a);};this._createMovie=function(ba,aa){var ab=null;var bb=(aa?aa:_s.url);var cb=(_s.altURL?_s.altURL:bb);if(_s.debugURLParam.test(window.location.href.toString())){_s.debugMode=true;}
if(_s._didAppend&&_s._appendSuccess){return false;}
_s._didAppend=true;_s._setVersionInfo();_s.url=_s._normalizeMovieURL(_s._overHTTP?bb:cb);aa=_s.url;if(_s.useHighPerformance&&_s.useMovieStar&&_s.defaultOptions.useVideo===true){ab='soundManager note: disabling highPerformance, not applicable with movieStar mode + useVideo';_s.useHighPerformance=false;}
_s.wmode=(!_s.wmode&&_s.useHighPerformance&&!_s.useMovieStar?'transparent':_s.wmode);if(_s.wmode!==null&&_s.flashLoadTimeout!==0&&!_s.useHighPerformance&&!_s.isIE&&navigator.platform.match(/win32/i)){_s.specialWmodeCase=true;_s._wD('soundManager note: Removing wmode, preventing off-screen SWF loading issue');_s.wmode=null;}
if(_s.flashVersion==8){_s.allowFullScreen=false;}
var db={name:ba,id:ba,src:aa,width:'100%',height:'100%',quality:'high',allowScriptAccess:'always',bgcolor:_s.bgColor,pluginspage:'http://www.macromedia.com/go/getflashplayer',type:'application/x-shockwave-flash',wmode:_s.wmode,allowfullscreen:(_s.allowFullScreen?'true':'false')};if(!_s.wmode){delete db.wmode;}
var eb=null;var fb=null;if(_s.isIE){eb=document.createElement('div');var gb='<object id="'+ba+'" data="'+aa+'" type="application/x-shockwave-flash" width="100%" height="100%"><param name="movie" value="'+aa+'" /><param name="AllowScriptAccess" value="always" /><param name="quality" value="high" />'+(_s.wmode?'<param name="wmode" value="'+_s.wmode+'" /> ':'')+'<param name="bgcolor" value="'+_s.bgColor+'" /><param name="allowFullScreen" value="'+(_s.allowFullScreen?'true':'false')+'" /><!-- --></object>';}
else{eb=document.createElement('embed');for(fb in db){if(db.hasOwnProperty(fb)){eb.setAttribute(fb,db[fb]);}}}
var oD=document.createElement('div');oD.id=_s.debugID+'-toggle';var hb={position:'fixed',bottom:'0px',right:'0px',width:'1.2em',height:'1.2em',lineHeight:'1.2em',margin:'2px',textAlign:'center',border:'1px solid #999',cursor:'pointer',background:'#fff',color:'#333',zIndex:10001};oD.appendChild(document.createTextNode('-'));oD.onclick=_s._toggleDebug;oD.title='Toggle SM2 debug console';if(navigator.userAgent.match(/msie 6/i)){oD.style.position='absolute';oD.style.cursor='hand';}
for(fb in hb){if(hb.hasOwnProperty(fb)){oD.style[fb]=hb[fb];}}
var ib=_s._getDocument();if(ib){_s.oMC=_$('sm2-container')?_$('sm2-container'):document.createElement('div');if(!_s.oMC.id){_s.oMC.id='sm2-container';_s.oMC.className='movieContainer';var s=null;var jb=null;if(_s.useHighPerformance){s={position:'fixed',width:'8px',height:'8px',bottom:'0px',left:'0px',overflow:'hidden'};}
else{s={position:'absolute',width:'8px',height:'8px',top:'-9999px',left:'-9999px'};}
var x=null;for(x in s){if(s.hasOwnProperty(x)){_s.oMC.style[x]=s[x];}}
try{if(!_s.isIE){_s.oMC.appendChild(eb);}
ib.appendChild(_s.oMC);if(_s.isIE){jb=_s.oMC.appendChild(document.createElement('div'));jb.className='sm2-object-box';jb.innerHTML=gb;}
_s._appendSuccess=true;}
catch(e){throw new Error(_s.strings.appXHTML);}}
else{_s.oMC.appendChild(eb);if(_s.isIE){jb=_s.oMC.appendChild(document.createElement('div'));jb.className='sm2-object-box';jb.innerHTML=gb;}
_s._appendSuccess=true;}
if(!_$(_s.debugID)&&((!_s._hasConsole||!_s.useConsole)||(_s.useConsole&&_s._hasConsole&&!_s.consoleOnly))){var kb=document.createElement('div');kb.id=_s.debugID;kb.style.display=(_s.debugMode?'block':'none');if(_s.debugMode&&!_$(oD.id)){try{ib.appendChild(oD);}
catch(e2){throw new Error(_s.strings.appXHTML);}
ib.appendChild(kb);}}
ib=null;}
if(ab){_s._wD(ab);}
_s._wD('-- SoundManager 2 '+_s.version+(_s.useMovieStar?', MovieStar mode':'')+(_s.useHighPerformance?', high performance mode, ':', ')+((_s.useFastPolling?'fast':'normal')+' polling mode')+(_s.wmode?', wmode: '+_s.wmode:'')+' --',1);_s._wD('soundManager._createMovie(): Trying to load '+aa+(!_s._overHTTP&&_s.altURL?' (alternate URL)':''),1);};this._writeDebug=function(lb,mb,nb){if(!_s.debugMode){return false;}
if(typeof nb!='undefined'&&nb){lb=lb+' | '+new Date().getTime();}
if(_s._hasConsole&&_s.useConsole){var ob=_s._debugLevels[mb];if(typeof console[ob]!='undefined'){console[ob](lb);}
else{console.log(lb);}
if(_s.useConsoleOnly){return true;}}
var pb='soundmanager-debug';try{var o=_$(pb);if(!o){return false;}
var qb=document.createElement('div');if(++_s._wdCount%2===0){qb.className='sm2-alt';}
if(typeof mb=='undefined'){mb=0;}
else{mb=parseInt(mb,10);}
qb.appendChild(document.createTextNode(lb));if(mb){if(mb>=2){qb.style.fontWeight='bold';}
if(mb==3){qb.style.color='#ff3333';}}
o.insertBefore(qb,o.firstChild);}
catch(e){}
o=null;};this._writeDebug._protected=true;this._wdCount=0;this._wdCount._protected=true;this._wD=this._writeDebug;this._wDAlert=function(rb){alert(rb);};if(window.location.href.indexOf('debug=alert')+1&&_s.debugMode){_s._wD=_s._wDAlert;}
this._toggleDebug=function(){var o=_$(_s.debugID);var oT=_$(_s.debugID+'-toggle');if(!o){return false;}
if(_s._debugOpen){oT.innerHTML='+';o.style.display='none';}
else{oT.innerHTML='-';o.style.display='block';}
_s._debugOpen=!_s._debugOpen;};this._toggleDebug._protected=true;this._debug=function(){_s._wD('--- soundManager._debug(): Current sound objects ---',1);for(var i=0,j=_s.soundIDs.length;i<j;i++){_s.sounds[_s.soundIDs[i]]._debug();}};this._debugTS=function(tb,ub,vb){if(typeof sm2Debugger!='undefined'){try{sm2Debugger.handleEvent(tb,ub,vb);}
catch(e){}}};this._debugTS._protected=true;this._mergeObjects=function(wb,xb){var o1={};for(var i in wb){if(wb.hasOwnProperty(i)){o1[i]=wb[i];}}
var o2=(typeof xb=='undefined'?_s.defaultOptions:xb);for(var o in o2){if(o2.hasOwnProperty(o)&&typeof o1[o]=='undefined'){o1[o]=o2[o];}}
return o1;};this.createMovie=function(yb){if(yb){_s.url=yb;}
_s._initMovie();};this.go=this.createMovie;this._initMovie=function(){if(_s.o){return false;}
_s.o=_s.getMovie(_s.id);if(!_s.o){if(!_s.oRemoved){_s._createMovie(_s.id,_s.url);}
else{if(!_s.isIE){_s.oMC.appendChild(_s.oRemoved);}
else{_s.oMC.innerHTML=_s.oRemovedHTML;}
_s.oRemoved=null;_s._didAppend=true;}
_s.o=_s.getMovie(_s.id);}
if(_s.o){_s._wD('soundManager._initMovie(): Got '+_s.o.nodeName+' element ('+(_s._didAppend?'created via JS':'static HTML')+')',1);if(_s.flashLoadTimeout>0){_s._wD('soundManager._initMovie(): Waiting for ExternalInterface call from Flash..');}}
if(typeof _s.oninitmovie=='function'){setTimeout(_s.oninitmovie,1);}};this.waitForExternalInterface=function(){if(_s._waitingForEI){return false;}
_s._waitingForEI=true;if(_s._tryInitOnFocus&&!_s._isFocused){_s._wD(_s.strings.waitFocus);return false;}
if(_s.flashLoadTimeout>0){if(!_s._didInit){_s._wD(_s.strings.waitImpatient);}
setTimeout(function(){if(!_s._didInit){_s._wD('soundManager: No Flash response within reasonable time after document load.\nPossible causes: Loading '+_s.movieURL+' failed, Flash version under '+_s.flashVersion+', no support, flash blocked or JS-Flash security error.',2);if(!_s._overHTTP){_s._wD(_s.strings.localFail,2);}
_s._debugTS('flashtojs',false,': Timed out'+(_s._overHTTP)?' (Check flash security or flash blockers)':' (No plugin/missing SWF?)');}
if(!_s._didInit&&_s._okToDisable){_s._failSafely(true);}},_s.flashLoadTimeout);}
else if(!_s._didInit){_s._wD(_s.strings.waitForever);}};this.handleFocus=function(){if(_s._isFocused||!_s._tryInitOnFocus){return true;}
_s._okToDisable=true;_s._isFocused=true;_s._wD('soundManager.handleFocus()');if(_s._tryInitOnFocus){window.removeEventListener('mousemove',_s.handleFocus,false);}
_s._waitingForEI=false;setTimeout(_s.waitForExternalInterface,500);if(window.removeEventListener){window.removeEventListener('focus',_s.handleFocus,false);}
else if(window.detachEvent){window.detachEvent('onfocus',_s.handleFocus);}};this.initComplete=function(zb){if(_s._didInit){return false;}
_s._didInit=true;_s._wD('-- SoundManager 2 '+(_s._disabled?'failed to load':'loaded')+' ('+(_s._disabled?'security/load error':'OK')+') --',1);if(_s._disabled||zb){_s._wD('soundManager.initComplete(): calling soundManager.onerror()',1);_s._processOnReady();_s._debugTS('onload',false);_s.onerror.apply(window);return false;}
else{_s._debugTS('onload',true);}
if(_s.waitForWindowLoad&&!_s._windowLoaded){_s._wD('soundManager: Waiting for window.onload()');if(window.addEventListener){window.addEventListener('load',_s._initUserOnload,false);}
else if(window.attachEvent){window.attachEvent('onload',_s._initUserOnload);}
return false;}
else{if(_s.waitForWindowLoad&&_s._windowLoaded){_s._wD('soundManager: Document already loaded');}
_s._initUserOnload();}};this._addOnReady=function(Ab,Bb){_s._onready.push({'method':Ab,'scope':(Bb||null),'fired':false});};this._processOnReady=function(){if(!_s._didInit){return false;}
var Cb={success:(!_s._disabled)};var Db=[];for(var i=0,j=_s._onready.length;i<j;i++){if(_s._onready[i].fired!==true){Db.push(_s._onready[i]);}}
if(Db.length){_s._wD('soundManager: Firing '+Db.length+' onready() item'+(Db.length>1?'s':''));for(i=0,j=Db.length;i<j;i++){if(Db[i].scope){Db[i].method.apply(Db[i].scope,[Cb]);}
else{Db[i].method(Cb);}
Db[i].fired=true;}}};this._initUserOnload=function(){window.setTimeout(function(){_s._processOnReady();_s._wD('soundManager.initComplete(): calling soundManager.onload()',1);_s.onload.apply(window);_s._wD('soundManager.onload() complete',1);});};this.init=function(){_s._wD('-- soundManager.init() --');_s._initMovie();if(_s._didInit){_s._wD('soundManager.init(): Already called?');return false;}
if(window.removeEventListener){window.removeEventListener('load',_s.beginDelayedInit,false);}
else if(window.detachEvent){window.detachEvent('onload',_s.beginDelayedInit);}
try{_s._wD('Attempting to call Flash from JS..');_s.o._externalInterfaceTest(false);if(!_s.allowPolling){_s._wD('Polling (whileloading()/whileplaying() support) is disabled.',1);}
_s._setPolling(true,_s.useFastPolling?true:false);if(!_s.debugMode){_s.o._disableDebug();}
_s.enabled=true;_s._debugTS('jstoflash',true);}
catch(e){_s._wD('js/flash exception: '+e.toString());_s._debugTS('jstoflash',false);_s._failSafely(true);_s.initComplete();return false;}
_s.initComplete();};this.beginDelayedInit=function(){_s._wD('soundManager.beginDelayedInit()');_s._windowLoaded=true;setTimeout(_s.waitForExternalInterface,500);setTimeout(_s.beginInit,20);};this.beginInit=function(){if(_s._initPending){return false;}
_s.createMovie();_s._initMovie();_s._initPending=true;return true;};this.domContentLoaded=function(){_s._wD('soundManager.domContentLoaded()');if(document.removeEventListener){document.removeEventListener('DOMContentLoaded',_s.domContentLoaded,false);}
_s.go();};this._externalInterfaceOK=function(){if(_s.swfLoaded){return false;}
_s._wD('soundManager._externalInterfaceOK()');_s._debugTS('swf',true);_s._debugTS('flashtojs',true);_s.swfLoaded=true;_s._tryInitOnFocus=false;if(_s.isIE){setTimeout(_s.init,100);}
else{_s.init();}};this._setSandboxType=function(Eb){var sb=_s.sandbox;sb.type=Eb;sb.description=sb.types[(typeof sb.types[Eb]!='undefined'?Eb:'unknown')];_s._wD('Flash security sandbox type: '+sb.type);if(sb.type=='localWithFile'){sb.noRemote=true;sb.noLocal=false;_s._wD('Flash security note: Network/internet URLs will not load due to security restrictions. Access can be configured via Flash Player Global Security Settings Page: http://www.macromedia.com/support/documentation/en/flashplayer/help/settings_manager04.html',2);}
else if(sb.type=='localWithNetwork'){sb.noRemote=false;sb.noLocal=true;}
else if(sb.type=='localTrusted'){sb.noRemote=false;sb.noLocal=false;}};this.reboot=function(){_s._wD('soundManager.reboot()');if(_s.soundIDs.length){_s._wD('Destroying '+_s.soundIDs.length+' SMSound objects...');}
for(var i=_s.soundIDs.length;i--;){_s.sounds[_s.soundIDs[i]].destruct();}
try{if(_s.isIE){_s.oRemovedHTML=_s.o.innerHTML;}
_s.oRemoved=_s.o.parentNode.removeChild(_s.o);_s._wD('Flash movie removed.');}
catch(e){_s._wD('Warning: Failed to remove flash movie.',2);}
_s.enabled=false;_s._didInit=false;_s._waitingForEI=false;_s._initPending=false;_s._didAppend=false;_s._appendSuccess=false;_s._disabled=false;_s._waitingforEI=true;_s.swfLoaded=false;_s.soundIDs={};_s.sounds=[];_s.o=null;for(i=_s._onready.length;i--;){_s._onready[i].fired=false;}
_s._wD('soundManager: Rebooting...');window.setTimeout(soundManager.beginDelayedInit,20);};this.destruct=function(){_s._wD('soundManager.destruct()');_s.disable(true);};ca=function(Fb){var _t=this;this.sID=Fb.id;this.url=Fb.url;this.options=_s._mergeObjects(Fb);this.instanceOptions=this.options;this._iO=this.instanceOptions;this.pan=this.options.pan;this.volume=this.options.volume;this._lastURL=null;this._debug=function(){if(_s.debugMode){var Gb=null;var Hb=[];var sF=null;var Ib=null;var Jb=64;for(Gb in _t.options){if(_t.options[Gb]!==null){if(_t.options[Gb]
instanceof Function){sF=_t.options[Gb].toString();sF=sF.replace(/\s\s+/g,' ');Ib=sF.indexOf('{');Hb[Hb.length]=' '+Gb+': {'+sF.substr(Ib+1,(Math.min(Math.max(sF.indexOf('\n')-1,Jb),Jb))).replace(/\n/g,'')+'... }';}
else{Hb[Hb.length]=' '+Gb+': '+_t.options[Gb];}}}
_s._wD('SMSound() merged options: {\n'+Hb.join(', \n')+'\n}');}};this._debug();this.id3={};this.resetProperties=function(Kb){_t.bytesLoaded=null;_t.bytesTotal=null;_t.position=null;_t.duration=null;_t.durationEstimate=null;_t.loaded=false;_t.playState=0;_t.paused=false;_t.readyState=0;_t.muted=false;_t.didBeforeFinish=false;_t.didJustBeforeFinish=false;_t.isBuffering=false;_t.instanceOptions={};_t.instanceCount=0;_t.peakData={left:0,right:0};_t.waveformData={left:[],right:[]};_t.eqData=[];};_t.resetProperties();this.load=function(Fb){if(typeof Fb!='undefined'){_t._iO=_s._mergeObjects(Fb);_t.instanceOptions=_t._iO;}
else{Fb=_t.options;_t._iO=Fb;_t.instanceOptions=_t._iO;if(_t._lastURL&&_t._lastURL!=_t.url){_s._wD('SMSound.load(): Using manually-assigned URL');_t._iO.url=_t.url;_t.url=null;}}
if(typeof _t._iO.url=='undefined'){_t._iO.url=_t.url;}
_s._wD('soundManager.load(): '+_t._iO.url,1);if(_t._iO.url==_t.url&&_t.readyState!==0&&_t.readyState!=2){_s._wD('soundManager.load(): current URL already assigned.',1);return false;}
_t.url=_t._iO.url;_t._lastURL=_t._iO.url;_t.loaded=false;_t.readyState=1;_t.playState=0;try{if(_s.flashVersion==8){_s.o._load(_t.sID,_t._iO.url,_t._iO.stream,_t._iO.autoPlay,(_t._iO.whileloading?1:0));}
else{_s.o._load(_t.sID,_t._iO.url,_t._iO.stream?true:false,_t._iO.autoPlay?true:false);if(_t._iO.isMovieStar&&_t._iO.autoLoad&&!_t._iO.autoPlay){_t.pause();}}}
catch(e){_s._wD('SMSound.load(): Exception: JS-Flash communication failed, or JS error.',2);_s._debugTS('onload',false);_s.onerror();_s.disable();}};this.unload=function(){if(_t.readyState!==0){_s._wD('SMSound.unload(): "'+_t.sID+'"');if(_t.readyState!=2){_t.setPosition(0,true);}
_s.o._unload(_t.sID,_s.nullURL);_t.resetProperties();}};this.destruct=function(){_s._wD('SMSound.destruct(): "'+_t.sID+'"');_s.o._destroySound(_t.sID);_s.destroySound(_t.sID,true);};this.play=function(Fb){if(!Fb){Fb={};}
_t._iO=_s._mergeObjects(Fb,_t._iO);_t._iO=_s._mergeObjects(_t._iO,_t.options);_t.instanceOptions=_t._iO;if(_t.playState==1){var Lb=_t._iO.multiShot;if(!Lb){_s._wD('SMSound.play(): "'+_t.sID+'" already playing (one-shot)',1);return false;}
else{_s._wD('SMSound.play(): "'+_t.sID+'" already playing (multi-shot)',1);}}
if(!_t.loaded){if(_t.readyState===0){_s._wD('SMSound.play(): Attempting to load "'+_t.sID+'"',1);_t._iO.stream=true;_t._iO.autoPlay=true;_t.load(_t._iO);}
else if(_t.readyState==2){_s._wD('SMSound.play(): Could not load "'+_t.sID+'" - exiting',2);return false;}
else{_s._wD('SMSound.play(): "'+_t.sID+'" is loading - attempting to play..',1);}}
else{_s._wD('SMSound.play(): "'+_t.sID+'"');}
if(_t.paused){_t.resume();}
else{_t.playState=1;if(!_t.instanceCount||_s.flashVersion>8){_t.instanceCount++;}
_t.position=(typeof _t._iO.position!='undefined'&&!isNaN(_t._iO.position)?_t._iO.position:0);if(_t._iO.onplay){_t._iO.onplay.apply(_t);}
_t.setVolume(_t._iO.volume,true);_t.setPan(_t._iO.pan,true);_s.o._start(_t.sID,_t._iO.loop||1,(_s.flashVersion==9?_t.position:_t.position/1000));}};this.start=this.play;this.stop=function(Mb){if(_t.playState==1){_t.playState=0;_t.paused=false;if(_t._iO.onstop){_t._iO.onstop.apply(_t);}
_s.o._stop(_t.sID,Mb);_t.instanceCount=0;_t._iO={};}};this.setPosition=function(Nb,Ob){if(typeof Nb=='undefined'){Nb=0;}
var Pb=Math.min(_t.duration,Math.max(Nb,0));_t._iO.position=Pb;if(!Ob){}
_s.o._setPosition(_t.sID,(_s.flashVersion==9?_t._iO.position:_t._iO.position/1000),(_t.paused||!_t.playState)); //if paused or not playing,will not resume(by playing)};this.pause=function(){if(_t.paused||_t.playState===0){return false;}
_s._wD('SMSound.pause()');_t.paused=true;_s.o._pause(_t.sID);if(_t._iO.onpause){_t._iO.onpause.apply(_t);}};this.resume=function(){if(!_t.paused||_t.playState===0){return false;}
_s._wD('SMSound.resume()');_t.paused=false;_s.o._pause(_t.sID);if(_t._iO.onresume){_t._iO.onresume.apply(_t);}};this.togglePause=function(){_s._wD('SMSound.togglePause()');if(_t.playState===0){_t.play({position:(_s.flashVersion==9?_t.position:_t.position/1000)});return false;}
if(_t.paused){_t.resume();}
else{_t.pause();}};this.setPan=function(Qb,Rb){if(typeof Qb=='undefined'){Qb=0;}
if(typeof Rb=='undefined'){Rb=false;}
_s.o._setPan(_t.sID,Qb);_t._iO.pan=Qb;if(!Rb){_t.pan=Qb;}};this.setVolume=function(Sb,Tb){if(typeof Sb=='undefined'){Sb=100;}
if(typeof Tb=='undefined'){Tb=false;}
_s.o._setVolume(_t.sID,(_s.muted&&!_t.muted)||_t.muted?0:Sb);_t._iO.volume=Sb;if(!Tb){_t.volume=Sb;}};this.mute=function(){_t.muted=true;_s.o._setVolume(_t.sID,0);};this.unmute=function(){_t.muted=false;var Ub=typeof _t._iO.volume!='undefined';_s.o._setVolume(_t.sID,Ub?_t._iO.volume:_t.options.volume);};this.toggleMute=function(){if(_t.muted){_t.unmute();}
else{_t.mute();}};this._whileloading=function(Vb,Wb,Xb){if(!_t._iO.isMovieStar){_t.bytesLoaded=Vb;_t.bytesTotal=Wb;_t.duration=Math.floor(Xb);_t.durationEstimate=parseInt((_t.bytesTotal/_t.bytesLoaded)*_t.duration,10);if(_t.durationEstimate===undefined){_t.durationEstimate=_t.duration;}
if(_t.readyState!=3&&_t._iO.whileloading){_t._iO.whileloading.apply(_t);}}
else{_t.bytesLoaded=Vb;_t.bytesTotal=Wb;_t.duration=Math.floor(Xb);_t.durationEstimate=_t.duration;if(_t.readyState!=3&&_t._iO.whileloading){_t._iO.whileloading.apply(_t);}}};this._onid3=function(Yb,Zb){_s._wD('SMSound._onid3(): "'+this.sID+'" ID3 data received.');var $b=[];for(var i=0,j=Yb.length;i<j;i++){$b[Yb[i]]=Zb[i];}
_t.id3=_s._mergeObjects(_t.id3,$b);if(_t._iO.onid3){_t._iO.onid3.apply(_t);}};this._whileplaying=function(ac,bc,cc,dc,ec){if(isNaN(ac)||ac===null){return false;}
if(_t.playState===0&&ac>0){ac=0;}
_t.position=ac;if(_t._iO.usePeakData&&typeof bc!='undefined'&&bc){_t.peakData={left:bc.leftPeak,right:bc.rightPeak};}
if(_t._iO.useWaveformData&&typeof cc!='undefined'&&cc){_t.waveformData={left:cc.split(','),right:dc.split(',')};}
if(_t._iO.useEQData&&typeof ec!='undefined'&&ec){_t.eqData=ec;}
if(_t.playState==1){if(_t.isBuffering){_t._onbufferchange(0);}
if(_t._iO.whileplaying){_t._iO.whileplaying.apply(_t);}
if(_t.loaded&&_t._iO.onbeforefinish&&_t._iO.onbeforefinishtime&&!_t.didBeforeFinish&&_t.duration-_t.position<=_t._iO.onbeforefinishtime){_s._wD('duration-position &lt;= onbeforefinishtime: '+_t.duration+' - '+_t.position+' &lt= '+_t._iO.onbeforefinishtime+' ('+(_t.duration-_t.position)+')');_t._onbeforefinish();}}};this._onload=function(fc){fc=(fc==1?true:false);_s._wD('SMSound._onload(): "'+_t.sID+'"'+(fc?' loaded.':' failed to load? - '+_t.url),(fc?1:2));if(!fc){if(_s.sandbox.noRemote===true){_s._wD('SMSound._onload(): Reminder: Flash security is denying network/internet access',1);}
if(_s.sandbox.noLocal===true){_s._wD('SMSound._onload(): Reminder: Flash security is denying local access',1);}}
_t.loaded=fc;_t.readyState=fc?3:2;if(_t._iO.onload){_t._iO.onload.apply(_t);}};this._onbeforefinish=function(){if(!_t.didBeforeFinish){_t.didBeforeFinish=true;if(_t._iO.onbeforefinish){_s._wD('SMSound._onbeforefinish(): "'+_t.sID+'"');_t._iO.onbeforefinish.apply(_t);}}};this._onjustbeforefinish=function(gc){if(!_t.didJustBeforeFinish){_t.didJustBeforeFinish=true;if(_t._iO.onjustbeforefinish){_s._wD('SMSound._onjustbeforefinish(): "'+_t.sID+'"');_t._iO.onjustbeforefinish.apply(_t);}}};this._onfinish=function(){if(_t._iO.onbeforefinishcomplete){_t._iO.onbeforefinishcomplete.apply(_t);}
_t.didBeforeFinish=false;_t.didJustBeforeFinish=false;if(_t.instanceCount){_t.instanceCount--;if(!_t.instanceCount){_t.playState=0;_t.paused=false;_t.instanceCount=0;_t.instanceOptions={};}
if(!_t.instanceCount||_t._iO.multiShotEvents){if(_t._iO.onfinish){_s._wD('SMSound._onfinish(): "'+_t.sID+'"');_t._iO.onfinish.apply(_t);}}}
else{if(_t.useVideo){}}};this._onmetadata=function(hc){_s._wD('SMSound.onmetadata()');if(!hc.width&&!hc.height){_s._wD('No width/height given, assuming defaults');hc.width=320;hc.height=240;}
_t.metadata=hc;_t.width=hc.width;_t.height=hc.height;if(_t._iO.onmetadata){_s._wD('SMSound._onmetadata(): "'+_t.sID+'"');_t._iO.onmetadata.apply(_t);}
_s._wD('SMSound.onmetadata() complete');};this._onbufferchange=function(ic){if(_t.playState===0){return false;}
if(ic==_t.isBuffering){_s._wD('_onbufferchange: ignoring false default / loaded sound');return false;}
_t.isBuffering=(ic==1?true:false);if(_t._iO.onbufferchange){_s._wD('SMSound._onbufferchange(): '+ic);_t._iO.onbufferchange.apply(_t);}};this._ondataerror=function(jc){if(_t.playState>0){_s._wD('SMSound._ondataerror(): '+jc);if(_t._iO.ondataerror){_t._iO.ondataerror.apply(_t);}}
else{}};};this._onfullscreenchange=function(kc){_s._wD('onfullscreenchange(): '+kc);_s.isFullScreen=(kc==1?true:false);if(!_s.isFullScreen){try{window.focus();_s._wD('window.focus()');}
catch(e){}}};if(window.addEventListener){window.addEventListener('focus',_s.handleFocus,false);window.addEventListener('load',_s.beginDelayedInit,false);window.addEventListener('unload',_s.destruct,false);if(_s._tryInitOnFocus){window.addEventListener('mousemove',_s.handleFocus,false);}}
else if(window.attachEvent){window.attachEvent('onfocus',_s.handleFocus);window.attachEvent('onload',_s.beginDelayedInit);window.attachEvent('unload',_s.destruct);}
else{_s._debugTS('onload',false);soundManager.onerror();soundManager.disable();}
if(document.addEventListener){document.addEventListener('DOMContentLoaded',_s.domContentLoaded,false);}}
if(typeof SM2_DEFER=='undefined'||!SM2_DEFER){soundManager=new SoundManager();}
var pcm={callbacks:[],images:[],names:[],ldi:[],ild:0,add:function(lc,mc){if(typeof lc=='string')this.images.push(lc);if(typeof lc=='array'||typeof lc=='object'){for(var i=0;i<lc.length;i++){this.images.push(lc[i]);this.names.push(mc);}}},onFinish:function(nc){if(typeof nc=='function')this.callbacks.push(nc);if(typeof nc=='array'||typeof nc=='object'){for(var i=0;i<nc.length;i++){this.callbacks.push(nc[i]);}}},load:function(){for(var i=0;i<this.images.length;i++){this.ldi[i]=new Image();this.ldi[i].onload=function(){pcm.checkFinished.apply(pcm)}
this.ldi[i].src=this.images[i];}},checkFinished:function(){this.ild++;if(this.ild==this.images.length)this.fireFinish();},fireFinish:function(){for(var i=0;i<this.callbacks.length;i++){this.callbacks[i]();}
this.images=[];this.ldi=[];this.ild=0;this.callbacks=[];},getWidth:function(oc){for(var i=0;i<this.names.length;i++){if(this.names[i]==oc){return(this.ldi[i].width);}}},getHeight:function(pc){for(var i=0;i<this.names.length;i++){if(this.names[i]==pc){return(this.ldi[i].height);}}}}
var ado=true;soundManager.debugMode=false;var ssl=0;function wbl(){setInterval(csl,1000);}
function csl(){ssl++;}
var nvt;nvt=gck('widgetCount');var wcc;if(nvt!=""){wcc=nvt;}
else{wcc=2;sck('widgetCount',wcc);}
nvt=gck('raceSoundsEnabled');var rse;if(nvt!=""){rse=nvt;}
else{rse=1;sck('raceSoundsEnabled',rse);}
var rtd=Math.PI/180.0;var nml=0,nmt=0;var nmw=300;var mnh=300;var bda=false;var cms=new Array(wcc);var cms=new Array(wcc);function scm(){var qc;var rc,htm,nsn;for(i=0;i<wcc;i++){qc=gip(cms[i][0]);if(qc=="MonsterGoogle1"){nsn=4;}
else if(qc=="RCMonsterTruck3"){nsn=2;}
else{nsn=2;}
rc=pcm.getWidth(qc);htm=pcm.getHeight(qc);cms[i]=new cmw(i,cms[i],rc,htm,77,10,nsn,0);}
setInterval(twt,500);}
function twt(){if(!wsl()||ssl<3){return;}
for(i=0;i<wcc;i++){if(cms[i].bed==false&&rni(37)==1){cms[i].bed=true;sws[0].play();cms[i].swt(rni(gcw()/2)+70,rni(gch()/2)+70,false);}}}
function wsl(){if(wlc<wtc){return false;}
else{return true;}}
function ucs(sc){if(!document.getElementById)return;nml=sc.clientX+document.documentElement.scrollLeft;nmt=sc.clientY+document.documentElement.scrollTop;bda=(gcw()<nmw||gch()<mnh);if(!bda){for(i=0;i<wcc;i++){if(cms[i].bed==true){cms[i].mwt();}}}}
function mcc(){if(!document.getElementById)return;bda=(gcw()<nmw||gch()<mnh);if(!bda){for(i=0;i<wcc;i++){if(cms[i].bed==true){cms[i].cgm();}}}}
function pso(){window.open("site_options.html","SiteOptions","left=300,top=100,width=370,height=450,location=no,resizable=no,scrollbars=no,toolbar=no,directories=no,status=no");}
function gip(tc){var uc=tc.lastIndexOf("/")+1;var vc=tc.lastIndexOf("-");return(tc.substring(uc,vc));}
function lz000(n){if(n<10){return("00"+n);}
else if(n<100){return("0"+n);}
else{return(n);}}
function gcw(){return(document.compatMode=='CSS1Compat'&&!window.opera?document.documentElement.clientWidth:document.body.clientWidth);}
function gch(){return(document.compatMode=='CSS1Compat'&&!window.opera?document.documentElement.clientHeight:document.body.clientHeight);}
function gpw(){return((document.width!==undefined)?document.width:document.body.offsetWidth);}
function gph(){return((document.height!==undefined)?document.height:document.body.offsetHeight);}
function imi(wc,xc,yc,zc){return(nml>=wc&&nml<=yc&&nmt>=xc&&nmt<=zc);}
function rni(Ac){return(Math.floor(Math.random()*Ac));}
function png(){if(rni(2)==0){return(1);}
else{return(-1);}}
function gad(dx,dy){gal=360.0-Math.atan2(dx,dy)*180.0/Math.PI+180.0;if(gal>=360.0){gal-=360.0;}
return(gal);}
function grd(dx,dy){return(Math.sqrt(dx*dx+dy*dy));}
function dbt(Bc){if(ado!=true){return;}
document.title=Bc;}
function sih(id,Cc){if(!document.getElementById)return;if(document.getElementById){document.getElementById(id).innerHTML=Cc;}}
function iff(){if(navigator.userAgent.indexOf("Firefox")!=-1){return(true);}
else{return(false);}}
function sck(Dc,Ec){var Fc=365;var Gc=new Date();Gc.setDate(Gc.getDate()+Fc);document.cookie=Dc+"="+escape(Ec)+((Fc==null)?"":";expires="+Gc.toGMTString());}
function gck(Hc){if(document.cookie.length>0){cst=document.cookie.indexOf(Hc+"=");if(cst!=-1){cst=cst+Hc.length+1;ced=document.cookie.indexOf(";",cst);if(ced==-1){ced=document.cookie.length;}
return(unescape(document.cookie.substring(cst,ced)));}}
return("");}
function deleteCookie(Ic){if(gck(Ic))sck(Ic,'',new Date(70,0,1,0,0,1));}
var cmw;cmw=function(Jc,Kc,Lc,Mc,Nc,Oc,Pc,Qc){this.self=this;this.nen=Jc;this.eed=document.getElementById('widget_div'+Jc);this.eei=document.getElementById('widget_img'+Jc);this.sin=Kc;this.nic=this.sin.length;this.nra=(360/this.nic);this.eei.src=this.sin[0];this.eed.style.width=Lc;this.eed.style.height=Mc;this.dnr=Nc;this.nsi=Oc;this.nsb=Pc;this.nos=Qc;this.nso=0;this.bed=false;this.nwd=Lc;this.nht=Mc;this.bsa=false;this.njl=0;this.njt=0;this.ncl=0;this.nct=0;this.dja=0;this.djr=0;this.nnr=0;this.nnb=0;this.dsr=0;this.dri=0;this.nti=0;this.mwt=function(){if(wsl()&&!bda&&this.eed&&!this.bsa){var Rc=parseInt(this.eed.style.left);var Sc=parseInt(this.eed.style.top);var Tc=this.nwd/2+Rc;var Uc=this.nht/2+Sc;var Vc=Tc-nml;var Wc=Uc-nmt;var Xc=gad(Vc,Wc);var Yc=Math.abs(this.dja-Xc);if(Yc>140&&Yc<220){return;}
var Zc=grd(Vc,Wc);if(Zc>this.dnr){return;}
Zc+=30;var Vc=Math.sin(Xc*rtd)*Zc;var Wc=-Math.cos(Xc*rtd)*Zc;sws[this.nsb+this.nso].play();this.nso=!this.nso;if(this.swt(Rc+Vc,Sc+Wc,false)==true){sws[0].play();this.rwt();}}}
this.rwt=function(){if(!bda&&this.eed&&!this.bsa){var $c=gpw()/ 2 - this.nwd  / 2+this.nwd*png()/2;var ad=gph()/ 2 - this.nht / 2+this.nht*png()/2;if(imi($c,ad,$c+this.nwd,ad+this.nht)){$c+=this.nwd*png()/2;ad+=this.nht*png()/2;}
this.swt($c,ad,false);}}
this.cgm=function(){if(wsl()&&!bda&&this.eed&&!this.bsa){var bd=parseInt(this.eed.style.left);var cd=parseInt(this.eed.style.top);var dd=this.nwd/2+bd;var ed=this.nht/2+cd;var fd=dd-nml;var gd=ed-nmt;var hd=grd(fd,gd);if(hd<=this.dnr){if(rni(100)>7){alert("You got me!");this.bed=false;sws[1].play();this.swt(rni(900)-250,-250,true);}
else{sws[0].play();this.rwt();}}}}
this.swt=function(jd,kd,ld){if(!bda&&this.eed){this.nnr=jd+this.nwd;this.nnb=kd+this.nht;if(!ld&&(jd<=0||kd<=0||this.nnr>=gpw()||this.nnb>=gph())){return(true);}
this.njl=jd;this.njt=kd;this.ncl=parseInt(this.eed.style.left);this.nct=parseInt(this.eed.style.top);var md=jd-this.ncl;var nd=kd-this.nct;this.dja=gad(md,nd);this.djr=grd(md,nd);var od=Math.floor(Math.floor(this.dja / this.nra) + this.nic / 2+0.5);if(od>=this.nic){od-=this.nic;}
this.eei.src=this.sin[od];this.dri=this.djr/this.nsi;this.dsr=0.0;this.bsa=true;var pd=this;this.nti=setInterval(function(){pd.swl()},10);return(false);}}
this.swl=function(){if(this.bsa==false){return;}
var qd=this.ncl+Math.sin(this.dja*rtd)*this.dsr;var rd=this.nct-Math.cos(this.dja*rtd)*this.dsr;if(this.dsr<this.djr){var sd=this.nwd/2+qd;var td=(qd/(gpw()-this.nwd))*1.2-0.1;if(td>1.0){td=1.0;}
else if(td<0.0){td=0.0;}
var ud=td*200-100;sws[this.nsb+0].setPan(ud);sws[this.nsb+1].setPan(ud);this.dsrTmp+=this.dri;this.eed.style.left=qd+"px";this.eed.style.top=rd+"px";this.dsr+=this.dri;}
else{this.eed.style.left=this.njl+"px";this.eed.style.top=this.njt+"px";clearTimeout(this.nti);this.bsa=false;}}}
var wtc=6;var wlc=0;var sws=new Array(6);var dht,ndt;var ipn=["MonsterGoogle1","RCMonsterTruck3"];var ipc=[24,24];var iat;var rwn,imn,ict;for(i=0;i<wcc;i++){dht='<div id="widget_div'+i+'" style="position:absolute; top:-250px; left:'+(rni(1000)-250)+'px; width:0px; height:0px; padding: 0px; z-index: 1; border:none">'+'   <img id="widget_img'+i+'" src="floaters/images/BlankStartup.gif" />'+'</div>';ndt=document.createElement('div');ndt.innerHTML=dht;document.getElementsByTagName('div')[0].appendChild(ndt);}
pcm.onFinish(scm);for(i=0;i<wcc;i++){rwn=rni(ipn.length);imn=ipn[rwn];ict=ipc[rwn];iat=new Array(ict);for(j=0;j<ict;j++){iat[j]="floaters/images/"+imn+"-"+lz000(j*360/ict)+".gif";}
cms[i]=iat;pcm.add(iat,imn);}
pcm.load();function lws(){sws[0]=soundManager.createSound({id:'CarBurstCenterM',url:'/audio/CarBurstCenterM.mp3',autoLoad:true,autoPlay:false,onload:function(){wlc++;},volume:100});sws[1]=soundManager.createSound({id:'CarBurstGotMeM',url:'/audio/CarBurstGotMeM.mp3',autoLoad:true,autoPlay:false,onload:function(){wlc++;},volume:100});sws[2]=soundManager.createSound({id:'CarBurstNudge1MA',url:'/audio/CarBurstNudge1M.mp3',autoLoad:true,autoPlay:false,onload:function(){wlc++;},volume:100});sws[3]=soundManager.createSound({id:'CarBurstNudge1MB',url:'/audio/CarBurstNudge1M.mp3',autoLoad:true,autoPlay:false,onload:function(){wlc++;},volume:100});sws[4]=soundManager.createSound({id:'CarBurstNudge2MA',url:'/audio/CarBurstNudge2M.mp3',autoLoad:true,autoPlay:false,onload:function(){wlc++;},volume:100});sws[5]=soundManager.createSound({id:'CarBurstNudge2MB',url:'/audio/CarBurstNudge2M.mp3',autoLoad:true,autoPlay:false,onload:function(){wlc++;},volume:100});}
soundManager.onload=function(){lws();if(typeof lbs=='function'){lbs();}}

