Frame 1
this._quality = "LOW";
this.global_sound = new Sound(this);
this.global_sound.original_volume = 50;
this.global_sound.setVolume(_root.global_sound.original_volume);
var active = false;
var loaded_amount = Math.round(this.getBytesLoaded() / 1024);
var total_amount = Math.round(this.getBytesTotal() / 1024);
var percent = Math.round((loaded_amount / total_amount) * 100);
Frame 2
if (percent < 100) {
this.gotoAndPlay(this._currentframe - 1);
} else {
gotoAndStop (4);
}
Frame 4
function playMain() {
gotoAndStop (4);
}
function playGame() {
gotoAndPlay (29);
}
function playHelp() {
gotoAndStop (30);
}
stop();
Frame 29
this._quality = "LOW";
this.active = true;
this.attachMovie("game_mc", "game", 1);
this.game._x = -2;
this.game._y = -2;
this.attachMovie("border", "border", 3001);
this.border._x = 0;
this.border._y = 0;
stop();
Frame 30
stop();
Symbol 6 MovieClip [points] Frame 30
this.removeMovieClip();
Symbol 7 MovieClip [map_mc] Frame 1
var level = new Array();
level[1] = new Array();
level[1][level[1].length] = [[7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7], [7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7], [7, -7, 0, -7, 0, -7, 0, -7, 0, -7, 0, -7, 0, 0, 0, 0, 0, 0, 0, -7, 0, -7, 0, -7, 0, -7, 0, -7, 0, -7, 0, 7], [7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 2, 2, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7], [7, -7, 0, 0, 1, 3, 0, -7, 0, 0, 0, -7, 0, -7, 0, 5, -7, 0, -7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -7, 0, 7], [7, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 5, 0, 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7], [7, 0, -7, 0, -7, 0, -7, 0, 0, 0, 0, 0, 0, -7, 0, -7, 0, -7, 0, 0, 0, 0, 0, -7, 0, -7, 0, -7, 0, -7, 0, 7], [7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7], [7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7]];
var theLevel = _parent._parent.current_level;
var randomMap = Math.round(Math.random() * (level[theLevel].length - 1));
var tile = new Object();
tile.width = 16;
tile.height = 16;
var walls = level[theLevel][randomMap];
var photocopiers = new Array();
var dozens = new Array();
var coffees = new Array();
var donuts = new Array();
var exits = new Array();
var tunnels = new Array();
this.create = function () {
this.attachMovie("empty_mc", "theTunnels", 50);
this.theTunnels.uniqueDepth = 1;
this.attachMovie("empty_mc", "theWalls", 100);
this.theWalls.attachMovie("map_image_mc", "map_image", 1);
this.theWalls.map_image.gotoAndStop((("map_" + theLevel) + "_") + randomMap);
this.theWalls._x = 1;
this.theWalls._y = 1;
this.attachMovie("empty_mc", "theExits", 200);
this.theExits.unique_depth = 1;
this.attachMovie("empty_mc", "theDonuts", 300);
this.theDonuts.unique_depth = 1;
this.attachMovie("empty_mc", "thePhotocopiers", 400);
this.thePhotocopiers.unique_depth = 1;
this.attachMovie("empty_mc", "theDozens", 500);
this.theDozens.unique_depth = 1;
this.attachMovie("empty_mc", "theCoffees", 600);
this.theCoffees.unique_depth = 1;
var i = 0;
while (i < this.walls.length) {
var j = 0;
while (j < this.walls[i].length) {
var tmp = new Object();
tmp.type = this.walls[i][j];
tmp.row = i;
tmp.col = j;
this.walls[i][j] = tmp;
if (this.walls[i][j].type == -3) {
this._parent.attachMovie("exit_mc", "exit", 998);
this._parent.exit._x = j * this.tile.width;
this._parent.exit._y = i * this.tile.height;
this.exits[this.exits.length] = this._parent.exit;
} else if (this.walls[i][j].type == -4) {
var copier_name = new String((("photocopier_" + i) + "_") + j);
this.thePhotocopiers.attachMovie("photocopier_mc", copier_name, this.thePhotocopiers.unique_depth++);
this.thePhotocopiers[copier_name]._x = j * this.tile.width;
this.thePhotocopiers[copier_name]._y = i * this.tile.height;
this.photocopiers[this.photocopiers.length] = this.thePhotocopiers[copier_name];
this.walls[i][j].type = 8;
_parent._parent.score.photocopiers.total++;
} else if (this.walls[i][j].type == -5) {
var dozen_name = new String((("dozen_" + i) + "_") + j);
this.theDozens.attachMovie("dozen_mc", dozen_name, this.theDozens.unique_depth++);
this.theDozens[dozen_name]._x = j * this.tile.width;
this.theDozens[dozen_name]._y = i * this.tile.height;
this.dozens[this.dozens.length] = this.theDozens[dozen_name];
_parent._parent.score.dozens.total++;
} else if (this.walls[i][j].type == -6) {
var coffee_name = new String((("coffee_" + i) + "_") + j);
this.theCoffees.attachMovie("coffee_mc", coffee_name, this.theCoffees.unique_depth++);
this.theCoffees[coffee_name]._x = j * this.tile.width;
this.theCoffees[coffee_name]._y = i * this.tile.height;
this.coffees[this.coffees.length] = this.theCoffees[coffee_name];
} else if (this.walls[i][j].type == -7) {
var donut_name = new String((("donut_" + i) + "_") + j);
this.theDonuts.attachMovie("donut_mc", donut_name, this.theDonuts.unique_depth++);
this.theDonuts[donut_name].gotoAndStop(this.theLevel);
this.theDonuts[donut_name]._x = j * this.tile.width;
this.theDonuts[donut_name]._y = i * this.tile.height;
this.donuts[this.donuts.length] = this.theDonuts[donut_name];
_parent._parent.score.donuts.total++;
} else if (this.walls[i][j].type == -8) {
this.theWalls[name].gotoAndStop(8);
var tunnel_name = new String((("tunnel_" + i) + "_") + j);
this.theTunnels.attachMovie("tunnel_mc", tunnel_name, this.theTunnels.unique_depth++);
this.theTunnels[tunnel_name]._x = j * this.tile.width;
this.theTunnels[tunnel_name]._y = i * this.tile.height;
this.tunnels[this.tunnels.length] = this.theTunnels[tunnel_name];
if (j == 0) {
this.theTunnels[tunnel_name].gotoAndStop("left");
} else if (j == (this.walls[i].length - 2)) {
this.theTunnels[tunnel_name].gotoAndStop("right");
}
if (i == 0) {
this.theTunnels[tunnel_name].gotoAndStop("top");
} else if (i == (this.walls.length - 1)) {
this.theTunnels[tunnel_name].gotoAndStop("bottom");
}
} else if (this.walls[i][j].type == -9) {
}
j++;
}
i++;
}
};
if (_root.active == true) {
this.create();
}
Symbol 14 MovieClip [item_hit_mc] Frame 12
gotoAndPlay (1);
Symbol 14 MovieClip [item_hit_mc] Frame 24
gotoAndPlay (13);
Symbol 14 MovieClip [item_hit_mc] Frame 36
gotoAndPlay (25);
Symbol 14 MovieClip [item_hit_mc] Frame 48
gotoAndPlay (37);
Symbol 39 MovieClip Frame 1
this.out_loaded = _parent.loaded_amount + " Kb";
this.out_total = _parent.total_amount + " Kb";
this.out_percent = _parent.percent + " %";
Symbol 39 MovieClip Frame 2
this.gotoAndPlay(this._currentframe - 1);
Symbol 80 MovieClip [boss_actions_mc] Frame 1
stop();
Symbol 80 MovieClip [boss_actions_mc] Frame 9
gotoAndStop (1);
Symbol 80 MovieClip [boss_actions_mc] Frame 19
gotoAndPlay (10);
Symbol 80 MovieClip [boss_actions_mc] Frame 35
gotoAndStop (1);
Symbol 80 MovieClip [boss_actions_mc] Frame 45
gotoAndStop (1);
Symbol 80 MovieClip [boss_actions_mc] Frame 46
play();
Symbol 80 MovieClip [boss_actions_mc] Frame 63
this.gotoAndPlay("sleep");
Symbol 80 MovieClip [boss_actions_mc] Frame 100
_parent.active = true;
Symbol 80 MovieClip [boss_actions_mc] Frame 105
this.gotoAndPlay("walk_loop");
Symbol 81 MovieClip [boss_mc] Frame 1
var attractor = 1;
var goal = "exit";
var direction = null;
var speed = new Object();
speed.original = _parent._parent.difficulty[_parent._parent.current_level].boss.speed.original;
speed.current = speed.original;
speed.boost = _parent._parent.difficulty[_parent._parent.current_level].boss.speed.boost;
var update = new Object();
update.remaining = 0;
update.time = function () {
return(Math.round((_parent.map.tile.width / speed.current) * Math.round((Math.random() * 4) + 2)));
};
var action = new Object();
action.remaining = 0;
action.time = 120;
var active = false;
this.sleep = function () {
this.actions.gotoAndPlay("sleep");
this.active = false;
var end_position = _parent[this.goal].hit.getBounds(_parent.map);
this._x = end_position.xMin;
this._y = end_position.yMin - 16;
this.touch._height = 56;
};
this.chooseRandomAction = function () {
var actions = new Array("static", "time", "drink");
var which = actions[Math.round(Math.random() * 2)];
this.actions.gotoAndPlay(which);
};
this.chaseSlackman = function () {
this.touch._height = 38;
_parent._parent.music.reset();
this.goal = "slackman";
this.speed.current = this.speed.boost;
this.direction = this.getNewDirection();
this.actions.gotoAndPlay("crazy");
};
this.getNewDirection = _parent.hue.getNewDirection;
this.move = function () {
if (this.active == true) {
if ((this.update.remaining == 0) || (_parent.collision(this, this.direction, _parent.map) == 0)) {
this.direction = this.getNewDirection();
this.update.remaining = this.update.time();
} else {
this.update.remaining--;
}
var amount = _parent.collision(this, this.direction, _parent.map);
if (this.direction == "up") {
this._y = this._y - amount;
} else if (this.direction == "down") {
this._y = this._y + amount;
} else if (this.direction == "left") {
this._x = this._x - amount;
} else if (this.direction == "right") {
this._x = this._x + amount;
}
_parent.checkForTunnel(this);
if (this.touch.hitTest(_parent[this.goal].touch)) {
if (((this.goal == "slackman") && (_parent.slackman.active == true)) && (_parent.slackman.action == false)) {
_parent._parent.fx.playFX("bad_short", true);
this.actions.gotoAndPlay("walk");
this.active = false;
this.goal = "exit";
this.speed.current = this.speed.original;
_parent._parent.score.looseSlack();
_parent._parent.score.coffee = 0;
_parent.slackman.boost.remaining = 0;
_parent.slackman.lead.remaining = _parent.slackman.lead.time;
_parent.slackman.change();
} else if (this.goal == "exit") {
this.sleep();
}
}
}
};
if (_root.active == true) {
this.sleep();
}
Symbol 163 MovieClip [noslack_walking_mc] Frame 12
gotoAndPlay (1);
Symbol 163 MovieClip [noslack_walking_mc] Frame 24
gotoAndPlay (13);
Symbol 163 MovieClip [noslack_walking_mc] Frame 36
gotoAndPlay (25);
Symbol 163 MovieClip [noslack_walking_mc] Frame 48
gotoAndPlay (37);
Symbol 163 MovieClip [noslack_walking_mc] Frame 77
_parent._parent.slackman.unwedgie();
this.gotoAndPlay(_parent.direction);
Symbol 163 MovieClip [noslack_walking_mc] Frame 88
_parent.endAction();
Symbol 163 MovieClip [noslack_walking_mc] Frame 99
_parent.endAction();
Symbol 163 MovieClip [noslack_walking_mc] Frame 109
_parent.endAction();
Symbol 163 MovieClip [noslack_walking_mc] Frame 120
_parent.endAction();
Symbol 163 MovieClip [noslack_walking_mc] Frame 152
_parent._parent.slackman.unwedgie();
this.gotoAndPlay(_parent.direction);
Symbol 169 MovieClip [hue_status_mc] Frame 5
gotoAndPlay (1);
Symbol 169 MovieClip [hue_status_mc] Frame 15
gotoAndPlay (6);
Symbol 169 MovieClip [hue_status_mc] Frame 25
gotoAndPlay (16);
Symbol 169 MovieClip [hue_status_mc] Frame 35
gotoAndPlay (26);
Symbol 169 MovieClip [hue_status_mc] Frame 45
gotoAndPlay (36);
Symbol 169 MovieClip [hue_status_mc] Frame 54
gotoAndPlay (46);
Symbol 169 MovieClip [hue_status_mc] Frame 64
gotoAndPlay (55);
Symbol 169 MovieClip [hue_status_mc] Frame 74
gotoAndPlay (65);
Symbol 169 MovieClip [hue_status_mc] Frame 85
gotoAndPlay (75);
Symbol 170 MovieClip [hue_mc] Frame 1
var speed = new Object();
speed.original = _parent._parent.difficulty[_parent._parent.current_level].hue.speed.original;
speed.current = speed.original;
speed.boost = _parent._parent.difficulty[_parent._parent.current_level].hue.speed.boost;
var direction = "left";
var goal = "slackman";
var attractor = 1;
var action = false;
var update = new Object();
update.remaining = 0;
update.time = function () {
return(Math.round((_parent.map.tile.width / speed.current) * Math.round((Math.random() * 8) + 2)));
};
this.endAction = function () {
this.action = false;
this.walking.gotoAndPlay(this.direction);
};
this.getNewDirection = function () {
this.fixNaN = function (value) {
if (isNaN(value)) {
return(0);
}
return(value);
};
this.chooseCloser = function () {
if (Math.abs(this._y - _parent[this.goal]._y) < Math.abs(this._x - _parent[this.goal]._x)) {
return(0);
}
if (Math.abs(this._x - _parent[this.goal]._x) < Math.abs(this._y - _parent[this.goal]._y)) {
return(1);
}
return(Math.round(Math.random()));
};
this.removeOpposite = function (a) {
var opposites = {right:"left", left:"right", down:"up", up:"down"};
var i = 0;
while (i < a.length) {
if (a[i] == opposites[this.direction]) {
a.splice(i, 1);
}
i++;
}
return(a);
};
var tile_x = Math.floor(this._x / _parent.map.tile.width);
var tile_y = Math.floor(this._x / _parent.map.tile.height);
var goal_x = Math.floor(_parent[this.goal]._x / _parent.map.tile.width);
var goal_y = Math.floor(_parent[this.goal]._y / _parent.map.tile.height);
var relative_x = this.fixNaN(((tile_x - goal_x) / Math.abs(tile_x - goal_x)) * this.attractor);
var relative_y = this.fixNaN(((tile_y - goal_y) / Math.abs(tile_y - goal_y)) * this.attractor);
var new_direction = this.direction;
var open = new Array("left", "right", "up", "down");
if ((relative_x == 0) && (relative_y == -1)) {
new_direction = "up";
open = new Array("left", "right");
} else if ((relative_x == 0) && (relative_y == 1)) {
new_direction = "down";
open = new Array("left", "right");
} else if ((relative_x == -1) && (relative_y == 0)) {
new_direction = "right";
open = new Array("up", "down");
} else if ((relative_x == 1) && (relative_y == 0)) {
new_direction = "left";
open = new Array("up", "down");
} else if ((relative_x == -1) && (relative_y == -1)) {
var choices = new Array("right", "down");
new_direction = choices[this.chooseCloser()];
open = new Array("down", "right", "up", "left");
} else if ((relative_x == 1) && (relative_y == 1)) {
var choices = new Array("left", "up");
new_direction = choices[this.chooseCloser()];
open = new Array("up", "left", "right", "down");
} else if ((relative_x == 1) && (relative_y == -1)) {
var choices = new Array("left", "down");
new_direction = choices[this.chooseCloser()];
open = new Array("down", "left", "up", "right");
} else if ((relative_x == -1) && (relative_y == 1)) {
var choices = new Array("right", "up");
new_direction = choices[this.chooseCloser()];
open = new Array("up", "right", "down", "left");
}
if (0 < Math.round(Math.random() * 2)) {
open = this.removeOpposite(open);
}
while (_parent.collision(this, new_direction, _parent.map) == 0) {
if (0 < open.length) {
new_direction = open[0];
open.shift();
} else {
break;
}
}
return(new_direction);
};
this.move = function () {
if (this.action == false) {
if (this.goal == "boss") {
this.status.gotoAndPlay("ratting_" + this.direction);
} else if ((this.goal == "slackman") && (0 < _parent.slackman.lead.remaining)) {
this.status.gotoAndPlay("away");
} else if (this.goal == "slackman") {
this.status.gotoAndPlay("looking_" + this.direction);
}
if ((this.update.remaining == 0) || (_parent.collision(this, this.direction, _parent.map) == 0)) {
this.direction = this.getNewDirection();
this.walking.gotoAndPlay(this.direction);
this.update.remaining = this.update.time();
} else {
this.update.remaining--;
}
if (this.touch.hitTest(_parent[this.goal].touch)) {
if ((this.goal == "boss") && (_parent.slackman.lead.remaining == 0)) {
_parent.boss.active = true;
_parent.boss.chaseSlackman();
_parent.slackman.boost.remaining = 0;
_parent.slackman.lead.remaining = 120;
this.goal = "slackman";
this.speed.current = this.speed.original;
} else if (this.goal == "slackman") {
if (_parent.slackman.lead.remaining == 0) {
_parent._parent.fx.playFX("alert", true);
this.goal = "boss";
this.speed.current = this.speed.boost;
this.action = true;
this.walking.gotoAndPlay("point_" + this.direction);
}
}
}
var amount = _parent.collision(this, this.direction, _parent.map);
if (this.direction == "up") {
this._y = this._y - amount;
} else if (this.direction == "down") {
this._y = this._y + amount;
} else if (this.direction == "left") {
this._x = this._x - amount;
} else if (this.direction == "right") {
this._x = this._x + amount;
}
_parent.checkForTunnel(this);
}
};
if (_root.active) {
i = 0;
while (i < _parent.map.walls.length) {
j = 0;
while (j < _parent.map.walls[i].length) {
if (_parent.map.walls[i][j].type == -2) {
this._x = j * _parent.map.tile.width;
this._y = i * _parent.map.tile.height;
}
j++;
}
i++;
}
this.walking.gotoAndStop(this.direction);
}
stop();
Symbol 176 Button
on (rollOver) {
this.gotoAndStop("play");
}
on (release) {
_parent._parent.playGame();
}
Symbol 177 Button
on (rollOver) {
this.gotoAndStop("how_to_play");
}
on (release) {
_parent._parent.playHelp();
}
Symbol 180 MovieClip Frame 1
stop();
Symbol 180 MovieClip Frame 10
stop();
Symbol 193 MovieClip [donut_mc] Frame 1
stop();
Symbol 193 MovieClip [donut_mc] Frame 2
stop();
Symbol 193 MovieClip [donut_mc] Frame 3
stop();
Symbol 193 MovieClip [donut_mc] Frame 4
stop();
Symbol 193 MovieClip [donut_mc] Frame 5
stop();
Symbol 263 MovieClip [photocopier_mc] Frame 1
this.used = false;
stop();
Symbol 263 MovieClip [photocopier_mc] Frame 34
this.used = true;
_parent._parent._parent.slackman.unphotocopy(this._x, this._y);
stop();
Symbol 263 MovieClip [photocopier_mc] Frame 67
this.used = true;
_parent._parent._parent.slackman.unphotocopy(this._x, this._y);
stop();
Symbol 269 MovieClip [tunnel_mc] Frame 1
stop();
Symbol 269 MovieClip [tunnel_mc] Frame 10
stop();
Symbol 269 MovieClip [tunnel_mc] Frame 21
stop();
Symbol 269 MovieClip [tunnel_mc] Frame 31
stop();
Symbol 302 MovieClip [map_image_mc] Frame 171
stop();
Symbol 312 MovieClip Frame 1
if (played == null) {
this.gotoAndStop(3);
}
var played = true;
Symbol 312 MovieClip Frame 2
stop();
Symbol 312 MovieClip Frame 3
stop();
Symbol 320 MovieClip [score_mc] Frame 1
function setOutTotal() {
if ((this.frame_count % 2) == 0) {
var difference = (this.total() - this.out_total);
if (50 < difference) {
this.out_total = this.out_total + Math.round(difference / 2);
} else {
this.out_total = this.total();
}
this.frame_count = 1;
} else {
this.frame_count++;
}
}
function looseSlack() {
this.slack--;
}
function gainSlack() {
if (this.slack < this.max_slack) {
this.slack++;
_parent.level.slackman.change();
_parent.fx.playFX("bonus", true);
}
this.points.threshold.shift();
}
function nextLevel() {
this.points.threshold.current = this.points.threshold.original();
_parent.total_level++;
_parent.cutaway.gotoAndPlay("next_level");
}
function checkForDead() {
if (0 >= this.slack) {
_parent.cutaway.gotoAndPlay("gameover");
}
}
function calculate() {
this.setOutTotal();
out_coffee = "x" + this.coffee;
out_slack = "x" + this.slack;
heads.gotoAndStop(this.slack + 1);
if ((this.donuts.eaten / this.points.threshold.current[0]) == 1) {
this.gainSlack();
}
if (this.donuts.eaten == this.donuts.total) {
_parent.level.slackman.dance();
}
_parent.music.update();
}
var out_slack;
var out_coffee;
var out_total = 0;
var frame_count = 1;
var slack = 2;
var max_slack = 2;
var coffee = 0;
var coffee_collected = 0;
var coffee_value = 250;
var slack_attacks = 0;
var slack_attack_value = 1000;
var total_coffee = 0;
var total_butt_copies = 0;
var total_slack_attacks = 0;
var total_donuts = 0;
var donuts = new Object();
donuts.eaten = 0;
donuts.total = 0;
donuts.value = 100;
var dozens = new Object();
dozens.eaten = 0;
dozens.total = 0;
dozens.value = 1200;
var photocopiers = new Object();
photocopiers.used = 0;
photocopiers.total = 0;
photocopiers.value = 2400;
var points = new Object();
points.threshold = new Object();
points.threshold.original = function () {
return(_parent.difficulty[_parent.current_level].points);
};
points.threshold.current = points.threshold.original();
points.carried_over = 0;
var total = function () {
return(((((points.carried_over + (this.donuts.eaten * this.donuts.value)) + (this.dozens.eaten * this.dozens.value)) + (this.photocopiers.used * this.photocopiers.value)) + (this.slack_attacks * this.slack_attack_value)) + (this.coffee_collected * this.coffee_value));
};
stop();
Symbol 508 MovieClip [semi_slack_walking_mc] Frame 12
gotoAndPlay (1);
Symbol 508 MovieClip [semi_slack_walking_mc] Frame 26
gotoAndPlay (13);
Symbol 508 MovieClip [semi_slack_walking_mc] Frame 38
gotoAndPlay (27);
Symbol 508 MovieClip [semi_slack_walking_mc] Frame 50
gotoAndPlay (39);
Symbol 508 MovieClip [semi_slack_walking_mc] Frame 164
gotoAndPlay (157);
Symbol 617 MovieClip [superslack_mc] Frame 2
_parent.eating = false;
Symbol 617 MovieClip [superslack_mc] Frame 12
gotoAndPlay (1);
Symbol 617 MovieClip [superslack_mc] Frame 14
_parent.eating = false;
Symbol 617 MovieClip [superslack_mc] Frame 24
gotoAndPlay (13);
Symbol 617 MovieClip [superslack_mc] Frame 26
_parent.eating = false;
Symbol 617 MovieClip [superslack_mc] Frame 36
gotoAndPlay (25);
Symbol 617 MovieClip [superslack_mc] Frame 38
_parent.eating = false;
Symbol 617 MovieClip [superslack_mc] Frame 48
gotoAndPlay (37);
Symbol 617 MovieClip [superslack_mc] Frame 58
_parent.unEat();
Symbol 617 MovieClip [superslack_mc] Frame 68
_parent.unEat();
Symbol 617 MovieClip [superslack_mc] Frame 78
_parent.unEat();
Symbol 617 MovieClip [superslack_mc] Frame 86
_parent.unEat();
Symbol 617 MovieClip [superslack_mc] Frame 87
Symbol 617 MovieClip [superslack_mc] Frame 102
_parent.undrink();
Symbol 617 MovieClip [superslack_mc] Frame 118
_parent.undrink();
Symbol 617 MovieClip [superslack_mc] Frame 130
_parent.undrink();
Symbol 617 MovieClip [superslack_mc] Frame 140
_parent.undrink();
Symbol 617 MovieClip [superslack_mc] Frame 146
_parent.active = true;
Symbol 617 MovieClip [superslack_mc] Frame 154
gotoAndPlay (147);
Symbol 617 MovieClip [superslack_mc] Frame 175
_parent.unChange();
Symbol 617 MovieClip [superslack_mc] Frame 235
_parent.unDance();
Symbol 618 MovieClip [slackman_mc] Frame 1
var point_depth = 10000;
var state = new Array(null, "semislack", "superslack");
var speed = new Object();
speed.original = _parent._parent.difficulty[_parent._parent.current_level].slackman.speed.original;
speed.current = speed.original;
speed.boost = _parent._parent.difficulty[_parent._parent.current_level].slackman.speed.boost;
var boost = new Object();
boost.remaining = 0;
boost.time = _parent._parent.difficulty[_parent._parent.current_level].slackman.boost;
var lead = new Object();
lead.remaining = 0;
lead.time = _parent._parent.difficulty[_parent._parent.current_level].slackman.lead;
var direction = null;
var last_direction = direction;
var active = true;
var action = false;
var eating = false;
this.getSlack = function () {
return(_parent._parent.score.slack);
};
this.setSlack = function (amount) {
_parent._parent.score.slack = amount;
};
this.getCoffee = function () {
return(_parent._parent.score.coffee);
};
this.setCoffee = function (amount) {
_parent._parent.score.coffee = amount;
};
this.update = function () {
var i = 0;
while (i < this.state.length) {
if (i == this.getSlack()) {
this[this.state[i]]._visible = true;
} else {
this[this.state[i]]._visible = false;
}
if (this.direction == null) {
if ((this.action == false) && (this.eating == false)) {
this[this.state[i]].stop();
this.item.stop();
}
this[this.state[i]].legs.stop();
} else if (this.action == false) {
this[this.state[i]].gotoAndPlay(this.direction);
this.item.gotoAndPlay(this.direction);
}
i++;
}
};
this.dance = function () {
_parent._parent.fx.playFX("dance", true);
_parent.hue.walking.gotoAndStop(_parent.hue.direction);
_parent.hue.status.gotoAndStop("away");
if (_parent.boss.active == true) {
_parent.boss.actions.gotoAndStop("static");
}
this.action = true;
this.active = false;
_parent._parent.paused = true;
var i = 0;
while (i < this.state.length) {
this[this.state[i]].gotoAndPlay("dance");
i++;
}
};
this.unDance = function () {
_parent._parent.score.nextLevel();
this.action = false;
this.active = true;
};
this.change = function () {
if ((this.active == true) && (this.action == false)) {
this.action = true;
this.active = false;
var i = 0;
while (i < this.state.length) {
this[this.state[i]].gotoAndPlay("change");
i++;
}
}
};
this.unChange = function () {
_parent._parent.score.checkForDead();
this.action = false;
if (0 < this.getSlack()) {
this.active = true;
}
this.lead.remaining = this.lead.time;
this.direction = this.last_direction;
this.update();
};
this.eat = function (which) {
_parent._parent.score.total_donuts++;
this.eating = true;
_parent._parent.fx.playFX("eat", false);
var i = 0;
while (i < this.state.length) {
this[this.state[i]].gotoAndPlay("eat_" + this.direction);
i++;
}
_parent._parent.score.donuts.eaten++;
_parent.map.donuts[which].removeMovieClip();
_parent.map.donuts.splice(which, 1);
this.playPoints(_parent._parent.score.donuts.value);
};
this.unEat = function () {
this.eating = false;
this.direction = this.last_direction;
this.update();
};
this.eatDozen = function (which) {
this.eating = true;
_parent._parent.fx.playFX("bonus_short", true);
var i = 0;
while (i < this.state.length) {
this[this.state[i]].gotoAndPlay("eat_" + this.direction);
i++;
}
_parent._parent.score.dozens.eaten++;
_parent.map.dozens[which].removeMovieClip();
_parent.map.dozens.splice(which, 1);
this.playPoints(_parent._parent.score.dozens.value);
};
this.drink = function () {
if (0 < this.getCoffee()) {
_parent._parent.fx.playFX("drink", true);
this.active = false;
this.action = true;
var theDirection = this.direction;
if (theDirection == null) {
theDirection = this.last_direction;
}
if (theDirection == null) {
theDirection = "right";
}
var i = 0;
while (i < this.state.length) {
this[this.state[i]].gotoAndPlay("drink_" + theDirection);
i++;
}
}
};
this.undrink = function () {
this.setCoffee(this.getCoffee() - 1);
this.attack();
};
this.attack = function () {
_parent._parent.music.reset();
this.speed.current = this.speed.boost;
this.boost.remaining = this.boost.time;
var i = 0;
while (i < this.state.length) {
this[this.state[i]].gotoAndPlay("slack_attack");
i++;
}
};
this.unattack = function () {
this.action = false;
this.boost.remaining = 0;
this.speed.current = this.speed.original;
if (this.direction == null) {
this.direction = this.last_direction;
this.update();
this.direction = null;
}
this.update();
};
this.playCutaway = function (which) {
_parent._parent.cutaway.gotoAndPlay(which);
};
this.playPoints = function (amount) {
_parent.attachMovie("points", "points" + this.point_depth, this.point_depth++);
var thePoints = _parent["points" + this.point_depth];
thePoints.amount = amount;
thePoints._x = this._x;
thePoints._y = this._y - 32;
};
this.photocopy = function (which) {
if ((this.active == true) && (this.action == false)) {
this.active = false;
this.action = true;
_parent._parent.fx.playFX("copy", true);
_parent._parent.score.total_butt_copies++;
which.gotoAndPlay(this.state[this.getSlack()]);
this._visible = false;
}
};
this.unphotocopy = function (x, y) {
this.boost.remaining = -1;
this.speed.current = this.speed.original;
_parent._parent.score.photocopiers.used++;
this.playPoints(_parent._parent.score.photocopiers.value);
this._x = x + 6;
this._y = y + 24;
this._visible = true;
this.active = true;
this.action = false;
if (0 < this.getSlack()) {
this.direction = "right";
this.last_direction = "right";
this.update();
}
};
this.wedgie = function () {
this.playPoints(_parent._parent.score.slack_attack_value);
_parent._parent.fx.playFX("end_slack_attack", true);
_parent._parent.score.total_slack_attacks++;
_parent._parent.score.slack_attacks++;
this.action = true;
this.active = false;
this._visible = false;
this.boost.remaining = -1;
this.lead.remaining = 120;
this.speed.current = this.speed.original;
_parent.hue.action = true;
_parent.hue.walking.gotoAndPlay("wedgie_" + this.state[this.getSlack()]);
_parent.hue.goal = "slackman";
_parent.hue.attractor = -1;
_parent.hue.speed.current = _parent.hue.speed.original;
};
this.unwedgie = function () {
this.active = true;
this.action = false;
this._visible = true;
this.direction = "right";
this.update();
this.direction = null;
this.update();
_parent.hue.action = false;
_parent.hue.direction = "right";
};
this.move = function (direction) {
if (direction != this.direction) {
this.last_direction = this.direction;
this.direction = direction;
this.update();
}
if (0 < this.boost.remaining) {
if (this.touch.hitTest(_parent.hue.touch)) {
this.wedgie();
}
this.boost.remaining--;
} else if (this.boost.remaining == 0) {
this.unattack();
this.boost.remaining--;
}
if (0 < this.lead.remaining) {
this.lead.remaining--;
} else {
_parent.hue.attractor = 1;
}
if (this.active == true) {
var amount = _parent.collision(this, this.direction, _parent.map);
if (this.direction == "up") {
this._y = this._y - amount;
} else if (this.direction == "down") {
this._y = this._y + amount;
} else if (this.direction == "left") {
this._x = this._x - amount;
} else if (this.direction == "right") {
this._x = this._x + amount;
}
_parent.checkForTunnel(this);
if (this.boost.remaining < 1) {
var i = 0;
while (i < _parent.map.photocopiers.length) {
if ((this.item.hitTest(_parent.map.photocopiers[i].hit) && (_parent.map.photocopiers[i].used == false)) && (this.direction == "up")) {
this.photocopy(_parent.map.photocopiers[i]);
}
i++;
}
var i = 0;
while (i < _parent.map.donuts.length) {
if (this.item.hitTest(_parent.map.donuts[i])) {
this.eat(i);
}
i++;
}
var i = 0;
while (i < _parent.map.coffees.length) {
if (this.item.hitTest(_parent.map.coffees[i])) {
_parent._parent.score.total_coffee++;
_parent._parent.score.coffee_collected++;
this.playPoints(_parent._parent.score.coffee_value);
_parent.map.coffees[i].removeMovieClip();
_parent.map.coffees.splice(i, 1);
this.setCoffee(this.getCoffee() + 1);
}
i++;
}
var i = 0;
while (i < _parent.map.dozens.length) {
if (this.item.hitTest(_parent.map.dozens[i].hit)) {
this.eatDozen(i);
}
i++;
}
}
}
};
if (_root.active) {
i = 0;
while (i < _parent.map.walls.length) {
j = 0;
while (j < _parent.map.walls[i].length) {
if (_parent.map.walls[i][j].type == -1) {
this._x = j * _parent.map.tile.width;
this._y = i * _parent.map.tile.height;
}
j++;
}
i++;
}
this.update();
_parent._parent.music.mute();
_parent._parent.music.update();
_parent._parent.fx.playFX("countdown", true);
}
stop();
this.attachMovie("slackman_countdown_mc", "scd", 1005);
this.scd._x = 4;
this.scd._y = -68;
Symbol 633 Button
on (press) {
_parent.newGame();
_parent.paused = false;
this.gotoAndStop("blank");
}
Symbol 646 Button
on (rollOver) {
this.gotoAndStop("play_again");
}
on (release) {
_parent.playAgain();
}
Symbol 647 Button
on (rollOver) {
this.gotoAndStop("exit");
}
on (release) {
_parent.exit();
}
Symbol 650 MovieClip Frame 1
stop();
Symbol 650 MovieClip Frame 10
stop();
Symbol 658 MovieClip [cutaway_mc] Frame 1
function start() {
_parent.paused = true;
_parent.music.mute();
_parent.music.update();
}
function end() {
_parent.paused = false;
_parent.music.unmute();
this.gotoAndStop("blank");
}
function _play(which) {
this.gotoAndPlay(which);
}
stop();
Symbol 658 MovieClip [cutaway_mc] Frame 15
this.start();
Symbol 658 MovieClip [cutaway_mc] Frame 29
this.end();
Symbol 658 MovieClip [cutaway_mc] Frame 44
this.end();
Symbol 658 MovieClip [cutaway_mc] Frame 59
this.end();
Symbol 658 MovieClip [cutaway_mc] Frame 74
this.end();
Symbol 658 MovieClip [cutaway_mc] Frame 89
this.end();
Symbol 658 MovieClip [cutaway_mc] Frame 90
_parent.fx.gotoAndPlay("next_level");
var out_level = ("LEVEL " + _parent.total_level);
this.start();
Symbol 658 MovieClip [cutaway_mc] Frame 150
_parent.goToNextLevel();
_parent.paused = false;
this.gotoAndStop("blank");
Symbol 658 MovieClip [cutaway_mc] Frame 151
this.start();
Symbol 658 MovieClip [cutaway_mc] Frame 165
this.end();
Symbol 658 MovieClip [cutaway_mc] Frame 166
this.start();
_parent.fx.gotoAndPlay("gameover");
Symbol 658 MovieClip [cutaway_mc] Frame 181
stop();
Symbol 658 MovieClip [cutaway_mc] Frame 182
_parent.fx.playFX("win", true);
this.start();
Symbol 658 MovieClip [cutaway_mc] Frame 197
stop();
Symbol 658 MovieClip [cutaway_mc] Frame 198
function playAgain() {
_parent.newGame();
_parent.paused = false;
this.gotoAndStop("blank");
}
function exit() {
_parent.music.semiSlack.gotoAndStop("stop");
_parent.music.superSlack.gotoAndStop("stop");
_parent.music.boss_loop.gotoAndStop("stop");
_parent.music.slack_attack_loop.gotoAndStop("stop");
_root.active = false;
_root.playMain();
_parent.removeMovieClip();
}
this.start();
_parent.fx.gotoAndPlay("gameover");
var final_donuts = _parent.score.total_donuts;
var final_copies = _parent.score.total_butt_copies;
var final_coffee = _parent.score.total_coffee;
var final_slackattacks = _parent.score.total_slack_attacks;
var final_points = _parent.score.total();
Symbol 658 MovieClip [cutaway_mc] Frame 260
_parent.level.boss.goal = "exit";
_parent.score.slack = 2;
_parent.music.reset();
_parent.music.unmute();
_parent.music.update();
Symbol 658 MovieClip [cutaway_mc] Frame 274
stop();
Symbol 660 MovieClip [level_mc] Frame 1
function checkForTunnel(which) {
var bounds = which.hit.getBounds(which._parent.map);
if (bounds.xMin < 0) {
which._x = which._x + 495;
} else if (496 < bounds.xMin) {
which._x = which._x - 495;
}
if (bounds.yMin < 0) {
which._y = which._y + 400;
} else if (401 < bounds.yMin) {
which._y = which._y - 400;
}
}
function collision(theCharacter, theDirection, theMap) {
var bounds = theCharacter.hit.getBounds(theMap);
var distance = theCharacter.speed.current;
if (theDirection == "up") {
var row = Math.floor((bounds.yMin - theCharacter.speed.current) / theMap.tile.height);
var left = Math.floor(bounds.xMin / theMap.tile.width);
var right = Math.floor((bounds.xMax - 0.1) / theMap.tile.width);
var center = Math.floor(((bounds.xMin + bounds.xMax) / 2) / theMap.tile.width);
if (((0 < theMap.walls[row][left].type) || (0 < theMap.walls[row][center].type)) || (0 < theMap.walls[row][right].type)) {
distance = bounds.yMin - ((row + 1) * theMap.tile.height);
}
} else if (theDirection == "down") {
var row = Math.floor(((bounds.yMax - 0.1) + theCharacter.speed.current) / theMap.tile.height);
var left = Math.floor(bounds.xMin / theMap.tile.width);
var right = Math.floor((bounds.xMax - 0.1) / theMap.tile.width);
var center = Math.floor(((bounds.xMin + bounds.xMax) / 2) / theMap.tile.width);
if (((0 < theMap.walls[row][left].type) || (0 < theMap.walls[row][center].type)) || (0 < theMap.walls[row][right].type)) {
distance = (row * theMap.tile.height) - bounds.yMax;
}
} else if (theDirection == "left") {
var col = Math.floor((bounds.xMin - theCharacter.speed.current) / theMap.tile.width);
var top = Math.floor(bounds.yMin / theMap.tile.height);
var middle = Math.floor(((bounds.yMin + bounds.yMax) / 2) / theMap.tile.height);
var bottom = Math.floor((bounds.yMax - 0.1) / theMap.tile.height);
if (((0 < theMap.walls[top][col].type) || (0 < theMap.walls[middle][col].type)) || (0 < theMap.walls[bottom][col].type)) {
distance = bounds.xMin - ((col + 1) * theMap.tile.width);
}
} else if (theDirection == "right") {
var col = Math.floor(((bounds.xMax - 0.1) + theCharacter.speed.current) / theMap.tile.width);
var top = Math.floor(bounds.yMin / theMap.tile.height);
var middle = Math.floor(((bounds.yMin + bounds.yMax) / 2) / theMap.tile.height);
var bottom = Math.floor((bounds.yMax - 0.1) / theMap.tile.height);
if (((0 < theMap.walls[top][col].type) || (0 < theMap.walls[middle][col].type)) || (0 < theMap.walls[bottom][col].type)) {
distance = (col * theMap.tile.width) - bounds.xMax;
}
}
if (distance < 0) {
distance = 0;
}
return(distance);
}
_parent.paused = true;
var coundown = 90;
this.attachMovie("map_mc", "map", 1);
this.attachMovie("slackman_mc", "slackman", 1000);
this.slackman._z = 1000;
this.attachMovie("hue_mc", "hue", 999);
this.hue._z = 999;
this.attachMovie("boss_mc", "boss", 997);
this.boss._z = 997;
Instance of Symbol 13 MovieClip [empty_mc] "engine" in Symbol 660 MovieClip [level_mc] Frame 1
onClipEvent (enterFrame) {
function sortClips(a, b) {
if (b._y < a._y) {
return(-1);
}
if (a._y < b._y) {
return(1);
}
if (a._y == b._y) {
return(0);
}
}
if (_parent._parent.paused != true) {
var direction;
if (Key.isDown(38)) {
direction = "up";
} else if (Key.isDown(40)) {
direction = "down";
} else if (Key.isDown(37)) {
direction = "left";
} else if (Key.isDown(39)) {
direction = "right";
} else {
direction = null;
}
if (_parent.slackman.active == true) {
_parent.slackman.move(direction);
}
_parent.hue.move();
_parent.boss.move();
_parent._parent.score.calculate();
if (Key.isDown(32)) {
if ((_parent.slackman.active == true) && (_parent.slackman.action == false)) {
_parent.slackman.drink();
}
}
var clips = new Array(_parent.slackman, _parent.hue, _parent.boss, _parent.exit);
clips.sort(sortClips);
clips[0].swapDepths(1000);
clips[1].swapDepths(999);
clips[2].swapDepths(998);
clips[3].swapDepths(997);
}
}
Symbol 667 MovieClip Frame 1
function randomWindows() {
var choices = new Array("three", "one");
this.gotoAndStop(choices[Math.round(Math.random())]);
}
randomWindows();
stop();
Symbol 667 MovieClip Frame 10
stop();
Symbol 669 MovieClip [game_mc] Frame 1
var paused = false;
var current_level = 1;
var total_level = current_level;
var max_level = 5;
var difficulty = new Array();
difficulty[1] = new Object();
difficulty[1].slackman = new Object();
difficulty[1].slackman.speed = new Object();
difficulty[1].slackman.speed.original = 4;
difficulty[1].slackman.speed.boost = 6;
difficulty[1].slackman.boost = 120;
difficulty[1].slackman.lead = 120;
difficulty[1].hue = new Object();
difficulty[1].hue.iq = 75;
difficulty[1].hue.speed = new Object();
difficulty[1].hue.speed.original = 3;
difficulty[1].hue.speed.boost = 4;
difficulty[1].boss = new Object();
difficulty[1].boss.iq = 100;
difficulty[1].boss.speed = new Object();
difficulty[1].boss.speed.original = 4;
difficulty[1].boss.speed.boost = 8;
difficulty[1].points = new Array(15, 30, 50, 75, 100, 125, 150, 175, 200);
difficulty[2] = new Object();
difficulty[2].slackman = new Object();
difficulty[2].slackman.speed = new Object();
difficulty[2].slackman.speed.original = 5;
difficulty[2].slackman.speed.boost = 7;
difficulty[2].slackman.boost = 105;
difficulty[2].slackman.lead = 105;
difficulty[2].hue = new Object();
difficulty[2].hue.iq = 80;
difficulty[2].hue.speed = new Object();
difficulty[2].hue.speed.original = 4;
difficulty[2].hue.speed.boost = 5;
difficulty[2].boss = new Object();
difficulty[2].boss.iq = 100;
difficulty[2].boss.speed = new Object();
difficulty[2].boss.speed.original = 4;
difficulty[2].boss.speed.boost = 9;
difficulty[2].points = new Array(15, 30, 45, 60, 75);
difficulty[3] = new Object();
difficulty[3].slackman = new Object();
difficulty[3].slackman.speed = new Object();
difficulty[3].slackman.speed.original = 6;
difficulty[3].slackman.speed.boost = 8;
difficulty[3].slackman.boost = 90;
difficulty[3].slackman.lead = 90;
difficulty[3].hue = new Object();
difficulty[3].hue.iq = 85;
difficulty[3].hue.speed = new Object();
difficulty[3].hue.speed.original = 5;
difficulty[3].hue.speed.boost = 6;
difficulty[3].boss = new Object();
difficulty[3].boss.iq = 90;
difficulty[3].boss.speed = new Object();
difficulty[3].boss.speed.original = 4;
difficulty[3].boss.speed.boost = 10;
difficulty[3].points = new Array(20, 40, 60, 80);
difficulty[4] = new Object();
difficulty[4].slackman = new Object();
difficulty[4].slackman.speed = new Object();
difficulty[4].slackman.speed.original = 7;
difficulty[4].slackman.speed.boost = 9;
difficulty[4].slackman.boost = 75;
difficulty[4].slackman.lead = 75;
difficulty[4].hue = new Object();
difficulty[4].hue.iq = 90;
difficulty[4].hue.speed = new Object();
difficulty[4].hue.speed.original = 6;
difficulty[4].hue.speed.boost = 7;
difficulty[4].boss = new Object();
difficulty[4].boss.iq = 100;
difficulty[4].boss.speed = new Object();
difficulty[4].boss.speed.original = 4;
difficulty[4].boss.speed.boost = 11;
difficulty[4].points = new Array(25, 50, 75);
difficulty[5] = new Object();
difficulty[5].slackman = new Object();
difficulty[5].slackman.speed = new Object();
difficulty[5].slackman.speed.original = 8;
difficulty[5].slackman.speed.boost = 10;
difficulty[5].slackman.boost = 60;
difficulty[5].slackman.lead = 60;
difficulty[5].hue = new Object();
difficulty[5].hue.iq = 100;
difficulty[5].hue.speed = new Object();
difficulty[5].hue.speed.original = 7;
difficulty[5].hue.speed.boost = 8;
difficulty[5].boss = new Object();
difficulty[5].boss.iq = 100;
difficulty[5].boss.speed = new Object();
difficulty[5].boss.speed.original = 4;
difficulty[5].boss.speed.boost = 12;
difficulty[5].points = new Array(50, 100);
this.createCutaway = function () {
this.attachMovie("cutaway_mc", "cutaway", 3);
};
this.createLevel = function (theLevel) {
this.attachMovie("level_mc", "level", 2);
this.level._y = 95;
this.level._x = -1;
};
this.goToNextLevel = function () {
this.score.points.carried_over = this.score.total();
this.score.donuts.eaten = 0;
this.score.donuts.total = 0;
this.score.photocopiers.used = 0;
this.score.photocopiers.total = 0;
this.score.dozens.eaten = 0;
this.score.dozens.total = 0;
this.score.coffee = 0;
this.score.coffee_collected = 0;
this.score.slack_attacks = 0;
this.background.windows.randomWindows();
if (this.current_level < this.max_level) {
this.current_level++;
}
this.createLevel(this.current_level);
};
this.newGame = function () {
this.score.points.carried_over = 0;
this.score.donuts.eaten = 0;
this.score.donuts.total = 0;
this.score.photocopiers.used = 0;
this.score.photocopiers.total = 0;
this.score.dozens.eaten = 0;
this.score.dozens.total = 0;
this.score.coffee = 0;
this.score.slack = this.score.max_slack;
this.score.total_coffee = 0;
this.score.total_butt_copies = 0;
this.score.total_slack_attacks = 0;
this.score.total_donuts = 0;
this.current_level = 1;
this.total_level = this.current_level;
this.createLevel(this.current_level);
};
this.createScore = function () {
this.attachMovie("score_mc", "score", 4);
};
this.createMusic = function () {
this.attachMovie("music_mc", "music", 5);
this.music.gotoAndStop(2);
};
this.createFx = function () {
this.attachMovie("fx_mc", "fx", 6);
};
if (_root.active == true) {
this.createCutaway();
this.createLevel();
this.createScore();
this.createMusic();
this.createFx();
this.attachMovie("sound_toggle_mc", "sound_toggle", 3000);
this.sound_toggle._x = 478;
this.sound_toggle._y = 60;
}
stop();
Symbol 676 MovieClip [slackman_countdown_mc] Frame 1
if (_root.active == true) {
play();
} else {
stop();
}
Symbol 676 MovieClip [slackman_countdown_mc] Frame 48
_parent._parent._parent.paused = false;
this.removeMovieClip();
Symbol 679 MovieClip [slack_attack_loop] Frame 20
stop();
Symbol 681 MovieClip [boss_loop_mc] Frame 29
stop();
Symbol 683 MovieClip Frame 21
stop();
Symbol 685 MovieClip Frame 20
stop();
Symbol 686 MovieClip [music_mc] Frame 1
function mute() {
this.isMuted = true;
}
function reset() {
this.semiSlack.gotoAndPlay("stop");
this.superSlack.gotoAndPlay("stop");
this.boss_loop.gotoAndPlay("stop");
this.slack_attack_loop.gotoAndPlay("stop");
}
function unmute() {
this.isMuted = false;
this.update();
}
function update() {
if (this.isMuted == false) {
if (_parent.level.boss.goal == "slackman") {
this[clips[0]].setVolume(100);
this[clips[1]].setVolume(0);
this[clips[2]].setVolume(0);
this[clips[3]].setVolume(0);
} else if (0 < _parent.level.slackman.boost.remaining) {
this[clips[0]].setVolume(0);
this[clips[1]].setVolume(0);
this[clips[2]].setVolume(0);
this[clips[3]].setVolume(100);
} else {
var i = 0;
while (i < clips.length) {
if (isPlaying(i)) {
this[clips[i]].setVolume(100);
} else {
this[clips[i]].setVolume(0);
}
i++;
}
}
} else {
var i = 0;
while (i < clips.length) {
this[clips[i]].setVolume(0);
i++;
}
}
}
var isMuted = false;
var clips = new Array("boss", "semi_slack", "super_slack", "slack_attack");
var isPlaying = function (which) {
if (which == _parent.score.slack) {
return(true);
}
return(false);
};
stop();
Symbol 686 MovieClip [music_mc] Frame 2
var semi_slack = new Sound(semiSlack);
var super_slack = new Sound(superSlack);
var boss = new Sound(boss_loop);
var slack_attack = new Sound(slack_attack_loop);
this.update();
stop();
Symbol 700 MovieClip [fx_mc] Frame 1
function playFX(which, mute) {
this.gotoAndPlay(which);
if (mute == true) {
_parent.music.mute();
}
}
function endFX() {
_parent.music.unmute();
_parent.music.reset();
}
var controller = new Sound(this);
stop();
Symbol 700 MovieClip [fx_mc] Frame 39
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 65
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 155
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 198
stop();
Symbol 700 MovieClip [fx_mc] Frame 225
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 231
_parent.music.unmute();
stop();
Symbol 700 MovieClip [fx_mc] Frame 299
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 365
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 387
stop();
Symbol 700 MovieClip [fx_mc] Frame 415
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 430
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 460
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 490
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 508
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 569
this.endFX();
stop();
Symbol 700 MovieClip [fx_mc] Frame 630
this.endFX();
stop();
Symbol 703 Button
on (release) {
if (0 < _root.global_sound.getVolume()) {
_root.global_sound.setVolume(0);
this.gotoAndStop("off");
} else {
_root.global_sound.setVolume(_root.global_sound.original_volume);
this.gotoAndStop("on");
}
}
Symbol 706 MovieClip [sound_toggle_mc] Frame 1
stop();
Symbol 706 MovieClip [sound_toggle_mc] Frame 10
stop();
Symbol 713 Button
on (release) {
_parent.playMain();
}
Symbol 716 Button
on (release) {
gotoAndStop (20);
}
Symbol 719 Button
on (release) {
_parent.playMain();
}
Symbol 720 Button
on (release) {
gotoAndStop (1);
}
Symbol 722 MovieClip Frame 1
stop();
Symbol 722 MovieClip Frame 20
stop();