Frame 1
stop();
Instance of Symbol 10 MovieClip [loader] in Frame 1
onClipEvent (enterFrame) {
loadingPercent = Math.round((_root.getBytesLoaded() / _root.getBytesTotal()) * 100);
_xscale = loadingPercent;
_parent.loadDisplay = loadingPercent + "%";
if (_root.getBytesLoaded() == _root.getBytesTotal()) {
_parent.gotoAndPlay(3);
}
}
Instance of Symbol 10 MovieClip [loader] in Frame 1
onClipEvent (enterFrame) {
loadingPercent = Math.round((_root.getBytesLoaded() / _root.getBytesTotal()) * 100);
_xscale = loadingPercent;
if (_root.getBytesLoaded() == _root.getBytesTotal()) {
_parent.gotoAndPlay(3);
}
}
Frame 2
stop();
Frame 3
function Balls(cx1, cy1, cd1, cx2, cy2, cd2, cx3, cy3, cd3, cx4, cy4, cd4, cx5, cy5, cd5, cx6, cy6, cd6, cx7, cy7, cd7, cx8, cy8, cd8, cx9, cy9, cd9, cx10, cy10, cd10, cx11, cy11, cd11, cx12, cy12, cd12, cx13, cy13, cd13, cx14, cy14, cd14, cx15, cy15, cd15, cx16, cy16, cd16, cx17, cy17, cd17, cx18, cy18, cd18, cx19, cy19, cd19, cx20, cy20, cd20, cx21, cy21, cd21, cx22, cy22, cd22, cx23, cy23, cd23, cx24, cy24, cd24, cx25, cy25, cd25) {
this.cbx1 = cx1;
this.cby1 = cy1;
this.cbd1 = cd1;
this.cbx2 = cx2;
this.cby2 = cy2;
this.cbd2 = cd2;
this.cbx3 = cx3;
this.cby3 = cy3;
this.cbd3 = cd3;
this.cbx4 = cx4;
this.cby4 = cy4;
this.cbd4 = cd4;
this.cbx5 = cx5;
this.cby5 = cy5;
this.cbd5 = cd5;
this.cbx6 = cx6;
this.cby6 = cy6;
this.cbd6 = cd6;
this.cbx7 = cx7;
this.cby7 = cy7;
this.cbd7 = cd7;
this.cbx8 = cx8;
this.cby8 = cy8;
this.cbd8 = cd8;
this.cbx9 = cx9;
this.cby9 = cy9;
this.cbd9 = cd9;
this.cbx10 = cx10;
this.cby10 = cy10;
this.cbd10 = cd10;
this.cbx11 = cx11;
this.cby11 = cy11;
this.cbd11 = cd11;
this.cbx12 = cx12;
this.cby12 = cy12;
this.cbd12 = cd12;
this.cbx13 = cx13;
this.cby13 = cy13;
this.cbd13 = cd13;
this.cbx14 = cx14;
this.cby14 = cy14;
this.cbd14 = cd14;
this.cbx15 = cx15;
this.cby15 = cy15;
this.cbd15 = cd15;
this.cbx16 = cx16;
this.cby16 = cy16;
this.cbd16 = cd16;
this.cbx17 = cx17;
this.cby17 = cy17;
this.cbd17 = cd17;
this.cbx18 = cx18;
this.cby18 = cy18;
this.cbd18 = cd18;
this.cbx19 = cx19;
this.cby19 = cy19;
this.cbd19 = cd19;
this.cbx20 = cx20;
this.cby20 = cy20;
this.cbd20 = cd20;
this.cbx21 = cx21;
this.cby21 = cy21;
this.cbd21 = cd21;
this.cbx22 = cx22;
this.cby22 = cy22;
this.cbd22 = cd22;
this.cbx23 = cx23;
this.cby23 = cy23;
this.cbd23 = cd23;
this.cbx24 = cx24;
this.cby24 = cy24;
this.cbd24 = cd24;
this.cbx25 = cx25;
this.cby25 = cy25;
this.cbd25 = cd25;
}
function Boxes(x1, y1, x2, y2, x3, y3, x4, y4, x5, y5, x6, y6, x7, y7, x8, y8, x9, y9, x10, y10, x11, y11, x12, y12, x13, y13, x14, y14, x15, y15, x16, y16, x17, y17, x18, y18, x19, y19, x20, y20, x21, y21, x22, y22, x23, y23, x24, y24, x25, y25, x26, y26, x27, y27, x28, y28, x29, y29, x30, y30, x31, y31, x32, y32, x33, y33, x34, y34, x35, y35, x36, y36, x37, y37, x38, y38, x39, y39, x40, y40, x41, y41, x42, y42, x43, y43, x44, y44, x45, y45, x46, y46, x47, y47, x48, y48, x49, y49, x50, y50, x51, y51, x52, y52, x53, y53, x54, y54, x55, y55, x56, y56, x57, y57, x58, y58, x59, y59, x60, y60, x61, y61, x62, y62, x63, y63, x64, y64, x65, y65, x66, y66, x67, y67, x68, y68, x69, y69, x70, y70, x71, y71, x72, y72, x73, y73, x74, y74, x75, y75) {
this.bx1 = x1;
this.by1 = y1;
this.bx2 = x2;
this.by2 = y2;
this.bx3 = x3;
this.by3 = y3;
this.bx4 = x4;
this.by4 = y4;
this.bx5 = x5;
this.by5 = y5;
this.bx6 = x6;
this.by6 = y6;
this.bx7 = x7;
this.by7 = y7;
this.bx8 = x8;
this.by8 = y8;
this.bx9 = x9;
this.by9 = y9;
this.bx10 = x10;
this.by10 = y10;
this.bx11 = x11;
this.by11 = y11;
this.bx12 = x12;
this.by12 = y12;
this.bx13 = x13;
this.by13 = y13;
this.bx14 = x14;
this.by14 = y14;
this.bx15 = x15;
this.by15 = y15;
this.bx16 = x16;
this.by16 = y16;
this.bx17 = x17;
this.by17 = y17;
this.bx18 = x18;
this.by18 = y18;
this.bx19 = x19;
this.by19 = y19;
this.bx20 = x20;
this.by20 = y20;
this.bx21 = x21;
this.by21 = y21;
this.bx22 = x22;
this.by22 = y22;
this.bx23 = x23;
this.by23 = y23;
this.bx24 = x24;
this.by24 = y24;
this.bx25 = x25;
this.by25 = y25;
this.bx26 = x26;
this.by26 = y26;
this.bx27 = x27;
this.by27 = y27;
this.bx28 = x28;
this.by28 = y28;
this.bx29 = x29;
this.by29 = y29;
this.bx30 = x30;
this.by30 = y30;
this.bx31 = x31;
this.by31 = y31;
this.bx32 = x32;
this.by32 = y32;
this.bx33 = x33;
this.by33 = y33;
this.bx34 = x34;
this.by34 = y34;
this.bx35 = x35;
this.by35 = y35;
this.bx36 = x36;
this.by36 = y36;
this.bx37 = x37;
this.by37 = y37;
this.bx38 = x38;
this.by38 = y38;
this.bx39 = x39;
this.by39 = y39;
this.bx40 = x40;
this.by40 = y40;
this.bx41 = x41;
this.by41 = y41;
this.bx42 = x42;
this.by42 = y42;
this.bx43 = x43;
this.by43 = y43;
this.bx44 = x44;
this.by44 = y44;
this.bx45 = x45;
this.by45 = y45;
this.bx46 = x46;
this.by46 = y46;
this.bx47 = x47;
this.by47 = y47;
this.bx48 = x48;
this.by48 = y48;
this.bx49 = x49;
this.by49 = y49;
this.bx50 = x50;
this.by50 = y50;
this.bx51 = x51;
this.by51 = y51;
this.bx52 = x52;
this.by52 = y52;
this.bx53 = x53;
this.by53 = y53;
this.bx54 = x54;
this.by54 = y54;
this.bx55 = x55;
this.by55 = y55;
this.bx56 = x56;
this.by56 = y56;
this.bx57 = x57;
this.by57 = y57;
this.bx58 = x58;
this.by58 = y58;
this.bx59 = x59;
this.by59 = y59;
this.bx60 = x60;
this.by60 = y60;
this.bx61 = x61;
this.by61 = y61;
this.bx62 = x62;
this.by62 = y62;
this.bx63 = x63;
this.by63 = y63;
this.bx64 = x64;
this.by64 = y64;
this.bx65 = x65;
this.by65 = y65;
this.bx66 = x66;
this.by66 = y66;
this.bx67 = x67;
this.by67 = y67;
this.bx68 = x68;
this.by68 = y68;
this.bx69 = x69;
this.by69 = y69;
this.bx70 = x70;
this.by70 = y70;
this.bx71 = x71;
this.by71 = y71;
this.bx72 = x72;
this.by72 = y72;
this.bx73 = x73;
this.by73 = y73;
this.bx74 = x74;
this.by74 = y74;
this.bx75 = x75;
this.by75 = y75;
}
stopAllSounds();
var siteStyle = new TextFormat();
siteStyle.font = "OE2";
siteStyle.size = 18;
siteStyle.color = 16776960 /* 0xFFFF00 */;
siteStyle.bold = true;
maxTrk = new Sound();
maxTrk.attachSound("MaxTrax");
pulsnd = new Sound();
pulsnd.attachSound("Pulsar");
ambs = new Sound();
ambs.attachSound("Amb");
ups = new Sound();
ups.attachSound("Up");
bmp = new Sound();
bmp.attachSound("bump");
pu = new Sound();
pu.attachSound("pickup");
dr = new Sound();
dr.attachSound("drop");
oc = new Sound();
oc.attachSound("Ouch");
yw = new Sound();
yw.attachSound("YouWin");
lr = new Sound();
lr.attachSound("LeftRight");
drr = new Sound();
drr.attachSound("Door");
go = new Sound();
go.attachSound("GameOver");
max = {};
max2 = {};
tit = {};
brief1 = {};
win = {};
spi = {};
long1 = {};
ins1 = {};
flame = {};
power = {};
ouch = {};
theend = {};
roomNumber = 1;
rooms = 9;
lives = 9;
Mouse.addListener(_root);
tit.mc = attachMovie("Title", "tit2", 10000, 1);
wall = new Array(rooms);
plant = new Array(rooms);
dor = new Array(rooms);
ba = new Array(rooms);
bb = new Array(rooms);
balls = new Array(26);
ballxt = new Array(26);
ballyt = new Array(26);
ballxi = new Array(26);
ballyi = new Array(26);
boxes = new Array(76);
numBoxes = [9, 12, 42, 24, 12, 15, 74, 20, 28];
numBalls = [8, 10, 15, 7, 0, 13, 25, 10, 9];
maxStartx = [228, 444, 228, 444, 444, 444, 444, 60, 444];
maxStarty = [328, 328, 40, 328, 56, 328, 328, 328, 328];
plantX = [12, 12, 12, 12, 12, -100, -100, 12, 108];
plantY = [8, 8, 136, 8, 8, -100, -100, 8, 72];
wallX = [12, 12, 12, -12, 12, 12, 12, 12, 12];
wallY = [8, 8, 8, 8, 8, 8, 8, 8, 8];
doorX = [12, 228, 60, 60, -100, 12, 36, 12, 468];
doorY = [296, 360, 296, 72, -100, 328, 8, 312, 328];
powerX = [60, 60, 228, 12, -100, 420, 60, 444, 252];
powerY = [40, 328, 280, 168, -100, 40, 328, 344, 200];
baX = [-100, 372, -100, 84, 36, -100, -100, 252, 60];
baY = [-100, 152, -100, 312, 24, -100, -100, 104, 72];
bbX = [-100, 372, -100, 396, 36, -100, -100, 252, 132];
bbY = [-100, 200, -100, 312, 24, -100, -100, 104, 72];
ball = new Array();
box = new Array();
i = 1;
while (i < (rooms + 1)) {
wall[i] = {};
plant[i] = {};
dor[i] = {};
ba[i] = {};
bb[i] = {};
i++;
}
j = 1;
while (j < 76) {
boxes[j] = {};
j++;
}
k = 1;
while (k < 26) {
balls[k] = {};
k++;
}
Frame 4
stopAllSounds();
tit.mc._alpha = 100;
maxTrk.start(0, 9);
onEnterFrame = function () {
_root.onMouseDown = function () {
tit.mc._alpha = 0;
gotoAndStop (5);
};
};
stop();
Frame 5
brief1.mc = attachMovie("Brief1", "brief2", 6900, 1);
ins1.mc = attachMovie("Instructions1", "inst1", 6901, 1);
ins1.mc._alpha = 100;
this.createTextField("textWindow", 6600, 10, 0, 492, 2830);
textWindow.background = true;
textWindow.backgroundColor = 0;
textWindow.border = false;
textWindow.type = "static";
textWindow.multiline = true;
textWindow.wordWrap = true;
textWindow.embedFonts = true;
textWindow.cacheAsBitmap = true;
MasterText = "\r\r\r\r\r\r\r\r\r\r\r\rMAXIMILLIAN B.\r\rBy J.D. Casten \u2013 (designed for the 8-bit Atari in 1987)\r\r Maximillian B. approached the large oak doors slowly and cautiously. As he drew ever closer, the doors creaked open, revealing an office the size of a basketball court and barren except for a large desk.\r\r \"Hurry up, Maxy babe,\" echoed a voice from behind the desk. \"My oh my, what a beak you have! You know, plastic surgery can do wonders these days.\" Max's bill began to clatter. Aunt Icked, the family's wealthy oddball, always gave him the chills.\r\r \"You asked to see me?\" gagged Max. Aunt Icked rarely summoned him just to make fun of his long beak.\r\r \"Yes Max, I have an assignment for you. This is big-time, Max.\" Aunt Icked pulled a few documents and a train ticket out of her desk and handed them to Max.\r\r \"Shouldn't cousin Sly handle matters of this sort? I'm an inventor, not an inspector.\" But Max's heart began to pound harder: this was a dream come true for him.\r\r \"No,\" replied Aunt Icked, \"this job requires someone with extra brain-power -- but you'll do. You and your Clijum-9 aircar are perfect for this mission. Besides, Sly has had terrible nightmares lately, and he needs all the rest he can get.\"\r\r \"What's the mission?\" questioned Max. Max swelled with pride: he had become an inspector.\r\r Aunt Icked sighed gravely. \"A Mechanical Electrical Operational Weapon manufactured by Icked Industries has gone haywire. The contraption took off in the middle of the night and holed up somewhere in the Rodentential section of Burger city. Evidently the machine has been terrorizing the mice and other rodent residents. Your mission is to enter the fortress and destroy the Mechanical Electrical Operational Weapon. The details are in those documents. Get your little ducktail moving.\"\r\rTHE MISSION\r\r On the train ride to Burger City, Max studied the material. Apparently the mechanical menace had built a fortress in a large mountain of deadly vampire vegetation. Max would have to climb and jump on the framework of the fortress, but could he avoid the vampire vegetation?\r\r The fortress has nine rooms, most of them isolated from one another by locked doors. The only way for Max to unlock a door is to overload the power pulsar in each room by feeding all the power charges from the room into the pulsar. The power charges move in straight paths until something blocks their way, making them turn counter-clockwise. The charges are lethal, so Max will need to move special electro-cubes around to change the paths of the charges.\r\r Once Max finds the Mechanical Electrical Operational Weapon, he must neutralize it with charges to complete his mission.\r\rCLIJUM-9 OPERATION\r\r In his amazing Clijum-9 micromini aircar, Max can move horizontally, jump, climb walls and pick up and deposit electro-cubes.\r\r To move, press the left or right arrow keys. To jump, press the space bar. To climb, press the space bar while facing in the direction of a wall (pressing the arrow key makes the Clijum-9 grasp the wall). Press the shift key to face forward.\r\r To pick up an electro-cube, press up the up arrow key; and to put one down, press the down arrow key. Picking up an electro-cube requires that the cube be in front of Max's aircar. When Max picks up an electro-cube, it becomes semi-material, and can be moved trough objects: but it must be dropped in an open space\u2014and it will deflect power-charges even in this semi-material state.\r\r Max begins with nine lives in Room One of the fortress. If Max loses a life, he'll have to start over at the room entrance. This \"room restart\" can also be activated at any time without losing a life by pressing the [Esc] key. The game ends when Max destroys the Mechanical Electrical Operational Weapon or when he loses all nine lives.\r\rHINTS\r\r First, get thoroughly familiar with the Clijum-9 aircar. Remember that left and right motion in jumps can be controlled continually with the arrow keys. Max is tough and can take falls from any height. He can't fly, but he can glide down in any direction. Electro-cubes can be put anywhere -- even in mid-air.\r\r Maximillian B. is just as much a game of intellect as of dexterity. Completion of the game rests heavily on strategic positioning of the electro-cubes. It only takes one cube to change the direction of a charge. In some cases (such as room one -- this is a hint) the charges will be trapped by Electro-cubes, and Max must set them free. On these screens, it is wise to set up a path for the charges to follow before letting them free.\r\r There are many ways to solve each screen, and it is possible to complete the mission.\r\r Good luck to you and Max!\r\r(Cheat Codes at www.jdcasten.info)\r\r\r\r\r\r\r\r\r\r\r\r\r";
textWindow.text = MasterText;
textWindow.setTextFormat(siteStyle);
brief1.mc._y = 262;
onEnterFrame = function () {
if (Key.isDown(32)) {
ins1.mc._alpha = 0;
removeMovieClip(brief1.mc);
removeMovieClip(ins1.mc);
textWindow.removeTextField();
maxTrk.stop();
gotoAndPlay (10);
}
textWindow._y = textWindow._y - 0.5;
if (textWindow._y < -2560) {
textWindow._y = 0;
}
};
stop();
Frame 10
onEnterFrame = function () {
ball[1] = new Balls(36, 296, 1, 60, 296, 1, 84, 296, 1, 36, 312, 1, 84, 312, 1, 36, 328, 1, 60, 328, 1, 84, 328, 1);
ball[2] = new Balls(132, 312, 2, 180, 312, 2, 228, 312, 2, 276, 312, 2, 324, 312, 2, 132, 344, 2, 180, 344, 2, 228, 344, 2, 276, 344, 2, 324, 344, 2);
ball[3] = new Balls(180, 136, 1, 204, 136, 1, 228, 136, 1, 252, 136, 1, 276, 136, 1, 180, 152, 1, 204, 152, 1, 228, 152, 1, 252, 152, 1, 276, 152, 1, 180, 168, 1, 204, 168, 1, 228, 168, 1, 252, 168, 1, 276, 168, 1);
ball[4] = new Balls(252, 56, 4, 252, 104, 4, 252, 152, 4, 252, 200, 4, 252, 248, 4, 372, 312, 3, 108, 344, 1);
ball[5] = new Balls(0, 0, 0);
ball[6] = new Balls(108, 24, 4, 252, 40, 1, 204, 136, 3, 324, 232, 1, 36, 280, 1, 60, 280, 1, 84, 280, 1, 36, 312, 1, 60, 312, 1, 84, 312, 1, 36, 344, 1, 60, 344, 1, 84, 344, 1);
ball[7] = new Balls(252, 40, 2, 300, 40, 1, 324, 40, 1, 348, 40, 1, 372, 40, 1, 396, 40, 1, 420, 40, 1, 324, 56, 1, 348, 56, 1, 396, 56, 1, 420, 56, 1, 324, 72, 1, 348, 72, 1, 372, 72, 1, 396, 72, 1, 420, 72, 1, 132, 88, 4, 252, 88, 2, 348, 88, 1, 372, 88, 1, 396, 88, 1, 420, 88, 1, 396, 104, 1, 420, 104, 1, 132, 136, 4);
ball[8] = new Balls(204, 24, 3, 84, 40, 2, 132, 40, 4, 84, 88, 2, 84, 136, 2, 132, 136, 4, 84, 184, 2, 84, 232, 2, 132, 232, 4, 84, 280, 2);
ball[9] = new Balls(132, 120, 1, 156, 104, 3, 228, 104, 3, 300, 104, 3, 372, 104, 3, 372, 136, 2, 372, 184, 2, 372, 232, 2, 372, 264, 1);
box[1] = new Boxes(372, 88, 372, 168, 372, 184, 372, 200, 372, 280, 36, 280, 60, 280, 84, 280, 108, 280);
box[2] = new Boxes(372, 24, 396, 24, 372, 40, 396, 40, 372, 56, 396, 56, 372, 312, 396, 312, 372, 328, 396, 328, 372, 344, 396, 344);
box[3] = new Boxes(156, 120, 180, 120, 204, 120, 228, 120, 228, 120, 252, 120, 276, 120, 300, 120, 156, 136, 300, 136, 156, 152, 300, 152, 156, 168, 300, 168, 156, 184, 180, 184, 204, 184, 228, 184, 252, 184, 276, 184, 300, 184, 348, 248, 372, 248, 396, 248, 348, 264, 372, 264, 396, 264, 348, 280, 372, 280, 396, 280, 348, 296, 372, 296, 396, 296, 348, 312, 372, 312, 396, 312, 348, 328, 372, 328, 396, 328, 348, 344, 372, 344, 396, 344);
box[4] = new Boxes(324, 72, 324, 88, 324, 104, 204, 104, 204, 120, 204, 136, 180, 200, 204, 200, 228, 200, 180, 216, 204, 216, 228, 216, 180, 232, 204, 232, 228, 232, 180, 248, 204, 248, 228, 248, 180, 264, 204, 264, 228, 264, 180, 280, 204, 280, 228, 280);
box[5] = new Boxes(276, 56, 300, 56, 276, 72, 300, 72, 276, 184, 300, 184, 276, 200, 300, 200, 276, 248, 300, 248, 276, 264, 300, 264);
box[6] = new Boxes(36, 264, 60, 264, 84, 264, 108, 264, 108, 280, 36, 296, 60, 296, 84, 296, 108, 296, 108, 312, 36, 328, 60, 328, 84, 328, 108, 328, 108, 344);
box[7] = new Boxes(276, 40, 276, 56, 300, 56, 276, 72, 300, 72, 276, 88, 300, 88, 324, 88, 300, 104, 324, 104, 348, 104, 372, 104, 348, 120, 372, 120, 396, 120, 420, 120, 36, 168, 60, 168, 84, 168, 36, 184, 60, 184, 84, 184, 108, 184, 132, 184, 108, 200, 132, 200, 156, 200, 180, 200, 156, 216, 180, 216, 180, 232, 204, 232, 228, 232, 36, 248, 60, 248, 84, 248, 204, 248, 228, 248, 252, 248, 36, 264, 60, 264, 84, 264, 108, 264, 132, 264, 228, 264, 252, 264, 36, 280, 60, 280, 84, 280, 108, 280, 132, 280, 156, 280, 252, 280, 276, 280, 132, 296, 156, 296, 180, 296, 252, 296, 276, 296, 132, 312, 156, 312, 180, 312, 276, 312, 300, 312, 132, 328, 156, 328, 180, 328, 276, 328, 300, 328, 132, 344, 156, 344, 180, 344, 276, 344, 300, 344);
box[8] = new Boxes(108, 40, 108, 56, 108, 72, 108, 88, 108, 104, 108, 120, 108, 136, 108, 152, 108, 168, 420, 56, 420, 72, 372, 296, 396, 296, 420, 296, 444, 296, 468, 296, 372, 312, 372, 328, 372, 344, 372, 360);
box[9] = new Boxes(36, 88, 60, 88, 60, 120, 84, 120, 36, 152, 60, 152, 60, 184, 84, 184, 84, 200, 36, 216, 84, 216, 36, 232, 84, 232, 108, 264, 132, 328, 156, 328, 180, 328, 204, 328, 228, 328, 252, 328, 276, 328, 300, 328, 324, 328, 348, 328, 372, 328, 396, 264, 420, 56, 444, 56);
gotoAndPlay (12);
};
stop();
Frame 12
ambs.stop();
ambs.start(0, 100);
onEnterFrame = function () {
removeMovieClip(max.mc);
max.mc = attachMovie("MaxB", "max2", 7000, 1);
removeMovieClip(flame.mc);
flame.mc = attachMovie("Flame", "flame2", 1, 1);
removeMovieClip(power.mc);
power.mc = attachMovie("Power", "power2", 900, 1);
j = 1;
while (j < 76) {
removeMovieClip(boxes[j].mc);
if (j <= numBoxes[roomNumber - 1]) {
boxes[j].mc = attachMovie("Box", "box" + j, 300 + j, 1);
boxes[j].mc._x = box[roomNumber]["bx" + j];
boxes[j].mc._y = box[roomNumber]["by" + j];
}
j++;
}
i = 1;
while (i < 26) {
removeMovieClip(balls[i].mc);
if (i <= numBalls[roomNumber - 1]) {
balls[i].mc = attachMovie("Chaos", "chaos" + i, 400 + i, 1);
balls[i].mc._x = ball[roomNumber]["cbx" + i];
balls[i].mc._y = ball[roomNumber]["cby" + i];
ballxt[i] = ball[roomNumber]["cbx" + i];
ballyt[i] = ball[roomNumber]["cby" + i];
}
i++;
}
k = 1;
while (k <= rooms) {
removeMovieClip(dor[k].mc);
removeMovieClip(wall[k].mc);
removeMovieClip(plant[k].mc);
removeMovieClip(ba[k].mc);
removeMovieClip(bb[k].mc);
k++;
}
ba[roomNumber].mc = attachMovie("BlinkA" + roomNumber, "bla", 80 + roomNumber, 1);
bb[roomNumber].mc = attachMovie("BlinkB" + roomNumber, "blb", 90 + roomNumber, 1);
dor[roomNumber].mc = attachMovie("Door" + roomNumber, "door", 70 + roomNumber, 1);
wall[roomNumber].mc = attachMovie("Walls" + roomNumber, "walls", 500 + roomNumber, 1);
plant[roomNumber].mc = attachMovie("Plants" + roomNumber, "plants", 60 + roomNumber, 1);
wall[roomNumber].mc._xscale = 100;
wall[roomNumber].mc._yscale = 100;
plant[roomNumber].mc._xscale = 100;
plant[roomNumber].mc._yscale = 100;
dor[roomNumber].mc._xscale = 100;
dor[roomNumber].mc._yscale = 100;
ba[roomNumber].mc._xscale = 100;
bb[roomNumber].mc._yscale = 100;
ba[roomNumber].mc._xscale = 100;
bb[roomNumber].mc._yscale = 100;
wall[roomNumber].mc._x = wallX[roomNumber - 1];
wall[roomNumber].mc._y = wallY[roomNumber - 1];
dor[roomNumber].mc._x = doorX[roomNumber - 1];
dor[roomNumber].mc._y = doorY[roomNumber - 1];
plant[roomNumber].mc._x = plantX[roomNumber - 1];
plant[roomNumber].mc._y = plantY[roomNumber - 1];
maxx = maxStartx[roomNumber - 1];
maxy = maxStarty[roomNumber - 1];
max.mc._x = maxx;
max.mc._y = maxy;
power.mc._x = powerX[roomNumber - 1];
power.mc._y = powerY[roomNumber - 1];
ba[roomNumber].mc._x = baX[roomNumber - 1];
ba[roomNumber].mc._y = baY[roomNumber - 1];
bb[roomNumber].mc._x = bbX[roomNumber - 1];
bb[roomNumber].mc._y = bbY[roomNumber - 1];
max.mc._rotation = 0;
max.mc._alpha = 100;
max.mc._xscale = 100;
max.mc._yscale = 100;
_root.image = 1;
img = 1;
blink = 0;
carry = 0;
zapped = 0;
center = 32;
gotoAndStop (15);
};
Frame 15
count = 0;
cx = 0;
cy = 0;
onEnterFrame = function () {
count = count + 1;
if (count == 4) {
killed = 0;
if ((((((((maxx == powerX[roomNumber - 1]) && ((maxy == powerY[roomNumber - 1]) || (maxy == (powerY[roomNumber - 1] - 16)))) || (plant[roomNumber].mc.hitTest(maxx + 1, maxy, true))) || (plant[roomNumber].mc.hitTest(maxx + 1, maxy + 16, true))) || (ba[roomNumber].mc.hitTest(maxx + 8, maxy, true))) || (ba[roomNumber].mc.hitTest(maxx + 8, maxy + 16, true))) || (bb[roomNumber].mc.hitTest(maxx + 8, maxy, true))) || (bb[roomNumber].mc.hitTest(maxx + 8, maxy + 16, true))) {
killed = 1;
gotoAndPlay (17);
} else {
if (((((maxx < 36) || (maxy > 372)) || (maxy < 24)) && (killed == 0)) || (Key.isDown(33))) {
if (roomNumber < 9) {
roomNumber = roomNumber + 1;
gotoAndStop (10);
} else {
gotoAndPlay (24);
}
}
count = 0;
oldboxdown = boxdown;
oy = maxy;
boxup = 0;
boxupleft = 0;
boxleft = 0;
boxupright = 0;
boxright = 0;
boxdown = 0;
lowbox = 0;
center = center - 1;
if (Key.isDown(45)) {
lives = lives + 1;
}
if (Key.isDown(16) || (center == 0)) {
img = 2;
_root.eyes = 0;
if (carry > 0) {
box[roomNumber]["bx" + carry] = maxx;
}
}
if (center == -16) {
center = 6;
_root.eyes = Math.floor(Math.random() * 2);
}
n = 1;
while (n <= numBoxes[roomNumber - 1]) {
if (n != carry) {
tbx = box[roomNumber]["bx" + n];
tby = box[roomNumber]["by" + n];
if (tby == (maxy + 16)) {
if (tbx == (maxx - 24)) {
boxleft = 1;
if (img == 1) {
lowbox = n;
}
}
if (tbx == (maxx + 24)) {
boxright = 1;
if (img == 3) {
lowbox = n;
}
}
}
if (tby == maxy) {
if (tbx == (maxx - 24)) {
boxupleft = 1;
}
if (tbx == (maxx + 24)) {
boxupright = 1;
}
}
}
n++;
}
left = 0;
right = 0;
up = 0;
olddown = down;
down = 0;
if ((((((((((boxleft == 1) || (boxupleft == 1)) || (wall[roomNumber].mc.hitTest(maxx - 8, maxy, true))) or wall[roomNumber].mc.hitTest(maxx - 8, maxy + 24, true)) or dor[roomNumber].mc.hitTest(maxx - 8, macy, true)) || (dor[roomNumber].mc.hitTest(maxx - 8, maxy + 24, true))) or ba[roomNumber].mc.hitTest(maxx - 8, maxy, true)) or ba[roomNumber].mc.hitTest(maxx - 8, maxy + 24, true)) || (bb[roomNumber].mc.hitTest(maxx - 8, maxy, true))) || (bb[roomNumber].mc.hitTest(maxx - 8, maxy + 24, true))) {
left = 1;
}
if ((((((((((boxright == 1) || (boxupright == 1)) || (wall[roomNumber].mc.hitTest(maxx + 48, maxy, true))) or wall[roomNumber].mc.hitTest(maxx + 48, maxy + 16, true)) or dor[roomNumber].mc.hitTest(maxx + 48, macy, true)) || (dor[roomNumber].mc.hitTest(maxx + 48, maxy + 16, true))) or ba[roomNumber].mc.hitTest(maxx + 48, maxy, true)) or ba[roomNumber].mc.hitTest(maxx + 48, maxy + 16, true)) || (bb[roomNumber].mc.hitTest(maxx + 48, maxy, true))) || (bb[roomNumber].mc.hitTest(maxx + 48, maxy + 16, true))) {
right = 1;
}
keyLeft = 0;
keyRight = 0;
oldcling = cling;
cling = 0;
if (Key.isDown(37)) {
center = 18;
if (left == 0) {
maxx = maxx - 24;
lr.start(0, 1);
} else {
cling = 1;
}
img = img - 1;
keyLeft = 1;
if (img < 1) {
img = 1;
}
}
if (Key.isDown(39)) {
center = 18;
if (right == 0) {
maxx = maxx + 24;
lr.start(0, 1);
} else {
cling = 1;
}
img = img + 1;
keyRight = 1;
if (img > 3) {
img = 3;
}
}
n = 1;
while (n <= numBoxes[roomNumber - 1]) {
if (n != carry) {
tbx = box[roomNumber]["bx" + n];
tby = box[roomNumber]["by" + n];
if ((maxx == tbx) && (tby == (maxy - 16))) {
boxup = 1;
}
if ((maxx == tbx) && (tby == (maxy + 32))) {
boxdown = 1;
}
}
n++;
}
if (((((boxup == 1) || (wall[roomNumber].mc.hitTest(maxx + 8, maxy - 16, true))) || (dor[roomNumber].mc.hitTest(maxx + 8, maxy - 16, true))) || (ba[roomNumber].mc.hitTest(maxx + 8, maxy - 16, true))) || (bb[roomNumber].mc.hitTest(maxx + 8, maxy - 16, true))) {
up = 1;
}
if (((((boxdown == 1) || (wall[roomNumber].mc.hitTest(maxx + 8, maxy + 38, true))) || (dor[roomNumber].mc.hitTest(maxx + 8, maxy + 38, true))) || (ba[roomNumber].mc.hitTest(maxx + 8, maxy + 38, true))) || (bb[roomNumber].mc.hitTest(maxx + 8, maxy + 38, true))) {
down = 1;
}
if ((((down == 0) && (boxdown == 0)) && (jump <= 1)) && (cling == 0)) {
maxy = maxy + 16;
}
jump = jump - 1;
if (Key.isDown(38)) {
if ((lowbox > 0) and (carry == 0)) {
pu.start(0, 1);
carry = lowbox;
center = 0;
}
}
if (Key.isDown(40)) {
caryhit = 0;
center = 0;
o = 1;
while (o <= numBoxes[roomNumber - 1]) {
cbx = box[roomNumber]["bx" + o];
cby = box[roomNumber]["by" + o];
if (((cx == cbx) && (cy == cby)) && (o != carry)) {
caryhit = 1;
}
o++;
}
p = 1;
while (p <= numBalls[roomNumber - 1]) {
cbx = balls[roomNumber]["cbx" + p];
cby = balls[roomNumber]["cby" + p];
if ((cx == cbx) && (cy == cby)) {
caryhit = 1;
}
p++;
}
if (wall[roomNumber].mc.hitTest(cx + 24, cy, true) or plant[roomNumber].mc.hitTest(cx + 24, cy, true)) {
caryhit = 1;
}
if ((carry > 0) && (caryhit == 0)) {
dr.start(0, 1);
if (img == 2) {
cx = maxx;
cy = maxy + 16;
box[roomNumber]["bx" + carry] = maxx;
}
boxes[carry].mc._y = box[roomNumber]["bx" + carry];
boxes[carry].mc._y = box[roomNumber]["by" + carry];
boxes[carry].mc._alpha = 100;
carry = 0;
}
} else if (carry > 0) {
ocx = cx;
ocy = cy;
cr = carry;
caryhit = 0;
cy = maxy + 16;
if (img == 1) {
cx = maxx + 24;
}
if (img == 3) {
cx = maxx - 24;
}
if ((img != 1) && (img != 3)) {
cx = maxx;
}
box[roomNumber]["bx" + cr] = cx;
box[roomNumber]["by" + cr] = cy;
}
if (Key.isDown(27)) {
gotoAndPlay (10);
}
flamea = 10;
if (Key.isDown(32)) {
ups.start(0, 1);
flamea = 100;
if ((((img == 3) and (right == 1)) or ((img == 1) and (left == 1))) and (up == 0)) {
maxy = oy - 16;
} else if (((up == 0) and (jump <= 1)) and ((((down == 1) or (olddown == 1)) or (oldboxdown == 1)) or (oldcling == 1))) {
maxy = oy - 16;
jump = 5;
}
}
flame.mc._alpha = flamea;
_root.image = img;
blink = blink + 1;
if (blink == 16) {
ba[roomNumber].mc = attachMovie("BlinkA" + roomNumber, "bla", 5080 + roomNumber, 1);
ba[roomNumber].mc._x = baX[roomNumber - 1];
ba[roomNumber].mc._y = baY[roomNumber - 1];
removeMovieClip(bb[roomNumber].mc);
}
if (blink == 32) {
bb[roomNumber].mc = attachMovie("BlinkB" + roomNumber, "blb", 5090 + roomNumber, 1);
bb[roomNumber].mc._x = bbX[roomNumber - 1];
bb[roomNumber].mc._y = bbY[roomNumber - 1];
removeMovieClip(ba[roomNumber].mc);
blink = 0;
}
nobump = 0;
i = 1;
while (i <= numBalls[roomNumber - 1]) {
oldx = ball[roomNumber]["cbx" + i];
oldy = ball[roomNumber]["cby" + i];
dir = ball[roomNumber]["cbd" + i];
xx = oldx;
yy = oldy;
if ((xx == powerX[roomNumber - 1]) && (yy == powerY[roomNumber - 1])) {
if (dir > 0) {
ball[roomNumber]["cbd" + i] = 0;
balls[i].mc._xscale = 300;
balls[i].mc._yscale = 300;
balls[i].mc._x = xx - 24;
balls[i].mc._y = yy - 16;
balls[i].mc._alpha = 20;
pulsnd.start(0, 1);
zapped = zapped + 1;
if (zapped == numBalls[roomNumber - 1]) {
drr.start(0, 1);
removeMovieClip(dor[roomNumber].mc);
}
}
} else {
if (dir == 1) {
xx = xx + 24;
ballxt[i] = xx;
}
if (dir == 2) {
yy = yy - 16;
ballyt[i] = yy;
}
if (dir == 3) {
xx = xx - 24;
ballxt[i] = xx;
}
if (dir == 4) {
yy = yy + 16;
ballyt[i] = yy;
}
ht = 0;
j = 1;
while (j <= numBalls[roomNumber - 1]) {
if (((xx == ball[roomNumber]["cbx" + j]) && (yy == ball[roomNumber]["cby" + j])) && (ball[roomNumber]["cbd" + j] > 0)) {
ht = 1;
}
j++;
}
k = 1;
while (k <= numBoxes[roomNumber - 1]) {
if ((xx == box[roomNumber]["bx" + k]) && (yy == box[roomNumber]["by" + k])) {
ht = 1;
}
k++;
}
if (((((wall[roomNumber].mc.hitTest(xx + 24, yy, true) || (dor[roomNumber].mc.hitTest(xx + 24, yy, true))) || (plant[roomNumber].mc.hitTest(xx + 24, yy, true))) || (ba[roomNumber].mc.hitTest(xx + 24, yy, true))) || (bb[roomNumber].mc.hitTest(xx + 24, yy, true))) || (ht == 1)) {
ballxt[i] = oldx;
ballyt[i] = oldy;
dir = dir + 1;
if (nobump == 0) {
bmp.start(0, 1);
nobump = 1;
}
ball[roomNumber]["cbd" + i] = dir;
if (dir >= 5) {
dir = 1;
ball[roomNumber]["cbd" + i] = dir;
}
} else {
ball[roomNumber]["cbx" + i] = xx;
ball[roomNumber]["cby" + i] = yy;
if (((maxy == yy) or (maxy == (yy - 16))) && (maxx == xx)) {
gotoAndStop (17);
}
}
}
i++;
}
}
}
m = 1;
while (m <= numBalls[roomNumber - 1]) {
if (ball[roomNumber]["cbd" + m] != 0) {
if (ballxt[m] > balls[m].mc._x) {
balls[m].mc._x = balls[m].mc._x + 6;
}
if (ballxt[m] < balls[m].mc._x) {
balls[m].mc._x = balls[m].mc._x - 6;
}
if (ballyt[m] > balls[m].mc._y) {
balls[m].mc._y = balls[m].mc._y + 4;
}
if (ballyt[m] < balls[m].mc._y) {
balls[m].mc._y = balls[m].mc._y - 4;
}
}
m++;
}
if (maxx > max.mc._x) {
max.mc._x = max.mc._x + 6;
}
if (maxx < max.mc._x) {
max.mc._x = max.mc._x - 6;
}
if (maxy > max.mc._y) {
max.mc._y = max.mc._y + 4;
}
if (maxy < max.mc._y) {
max.mc._y = max.mc._y - 4;
}
flame.mc._x = max.mc._x;
flame.mc._y = max.mc._y + 30;
if (carry > 0) {
boxes[carry].mc._y = max.mc._y + 16;
boxes[carry].mc._alpha = 50;
if (img == 1) {
boxes[carry].mc._x = max.mc._x + 24;
}
if (img == 3) {
boxes[carry].mc._x = max.mc._x - 24;
}
if ((img != 1) && (img != 3)) {
boxes[carry].mc._x = max.mc._x;
}
}
};
stop();
Frame 17
countera = 0;
counterb = 100;
flame.mc._alpha = 0;
ouch.mc = attachMovie("Ouchie", "ouchie2", 6000, 1);
ouch.mc._alpha = 0;
stopAllSounds();
oc.start(0, 1);
onEnterFrame = function () {
max.mc._alpha = 100 - countera;
max.mc._xscale = countera * 10;
max.mc._yscale = countera * 10;
max.mc._x = max.mc._x - 2;
max.mc._y = max.mc._y - 2;
ouch.mc._alpha = countera;
counterb = counterb - 1;
countera = countera + 1;
if (countera >= 100) {
lives = lives - 1;
if (lives < 0) {
gotoAndPlay (20);
} else {
removeMovieClip(ouch.mc);
gotoAndPlay (10);
}
}
};
stop();
Frame 20
theend.mc = attachMovie("THEND", "thend2", 6005, 1);
theend.mc._x = 251;
theend.mc._y = 208;
theend.mc._xscale = 0;
theend.mc._yscale = 0;
counterb = 0;
oc.stop();
go.start(0, 2);
onEnterFrame = function () {
if (counterb <= 100) {
theend.mc._rotation = counterb * 7.2;
theend.mc._xscale = counterb;
theend.mc._yscale = counterb;
}
counterb = counterb + 1;
if (counterb > 400) {
removeMovieClip(theend.mc);
removeMovieClip(ouch.mc);
lives = 9;
roomNumber = 1;
gotoAndPlay (4);
}
};
stop();
Frame 24
spi.mc = attachMovie("Spinner", "spin1", 9011, 1);
max2.mc = attachMovie("MaxB", "Maxwin2", 9020, 1);
win.mc = attachMovie("HurrayWin", "win2", 9015, 1);
stopAllSounds();
yw.start(0, 5);
spi.mc._x = 251;
spi.mc._y = 208;
max2.mc._x = 203;
max2.mc._y = 174;
max2.mc._xscale = 400;
max2.mc._yscale = 400;
_root.eyes = 0;
_root.image = 2;
counterc = 0;
max.mc._alpha = 0;
onEnterFrame = function () {
counterc = counterc + 1;
if (counterc == 16) {
_root.eyes = 1;
}
if (counterc == 32) {
_root.eyes = 0;
}
if ((counterc > 64) and (Math.floor(Math.random() * 100) == 0)) {
counterc = 0;
}
spi.mc._rotation = spi.mc._rotation + 5;
if (Key.isDown(32)) {
removeMovieClip(spi.mc);
removeMovieClip(win.mc);
removeMovieClip(max2.mc);
gotoAndPlay (4);
lives = 9;
roomNumber = 1;
}
};
stop();
Frame 25
stop();
Symbol 14 MovieClip [Spinner] Frame 1
_rotation = (_rotation + 1);
Symbol 117 MovieClip [MaxB] Frame 1
onEnterFrame = function () {
if (_root.eyes == 1) {
gotoAndPlay (5);
}
if (_root.image == 1) {
gotoAndPlay (2);
}
if ((_root.image == 2) and (_root.eyes != 1)) {
gotoAndPlay (3);
}
if (_root.image == 3) {
gotoAndPlay (4);
}
};
stop();
Symbol 117 MovieClip [MaxB] Frame 2
stop();
Symbol 117 MovieClip [MaxB] Frame 3
stop();
Symbol 117 MovieClip [MaxB] Frame 4
stop();
Symbol 176 MovieClip [Box] Frame 1
onEnterFrame = function () {
go = Math.floor(Math.random() * 4) + 2;
gotoAndPlay(go);
};
stop();
Symbol 176 MovieClip [Box] Frame 2
stop();
Symbol 176 MovieClip [Box] Frame 3
stop();
Symbol 176 MovieClip [Box] Frame 4
stop();
Symbol 176 MovieClip [Box] Frame 5
stop();