Frame 6
stop();
Frame 35
function makeCharacterFall() {
sliding = false;
Key.removeListener(keyListener);
codemovie_mc.onEnterFrame = function () {
};
bg_mc.onEnterFrame = function () {
};
icemask_mc.onEnterFrame = function () {
};
skyline_mc.onEnterFrame = function () {
};
characterset_mc.gotoAndStop("fallen");
instructions_mc.gotoAndStop("off");
characterset_mc.onEnterFrame = function () {
trace("characterset animating");
this._x = this._x + (20 * runspeed);
runspeed = runspeed - 0.025;
if (runspeed <= 0) {
runspeed = 0;
this.oldtime = getTimer();
this.onEnterFrame = function () {
if ((getTimer() - this.oldtime) >= 2000) {
this.onEnterFrame = function () {
};
_root.gotoAndStop("intro");
}
};
_root.gotoAndStop("gameover");
}
};
}
function runWhenLanded() {
if (currenttotaldistance < 75) {
makeCharacterFall();
return(undefined);
}
tiltposition = 0;
timedelay = 2000;
tiltspeed = 0;
tiltaccel = 2 * (runspeed / 10);
sliding = true;
keyListener = new Object();
keyListener.onKeyUp = function () {
if (Key.getCode() == 37) {
tiltposition = tiltposition - 15;
} else if (Key.getCode() == 39) {
tiltposition = tiltposition + 15;
}
};
Key.addListener(keyListener);
characterset_mc.character_mc.slidingcharacter_mc.leftarm_mc.onEnterFrame = function () {
this._rotation = 90 + tiltposition;
};
characterset_mc.character_mc.slidingcharacter_mc.rightarm_mc.onEnterFrame = function () {
this._rotation = -90 + tiltposition;
};
codemovie_mc.oldtime = getTimer() - 9999;
codemovie_mc.onEnterFrame = function () {
currenttotaldistance = currenttotaldistance + runspeed;
if ((getTimer() - this.oldtime) >= timedelay) {
this.oldtime = getTimer();
tiltspeed = 0;
if (random(2) == 0) {
tiltaccel = tiltaccel * -1;
} else {
tiltaccel = tiltaccel * 1;
}
}
tiltposition = tiltposition + tiltspeed;
tiltspeed = tiltspeed + tiltaccel;
if ((tiltposition < -90) || (tiltposition > 90)) {
makeCharacterFall();
}
if (sliding) {
currentslidedistance = currentslidedistance + runspeed;
currentslidedistance_display = Math.round(currentslidedistance);
}
runspeed = runspeed - 0.001;
if (runspeed <= 0) {
runspeed = 0;
Key.removeListener(keyListener);
this.oldtime = getTimer();
this.onEnterFrame = function () {
trace("ENTERFRAME WORKS");
if ((getTimer() - this.oldtime) >= 2000) {
_root.gotoAndStop("intro");
this.onEnterFrame = function () {
};
}
};
trace("hello I'm at the end of code movie");
instructions_mc.gotoAndStop("off");
_root.gotoAndStop("gameover");
}
};
instructions_mc.gotoAndStop("sliding");
}
runspeed = 0;
inair = false;
sliding = false;
landed = false;
if (Math.round(currentslidedistance) > highscore) {
highscore = Math.round(currentslidedistance);
}
currenttotaldistance = 0;
currentslidedistance = 0;
currentslidedistance_display = "0";
bg_mc._x = 0;
characterset_mc._x = 61;
characterset_mc.gotoAndStop(1);
instructions_mc.gotoAndStop("running");
icemask_mc._x = 0;
skyline_mc._x = 0;
var keyListener = new Object();
keyListener.onKeyUp = function () {
if ((Key.getCode() == 37) && (lastcursorkey != 37)) {
lastcursorkey = 37;
runspeed = runspeed + 0.025;
if (runspeed > 1) {
runspeed = 1;
}
} else if ((Key.getCode() == 39) && (lastcursorkey != 39)) {
lastcursorkey = 39;
runspeed = runspeed + 0.025;
if (runspeed > 1) {
runspeed = 1;
}
} else if (Key.getCode() == 38) {
codemovie_mc.onEnterFrame = function () {
currenttotaldistance = currenttotaldistance + runspeed;
};
inair = true;
characterset_mc.gotoAndStop("sliding");
instructions_mc.gotoAndStop("off");
Key.removeListener(keyListener);
}
};
Key.addListener(keyListener);
codemovie_mc.onEnterFrame = function () {
runspeed = runspeed - 0.005;
if (runspeed < 0) {
runspeed = 0;
characterset_mc.gotoAndStop(1);
}
currenttotaldistance = currenttotaldistance + runspeed;
if (currenttotaldistance > 75) {
makeCharacterFall();
}
};
bg_mc.onEnterFrame = function () {
this._x = this._x - (20 * runspeed);
if (this._x < -550) {
this._x = (this._x = this._x + 550);
}
};
icemask_mc.onEnterFrame = function () {
if (currenttotaldistance >= 50) {
this._x = this._x - (20 * runspeed);
if (this._x < -600) {
this.onEnterFrame = function () {
};
}
}
};
skyline_mc.onEnterFrame = function () {
this._x = this._x - (5 * runspeed);
if (this._x < -762) {
this._x = (this._x = this._x + 762);
}
};
instructions_jump_mc.onEnterFrame = function () {
this._x = icemask_mc._x + 570;
};
stop();
Instance of Symbol 72 MovieClip "s_slide_mc" in Frame 35
onClipEvent (load) {
s = new Sound(this);
s.attachSound("slide");
s.setVolume(0);
s.stop;
s.start(0, 999);
}
onClipEvent (enterFrame) {
if (_root.sliding) {
s.setVolume(_root.runspeed * 100);
} else if (s.getVolume() != 0) {
s.setVolume(0);
}
}
Frame 36
trace("been to game over frame");
Symbol 7 MovieClip Frame 1
var bitsloaded;
var total;
var percent;
_visible = false;
this.onEnterFrame = function () {
bitsloaded = _parent.getBytesLoaded();
total = _parent.getBytesTotal();
if (bitsloaded == total) {
this._parent.gotoAndPlay("intro");
} else {
_visible = true;
percent = bitsloaded / total;
fill_mc._xscale = percent * 100;
if (percent == 1) {
this.onEnterFrame = function () {
this._alpha = this._alpha + ((-_alpha) / 5);
if (this._alpha < 2) {
this.onEnterFrame = function () {
};
this._visible = false;
this._parent.gotoAndPlay("intro");
}
};
}
}
};
Symbol 22 Button
on (release) {
gotoAndStop ("off");
}
Symbol 26 MovieClip Frame 1
stop();
Symbol 46 MovieClip Frame 2
if (_root.runspeed > 0) {
_parent.nextFrame();
}
Symbol 55 MovieClip Frame 33
if (_root.runspeed >= 0.25) {
_parent.nextFrame();
} else if (_root.runspeed == 0) {
_parent.prevFrame();
}
Symbol 56 MovieClip Frame 21
if (_root.runspeed > 0.5) {
_parent.nextFrame();
} else if (_root.runspeed < 0.25) {
_parent.prevFrame();
}
Symbol 57 MovieClip Frame 13
if (_root.runspeed >= 0.75) {
_parent.nextFrame();
} else if (_root.runspeed < 0.5) {
_parent.prevFrame();
}
Symbol 58 MovieClip Frame 9
if (_root.runspeed < 0.75) {
_parent.prevFrame();
}
Instance of Symbol 51 MovieClip in Symbol 63 MovieClip Frame 1
onClipEvent (enterFrame) {
this._rotation = _parent.leftarm_mc._rotation;
}
Instance of Symbol 51 MovieClip in Symbol 63 MovieClip Frame 1
onClipEvent (enterFrame) {
this._rotation = _parent.rightarm_mc._rotation;
}
Symbol 64 MovieClip Frame 19
_root.runWhenLanded();
stop();
Symbol 71 MovieClip Frame 1
stop();
Symbol 77 MovieClip Frame 1
stop();
Symbol 78 MovieClip Frame 1
stop();
Instance of Symbol 77 MovieClip in Symbol 78 MovieClip Frame 2
onClipEvent (enterFrame) {
if (_root.tiltposition > 0) {
this.gotoAndStop("left");
} else if (_root.tiltposition < 0) {
this.gotoAndStop("right");
} else {
this.gotoAndStop("default");
}
}