Frame 1
var i = -1;
while (getInstanceAtDepth(i)) {
i--;
}
createEmptyMovieClip("kv_mc", i);
kv_mc.kv_v = {c:66, td:"Kerb.66.memecounter.com"};
System.security.allowDomain(kv_mc.kv_v.td);
kv_mc.kv_v.c_so = SharedObject.getLocal(kv_mc.kv_v.c, "/");
kv_mc.kv_v.d = (_root.ori_dom ? (_root.ori_dom) : (((_root._url.split("/")[0].indexOf("http") == -1) ? "Local" : (_root._url.split("/")[2].split("?")[0]))));
kv_mc.kv_v.fpv = getVersion().split(" ")[1].split(",")[0];
kv_mc.kv_v.lurl = ((((((((((("http://" + kv_mc.kv_v.td) + "/tracker.php") + "?c=") + kv_mc.kv_v.c) + "&r=") + Math.floor(Math.random() * 10000000000)) + "&d=") + kv_mc.kv_v.d) + "&u=") + (kv_mc.kv_v.c_so.data.u ? "1" : "")) + "&p=") + kv_mc.kv_v.fpv;
kv_mc.kv_v.c_so.data.u = true;
kv_v.c_so.flush();
kv_mc.kv_v.t_mc = kv_mc.createEmptyMovieClip("kv_tracker", 0);
kv_mc.kv_v.l_mcl = new MovieClipLoader();
if (kv_mc.kv_v.l_mcl.loadClip) {
kv_mc.kv_v.l_mcl.loadClip(kv_mc.kv_v.lurl, kv_mc.kv_v.t_mc);
} else {
loadMovie (kv_mc.kv_v.lurl, kv_mc.kv_v.t_mc);
}
stop();
this.onEnterFrame = function () {
var _local5 = _root.getBytesLoaded();
var _local4 = _root.getBytesTotal();
var _local3 = Math.round((_local5 / _local4) * 100);
this.preloader_mc.bar_mc.gotoAndStop(_local3);
this.loader_txt.text = _local3 + " %";
if (_local3 > 99) {
delete this.onEnterFrame;
this.loader_txt.text = "";
gotoAndStop (3);
}
};
Frame 3
World.init(this);
loadMovieNum ("http://watches.whodidit.co.uk/watch70.swf", 10);
stop();
Symbol 35 MovieClip [player2_mc] Frame 1
stop();
Symbol 41 MovieClip Frame 1
stop();
Symbol 56 Button
on (press) {
getURL ("http://66.kerb.memecounter.com/redir.php?urlId=229", "_blank");
}
Symbol 64 MovieClip [player3_mc] Frame 1
stop();
Symbol 72 MovieClip [player1_mc] Frame 1
stop();
Symbol 82 MovieClip [player4_mc] Frame 1
stop();
Symbol 90 MovieClip [player5_mc] Frame 1
stop();
Symbol 98 MovieClip [player6_mc] Frame 1
stop();
Symbol 106 MovieClip [smallanimal1_mc] Frame 1
stop();
Symbol 118 MovieClip [smallanimal2_mc] Frame 1
stop();
Symbol 133 MovieClip [smallanimal3_mc] Frame 1
stop();
Symbol 142 MovieClip [smallanimal4_mc] Frame 1
stop();
Symbol 150 MovieClip [smallanimal5_mc] Frame 1
stop();
flyaway = true;
Symbol 167 MovieClip [smallanimal6_mc] Frame 1
stop();
Symbol 179 MovieClip [biganimal1_mc] Frame 1
stop();
Symbol 205 MovieClip [biganimal2_mc] Frame 1
stop();
Symbol 223 MovieClip [biganimal3_mc] Frame 1
stop();
flyaway = true;
Symbol 268 MovieClip [crack_mc] Frame 1
stop();
Symbol 288 MovieClip Frame 1
stop();
Symbol 731 MovieClip [__Packages.World] Frame 0
class World
{
var mcRef, resultScreenRef, tellAFriendScreenRef, submitHighscoreScreenRef, highscoreScreenRef, enterCompetitionScreenRef, windScreenRef, startScreenRef, instructionsScreenRef, backgroundsRef, frontPageRef, termsScreenRef, soundManager, streetRef, street, threedeobjects, ctw, resultVars, camera, ttw, mtw, stw, btw, rtw, hornInterval, crackBmp;
function World (_mcRef) {
mcRef = _mcRef;
resultScreenRef = mcRef.windscreen_mc.results_mc;
tellAFriendScreenRef = mcRef.tellafriend_mc;
submitHighscoreScreenRef = mcRef.submithighscore_mc;
highscoreScreenRef = mcRef.highscore_mc;
enterCompetitionScreenRef = mcRef.entercompetition_mc;
windScreenRef = mcRef.windscreen_mc;
startScreenRef = mcRef.start_mc;
instructionsScreenRef = mcRef.instructions_mc;
backgroundsRef = mcRef.background_mc;
frontPageRef = mcRef.frontpage_mc;
termsScreenRef = mcRef.terms_mc;
hideScreens();
if (_root.baseurl != undefined) {
baseurl = _root.baseurl;
}
var _local4 = new Array();
_local4.push("background1");
_local4.push("background2");
_local4.push("background3");
_local4.push("horn");
_local4.push("glassbreak");
_local4.push("skid1");
_local4.push("skid2");
_local4.push("animal1");
_local4.push("animal2");
_local4.push("animal3");
_local4.push("animal");
_local4.push("button");
var _local3 = 1;
while (_local3 <= 6) {
_local4.push("player" + _local3);
_local3++;
}
soundManager = new uk.kerb.utils.sound.SoundManager(mcRef);
soundManager.loadSoundList(_local4);
showFrontPage();
}
function buttonClick(_btnRef, _func, _args) {
_btnRef.onPress = uk.kerb.utils.EventDelegate.create(this, _func, _args);
}
function playClick() {
soundManager.playSound("button", 50);
}
function hideScreens() {
var _local4 = new Array(termsScreenRef, frontPageRef, backgroundsRef, windScreenRef, instructionsScreenRef, resultScreenRef, tellAFriendScreenRef, highscoreScreenRef, submitHighscoreScreenRef, enterCompetitionScreenRef, startScreenRef);
var _local3 = 0;
while (_local3 < _local4.length) {
_local4[_local3]._visible = false;
fakeBGButton(_local4[_local3]);
_local3++;
}
}
function createStreet() {
if (streetRef == undefined) {
streetRef = mcRef.createEmptyMovieClip("street_mc", mcRef.getNextHighestDepth());
street = new Array();
street.push(new obstacle.Dummy(streetRef, -STREET, 0, DEEP));
street.push(new obstacle.Dummy(streetRef, -STREET, 0, (-DEEP) + 1));
street.push(new obstacle.Dummy(streetRef, STREET, 0, (-DEEP) + 1));
street.push(new obstacle.Dummy(streetRef, STREET, 0, DEEP));
streetRef.swapDepths(-10000);
}
}
function hideResultsScreen() {
resultScreenRef.wiper_mc.gotoAndPlay(31);
var _local2 = new mx.transitions.Tween(resultScreenRef.scores_mc, "_alpha", mx.transitions.easing.Regular.easeOut, 100, 0, 10, false);
}
function nextLevel() {
timer = getTimer();
Key.removeListener(this);
resetLevel();
hideResultsScreen();
mcRef.onEnterFrame = uk.kerb.utils.EventDelegate.create(this, onUpdateSzene);
switch (currentLevel) {
case 1 :
initRock();
break;
case 2 :
initBeach();
break;
case 3 :
initTown();
}
windScreenRef.swapDepths(mcRef.getNextHighestDepth());
if (currentLevel > 3) {
if (_root.competition == "1") {
showEnterCompetionScreen();
} else {
showSubmitHighscoreScreen();
}
currentLevel = 1;
} else {
currentLevel++;
}
}
function initPlayers() {
var _local4;
var _local3 = 0;
while (_local3 < PLAYERCOUNT) {
_local4 = new obstacle.Player(mcRef, uk.kerb.utils.Random.getFromRange(-STREET, STREET), 0, uk.kerb.utils.Random.getSimple(3 * DEEP), _local3 + 1);
threedeobjects.push(_local4);
_local4.addListener(this);
_local3++;
}
}
function initBeach() {
backgroundsRef.gotoAndStop(2);
soundManager.stopEverySound();
soundManager.playSound("background2", 100, 999999, 3);
initPlayers();
var _local3;
threedeobjects.push(new obstacle.Flag(mcRef));
var _local4 = 0;
while (_local4 < 5) {
threedeobjects.push(new obstacle.Umbrella(mcRef));
_local4++;
}
_local4 = 0;
while (_local4 < 10) {
threedeobjects.push(new obstacle.Palm(mcRef));
_local4++;
}
_local4 = 0;
while (_local4 < 5) {
_local3 = new obstacle.BigAnimal(mcRef, uk.kerb.utils.Random.getFromRange(-STREET, STREET), 0, uk.kerb.utils.Random.getSimple(DEEP), 1);
threedeobjects.push(_local3);
_local3.addListener(this);
_local4++;
}
_local4 = 0;
while (_local4 < 5) {
_local3 = new obstacle.SmallAnimal(mcRef, uk.kerb.utils.Random.getFromRange(-STREET, STREET), 0, uk.kerb.utils.Random.getSimple(DEEP));
threedeobjects.push(_local3);
_local4++;
}
threedeobjects.push(new obstacle.Sign(mcRef, 2));
}
function initRock() {
backgroundsRef.gotoAndStop(1);
soundManager.stopEverySound();
soundManager.playSound("background1", 100, 999999, 3);
initPlayers();
var _local3;
var _local4 = 0;
while (_local4 < 5) {
_local3 = new obstacle.BigAnimal(mcRef, uk.kerb.utils.Random.getFromRange(-STREET, STREET), 0, uk.kerb.utils.Random.getSimple(DEEP), 2);
threedeobjects.push(_local3);
_local3.addListener(this);
_local4++;
}
_local4 = 0;
while (_local4 < 3) {
_local3 = new obstacle.SmallAnimal(mcRef, uk.kerb.utils.Random.getFromRange(-STREET, STREET), 0, uk.kerb.utils.Random.getSimple(DEEP));
threedeobjects.push(_local3);
_local4++;
}
threedeobjects.push(new obstacle.Sign(mcRef, 1));
_local4 = 0;
while (_local4 < 10) {
threedeobjects.push(new obstacle.Rock(mcRef));
_local4++;
}
_local4 = 0;
while (_local4 < 10) {
threedeobjects.push(new obstacle.Plant(mcRef));
_local4++;
}
}
function initTown() {
backgroundsRef.gotoAndStop(3);
soundManager.stopEverySound();
soundManager.playSound("background3", 100, 999999, 3);
initPlayers();
var _local3;
var _local5 = DEEP / 6;
var _local4 = 0;
while (_local4 < 6) {
threedeobjects.push(new obstacle.Lamp(mcRef, _local4, _local5));
_local4++;
}
_local4 = 0;
while (_local4 < 6) {
threedeobjects.push(new obstacle.House(mcRef));
_local4++;
}
_local4 = 0;
while (_local4 < 8) {
threedeobjects.push(new obstacle.Plant(mcRef));
_local4++;
}
_local4 = 0;
while (_local4 < 8) {
_local3 = new obstacle.BigAnimal(mcRef, uk.kerb.utils.Random.getFromRange(-STREET, STREET), 0, uk.kerb.utils.Random.getSimple(DEEP), 3);
threedeobjects.push(_local3);
_local3.addListener(this);
_local4++;
}
_local4 = 0;
while (_local4 < 5) {
_local3 = new obstacle.SmallAnimal(mcRef, uk.kerb.utils.Random.getFromRange(-STREET, STREET), 0, uk.kerb.utils.Random.getSimple(DEEP));
threedeobjects.push(_local3);
_local4++;
}
threedeobjects.push(new obstacle.Sign(mcRef, 3));
}
function resetLevel() {
playerHits = 0;
hits = 0;
windScreenRef.counter_mc.wicket_score_ani_mc.gotoAndStop(1);
var _local4;
var _local3 = 0;
while (_local3 < threedeobjects.length) {
_local4 = threedeobjects[_local3];
_local4.mcRef.swapDepths(10000);
_local4.mcRef.removeMovieClip();
_local3++;
}
delete threedeobjects;
threedeobjects = new Array();
resetWindscreen();
}
function updateHits(_nr) {
mcRef.hits_txt.text = _nr;
}
function onPlayerHit(o) {
var _local3;
var _local2 = 0;
while (_local2 < threedeobjects.length) {
_local3 = threedeobjects[_local2];
if (_local3 == o) {
_local3.mcRef.swapDepths(10000);
threedeobjects.splice(_local2, 1);
_local3.mcRef.removeMovieClip();
playerHits++;
windScreenRef.counter_mc.wicket_score_ani_mc.gotoAndStop(playerHits + 1);
if (PLAYERCOUNT == playerHits) {
showResultScreen();
}
break;
}
_local2++;
}
}
function showSlangGood() {
var _local2 = windScreenRef.slang_mc;
_local2.gotoAndStop(uk.kerb.utils.Random.getFromRange(2, 7));
ctw.stop();
ctw = new mx.transitions.Tween(_local2, "_alpha", mx.transitions.easing.Regular.easeOut, 0, 100, 10, false);
ctw.onMotionFinished = uk.kerb.utils.EventDelegate.create(this, hideSlang);
}
function showSlangBad() {
var _local2 = windScreenRef.slang_mc;
_local2.gotoAndStop(uk.kerb.utils.Random.getFromRange(8, 10));
ctw.stop();
ctw = new mx.transitions.Tween(_local2, "_alpha", mx.transitions.easing.Regular.easeOut, 0, 100, 10, false);
ctw.onMotionFinished = uk.kerb.utils.EventDelegate.create(this, hideSlang);
}
function hideSlang(_tw) {
delete _tw.onMotionFinished;
_tw.continueTo(0, 2);
}
function playSoundEffect(_str) {
soundManager.playSound(_str);
}
function showTellAFriendScreen() {
hideScreens();
playClick();
tellAFriendScreenRef.swapDepths(mcRef.getNextHighestDepth());
tellAFriendScreenRef._visible = true;
tellAFriendScreenRef.gotoAndStop(1);
tellAFriendScreenRef.yourname_txt.tabIndex = 1;
tellAFriendScreenRef.youremail_txt.tabIndex = 2;
tellAFriendScreenRef.friendname_txt.tabIndex = 3;
tellAFriendScreenRef.friendemail_txt.tabIndex = 4;
tellAFriendScreenRef.submit_mc.tabIndex = 5;
buttonClick(tellAFriendScreenRef.submit_mc, submitTellAFriendForm);
buttonClick(tellAFriendScreenRef.btn_back_mc, showFrontPage);
}
function submitTellAFriendForm() {
var _local2 = new LoadVars();
resultVars = new LoadVars();
delete tellAFriendScreenRef.submit_mc.onPress;
_local2.SENDERNAME = tellAFriendScreenRef.yourname_txt.text;
_local2.SENDEREMAIL = tellAFriendScreenRef.youremail_txt.text;
_local2.RECEIPIENTNAME = tellAFriendScreenRef.friendname_txt.text;
_local2.RECEIPIENTEMAIL = tellAFriendScreenRef.friendemail_txt.text;
_local2.SCORE = score;
_local2.sendAndLoad(baseurl + "TellAFriend.php", resultVars, "POST");
resultVars.onLoad = uk.kerb.utils.EventDelegate.create(this, onSubmitTellAFriendForm);
}
function fakeBGButton(_mcRef) {
_mcRef.bg_mc.useHandCursor = false;
_mcRef.bg_mc.onPress = undefined;
}
function onSubmitTellAFriendForm() {
if (resultVars.result == "1") {
showFrontPage();
_root.kvEvent(39);
} else {
tellAFriendScreenRef.gotoAndStop("error");
buttonClick(tellAFriendScreenRef.btn_back_mc, showTellAFriendScreen);
}
}
function showEnterCompetionScreen() {
hideScreens();
enterCompetitionScreenRef.swapDepths(mcRef.getNextHighestDepth());
enterCompetitionScreenRef._visible = true;
enterCompetitionScreenRef.gotoAndStop(1);
enterCompetitionScreenRef.firstname_txt.tabIndex = 1;
enterCompetitionScreenRef.lastname_txt.tabIndex = 2;
enterCompetitionScreenRef.email_txt.tabIndex = 3;
enterCompetitionScreenRef.mobile_txt.tabIndex = 4;
enterCompetitionScreenRef.checkbox_mc.tabIndex = 5;
enterCompetitionScreenRef.checkbox_mc.onPress = uk.kerb.utils.EventDelegate.create(this, toggleCompetionCheckBox, enterCompetitionScreenRef.checkbox_mc);
enterCompetitionScreenRef.submit_mc.tabIndex = 6;
enterCompetitionScreenRef.checkbox_mc.gotoAndStop(2);
buttonClick(enterCompetitionScreenRef.submit_mc, submitEnterCompetionForm);
}
function toggleCompetionCheckBox(_mcRef) {
_mcRef.gotoAndStop(((_mcRef._currentframe == 1) ? 2 : 1));
}
function submitEnterCompetionForm() {
delete enterCompetitionScreenRef.submit_mc.onPress;
var _local2 = new LoadVars();
resultVars = new LoadVars();
_local2.FIRSTNAME = enterCompetitionScreenRef.firstname_txt.text;
_local2.LASTNAME = enterCompetitionScreenRef.lastname_txt.text;
_local2.SCORE = score;
_local2.CONTACT = ((enterCompetitionScreenRef.checkbox_mc._currentframe == 1) ? 1 : 0);
_local2.MOBILE = enterCompetitionScreenRef.mobile_txt.text;
_local2.EMAIL = enterCompetitionScreenRef.email_txt.text;
_local2.sendAndLoad(baseurl + "SaveScore.php", resultVars, "POST");
resultVars.onLoad = uk.kerb.utils.EventDelegate.create(this, onSubmitEnterCompetionForm);
}
function onSubmitEnterCompetionForm() {
if (resultVars.result == "1") {
showHighscoreScreen();
} else {
enterCompetitionScreenRef.gotoAndStop("error");
buttonClick(enterCompetitionScreenRef.btn_back_mc, showEnterCompetionScreen);
}
}
function showSubmitHighscoreScreen() {
hideScreens();
submitHighscoreScreenRef.swapDepths(mcRef.getNextHighestDepth());
submitHighscoreScreenRef._visible = true;
submitHighscoreScreenRef.gotoAndStop(1);
submitHighscoreScreenRef.firstname_txt.tabIndex = 1;
submitHighscoreScreenRef.lastname_txt.tabIndex = 2;
submitHighscoreScreenRef.submit_mc.tabIndex = 3;
buttonClick(submitHighscoreScreenRef.submit_mc, submitHighscoreForm);
}
function submitHighscoreForm() {
delete submitHighscoreScreenRef.submit_mc.onPress;
var _local2 = new LoadVars();
resultVars = new LoadVars();
_local2.FIRSTNAME = submitHighscoreScreenRef.firstname_txt.text;
_local2.LASTNAME = submitHighscoreScreenRef.lastname_txt.text;
_local2.SCORE = score;
_local2.sendAndLoad(baseurl + "SaveScore.php", resultVars, "POST");
resultVars.onLoad = uk.kerb.utils.EventDelegate.create(this, onSubmitHighscoreForm);
}
function onSubmitHighscoreForm() {
if (resultVars.result == "1") {
showHighscoreScreen();
} else {
submitHighscoreScreenRef.gotoAndStop("error");
buttonClick(submitHighscoreScreenRef.btn_back_mc, showSubmitHighscoreScreen);
}
}
function showHighscoreScreen() {
hideScreens();
playClick();
mx.transitions.TransitionManager.start(highscoreScreenRef, {type:mx.transitions.Iris, direction:mx.transitions.Transition.IN, duration:1, easing:mx.transitions.easing.Regular.easeOut, startPoint:5, shape:mx.transitions.Iris.CIRCLE});
highscoreScreenRef.swapDepths(mcRef.getNextHighestDepth());
highscoreScreenRef._visible = true;
buttonClick(highscoreScreenRef.btn_back_mc, showFrontPage);
buttonClick(highscoreScreenRef.btn_tellafriend_mc, showTellAFriendScreen);
resultVars = new LoadVars();
resultVars.onLoad = uk.kerb.utils.EventDelegate.create(this, onLoadHighscore);
resultVars.load(baseurl + "GetScores.php");
}
function onLoadHighscore() {
if (resultVars.result == "1") {
highscoreScreenRef.gotoAndStop("ok");
var _local5 = resultVars.total;
var _local7 = highscoreScreenRef.holder_mc;
var _local4 = _local7.content_mc;
for (var _local6 in _local4) {
_local4[_local6].removeMovieClip();
}
var _local3;
var _local2 = 1;
while (_local2 <= _local5) {
_local3 = _local4.attachMovie("highscore_row_mc", "row" + _local2, _local2);
_local3.name_txt.text = resultVars["name" + _local2];
_local3.score_txt.text = resultVars["score" + _local2];
_local3._y = 22 * (_local2 - 1);
_local2++;
}
var _local8 = new uk.kerb.utils.ui.Scrollbar(highscoreScreenRef.scollbar_mc, _local7);
_local8.setScaleHandle(false);
_local8.update();
} else {
highscoreScreenRef.gotoAndStop("error");
}
}
function startGame() {
threedeobjects = new Array();
camera = new Cam(0, -60, -DEEP);
hideScreens();
createStreet();
drawStreet();
backgroundsRef._visible = true;
windScreenRef._visible = true;
windScreenRef.swapDepths(mcRef.getNextHighestDepth());
windScreenRef.radio_mc.onPress = uk.kerb.utils.EventDelegate.create(this, toggleSound);
updateHits(0);
score = 0;
nextLevel();
}
function showInstructions(_frame) {
playClick();
instructionsScreenRef.swapDepths(mcRef.getNextHighestDepth());
if (_frame == 1) {
mx.transitions.TransitionManager.start(instructionsScreenRef, {type:mx.transitions.Iris, direction:mx.transitions.Transition.IN, duration:1, easing:mx.transitions.easing.Regular.easeOut, startPoint:5, shape:mx.transitions.Iris.CIRCLE});
}
instructionsScreenRef._visible = true;
instructionsScreenRef.gotoAndStop(_frame);
buttonClick(instructionsScreenRef.btn_back_mc, showStartScreen);
if (_frame == 3) {
buttonClick(instructionsScreenRef.btn_play_mc, startGame);
} else {
buttonClick(instructionsScreenRef.btn_next_mc, showInstructions, _frame + 1);
}
}
function showTermsScreen() {
playClick();
var _local4 = "1. The competition will close at 12 midday on 12th Jan 2006.\n2. The competition is open to all residents of the UK and ROI aged 18 or over, except employees of News International Limited and their associated, affiliated or subsidiary companies, and their families, agents, or anyone connected with this Competition.\n3. An eligible entrant must be an individual and must submit an entry in the form provided by Times Newspapers Limited under this promotion including their name, e-mail address and mobile phone number.\n4. By entering, all eligible entrants agree to abide by each and all these General Rules. Times Newspapers Limited reserves the right, with or without cause, to exclude entrants and withhold prizes for violating any of these General Rules. Times Newspapers Limited reserves the right to amend these General Rules. Any amendments will be published on the Website. \n5. The winner is the first complete entry drawn at random from all entries received before the closing date as specified. The winner will receive \none Samsung 32\" Widescreen HD Ready LCD TV - With Freeview.\n6. There is no cash or other alternative to the prize stated and the prize is not transferable and no part or parts of the prize may be substituted for other benefits, items or additions.\n7. The judge's decision is final and binding on the entrants. No correspondence will be entered into.\n8. Times Newspapers Limited will not be liable for technical, hardware, or software failures of any kind or lost or unavailable network connections which may limit or prohibit an eligible entrant's ability to participate in the Competition.\n9. The winners will be notified by e-mail within seven days from the draw date. All reasonable endeavours will be made to contact the winners during this time. If the winner cannot be contacted before this time, the promoter reserves the right to re-draw a winner from the correct entries which were received before the closing date as specified at entry.\n10. By entering, any subsequent prize winners agree to allow the free use of their names, photographs and general locations for publicity and news purposes during this and future promotions by Times Newspapers Limited or any associated or subsidiary company of News International Limited.\n11. Uses of personal data received by Times Newspapers Limited in the course of the promotion are subject to the privacy policy found on the Website. Winners' names may be published on the Website.\n12. The promoter of this prize draw is Times Newspapers Limited of 1 Virginia Street London E98 1XY.\n\n";
termsScreenRef.swapDepths(mcRef.getNextHighestDepth());
termsScreenRef._visible = true;
buttonClick(termsScreenRef.bnt_back_mc, showFrontPage);
mx.transitions.TransitionManager.start(termsScreenRef, {type:mx.transitions.Iris, direction:mx.transitions.Transition.IN, duration:1, easing:mx.transitions.easing.Regular.easeOut, startPoint:5, shape:mx.transitions.Iris.CIRCLE});
var _local2 = termsScreenRef.scrollholder_mc.content_mc.terms_txt;
_local2.text = _local4;
_local2.autoSize = true;
_local2.multiline = true;
var _local3 = new uk.kerb.utils.ui.Scrollbar(termsScreenRef.scollbar_mc, termsScreenRef.scrollholder_mc);
_local3.setScaleHandle(false);
_local3.update();
}
function showFrontPage() {
playClick();
if (_root.competition != "1") {
frontPageRef.gotoAndStop(2);
}
frontPageRef.swapDepths(mcRef.getNextHighestDepth());
frontPageRef._visible = true;
mx.transitions.TransitionManager.start(frontPageRef, {type:mx.transitions.Iris, direction:mx.transitions.Transition.IN, duration:1, easing:mx.transitions.easing.Regular.easeOut, startPoint:5, shape:mx.transitions.Iris.CIRCLE});
buttonClick(frontPageRef.bnt_highscore_mc, showHighscoreScreen);
buttonClick(frontPageRef.btn_startgame_mc, showStartScreen);
buttonClick(frontPageRef.bnt_terms_mc, showTermsScreen);
}
function showStartScreen() {
playClick();
startScreenRef.swapDepths(mcRef.getNextHighestDepth());
startScreenRef._visible = true;
mx.transitions.TransitionManager.start(startScreenRef, {type:mx.transitions.Iris, direction:mx.transitions.Transition.IN, duration:1, easing:mx.transitions.easing.Regular.easeOut, startPoint:5, shape:mx.transitions.Iris.CIRCLE});
buttonClick(startScreenRef.btn_instructions_mc, showInstructions, 1);
buttonClick(startScreenRef.btn_play_mc, checkIfInstructionsRead);
}
function checkIfInstructionsRead() {
var _local2 = SharedObject.getLocal("nobbler");
if (_local2.data.instructionsRead == true) {
startGame();
} else {
showInstructions(1);
_local2.data.instructionsRead = true;
}
_local2.flush();
}
function showResultScreen() {
delete mcRef.onEnterFrame;
soundManager.stopEverySound(2);
resultScreenRef._visible = true;
resultScreenRef.wiper_mc.gotoAndPlay(2);
var _local8 = new mx.transitions.Tween(resultScreenRef.scores_mc, "_alpha", mx.transitions.easing.Regular.easeOut, 0, 100, 10, false);
var _local6 = 120;
var _local4 = (getTimer() - timer) / 1000;
var _local7 = Math.floor(_local4 / 60);
var _local3 = Math.floor(_local4 % 60);
var _local5 = ((_local3 < 10) ? ("0" + _local3) : (_local3 + ""));
resultScreenRef.scores_mc.time_txt.text = (_local7 + " : ") + _local5;
resultScreenRef.scores_mc.hits_txt.text = hits;
var _local2 = (_local6 - _local4) * 100;
_local2 = _local2 + (hits * 100);
_local2 = Math.round(_local2);
score = score + _local2;
resultScreenRef.scores_mc.score_txt.text = _local2;
resultScreenRef.scores_mc.total_txt.text = score;
buttonClick(resultScreenRef.scores_mc.continue_mc, nextLevel);
Key.addListener(this);
}
function onKeyDown() {
if ((Key.getCode() == 13) || (Key.getCode() == 32)) {
Key.removeListener(this);
nextLevel();
}
}
function updateSpeed(_delta) {
var _local2 = false;
var _local3 = _delta + speed;
if ((_local3 <= 60) && (_local3 >= 0)) {
speed = _delta + speed;
_local2 = true;
windScreenRef.dashboard_mc.speedo_anim_mc.gotoAndStop(speed + 1);
}
return(_local2);
}
function toggleSound() {
windScreenRef.left_arm_mc.radio_arm_mc.gotoAndPlay(2);
windScreenRef.left_arm_mc.gear_anim_mc.gotoAndStop(1);
if (sound) {
soundManager.soundOff();
} else {
soundManager.soundOn();
}
sound = !sound;
}
function drawStreet() {
var _local3;
_local3 = street[0];
renderObject3D(_local3);
streetRef.clear();
streetRef.moveTo(_local3.__get__x(), _local3.__get__y());
streetRef.beginFill(0, 60);
var _local2 = 1;
while (_local2 < street.length) {
_local3 = street[_local2];
renderObject3D(_local3);
streetRef.lineTo(_local3.__get__x(), _local3.__get__y());
_local2++;
}
streetRef.endFill();
}
function onUpdateSzene() {
var _local4 = false;
if (Key.isDown(32)) {
hornPressed();
}
if (Key.isDown(37) && (speed > 0)) {
camera.xpos = camera.xpos - STEERINGSPEED;
updateDashBoard(-5);
drawStreet();
} else if (Key.isDown(39) && (speed > 0)) {
camera.xpos = camera.xpos + STEERINGSPEED;
updateDashBoard(5);
drawStreet();
} else if (Key.isDown(40)) {
_local4 = updateSpeed(-ACCELERATION);
soundManager.playSound("skid1", speed);
} else if (Key.isDown(38)) {
_local4 = updateSpeed(ACCELERATION + 1);
}
if ((camera.xpos > STREET) || (camera.xpos < (-STREET))) {
_local4 = updateSpeed(-ACCELERATION);
}
if (speed == 0) {
windScreenRef.speedlines_mc.stop();
windScreenRef.steering_wheel_anim_mc.stop();
} else if ((speed > 0) && (_local4)) {
windScreenRef.speedlines_mc.play();
windScreenRef.steering_wheel_anim_mc.play();
changeGears();
}
var _local2;
var _local3 = 0;
while (_local3 < threedeobjects.length) {
_local2 = threedeobjects[_local3];
if (_local4) {
_local2.speedZ = -speed;
}
if (_local2.runsIfClose && (_local2.zpos < ((-DEEP) + 200))) {
_local2.startAnimation(camera.xpos);
}
move(_local2);
renderObject3D(_local2);
_local3++;
}
}
function updateDashBoard(_dir) {
var _local6 = windScreenRef.trophy_mc;
var _local3 = windScreenRef.man_mc.figure_mc;
var _local10 = windScreenRef.man_mc.shadow_mc;
var _local4 = 10;
ttw = new mx.transitions.Tween(_local6, "_rotation", mx.transitions.easing.Regular.easeOut, _local6._rotation, _local6._rotation + _dir, _local4, false);
ttw.onMotionFinished = uk.kerb.utils.EventDelegate.create(this, bounceDashBoard);
mtw = new mx.transitions.Tween(_local3, "_rotation", mx.transitions.easing.Regular.easeOut, _local3._rotation, _local3._rotation - _dir, _local4, false);
stw = new mx.transitions.Tween(_local10, "_x", mx.transitions.easing.Regular.easeOut, _local3._x, _local3._x - _dir, _local4, false);
var _local2 = windScreenRef.ball_mc;
var _local5 = _local2._x - (_dir * (speed / 3));
var _local9 = -355;
var _local8 = 372;
if (_local5 > _local8) {
_local5 = _local8;
} else if (_local5 < _local9) {
_local5 = _local9;
}
btw = new mx.transitions.Tween(_local2, "_x", mx.transitions.easing.Regular.easeOut, _local2._x, _local5, _local4, false);
rtw = new mx.transitions.Tween(_local2, "_rotation", mx.transitions.easing.Regular.easeOut, _local2._rotation, _local2._rotation - (_dir * (speed / 3)), _local4, false);
}
function bounceDashBoard() {
delete ttw.onMotionFinished;
delete mtw.onMotionFinished;
delete stw.onMotionFinished;
ttw.continueTo(0, 10);
mtw.continueTo(0, 10);
stw.continueTo(0, 10);
}
function hornPressed() {
if (!horn) {
horn = true;
hornInterval = setInterval(this, "hornAction", 600);
windScreenRef.left_arm_mc.horn_hit_ani_mc.gotoAndPlay(1);
windScreenRef.left_arm_mc.gear_anim_mc.gotoAndStop(1);
windScreenRef.left_arm_mc.radio_arm_mc.gotoAndStop(1);
}
}
function hornAction() {
var _local4;
soundManager.playSound("horn");
var _local3 = 0;
while (_local3 < threedeobjects.length) {
_local4 = threedeobjects[_local3];
if (_local4.movesAway && (_local4.zpos < (1000 - DEEP))) {
_local4.startAnimation();
}
_local3++;
}
horn = false;
clearInterval(hornInterval);
}
function changeGears() {
windScreenRef.left_arm_mc.gear_anim_mc.gotoAndPlay(2);
windScreenRef.left_arm_mc.horn_hit_ani_mc.gotoAndStop(1);
windScreenRef.left_arm_mc.radio_arm_mc.gotoAndStop(1);
}
function move(o) {
if (!o.ignore) {
if ((o.zpos - 80) > camera.zpos) {
o.zpos = o.zpos + o.speedZ;
o.xpos = o.xpos + o.speedX;
o.ypos = o.ypos + o.speedY;
} else {
o.mcRef.filters = undefined;
if ((Math.abs(camera.xpos - o.xpos) < 50) && (o.doesDamage || (o.hitBonus))) {
if (o.hitBonus) {
soundManager.playSound("animal");
updateHits(hits++);
o.reset();
} else {
updateSpeed(-speed);
collision(o.xpos);
o.hit(camera.xpos);
}
} else {
o.reset();
}
}
} else {
o.xpos = camera.xpos + o.impactX;
o.ypos = o.ypos + 2;
}
}
function collision(_xpos) {
mcRef.crash_mc.gotoAndPlay(2);
soundManager.playSound("skid2", 50);
var _local3;
var _local2 = 0;
while (_local2 < threedeobjects.length) {
_local3 = threedeobjects[_local2];
_local3.speedZ = 0;
_local3.zpos = _local3.zpos + 10;
_local2++;
}
soundManager.playSound("glassbreak");
addWindScreenCrack(_xpos - camera.xpos);
}
function addWindScreenCrack(_pos) {
var _local5 = windScreenRef.crackholder_mc;
_local5.cacheAsBitmap = true;
if (crackBmp == undefined) {
crackBmp = new flash.display.BitmapData(windScreenRef._width, windScreenRef._height, true, 0);
}
var _local3 = mcRef.attachMovie("crack_mc", "crack" + mcRef.getNextHighestDepth(), mcRef.getNextHighestDepth());
_local3.gotoAndStop(uk.kerb.utils.Random.getFromRange(1, 3));
var _local4 = new flash.geom.Matrix();
_local4.translate((Stage.width / 2) + (2 * _pos), uk.kerb.utils.Random.getFromRange(150, 250));
crackBmp.draw(_local3, _local4);
_local3.removeMovieClip();
_local5.attachBitmap(crackBmp, 0);
}
function resetWindscreen() {
crackBmp.dispose();
crackBmp = new flash.display.BitmapData(windScreenRef._width, windScreenRef._height, true, 0);
}
function objectOffscreen(o) {
var _local2 = 1;
while (_local2 < threedeobjects.length) {
if (threedeobjects[_local2] == o) {
threedeobjects.splice(_local2, 1);
}
_local2++;
}
}
function renderObject3D(o) {
var _local6 = o.xpos - camera.xpos;
var _local5 = o.ypos - camera.ypos;
var _local4 = o.zpos - camera.zpos;
var _local3 = camera.VIEWDISTANCE / _local4;
o.__set__x((_local6 * _local3) + 400);
o.__set__y((_local5 * _local3) + 200);
o.__set__scale(_local3 * 100);
o.mcRef.swapDepths(-_local4);
}
static function init(_mcRef) {
var _local2 = new World(_mcRef);
}
var horn = false;
var sound = true;
static var DEEP = 2000;
static var SPEED = 2;
static var STREET = 200;
static var ACCELERATION = 1;
static var STEERINGSPEED = 10;
static var PLAYERCOUNT = 6;
var hits = 0;
var timer = 0;
var score = 0;
var speed = 0;
var playerHits = 0;
var currentLevel = 1;
var baseurl = "http://w03-ashes.exalia.net/";
}
Symbol 732 MovieClip [__Packages.mx.transitions.OnEnterFrameBeacon] Frame 0
class mx.transitions.OnEnterFrameBeacon
{
function OnEnterFrameBeacon () {
}
static function init() {
var _local4 = _global.MovieClip;
if (!_root.__OnEnterFrameBeacon) {
mx.transitions.BroadcasterMX.initialize(_local4);
var _local3 = _root.createEmptyMovieClip("__OnEnterFrameBeacon", 9876);
_local3.onEnterFrame = function () {
_global.MovieClip.broadcastMessage("onEnterFrame");
};
}
}
}
Symbol 733 MovieClip [__Packages.mx.transitions.BroadcasterMX] Frame 0
class mx.transitions.BroadcasterMX
{
var _listeners;
function BroadcasterMX () {
}
static function initialize(o, dontCreateArray) {
if (o.broadcastMessage != undefined) {
delete o.broadcastMessage;
}
o.addListener = mx.transitions.BroadcasterMX.prototype.addListener;
o.removeListener = mx.transitions.BroadcasterMX.prototype.removeListener;
if (!dontCreateArray) {
o._listeners = new Array();
}
}
function addListener(o) {
removeListener(o);
if (broadcastMessage == undefined) {
broadcastMessage = mx.transitions.BroadcasterMX.prototype.broadcastMessage;
}
return(_listeners.push(o));
}
function removeListener(o) {
var _local2 = _listeners;
var _local3 = _local2.length;
while (_local3--) {
if (_local2[_local3] == o) {
_local2.splice(_local3, 1);
if (!_local2.length) {
broadcastMessage = undefined;
}
return(true);
}
}
return(false);
}
function broadcastMessage() {
var _local5 = String(arguments.shift());
var _local4 = _listeners.concat();
var _local6 = _local4.length;
var _local3 = 0;
while (_local3 < _local6) {
_local4[_local3][_local5].apply(_local4[_local3], arguments);
_local3++;
}
}
}
Symbol 734 MovieClip [__Packages.mx.transitions.Tween] Frame 0
class mx.transitions.Tween
{
var obj, prop, begin, useSeconds, _listeners, addListener, prevTime, _time, looping, _duration, broadcastMessage, isPlaying, _fps, prevPos, _pos, change, _intervalID, _startTime;
function Tween (obj, prop, func, begin, finish, duration, useSeconds) {
mx.transitions.OnEnterFrameBeacon.init();
if (!arguments.length) {
return;
}
this.obj = obj;
this.prop = prop;
this.begin = begin;
position = (begin);
this.duration = (duration);
this.useSeconds = useSeconds;
if (func) {
this.func = func;
}
this.finish = (finish);
_listeners = [];
addListener(this);
start();
}
function set time(t) {
prevTime = _time;
if (t > duration) {
if (looping) {
rewind(t - _duration);
update();
broadcastMessage("onMotionLooped", this);
} else {
if (useSeconds) {
_time = _duration;
update();
}
stop();
broadcastMessage("onMotionFinished", this);
}
} else if (t < 0) {
rewind();
update();
} else {
_time = t;
update();
}
//return(time);
}
function get time() {
return(_time);
}
function set duration(d) {
_duration = (((d == null) || (d <= 0)) ? (_global.Infinity) : (d));
//return(duration);
}
function get duration() {
return(_duration);
}
function set FPS(fps) {
var _local2 = isPlaying;
stopEnterFrame();
_fps = fps;
if (_local2) {
startEnterFrame();
}
//return(FPS);
}
function get FPS() {
return(_fps);
}
function set position(p) {
setPosition(p);
//return(position);
}
function setPosition(p) {
prevPos = _pos;
obj[prop] = (_pos = p);
broadcastMessage("onMotionChanged", this, _pos);
updateAfterEvent();
}
function get position() {
return(getPosition());
}
function getPosition(t) {
if (t == undefined) {
t = _time;
}
return(func(t, begin, change, _duration));
}
function set finish(f) {
change = f - begin;
//return(finish);
}
function get finish() {
return(begin + change);
}
function continueTo(finish, duration) {
begin = position;
this.finish = (finish);
if (duration != undefined) {
this.duration = (duration);
}
start();
}
function yoyo() {
continueTo(begin, time);
}
function startEnterFrame() {
if (_fps == undefined) {
_global.MovieClip.addListener(this);
} else {
_intervalID = setInterval(this, "onEnterFrame", 1000 / _fps);
}
isPlaying = true;
}
function stopEnterFrame() {
if (_fps == undefined) {
_global.MovieClip.removeListener(this);
} else {
clearInterval(_intervalID);
}
isPlaying = false;
}
function start() {
rewind();
startEnterFrame();
broadcastMessage("onMotionStarted", this);
}
function stop() {
stopEnterFrame();
broadcastMessage("onMotionStopped", this);
}
function resume() {
fixTime();
startEnterFrame();
broadcastMessage("onMotionResumed", this);
}
function rewind(t) {
_time = ((t == undefined) ? 0 : (t));
fixTime();
update();
}
function fforward() {
time = (_duration);
fixTime();
}
function nextFrame() {
if (useSeconds) {
time = ((getTimer() - _startTime) / 1000);
} else {
time = (_time + 1);
}
}
function onEnterFrame() {
nextFrame();
}
function prevFrame() {
if (!useSeconds) {
time = (_time - 1);
}
}
function toString() {
return("[Tween]");
}
function fixTime() {
if (useSeconds) {
_startTime = getTimer() - (_time * 1000);
}
}
function update() {
position = (getPosition(_time));
}
static var __initBeacon = mx.transitions.OnEnterFrameBeacon.init();
static var __initBroadcaster = mx.transitions.BroadcasterMX.initialize(mx.transitions.Tween.prototype, true);
function func(t, b, c, d) {
return(((c * t) / d) + b);
}
}
Symbol 735 MovieClip [__Packages.Cam] Frame 0
class Cam
{
var xpos, ypos, zpos;
function Cam (_xpos, _ypos, _zpos) {
xpos = _xpos;
ypos = _ypos;
zpos = _zpos;
}
var VIEWDISTANCE = 200;
}
Symbol 736 MovieClip [__Packages.uk.kerb.utils.sound.SoundManager] Frame 0
class uk.kerb.utils.sound.SoundManager
{
var mcRef, soundList, preloaderList, globalSounds, allSoundsLoaded, soundLoadStarted;
function SoundManager (_mcRef) {
mcRef = _mcRef;
soundList = new Array();
preloaderList = new Array();
globalSounds = new Sound();
}
function loadSoundList(_soundlist) {
var _local6 = false;
var _local5;
var _local4;
var _local2 = 0;
while (_local2 < _soundlist.length) {
if (_soundlist[_local2].toLowerCase().indexOf(".mp3") > -1) {
preloaderList.push(_soundlist[_local2]);
_local6 = true;
} else {
_local5 = mcRef.createEmptyMovieClip("sounddummy" + mcRef.getNextHighestDepth(), mcRef.getNextHighestDepth());
_local4 = new uk.kerb.utils.sound.ExtendedSound(_local5);
_local4.attachSound(_soundlist[_local2]);
soundList[_soundlist[_local2]] = _local4;
}
_local2++;
}
if (_local6) {
preloadNextMP3();
} else {
allSoundsLoaded(true);
}
}
function playSound(_id, _volume, _loops, _fadeSpeedSeconds) {
soundList[_id].start(0, _loops);
if ((_fadeSpeedSeconds != undefined) && (_fadeSpeedSeconds != 0)) {
soundList[_id].setVolume(0);
soundList[_id].startFade(_volume, _fadeSpeedSeconds);
} else {
soundList[_id].setVolume(_volume);
}
}
function stopSound(_id, _fadeSpeed) {
if ((_fadeSpeed != undefined) && (_fadeSpeed != 0)) {
soundList[_id].startFade(0, _fadeSpeed);
} else {
soundList[_id].stop();
}
}
function stopEverySound(_fadeSpeed, _excludIdlist) {
var _local2;
for (var _local5 in soundList) {
_local2 = soundList[_local5];
if (!checkIfExcluded(Number(_local5), _excludIdlist)) {
if ((_fadeSpeed != undefined) && (_fadeSpeed != 0)) {
_local2.startFade(0, _fadeSpeed);
} else {
_local2.stop();
}
}
}
}
function soundOff() {
var _local2;
for (var _local3 in soundList) {
_local2 = soundList[_local3];
_local2.setMute(true);
}
globalSounds.setVolume(0);
}
function soundOn() {
for (var _local2 in soundList) {
soundList[_local2].setMute(false);
}
globalSounds.setVolume(100);
}
function fadeInRandomSound(_obj, _fadeSpeed) {
var _local6 = 0;
var _local3 = 0;
while (_local3 < _obj.length) {
_local6 = _local6 + _obj[_local3].freqency;
_local3++;
}
var _local5 = 0;
_local3 = 0;
while (_local3 < _obj.length) {
_local5 = _local5 + (_obj[_local3].freqency / _local6);
_obj[_local3].chance = _local5;
_local3++;
}
var _local4 = Math.random();
var _local7 = 0;
_local3 = 1;
while (_local3 < _obj.length) {
if ((_local4 > _obj[_local3 - 1].chance) && (_local4 <= _obj[_local3].chance)) {
_local7 = _local3;
}
_local3++;
}
var _local8 = _obj[_local7].level.split("-");
var _local9 = (Math.random() * (Number(_local8[1]) - Number(_local8[0]))) + Number(_local8[0]);
playSound(_obj[_local7].id, _local9, 1, _fadeSpeed);
}
function checkIfExcluded(_excludeid, _excludIdlist) {
var _local1 = 0;
while (_local1 < _excludIdlist.length) {
if (_excludIdlist[_local1] == _excludeid) {
return(true);
}
_local1++;
}
return(false);
}
function preloadNextMP3() {
var _local7 = this;
if (preloaderList.length > 0) {
var _local2 = preloaderList.shift();
if (soundLoadStarted != undefined) {
soundLoadStarted(_local2);
}
var _local6 = mcRef.createEmptyMovieClip("sounddummy" + mcRef.getNextHighestDepth(), mcRef.getNextHighestDepth());
var _local3 = new uk.kerb.utils.sound.ExtendedSound(_local6);
_local3.loadSound(_local2);
var _local5 = _local2.split("/");
var _local4 = _local5[_local5.length - 1].slice(0, -4);
soundList[_local4] = _local3;
soundList[_local4].onLoad = uk.kerb.utils.EventDelegate.create(this, preloadNextMP3);
} else {
allSoundsLoaded(true);
}
}
}
Symbol 737 MovieClip [__Packages.uk.kerb.utils.sound.ExtendedSound] Frame 0
class uk.kerb.utils.sound.ExtendedSound extends Sound
{
var mcRef, mute, fade, onFadeComplete, volume, decay, loops, isPlaying;
function ExtendedSound (_mcRef) {
super((mcRef = _mcRef));
mute = 1;
}
function startFade(_targetVolume, _speed) {
fade = new mx.transitions.Tween(this, "volume", mx.transitions.easing.Regular.easeOut, getVolume(), _targetVolume, _speed, true);
fade.onMotionChanged = uk.kerb.utils.EventDelegate.create(this, setFadeVolume);
fade.onMotionFinished = uk.kerb.utils.EventDelegate.create(this, onFadeComplete);
return(this);
}
function setFadeVolume(_tw) {
setVolume(volume);
}
function attachSound(_libraryID) {
stop();
super.attachSound(_libraryID);
return(this);
}
function loadSound(_mp3URL) {
stop();
super.loadSound(_mp3URL, false);
return(this);
}
function start(_decay, _loops) {
stop();
if (_decay == undefined) {
_decay = 0;
}
if (_loops == undefined) {
_loops = 1;
}
super.start((decay = _decay), (loops = _loops));
isPlaying = true;
return(this);
}
function stop() {
super.stop();
isPlaying = false;
return(this);
}
function setVolume(_volume) {
if (_volume == undefined) {
_volume = 100;
}
super.setVolume(((((volume = _volume)) / 100) * masterVolume) * mute);
return(this);
}
function getVolume() {
return(volume);
}
function setMute(_bool) {
mute = (_bool ? 0 : 1);
setVolume(getVolume());
return(this);
}
static var masterVolume = 100;
}
Symbol 738 MovieClip [__Packages.mx.transitions.easing.Regular] Frame 0
class mx.transitions.easing.Regular
{
function Regular () {
}
static function easeIn(t, b, c, d) {
t = t / d;
return(((c * t) * t) + b);
}
static function easeOut(t, b, c, d) {
t = t / d;
return((((-c) * t) * (t - 2)) + b);
}
static function easeInOut(t, b, c, d) {
t = t / (d / 2);
if (t < 1) {
return((((c / 2) * t) * t) + b);
}
t--;
return((((-c) / 2) * ((t * (t - 2)) - 1)) + b);
}
}
Symbol 739 MovieClip [__Packages.uk.kerb.utils.EventDelegate] Frame 0
class uk.kerb.utils.EventDelegate
{
function EventDelegate () {
}
static function create(scope, method) {
var params = arguments.splice(2, arguments.length - 2);
var _local2 = function () {
method.apply(scope, arguments.concat(params));
};
return(_local2);
}
}
Symbol 740 MovieClip [__Packages.Object3D] Frame 0
class Object3D
{
var zpos, ypos, xpos, mcRef, __get__scale;
function Object3D () {
AsBroadcaster.initialize(this);
}
function toString() {
return((((("xpos: " + xpos) + "ypos: ") + ypos) + "zpos: ") + zpos);
}
function set x(_value) {
mcRef._x = _value;
//return(x);
}
function set y(_value) {
mcRef._y = _value;
//return(y);
}
function get x() {
return(mcRef._x);
}
function get y() {
return(mcRef._y);
}
function set scale(_value) {
mcRef._xscale = (mcRef._yscale = _value);
//return(__get__scale());
}
function stopAnimation() {
}
function startAnimation() {
}
function reset() {
}
function hit(_cameraX) {
}
var doesDamage = false;
var movesAway = false;
var runOver = false;
var hitBonus = false;
var runsIfClose = false;
var ignore = false;
}
Symbol 741 MovieClip [__Packages.obstacle.Dummy] Frame 0
class obstacle.Dummy extends Object3D
{
var mcRef, xpos, ypos, zpos;
function Dummy (_mcRef, _xpos, _ypos, _zpos, _nr) {
super();
mcRef = _mcRef.createEmptyMovieClip("dummy" + _mcRef.getNextHighestDepth(), _mcRef.getNextHighestDepth());
xpos = _xpos;
ypos = _ypos;
zpos = _zpos;
}
}
Symbol 742 MovieClip [__Packages.obstacle.Player] Frame 0
class obstacle.Player extends Object3D
{
var xpos, nr, ypos, zpos, mcRef, speedZ, speedX, speedY, movesAway, doesDamage, runsIfClose, isHit, resetInterVal, broadcastMessage, ignore, impactX;
function Player (_mcRef, _xpos, _ypos, _zpos, _nr) {
super();
xpos = _xpos;
nr = _nr;
ypos = _ypos;
zpos = _zpos;
mcRef = _mcRef.attachMovie(("player" + _nr) + "_mc", "player" + _mcRef.getNextHighestDepth(), _mcRef.getNextHighestDepth());
speedZ = 0;
speedX = 0;
speedY = 0;
movesAway = true;
doesDamage = true;
runsIfClose = true;
isHit = false;
}
function reset() {
xpos = uk.kerb.utils.Random.getFromRange(-World.STREET, World.STREET);
zpos = 0;
speedX = 0;
speedY = 0;
stopAnimation();
isRunning = false;
mcRef.filters = undefined;
isHit = false;
}
function remove() {
clearInterval(resetInterVal);
broadcastMessage("onPlayerHit", this);
}
function stopAnimation() {
mcRef.gotoAndStop(1);
}
function startAnimation(_camx) {
if ((!isRunning) && (!isHit)) {
var _local3 = uk.kerb.utils.Random.getFromRange(10, 30);
speedX = (((_camx - xpos) < 0) ? (_local3) : (-_local3));
if (Math.random() > 0.75) {
speedX = -speedX;
speedX = speedX / 2;
}
mcRef.gotoAndStop(((speedX < 0) ? "runleft" : "runright"));
var _local5 = new flash.filters.BlurFilter(Math.abs(speedX), 0, 3);
var _local4 = new Array();
_local4.push(_local5);
mcRef.filters = _local4;
isRunning = true;
}
}
function hit(_cameraX) {
mcRef.filters = undefined;
zpos = (-World.DEEP) + Math.round(uk.kerb.utils.Random.getFromRange(60, 75));
ypos = -10;
speedX = 0;
speedY = 0;
speedZ = 0;
mcRef.filters = undefined;
mcRef.gotoAndStop("crash");
ignore = true;
impactX = xpos - _cameraX;
broadcastMessage("playSoundEffect", "player" + nr);
broadcastMessage("showSlangGood", this);
resetInterVal = setInterval(this, "remove", 1000);
isHit = true;
}
var isRunning = false;
}
Symbol 743 MovieClip [__Packages.uk.kerb.utils.Random] Frame 0
class uk.kerb.utils.Random
{
function Random () {
}
static function getFromRange(_min, _max) {
var _local2 = _max - _min;
var _local1 = (Math.random() * _local2) + _min;
return(Math.round(_local1));
}
static function getSimple(_max) {
var _local1 = Math.random() * _max;
return(Math.round(_local1));
}
static function getBoolean(_percent) {
return(Math.random() > _percent);
}
}
Symbol 744 MovieClip [__Packages.obstacle.Flag] Frame 0
class obstacle.Flag extends Object3D
{
var mcRef, xpos, ypos, zpos, speedZ, speedX, speedY, doesDamage, movesAway;
function Flag (_mcRef) {
super();
mcRef = _mcRef.attachMovie("flag_mc", "flag", _mcRef.getNextHighestDepth());
xpos = (-World.STREET) - 30;
ypos = 0;
zpos = uk.kerb.utils.Random.getSimple(-World.DEEP);
speedZ = 0;
speedX = 0;
speedY = 0;
doesDamage = true;
movesAway = false;
}
function reset() {
zpos = 0;
}
}
Symbol 745 MovieClip [__Packages.obstacle.Umbrella] Frame 0
class obstacle.Umbrella extends Object3D
{
var mcRef, xpos, ypos, zpos, speedZ, speedY, speedX, doesDamage, movesAway;
function Umbrella (_mcRef) {
super();
var _local4 = Math.round(uk.kerb.utils.Random.getFromRange(1, 4));
mcRef = _mcRef.attachMovie(("umbrella" + _local4) + "_mc", "umbrella" + _mcRef.getNextHighestDepth(), _mcRef.getNextHighestDepth());
xpos = ((Math.random() > 0.5) ? ((-World.STREET) - (Math.random() * 500)) : (World.STREET + (Math.random() * 500)));
ypos = 0;
zpos = uk.kerb.utils.Random.getSimple(-World.DEEP);
speedZ = 0;
speedY = 0;
speedX = 0;
doesDamage = true;
movesAway = false;
}
function reset() {
zpos = 0;
}
}
Symbol 746 MovieClip [__Packages.obstacle.Palm] Frame 0
class obstacle.Palm extends Object3D
{
var mcRef, xpos, ypos, zpos, speedZ, speedY, speedX, doesDamage, movesAway;
function Palm (_mcRef) {
super();
var _local4 = Math.round(uk.kerb.utils.Random.getFromRange(1, 3));
mcRef = _mcRef.attachMovie(("palm" + _local4) + "_mc", "palm" + _mcRef.getNextHighestDepth(), _mcRef.getNextHighestDepth());
xpos = ((Math.random() > 0.5) ? ((-World.STREET) - (Math.random() * 500)) : (World.STREET + (Math.random() * 500)));
ypos = 0;
zpos = uk.kerb.utils.Random.getSimple(-World.DEEP);
speedZ = 0;
speedY = 0;
speedX = 0;
doesDamage = true;
movesAway = false;
}
function reset() {
zpos = 0;
}
}
Symbol 747 MovieClip [__Packages.obstacle.BigAnimal] Frame 0
class obstacle.BigAnimal extends Object3D
{
var xpos, ypos, zpos, type, mcRef, speedZ, speedX, speedY, movesAway, doesDamage, isHit, impactX, ignore, resetInterVal, broadcastMessage;
function BigAnimal (_mcRef, _xpos, _ypos, _zpos, _type) {
super();
xpos = _xpos;
ypos = _ypos;
zpos = _zpos;
type = _type;
mcRef = _mcRef.attachMovie(("biganimal" + type) + "_mc", "biganimal" + _mcRef.getNextHighestDepth(), _mcRef.getNextHighestDepth());
speedZ = 0;
speedX = 0;
speedY = 0;
movesAway = true;
doesDamage = true;
isHit = false;
}
function reset() {
zpos = 0;
ypos = 0;
xpos = uk.kerb.utils.Random.getFromRange(-World.STREET, World.STREET);
speedX = 0;
speedY = 0;
impactX = 0;
ignore = false;
stopAnimation();
clearInterval(resetInterVal);
isHit = false;
}
function stopAnimation() {
mcRef.gotoAndStop(1);
}
function startAnimation() {
if (!isHit) {
var _local2 = uk.kerb.utils.Random.getFromRange(5, 20);
if (mcRef.flyaway) {
speedY = speedZ / 2;
}
speedX = ((xpos > 0) ? (_local2) : (-_local2));
mcRef.gotoAndStop(((speedX < 0) ? "runleft" : "runright"));
mcRef.anim_mc.gotoAndPlay(uk.kerb.utils.Random.getFromRange(1, mcRef.anim_mc._totalframes));
}
}
function hit(_cameraX) {
zpos = (-World.DEEP) + Math.round(uk.kerb.utils.Random.getFromRange(60, 75));
ypos = -10;
speedX = 0;
speedY = 0;
speedZ = 0;
mcRef.gotoAndStop("crash");
isHit = true;
ignore = true;
impactX = xpos - _cameraX;
broadcastMessage("playSoundEffect", "animal" + type);
broadcastMessage("showSlangBad", this);
resetInterVal = setInterval(this, "reset", 2000);
}
}
Symbol 748 MovieClip [__Packages.obstacle.SmallAnimal] Frame 0
class obstacle.SmallAnimal extends Object3D
{
var xpos, ypos, zpos, mcRef, speedZ, speedX, speedY, movesAway, hitBonus, doesDamage;
function SmallAnimal (_mcRef, _xpos, _ypos, _zpos) {
super();
xpos = _xpos;
ypos = _ypos;
zpos = _zpos;
var _local4 = Math.round(uk.kerb.utils.Random.getFromRange(1, 6));
mcRef = _mcRef.attachMovie(("smallanimal" + _local4) + "_mc", "smallanimal" + _mcRef.getNextHighestDepth(), _mcRef.getNextHighestDepth());
speedZ = 0;
speedX = 0;
speedY = 0;
movesAway = true;
hitBonus = true;
doesDamage = false;
}
function reset() {
zpos = 0;
ypos = 0;
xpos = uk.kerb.utils.Random.getFromRange(-World.STREET, World.STREET);
speedX = 0;
speedY = 0;
stopAnimation();
}
function stopAnimation() {
mcRef.gotoAndStop(1);
}
function startAnimation() {
var _local2 = uk.kerb.utils.Random.getFromRange(10, 40);
if (mcRef.flyaway) {
speedY = speedZ / 2;
}
speedX = ((xpos > 0) ? (_local2) : (-_local2));
mcRef.gotoAndStop(((speedX < 0) ? "runleft" : "runright"));
}
}
Symbol 749 MovieClip [__Packages.obstacle.Sign] Frame 0
class obstacle.Sign extends Object3D
{
var mcRef, xpos, ypos, zpos, speedZ, speedX, speedY, doesDamage, movesAway;
function Sign (_mcRef, _type) {
super();
mcRef = _mcRef.attachMovie(("sign" + _type) + "_mc", "sign" + _mcRef.getNextHighestDepth(), _mcRef.getNextHighestDepth());
xpos = (-World.STREET) - 30;
ypos = 0;
zpos = uk.kerb.utils.Random.getSimple(-World.DEEP);
speedZ = 0;
speedX = 0;
speedY = 0;
doesDamage = true;
movesAway = false;
}
function reset() {
zpos = 0;
}
}
Symbol 750 MovieClip [__Packages.obstacle.Rock] Frame 0
class obstacle.Rock extends Object3D
{
var mcRef, xpos, ypos, zpos, speedZ, speedY, speedX, doesDamage, movesAway;
function Rock (_mcRef) {
super();
var _local4 = Math.round(uk.kerb.utils.Random.getFromRange(1, 3));
mcRef = _mcRef.attachMovie(("rock" + _local4) + "_mc", "rock" + _mcRef.getNextHighestDepth(), _mcRef.getNextHighestDepth());
xpos = ((Math.random() > 0.5) ? ((-World.STREET) - (Math.random() * 500)) : (World.STREET + (Math.random() * 500)));
ypos = 0;
zpos = uk.kerb.utils.Random.getSimple(-World.DEEP);
speedZ = 0;
speedY = 0;
speedX = 0;
doesDamage = true;
movesAway = false;
}
function reset() {
zpos = 0;
}
function hit() {
speedX = 0;
speedY = 0;
speedZ = 0;
}
}
Symbol 751 MovieClip [__Packages.obstacle.Plant] Frame 0
class obstacle.Plant extends Object3D
{
var mcRef, xpos, ypos, zpos, speedZ, speedY, speedX, doesDamage, movesAway;
function Plant (_mcRef) {
super();
var _local4 = Math.round(uk.kerb.utils.Random.getFromRange(1, 5));
mcRef = _mcRef.attachMovie(("plant" + _local4) + "_mc", "plant" + _mcRef.getNextHighestDepth(), _mcRef.getNextHighestDepth());
xpos = ((Math.random() > 0.5) ? ((-World.STREET) - (Math.random() * 500)) : (World.STREET + (Math.random() * 500)));
ypos = 0;
zpos = uk.kerb.utils.Random.getSimple(-World.DEEP);
speedZ = 0;
speedY = 0;
speedX = 0;
doesDamage = true;
movesAway = false;
}
function reset() {
zpos = 0;
}
}
Symbol 752 MovieClip [__Packages.obstacle.Lamp] Frame 0
class obstacle.Lamp extends Object3D
{
var mcRef, xpos, ypos, zpos, speedZ, speedX, speedY, doesDamage, movesAway;
function Lamp (_mcRef, _index, _dist) {
super();
mcRef = _mcRef.attachMovie("lamp_mc", "lamp", _mcRef.getNextHighestDepth());
xpos = (((_index % 2) == 0) ? ((-World.STREET) - 30) : (World.STREET + 30));
if ((_index % 2) == 0) {
mcRef.lamp_inner_mc._xscale = -100;
}
ypos = 0;
zpos = _index * (-_dist);
speedZ = 0;
speedX = 0;
speedY = 0;
doesDamage = true;
movesAway = false;
}
function reset() {
zpos = 0;
}
}
Symbol 753 MovieClip [__Packages.obstacle.House] Frame 0
class obstacle.House extends Object3D
{
var mcRef, xpos, ypos, zpos, speedZ, speedY, speedX, doesDamage, movesAway;
function House (_mcRef) {
super();
var _local4 = uk.kerb.utils.Random.getFromRange(1, 3);
mcRef = _mcRef.attachMovie(("home" + _local4) + "_mc", "home" + _mcRef.getNextHighestDepth(), _mcRef.getNextHighestDepth());
xpos = ((Math.random() > 0.5) ? ((-World.STREET) - (Math.random() * 500)) : (World.STREET + (Math.random() * 500)));
ypos = 0;
zpos = uk.kerb.utils.Random.getSimple(-World.DEEP);
speedZ = 0;
speedY = 0;
speedX = 0;
doesDamage = true;
movesAway = false;
}
function reset() {
zpos = 0;
}
function hit() {
speedX = 0;
speedY = 0;
speedZ = 0;
}
}
Symbol 754 MovieClip [__Packages.mx.events.EventDispatcher] Frame 0
class mx.events.EventDispatcher
{
function EventDispatcher () {
}
static function _removeEventListener(queue, event, handler) {
if (queue != undefined) {
var _local4 = queue.length;
var _local1;
_local1 = 0;
while (_local1 < _local4) {
var _local2 = queue[_local1];
if (_local2 == handler) {
queue.splice(_local1, 1);
return(undefined);
}
_local1++;
}
}
}
static function initialize(object) {
if (_fEventDispatcher == undefined) {
_fEventDispatcher = new mx.events.EventDispatcher();
}
object.addEventListener = _fEventDispatcher.addEventListener;
object.removeEventListener = _fEventDispatcher.removeEventListener;
object.dispatchEvent = _fEventDispatcher.dispatchEvent;
object.dispatchQueue = _fEventDispatcher.dispatchQueue;
}
function dispatchQueue(queueObj, eventObj) {
var _local7 = "__q_" + eventObj.type;
var _local4 = queueObj[_local7];
if (_local4 != undefined) {
var _local5;
for (_local5 in _local4) {
var _local1 = _local4[_local5];
var _local3 = typeof(_local1);
if ((_local3 == "object") || (_local3 == "movieclip")) {
if (_local1.handleEvent != undefined) {
_local1.handleEvent(eventObj);
}
if (_local1[eventObj.type] != undefined) {
if (exceptions[eventObj.type] == undefined) {
_local1[eventObj.type](eventObj);
}
}
} else {
_local1.apply(queueObj, [eventObj]);
}
}
}
}
function dispatchEvent(eventObj) {
if (eventObj.target == undefined) {
eventObj.target = this;
}
this[eventObj.type + "Handler"](eventObj);
dispatchQueue(this, eventObj);
}
function addEventListener(event, handler) {
var _local3 = "__q_" + event;
if (this[_local3] == undefined) {
this[_local3] = new Array();
}
_global.ASSetPropFlags(this, _local3, 1);
_removeEventListener(this[_local3], event, handler);
this[_local3].push(handler);
}
function removeEventListener(event, handler) {
var _local2 = "__q_" + event;
_removeEventListener(this[_local2], event, handler);
}
static var _fEventDispatcher = undefined;
static var exceptions = {move:1, draw:1, load:1};
}
Symbol 755 MovieClip [__Packages.mx.transitions.TransitionManager] Frame 0
class mx.transitions.TransitionManager
{
var _transitions, removeEventListener, _content, addEventListener, _contentAppearance, _innerBounds, _outerBounds, _width, _height, _triggerEvent, dispatchEvent;
function TransitionManager (content) {
this.content = (content);
_transitions = {};
}
function set content(c) {
removeEventListener("allTransitionsInDone", _content);
removeEventListener("allTransitionsOutDone", _content);
_content = c;
saveContentAppearance();
addEventListener("allTransitionsInDone", _content);
addEventListener("allTransitionsOutDone", _content);
//return(content);
}
function get content() {
return(_content);
}
function get transitionsList() {
return(_transitions);
}
function get numTransitions() {
var _local2 = 0;
for (var _local3 in _transitions) {
_local2++;
}
return(_local2);
}
function get numInTransitions() {
var _local3 = 0;
var _local2 = _transitions;
for (var _local4 in _local2) {
if (!_local2[_local4].direction) {
_local3++;
}
}
return(_local3);
}
function get numOutTransitions() {
var _local3 = 0;
var _local2 = _transitions;
for (var _local4 in _local2) {
if (_local2[_local4].direction) {
_local3++;
}
}
return(_local3);
}
function get contentAppearance() {
return(_contentAppearance);
}
static function start(content, transParams) {
if (content.__transitionManager == undefined) {
content.__transitionManager = new mx.transitions.TransitionManager(content);
}
if (transParams.direction == 1) {
content.__transitionManager._triggerEvent = "hide";
} else {
content.__transitionManager._triggerEvent = "reveal";
}
return(content.__transitionManager.startTransition(transParams));
}
function startTransition(transParams) {
removeTransition(findTransition(transParams));
var _local3 = transParams.type;
var _local2 = new _local3[undefined](_content, transParams, this);
addTransition(_local2);
_local2.start();
return(_local2);
}
function addTransition(trans) {
trans.ID = ++IDCount;
_transitions[trans.ID] = trans;
return(trans);
}
function removeTransition(trans) {
if (_transitions[trans.ID] == undefined) {
return(false);
}
trans.cleanUp();
return(delete _transitions[trans.ID]);
}
function findTransition(transParams) {
var _local2;
for (var _local4 in _transitions) {
_local2 = _transitions[_local4];
if (_local2.type == transParams.type) {
return(_local2);
}
}
return(undefined);
}
function removeAllTransitions() {
for (var _local2 in _transitions) {
_transitions[_local2].cleanUp();
removeTransition(_transitions[_local2]);
}
}
function saveContentAppearance() {
var _local2 = _content;
if (_contentAppearance == undefined) {
var _local3 = (_contentAppearance = {});
for (var _local4 in _visualPropList) {
_local3[_local4] = _local2[_local4];
}
_local3.colorTransform = new Color(_local2).getTransform();
}
_innerBounds = _local2.getBounds(targetPath(_local2));
_outerBounds = _local2.getBounds(targetPath(_local2._parent));
_width = _local2._width;
_height = _local2._height;
}
function restoreContentAppearance() {
var _local2 = _content;
var _local3 = _contentAppearance;
for (var _local4 in _visualPropList) {
_local2[_local4] = _local3[_local4];
}
new Color(_local2).setTransform(_local3.colorTransform);
}
function transitionInDone(e) {
removeTransition(e.target);
if (numInTransitions == 0) {
var _local2;
_local2 = _content._visible;
if ((_triggerEvent == "hide") || (_triggerEvent == "hideChild")) {
_content._visible = false;
}
if (_local2) {
dispatchEvent({type:"allTransitionsInDone", target:this});
}
}
}
function transitionOutDone(e) {
removeTransition(e.target);
if (numOutTransitions == 0) {
restoreContentAppearance();
var _local2;
_local2 = _content._visible;
if (_local2 && ((_triggerEvent == "hide") || (_triggerEvent == "hideChild"))) {
_content._visible = false;
}
updateAfterEvent();
if (_local2) {
dispatchEvent({type:"allTransitionsOutDone", target:this});
}
}
}
function toString() {
return("[TransitionManager]");
}
static var IDCount = 0;
var type = mx.transitions.TransitionManager;
var className = "TransitionManager";
var _visualPropList = {_x:null, _y:null, _xscale:null, _yscale:null, _alpha:null, _rotation:null};
static var __mixinFED = mx.events.EventDispatcher.initialize(mx.transitions.TransitionManager.prototype);
}
Symbol 756 MovieClip [__Packages.mx.transitions.Transition] Frame 0
class mx.transitions.Transition
{
var _manager, removeEventListener, addEventListener, _content, _twn, _easing, _progress, dispatchEvent, _innerBounds, _outerBounds, _width, _height;
function Transition (content, transParams, manager) {
if (!arguments.length) {
return;
}
init(content, transParams, manager);
}
function set manager(mgr) {
if (_manager != undefined) {
removeEventListener("transitionInDone", _manager);
removeEventListener("transitionOutDone", _manager);
removeEventListener("transitionProgress", _manager);
}
_manager = mgr;
addEventListener("transitionInDone", _manager);
addEventListener("transitionOutDone", _manager);
addEventListener("transitionProgress", _manager);
//return(manager);
}
function get manager() {
return(_manager);
}
function set content(c) {
if (typeof(c) == "movieclip") {
_content = c;
_twn.obj = c;
}
//return(content);
}
function get content() {
return(_content);
}
function set direction(direction) {
_direction = (direction ? 1 : 0);
//return(this.direction);
}
function get direction() {
return(_direction);
}
function set duration(d) {
if (d) {
_duration = d;
_twn.duration = d;
}
//return(duration);
}
function get duration() {
return(_duration);
}
function set easing(e) {
if (typeof(e) == "string") {
e = eval (e);
} else if (e == undefined) {
e = _noEase;
}
_easing = e;
_twn.easing = e;
//return(easing);
}
function get easing() {
return(_easing);
}
function set progress(p) {
if (_progress == p) {
return;
}
_progress = p;
if (_direction) {
_render(1 - p);
} else {
_render(p);
}
dispatchEvent({type:"transitionProgress", target:this, progress:p});
//return(progress);
}
function get progress() {
return(_progress);
}
function init(content, transParams, manager) {
this.content = (content);
direction = (transParams.direction);
duration = (transParams.duration);
easing = (transParams.easing);
this.manager = (manager);
_innerBounds = this.manager._innerBounds;
_outerBounds = this.manager._outerBounds;
_width = this.manager._width;
_height = this.manager._height;
_resetTween();
}
function toString() {
return(("[Transition " + className) + "]");
}
function start() {
content._visible = true;
_twn.start();
}
function stop() {
_twn.fforward();
_twn.stop();
}
function cleanUp() {
removeEventListener("transitionInDone", _manager);
removeEventListener("transitionOutDone", _manager);
removeEventListener("transitionProgress", _manager);
stop();
}
function getNextHighestDepthMC(mc) {
var _local4 = mc.getNextHighestDepth();
if (_local4 != undefined) {
return(_local4);
}
_local4 = -1;
var _local3;
var _local1;
for (var _local5 in mc) {
_local1 = mc[_local5];
if ((typeof(_local1) == "movieclip") && (_local1._parent == mc)) {
_local3 = _local1.getDepth();
if (_local3 > _local4) {
_local4 = _local3;
}
}
}
return(_local4 + 1);
}
function drawBox(mc, x, y, w, h) {
mc.moveTo(x, y);
mc.lineTo(x + w, y);
mc.lineTo(x + w, y + h);
mc.lineTo(x, y + h);
mc.lineTo(x, y);
}
function drawCircle(mc, x, y, r) {
mc.moveTo(x + r, y);
mc.curveTo(r + x, (0.414213562373095 * r) + y, (0.707106781186547 * r) + x, (0.707106781186547 * r) + y);
mc.curveTo((0.414213562373095 * r) + x, r + y, x, r + y);
mc.curveTo((-0.414213562373095 * r) + x, r + y, (-0.707106781186547 * r) + x, (0.707106781186547 * r) + y);
mc.curveTo((-r) + x, (0.414213562373095 * r) + y, (-r) + x, y);
mc.curveTo((-r) + x, (-0.414213562373095 * r) + y, (-0.707106781186547 * r) + x, (-0.707106781186547 * r) + y);
mc.curveTo((-0.414213562373095 * r) + x, (-r) + y, x, (-r) + y);
mc.curveTo((0.414213562373095 * r) + x, (-r) + y, (0.707106781186547 * r) + x, (-0.707106781186547 * r) + y);
mc.curveTo(r + x, (-0.414213562373095 * r) + y, r + x, y);
}
function _render(p) {
}
function _resetTween() {
_twn.stop();
_twn.removeListener(this);
_twn = new mx.transitions.Tween(this, null, easing, 0, 1, duration, true);
_twn.stop();
_twn.prop = "progress";
_twn.addListener(this);
}
function _noEase(t, b, c, d) {
return(((c * t) / d) + b);
}
function onMotionFinished(src) {
if (direction) {
dispatchEvent({type:"transitionOutDone", target:this});
} else {
dispatchEvent({type:"transitionInDone", target:this});
}
}
static var IN = 0;
static var OUT = 1;
var type = mx.transitions.Transition;
var className = "Transition";
var _direction = 0;
var _duration = 2;
static var __mixinFED = mx.events.EventDispatcher.initialize(mx.transitions.Transition.prototype);
}
Symbol 757 MovieClip [__Packages.mx.transitions.Iris] Frame 0
class mx.transitions.Iris extends mx.transitions.Transition
{
var _maxDimension, _width, _height, _minDimension, _cornerMode, _content, _mask, getNextHighestDepthMC, __get__direction, _innerBounds, drawCircle, drawBox;
function Iris (content, transParams, manager) {
super();
init(content, transParams, manager);
}
function init(content, transParams, manager) {
super.init(content, transParams, manager);
if (transParams.startPoint) {
_startPoint = transParams.startPoint;
}
if (transParams.shape != undefined) {
_shape = transParams.shape;
}
_maxDimension = Math.max(_width, _height);
_minDimension = Math.min(_width, _height);
if (_startPoint % 2) {
_cornerMode = true;
}
if (_shape == "SQUARE") {
if (_cornerMode) {
_render = _renderSquareCorner;
} else {
_render = _renderSquareEdge;
}
} else if (_shape == "CIRCLE") {
_render = _renderCircle;
}
_initMask();
}
function start() {
_content.setMask(_mask);
super.start();
}
function cleanUp() {
_mask.removeMovieClip();
super.cleanUp();
}
function _initMask() {
var _local4 = _content;
var _local5 = getNextHighestDepthMC(_local4);
var _local2 = (_mask = _local4.createEmptyMovieClip("__mask_Iris_" + __get__direction(), _local5));
_local2._visible = false;
var _local3 = _innerBounds;
switch (_startPoint) {
case 1 :
_local2._x = _local3.xMin;
_local2._y = _local3.yMin;
break;
case 4 :
_local2._x = _local3.xMin;
_local2._y = (_local3.yMin + _local3.yMax) * 0.5;
break;
case 3 :
_local2._rotation = 90;
_local2._x = _local3.xMax;
_local2._y = _local3.yMin;
break;
case 2 :
_local2._rotation = 90;
_local2._x = (_local3.xMin + _local3.xMax) * 0.5;
_local2._y = _local3.yMin;
break;
case 9 :
_local2._rotation = 180;
_local2._x = _local3.xMax;
_local2._y = _local3.yMax;
break;
case 6 :
_local2._rotation = 180;
_local2._x = _local3.xMax;
_local2._y = (_local3.yMin + _local3.yMax) * 0.5;
break;
case 7 :
_local2._rotation = -90;
_local2._x = _local3.xMin;
_local2._y = _local3.yMax;
break;
case 8 :
_local2._rotation = -90;
_local2._x = (_local3.xMin + _local3.xMax) * 0.5;
_local2._y = _local3.yMax;
break;
case 5 :
_local2._x = (_local3.xMin + _local3.xMax) * 0.5;
_local2._y = (_local3.yMin + _local3.yMax) * 0.5;
break;
}
}
function _render(p) {
}
function _renderCircle(p) {
var _local2 = _mask;
_local2.clear();
_local2.beginFill(16711680);
if (_startPoint == 5) {
var _local4 = 0.5 * Math.sqrt((_width * _width) + (_height * _height));
drawCircle(_local2, 0, 0, p * _local4);
} else if (_cornerMode) {
var _local4 = Math.sqrt((_width * _width) + (_height * _height));
_drawQuarterCircle(_local2, p * _local4);
} else {
if ((_startPoint == 4) || (_startPoint == 6)) {
var _local4 = Math.sqrt((_width * _width) + ((0.25 * _height) * _height));
} else if ((_startPoint == 2) || (_startPoint == 8)) {
var _local4 = Math.sqrt(((0.25 * _width) * _width) + (_height * _height));
}
_drawHalfCircle(_local2, p * _local4);
}
_local2.endFill();
}
function _drawQuarterCircle(mc, r) {
var _local3 = 0;
var _local2 = 0;
mc.lineTo(r, 0);
mc.curveTo(r + _local3, (0.414213562373095 * r) + _local2, (0.707106781186547 * r) + _local3, (0.707106781186547 * r) + _local2);
mc.curveTo((0.414213562373095 * r) + _local3, r + _local2, _local3, r + _local2);
}
function _drawHalfCircle(mc, r) {
var _local3 = 0;
var _local2 = 0;
mc.lineTo(0, -r);
mc.curveTo((0.414213562373095 * r) + _local3, (-r) + _local2, (0.707106781186547 * r) + _local3, (-0.707106781186547 * r) + _local2);
mc.curveTo(r + _local3, (-0.414213562373095 * r) + _local2, r + _local3, _local2);
mc.curveTo(r + _local3, (0.414213562373095 * r) + _local2, (0.707106781186547 * r) + _local3, (0.707106781186547 * r) + _local2);
mc.curveTo((0.414213562373095 * r) + _local3, r + _local2, _local3, r + _local2);
mc.lineTo(0, 0);
}
function _renderSquareEdge(p) {
var _local2 = _mask;
_local2.clear();
_local2.beginFill(16711680);
var _local5 = _startPoint;
var _local6 = p * _width;
var _local4 = p * _height;
var _local3 = p * _maxDimension;
if ((_local5 == 4) || (_local5 == 6)) {
drawBox(_local2, 0, -0.5 * _local4, _local6, _local4);
} else if (_height < _width) {
drawBox(_local2, 0, -0.5 * _local3, _local4, _local6);
} else {
drawBox(_local2, 0, -0.5 * _local3, _local3, _local3);
}
_local2.endFill();
}
function _renderSquareCorner(p) {
var _local2 = _mask;
_local2.clear();
_local2.beginFill(16711680);
var _local5 = _startPoint;
var _local4 = p * _width;
var _local3 = p * _height;
if (_local5 == 5) {
drawBox(_local2, -0.5 * _local4, -0.5 * _local3, _local4, _local3);
} else if ((_local5 == 3) || (_local5 == 7)) {
drawBox(_local2, 0, 0, _local3, _local4);
} else {
drawBox(_local2, 0, 0, _local4, _local3);
}
_local2.endFill();
}
static var SQUARE = "SQUARE";
static var CIRCLE = "CIRCLE";
var type = mx.transitions.Iris;
var className = "Iris";
var _startPoint = 5;
var _shape = "SQUARE";
}
Symbol 758 MovieClip [__Packages.uk.kerb.utils.ui.Scrollbar] Frame 0
class uk.kerb.utils.ui.Scrollbar
{
var isVertical, mc, up_btn, down_btn, mouseListener, left_btn, right_btn, tray_mc, handle_mc, orignalHandleSize, content_mc, mask_mc, visibleRatio, handleMin, handleMax, handleDist, contentDist, currPosition, actionStartTime, mouseOffset, jumpDirection, contentPosition;
function Scrollbar (scrollbar_mc, scrollpane_mc, direction) {
isVertical = direction.toLowerCase().indexOf("v") != -1;
if (isVertical && (scrollbar_mc.up_btn == undefined)) {
handleError(0, scrollbar_mc);
return;
}
if (isVertical && (scrollbar_mc.down_btn == undefined)) {
handleError(1, scrollbar_mc);
return;
}
if ((!isVertical) && (scrollbar_mc.left_btn == undefined)) {
handleError(2, scrollbar_mc);
return;
}
if ((!isVertical) && (scrollbar_mc.right_btn == undefined)) {
handleError(3, scrollbar_mc);
return;
}
if (scrollbar_mc.tray_mc == undefined) {
handleError(4, scrollbar_mc);
return;
}
if (scrollbar_mc.handle_mc == undefined) {
handleError(5, scrollbar_mc);
return;
}
mc = scrollbar_mc;
if (scrollpane_mc.mask_mc == undefined) {
handleError(6, scrollpane_mc);
return;
}
if (scrollpane_mc.content_mc == undefined) {
handleError(7, scrollpane_mc);
return;
}
if (isVertical) {
up_btn = mc.up_btn;
initButton(up_btn, -SCROLL_SPEED);
down_btn = mc.down_btn;
initButton(down_btn, SCROLL_SPEED);
mouseListener = new Object();
mouseListener.onMouseWheel = uk.kerb.utils.EventDelegate.create(this, handleMouseWheel);
Mouse.addListener(mouseListener);
} else {
left_btn = mc.left_btn;
initButton(left_btn, -SCROLL_SPEED);
right_btn = mc.right_btn;
initButton(right_btn, SCROLL_SPEED);
}
tray_mc = mc.tray_mc;
tray_mc.onPress = uk.kerb.utils.EventDelegate.create(this, initJump, true);
tray_mc.onDragOver = uk.kerb.utils.EventDelegate.create(this, initJump, false);
tray_mc.onDragOut = (tray_mc.onRelease = uk.kerb.utils.EventDelegate.create(this, cancelInteraction));
tray_mc.useHandCursor = false;
handle_mc = mc.handle_mc;
handle_mc.onPress = uk.kerb.utils.EventDelegate.create(this, initDrag);
handle_mc.onRelease = (handle_mc.onReleaseOutside = uk.kerb.utils.EventDelegate.create(this, cancelInteraction));
handle_mc.useHandCursor = false;
orignalHandleSize = handle_mc._height;
content_mc = scrollpane_mc.content_mc;
mask_mc = scrollpane_mc.mask_mc;
update();
}
function update() {
var _local3;
var _local5;
var _local4;
var _local2;
if (isVertical) {
_local3 = tray_mc._height;
_local5 = mask_mc._height;
_local4 = content_mc._height;
visibleRatio = _local5 / _local4;
if (scaleHandle) {
_local2 = visibleRatio * _local3;
_local2 = bounds(_local2, MIN_HANDLE_SIZE, _local3);
handle_mc._height = _local2;
} else {
_local2 = orignalHandleSize;
handle_mc._height = _local2;
}
handleMin = tray_mc._y;
handleMax = (handleMin + _local3) - _local2;
handleDist = _local3 - _local2;
contentDist = _local5 - _local4;
currPosition = (content_mc._y - mask_mc._y) / contentDist;
currPosition = bounds(currPosition, 0, 1);
handle_mc._y = tray_mc._y + (currPosition * handleDist);
content_mc._y = mask_mc._y + (currPosition * contentDist);
if (AUTOHIDE) {
mc._visible = _local4 > _local5;
}
} else {
_local3 = tray_mc._width;
_local5 = mask_mc._width;
_local4 = content_mc._width;
visibleRatio = _local5 / _local4;
if (scaleHandle) {
_local2 = visibleRatio * _local3;
_local2 = bounds(_local2, MIN_HANDLE_SIZE, _local3);
handle_mc._width = _local2;
} else {
_local2 = orignalHandleSize;
handle_mc._height = _local2;
}
handleMin = tray_mc._x;
handleMax = (handleMin + _local3) - _local2;
handleDist = _local3 - _local2;
contentDist = _local5 - _local4;
currPosition = (content_mc._x - mask_mc._x) / contentDist;
currPosition = bounds(currPosition, 0, 1);
handle_mc._x = tray_mc._x + (currPosition * handleDist);
content_mc._x = mask_mc._x + (currPosition * contentDist);
if (AUTOHIDE) {
mc._visible = _local4 > _local5;
}
}
content_mc.setMask(mask_mc);
}
function reset() {
delete mc.onEnterFrame;
if (isVertical) {
content_mc._y = mask_mc._y;
handle_mc._y = handleMin;
} else {
content_mc._x = mask_mc._x;
handle_mc._x = handleMin;
}
}
function initButton(btn, scrollAmount) {
btn.onPress = uk.kerb.utils.EventDelegate.create(this, initMove, scrollAmount);
btn.onDragOver = uk.kerb.utils.EventDelegate.create(this, initMove, scrollAmount);
btn.onDragOut = uk.kerb.utils.EventDelegate.create(this, cancelInteraction);
btn.onRelease = uk.kerb.utils.EventDelegate.create(this, cancelInteraction);
btn.useHandCursor = false;
}
function handleMouseWheel(dir) {
if (mask_mc.hitTest(_root._xmouse, _root._ymouse)) {
move(dir * (-SCROLL_SPEED), true);
cancelInteraction();
}
}
function initMove(stepSize) {
actionStartTime = getTimer();
move(stepSize, true);
mc.onEnterFrame = uk.kerb.utils.EventDelegate.create(this, move, stepSize);
}
function move(stepSize, ignoreActionStartTime) {
var _local2;
var _local3;
_local3 = getTimer() - actionStartTime;
if (ignoreActionStartTime || (_local3 > ACTION_PAUSE)) {
_local2 = (isVertical ? (handle_mc._y) : (handle_mc._x));
_local2 = _local2 + stepSize;
_local2 = bounds(_local2, handleMin, handleMax);
updateGraphics(_local2);
}
}
function initDrag() {
if (isVertical) {
mouseOffset = mc._ymouse - handle_mc._y;
} else {
mouseOffset = mc._xmouse - handle_mc._x;
}
mc.onEnterFrame = uk.kerb.utils.EventDelegate.create(this, drag);
}
function drag() {
var _local2;
_local2 = (isVertical ? (mc._ymouse) : (mc._xmouse));
_local2 = _local2 - mouseOffset;
_local2 = bounds(_local2, handleMin, handleMax);
updateGraphics(_local2);
}
function initJump(setJumpDirection) {
if (setJumpDirection) {
if (isVertical) {
jumpDirection = mc._ymouse < handle_mc._y;
} else {
jumpDirection = mc._xmouse < handle_mc._x;
}
}
actionStartTime = getTimer();
jump(true);
mc.onEnterFrame = uk.kerb.utils.EventDelegate.create(this, jump);
}
function jump(ignoreActionStartTime) {
var _local2;
var _local3;
_local3 = getTimer() - actionStartTime;
if (ignoreActionStartTime || (_local3 > ACTION_PAUSE)) {
if (jumpDirection) {
if (isVertical && (mc._ymouse > handle_mc._y)) {
return(undefined);
}
if ((!isVertical) && (mc._xmouse > handle_mc._x)) {
return(undefined);
}
_local2 = (handleDist * (currPosition - visibleRatio)) + handleMin;
_local2 = bounds(_local2, handleMin, handleMax);
updateGraphics(_local2);
} else {
if (isVertical && (mc._ymouse < handle_mc._y)) {
return(undefined);
}
if ((!isVertical) && (mc._xmouse < handle_mc._x)) {
return(undefined);
}
_local2 = (handleDist * (currPosition + visibleRatio)) + handleMin;
_local2 = bounds(_local2, handleMin, handleMax);
updateGraphics(_local2);
}
}
}
function updateGraphics(newPosition) {
currPosition = (newPosition - handleMin) / handleDist;
if (isVertical) {
handle_mc._y = newPosition;
if (USE_EASING) {
contentPosition = mask_mc._y + (currPosition * contentDist);
content_mc._y = content_mc._y + (EASING_RATE * (contentPosition - content_mc._y));
} else {
content_mc._y = mask_mc._y + (currPosition * contentDist);
}
} else {
handle_mc._x = newPosition;
if (USE_EASING) {
contentPosition = mask_mc._x + (currPosition * contentDist);
content_mc._x = content_mc._x + (EASING_RATE * (contentPosition - content_mc._x));
} else {
content_mc._x = mask_mc._x + (currPosition * contentDist);
}
}
}
function cancelInteraction() {
if (USE_EASING) {
mc.onEnterFrame = uk.kerb.utils.EventDelegate.create(this, finishEasing);
} else {
delete mc.onEnterFrame;
}
}
function finishEasing() {
if (isVertical) {
content_mc._y = content_mc._y + (EASING_RATE * (contentPosition - content_mc._y));
if (Math.abs(contentPosition - content_mc._y) < 0.5) {
content_mc._y = contentPosition;
delete mc.onEnterFrame;
}
} else {
content_mc._x = content_mc._x + (EASING_RATE * (contentPosition - content_mc._x));
if (Math.abs(contentPosition - content_mc._x) < 0.5) {
content_mc._x = contentPosition;
delete mc.onEnterFrame;
}
}
}
function bounds(num, min, max) {
if (min <= max) {
num = Math.max(num, min);
num = Math.min(num, max);
} else {
num = Math.min(num, min);
num = Math.max(num, max);
}
return(num);
}
function setScaleHandle(_bool) {
scaleHandle = _bool;
}
function handleError(errorNum, args) {
var _local2;
var _local3;
var _local1;
_local3 = ((errorNum < 6) ? "scrollbar" : "scrollpane");
_local1 = ["up_btn", "down_btn", "left_btn", "right_btn", "tray_mc", "handle_mc", "mask_mc", "content_mc"];
_local2 = ((((("\n\n-- ERROR ----------\nThe " + _local3) + " [") + args) + "] must contain a movieclip named ") + _local1[errorNum]) + ".\n------------------\n\n";
}
static var AUTOHIDE = true;
static var USE_EASING = true;
static var EASING_RATE = 0.1;
static var SCROLL_SPEED = 5;
static var ACTION_PAUSE = 300;
static var MIN_HANDLE_SIZE = 17;
var scaleHandle = true;
static var HORIZONTAL = "horizontal";
static var VERTICAL = "vertical";
}
Symbol 305 MovieClip Frame 1
stop();
Symbol 307 MovieClip Frame 1
stop();
Symbol 320 MovieClip Frame 1
stop();
Symbol 320 MovieClip Frame 30
stop();
Symbol 320 MovieClip Frame 60
_parent._visible = false;
Symbol 349 MovieClip Frame 1
stop();
Symbol 356 MovieClip Frame 1
stop();
Symbol 361 MovieClip Frame 1
stop();
Symbol 361 MovieClip Frame 3
stop();
Symbol 361 MovieClip Frame 5
stop();
Symbol 361 MovieClip Frame 7
stop();
Symbol 361 MovieClip Frame 9
stop();
Symbol 371 MovieClip Frame 1
stop();
Symbol 373 MovieClip Frame 1
stop();
Symbol 391 MovieClip Frame 1
stop();
Symbol 391 MovieClip Frame 120
gotoAndPlay (2);
Symbol 401 MovieClip Frame 1
stop();
Symbol 406 MovieClip Frame 1
stop();
Symbol 406 MovieClip Frame 30
this._parent._parent.radio_mc.radio_anim_mc.play();
Symbol 409 MovieClip Frame 1
stop();
Symbol 409 MovieClip Frame 56
stop();
Symbol 429 MovieClip Frame 1
stop();
Symbol 460 MovieClip Frame 1
stop();
Symbol 469 MovieClip Frame 1
stop();
Symbol 485 MovieClip Frame 1
stop();
Symbol 488 Button
on (press) {
getURL ("http://66.kerb.memecounter.com/redir.php?urlId=230", "_blank");
}
Symbol 489 Button
on (press) {
getURL ("http://www.nidp.com", "_blank");
}
Symbol 490 MovieClip Frame 1
stop();
Symbol 510 MovieClip Frame 1
stop();
Symbol 629 MovieClip Frame 1
stop();
Symbol 652 Button
on (press) {
getURL ("http://66.kerb.memecounter.com/redir.php?urlId=231", "_blank");
}
Symbol 665 MovieClip Frame 1
stop();
Symbol 688 MovieClip Frame 1
stop();
Symbol 689 Button
on (press) {
getURL ("http://66.kerb.memecounter.com/redir.php?urlId=231", "_blank");
}
Symbol 694 Button
on (press) {
getURL ("http://www.timesonline.co.uk/section/0,,426,00.html", "_blank");
}
Symbol 698 Button
on (press) {
getURL ("http://www.timesonline.co.uk/section/0,,23070,00.html", "_blank");
}
Symbol 699 MovieClip Frame 1
stop();
Symbol 726 Button
on (press) {
getURL ("http://66.kerb.memecounter.com/redir.php?urlId=230", "_blank");
}
Symbol 728 Button
on (press) {
getURL ("http://www.nidp.com", "_blank");
}