Frame 1
function bounceButtons(btn) {
var _local1 = new mx.transitions.TweenExtended(btn, ["_xscale", "_yscale"], mx.transitions.easing.Elastic.easeOut, [200, 200], [100, 100], 1, true);
}
function startBGLoop() {
if (_global.soundOff == false) {
bg_snd.stop();
bg_snd.attachSound("bgloop");
bg_snd.setVolume(20);
bg_snd.start(0, 99999);
}
}
function createSound(clp) {
if (_global.soundOff == false) {
sndfx.setVolume(100);
sndfx.attachSound(clp);
sndfx.start();
}
}
function doNext() {
spider_mask.gotoAndPlay(2);
}
function tracking(cd) {
clearInterval(ttii);
trace("");
trace("TRACKING");
trace("code = " + cd);
trace("");
switch (cd) {
case "load" :
break;
case "play" :
getURL ("javascript:if (window.change_state) { change_state ('327~HE+SpiderMan3+rescue_mj+play') }");
break;
case "replay" :
getURL ("javascript:if (window.change_state) { change_state ('327~HE+SpiderMan3+rescue_mj+replaygame') }");
break;
case "end" :
break;
case "msnlogo" :
case "msntab" :
ttii = setInterval(this, "exittrack", 120, cd);
break;
}
}
function exittrack(cd) {
trace(">>");
trace("EXIT TRACK");
trace("code = " + cd);
trace("<<");
clearInterval(ttii);
switch (cd) {
case "msnlogo" :
getURL ("javascript:if(window.change_state){ change_state('320~http://movies.msn.com/movies/movie.aspx?m=560901&ocid=B001OFF03A1101A~289~www.sonypictures.com/homevideo/spiderman3/game/rescuemj/') }");
break;
case "msntab" :
getURL ("javascript:if(window.change_state){ change_state('320~http://spiderman3.msn.com/?ocid=B001OFF03A1101A~289~www.sonypictures.com/homevideo/spiderman3/game/rescuemj/') }");
}
}
_global.soundOff = false;
var bg_snd = new Sound(backgroundloop);
var sndfx = new Sound(this);
var ttii;
stop();
Frame 14
startBGLoop();
_level0.tracking("load");
Frame 26
stop();
Frame 36
play();
var gameObj = {};
gameObj.totalLevels = 3;
gameObj.currentLevel = 1;
var i = 1;
while (i <= gameObj.totalLevels) {
gameObj["level" + i] = {};
gameObj["level" + i].falls = 0;
gameObj["level" + i].totalTries = 0;
i++;
}
Frame 72
stop();
game_mc.init();
Frame 74
stop();
Frame 75
gotoAndStop ("end");
Symbol 21 MovieClip [pow_mc] Frame 32
this.removeMovieClip();
Symbol 35 MovieClip [pumpkin_bomb] Frame 1
#initclip 17
Object.registerClass("pumpkin_bomb", com.v8.pumpkinBomb);
#endinitclip
stop();
Symbol 35 MovieClip [pumpkin_bomb] Frame 2
_level0.createSound("explosion.wav");
Symbol 35 MovieClip [pumpkin_bomb] Frame 24
killMe();
Symbol 38 MovieClip [timer_mc] Frame 1
#initclip 13
Object.registerClass("timer_mc", com.v8.timerDisplay);
#endinitclip
Symbol 50 MovieClip [goblinFlight_mc] Frame 1
#initclip 14
Object.registerClass("goblinFlight_mc", com.v8.goblin);
#endinitclip
Symbol 58 MovieClip [venomClimb_mc] Frame 1
#initclip 15
Object.registerClass("venomClimb_mc", com.v8.venom);
#endinitclip
Symbol 59 MovieClip [webbing] Frame 1
#initclip 16
Object.registerClass("webbing", com.v8.swingingWebGeneration);
#endinitclip
Symbol 66 MovieClip Frame 1
function setLoaderAnim() {
this.onEnterFrame = function () {
var _local3 = this.clip.getBytesLoaded();
var _local2 = this.clip.getBytesTotal();
if ((_local2.toString() != undefined) || (_local2.toString() != "NaN")) {
this.percent = Math.round((_local3 / _local2) * 100);
if (!tweenFlag) {
openMask(this.percent);
}
if ((this.percent.toString() == "100") && (mask_mc._yscale == 100)) {
this.onEnterFrame = null;
scaleDownLoader();
}
}
};
}
function scaleUpLoader() {
_tween = new mx.transitions.TweenExtended(this, ["_xscale", "_yscale"], mx.transitions.easing.Regular.easeIn, [this._xscale, this._yscale], [maxScale, maxScale], 0.4, true);
_tween.onMotionFinished = function (evt) {
evt.obj.setLoaderAnim();
};
}
function scaleDownLoader() {
_tween = new mx.transitions.TweenExtended(this, ["_xscale", "_yscale"], mx.transitions.easing.Regular.easeIn, [this._xscale, this._yscale], [0, 0], 0.4, true);
_tween.onMotionFinished = function (evt) {
evt.obj._parent.gotoAndStop("build");
};
}
function openMask(pct) {
tweenFlag = true;
mask_tween = new mx.transitions.TweenExtended(mask_mc, ["_yscale"], mx.transitions.easing.Back.easeOut, [mask_mc._yscale], [pct], 0.7, true);
mask_tween.onMotionFinished = function (evt) {
evt.obj._parent.tweenFlag = false;
};
}
var _tween;
var mask_tween;
mask_mc._yscale = 0;
spider_mc.setMask(mask_mc);
var tweenFlag = false;
this._xscale = (this._yscale = 10);
this._alpha = 100;
var maxScale = 50;
this.clip = _root;
this.stop();
scaleUpLoader();
Symbol 219 MovieClip [__Packages.mx.transitions.easing.Elastic] Frame 0
class mx.transitions.easing.Elastic
{
function Elastic () {
}
static function easeIn(t, b, c, d, a, p) {
if (t == 0) {
return(b);
}
t = t / d;
if (t == 1) {
return(b + c);
}
if (!p) {
p = d * 0.3;
}
if ((!a) || (a < Math.abs(c))) {
a = c;
var _local7 = p / 4;
} else {
var _local7 = (p / (Math.PI*2)) * Math.asin(c / a);
}
t = t - 1;
return((-((a * Math.pow(2, 10 * t)) * Math.sin((((t * d) - _local7) * (Math.PI*2)) / p))) + b);
}
static function easeOut(t, b, c, d, a, p) {
if (t == 0) {
return(b);
}
t = t / d;
if (t == 1) {
return(b + c);
}
if (!p) {
p = d * 0.3;
}
if ((!a) || (a < Math.abs(c))) {
a = c;
var _local7 = p / 4;
} else {
var _local7 = (p / (Math.PI*2)) * Math.asin(c / a);
}
return((((a * Math.pow(2, -10 * t)) * Math.sin((((t * d) - _local7) * (Math.PI*2)) / p)) + c) + b);
}
static function easeInOut(t, b, c, d, a, p) {
if (t == 0) {
return(b);
}
t = t / (d / 2);
if (t == 2) {
return(b + c);
}
if (!p) {
p = d * 0.45;
}
if ((!a) || (a < Math.abs(c))) {
a = c;
var _local7 = p / 4;
} else {
var _local7 = (p / (Math.PI*2)) * Math.asin(c / a);
}
if (t < 1) {
t = t - 1;
return((-0.5 * ((a * Math.pow(2, 10 * t)) * Math.sin((((t * d) - _local7) * (Math.PI*2)) / p))) + b);
}
t = t - 1;
return(((((a * Math.pow(2, -10 * t)) * Math.sin((((t * d) - _local7) * (Math.PI*2)) / p)) * 0.5) + c) + b);
}
static var version = "1.1.0.52";
}
Symbol 220 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");
};
}
}
static var version = "1.1.0.52";
}
Symbol 221 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++;
}
}
static var version = "1.1.0.52";
}
Symbol 222 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 version = "1.1.0.52";
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 223 MovieClip [__Packages.mx.transitions.TweenExtended] Frame 0
class mx.transitions.TweenExtended extends mx.transitions.Tween
{
var aChange, obj, aProps, aBegin, __set__duration, useSeconds, func, point1, point2, _listeners, addListener, start, _time, __get__time, _duration, _aPos, broadcastMessage, looping;
function TweenExtended (target, props, easeFunc, strt, end, dur, useSecs, p1, p2) {
super();
mx.transitions.OnEnterFrameBeacon.init();
if (!arguments.length) {
return;
}
aChange = [];
obj = target;
aProps = props;
aBegin = strt;
position = (copyArray(strt));
__set__duration(dur);
useSeconds = useSecs;
if (easeFunc) {
func = easeFunc;
}
finish = (end);
point1 = p1;
point2 = p2;
_listeners = [];
addListener(this);
start();
}
function update() {
position = (getPosition(_time));
}
function continueTo(fin, dur) {
var _local2 = 0;
while (_local2 < aProps.length) {
aBegin[_local2] = position[_local2];
_local2++;
}
finish = (fin);
if (dur != undefined) {
__set__duration(dur);
}
start();
}
function yoyo() {
var _local2 = copyArray(aBegin);
continueTo(_local2, __get__time());
}
function get position() {
return(getPosition());
}
function getPosition(t) {
if (t == undefined) {
t = _time;
}
var _local5 = [];
var _local2 = 0;
while (_local2 < aProps.length) {
var _local4 = Number(aBegin[_local2]);
var _local3 = Number(aChange[_local2]);
if ((point1 == undefined) && (point2 == undefined)) {
_local5[_local2] = func(t, _local4, _local3, _duration);
} else if ((point1 != undefined) && (point2 == undefined)) {
_local5[_local2] = func(t, _local4, _local3, _duration, point1);
} else if ((point1 != undefined) && (point2 != undefined)) {
_local5[_local2] = func(t, _local4, _local3, _duration, point1, point2);
}
_local2++;
}
return(_local5);
}
function set position(p) {
setPosition(p);
//return(position);
}
function setPosition(p) {
var _local2 = 0;
while (_local2 < aProps.length) {
obj[aProps[_local2]] = (_aPos[_local2] = p[_local2]);
_local2++;
}
broadcastMessage("onMotionChanged", this, p);
updateAfterEvent();
}
function set finish(f) {
var _local2 = 0;
while (_local2 < aProps.length) {
aChange[_local2] = f[_local2] - aBegin[_local2];
_local2++;
}
//return(finish);
}
function get finish() {
var _local3 = [];
var _local2 = 0;
while (_local2 < aProps.length) {
_local3[_local2] = aBegin[_local2] + aChange[_local2];
_local2++;
}
return(_local3);
}
function set loop(b) {
looping = b;
//return(loop);
}
function get loop() {
return(looping);
}
function copyArray(arr) {
var _local3 = [];
if (arr.length == 0) {
for (var _local1 in arr) {
_local3[_local1] = arr[_local1];
}
}
var _local1 = 0;
while (_local1 < arr.length) {
_local3[_local1] = arr[_local1];
_local1++;
}
return(_local3);
}
function toString() {
return(("[" + className) + "]");
}
var className = "TweenExtended";
static var version = "1.0.6";
}
Symbol 224 MovieClip [__Packages.mx.transitions.easing.Back] Frame 0
class mx.transitions.easing.Back
{
function Back () {
}
static function easeIn(t, b, c, d, s) {
if (s == undefined) {
s = 1.70158;
}
t = t / d;
return((((c * t) * t) * (((s + 1) * t) - s)) + b);
}
static function easeOut(t, b, c, d, s) {
if (s == undefined) {
s = 1.70158;
}
t = (t / d) - 1;
return((c * (((t * t) * (((s + 1) * t) + s)) + 1)) + b);
}
static function easeInOut(t, b, c, d, s) {
if (s == undefined) {
s = 1.70158;
}
t = t / (d / 2);
if (t < 1) {
s = s * 1.525;
return(((c / 2) * ((t * t) * (((s + 1) * t) - s))) + b);
}
t = t - 2;
s = s * 1.525;
return(((c / 2) * (((t * t) * (((s + 1) * t) + s)) + 2)) + b);
}
static var version = "1.1.0.52";
}
Symbol 225 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);
}
static var version = "1.1.0.52";
}
Symbol 226 MovieClip [__Packages.com.v8.timerDisplay] Frame 0
class com.v8.timerDisplay extends MovieClip
{
var timeLeft, threshold, timer_txt, whiteFMT, redFMT, timeInSeconds, startTime, timer1, _parent;
function timerDisplay () {
super();
timeLeft = 0;
threshold = 10;
timer_txt.text = "00:00:00";
whiteFMT = new TextFormat();
whiteFMT.color = 16777215 /* 0xFFFFFF */;
redFMT = new TextFormat();
redFMT.color = 16711680 /* 0xFF0000 */;
timer_txt.setTextFormat(whiteFMT);
}
function createTimer(time) {
timeInSeconds = time;
startTime = getTimer();
startTimer();
}
function timer() {
timeLeft = (timeInSeconds * 1000) - (getTimer() - startTime);
var _local6 = 0;
var _local2 = Math.floor(timeLeft / 1000);
var _local7 = Math.floor((timeLeft - (_local2 * 1000)) / 10);
var _local5 = _local7;
var _local3 = _local2;
var _local4 = _local6;
if (_local2 > 59) {
_local3 = _local2 - 60;
_local4 = _local6 + 1;
}
if (_local4 < 10) {
_local4 = String("0" + _local4);
}
if (_local5 < 10) {
_local5 = String("0" + _local5);
}
if (_local3 < 10) {
_local3 = String("0" + _local3);
}
timer_txt.text = (((_local4 + " : ") + _local3) + " : ") + _local5;
if (_local2 < 0) {
timer_txt.text = "00:00:00";
clearInterval(timer1);
_parent.endLevel();
clearTimer();
} else if (_local2 < threshold) {
timer_txt.setTextFormat(redFMT);
}
}
function getTimeLeft() {
return(timeLeft / 1000);
}
function getTimeLeftInTime() {
var _local2 = Math.round(((timeLeft / 1000) / 60) * 100) / 100;
return(_local2);
}
function clearTimer() {
timer_txt.text = "00:00:00";
clearInterval(timer1);
}
function pauseTimer() {
clearInterval(timer1);
}
function startTimer() {
timer1 = setInterval(this, "timer", 10);
}
}
Symbol 227 MovieClip [__Packages.com.v8.goblin] Frame 0
class com.v8.goblin extends MovieClip
{
var leftDist, char, dir, vx, speed, rightDist, timeInt, _parent, _y, _x;
function goblin () {
super();
leftDist = char._y;
char.stop();
dir = "right";
vx = 0;
}
function autoSetUp() {
setDist(400);
setSpeed(30);
initGoblin();
}
function setSpeed(amt) {
speed = amt;
}
function setDist(amt) {
rightDist = leftDist + amt;
}
function initGoblin() {
timeInt = setInterval(this, "moveGoblin", speed);
}
function moveGoblin() {
if (_global.pause == false) {
var _local4 = 20;
var _local3 = 0;
switch (dir) {
case "right" :
_local3 = (rightDist - char._x) * 0.1;
break;
case "left" :
_local3 = (leftDist - char._x) * 0.1;
}
if (((char._x + _local4) >= rightDist) || ((char._x - _local4) <= leftDist)) {
if (char._currentframe != 2) {
tossPumpkin();
char.gotoAndStop(2);
}
} else {
char.gotoAndStop(1);
}
char._x = char._x + (_local3 / 2);
if (Math.ceil(char._x) == rightDist) {
dir = "left";
char._xscale = -100;
}
if (Math.ceil(char._x) == leftDist) {
dir = "right";
char._xscale = 100;
}
}
}
function tossPumpkin() {
var _local2 = _parent.attachMovie("pumpkin_bomb", "pb" + _parent.getNextHighestDepth(), _parent.getNextHighestDepth());
_local2._y = _y + char._y;
_local2._x = _x + char._x;
}
}
Symbol 228 MovieClip [__Packages.com.v8.venom] Frame 0
class com.v8.venom extends MovieClip
{
var bottom, char, orderArray, currentAction, busy, jumpLength, dir, maxlength, timeInt, __jumptween;
function venom () {
super();
bottom = char._y;
char.stop();
orderArray = new Array("ready", "jump", "wait");
currentAction = 0;
busy = false;
jumpLength = 150;
dir = "up";
}
function setCeil(len) {
maxlength = -len;
}
function move(amt) {
char._y = amt;
}
function setBottom(amt) {
bottom = amt;
}
function initVenom() {
if (maxlength.toString() == undefined) {
setCeil(200);
}
timeInt = setInterval(this, "stepManager", 20);
}
function stepManager() {
if (_global.pause == false) {
if (busy == false) {
clearInterval(timeInt);
this[orderArray[currentAction]].apply(this);
currentAction = (((currentAction + 1) >= orderArray.length) ? 0 : (currentAction + 1));
}
}
}
function ready() {
timeInt = setInterval(this, "stepManager", 500);
char.gotoAndStop(2);
}
function jump() {
timeInt = setInterval(this, "stepManager", 1100);
var _local2 = findDistance();
__jumptween = new mx.transitions.TweenExtended(char, ["_y"], mx.transitions.easing.Regular.easeOut, [char._y], [char._y - _local2], 1, true);
if (_local2 != 0) {
char.gotoAndStop(3);
}
}
function wait() {
timeInt = setInterval(this, "stepManager", random(1000));
char.gotoAndStop(1);
}
function findDistance() {
var _local2 = jumpLength;
if (dir == "up") {
if ((char._y - jumpLength) < (bottom + maxlength)) {
dir = "down";
char._xscale = -100;
_local2 = (bottom + maxlength) - char._y;
}
} else {
_local2 = -jumpLength;
if ((char._y + jumpLength) > bottom) {
dir = "up";
char._xscale = 100;
_local2 = bottom - char._y;
}
}
return(_local2);
}
}
Symbol 229 MovieClip [__Packages.com.v8.swingingWebGeneration] Frame 0
class com.v8.swingingWebGeneration extends MovieClip
{
var dir, spideyAttached, __length, webbing, createEmptyMovieClip, capAngle, timeInt, spidey, clear, _y;
function swingingWebGeneration () {
super();
dir = 1;
spideyAttached = false;
__length = 130;
}
function autoSetUp() {
createWebbing(__length);
createSwing(10, 45, random(22));
}
function changeDir(n) {
dir = n;
}
function createWebbing(len) {
__length = len;
webbing.removeMovieClip();
createEmptyMovieClip("webbing", 666999);
webbing.lineStyle(0, 13421772, 100);
webbing.moveTo(0, 0);
webbing.lineTo(0, len);
createInvisibleHitState(len);
createSwingPoint(len);
}
function createInvisibleHitState(len) {
webbing.beginFill(16711680, 0);
webbing.moveTo(-1, 0);
webbing.lineTo(1, 0);
webbing.lineTo(1, len + 2);
webbing.lineTo(-1, len + 2);
webbing.lineTo(-1, 0);
webbing.endFill();
}
function createSwingPoint(len) {
webbing.createEmptyMovieClip("anchor", 667000);
webbing.anchor._y = len / 2;
}
function createSwing(spd, capAng, startAngle) {
capAngle = capAng;
webbing._rotation = startAngle;
timeInt = setInterval(this, "rotateweb", spd);
}
function rotateweb() {
if (_global.pause == false) {
webbing._rotation = webbing._rotation + dir;
if ((dir > 0) && (webbing._rotation > capAngle)) {
dir = -dir;
}
if ((dir < 0) && (webbing._rotation < (-capAngle))) {
dir = Math.abs(dir);
}
if (spidey.currentState == "hit") {
detachSpidey();
}
if (spideyAttached) {
setAttachedSpidey();
}
clear();
updateAfterEvent();
}
}
function attachSpidey(spdy) {
spidey = spdy;
spideyAttached = true;
createRelativeSwingPoint();
}
function detachSpidey() {
spideyAttached = false;
webbing.anchor._y = __length / 2;
}
function createRelativeSwingPoint() {
webbing.anchor._y = spidey._y - _y;
webbing.anchor._y = webbing.anchor._y - 60;
webbing.anchor._y = ((webbing.anchor._y >= __length) ? (__length - 1) : (webbing.anchor._y));
webbing.anchor._y = ((webbing.anchor._y <= 5) ? 5 : (webbing.anchor._y));
setAttachedSpidey();
}
function setAttachedSpidey() {
var _local2 = {x:0, y:0};
webbing.anchor.localToGlobal(_local2);
spidey._x = _local2.x;
spidey._y = _local2.y;
spidey.momentum = webbing.anchor._y;
}
function spideySlideUp() {
if (webbing.anchor._y > 10) {
webbing.anchor._y = webbing.anchor._y - 2;
}
}
function spideySlideDown() {
if (webbing.anchor._y < (__length - 10)) {
webbing.anchor._y = webbing.anchor._y + 2;
}
}
}
Symbol 230 MovieClip [__Packages.com.v8.pumpkinBomb] Frame 0
class com.v8.pumpkinBomb extends MovieClip
{
var dist, timeInt, _y, removeMovieClip, gotoAndPlay;
function pumpkinBomb () {
super();
dist = 2;
timeInt = setInterval(this, "drop", 20);
}
function drop() {
if (_global.pause == false) {
_y = _y + dist;
if (_y > Stage.height) {
killMe();
}
}
}
function killMe() {
clearInterval(timeInt);
removeMovieClip();
}
function react() {
gotoAndPlay(2);
}
}
Symbol 76 Button
on (release) {
_parent.instructions();
_parent._parent.instructions();
}
Symbol 86 MovieClip Frame 1
function slideMeOut() {
closeState = "down";
_tween = new mx.transitions.TweenExtended(this, ["_y", "_alpha"], mx.transitions.easing.Regular.easeIn, [this._y, this._alpha], [origY, 100], 0.8, true);
}
function slideMeIn() {
closeState = "up";
_tween = new mx.transitions.TweenExtended(this, ["_y", "_alpha"], mx.transitions.easing.Regular.easeIn, [this._y, this._alpha], [closeY, 0], 0.8, true);
}
this._alpha = 0;
var origY = this._y;
var closeY = ((this._y - this._height) - 10);
var closeState = "up";
this._y = closeY;
var _tween;
Symbol 108 Button
on (release) {
instructions();
}
Symbol 110 Button
on (release) {
_global.soundOff = true;
stopAllSounds();
gotoAndStop (2);
}
Symbol 113 Button
on (release) {
_global.soundOff = false;
_level0.startBGLoop();
gotoAndStop (1);
}
Symbol 114 MovieClip Frame 1
stop();
Symbol 115 Button
on (release) {
getURL ("javascript:window.close();");
}
Symbol 116 MovieClip Frame 1
function instructions() {
if (instructions_mc.closeState == "up") {
instructions_mc.slideMeOut();
} else {
instructions_mc.slideMeIn();
}
}
Symbol 116 MovieClip Frame 56
_parent.gotoAndPlay("intro");
Symbol 116 MovieClip Frame 133
stop();
Symbol 134 MovieClip Frame 20
_level0.createSound("SND_whoosh09.wav");
Symbol 134 MovieClip Frame 31
_level0.createSound("webshooter");
Symbol 134 MovieClip Frame 49
_level0.bounceButtons(playgame_btn);
_level0.bounceButtons(instructions_btn);
_level0.bounceButtons(msn_btn);
playgame_btn.onRelease = function () {
if (_root.frame_mc.instructions_mc.closeState == "up") {
_level0.tracking("play");
_level0.createSound("SND_poofter04.wav");
gotoAndPlay ("exitintro");
}
};
msn_btn.onRollOver = (instructions_btn.onRollOver = (playgame_btn.onRollOver = function () {
if (_root.frame_mc.instructions_mc.closeState == "up") {
_level0.createSound("SND_ching03.wav");
this.useHandCursor = true;
} else {
this.useHandCursor = false;
}
}));
instructions_btn.onRelease = function () {
if (_root.frame_mc.instructions_mc.closeState == "up") {
_level0.createSound("SND_poofter04.wav");
_level0.frame_mc.instructions();
}
};
msn_btn.onRelease = function () {
if (_root.frame_mc.instructions_mc.closeState == "up") {
_level0.tracking("msntab");
_level0.createSound("SND_poofter04.wav");
getURL ("http://spiderman3.msn.com/?ocid=B001OFF03A1101A", "_blank");
}
};
Symbol 134 MovieClip Frame 52
stop();
Symbol 134 MovieClip Frame 53
play();
Symbol 134 MovieClip Frame 58
_level0.createSound("SND_whoosh09.wav");
Symbol 134 MovieClip Frame 63
_parent.gotoAndPlay("game");
Symbol 134 MovieClip Frame 83
stop();
Symbol 136 MovieClip Frame 1
stop();
Symbol 136 MovieClip Frame 24
if (_parent.gameObj.currentLevel <= 3) {
_parent.gotoAndPlay("reset");
} else {
_parent.gotoAndPlay("end");
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(140);
createSwing(20, 49, random(22));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(115);
createSwing(8, 67, random(45));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(140);
createSwing(20, 49, random(22));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(150);
createSwing(27, 50, random(45));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(120);
createSwing(18, 60, random(45));
}
Symbol 155 MovieClip Frame 2
gotoAndPlay ("loop");
Instance of Symbol 58 MovieClip [venomClimb_mc] in Symbol 157 MovieClip Frame 1
onClipEvent (load) {
move(80);
setCeil(300);
setBottom(400);
jumpLength = 150;
initVenom();
}
Instance of Symbol 50 MovieClip [goblinFlight_mc] in Symbol 157 MovieClip Frame 1
onClipEvent (load) {
autoSetUp();
}
Instance of Symbol 50 MovieClip [goblinFlight_mc] in Symbol 157 MovieClip Frame 1
onClipEvent (load) {
setDist(200);
setSpeed(30);
initGoblin();
}
Symbol 182 MovieClip Frame 1
stop();
Instance of Symbol 59 MovieClip [webbing] in Symbol 187 MovieClip Frame 1
onClipEvent (load) {
createWebbing(180);
createSwing(8, 20, random(15));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 187 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 187 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 187 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(140);
createSwing(20, 49, random(22));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 187 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 187 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(115);
createSwing(8, 67, random(45));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 187 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(140);
createSwing(20, 49, random(22));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 187 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(150);
createSwing(27, 50, random(45));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 187 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 187 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(220);
createSwing(18, 60, random(45));
}
Instance of Symbol 58 MovieClip [venomClimb_mc] in Symbol 188 MovieClip Frame 1
onClipEvent (load) {
initVenom();
}
Instance of Symbol 58 MovieClip [venomClimb_mc] in Symbol 188 MovieClip Frame 1
onClipEvent (load) {
initVenom();
}
Instance of Symbol 58 MovieClip [venomClimb_mc] in Symbol 188 MovieClip Frame 1
onClipEvent (load) {
initVenom();
}
Instance of Symbol 50 MovieClip [goblinFlight_mc] in Symbol 188 MovieClip Frame 1
onClipEvent (load) {
setDist(280);
setSpeed(17);
initGoblin();
}
Instance of Symbol 50 MovieClip [goblinFlight_mc] in Symbol 188 MovieClip Frame 1
onClipEvent (load) {
setDist(320);
setSpeed(30);
initGoblin();
}
Instance of Symbol 50 MovieClip [goblinFlight_mc] in Symbol 188 MovieClip Frame 1
onClipEvent (load) {
setDist(200);
setSpeed(30);
initGoblin();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
createWebbing(200);
createSwing(10, 50, random(15));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
createWebbing(130);
createSwing(10, 45, 5);
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(140);
createSwing(20, 49, random(22));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(115);
createSwing(8, 67, random(45));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(100);
createSwing(20, 49, random(22));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(150);
createSwing(27, 50, random(45));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
this.autoSetUp();
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
this.createWebbing(100);
createSwing(18, 60, random(45));
}
Instance of Symbol 59 MovieClip [webbing] in Symbol 194 MovieClip Frame 1
onClipEvent (load) {
createWebbing(165);
createSwing(8, 50, 0);
}
Instance of Symbol 58 MovieClip [venomClimb_mc] in Symbol 195 MovieClip Frame 1
onClipEvent (load) {
setCeil(150);
jumpLength = 60;
initVenom();
}
Instance of Symbol 58 MovieClip [venomClimb_mc] in Symbol 195 MovieClip Frame 1
onClipEvent (load) {
initVenom();
}
Instance of Symbol 58 MovieClip [venomClimb_mc] in Symbol 195 MovieClip Frame 1
onClipEvent (load) {
initVenom();
}
Instance of Symbol 50 MovieClip [goblinFlight_mc] in Symbol 195 MovieClip Frame 1
onClipEvent (load) {
setDist(200);
setSpeed(15);
initGoblin();
}
Instance of Symbol 50 MovieClip [goblinFlight_mc] in Symbol 195 MovieClip Frame 1
onClipEvent (load) {
setDist(320);
setSpeed(30);
initGoblin();
}
Instance of Symbol 50 MovieClip [goblinFlight_mc] in Symbol 195 MovieClip Frame 1
onClipEvent (load) {
setDist(200);
setSpeed(15);
initGoblin();
}
Symbol 197 MovieClip Frame 1
function init() {
initSpidey();
stageInt = setInterval(this, "StageManager", 20);
var _local3 = ((_parent.gameObj.currentLevel == 3) ? 90 : 120);
timer_mc.createTimer(_local3);
}
function fall_wait() {
if (!this.stageMC.limitMC.hitTest(this.spidey._x, this.spidey._y, true)) {
spidey.currentState = "jumpDown";
}
}
function move_left(valueX) {
if (!this.stageMC.limitMC.hitTest((this.spidey._x - valueX) - 8, this.spidey._y - 4, true)) {
this.spidey._x = this.spidey._x - valueX;
this.spidey.gotoAndStop("walk");
}
}
function move_right(valueX) {
if (!this.stageMC.limitMC.hitTest((this.spidey._x + valueX) + 8, this.spidey._y - 4, true)) {
this.spidey._x = this.spidey._x + valueX;
this.spidey.gotoAndStop("walk");
}
}
function jump_down(valueY) {
if (!this.stageMC.limitMC.hitTest(this.spidey._x, this.spidey._y, true)) {
this.spidey._y = this.spidey._y + valueY;
} else {
i = 1;
while (i <= (fallSpeed + 5)) {
if (!this.stageMC.limitMC.hitTest(this.spidey._x, this.spidey._y - i, true)) {
this.spidey._y = this.spidey._y - (i - 3);
break;
}
i++;
}
spidey.currentState = "wait";
_level0.createSound("land.mp3");
this.spidey.gotoAndStop("stand");
}
}
function jumpSwing_right(valueX) {
this.spidey._x = this.spidey._x + valueX;
}
function jumpSwing_left(valueX) {
this.spidey._x = this.spidey._x - valueX;
}
function StageManager() {
if (!__locked) {
checkKeys();
checkContactWithWeb();
checkSpideyOnEdge();
checkVillianHit();
}
evalSpideyState();
checkDeath();
}
function checkSpideyOnEdge() {
if (spidey._x > (Stage.width - 80)) {
clearInterval(stageInt);
stageInt = setInterval(this, "slideStage", 20, stageMC._x);
}
}
function initSpidey() {
spidey.currentState = "jumpDown";
spidey.jumpH = 0;
spidey.currentVine = null;
}
function slideStage(origX) {
if ((stageMC._x <= (origX - (Stage.width - 140))) || (stageMC._x <= (-((stageMC._width - 10) - Stage.width)))) {
_global.pause = false;
clearInterval(stageInt);
stageInt = setInterval(this, "StageManager", 20);
} else {
_global.pause = true;
spidey._x = spidey._x - 10;
stageMC._x = stageMC._x - 10;
}
}
function evalSpideyState() {
spidey.gotoAndStop(spidey.currentState);
switch (spidey.currentState) {
case "jumpDown" :
jumpDownSpidey();
return;
case "jumpUp" :
jumpUpSpidey();
return;
case "jumpOut" :
spidey.gotoAndStop("jumpUp");
jumpOutSpidey();
return;
case "wait" :
spideyWait();
return;
case "hit" :
spideyKnockBack();
}
}
function checkKeys() {
var _local2 = false;
if (!Key.isDown(Kjump)) {
jumpLock = false;
}
if (!__locked) {
if (((spidey.currentState != "swing") && (spidey.currentState != "jumpOut")) && (spidey.currentState != "climb")) {
if (Key.isDown(Kright)) {
_local2 = true;
spidey._xscale = 100;
move_right(walkSpeed);
}
if (Key.isDown(Kleft)) {
_local2 = true;
spidey._xscale = -100;
move_left(walkSpeed);
}
if (Key.isDown(Kjump) && (spidey.currentState == "wait")) {
jumpLock = true;
_local2 = true;
spidey.jumpH = -jumpHeight;
spidey.currentState = "jumpUp";
}
if (!_local2) {
this.spidey.gotoAndStop("stand");
}
} else {
if (((((Key.isDown(Kjump) && (spidey.currentState != "jumpOut")) && (spidey.currentState != "climb")) && (!Key.isDown(Kup))) && (!Key.isDown(Kdown))) && (jumpLock == false)) {
jumpLock = true;
spidey.currentState = "jumpOut";
spidey.currentVine.detachSpidey();
spidey.jumpH = -jumpHeight;
_level0.createSound("airwhoosh35.wav");
clearVineInt = setInterval(this, "resetVine", 500);
}
if (Key.isDown(Kright)) {
spidey._xscale = 100;
}
if (Key.isDown(Kleft)) {
spidey._xscale = -100;
}
if (Key.isDown(Kup) && (!Key.isDown(Kjump))) {
_local2 = true;
spidey.currentVine.spideySlideUp();
spidey.currentState = "climb";
}
if (Key.isDown(Kdown) && (!Key.isDown(Kjump))) {
_local2 = true;
spidey.currentVine.spideySlideDown();
spidey.currentState = "climb";
}
if (((!_local2) && (spidey.currentState != "jumpOut")) && (this.spidey.currentVine != null)) {
spidey.currentState = "swing";
}
}
}
}
function resetVine() {
clearInterval(clearVineInt);
this.spidey.currentVine = null;
}
function jumpDownSpidey() {
if (spidey.jumpH < fallSpeed) {
spidey.jumpH = spidey.jumpH + jumpSpeed;
}
jump_down(spidey.jumpH);
}
function jumpUpSpidey() {
spidey._y = spidey._y + spidey.jumpH;
spidey.jumpH = spidey.jumpH + jumpSpeed;
if (spidey.jumpH >= 0) {
spidey.currentState = "jumpDown";
}
}
function jumpOutSpidey() {
spidey._y = spidey._y + spidey.jumpH;
if (spidey._xscale > 0) {
jumpSwing_right(spidey.momentum / 14);
} else {
jumpSwing_left(spidey.momentum / 14);
}
spidey.jumpH = spidey.jumpH + jumpSpeed;
if (spidey.jumpH >= 0) {
spidey.currentState = "jumpDown";
}
}
function spideyWait() {
fall_wait();
}
function checkContactWithWeb() {
if (this.spidey.currentState != "swing") {
for (var _local2 in this.stageMC.webMC) {
if (typeof(this.stageMC.webMC[_local2]) == "movieclip") {
if (this.stageMC.webMC[_local2].hitTest(this.spidey) && (spidey.currentVine != this.stageMC.webMC[_local2])) {
if (((this.spidey._y - this.spidey._height) - 4) >= this.stageMC.webMC[_local2]._y) {
resetVine();
this.stageMC.webMC[_local2].attachSpidey(this.spidey);
spidey.currentVine = this.stageMC.webMC[_local2];
this.spidey.currentState = "swing";
break;
}
}
}
}
}
}
function checkVillianHit() {
for (var _local4 in this.stageMC.villansMC) {
if (typeof(this.stageMC.villansMC[_local4]) == "movieclip") {
if (this.stageMC.villansMC[_local4].char.hitstate.hitTest(this.spidey)) {
this.stageMC.villansMC[_local4].react();
__locked = true;
this.attachMovie("pow_mc", "pow_mc", 12227, {_x:spidey._x, _y:spidey._y});
this.spidey.currentState = "hit";
} else if (this.stageMC.villansMC[_local4].end.hitTest(this.spidey)) {
winLevel();
}
}
}
}
function spideyKnockBack() {
if (this.spidey._xscale > 0) {
this.spidey._x = this.spidey._x - 5;
} else {
this.spidey._x = this.spidey._x + 5;
}
this.spidey._y = this.spidey._y + 10;
this.spidey.gotoAndStop("jumpDown");
}
function checkDeath() {
if (this.spidey._y > (Stage.height + 200)) {
_parent.gameObj["level" + _parent.gameObj.currentLevel].falls = _parent.gameObj["level" + _parent.gameObj.currentLevel].falls + 1;
__locked = false;
this.spidey._y = -11;
this.spidey._x = 88;
this.spidey.currentState = "wait";
spidey.currentVine = null;
}
}
function endLevel() {
clearInterval(stageInt);
stageInt = setInterval(this, "countDown", 800);
_level0.doNext();
}
function winLevel() {
clearInterval(stageInt);
stageInt = setInterval(this, "countDown", 800);
_parent.gameObj.currentLevel = _parent.gameObj.currentLevel + 1;
_level0.doNext();
}
_global.pause = false;
var Kleft = 37;
var Kright = 39;
var Kup = 38;
var Kdown = 40;
var Kjump = 32;
var walkSpeed = 5;
var jumpHeight = 12;
var jumpSpeed = 1.2;
var fallSpeed = 6;
var __locked = false;
var clearVineInt;
var stageInt;
var jumpLock = false;
_parent.gameObj["level" + _parent.gameObj.currentLevel].totalTries = _parent.gameObj["level" + _parent.gameObj.currentLevel].totalTries + 1;
if (_parent.gameObj.currentLevel > 1) {
_level0.tracking(_parent.gameObj.currentLevel);
}
gotoAndStop(_parent.gameObj.currentLevel + 1);
Symbol 211 Button
on (release) {
_level0.tracking("msnlogo");
getURL ("http://movies.msn.com/movies/movie.aspx?m=560901&ocid=B001OFF03A1101A", "_blank");
}
Symbol 217 Button
on (release) {
_level0.tracking("replay");
_level0.createSound("SND_poofter04.wav");
_level0.gotoAndPlay("build");
}
on (rollOver) {
_level0.createSound("SND_ching03.wav");
}
Symbol 218 MovieClip Frame 1
_level0.tracking("end");
Symbol 218 MovieClip Frame 41
_level0.createSound("SND_whoosh09.wav");
Symbol 218 MovieClip Frame 48
_level0.createSound("SND_ swish09.wav");
Symbol 218 MovieClip Frame 52
level1_txt.text = ((("LEVEL 1\rAttempts: " + _parent.gameObj.level1.totalTries) + newline) + "Falls: ") + _parent.gameObj.level1.falls;
level2_txt.text = ((("LEVEL 2\rAttempts: " + _parent.gameObj.level2.totalTries) + newline) + "Falls: ") + _parent.gameObj.level2.falls;
level3_txt.text = ((("LEVEL 3\rAttempts: " + _parent.gameObj.level3.totalTries) + newline) + "Falls: ") + _parent.gameObj.level3.falls;
Symbol 218 MovieClip Frame 63
stop();