Frame 1
tabEnabled = false;
Stage.showMenu = false;
var VOLUME = 100;
_quality = "MEDIUM";
var EFFECTS = true;
var SAVE = true;
stop();
_root.WPI_ArcadeStartSingleGame = function () {
trace("WPI_ArcadeStartSingleGame called - the current game has started");
};
_root.WPI_ArcadeStopSingleGame = function (score) {
trace("WPI_ArcadeStopSingleGame called - the current game has finished with score: " + score);
};
Instance of Symbol 17 MovieClip "dustparticle" in Frame 1
onClipEvent (load) {
var rotspeed = (random(20) - 10);
if (_parent._currentframe < 20) {
gotoAndStop(int(random(6) + 1));
var gravity = 0;
var fade = 6;
_alpha = 80;
} else if (_parent._currentframe < 35) {
gotoAndStop(int(random(8) + 7));
var gravity = (random(0.25) + 0.25);
_y = (_y + 5);
var fade = 3;
_alpha = 100;
} else {
gotoAndStop(int(random(3) + 15));
var gravity = 0;
var fade = 6;
_alpha = 80;
}
var xscalespeed = (random(2) + 2);
var yscalespeed = (random(2) + 2);
_xscale = 40;
_yscale = 40;
_x = (_x + (random(20) - 10));
_y = (_y - 5);
_rotation = random(360);
var yspeed = 3;
}
onClipEvent (enterFrame) {
if (_name == "dustparticle") {
_visible = false;
} else {
_xscale = (_xscale + xscalespeed);
_yscale = (_yscale + yscalespeed);
_alpha = (_alpha - fade);
_rotation = (_rotation + rotspeed);
yspeed = yspeed - gravity;
_y = (_y - yspeed);
if (_alpha <= 0) {
this.removeMovieClip();
}
if (_parent.info._currentframe != 1) {
this.removeMovieClip();
}
}
}
Frame 2
mission_complete = function (MISSION, TIME, OBJECTS_ACHIEVED, OBJECTS_TOTAL, POINTS) {
if (info._currentframe == 1) {
items_score = Math.floor((OBJECTS_ACHIEVED / OBJECTS_TOTAL) * 100);
onEnterFrame = null;
info.play();
}
};
stars = function (AMOUNT) {
if (EFFECTS == true) {
lmao = 1;
while (lmao <= AMOUNT) {
starparticle.duplicateMovieClip("starparticle" + lmao, getNextHighestDepth());
lmao++;
}
}
};
dust = function (XPOS, YPOS) {
if (EFFECTS == true) {
var _local2 = getNextHighestDepth();
dustparticle.duplicateMovieClip("dustparticle" + _local2, _local2);
this["dustparticle" + _local2]._x = XPOS;
this["dustparticle" + _local2]._y = YPOS;
}
};
setsound = false;
var levelhighscores = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
var goldcoincollected = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
var savefile = SharedObject.getLocal("wiggi_sidescroller");
i = 1;
while (i < 13) {
this["missionhighscore" + i] = savefile.data["missionhighscore" + i];
if (this["missionhighscore" + i] == undefined) {
this["missionhighscore" + i] = 0;
}
this["goldcoincollected" + i] = savefile.data["goldcoincollected" + i];
if (this["goldcoincollected" + i] == undefined) {
this["goldcoincollected" + i] = 0;
}
levelhighscores[i - 1] = this["missionhighscore" + i];
goldcoincollected[i - 1] = this["goldcoincollected" + i];
i++;
}
trace("The gold coin array has been loaded as: ");
trace(goldcoincollected);
stop();
Instance of Symbol 66 MovieClip in Frame 2
onClipEvent (enterFrame) {
if (Key.isDown(32)) {
_parent.play();
}
}
Frame 3
var missionbank = new Array();
missionbank = [8, 11, 14, 17, 20, 23, 26, 29, 32, 35, 38, 41];
var playing_main_game = false;
stopAllSounds();
delete menu_loop;
delete city_loop;
delete beach_loop;
delete forest_loop;
var menu_loop = new Sound();
menu_loop.attachSound("main_menu_loop");
menu_loop.start(0, 100);
setsound = true;
stop();
Frame 4
stop();
Frame 5
stop();
Frame 6
stop();
Instance of Symbol 167 MovieClip "lowqual" in Frame 6
onClipEvent (load) {
if (_parent._quality == "LOW") {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
on (release, releaseOutside) {
_parent._quality = "LOW";
this.gotoAndStop(2);
_parent.medqual.gotoAndStop(1);
_parent.highqual.gotoAndStop(1);
}
Instance of Symbol 170 MovieClip "medqual" in Frame 6
onClipEvent (load) {
if (_parent._quality == "MEDIUM") {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
on (release, releaseOutside) {
_parent._quality = "MEDIUM";
this.gotoAndStop(2);
_parent.lowqual.gotoAndStop(1);
_parent.highqual.gotoAndStop(1);
}
Instance of Symbol 173 MovieClip "highqual" in Frame 6
onClipEvent (load) {
if (_parent._quality == "HIGH") {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
on (release, releaseOutside) {
_parent._quality = "HIGH";
this.gotoAndStop(2);
_parent.medqual.gotoAndStop(1);
_parent.lowqual.gotoAndStop(1);
}
Instance of Symbol 176 MovieClip "effectsoff" in Frame 6
onClipEvent (load) {
if (_parent.EFFECTS == false) {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
on (release, releaseOutside) {
_parent.EFFECTS = false;
this.gotoAndStop(2);
_parent.effectson.gotoAndStop(1);
}
Instance of Symbol 179 MovieClip "effectson" in Frame 6
onClipEvent (load) {
if (_parent.EFFECTS == true) {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
on (release, releaseOutside) {
i = 1;
while (i <= 30) {
_parent.starparticle.duplicateMovieClip("starparticle" + i, _parent.getNextHighestDepth());
i++;
}
_parent.EFFECTS = true;
_parent.effectsoff.gotoAndStop(1);
this.gotoAndStop(2);
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 6
onClipEvent (load) {
_x = _parent._xmouse;
_y = _parent._ymouse;
var xspeed = ((Math.random() * 10) - 5);
var yspeed = ((-(Math.random() * 10)) - 5);
var gravity = 1;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Instance of Symbol 176 MovieClip "saveoff" in Frame 6
onClipEvent (load) {
if (_parent.SAVE == false) {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
on (release, releaseOutside) {
_parent.SAVE = false;
this.gotoAndStop(2);
_parent.saveon.gotoAndStop(1);
}
Instance of Symbol 179 MovieClip "saveon" in Frame 6
onClipEvent (load) {
if (_parent.SAVE == true) {
this.gotoAndStop(2);
} else {
this.gotoAndStop(1);
}
}
on (release, releaseOutside) {
_parent.SAVE = true;
_parent.saveoff.gotoAndStop(1);
this.gotoAndStop(2);
}
Frame 7
missionbank = [8, 11, 14, 17, 20, 23, 26, 29, 32, 35, 38, 41];
i = 1;
while (i < 13) {
this["icon" + i].gotoAndStop(i);
this["icon" + i]._alpha = 80;
this["icon" + i].idnumber = i;
this["icon" + i].onRollOver = function () {
this._xscale = this._xscale + 30;
this._yscale = this._yscale + 30;
this._alpha = 100;
};
this["icon" + i].onRollOut = function () {
this._xscale = this._xscale - 30;
this._yscale = this._yscale - 30;
this._alpha = 80;
};
this["icon" + i].onRelease = function () {
playing_main_game = false;
nextmission = missionbank[this.idnumber - 1];
gotoAndPlay(nextmission);
};
this["score" + i] = levelhighscores[i - 1];
trace(goldcoincollected);
if (goldcoincollected[i - 1] != 1) {
this["gold" + i]._x = this["gold" + i]._x + 10000;
}
trace(goldcoincollected);
i++;
}
stopAllSounds();
delete beach_loop;
delete city_loop;
delete forest_loop;
delete menu_loop;
var menu_loop = new Sound();
menu_loop.attachSound("main_menu_loop");
menu_loop.start(0, 100);
stop();
Frame 8
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
stopAllSounds();
var city_loop = new Sound();
city_loop.attachSound("paper_bag");
city_loop.start(0, 100);
city_loop.setVolume(VOLUME);
stop();
Frame 9
var crate_collected = false;
invisi_target._visible = false;
var leveltime = 60;
var mish_num = 1;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Pick up the crate";
var items_score = 0;
var levelbonus = 100;
info.digit4.gotoAndStop(1);
info.digit5.gotoAndStop(11);
info.digit6.gotoAndStop(2);
stop();
Instance of Symbol 342 MovieClip in Frame 9
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
this.cacheAsBitmap = true;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 350 MovieClip "invisi_target" in Frame 9
onClipEvent (enterFrame) {
if ((_parent.playerwiggie._x < this._x) and (_parent.crate_collected == true)) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.mission_complete(1, 1, 1, 1, 100);
this._y = this._y + 10000;
}
}
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 9
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 9
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 367 MovieClip "crate" in Frame 9
onClipEvent (enterFrame) {
if (hitTest(_parent.playerwiggie)) {
_parent.crate_collected = true;
this._y = this._y + 10000;
_parent.stars(30);
_parent.info.missiontext.text = "Get back to the shop";
_parent.info.digit4.nextFrame();
}
}
Instance of Symbol 369 MovieClip in Frame 9
onClipEvent (load) {
var xspeed = -5;
var yspeed = 5;
var gravity = 1;
var defx = _x;
var defy = _y;
}
onClipEvent (enterFrame) {
yspeed = yspeed + gravity;
if (yspeed > 20) {
yspeed = 20;
}
_y = (_y + yspeed);
if (_parent.ground.solid.hitTest(_x, _y + 46, true)) {
if (yspeed > 0) {
yspeed = -yspeed;
}
}
_x = (_x + xspeed);
if (_x < (_parent.playerwiggie._x - 450)) {
_y = (_parent.playerwiggie._y - 400);
_x = (_parent.playerwiggie._x + 450);
yspeed = 5;
}
i = 0;
while (i <= 360) {
var xcheck = (Math.cos(i / 57.2957795130823) * 46);
var ycheck = (Math.sin(i / 57.2957795130823) * 46);
if (_parent.playerwiggie.hitTest(_x + xcheck, _y + ycheck, true)) {
_parent.playerwiggie.yspeed = ycheck / 5;
_parent.playerwiggie.canjump = false;
_parent.playerwiggie.climbing = false;
if (_parent.playerwiggie.facing == "right") {
_parent.playerwiggie.gotoAndStop(5);
} else {
_parent.playerwiggie.gotoAndStop(6);
}
}
var rpt = 0;
while (_parent.playerwiggie.hitTest(_x + xcheck, _y + ycheck, true) and (rpt <= 50)) {
if (xcheck != 0) {
_parent.playerwiggie._x = _parent.playerwiggie._x + (xcheck / 46);
} else {
_parent.playerwiggie._x = _parent.playerwiggie._x - 1;
}
rpt++;
}
i = i + 10;
}
_rotation = (_rotation - 10);
}
Instance of Symbol 371 MovieClip in Frame 9
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(_x, _y, true)) {
_parent.leveltime = _parent.leveltime + 30;
_parent.stars(30);
this.swapDepths(_parent.getNextHighestDepth());
this.removeMovieClip();
}
}
Instance of Symbol 315 MovieClip in Frame 9
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Frame 10
stop();
Instance of Symbol 430 MovieClip in Frame 10
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 11
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
var city_loop = new Sound();
city_loop.attachSound("paper_bag");
city_loop.start(0, 100);
city_loop.setVolume(VOLUME);
stop();
Frame 12
var carrying_litter = false;
var leveltime = 100;
var mish_num = 2;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Find some litter";
var items_score = 0;
var levelbonus = 200;
info.digit4.gotoAndStop(1);
info.digit5.gotoAndStop(11);
info.digit6.gotoAndStop(7);
i = 0;
while (i <= 6) {
this["litter" + i]._rotation = Math.random() * 360;
this["litter" + i].onEnterFrame = function () {
if (playerwiggie.hitTest(this)) {
if (carrying_litter == false) {
this._y = this._y + 10000;
info.missiontext.text = "Return to trash can";
carrying_litter = true;
stars(30);
this.onEnterFrame = null;
} else {
info.missiontext.text = "You are already holding litter";
}
}
};
i++;
}
trashcan.onEnterFrame = function () {
if (playerwiggie.hitTest(this._x, this._y, true)) {
if (carrying_litter == true) {
carrying_litter = false;
info.missiontext.text = "Find some litter";
info.digit4.nextFrame();
stars(30);
}
}
if (info.digit4._currentframe == 7) {
mission_complete(2, 1, 6, 6, 200);
}
};
stop();
Instance of Symbol 445 MovieClip in Frame 12
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 12
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 12
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
i = 1;
if (_parent.carrying_litter == true) {
_parent["pointer" + i]._visible = true;
_parent["pointer" + i]._x = _x;
_parent["pointer" + i]._y = _y;
xdiff = _parent.trashcan._x - _parent["pointer" + i]._x;
ydiff = _parent.trashcan._y - _parent["pointer" + i]._y;
_parent["pointer" + i]._rotation = (Math.atan2(ydiff, xdiff) * 57.2957795130823) + 180;
_parent["pointer" + i]._y = _parent["pointer" + i]._y - 40;
_parent["pointer" + i].gotoAndStop(4);
} else {
_parent["pointer" + i]._visible = false;
}
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 371 MovieClip in Frame 12
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(_x, _y, true)) {
_parent.leveltime = _parent.leveltime + 30;
_parent.stars(30);
this.swapDepths(_parent.getNextHighestDepth());
this.removeMovieClip();
}
}
Instance of Symbol 371 MovieClip in Frame 12
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(_x, _y, true)) {
_parent.leveltime = _parent.leveltime + 30;
_parent.stars(30);
this.swapDepths(_parent.getNextHighestDepth());
this.removeMovieClip();
}
}
Instance of Symbol 315 MovieClip in Frame 12
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Frame 13
stop();
Instance of Symbol 478 MovieClip in Frame 13
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 14
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
var city_loop = new Sound();
city_loop.attachSound("paper_bag");
city_loop.start(0, 100);
city_loop.setVolume(VOLUME);
stop();
Frame 15
invisible_target._visible = false;
var current_tool = "none";
var tools_array = ["green screwdriver", "red screwdriver", "blue screwdriver", "small wrench", "medium wrench", "large wrench", "two-toothed cog", "four-toothed cog", "eight-toothed cog"];
var requested_tool = tools_array[int(random(9))];
var leveltime = 120;
var mish_num = 3;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Get the " + requested_tool;
var items_score = 0;
var levelbonus = 200;
info.digit4.gotoAndStop(1);
info.digit5.gotoAndStop(11);
info.digit6.gotoAndStop(5);
i = 1;
while (i <= 9) {
this["tool" + i].id_num = i;
this["tool" + i].tool_name = tools_array[i - 1];
this["tool" + i].onEnterFrame = function () {
if (playerwiggie.hitTest(this)) {
if (current_tool == "none") {
current_tool = this.tool_name;
this._y = this._y + 10000;
info.missiontext.text = "Return to the mechanic";
stars(30);
} else {
info.missiontext.text = "You already have the " + current_tool;
}
}
};
i++;
}
invisible_target.onEnterFrame = function () {
if (playerwiggie.hitTest(this)) {
if (current_tool != "none") {
if (current_tool == requested_tool) {
i = 0;
while (i < tools_array.length) {
if (tools_array[i] == requested_tool) {
tools_array.splice(i, 1);
}
i++;
}
requested_tool = tools_array[int(random(tools_array.length))];
current_tool = "none";
info.missiontext.text = "Get the " + requested_tool;
info.digit4.nextFrame();
stars(30);
} else {
info.missiontext.text = "Wrong tool! Get the " + requested_tool;
i = 1;
while (i < 10) {
if (this._parent["tool" + i]._y > 1000) {
this._parent["tool" + i]._y = this._parent["tool" + i]._y - 10000;
}
i++;
}
current_tool = "none";
}
}
}
if (info.digit4._currentframe == 5) {
mission_complete(2, 1, 4, 4, 200);
} else if (leveltime <= 0) {
mission_complete(2, 1, 9 - tools_array.length, 4, 120 - ((tools_array.length - 5) * 30));
}
};
stop();
Instance of Symbol 489 MovieClip in Frame 15
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 15
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
i = 1;
if (_parent.current_tool != "none") {
_parent["pointer" + i]._visible = true;
_parent["pointer" + i]._x = _x;
_parent["pointer" + i]._y = _y;
xdiff = _parent.invisible_target._x - _parent["pointer" + i]._x;
ydiff = _parent.invisible_target._y - _parent["pointer" + i]._y;
_parent["pointer" + i]._rotation = (Math.atan2(ydiff, xdiff) * 57.2957795130823) + 180;
_parent["pointer" + i]._y = _parent["pointer" + i]._y - 40;
_parent["pointer" + i].gotoAndStop(5);
} else {
_parent["pointer" + i]._visible = false;
}
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 315 MovieClip in Frame 15
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Instance of Symbol 521 MovieClip "ground" in Frame 15
onClipEvent (load) {
this.cacheAsBitmap = true;
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 15
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Frame 16
stop();
Instance of Symbol 530 MovieClip in Frame 16
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 17
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
var city_loop = new Sound();
city_loop.attachSound("paper_bag");
city_loop.start(0, 100);
city_loop.setVolume(VOLUME);
stop();
Frame 18
var leveltime = 120;
var balloons_got = 0;
var mish_num = 4;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Get the balloons";
var items_score = 0;
var levelbonus = 200;
info.digit4.gotoAndStop(1);
info.digit5.gotoAndStop(1);
info.digit6.gotoAndStop(1);
i = 1;
while (i <= 11) {
this["balloon" + i].onEnterFrame = function () {
if (playerwiggie.hitTest(this)) {
playerwiggie.gravity = playerwiggie.gravity - 0.1;
this._x = this._x + 10000;
stars(30);
info.digit6.nextFrame();
if (info.digit6._currentframe == 11) {
info.digit6.gotoAndStop(1);
info.digit5.nextFrame();
}
balloons_got = balloons_got + 1;
if (balloons_got >= 10) {
mission_complete(2, 1, 10, 10, 200);
}
this.onEnterFrame = null;
}
};
i++;
}
stop();
Instance of Symbol 550 MovieClip in Frame 18
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 18
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
i = 1;
_parent["pointer" + i]._visible = true;
_parent["pointer" + i]._x = _x;
_parent["pointer" + i]._y = _y;
xdiff = _parent["balloon" + (_parent.balloons_got + 1)]._x - _parent["pointer" + i]._x;
ydiff = _parent["balloon" + (_parent.balloons_got + 1)]._y - _parent["pointer" + i]._y;
_parent["pointer" + i]._rotation = (Math.atan2(ydiff, xdiff) * 57.2957795130823) + 180;
_parent["pointer" + i]._y = _parent["pointer" + i]._y - 40;
_parent["pointer" + i].gotoAndStop(6);
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 315 MovieClip in Frame 18
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 18
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Frame 19
stop();
Instance of Symbol 571 MovieClip in Frame 19
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 20
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
stopAllSounds();
var forest_loop = new Sound();
forest_loop.attachSound("forest_lullaby");
forest_loop.start(0, 100);
forest_loop.setVolume(VOLUME);
stop();
Frame 21
var leveltime = 120;
var mish_num = 5;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Find the Scientist and the glasses";
var items_score = 0;
var levelbonus = 150;
info.digit4.gotoAndStop(1);
info.digit5.gotoAndStop(11);
info.digit6.gotoAndStop(3);
glasses.onEnterFrame = function () {
if (playerwiggie.hitTest(this._x, this._y, true)) {
this._x = this._x + 10000;
stars(30);
info.digit4.nextFrame();
info.missiontext.text = "Find the Scientist and get back out";
this.onEnterFrame = null;
}
};
invisible_target.onEnterFrame = function () {
if (playerwiggie._x < this._x) {
if (info.digit4._currentframe == 3) {
mission_complete(2, 1, 2, 2, 150);
}
}
};
stop();
Instance of Symbol 589 MovieClip in Frame 21
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 21
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
if (_y > 1600) {
yspeed = 0;
_x = -1300;
_y = 854;
_parent.info.missiontext.text = "Ouch! Back to the start!";
}
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 600 MovieClip in Frame 21
onClipEvent (load) {
var activated = false;
var prevx = new Array();
var prevy = new Array();
var prevf = new Array();
var delay = 25;
_parent.chatbubble._alpha = 0;
}
onClipEvent (enterFrame) {
if (activated == true) {
prevf.push(_parent.playerwiggie._currentframe);
prevx.push(_parent.playerwiggie._x);
prevy.push(_parent.playerwiggie._y);
if (prevy.length > delay) {
prevy.splice(0, 1);
prevx.splice(0, 1);
prevf.splice(0, 1);
}
_x = prevx[0];
_y = prevy[0];
gotoAndStop(prevf[0]);
_parent.chatbubble._alpha = _parent.chatbubble._alpha - 1;
_parent.chatbubble._x = _x;
_parent.chatbubble._y = _y;
} else if (_parent.playerwiggie.hitTest(_x, _y - 20, true)) {
activated = true;
_parent.stars(45);
_parent.info.digit4.nextFrame();
_parent.info.missiontext.text = "Find the glasses and get back out";
_parent.chatbubble._alpha = 100;
_parent.chatbubble._x = _x;
_parent.chatbubble._y = _y;
}
}
Instance of Symbol 371 MovieClip in Frame 21
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(_x, _y, true)) {
_parent.leveltime = _parent.leveltime + 30;
_parent.stars(30);
this.swapDepths(_parent.getNextHighestDepth());
this.removeMovieClip();
}
}
Instance of Symbol 315 MovieClip in Frame 21
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 21
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Frame 22
stop();
Instance of Symbol 633 MovieClip in Frame 22
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 23
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
stopAllSounds();
var forest_loop = new Sound();
forest_loop.attachSound("forest_lullaby");
forest_loop.start(0, 100);
forest_loop.setVolume(VOLUME);
stop();
Frame 24
var leveltime = 120;
var mish_num = 6;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "You're it! Catch someone!";
var items_score = 0;
var levelbonus = 150;
info.digit4.gotoAndStop(1);
info.digit5.gotoAndStop(1);
info.digit6.gotoAndStop(1);
var tagger = 4;
var prevtagger = 4;
var timer = 25;
onEnterFrame = function () {
timer--;
if (leveltime <= 0) {
mission_complete(2, 1, 6, 6, 200);
this.onEnterFrame = null;
}
};
stop();
Instance of Symbol 589 MovieClip in Frame 24
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 365 MovieClip "tagkid4" in Frame 24
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
if (_parent["tagkid" + _parent.tagger].hitTest(this) and (_parent.tagger != 4)) {
if (_parent.timer <= 0) {
_parent.prevtagger = _parent.tagger;
_parent.tagger = 4;
_parent.info.missiontext.text = "You've been tagged!";
_parent.timer = 25;
_parent.stars(30);
}
}
i = 1;
while (i < 4) {
_parent["pointer" + i]._x = _x;
_parent["pointer" + i]._y = _y;
xdiff = _parent["tagkid" + i]._x - _parent["pointer" + i]._x;
ydiff = _parent["tagkid" + i]._y - _parent["pointer" + i]._y;
_parent["pointer" + i]._rotation = (Math.atan2(ydiff, xdiff) * 57.2957795130823) + 180;
_parent["pointer" + i]._y = _parent["pointer" + i]._y - 40;
_parent["pointer" + i].gotoAndStop(i);
i++;
}
_parent.playerwiggie._x = _x;
_parent.playerwiggie._y = _y;
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 647 MovieClip "tagkid1" in Frame 24
onClipEvent (load) {
var xspeed = 14;
var yspeed = 0;
var gravity = 2;
var jumpspeed = 30;
var facing = "left";
}
onClipEvent (enterFrame) {
yspeed = yspeed + gravity;
_y = (_y + yspeed);
jumpspeed = (Math.random() * 20) + 20;
while (_parent.ground.hitTest(_x, _y, true)) {
_y = (_y - 0.5);
yspeed = 0;
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
if (facing == "right") {
_x = (_x + xspeed);
} else {
_x = (_x - xspeed);
}
while (_parent.ground.hitTest(_x, _y, true)) {
_y = (_y - 0.5);
yspeed = 0;
}
i = 1;
while (i < 12) {
if (this.hitTest(_parent["jumpright" + i]._x, _parent["jumpright" + i]._y, true)) {
if (_parent.ground.hitTest(_x, _y + 10, true)) {
yspeed = -jumpspeed;
facing = "right";
}
}
i++;
}
i = 1;
while (i < 13) {
if (this.hitTest(_parent["jumpleft" + i]._x, _parent["jumpleft" + i]._y, true)) {
if (_parent.ground.hitTest(_x, _y + 10, true)) {
yspeed = -jumpspeed;
facing = "left";
}
}
i++;
}
i = 1;
while (i < 5) {
if (this.hitTest(_parent["faceright" + i]._x, _parent["faceright" + i]._y, true)) {
facing = "right";
}
i++;
}
if (_x > 2650) {
facing = "left";
}
if (_x < -1050) {
facing = "right";
}
if (!_parent.ground.hitTest(_x, _y + 10, true)) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (_parent.tagger != 1) {
if ((_parent["tagkid" + _parent.tagger]._x > (_x - 200)) and (_parent["tagkid" + _parent.tagger]._x < (_x + 200))) {
if (_parent.ground.hitTest(_x, _y + 10, true)) {
yspeed = -jumpspeed;
}
}
if (_parent["tagkid" + _parent.tagger].hitTest(this)) {
if (_parent.timer <= 0) {
_parent.prevtagger = _parent.tagger;
_parent.tagger = 1;
_parent.info.missiontext.text = "Red has been tagged!";
_parent.timer = 25;
_parent.stars(30);
}
}
}
}
Instance of Symbol 655 MovieClip "tagkid2" in Frame 24
onClipEvent (load) {
var xspeed = 14;
var yspeed = 0;
var gravity = 2;
var jumpspeed = 30;
var facing = "right";
}
onClipEvent (enterFrame) {
yspeed = yspeed + gravity;
_y = (_y + yspeed);
jumpspeed = (Math.random() * 20) + 20;
while (_parent.ground.hitTest(_x, _y, true)) {
_y = (_y - 0.5);
yspeed = 0;
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
if (facing == "right") {
_x = (_x + xspeed);
} else {
_x = (_x - xspeed);
}
while (_parent.ground.hitTest(_x, _y, true)) {
_y = (_y - 0.5);
yspeed = 0;
}
i = 1;
while (i < 12) {
if (this.hitTest(_parent["jumpright" + i]._x, _parent["jumpright" + i]._y, true)) {
if (_parent.ground.hitTest(_x, _y + 10, true)) {
yspeed = -jumpspeed;
facing = "right";
}
}
i++;
}
i = 1;
while (i < 13) {
if (this.hitTest(_parent["jumpleft" + i]._x, _parent["jumpleft" + i]._y, true)) {
if (_parent.ground.hitTest(_x, _y + 10, true)) {
yspeed = -jumpspeed;
facing = "left";
}
}
i++;
}
i = 1;
while (i < 5) {
if (this.hitTest(_parent["faceright" + i]._x, _parent["faceright" + i]._y, true)) {
facing = "right";
}
i++;
}
if (_x > 2650) {
facing = "left";
}
if (_x < -1050) {
facing = "right";
}
if (!_parent.ground.hitTest(_x, _y + 10, true)) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (_parent.tagger != 2) {
if ((_parent["tagkid" + _parent.tagger]._x > (_x - 200)) and (_parent["tagkid" + _parent.tagger]._x < (_x + 200))) {
if (_parent.ground.hitTest(_x, _y + 10, true)) {
yspeed = -jumpspeed;
}
}
if (_parent["tagkid" + _parent.tagger].hitTest(this)) {
if (_parent.timer <= 0) {
_parent.prevtagger = _parent.tagger;
_parent.tagger = 2;
_parent.info.missiontext.text = "Yellow has been tagged!";
_parent.timer = 25;
_parent.stars(30);
}
}
}
}
Instance of Symbol 663 MovieClip "tagkid3" in Frame 24
onClipEvent (load) {
var xspeed = 14;
var yspeed = 0;
var gravity = 2;
var jumpspeed = 30;
var facing = "right";
}
onClipEvent (enterFrame) {
yspeed = yspeed + gravity;
_y = (_y + yspeed);
jumpspeed = (Math.random() * 20) + 20;
while (_parent.ground.hitTest(_x, _y, true)) {
_y = (_y - 0.5);
yspeed = 0;
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
if (facing == "right") {
_x = (_x + xspeed);
} else {
_x = (_x - xspeed);
}
while (_parent.ground.hitTest(_x, _y, true)) {
_y = (_y - 0.5);
yspeed = 0;
}
i = 1;
while (i < 12) {
if (this.hitTest(_parent["jumpright" + i]._x, _parent["jumpright" + i]._y, true)) {
if (_parent.ground.hitTest(_x, _y + 10, true)) {
yspeed = -jumpspeed;
facing = "right";
}
}
i++;
}
i = 1;
while (i < 13) {
if (this.hitTest(_parent["jumpleft" + i]._x, _parent["jumpleft" + i]._y, true)) {
if (_parent.ground.hitTest(_x, _y + 10, true)) {
yspeed = -jumpspeed;
facing = "left";
}
}
i++;
}
i = 1;
while (i < 5) {
if (this.hitTest(_parent["faceright" + i]._x, _parent["faceright" + i]._y, true)) {
facing = "right";
}
i++;
}
if (_x > 2650) {
facing = "left";
}
if (_x < -1050) {
facing = "right";
}
if (!_parent.ground.hitTest(_x, _y + 10, true)) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (_parent.tagger != 3) {
if ((_parent["tagkid" + _parent.tagger]._x > (_x - 200)) and (_parent["tagkid" + _parent.tagger]._x < (_x + 200))) {
if (_parent.ground.hitTest(_x, _y + 10, true)) {
yspeed = -jumpspeed;
}
}
if (_parent["tagkid" + _parent.tagger].hitTest(this)) {
if (_parent.timer <= 0) {
_parent.prevtagger = _parent.tagger;
_parent.tagger = 3;
_parent.info.missiontext.text = "Brown has been tagged!";
_parent.timer = 25;
_parent.stars(30);
}
}
}
}
Instance of Symbol 315 MovieClip in Frame 24
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.tagkid4.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 24
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
trace("cocks");
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Frame 25
stop();
Instance of Symbol 677 MovieClip in Frame 25
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 26
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
stopAllSounds();
var forest_loop = new Sound();
forest_loop.attachSound("forest_lullaby");
forest_loop.start(0, 100);
forest_loop.setVolume(VOLUME);
stop();
Frame 27
var leveltime = 120;
var mish_num = 7;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Squish all the crawler plants";
var items_score = 0;
var levelbonus = 200;
info.digit4.gotoAndStop(6);
info.digit5.gotoAndStop(11);
info.digit6.gotoAndStop(6);
i = 1;
while (i <= 5) {
this["crawler" + i].onEnterFrame = function () {
if (this.active == true) {
if (playerwiggie.hitTest(this._x, this._y - 40, true) and (playerwiggie.yspeed > 10)) {
this.play();
this.active = false;
stars(30);
info.digit4.nextFrame();
if (info.digit4._currentframe >= 6) {
mission_complete(2, 1, 5, 5, 200);
}
}
}
};
i++;
}
stop();
Instance of Symbol 589 MovieClip in Frame 27
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 27
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
i = 1;
while (i < 6) {
if (_parent["crawler" + i].active == true) {
_parent["pointer" + i]._visible = true;
_parent["pointer" + i]._x = _x;
_parent["pointer" + i]._y = _y;
xdiff = _parent["crawler" + i]._x - _parent["pointer" + i]._x;
ydiff = _parent["crawler" + i]._y - _parent["pointer" + i]._y;
_parent["pointer" + i]._rotation = (Math.atan2(ydiff, xdiff) * 57.2957795130823) + 180;
_parent["pointer" + i]._y = _parent["pointer" + i]._y - 40;
_parent["pointer" + i].gotoAndStop(7);
} else {
_parent["pointer" + i]._visible = false;
}
i++;
}
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 706 MovieClip in Frame 27
onClipEvent (enterFrame) {
if ((_parent.crawler1.active == true) and (_parent.crawler2.active == true)) {
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
} else if (_alpha > 0) {
_alpha = (_alpha - 2);
}
}
Instance of Symbol 708 MovieClip in Frame 27
onClipEvent (enterFrame) {
if ((_parent.crawler1.active == true) and (_parent.crawler5.active == true)) {
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
} else if (_alpha > 0) {
_alpha = (_alpha - 2);
}
}
Instance of Symbol 710 MovieClip in Frame 27
onClipEvent (enterFrame) {
if ((_parent.crawler1.active == true) and (_parent.crawler4.active == true)) {
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
} else if (_alpha > 0) {
_alpha = (_alpha - 2);
}
}
Instance of Symbol 712 MovieClip in Frame 27
onClipEvent (enterFrame) {
if ((_parent.crawler1.active == true) and (_parent.crawler3.active == true)) {
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
} else if (_alpha > 0) {
_alpha = (_alpha - 2);
}
}
Instance of Symbol 714 MovieClip in Frame 27
onClipEvent (enterFrame) {
if ((_parent.crawler5.active == true) and (_parent.crawler2.active == true)) {
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
} else if (_alpha > 0) {
_alpha = (_alpha - 2);
}
}
Instance of Symbol 716 MovieClip in Frame 27
onClipEvent (enterFrame) {
if ((_parent.crawler3.active == true) and (_parent.crawler2.active == true)) {
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
} else if (_alpha > 0) {
_alpha = (_alpha - 2);
}
}
Instance of Symbol 718 MovieClip in Frame 27
onClipEvent (enterFrame) {
if ((_parent.crawler4.active == true) and (_parent.crawler2.active == true)) {
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
} else if (_alpha > 0) {
_alpha = (_alpha - 2);
}
}
Instance of Symbol 720 MovieClip in Frame 27
onClipEvent (enterFrame) {
if ((_parent.crawler3.active == true) and (_parent.crawler5.active == true)) {
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
} else if (_alpha > 0) {
_alpha = (_alpha - 2);
}
}
Instance of Symbol 722 MovieClip in Frame 27
onClipEvent (enterFrame) {
if ((_parent.crawler4.active == true) and (_parent.crawler5.active == true)) {
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
} else if (_alpha > 0) {
_alpha = (_alpha - 2);
}
}
Instance of Symbol 724 MovieClip in Frame 27
onClipEvent (enterFrame) {
if ((_parent.crawler3.active == true) and (_parent.crawler4.active == true)) {
if (_alpha < 100) {
_alpha = (_alpha + 2);
}
} else if (_alpha > 0) {
_alpha = (_alpha - 2);
}
}
Instance of Symbol 371 MovieClip in Frame 27
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(_x, _y, true)) {
_parent.leveltime = _parent.leveltime + 30;
_parent.stars(30);
this.swapDepths(_parent.getNextHighestDepth());
this.removeMovieClip();
}
}
Instance of Symbol 315 MovieClip in Frame 27
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 27
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
trace("star spawned");
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Frame 28
stop();
Instance of Symbol 731 MovieClip in Frame 28
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 29
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
stopAllSounds();
var forest_loop = new Sound();
forest_loop.attachSound("forest_lullaby");
forest_loop.start(0, 100);
forest_loop.setVolume(VOLUME);
stop();
Frame 30
var leveltime = 90;
var mish_num = 8;
var butterflies_got = 0;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Catch all the butterflies";
var items_score = 0;
var levelbonus = 100;
info.digit4.gotoAndStop(1);
info.digit5.gotoAndStop(11);
info.digit6.gotoAndStop(5);
i = 0;
while (i <= 4) {
this["bug" + i].onEnterFrame = function () {
if (playerwiggie.hitTest(this)) {
this._y = this._y + 10000;
stars(30);
info.digit4.nextFrame();
butterflies_got = butterflies_got + 1;
if (butterflies_got >= 4) {
mission_complete(2, 1, 5, 5, 100);
}
}
};
i++;
}
stop();
Instance of Symbol 589 MovieClip in Frame 30
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 30
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
if (_y > 1600) {
yspeed = 0;
_x = -1300;
_y = 854;
_parent.info.missiontext.text = "Ouch! Back to the start!";
}
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 315 MovieClip in Frame 30
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 30
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
trace("star spawned");
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Frame 31
stop();
Instance of Symbol 771 MovieClip in Frame 31
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 32
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
stopAllSounds();
var forest_loop = new Sound();
forest_loop.attachSound("forest_lullaby");
forest_loop.start(0, 100);
forest_loop.setVolume(VOLUME);
stop();
Frame 33
var jumpy_points = 0;
var leveltime = 60;
var mish_num = 9;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Catch Jumpy";
var items_score = 0;
var levelbonus = 100;
info.digit4.gotoAndStop(1);
info.digit5.gotoAndStop(11);
info.digit6.gotoAndStop(2);
var levelspeed = 5;
var delay = 60;
var timer = 0;
onEnterFrame = function () {
timer--;
if (timer <= 0) {
if (Math.random() > 0.5) {
ground.solid.branch1.duplicateMovieClip("dupbranch" + ground.solid.getNextHighestDepth(), ground.solid.getNextHighestDepth());
} else {
ground.solid.branch2.duplicateMovieClip("dupbranch" + ground.solid.getNextHighestDepth(), ground.solid.getNextHighestDepth());
}
timer = delay;
}
if (timer == Math.floor(delay / 2)) {
if (Math.random() > 0.5) {
if (Math.random() > 0.5) {
ground.solid.branch3.duplicateMovieClip("dupbranch" + ground.solid.getNextHighestDepth(), ground.solid.getNextHighestDepth());
} else {
ground.solid.branch5.duplicateMovieClip("dupbranch" + ground.solid.getNextHighestDepth(), ground.solid.getNextHighestDepth());
}
} else if (Math.random() > 0.5) {
ground.solid.branch4.duplicateMovieClip("dupbranch" + ground.solid.getNextHighestDepth(), ground.solid.getNextHighestDepth());
} else {
ground.solid.branch6.duplicateMovieClip("dupbranch" + ground.solid.getNextHighestDepth(), ground.solid.getNextHighestDepth());
}
}
if (playerwiggie._y < 400) {
jumpy_points = jumpy_points + 2;
} else {
jumpy_points = jumpy_points + 1;
}
if (jumpy_points < 0) {
jumpy_points = 0;
}
if (leveltime <= 0) {
levelbonus = 100;
mission_complete(2, 1, 0, 1, 0);
this.onEnterFrame = null;
}
};
stop();
Instance of Symbol 786 MovieClip in Frame 33
onClipEvent (enterFrame) {
_y = (_y + (_parent.levelspeed / 10));
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 33
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = 0;
_parent._y = 0;
_parent.info._y = 300;
_parent.info._x = 400;
_parent.info.swapDepths(_parent.getNextHighestDepth);
if (_y > 700) {
yspeed = -40;
if (Math.random() > 0.5) {
_x = 202.9;
} else {
_x = 566.9;
}
_y = 680;
_parent.jumpy_points = _parent.jumpy_points - 100;
_parent.info.missiontext.text = "Whoa, careful! Back up you go!";
}
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 810 MovieClip in Frame 33
onClipEvent (load) {
this.stop();
}
onClipEvent (enterFrame) {
_y = (_y + _parent.levelspeed);
if ((_y - _parent.playerwiggie._y) < (300 - (_parent.jumpy_points / 2))) {
this.gotoAndStop(2);
}
if ((_parent.playerwiggie.hitTest(_x, _y, false) and (_parent.jumpy_points > 500)) and (this._visible == true)) {
_parent.stars(30);
_parent.mission_complete(2, 1, 1, 1, 200);
this._visible = false;
}
}
Frame 34
stop();
Instance of Symbol 815 MovieClip in Frame 34
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 35
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
stopAllSounds();
var beach_loop = new Sound();
beach_loop.attachSound("aqua_slug");
beach_loop.start(0, 100);
beach_loop.setVolume(VOLUME);
stop();
Frame 36
var leveltime = 90;
var mish_num = 10;
var ballscaught = 0;
var ballsthrown = 0;
var active_ball = "catchball1";
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Catch 15 balls";
var items_score = 0;
var levelbonus = 200;
info.digit4.gotoAndStop(12);
info.digit5.gotoAndStop(1);
info.digit6.gotoAndStop(1);
onEnterFrame = function () {
trace(active_ball);
info.digit5.gotoAndStop((ballscaught - (ballscaught % 10)) + 1);
info.digit6.gotoAndStop((ballscaught % 10) + 1);
if (ballscaught >= 15) {
mission_complete(2, 1, ballscaught, ballsthrown, 200);
this.onEnterFrame = null;
} else if (leveltime <= 0) {
mission_complete(2, 1, ballscaught, ballsthrown, 200);
levelbonus = levelbonus - ((15 - ballscaught) * 10);
this.onEnterFrame = null;
}
};
stop();
Instance of Symbol 826 MovieClip in Frame 36
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 36
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
while (_x > 700) {
_x = (_x - 1);
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
i = 1;
_parent["pointer" + i]._visible = true;
_parent["pointer" + i]._x = _x;
_parent["pointer" + i]._y = _y;
xdiff = _parent[_parent.active_ball]._x - _parent["pointer" + i]._x;
ydiff = _parent[_parent.active_ball]._y - _parent["pointer" + i]._y;
_parent["pointer" + i]._rotation = (Math.atan2(ydiff, xdiff) * 57.2957795130823) + 180;
_parent["pointer" + i]._y = _parent["pointer" + i]._y - 40;
_parent["pointer" + i].gotoAndStop(3);
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 315 MovieClip in Frame 36
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Instance of Symbol 858 MovieClip "catchball" in Frame 36
onClipEvent (load) {
var angle = (random(60) + 190);
var power = (random(10) + 15);
var xspeed = (Math.sin(angle / (Math.PI/180)) * power);
var yspeed = (Math.cos(angle / (Math.PI/180)) * power);
if (xspeed > 0) {
xspeed = xspeed * -1;
}
var gravity = 0.5;
_rotation = random(360);
var rotspeed = (random(20) - 10);
var timer = 250;
_y = (_y - random(400));
_parent.active_ball = this._name;
if (_name == "catchball") {
var dup = 1;
this.duplicateMovieClip("catchball" + dup, _parent.getNextHighestDepth());
dup++;
} else {
_parent.ballsthrown = _parent.ballsthrown + 1;
}
}
onClipEvent (enterFrame) {
if (_name != "catchball") {
timer--;
if (timer <= 25) {
_alpha = (_alpha - 4);
}
if (timer <= 0) {
_parent.catchball.duplicateMovieClip("catchball" + _parent.catchball.dup, _parent.getNextHighestDepth());
_parent.catchball.dup++;
this.removeMovieClip();
}
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_rotation = (_rotation + rotspeed);
while (_parent.ground.hitTest(_x, _y + 15, true) or (_y > 500)) {
if (yspeed > 0) {
yspeed = yspeed * -1;
}
_y = (_y - 1);
}
while (_parent.ground.hitTest(_x, _y - 15, true)) {
if (yspeed < 0) {
yspeed = yspeed * -1;
}
_y = (_y + 1);
}
while (_parent.ground.hitTest(_x - 15, _y, true)) {
if (xspeed < 0) {
xspeed = xspeed * -1;
}
_x = (_x + 1);
}
if (_parent.playerwiggie.hitTest(this)) {
_parent.stars(30);
_parent.ballscaught = _parent.ballscaught + 1;
_parent.catchball.duplicateMovieClip("catchball" + _parent.catchball.dup, _parent.getNextHighestDepth());
_parent.catchball.dup++;
this.removeMovieClip();
}
if (_parent.info._currentframe != 1) {
this.removeMovieClip();
}
}
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 36
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
trace("star spawned");
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Frame 37
stop();
Instance of Symbol 864 MovieClip in Frame 37
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 38
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
stopAllSounds();
var beach_loop = new Sound();
beach_loop.attachSound("aqua_slug");
beach_loop.start(0, 100);
beach_loop.setVolume(VOLUME);
stop();
Frame 39
var leveltime = 150;
var mish_num = 11;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Find the buried treasures";
var items_score = 0;
var levelbonus = 250;
info.digit4.gotoAndStop(1);
info.digit5.gotoAndStop(11);
info.digit6.gotoAndStop(6);
i = 0;
while (i <= 5) {
this["treasure" + i]._visible = false;
this["treasure" + i].collected = false;
this["treasure" + i].onEnterFrame = function () {
if ((playerwiggie.hitTest(this) and (playerwiggie.yspeed > 0)) and (this.collected == false)) {
this.collected = true;
this._visible = true;
stars(30);
info.digit4.nextFrame();
}
if (this.collected == true) {
this._alpha = this._alpha - 2;
if (this._alpha <= 0) {
this._y = this._y + 1000000;
this.onEnterFrame = null;
}
}
};
i++;
}
var totaldistances = 0;
onEnterFrame = function () {
var _local3 = 10000;
var _local2 = 0;
i = 1;
while (i <= 5) {
_local2 = Math.sqrt(Math.pow(this["treasure" + i]._x - playerwiggie._x, 2) + Math.pow(this["treasure" + i]._y - playerwiggie._y, 2));
if (_local2 < _local3) {
_local3 = _local2;
}
i++;
}
trace(_local3);
if (_local3 < 1000) {
totaldistances = totaldistances + (100 - (_local3 / 10));
}
if (totaldistances > 300) {
redlight.play();
totaldistances = totaldistances - 300;
}
if (info.digit4._currentframe >= 6) {
mission_complete(2, 1, 5, 5, 100);
redlight._visible = false;
onEnterFrame = null;
}
};
stop();
Instance of Symbol 826 MovieClip in Frame 39
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 39
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
_parent.redlight._x = _x + 343;
_parent.redlight._y = _y - 270.5;
_parent.redlight.swapDepths(_parent.getNextHighestDepth);
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 315 MovieClip in Frame 39
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 39
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
trace("star spawned");
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Frame 40
stop();
Instance of Symbol 903 MovieClip in Frame 40
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 41
stopAllSounds();
delete city_loop;
delete forest_loop;
delete beach_loop;
delete menu_loop;
stopAllSounds();
var beach_loop = new Sound();
beach_loop.attachSound("aqua_slug");
beach_loop.start(0, 100);
beach_loop.setVolume(VOLUME);
stop();
Frame 42
var leveltime = 60;
var mish_num = 12;
info.interface_icon.gotoAndStop(mish_num);
info.missiontext.text = "Give away the ice-creams before they melt";
var items_score = 0;
var levelbonus = 100;
info.digit4.gotoAndStop(1);
info.digit5.gotoAndStop(11);
info.digit6.gotoAndStop(4);
i = 0;
while (i <= 3) {
this["wiggie" + i].gotoAndStop(1);
this["wiggie" + i].onEnterFrame = function () {
if (playerwiggie.hitTest(this._x, this._y, true)) {
if (this._currentframe == 1) {
this.gotoAndStop(2);
stars(30);
info.digit4.nextFrame();
if (info.digit4._currentframe >= 4) {
mission_complete(2, 1, 3, 3, 100);
}
}
}
};
i++;
}
this.onEnterFrame = function () {
if (leveltime < 30) {
info.missiontext.text = "Hurry, before the ice-cream melts!";
}
if (leveltime < 10) {
info.missiontext.text = "It's almost all melted now!";
}
if (leveltime <= 0) {
info.missiontext.text = "The ice-cream melted...";
mission_complete(2, 1, info.digit4._currentframe - 1, 3, 100);
levelbonus = 0;
}
};
stop();
Instance of Symbol 826 MovieClip in Frame 42
onClipEvent (load) {
xdiff = _x - _parent._x;
ydiff = _y - _parent._y;
xdef = _x;
ydef = _y;
}
onClipEvent (enterFrame) {
_x = ((xdiff - _parent._x) - ((_x - xdef) / 10));
_y = ((ydiff - _parent._y) - ((_y - ydef) / 10));
}
Instance of Symbol 365 MovieClip "playerwiggie" in Frame 42
onClipEvent (load) {
var xspeed = 12;
var ground = "ground";
var yspeed = 0;
var gravity = 2;
var canjump = false;
var jump = 30;
var xchanged = false;
var maxspeed = 30;
gotoAndStop (1);
var jumppressed = true;
var climbing = false;
var WIDTH = 50;
var HEIGHT = 80;
var climbspeed = 6;
var facing = "left";
}
onClipEvent (enterFrame) {
if (climbing == false) {
xchanged = false;
if (Key.isDown(39)) {
_x = (_x + xspeed);
xchanged = true;
facing = "right";
}
if (Key.isDown(37)) {
_x = (_x - xspeed);
xchanged = true;
facing = "left";
}
if ((xchanged == false) and (canjump == true)) {
if ((_currentframe == 4) or (_currentframe == 6)) {
gotoAndStop (2);
}
if ((_currentframe == 3) or (_currentframe == 5)) {
gotoAndStop (1);
}
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x - 0.1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - (HEIGHT / 2), true)) {
_x = (_x + 0.1);
}
yspeed = yspeed + gravity;
_y = (_y + yspeed);
canjump = false;
while (_parent[ground].hitTest(_x, _y, true)) {
_y = (_y - gravity);
yspeed = 0;
canjump = true;
if (xchanged == true) {
if (facing == "right") {
gotoAndStop (3);
} else {
gotoAndStop (4);
}
}
}
if (_parent[ground].hitTest(_x, _y + 10, true)) {
canjump = true;
}
while (_parent[ground].solid.hitTest(_x, _y - HEIGHT, true)) {
_y = (_y + gravity);
yspeed = 0;
}
if (Key.isDown(38)) {
if (_parent.ladder.hitTest(_x, _y - (HEIGHT / 2), true)) {
climbing = true;
yspeed = 0;
}
}
if (Key.isDown(40)) {
if (_parent.ladder.hitTest(_x, _y + 5, true)) {
climbing = true;
yspeed = 0;
}
}
} else {
yspeed = 0;
if (Key.isDown(38)) {
_y = (_y - climbspeed);
}
if (Key.isDown(40)) {
_y = (_y + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_y = (_y + 1);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true)) {
_y = (_y - 1);
}
if (Key.isDown(37)) {
_x = (_x - climbspeed);
}
if (Key.isDown(39)) {
_x = (_x + climbspeed);
}
while (_parent[ground].solid.hitTest(_x - (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x - (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x + 0.5);
}
while (_parent[ground].solid.hitTest(_x + (WIDTH / 2), _y, true) or _parent[ground].solid.hitTest(_x + (WIDTH / 2), _y - HEIGHT, true)) {
_x = (_x - 0.5);
}
if (!_parent.ladder.hitTest(_x, _y, true)) {
climbing = false;
}
gotoAndStop (7);
}
if (canjump == false) {
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
if (Key.isDown(32)) {
if (jumppressed == false) {
if (canjump == true) {
yspeed = -jump;
canjump = false;
climbing = false;
if (facing == "right") {
gotoAndStop (5);
} else {
gotoAndStop (6);
}
}
}
jumppressed = true;
} else {
jumppressed = false;
}
if (yspeed > maxspeed) {
yspeed = maxspeed;
}
_parent._x = (Stage.width / 2) - _x;
_parent._y = (Stage.height / 2) - _y;
_parent.info._y = _y;
_parent.info._x = _x;
_parent.info.swapDepths(_parent.getNextHighestDepth);
}
onClipEvent (unload) {
_parent._x = 0;
_parent._y = 0;
}
Instance of Symbol 315 MovieClip in Frame 42
onClipEvent (load) {
_parent.thiscoincollected = false;
}
onClipEvent (enterFrame) {
if (_parent.playerwiggie.hitTest(this)) {
_parent.thiscoincollected = true;
_parent.stars(60);
_y = (_y + 10000);
}
}
Instance of Symbol 183 MovieClip "starparticle" in Frame 42
onClipEvent (load) {
_x = _parent.playerwiggie._x;
_y = (_parent.playerwiggie._y - 40);
var xspeed = ((Math.random() * 3) - 1.5);
var yspeed = ((-(Math.random() * 5)) - 3);
var gravity = 0.5;
var fade = 3;
gotoAndPlay(int(random(7) + 1));
trace("star spawned");
}
onClipEvent (enterFrame) {
if (_name == "starparticle") {
_visible = false;
} else {
yspeed = yspeed + gravity;
_x = (_x + xspeed);
_y = (_y + yspeed);
_alpha = (_alpha - fade);
_rotation = (Math.random() * 360);
if (_alpha <= 0) {
this.removeMovieClip();
}
}
}
Frame 43
stop();
Instance of Symbol 944 MovieClip in Frame 43
onClipEvent (unload) {
_parent.gotoAndPlay(_parent.nextmission);
}
Frame 44
_root.WPI_ArcadeStopSingleGame(gametotal);
gamescoretext.text = gametotal;
var tempscore = gametotal;
gamescore = 0;
beach_loop.stop();
city_loop.stop();
forest_loop.stop();
menu_loop.stop();
stop();
Instance of Symbol 952 MovieClip in Frame 44
onClipEvent (load) {
stop();
}
on (release) {
if (_currentframe == 1) {
mynamevar = _parent.nametext.text;
ab20_09 = new LoadVars();
ab20_09.z = mynamevar;
ab20_09.x = _parent.tempscore;
ab20_09.c = 1532;
ab20_09.v = "HZBQPQ";
ab20_09.sendAndLoad("http://armorbot.com/s_b", ab20_09, "POST");
nextFrame();
} else {
_parent.getURL("http://www.armorbot.com/mytable/?id=1532", "_blank");
}
}
Symbol 22 MovieClip Frame 17
gotoAndPlay (15);
Symbol 23 Button
on (release) {
getURL ("http://www.wiggiworld.com", "_blank");
}
Symbol 32 MovieClip Frame 15
stop();
Symbol 34 Button
on (release) {
_root.gotoAndPlay("start");
}
Symbol 48 MovieClip Frame 1
stop();
this.onEnterFrame = function () {
bl = _root.getBytesLoaded();
bt = _root.getBytesTotal();
perc = (bl / bt) * 100;
bar.bar._xscale = perc;
if (perc >= 100) {
this.gotoAndPlay("goplay");
delete this.onEnterFrame;
}
};
Symbol 48 MovieClip Frame 25
stop();
Symbol 57 MovieClip Frame 12
stop();
Symbol 61 MovieClip Frame 13
stop();
Symbol 64 MovieClip Frame 12
stop();
Symbol 66 MovieClip Frame 202
_parent.play();
stop();
Symbol 72 MovieClip Frame 1
stop();
Symbol 75 Button
on (release) {
gotoAndPlay (3);
}
Symbol 82 Button
on (release) {
var missionbank = new Array();
missionbank = [8, 11, 14, 17, 20, 23, 26, 29, 32, 35, 38, 41];
menu_loop.stop();
playing_main_game = true;
var gametotal = 0;
var missionsleft = 4;
_root.WPI_ArcadeStartSingleGame();
gotoAndPlay(missionbank[int(random(missionbank.length))]);
}
Symbol 86 Button
on (release) {
gotoAndPlay ("instructions");
}
Symbol 89 Button
on (release) {
gotoAndPlay ("credits");
}
Symbol 96 Button
on (release) {
gotoAndPlay ("settings");
}
Symbol 100 Button
on (release) {
gotoAndPlay ("mission_select");
}
Symbol 121 MovieClip Frame 70
stop();
Symbol 125 Button
on (release) {
gotoAndPlay ("main_menu");
}
Instance of Symbol 159 MovieClip in Symbol 162 MovieClip Frame 1
on (press) {
startDrag (this, true, 1, -30, 400, -30);
}
on (release, releaseOutside) {
stopDrag();
}
onClipEvent (enterFrame) {
_parent.gotoAndStop(Math.ceil(_x) + 1);
_parent._parent.VOLUME = _x / 4;
_parent._parent.menu_loop.setVolume(_parent._parent.VOLUME);
_parent._parent.city_loop.setVolume(_parent._parent.VOLUME);
_parent._parent.forest_loop.setVolume(_parent._parent.VOLUME);
_parent._parent.beach_loop.setVolume(_parent._parent.VOLUME);
}
Symbol 167 MovieClip Frame 1
stop();
Symbol 170 MovieClip Frame 1
stop();
Symbol 173 MovieClip Frame 1
stop();
Symbol 176 MovieClip Frame 1
stop();
Symbol 179 MovieClip Frame 1
stop();
Symbol 261 MovieClip Frame 1
blahblah = 0;
i = 0;
while (i < _parent.goldcoincollected.length) {
if (_parent.goldcoincollected[i] == 1) {
blahblah++;
}
i++;
}
if (blahblah >= 11) {
this.play();
} else {
this.stop();
}
Symbol 261 MovieClip Frame 2
stop();
Instance of Symbol 199 MovieClip in Symbol 261 MovieClip Frame 2
onClipEvent (load) {
stop();
}
on (press) {
this.startDrag(false);
blahx = _x;
blahy = _y;
}
on (release, releaseOutside) {
this.stopDrag();
if ((blahx == _x) and (blahy == _y)) {
if (_currentframe < 10) {
this.nextFrame();
} else {
this.gotoAndStop(1);
}
}
}
Instance of Symbol 199 MovieClip in Symbol 261 MovieClip Frame 2
onClipEvent (load) {
stop();
}
on (press) {
this.startDrag(false);
blahx = _x;
blahy = _y;
}
on (release, releaseOutside) {
this.stopDrag();
if ((blahx == _x) and (blahy == _y)) {
if (_currentframe < 10) {
this.nextFrame();
} else {
this.gotoAndStop(1);
}
}
}
Instance of Symbol 212 MovieClip "bodies" in Symbol 261 MovieClip Frame 2
onClipEvent (load) {
stop();
}
on (press) {
this.startDrag(false);
blahx = _x;
blahy = _y;
}
on (release, releaseOutside) {
this.stopDrag();
if ((blahx == _x) and (blahy == _y)) {
if (_currentframe < 12) {
this.nextFrame();
} else {
this.gotoAndStop(1);
}
}
}
Instance of Symbol 222 MovieClip in Symbol 261 MovieClip Frame 2
onClipEvent (load) {
stop();
}
on (press) {
this.startDrag(false);
blahx = _x;
blahy = _y;
}
on (release, releaseOutside) {
this.stopDrag();
if ((blahx == _x) and (blahy == _y)) {
if (_currentframe < 9) {
this.nextFrame();
} else {
this.gotoAndStop(1);
}
}
}
Instance of Symbol 234 MovieClip "eyes" in Symbol 261 MovieClip Frame 2
onClipEvent (load) {
stop();
}
on (press) {
this.startDrag(false);
blahx = _x;
blahy = _y;
}
on (release, releaseOutside) {
this.stopDrag();
if ((blahx == _x) and (blahy == _y)) {
if (_currentframe < 11) {
this.nextFrame();
} else {
this.gotoAndStop(1);
}
}
}
Instance of Symbol 247 MovieClip "eyebrow_left" in Symbol 261 MovieClip Frame 2
onClipEvent (load) {
stop();
}
on (press) {
this.startDrag(false);
blahx = _x;
blahy = _y;
}
on (release, releaseOutside) {
this.stopDrag();
if ((blahx == _x) and (blahy == _y)) {
if (_currentframe < 12) {
this.nextFrame();
} else {
this.gotoAndStop(1);
}
}
}
Instance of Symbol 247 MovieClip "eyebrow_right" in Symbol 261 MovieClip Frame 2
onClipEvent (load) {
stop();
}
on (press) {
this.startDrag(false);
blahx = _x;
blahy = _y;
}
on (release, releaseOutside) {
this.stopDrag();
if ((blahx == _x) and (blahy == _y)) {
if (_currentframe < 12) {
this.nextFrame();
} else {
this.gotoAndStop(1);
}
}
}
Instance of Symbol 260 MovieClip in Symbol 261 MovieClip Frame 2
onClipEvent (load) {
stop();
}
on (press) {
this.startDrag(false);
blahx = _x;
blahy = _y;
}
on (release, releaseOutside) {
this.stopDrag();
if ((blahx == _x) and (blahy == _y)) {
if (_currentframe < 12) {
this.nextFrame();
} else {
this.gotoAndStop(1);
}
}
}
Instance of Symbol 260 MovieClip in Symbol 261 MovieClip Frame 2
onClipEvent (load) {
stop();
}
on (press) {
this.startDrag(false);
blahx = _x;
blahy = _y;
}
on (release, releaseOutside) {
this.stopDrag();
if ((blahx == _x) and (blahy == _y)) {
if (_currentframe < 12) {
this.nextFrame();
} else {
this.gotoAndStop(1);
}
}
}
Symbol 334 Button
on (release) {
if (_currentframe == 41) {
_parent.play();
} else {
play();
}
}
Symbol 339 MovieClip Frame 30
stop();
Symbol 339 MovieClip Frame 31
stop();
Symbol 339 MovieClip Frame 36
stop();
Symbol 339 MovieClip Frame 41
stop();
Symbol 357 MovieClip Frame 25
gotoAndPlay (2);
Symbol 358 MovieClip Frame 25
gotoAndPlay (2);
Symbol 359 MovieClip Frame 27
gotoAndPlay (13);
Symbol 360 MovieClip Frame 45
stop();
Symbol 364 MovieClip Frame 19
gotoAndPlay (2);
Instance of Symbol 359 MovieClip in Symbol 365 MovieClip Frame 3
onClipEvent (enterFrame) {
if (Math.random() > 0.5) {
_parent._parent.dust(_parent._x, _parent._y);
}
}
Instance of Symbol 364 MovieClip in Symbol 365 MovieClip Frame 7
onClipEvent (enterFrame) {
if (((Key.isDown(38) or Key.isDown(40)) or Key.isDown(37)) or Key.isDown(39)) {
this.play();
} else {
this.stop();
}
}
Symbol 403 MovieClip Frame 1
stop();
Symbol 417 Button
on (release) {
if (_parent.playing_main_game == true) {
i = 0;
while (i < _parent.missionbank.length) {
if (_parent.missionbank[i] == (_parent._currentframe - 1)) {
_parent.missionbank.splice(i, 1);
}
i++;
}
randomnumber = int(random(_parent.missionbank.length));
_parent.missionsleft--;
if (_parent.missionsleft > 0) {
_parent.nextmission = _parent.missionbank[randomnumber];
} else {
_parent.nextmission = 44;
}
_parent.play();
} else {
_parent.nextmission = 7;
_parent.play();
}
}
Symbol 419 MovieClip Frame 20
stop();
Symbol 421 MovieClip Frame 1
stop();
Instance of Symbol 371 MovieClip in Symbol 421 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_parent._currentframe == 1) {
_parent._parent.leveltime = _parent._parent.leveltime - 0.04;
_parent.digit1.gotoAndStop(Math.ceil(_parent._parent.leveltime / 60));
_parent.digit2.gotoAndStop(Math.ceil((_parent._parent.leveltime % 60) / 10));
_parent.digit3.gotoAndStop(Math.ceil((_parent._parent.leveltime % 60) % 10));
}
}
Symbol 421 MovieClip Frame 21
if (_parent.leveltime >= 0) {
time_display.text = Math.floor(_parent.leveltime);
} else {
_parent.leveltime = 0;
time_display.text = Math.floor(_parent.leveltime);
}
items_display.text = _parent.items_score;
bonus_display.text = _parent.levelbonus;
var thistotal = ((Math.floor(_parent.leveltime) + _parent.items_score) + _parent.levelbonus);
total_display.text = thistotal;
_parent.gametotal = _parent.gametotal + thistotal;
if (thistotal > _parent.levelhighscores[_parent.mish_num - 1]) {
_parent.levelhighscores[_parent.mish_num - 1] = thistotal;
_parent["missionhighscore" + _parent.mish_num] = thistotal;
if (_parent.SAVE == true) {
_parent.savefile.data["missionhighscore" + _parent.mish_num] = thistotal;
_parent.savefile.flush();
}
} else {
newhighscore._visible = false;
}
if ((_parent.SAVE == true) and (_parent.thiscoincollected == true)) {
_parent.savefile.data["goldcoincollected" + _parent.mish_num] = 1;
_parent.savefile.flush();
_parent.goldcoincollected[_parent.mish_num - 1] = 1;
}
trace(_parent.levelhighscores);
_parent._x = 0;
_parent._y = 0;
stop();
Symbol 427 Button
on (release) {
play();
}
Symbol 430 MovieClip Frame 29
stop();
Symbol 430 MovieClip Frame 33
stop();
Symbol 430 MovieClip Frame 34
stop();
Symbol 430 MovieClip Frame 35
_parent.play();
Symbol 436 Button
on (release) {
if (_currentframe == 50) {
_parent.play();
} else {
play();
}
}
Symbol 442 MovieClip Frame 33
stop();
Symbol 442 MovieClip Frame 38
stop();
Symbol 442 MovieClip Frame 39
stop();
Symbol 442 MovieClip Frame 45
stop();
Symbol 442 MovieClip Frame 50
stop();
Symbol 473 Button
on (release) {
if (_currentframe == 44) {
_parent.play();
} else {
play();
}
}
Symbol 478 MovieClip Frame 34
stop();
Symbol 478 MovieClip Frame 39
stop();
Symbol 478 MovieClip Frame 44
stop();
Symbol 486 MovieClip Frame 34
stop();
Symbol 486 MovieClip Frame 39
stop();
Symbol 486 MovieClip Frame 44
stop();
Symbol 528 Button
on (release) {
if (_currentframe != 35) {
play();
} else {
_parent.play();
}
}
Symbol 530 MovieClip Frame 34
stop();
Symbol 530 MovieClip Frame 35
stop();
Symbol 542 Button
on (release) {
if (_currentframe == 40) {
_parent.play();
} else {
play();
}
}
Symbol 547 MovieClip Frame 30
stop();
Symbol 547 MovieClip Frame 35
stop();
Symbol 547 MovieClip Frame 40
stop();
Symbol 569 Button
on (release) {
if (_currentframe == 34) {
_parent.play();
} else {
play();
}
}
Symbol 571 MovieClip Frame 33
stop();
Symbol 571 MovieClip Frame 34
stop();
Symbol 582 Button
on (release) {
if (_currentframe == 43) {
_parent.play();
} else {
play();
}
}
Symbol 586 MovieClip Frame 33
stop();
Symbol 586 MovieClip Frame 38
stop();
Symbol 586 MovieClip Frame 43
stop();
Symbol 598 MovieClip Frame 27
gotoAndPlay (13);
Symbol 600 MovieClip Frame 1
stop();
Instance of Symbol 598 MovieClip in Symbol 600 MovieClip Frame 3
onClipEvent (enterFrame) {
if (Math.random() > 0.5) {
_parent._parent.dust(_parent._x, _parent._y);
}
}
Symbol 633 MovieClip Frame 30
stop();
Symbol 633 MovieClip Frame 35
stop();
Symbol 633 MovieClip Frame 40
stop();
Symbol 640 MovieClip Frame 33
stop();
Symbol 640 MovieClip Frame 38
stop();
Symbol 640 MovieClip Frame 43
stop();
Symbol 645 MovieClip Frame 27
gotoAndPlay (13);
Symbol 647 MovieClip Frame 1
stop();
Instance of Symbol 645 MovieClip in Symbol 647 MovieClip Frame 3
onClipEvent (enterFrame) {
if (Math.random() > 0.5) {
_parent._parent.dust(_parent._x, _parent._y);
}
}
Symbol 653 MovieClip Frame 27
gotoAndPlay (13);
Symbol 655 MovieClip Frame 1
stop();
Instance of Symbol 653 MovieClip in Symbol 655 MovieClip Frame 3
onClipEvent (enterFrame) {
if (Math.random() > 0.5) {
_parent._parent.dust(_parent._x, _parent._y);
}
}
Symbol 661 MovieClip Frame 27
gotoAndPlay (13);
Symbol 663 MovieClip Frame 1
stop();
Instance of Symbol 661 MovieClip in Symbol 663 MovieClip Frame 3
onClipEvent (enterFrame) {
if (Math.random() > 0.5) {
_parent._parent.dust(_parent._x, _parent._y);
}
}
Symbol 675 Button
on (release) {
if (_currentframe == 38) {
_root.play();
} else {
play();
}
}
Symbol 677 MovieClip Frame 33
stop();
Symbol 677 MovieClip Frame 38
stop();
Symbol 685 Button
on (release) {
if (_currentframe == 43) {
_root.play();
} else {
play();
}
}
Symbol 688 MovieClip Frame 33
stop();
Symbol 688 MovieClip Frame 38
stop();
Symbol 688 MovieClip Frame 43
stop();
Symbol 704 MovieClip Frame 1
active = true;
_parent.info.digit4.gotoAndStop(_parent.info.digit4._currentframe - 1);
stop();
Symbol 704 MovieClip Frame 2
active = false;
Symbol 731 MovieClip Frame 33
stop();
Symbol 731 MovieClip Frame 38
stop();
Symbol 738 MovieClip Frame 33
stop();
Symbol 738 MovieClip Frame 38
stop();
Symbol 738 MovieClip Frame 43
stop();
Symbol 771 MovieClip Frame 33
stop();
Symbol 771 MovieClip Frame 38
stop();
Symbol 777 Button
on (release) {
if (_currentframe == 44) {
_root.play();
} else {
play();
}
}
Symbol 783 MovieClip Frame 33
stop();
Symbol 783 MovieClip Frame 38
stop();
Symbol 783 MovieClip Frame 43
stop();
Symbol 783 MovieClip Frame 44
stop();
Instance of Symbol 790 MovieClip "branch3" in Symbol 801 MovieClip Frame 1
onClipEvent (load) {
_y = -200;
}
onClipEvent (enterFrame) {
if (_name != "branch3") {
_y = (_y + _parent._parent._parent.levelspeed);
if (_y > 1000) {
this.removeMovieClip();
}
}
}
Instance of Symbol 792 MovieClip "branch6" in Symbol 801 MovieClip Frame 1
onClipEvent (load) {
_y = -200;
}
onClipEvent (enterFrame) {
if (_name != "branch6") {
_y = (_y + _parent._parent._parent.levelspeed);
if (_y > 1000) {
this.removeMovieClip();
}
}
}
Instance of Symbol 794 MovieClip "branch4" in Symbol 801 MovieClip Frame 1
onClipEvent (load) {
_y = -200;
}
onClipEvent (enterFrame) {
if (_name != "branch4") {
_y = (_y + _parent._parent._parent.levelspeed);
if (_y > 1000) {
this.removeMovieClip();
}
}
}
Instance of Symbol 796 MovieClip "branch5" in Symbol 801 MovieClip Frame 1
onClipEvent (load) {
_y = -200;
}
onClipEvent (enterFrame) {
if (_name != "branch5") {
_y = (_y + _parent._parent._parent.levelspeed);
if (_y > 1000) {
this.removeMovieClip();
}
}
}
Instance of Symbol 798 MovieClip "branch1" in Symbol 801 MovieClip Frame 1
onClipEvent (load) {
_y = -200;
}
onClipEvent (enterFrame) {
if (_name != "branch1") {
_y = (_y + _parent._parent._parent.levelspeed);
if (_y > 1000) {
this.removeMovieClip();
}
}
}
Instance of Symbol 800 MovieClip "branch2" in Symbol 801 MovieClip Frame 1
onClipEvent (load) {
_y = -200;
}
onClipEvent (enterFrame) {
if (_name != "branch2") {
_y = (_y + _parent._parent._parent.levelspeed);
if (_y > 1000) {
this.removeMovieClip();
}
}
}
Symbol 809 MovieClip Frame 36
_parent._y = -100;
_parent._x = random(400) + 200;
_parent.gotoAndStop(1);
Symbol 815 MovieClip Frame 33
stop();
Symbol 815 MovieClip Frame 38
stop();
Symbol 823 MovieClip Frame 33
stop();
Symbol 823 MovieClip Frame 38
stop();
Symbol 823 MovieClip Frame 43
stop();
Symbol 864 MovieClip Frame 33
stop();
Symbol 864 MovieClip Frame 38
stop();
Symbol 871 Button
on (release) {
if (_currentframe == 41) {
_root.play();
} else {
play();
}
}
Symbol 874 Button
on (release) {
if (_currentframe == 45) {
_root.play();
} else {
play();
}
}
Symbol 875 MovieClip Frame 33
stop();
Symbol 875 MovieClip Frame 38
stop();
Symbol 875 MovieClip Frame 45
stop();
Symbol 896 MovieClip Frame 1
stop();
Symbol 896 MovieClip Frame 2
stop();
Symbol 900 Button
on (release) {
if (_currentframe == 39) {
_root.play();
} else {
play();
}
}
Symbol 903 MovieClip Frame 34
stop();
Symbol 903 MovieClip Frame 39
stop();
Symbol 911 MovieClip Frame 33
stop();
Symbol 911 MovieClip Frame 38
stop();
Symbol 911 MovieClip Frame 43
stop();
Symbol 944 MovieClip Frame 33
stop();
Symbol 944 MovieClip Frame 38
stop();
Symbol 957 Button
on (release) {
gotoAndPlay (3);
}
Symbol 960 Button
on (release) {
var missionbank = new Array();
missionbank = [8, 11, 14, 17, 20, 23, 26, 29, 32, 35, 38, 41];
menu_loop.stop();
playing_main_game = true;
var gametotal = 0;
var missionsleft = 4;
_root.WPI_ArcadeStartSingleGame();
gotoAndPlay(missionbank[int(random(missionbank.length))]);
var missionbank = new Array();
missionbank = [8, 11, 14, 17, 20, 23, 26, 29, 32, 35, 38, 41];
}