Frame 1
function gotoNextFrame() {
_root.gotoAndStop(2);
}
Stage.showMenu = false;
stop();
var previousTime = getTimer();
var waitTime = 3000;
var CPMStarPoolID = 1052;
var CPMStarSubPoolID = 12;
System.security.allowDomain("server.cpmstar.com");
adBox.loadMovie((("http://server.cpmstar.com/adviewas2.swf?poolid=" + CPMStarPoolID) + "&subpoolid=") + CPMStarSubPoolID);
var tempNum = 1;
myLSO = SharedObject.getLocal("OpenDoors2");
if (myLSO.data.myObj != undefined) {
tempNum = myLSO.data.myObj.objArray[4];
}
_root.bgGrid.gotoAndStop(tempNum);
_root.bgColor.gotoAndStop(tempNum);
_root.bgBorder.gotoAndStop(tempNum);
function preloaderInterval() {
if (_root.loadingBar._visible) {
PercentLoaded = (_root.getBytesLoaded() / _root.getBytesTotal()) * 100;
PercentTime = ((getTimer() - _root.previousTime) / _root.waitTime) * 100;
if (PercentTime > PercentLoaded) {
if (PercentLoaded != 100) {
_root.loadingBar.gotoAndStop(Math.floor((PercentLoaded / 100) * (_root.loadingBar._totalframes - 1)) + 1);
} else {
_root.loadingBar.gotoAndStop(_root.loadingBar._totalframes);
clearInterval(_root.interval);
}
} else if (PercentTime < PercentLoaded) {
if (PercentTime < 100) {
_root.loadingBar.gotoAndStop(Math.floor((PercentTime / 100) * (_root.loadingBar._totalframes - 1)) + 1);
} else {
_root.loadingBar.gotoAndStop(_root.loadingBar._totalframes);
clearInterval(_root.interval);
}
}
}
}
stop();
var PercentLoaded = ((_root.getBytesLoaded() / _root.getBytesTotal()) * 100);
var PercentTime = (((getTimer() - _root.previousTime) / _root.waitTime) * 100);
_root.loadingBar.gotoAndStop(1);
var interval = setInterval(preloaderInterval, 10);
Frame 2
function toggleSound() {
soundOn = !soundOn;
_root.SOUND_button.setVolume(100 * soundOn);
_root.SOUND_button.start();
_root.menuMusic.gotoAndStop(Number(soundOn) + 1);
if (_currentframe < 4) {
_root.menuMusic.bgMusic._visible = false;
} else {
_root.menuMusic.bgMusic._visible = soundOn;
}
_root.saveGame();
}
function winGame() {
_root.gotoMenu();
_root.gotoCredits();
}
function whatShouldSoundDo() {
if (_currentframe < 4) {
_root.menuMusic.bgMusic.gotoAndPlay(7719);
} else {
_root.menuMusic.bgMusic.gotoAndPlay(1);
}
}
function saveGame() {
myLSO = SharedObject.getLocal("OpenDoors2");
if (myLSO.data.myObj == undefined) {
}
myObj = {};
myObj.objArray = new Array();
myObj.objArray[0] = (levels36 = convertFromLevelStrTo36(levelsStr));
myObj.objArray[1] = saveArray(movesArray);
myObj.objArray[2] = saveArray(timesArray);
myObj.objArray[3] = soundOn;
myObj.objArray[4] = themeNum;
myLSO.data.myObj = myObj;
myLSO.data.flush();
}
function loadGame() {
myLSO = SharedObject.getLocal("OpenDoors2");
if (myLSO.data.myObj == undefined) {
return(false);
}
levels36 = myLSO.data.myObj.objArray[0];
levelsStr = convertFrom36ToLevelStr(levels36);
movesArray = loadArray(myLSO.data.myObj.objArray[1]);
timesArray = loadArray(myLSO.data.myObj.objArray[2]);
soundOn = myLSO.data.myObj.objArray[3];
themeNum = myLSO.data.myObj.objArray[4];
return(true);
}
function convertFrom36ToLevelStr(b) {
var _local5 = "";
var _local2 = 0;
while (_local2 < b.length) {
var _local1 = "";
if (b.charAt(_local2) == "@") {
_local1 = String(parseInt(b.substr(_local2 + 1, 2), 36));
var _local3 = _local1.length;
while (_local3 < 5) {
_local1 = "0" + _local1;
_local3++;
}
_local2 = _local2 + 2;
} else if (b.charAt(_local2) == "#") {
_local1 = String(parseInt(b.substr(_local2 + 1, 3), 36));
var _local3 = _local1.length;
while (_local3 < 5) {
_local1 = "0" + _local1;
_local3++;
}
_local2 = _local2 + 3;
} else {
_local1 = String(parseInt(b.charAt(_local2), 36));
var _local3 = _local1.length;
while (_local3 < 5) {
_local1 = "0" + _local1;
_local3++;
}
}
_local5 = _local5 + _local1;
_local2++;
}
return(_local5);
}
function toNumber(b) {
var _local3 = 0;
var _local1 = 0;
while (_local1 < b.length) {
if (b.charAt(_local1) != "0") {
_local3 = Number(b.substr(_local1, b.length));
break;
}
_local1++;
}
return(_local3);
}
function convertFromLevelStrTo36(b) {
var _local3 = "";
var _local1 = 0;
while (_local1 < b.length) {
var _local2 = toNumber(b.substr(_local1, 5)).toString(36);
_local1 = _local1 + 4;
if (_local2.length == 2) {
_local3 = _local3 + "@";
} else if (_local2.length == 3) {
_local3 = _local3 + "#";
}
_local3 = _local3 + _local2;
_local1++;
}
return(_local3);
}
function saveArray(b) {
var _local3 = "";
var _local2 = 0;
while (_local2 < b.length) {
var _local1 = b[_local2].toString(36);
if (_local1.length == 2) {
_local3 = _local3 + "@";
} else if (_local1.length == 3) {
_local3 = _local3 + "#";
}
_local3 = _local3 + _local1;
_local2++;
}
return(_local3);
}
function loadArray(b) {
var _local4 = new Array();
var _local1 = 0;
while (_local1 < b.length) {
var _local2 = 0;
if (b.charAt(_local1) == "@") {
_local2 = parseInt(b.substr(_local1 + 1, 2), 36);
_local1 = _local1 + 2;
} else if (b.charAt(_local1) == "#") {
_local2 = parseInt(b.substr(_local1 + 1, 3), 36);
_local1 = _local1 + 3;
} else {
_local2 = parseInt(b.charAt(_local1), 36);
}
_local4.push(_local2);
_local1++;
}
return(_local4);
}
var levels36 = "00000000";
var levelsStr = "000000000000000000000000000000000000";
var movesArray = new Array();
var i = 0;
while (i < levelsStr.length) {
movesArray.push(999);
i++;
}
var timesArray = new Array();
var i = 0;
while (i < levelsStr.length) {
timesArray.push(999);
i++;
}
var MAX_Moves = [[13, 18, 25], [32, 40, 54], [22, 32, 52], [22, 33, 55], [58, 66, 85], [32, 44, 68], [36, 48, 72], [36, 50, 78], [38, 52, 80], [39, 57, 85], [28, 40, 74], [59, 77, 105], [30, 40, 60], [25, 35, 55], [28, 36, 54], [38, 46, 64], [36, 48, 80], [66, 78, 100], [25, 35, 55], [45, 60, 85], [14, 32, 50], [44, 60, 88], [18, 32, 64], [34, 56, 78], [62, 74, 96], [90, 128, 172], [15, 30, 60], [99, 127, 165], [69, 96, 133], [81, 100, 147], [113, 145, 187], [49, 76, 119], [39, 67, 105], [75, 99, 153], [72, 96, 144], [111, 142, 203]];
var MAX_Times = [[3, 6, 12], [10, 20, 40], [6, 12, 24], [6, 14, 28], [14, 22, 40], [8, 16, 32], [8, 18, 36], [10, 20, 40], [11, 22, 44], [9, 18, 36], [7, 14, 28], [14, 21, 35], [10, 20, 40], [5, 10, 20], [8, 16, 32], [12, 20, 36], [10, 20, 40], [18, 26, 44], [6, 12, 36], [11, 22, 44], [4, 8, 18], [12, 24, 48], [5, 10, 25], [8, 16, 32], [15, 25, 50], [29, 40, 71], [4, 8, 18], [24, 30, 48], [20, 30, 50], [23, 32, 41], [32, 40, 72], [15, 30, 60], [11, 22, 44], [19, 38, 76], [23, 45, 90], [29, 58, 116]];
var soundOn = true;
var levelToStartAt = 0;
var themeNum = 1;
var SOUND_playerMoving = new Sound();
SOUND_playerMoving.attachSound("PlayerMoving.mp3");
var SOUND_undoMove = new Sound();
SOUND_undoMove.attachSound("PlayerMovingBackwards.mp3");
var SOUND_doorOpening = new Sound();
SOUND_doorOpening.attachSound("DoorOpening.mp3");
var SOUND_parlorDoorOpening = new Sound();
SOUND_parlorDoorOpening.attachSound("ParlorDoorOpening.mp3");
var SOUND_win1 = new Sound();
SOUND_win1.attachSound("Win1.mp3");
var SOUND_win2 = new Sound();
SOUND_win2.attachSound("Win2.mp3");
var SOUND_win3 = new Sound();
SOUND_win3.attachSound("Win3.mp3");
var SOUND_switchToggled = new Sound();
SOUND_switchToggled.attachSound("switchToggled.mp3");
var SOUND_gateToggle = new Sound();
SOUND_gateToggle.attachSound("gateToggle.mp3");
var SOUND_falling = new Sound();
SOUND_falling.attachSound("falling.mp3");
var SOUND_button = new Sound();
SOUND_button.attachSound("Button.mp3");
loadGame();
_root.SOUND_button.setVolume(100 * soundOn);
_root.menuMusic.gotoAndStop(Number(soundOn) + 1);
_root.menuMusic.bgMusic.gotoAndPlay(7719);
_root.menuMusic._visible = false;
_root.colorBtn._visible = false;
_root.bgGrid.gotoAndStop(themeNum);
_root.bgColor.gotoAndStop(themeNum);
_root.bgBorder.gotoAndStop(themeNum);
stop();
Frame 3
function gotoMenu() {
_root.menuThing.gotoAndStop(1);
var _local2 = 1;
while (_local2 <= 5) {
_root["btn" + _local2].enabled = true;
_local2++;
}
}
function gotoCredits() {
_root.menuThing.gotoAndStop(2);
var _local2 = 1;
while (_local2 <= 5) {
_root["btn" + _local2].enabled = false;
_local2++;
}
}
function gotoIPhone() {
_root.menuThing.gotoAndStop(3);
var _local2 = 1;
while (_local2 <= 5) {
_root["btn" + _local2].enabled = false;
_local2++;
}
}
function toggleTheme() {
_root.themeNum++;
if (_root.themeNum > 6) {
_root.themeNum = 1;
}
_root.bgGrid.gotoAndStop(_root.themeNum);
_root.bgColor.gotoAndStop(_root.themeNum);
_root.bgBorder.gotoAndStop(_root.themeNum);
if (_root.menuThing._currentframe > 1) {
_root.menuThing.bgGrid.gotoAndStop(_root.themeNum);
_root.menuThing.bgColor.gotoAndStop(_root.themeNum);
}
_root.saveGame();
}
function gotoLevelSelect() {
_root.menuThing.gotoAndStop(4);
var _local5 = 0;
var _local4 = 0;
var _local2 = 1;
while (_local2 <= 36) {
var _local3 = _root.levelsStr.charAt(_local2 - 1);
_local5 = _local5 + _root.movesArray[_local2 - 1];
_local4 = _local4 + _root.timesArray[_local2 - 1];
if ((((_local2 == 1) || (_local2 == 7)) || (_local2 == 17)) || (_local2 == 27)) {
_root.menuThing["L" + _local2].btn.enabled = true;
_root.menuThing["L" + _local2].num.gotoAndStop(_local2 + 1);
if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][0]) {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(4);
} else if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][1]) {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(3);
} else if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][2]) {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(2);
} else {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(1);
}
if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][0]) {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(4);
} else if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][1]) {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(3);
} else if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][2]) {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(2);
} else {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(1);
}
} else if (_local3 == "0") {
if (_root.levelsStr.charAt(_local2 - 2) != "0") {
_root.menuThing["L" + _local2].btn.enabled = true;
_root.menuThing["L" + _local2].num.gotoAndStop(_local2 + 1);
if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][0]) {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(4);
} else if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][1]) {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(3);
} else if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][2]) {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(2);
} else {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(1);
}
if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][0]) {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(4);
} else if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][1]) {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(3);
} else if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][2]) {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(2);
} else {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(1);
}
} else {
_root.menuThing["L" + _local2].btn.enabled = false;
_root.menuThing["L" + _local2].num.gotoAndStop(1);
}
} else {
_root.menuThing["L" + _local2].btn.enabled = true;
_root.menuThing["L" + _local2].num.gotoAndStop(_local2 + 1);
if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][0]) {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(4);
} else if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][1]) {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(3);
} else if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][2]) {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(2);
} else {
_root.menuThing["L" + _local2].bg.moves.gotoAndStop(1);
}
if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][0]) {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(4);
} else if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][1]) {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(3);
} else if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][2]) {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(2);
} else {
_root.menuThing["L" + _local2].bg.times.gotoAndStop(1);
}
}
_local2++;
}
_root.menuThing.screen.gate._visible = true;
_root.menuThing.screen.allText._visible = false;
_root.menuThing.mT.text = ("(" + _local5) + ") Moves";
_root.menuThing.tT.text = ("(" + _local4) + ") Seconds";
_root.menuThing.blah.text = "Across All Levels";
_local2 = 1;
while (_local2 <= 5) {
_root["btn" + _local2].enabled = false;
_local2++;
}
}
function destroyAtMenu() {
clearInterval(bgAnimation);
}
function bgMain() {
checkKeys();
_root.spinner._rotation = _root.spinner._rotation + 0.5;
if (KEY_Menu_Down && (KEY_Menu_Reset)) {
gotoMenu();
_root.SOUND_button.start();
KEY_Menu_Reset = false;
} else if (KEY_Sound_Down && (KEY_Sound_Reset)) {
_root.toggleSound();
KEY_Sound_Reset = false;
} else if (KEY_Color_Down && (KEY_Color_Reset)) {
_root.toggleTheme();
KEY_Color_Reset = false;
}
}
function onButtonPress() {
var _local2 = 1;
while (_local2 <= 36) {
if (_root.menuThing["L" + _local2].btn.enabled && (_root.menuThing["L" + _local2].hitTest(_root._xmouse, _root._ymouse))) {
_root.levelToStartAt = _local2;
destroyAtMenu();
gotoAndStop ("gameFrame");
_root.SOUND_button.start();
break;
}
_local2++;
}
}
function onButtonRollOver() {
var _local3 = false;
var _local2 = 1;
while (_local2 <= 36) {
if (_root.menuThing["L" + _local2].btn.enabled && (_root.menuThing["L" + _local2].hitTest(_root._xmouse, _root._ymouse))) {
_root.menuThing.screen.prev.gotoAndStop(_local2);
if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][0]) {
_root.menuThing.screen.allText.moves.gotoAndStop(1);
} else if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][1]) {
_root.menuThing.screen.allText.moves.gotoAndStop(2);
} else if (_root.movesArray[_local2 - 1] <= _root.MAX_Moves[_local2 - 1][2]) {
_root.menuThing.screen.allText.moves.gotoAndStop(3);
} else {
_root.menuThing.screen.allText.moves.gotoAndStop(4);
}
_root.menuThing.screen.allText.movesTxt.text = _root.movesArray[_local2 - 1];
_root.menuThing.screen.allText.moves1Txt.text = _root.MAX_Moves[_local2 - 1][0];
_root.menuThing.screen.allText.moves2Txt.text = _root.MAX_Moves[_local2 - 1][1];
_root.menuThing.screen.allText.moves3Txt.text = _root.MAX_Moves[_local2 - 1][2];
if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][0]) {
_root.menuThing.screen.allText.times.gotoAndStop(1);
} else if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][1]) {
_root.menuThing.screen.allText.times.gotoAndStop(2);
} else if (_root.timesArray[_local2 - 1] <= _root.MAX_Times[_local2 - 1][2]) {
_root.menuThing.screen.allText.times.gotoAndStop(3);
} else {
_root.menuThing.screen.allText.times.gotoAndStop(4);
}
_root.menuThing.screen.allText.timeTxt.text = _root.timesArray[_local2 - 1];
_root.menuThing.screen.allText.time1Txt.text = _root.MAX_Times[_local2 - 1][0];
_root.menuThing.screen.allText.time2Txt.text = _root.MAX_Times[_local2 - 1][1];
_root.menuThing.screen.allText.time3Txt.text = _root.MAX_Times[_local2 - 1][2];
_local3 = true;
break;
}
_local2++;
}
_root.menuThing.screen.gate._visible = !_local3;
_root.menuThing.screen.allText._visible = _local3;
}
function checkKeys() {
KEY_Menu_Down = Key.isDown(77);
KEY_Sound_Down = Key.isDown(83);
KEY_Color_Down = Key.isDown(67);
if (!KEY_Menu_Down) {
KEY_Menu_Reset = true;
}
if (!KEY_Sound_Down) {
KEY_Sound_Reset = true;
}
if (!KEY_Color_Down) {
KEY_Color_Reset = true;
}
}
var KEY_Menu_Down = false;
var KEY_Sound_Down = false;
var KEY_Color_Down = false;
var KEY_Menu_Reset = true;
var KEY_Sound_Reset = true;
var KEY_Color_Reset = true;
_root.spinner.gotoAndStop(1);
if (_root.menuMusic.bgMusic._currentframe < 7719) {
_root.menuMusic.bgMusic.gotoAndPlay(7719);
}
_root.menuMusic._visible = true;
_root.menuMusic.bgMusic._visible = false;
_root.menuMusic.gotoAndStop(Number(_root.soundOn) + 1);
_root.colorBtn._visible = true;
var bgAnimation = setInterval(bgMain, 10);
Frame 4
function gotoMenu() {
fps = null;
previousTime = null;
KEY_UP_Down = null;
KEY_DOWN_Down = null;
KEY_LEFT_Down = null;
KEY_RIGHT_Down = null;
keyTime = null;
game.destroy();
game = null;
menuMusic.removeMovieClip();
clearInterval(gameInterval);
gotoAndStop ("menuFrame");
}
function toggleTheme() {
game.toggleTheme();
}
function restart() {
game.restart();
}
function mainInterval() {
while ((previousTime + int(1000 / fps)) > getTimer()) {
}
previousTime = getTimer();
game.step();
}
stop();
var fps = 30;
var previousTime = getTimer();
var game = new Game();
_root.menuMusic.bgMusic.gotoAndPlay(1);
_root.menuMusic.swapDepths(11010);
_root.menuMusic.gotoAndStop(Number(_root.soundOn) + 1);
_root.menuMusic._visible = true;
_root.menuMusic.bgMusic._visible = _root.soundOn;
var gameInterval = setInterval(mainInterval, 5);
Symbol 23 MovieClip Frame 1860
gotoAndPlay ("Idle");
Symbol 24 MovieClip Frame 1
stop();
Symbol 24 MovieClip Frame 2
play();
Symbol 24 MovieClip Frame 6
gotoAndStop (1);
Symbol 24 MovieClip Frame 7
play();
Symbol 24 MovieClip Frame 11
gotoAndStop (1);
Symbol 24 MovieClip Frame 12
play();
Symbol 24 MovieClip Frame 16
gotoAndStop (1);
Symbol 24 MovieClip Frame 17
play();
Symbol 24 MovieClip Frame 21
gotoAndStop (1);
Symbol 24 MovieClip Frame 22
play();
Symbol 24 MovieClip Frame 50
gotoAndStop (1);
_root.game.playerWin();
Symbol 24 MovieClip Frame 51
play();
Symbol 24 MovieClip Frame 125
gotoAndStop (1);
_root.game.undo();
Symbol 26 MovieClip Frame 1860
gotoAndPlay ("Idle");
Symbol 27 MovieClip Frame 1
stop();
Symbol 27 MovieClip Frame 2
play();
Symbol 27 MovieClip Frame 6
gotoAndStop (1);
Symbol 27 MovieClip Frame 7
play();
Symbol 27 MovieClip Frame 11
gotoAndStop (1);
Symbol 27 MovieClip Frame 12
play();
Symbol 27 MovieClip Frame 16
gotoAndStop (1);
Symbol 27 MovieClip Frame 17
play();
Symbol 27 MovieClip Frame 21
gotoAndStop (1);
Symbol 27 MovieClip Frame 22
play();
Symbol 27 MovieClip Frame 50
gotoAndStop (1);
_root.game.playerWin();
Symbol 27 MovieClip Frame 51
play();
Symbol 27 MovieClip Frame 125
gotoAndStop (1);
_root.game.undo();
Symbol 29 MovieClip Frame 1860
gotoAndPlay ("Idle");
Symbol 30 MovieClip Frame 1
stop();
Symbol 30 MovieClip Frame 2
play();
Symbol 30 MovieClip Frame 6
gotoAndStop (1);
Symbol 30 MovieClip Frame 7
play();
Symbol 30 MovieClip Frame 11
gotoAndStop (1);
Symbol 30 MovieClip Frame 12
play();
Symbol 30 MovieClip Frame 16
gotoAndStop (1);
Symbol 30 MovieClip Frame 17
play();
Symbol 30 MovieClip Frame 21
gotoAndStop (1);
Symbol 30 MovieClip Frame 22
play();
Symbol 30 MovieClip Frame 50
gotoAndStop (1);
_root.game.playerWin();
Symbol 30 MovieClip Frame 51
play();
Symbol 30 MovieClip Frame 125
gotoAndStop (1);
_root.game.undo();
Symbol 32 MovieClip Frame 1860
gotoAndPlay ("Idle");
Symbol 33 MovieClip Frame 1
stop();
Symbol 33 MovieClip Frame 2
play();
Symbol 33 MovieClip Frame 6
gotoAndStop (1);
Symbol 33 MovieClip Frame 7
play();
Symbol 33 MovieClip Frame 11
gotoAndStop (1);
Symbol 33 MovieClip Frame 12
play();
Symbol 33 MovieClip Frame 16
gotoAndStop (1);
Symbol 33 MovieClip Frame 17
play();
Symbol 33 MovieClip Frame 21
gotoAndStop (1);
Symbol 33 MovieClip Frame 22
play();
Symbol 33 MovieClip Frame 50
gotoAndStop (1);
_root.game.playerWin();
Symbol 33 MovieClip Frame 51
play();
Symbol 33 MovieClip Frame 125
gotoAndStop (1);
_root.game.undo();
Symbol 35 MovieClip Frame 1860
gotoAndPlay ("Idle");
Symbol 36 MovieClip Frame 1
stop();
Symbol 36 MovieClip Frame 2
play();
Symbol 36 MovieClip Frame 6
gotoAndStop (1);
Symbol 36 MovieClip Frame 7
play();
Symbol 36 MovieClip Frame 11
gotoAndStop (1);
Symbol 36 MovieClip Frame 12
play();
Symbol 36 MovieClip Frame 16
gotoAndStop (1);
Symbol 36 MovieClip Frame 17
play();
Symbol 36 MovieClip Frame 21
gotoAndStop (1);
Symbol 36 MovieClip Frame 22
play();
Symbol 36 MovieClip Frame 50
gotoAndStop (1);
_root.game.playerWin();
Symbol 36 MovieClip Frame 51
play();
Symbol 36 MovieClip Frame 125
gotoAndStop (1);
_root.game.undo();
Symbol 38 MovieClip Frame 1860
gotoAndPlay ("Idle");
Symbol 39 MovieClip Frame 1
stop();
Symbol 39 MovieClip Frame 2
play();
Symbol 39 MovieClip Frame 6
gotoAndStop (1);
Symbol 39 MovieClip Frame 7
play();
Symbol 39 MovieClip Frame 11
gotoAndStop (1);
Symbol 39 MovieClip Frame 12
play();
Symbol 39 MovieClip Frame 16
gotoAndStop (1);
Symbol 39 MovieClip Frame 17
play();
Symbol 39 MovieClip Frame 21
gotoAndStop (1);
Symbol 39 MovieClip Frame 22
play();
Symbol 39 MovieClip Frame 50
gotoAndStop (1);
_root.game.playerWin();
Symbol 39 MovieClip Frame 51
play();
Symbol 39 MovieClip Frame 125
gotoAndStop (1);
_root.game.undo();
Symbol 46 MovieClip Frame 1
stop();
Symbol 46 MovieClip Frame 2
play();
Symbol 46 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 51 MovieClip Frame 1
stop();
Symbol 51 MovieClip Frame 2
play();
Symbol 51 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 57 MovieClip Frame 1
stop();
Symbol 57 MovieClip Frame 2
play();
Symbol 57 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 62 MovieClip Frame 1
stop();
Symbol 62 MovieClip Frame 2
play();
Symbol 62 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 68 MovieClip Frame 1
stop();
Symbol 68 MovieClip Frame 2
play();
Symbol 68 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 73 MovieClip Frame 1
stop();
Symbol 73 MovieClip Frame 2
play();
Symbol 73 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 79 MovieClip Frame 1
stop();
Symbol 79 MovieClip Frame 2
play();
Symbol 79 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 84 MovieClip Frame 1
stop();
Symbol 84 MovieClip Frame 2
play();
Symbol 84 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 90 MovieClip Frame 1
stop();
Symbol 90 MovieClip Frame 2
play();
Symbol 90 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 95 MovieClip Frame 1
stop();
Symbol 95 MovieClip Frame 2
play();
Symbol 95 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 101 MovieClip Frame 1
stop();
Symbol 101 MovieClip Frame 2
play();
Symbol 101 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 105 MovieClip Frame 1
stop();
Symbol 105 MovieClip Frame 2
play();
Symbol 105 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 111 MovieClip Frame 1
stop();
Symbol 111 MovieClip Frame 2
play();
Symbol 111 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 116 MovieClip Frame 1
stop();
Symbol 116 MovieClip Frame 2
play();
Symbol 116 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 121 MovieClip Frame 1
stop();
Symbol 121 MovieClip Frame 2
play();
Symbol 121 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 126 MovieClip Frame 1
stop();
Symbol 126 MovieClip Frame 2
play();
Symbol 126 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 131 MovieClip Frame 1
stop();
Symbol 131 MovieClip Frame 2
play();
Symbol 131 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 136 MovieClip Frame 1
stop();
Symbol 136 MovieClip Frame 2
play();
Symbol 136 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 147 MovieClip Frame 1
stop();
Symbol 147 MovieClip Frame 2
play();
Symbol 147 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 148 MovieClip Frame 1
stop();
Symbol 148 MovieClip Frame 2
play();
Symbol 148 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 154 MovieClip Frame 1
stop();
Symbol 154 MovieClip Frame 2
play();
Symbol 154 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 155 MovieClip Frame 1
stop();
Symbol 155 MovieClip Frame 2
play();
Symbol 155 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 161 MovieClip Frame 1
stop();
Symbol 161 MovieClip Frame 2
play();
Symbol 161 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 162 MovieClip Frame 1
stop();
Symbol 162 MovieClip Frame 2
play();
Symbol 162 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 168 MovieClip Frame 1
stop();
Symbol 168 MovieClip Frame 2
play();
Symbol 168 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 169 MovieClip Frame 1
stop();
Symbol 169 MovieClip Frame 2
play();
Symbol 169 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 175 MovieClip Frame 1
stop();
Symbol 175 MovieClip Frame 2
play();
Symbol 175 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 176 MovieClip Frame 1
stop();
Symbol 176 MovieClip Frame 2
play();
Symbol 176 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 182 MovieClip Frame 1
stop();
Symbol 182 MovieClip Frame 2
play();
Symbol 182 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 183 MovieClip Frame 1
stop();
Symbol 183 MovieClip Frame 2
play();
Symbol 183 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 192 MovieClip Frame 1
stop();
Symbol 192 MovieClip Frame 2
play();
Symbol 192 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 193 MovieClip Frame 1
stop();
Symbol 193 MovieClip Frame 2
play();
Symbol 193 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 198 MovieClip Frame 1
stop();
Symbol 198 MovieClip Frame 2
play();
Symbol 198 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 199 MovieClip Frame 1
stop();
Symbol 199 MovieClip Frame 2
play();
Symbol 199 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 204 MovieClip Frame 1
stop();
Symbol 204 MovieClip Frame 2
play();
Symbol 204 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 205 MovieClip Frame 1
stop();
Symbol 205 MovieClip Frame 2
play();
Symbol 205 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 210 MovieClip Frame 1
stop();
Symbol 210 MovieClip Frame 2
play();
Symbol 210 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 211 MovieClip Frame 1
stop();
Symbol 211 MovieClip Frame 2
play();
Symbol 211 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 216 MovieClip Frame 1
stop();
Symbol 216 MovieClip Frame 2
play();
Symbol 216 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 217 MovieClip Frame 1
stop();
Symbol 217 MovieClip Frame 2
play();
Symbol 217 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 222 MovieClip Frame 1
stop();
Symbol 222 MovieClip Frame 2
play();
Symbol 222 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 249 Button
on (press) {
_root.editor.save();
}
Symbol 250 Button
on (press) {
_root.editor.load();
}
Symbol 251 Button
on (press) {
_root.editor.fillWalls();
}
Symbol 266 MovieClip Frame 1
stop();
Symbol 266 MovieClip Frame 2
play();
Symbol 266 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 267 MovieClip Frame 1
stop();
Symbol 267 MovieClip Frame 2
play();
Symbol 267 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 274 MovieClip Frame 1
stop();
Symbol 274 MovieClip Frame 2
play();
Symbol 274 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 275 MovieClip Frame 1
stop();
Symbol 275 MovieClip Frame 2
play();
Symbol 275 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 282 MovieClip Frame 1
stop();
Symbol 282 MovieClip Frame 2
play();
Symbol 282 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 283 MovieClip Frame 1
stop();
Symbol 283 MovieClip Frame 2
play();
Symbol 283 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 290 MovieClip Frame 1
stop();
Symbol 290 MovieClip Frame 2
play();
Symbol 290 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 291 MovieClip Frame 1
stop();
Symbol 291 MovieClip Frame 2
play();
Symbol 291 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 298 MovieClip Frame 1
stop();
Symbol 298 MovieClip Frame 2
play();
Symbol 298 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 299 MovieClip Frame 1
stop();
Symbol 299 MovieClip Frame 2
play();
Symbol 299 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 306 MovieClip Frame 1
stop();
Symbol 306 MovieClip Frame 2
play();
Symbol 306 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 307 MovieClip Frame 1
stop();
Symbol 307 MovieClip Frame 2
play();
Symbol 307 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 323 MovieClip Frame 1
stop();
Symbol 323 MovieClip Frame 2
play();
Symbol 323 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 326 MovieClip Frame 1
stop();
Symbol 326 MovieClip Frame 2
play();
Symbol 326 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 337 MovieClip Frame 1
stop();
Symbol 337 MovieClip Frame 2
play();
Symbol 337 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 340 MovieClip Frame 1
stop();
Symbol 340 MovieClip Frame 2
play();
Symbol 340 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 352 MovieClip Frame 1
stop();
Symbol 352 MovieClip Frame 2
play();
Symbol 352 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 355 MovieClip Frame 1
stop();
Symbol 355 MovieClip Frame 2
play();
Symbol 355 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 366 MovieClip Frame 1
stop();
Symbol 366 MovieClip Frame 2
play();
Symbol 366 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 369 MovieClip Frame 1
stop();
Symbol 369 MovieClip Frame 2
play();
Symbol 369 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 380 MovieClip Frame 1
stop();
Symbol 380 MovieClip Frame 2
play();
Symbol 380 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 383 MovieClip Frame 1
stop();
Symbol 383 MovieClip Frame 2
play();
Symbol 383 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 392 MovieClip Frame 1
stop();
Symbol 392 MovieClip Frame 2
play();
Symbol 392 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 395 MovieClip Frame 1
stop();
Symbol 395 MovieClip Frame 2
play();
Symbol 395 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 402 MovieClip Frame 1
stop();
Symbol 402 MovieClip Frame 2
play();
Symbol 402 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 404 MovieClip Frame 1
stop();
Symbol 404 MovieClip Frame 2
play();
Symbol 404 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 410 MovieClip Frame 1
stop();
Symbol 410 MovieClip Frame 2
play();
Symbol 410 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 412 MovieClip Frame 1
stop();
Symbol 412 MovieClip Frame 2
play();
Symbol 412 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 418 MovieClip Frame 1
stop();
Symbol 418 MovieClip Frame 2
play();
Symbol 418 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 420 MovieClip Frame 1
stop();
Symbol 420 MovieClip Frame 2
play();
Symbol 420 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 426 MovieClip Frame 1
stop();
Symbol 426 MovieClip Frame 2
play();
Symbol 426 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 428 MovieClip Frame 1
stop();
Symbol 428 MovieClip Frame 2
play();
Symbol 428 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 434 MovieClip Frame 1
stop();
Symbol 434 MovieClip Frame 2
play();
Symbol 434 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 436 MovieClip Frame 1
stop();
Symbol 436 MovieClip Frame 2
play();
Symbol 436 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 442 MovieClip Frame 1
stop();
Symbol 442 MovieClip Frame 2
play();
Symbol 442 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 444 MovieClip Frame 1
stop();
Symbol 444 MovieClip Frame 2
play();
Symbol 444 MovieClip Frame 7
stop();
_root.game.level.handleActiveDoor(_parent);
Symbol 494 Button
on (press) {
getURL ("http://armorgames.com", "_blank");
}
Symbol 503 Button
on (press) {
_root.gotoNextFrame();
}
Symbol 504 MovieClip Frame 1
stop();
Symbol 768 MovieClip [__Packages.Game] Frame 0
class Game
{
var trans, level, levelNum, undoList, player, KEY_UP_Down, KEY_DOWN_Down, KEY_LEFT_Down, KEY_RIGHT_Down, KEY_Undo_Down, KEY_Restart_Down, KEY_Menu_Down, KEY_Sound_Down, KEY_Color_Down, KEY_UP_Reset, KEY_DOWN_Reset, KEY_LEFT_Reset, KEY_RIGHT_Reset, KEY_Undo_Reset, KEY_Restart_Reset, KEY_Menu_Reset, KEY_Sound_Reset, KEY_Color_Reset, numMovesMade, stopWatch;
function Game () {
trans = new SlideAndShowTransition(level.clip);
level = new Level(this);
levelNum = _root.levelToStartAt;
undoList = new Array();
level.load(Levels["L" + levelNum]);
_root.tutorialTxt.gotoAndStop(levelNum);
player = level.player;
KEY_UP_Down = false;
KEY_DOWN_Down = false;
KEY_LEFT_Down = false;
KEY_RIGHT_Down = false;
KEY_Undo_Down = false;
KEY_Restart_Down = false;
KEY_Menu_Down = false;
KEY_Sound_Down = false;
KEY_Color_Down = false;
KEY_UP_Reset = true;
KEY_DOWN_Reset = true;
KEY_LEFT_Reset = true;
KEY_RIGHT_Reset = true;
KEY_Undo_Reset = true;
KEY_Restart_Reset = true;
KEY_Menu_Reset = true;
KEY_Sound_Reset = true;
KEY_Color_Reset = true;
numMovesMade = 0;
stopWatch = new StopWatch();
if (levelNum <= 10) {
_root.topLeftOutputTxt.text = "Level: 0" + (levelNum - 1);
} else {
_root.topLeftOutputTxt.text = "Level: " + (levelNum - 1);
}
_root.topRightOutputTxt.text = "Moves: 0 Time: 0";
_root.medals.mM.gotoAndStop(whatMedal(_root.movesArray[levelNum - 1], _root.MAX_Moves[levelNum - 1]));
_root.medals.mM.ani.gotoAndStop(1);
_root.medals.tM.gotoAndStop(whatMedal(_root.timesArray[levelNum - 1], _root.MAX_Times[levelNum - 1]));
_root.medals.tM.ani.gotoAndStop(1);
trans.setUpForFadeIn();
}
function toggleTheme() {
if (player.clip.ani._currentframe <= 1) {
_root.themeNum++;
if (_root.themeNum > 6) {
_root.themeNum = 1;
}
_root.bgGrid.gotoAndStop(_root.themeNum);
_root.bgColor.gotoAndStop(_root.themeNum);
_root.bgBorder.gotoAndStop(_root.themeNum);
player.clip.gotoAndStop(_root.themeNum);
level.goal.clip.eh.gotoAndStop(_root.themeNum);
var _local4 = 0;
while (_local4 < level.tiles.length) {
var _local3 = 0;
while (_local3 < level.tiles[_local4].length) {
if (level.tiles[_local4][_local3] != null) {
level.tiles[_local4][_local3].clip.bgGrid.eh.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].clip.bgColor.gotoAndStop(_root.themeNum);
var _local5 = 1;
if ((level.tiles[_local4][_local3].wall_Left != null) && ((level.tiles[_local4][_local3].wall_Left instanceof OneWayDoor) || (level.tiles[_local4][_local3].wall_Left instanceof RemoteOneWayDoor))) {
_local5 = level.tiles[_local4][_local3].wall_Left.clip.eh._currentframe;
level.tiles[_local4][_local3].wall_Left.clip.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].wall_Left.clip.eh.gotoAndStop(_local5);
}
if ((level.tiles[_local4][_local3].wall_Right != null) && ((level.tiles[_local4][_local3].wall_Right instanceof OneWayDoor) || (level.tiles[_local4][_local3].wall_Right instanceof RemoteOneWayDoor))) {
_local5 = level.tiles[_local4][_local3].wall_Right.clip.eh._currentframe;
level.tiles[_local4][_local3].wall_Right.clip.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].wall_Right.clip.eh.gotoAndStop(_local5);
}
if ((level.tiles[_local4][_local3].wall_Top != null) && ((level.tiles[_local4][_local3].wall_Top instanceof OneWayDoor) || (level.tiles[_local4][_local3].wall_Top instanceof RemoteOneWayDoor))) {
_local5 = level.tiles[_local4][_local3].wall_Top.clip.eh._currentframe;
level.tiles[_local4][_local3].wall_Top.clip.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].wall_Top.clip.eh.gotoAndStop(_local5);
}
if ((level.tiles[_local4][_local3].wall_Bottom != null) && ((level.tiles[_local4][_local3].wall_Bottom instanceof OneWayDoor) || (level.tiles[_local4][_local3].wall_Bottom instanceof RemoteOneWayDoor))) {
_local5 = level.tiles[_local4][_local3].wall_Bottom.clip.eh._currentframe;
level.tiles[_local4][_local3].wall_Bottom.clip.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].wall_Bottom.clip.eh.gotoAndStop(_local5);
}
if (level.tiles[_local4][_local3].door_Top_Left != null) {
_local5 = level.tiles[_local4][_local3].door_Top_Left.clip.eh._currentframe;
level.tiles[_local4][_local3].door_Top_Left.clip.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].door_Top_Left.clip.eh.gotoAndStop(_local5);
}
if (level.tiles[_local4][_local3].door_Top_Right != null) {
_local5 = level.tiles[_local4][_local3].door_Top_Right.clip.eh._currentframe;
level.tiles[_local4][_local3].door_Top_Right.clip.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].door_Top_Right.clip.eh.gotoAndStop(_local5);
}
if (level.tiles[_local4][_local3].door_Bottom_Left != null) {
_local5 = level.tiles[_local4][_local3].door_Bottom_Left.clip.eh._currentframe;
level.tiles[_local4][_local3].door_Bottom_Left.clip.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].door_Bottom_Left.clip.eh.gotoAndStop(_local5);
}
if (level.tiles[_local4][_local3].door_Bottom_Right != null) {
_local5 = level.tiles[_local4][_local3].door_Bottom_Right.clip.eh._currentframe;
level.tiles[_local4][_local3].door_Bottom_Right.clip.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].door_Bottom_Right.clip.eh.gotoAndStop(_local5);
}
if (level.tiles[_local4][_local3].splitFloor != null) {
_local5 = level.tiles[_local4][_local3].splitFloor.clip.eh._currentframe;
level.tiles[_local4][_local3].splitFloor.clip.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].splitFloor.clip.eh.gotoAndStop(_local5);
}
if (level.tiles[_local4][_local3].theSwitch != null) {
_local5 = level.tiles[_local4][_local3].theSwitch.clip.eh._currentframe;
level.tiles[_local4][_local3].theSwitch.clip.gotoAndStop(_root.themeNum);
level.tiles[_local4][_local3].theSwitch.clip.eh.gotoAndStop(_local5);
}
}
_local3++;
}
_local4++;
}
_root.saveGame();
}
}
function whatMedal(a, bM) {
if (a <= bM[2]) {
if (a <= bM[0]) {
return(1);
}
if (a <= bM[1]) {
return(2);
}
return(3);
}
return(4);
}
function destroy() {
level.destroy();
level = null;
player = null;
KEY_UP_Down = null;
KEY_DOWN_Down = null;
KEY_LEFT_Down = null;
KEY_RIGHT_Down = null;
KEY_Undo_Down = null;
KEY_Restart_Down = null;
KEY_Menu_Down = null;
KEY_Sound_Down = null;
KEY_Color_Down = null;
KEY_UP_Reset = null;
KEY_DOWN_Reset = null;
KEY_LEFT_Reset = null;
KEY_RIGHT_Reset = null;
KEY_Undo_Reset = null;
KEY_Restart_Reset = null;
KEY_Menu_Reset = null;
KEY_Sound_Reset = null;
KEY_Color_Reset = null;
levelNum = null;
while (undoList.length > 0) {
undoList.pop();
}
undoList = null;
numMovesMade = null;
stopWatch.destroy();
stopWatch = null;
trans.destroy();
trans = null;
}
function checkKeys() {
KEY_UP_Down = Key.isDown(38);
KEY_DOWN_Down = Key.isDown(40);
KEY_LEFT_Down = Key.isDown(37);
KEY_RIGHT_Down = Key.isDown(39);
KEY_Undo_Down = Key.isDown(85);
KEY_Restart_Down = Key.isDown(82);
KEY_Menu_Down = Key.isDown(77);
KEY_Sound_Down = Key.isDown(83);
KEY_Color_Down = Key.isDown(67);
if (!KEY_UP_Down) {
KEY_UP_Reset = true;
}
if (!KEY_DOWN_Down) {
KEY_DOWN_Reset = true;
}
if (!KEY_LEFT_Down) {
KEY_LEFT_Reset = true;
}
if (!KEY_RIGHT_Down) {
KEY_RIGHT_Reset = true;
}
if (!KEY_Undo_Down) {
KEY_Undo_Reset = true;
}
if (!KEY_Restart_Down) {
KEY_Restart_Reset = true;
}
if (!KEY_Menu_Down) {
KEY_Menu_Reset = true;
}
if (!KEY_Sound_Down) {
KEY_Sound_Reset = true;
}
if (!KEY_Color_Down) {
KEY_Color_Reset = true;
}
}
function addNewUndoSpot(obj) {
if (undoList.length >= 10) {
undoList.shift();
}
undoList.push(new Array());
undoList[undoList.length - 1].push(obj);
}
function addToUndoSpot(obj) {
undoList[undoList.length - 1].push(obj);
}
function restart() {
loadLevel(String(levelNum));
_root.tutorialTxt.gotoAndStop(levelNum);
numMovesMade = 0;
stopWatch.reset();
if (levelNum <= 10) {
_root.topLeftOutputTxt.text = "Level: 0" + (levelNum - 1);
} else {
_root.topLeftOutputTxt.text = "Level: " + (levelNum - 1);
}
_root.topRightOutputTxt.text = "Moves: 0 Time: 0";
_root.medals.mM.gotoAndStop(whatMedal(_root.movesArray[levelNum - 1], _root.MAX_Moves[levelNum - 1]));
_root.medals.mM.ani.gotoAndStop(1);
_root.medals.tM.gotoAndStop(whatMedal(_root.timesArray[levelNum - 1], _root.MAX_Times[levelNum - 1]));
_root.medals.tM.ani.gotoAndStop(1);
}
function undo() {
if (undoList.length > 0) {
if (undoList[undoList.length - 1].length > 0) {
var _local4 = Tile(undoList[undoList.length - 1][0]);
if (_local4.row < player.row) {
player.clip.ani.gotoAndStop("Going Up");
} else if (_local4.row > player.row) {
player.clip.ani.gotoAndStop("Going Down");
} else if (_local4.col < player.col) {
player.clip.ani.gotoAndStop("Going Left");
} else if (_local4.col > player.col) {
player.clip.ani.gotoAndStop("Going Right");
}
_root.SOUND_undoMove.start();
player.moveTo(_local4.row, _local4.col);
numMovesMade--;
}
var _local3 = 1;
while (_local3 < undoList[undoList.length - 1].length) {
undoList[undoList.length - 1][_local3].toggle();
_local3++;
}
undoList.pop();
}
}
function loadLevel(str) {
while (undoList.length > 0) {
undoList.pop();
}
level.load(str);
player = level.player;
}
function playerWin() {
player.clip.swapDepths(level.LAYER_Player);
trans.setUpForFadeOut();
}
function step() {
checkKeys();
if (trans.transitioning) {
if (trans.fadingIn) {
trans.fadeIn();
} else if (trans.fadingOut) {
trans.fadeOut();
} else {
if (!Key.isDown(16)) {
levelNum++;
}
if (levelNum <= 36) {
while (undoList.length > 0) {
undoList.pop();
}
level.load(Levels["L" + levelNum]);
_root.tutorialTxt.gotoAndStop(levelNum);
player = level.player;
numMovesMade = 0;
stopWatch.reset();
trans.setUpForFadeIn();
if (levelNum <= 10) {
_root.topLeftOutputTxt.text = "Level: 0" + (levelNum - 1);
} else {
_root.topLeftOutputTxt.text = "Level: " + (levelNum - 1);
}
_root.topRightOutputTxt.text = "Moves: 0 Time: 0";
_root.medals.mM.gotoAndStop(whatMedal(_root.movesArray[levelNum - 1], _root.MAX_Moves[levelNum - 1]));
_root.medals.mM.ani.gotoAndStop(1);
_root.medals.tM.gotoAndStop(whatMedal(_root.timesArray[levelNum - 1], _root.MAX_Times[levelNum - 1]));
_root.medals.tM.ani.gotoAndStop(1);
} else {
_root.winGame();
return(undefined);
}
}
} else {
if (player.clip.ani._currentframe <= 1) {
if (!stopWatch.active) {
stopWatch.start();
}
if ((player.row == level.goal.row) && (player.col == level.goal.col)) {
stopWatch.stop();
if (numMovesMade <= _root.MAX_Moves[levelNum - 1][2]) {
if (numMovesMade <= _root.MAX_Moves[levelNum - 1][0]) {
if (numMovesMade < _root.movesArray[levelNum - 1]) {
_root.medals.mM.gotoAndStop(1);
_root.medals.mM.ani.gotoAndPlay(2);
_root.movesArray[levelNum - 1] = numMovesMade;
}
} else if (numMovesMade <= _root.MAX_Moves[levelNum - 1][1]) {
if (numMovesMade < _root.movesArray[levelNum - 1]) {
_root.medals.mM.gotoAndStop(2);
_root.medals.mM.ani.gotoAndPlay(2);
_root.movesArray[levelNum - 1] = numMovesMade;
}
} else if (numMovesMade < _root.movesArray[levelNum - 1]) {
_root.medals.mM.gotoAndStop(3);
_root.medals.mM.ani.gotoAndPlay(2);
_root.movesArray[levelNum - 1] = numMovesMade;
}
} else if (numMovesMade < _root.movesArray[levelNum - 1]) {
_root.movesArray[levelNum - 1] = numMovesMade;
}
var _local3 = Math.floor(stopWatch.getTime() / 1000);
if (_local3 <= _root.MAX_Times[levelNum - 1][2]) {
if (_local3 <= _root.MAX_Times[levelNum - 1][0]) {
if (_local3 < _root.timesArray[levelNum - 1]) {
_root.medals.tM.gotoAndStop(1);
_root.medals.tM.ani.gotoAndPlay(2);
_root.timesArray[levelNum - 1] = _local3;
}
} else if (_local3 <= _root.MAX_Times[levelNum - 1][1]) {
if (_local3 < _root.timesArray[levelNum - 1]) {
_root.medals.tM.gotoAndStop(2);
_root.medals.tM.ani.gotoAndPlay(2);
_root.timesArray[levelNum - 1] = _local3;
}
} else if (_local3 < _root.timesArray[levelNum - 1]) {
_root.medals.tM.gotoAndStop(3);
_root.medals.tM.ani.gotoAndPlay(2);
_root.timesArray[levelNum - 1] = _local3;
}
} else if (_local3 < _root.timesArray[levelNum - 1]) {
_root.timesArray[levelNum - 1] = _local3;
}
_root.levelsStr = (_root.levelsStr.substr(0, levelNum - 1) + "1") + _root.levelsStr.substr(levelNum, _root.levelsStr.length);
_root.saveGame();
player.clip.swapDepths(10000);
player.clip.ani.gotoAndPlay("Win");
_root.SOUND_win1.start();
} else if (((level.tiles[player.row][player.col] instanceof FloorlessTile) && (level.tiles[player.row][player.col].splitFloor != null)) && (level.tiles[player.row][player.col].splitFloor.isOpen)) {
player.clip.ani.gotoAndPlay("Fall");
_root.SOUND_falling.start();
} else if (KEY_Undo_Down && (KEY_Undo_Reset)) {
undo();
_root.SOUND_button.start();
KEY_Undo_Reset = false;
} else if (KEY_Restart_Down && (KEY_Restart_Reset)) {
restart();
_root.SOUND_button.start();
KEY_Restart_Reset = false;
} else if (KEY_Menu_Down && (KEY_Menu_Reset)) {
_root.gotoMenu();
_root.SOUND_button.start();
KEY_Menu_Reset = false;
} else if (KEY_Sound_Down && KEY_Sound_Reset) {
_root.toggleSound();
KEY_Sound_Reset = false;
} else if (KEY_Color_Down && KEY_Color_Reset) {
toggleTheme();
KEY_Color_Reset = false;
} else if (KEY_UP_Down && KEY_UP_Reset) {
player.moveBy(-1, 0);
KEY_UP_Reset = false;
} else if (KEY_DOWN_Down && KEY_DOWN_Reset) {
player.moveBy(1, 0);
KEY_DOWN_Reset = false;
} else if (KEY_LEFT_Down && KEY_LEFT_Reset) {
player.moveBy(0, -1);
KEY_LEFT_Reset = false;
} else if (KEY_RIGHT_Down && KEY_RIGHT_Reset) {
player.moveBy(0, 1);
KEY_RIGHT_Reset = false;
}
}
if (levelNum <= 10) {
_root.topLeftOutputTxt.text = "Level: 0" + (levelNum - 1);
} else {
_root.topLeftOutputTxt.text = "Level: " + (levelNum - 1);
}
_root.topRightOutputTxt.text = (("Moves: " + numMovesMade) + " Time: ") + Math.floor(stopWatch.getTime() / 1000);
}
}
}
Symbol 769 MovieClip [__Packages.Level] Frame 0
class Level
{
var LAYER_Tiles, LAYER_Switches, LAYER_SplitFloors, LAYER_Pivots, LAYER_Goal, LAYER_Player, LAYER_Doors, LAYER_Walls, game, clip, themeNumber, tileSize, tiles, player, goal, activeDoorTiles, remotes;
function Level (g) {
LAYER_Tiles = 1000;
LAYER_Switches = 2000;
LAYER_SplitFloors = 3000;
LAYER_Pivots = 5000;
LAYER_Goal = 6000;
LAYER_Player = 7000;
LAYER_Doors = 8000;
LAYER_Walls = 9000;
game = g;
clip = _root.createEmptyMovieClip("clip", 1);
clip.createEmptyMovieClip("walls", LAYER_Walls);
clip.createEmptyMovieClip("tiles", LAYER_Tiles);
clip.walls.filters = [new flash.filters.DropShadowFilter(5, 270, 0, 1, 5, 5, 0.23, 3, true), new flash.filters.GlowFilter(0, 1, 3, 3, 10, 3)];
clip.cacheAsBitmap;
clip.walls.cacheAsBitmap;
clip.tiles.cacheAsBitmap;
themeNumber = _root.themeNum;
tileSize = 50;
tiles = new Array(9);
var _local4 = 0;
while (_local4 < tiles.length) {
tiles[_local4] = new Array(12);
var _local3 = 0;
while (_local3 < tiles[_local4].length) {
tiles[_local4][_local3] = null;
_local3++;
}
_local4++;
}
player = null;
goal = null;
activeDoorTiles = new Array();
remotes = new Array();
_root.bgGrid.gotoAndStop(themeNumber);
_root.bgColor.gotoAndStop(themeNumber);
_root.bgBorder.gotoAndStop(themeNumber);
}
function addTopWall(r, c) {
if (tiles[r][c] != null) {
tiles[r][c].addWall("Top");
if (tiles[r - 1][c] != null) {
tiles[r - 1][c].wall_Bottom = tiles[r][c].wall_Top;
}
} else if (tiles[r - 1][c] != null) {
tiles[r - 1][c].addWall("Bottom");
}
}
function addLeftWall(r, c) {
if (tiles[r][c] != null) {
tiles[r][c].addWall("Left");
if (tiles[r][c - 1] != null) {
tiles[r][c - 1].wall_Right = tiles[r][c].wall_Left;
}
} else if (tiles[r][c - 1] != null) {
tiles[r][c - 1].addWall("Right");
}
}
function handleActiveDoor(mc) {
var _local3 = null;
var _local4 = "";
var _local2 = 0;
while (_local2 < activeDoorTiles.length) {
if (activeDoorTiles[_local2].door_Top_Left.clip.eh == mc) {
_local3 = activeDoorTiles[_local2];
activeDoorTiles.splice(_local2, 1);
_local4 = "TL";
break;
}
if (activeDoorTiles[_local2].door_Top_Right.clip.eh == mc) {
_local3 = activeDoorTiles[_local2];
activeDoorTiles.splice(_local2, 1);
_local4 = "TR";
break;
}
if (activeDoorTiles[_local2].door_Bottom_Left.clip.eh == mc) {
_local3 = activeDoorTiles[_local2];
activeDoorTiles.splice(_local2, 1);
_local4 = "BL";
break;
}
if (activeDoorTiles[_local2].door_Bottom_Right.clip.eh == mc) {
_local3 = activeDoorTiles[_local2];
activeDoorTiles.splice(_local2, 1);
_local4 = "BR";
break;
}
if (activeDoorTiles[_local2].wall_Top.clip.eh == mc) {
_local3 = activeDoorTiles[_local2];
activeDoorTiles.splice(_local2, 1);
_local4 = "T";
break;
}
if (activeDoorTiles[_local2].wall_Bottom.clip.eh == mc) {
_local3 = activeDoorTiles[_local2];
activeDoorTiles.splice(_local2, 1);
_local4 = "B";
break;
}
if (activeDoorTiles[_local2].wall_Left.clip.eh == mc) {
_local3 = activeDoorTiles[_local2];
activeDoorTiles.splice(_local2, 1);
_local4 = "L";
break;
}
if (activeDoorTiles[_local2].wall_Right.clip.eh == mc) {
_local3 = activeDoorTiles[_local2];
activeDoorTiles.splice(_local2, 1);
_local4 = "R";
break;
}
_local2++;
}
if (_local3 != null) {
if (_local4 == "TL") {
if (_local3.door_Top_Left.orientedVertical) {
var _local6 = tiles[_local3.row][_local3.col - 1];
if (_local6 != null) {
if (((_local6.door_Top_Right != null) && (_local6.door_Top_Right.orientedVertical)) && (!(_local6.door_Top_Right instanceof RemoteDoor))) {
_local6.door_Top_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Right);
}
if (((_local6.door_Bottom_Right != null) && (_local6.door_Bottom_Right.orientedVertical)) && (!(_local6.door_Bottom_Right instanceof RemoteDoor))) {
_local6.door_Bottom_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Right);
}
}
} else {
var _local6 = tiles[_local3.row - 1][_local3.col];
if (_local6 != null) {
if (((_local6.door_Bottom_Left != null) && (!_local6.door_Bottom_Left.orientedVertical)) && (!(_local6.door_Bottom_Left instanceof RemoteDoor))) {
_local6.door_Bottom_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Left);
}
if (((_local6.door_Bottom_Right != null) && (!_local6.door_Bottom_Right.orientedVertical)) && (!(_local6.door_Bottom_Right instanceof RemoteDoor))) {
_local6.door_Bottom_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Right);
}
}
}
} else if (_local4 == "TR") {
if (_local3.door_Top_Right.orientedVertical) {
var _local6 = tiles[_local3.row][_local3.col + 1];
if (_local6 != null) {
if (((_local6.door_Top_Left != null) && (_local6.door_Top_Left.orientedVertical)) && (!(_local6.door_Top_Left instanceof RemoteDoor))) {
_local6.door_Top_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Left);
}
if (((_local6.door_Bottom_Left != null) && (_local6.door_Bottom_Left.orientedVertical)) && (!(_local6.door_Bottom_Left instanceof RemoteDoor))) {
_local6.door_Bottom_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Left);
}
}
} else {
var _local6 = tiles[_local3.row - 1][_local3.col];
if (_local6 != null) {
if (((_local6.door_Bottom_Left != null) && (!_local6.door_Bottom_Left.orientedVertical)) && (!(_local6.door_Bottom_Left instanceof RemoteDoor))) {
_local6.door_Bottom_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Left);
}
if (((_local6.door_Bottom_Right != null) && (!_local6.door_Bottom_Right.orientedVertical)) && (!(_local6.door_Bottom_Right instanceof RemoteDoor))) {
_local6.door_Bottom_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Right);
}
}
}
} else if (_local4 == "BL") {
if (_local3.door_Bottom_Left.orientedVertical) {
var _local6 = tiles[_local3.row][_local3.col - 1];
if (_local6 != null) {
if (((_local6.door_Top_Right != null) && (_local6.door_Top_Right.orientedVertical)) && (!(_local6.door_Top_Right instanceof RemoteDoor))) {
_local6.door_Top_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Right);
}
if (((_local6.door_Bottom_Right != null) && (_local6.door_Bottom_Right.orientedVertical)) && (!(_local6.door_Bottom_Right instanceof RemoteDoor))) {
_local6.door_Bottom_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Right);
}
}
} else {
var _local6 = tiles[_local3.row + 1][_local3.col];
if (_local6 != null) {
if (((_local6.door_Top_Left != null) && (!_local6.door_Top_Left.orientedVertical)) && (!(_local6.door_Top_Left instanceof RemoteDoor))) {
_local6.door_Top_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Left);
}
if (((_local6.door_Top_Right != null) && (!_local6.door_Top_Right.orientedVertical)) && (!(_local6.door_Top_Right instanceof RemoteDoor))) {
_local6.door_Top_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Right);
}
}
}
} else if (_local4 == "BR") {
if (_local3.door_Bottom_Right.orientedVertical) {
var _local6 = tiles[_local3.row][_local3.col + 1];
if (_local6 != null) {
if (((_local6.door_Top_Left != null) && _local6.door_Top_Left.orientedVertical) && (!(_local6.door_Top_Left instanceof RemoteDoor))) {
_local6.door_Top_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Left);
}
if (((_local6.door_Bottom_Left != null) && _local6.door_Bottom_Left.orientedVertical) && (!(_local6.door_Bottom_Left instanceof RemoteDoor))) {
_local6.door_Bottom_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Left);
}
}
} else {
var _local6 = tiles[_local3.row + 1][_local3.col];
if (_local6 != null) {
if (((_local6.door_Top_Left != null) && (!_local6.door_Top_Left.orientedVertical)) && (!(_local6.door_Top_Left instanceof RemoteDoor))) {
_local6.door_Top_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Left);
}
if (((_local6.door_Top_Right != null) && (!_local6.door_Top_Right.orientedVertical)) && (!(_local6.door_Top_Right instanceof RemoteDoor))) {
_local6.door_Top_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Right);
}
}
}
} else if (_local4 == "T") {
if (_local3.wall_Top.isOpen) {
var _local6 = tiles[_local3.row - 1][_local3.col - 1];
if (_local6 != null) {
if (((_local6.door_Top_Right != null) && _local6.door_Top_Right.orientedVertical) && (!(_local6.door_Top_Right instanceof RemoteDoor))) {
_local6.door_Top_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Right);
}
if (((_local6.door_Bottom_Right != null) && _local6.door_Bottom_Right.orientedVertical) && (!(_local6.door_Bottom_Right instanceof RemoteDoor))) {
_local6.door_Bottom_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Right);
}
}
_local6 = tiles[_local3.row - 1][_local3.col + 1];
if (_local6 != null) {
if (((_local6.door_Top_Left != null) && _local6.door_Top_Left.orientedVertical) && (!(_local6.door_Top_Left instanceof RemoteDoor))) {
_local6.door_Top_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Left);
}
if (((_local6.door_Bottom_Left != null) && _local6.door_Bottom_Left.orientedVertical) && (!(_local6.door_Bottom_Left instanceof RemoteDoor))) {
_local6.door_Bottom_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Left);
}
}
} else {
var _local6 = tiles[_local3.row][_local3.col];
if (_local6 != null) {
if (((_local6.door_Top_Left != null) && (!_local6.door_Top_Left.orientedVertical)) && (!(_local6.door_Top_Left instanceof RemoteDoor))) {
_local6.door_Top_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Left);
}
if (((_local6.door_Top_Right != null) && (!_local6.door_Top_Right.orientedVertical)) && (!(_local6.door_Top_Right instanceof RemoteDoor))) {
_local6.door_Top_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Right);
}
}
}
} else if (_local4 == "B") {
if (_local3.wall_Bottom.isOpen) {
var _local6 = tiles[_local3.row + 1][_local3.col - 1];
if (_local6 != null) {
if (((_local6.door_Top_Right != null) && _local6.door_Top_Right.orientedVertical) && (!(_local6.door_Top_Right instanceof RemoteDoor))) {
_local6.door_Top_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Right);
}
if (((_local6.door_Bottom_Right != null) && _local6.door_Bottom_Right.orientedVertical) && (!(_local6.door_Bottom_Right instanceof RemoteDoor))) {
_local6.door_Bottom_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Right);
}
}
_local6 = tiles[_local3.row + 1][_local3.col + 1];
if (_local6 != null) {
if (((_local6.door_Top_Left != null) && _local6.door_Top_Left.orientedVertical) && (!(_local6.door_Top_Left instanceof RemoteDoor))) {
_local6.door_Top_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Left);
}
if (((_local6.door_Bottom_Left != null) && _local6.door_Bottom_Left.orientedVertical) && (!(_local6.door_Bottom_Left instanceof RemoteDoor))) {
_local6.door_Bottom_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Left);
}
}
} else {
var _local6 = tiles[_local3.row][_local3.col];
if (_local6 != null) {
if (((_local6.door_Bottom_Left != null) && (!_local6.door_Bottom_Left.orientedVertical)) && (!(_local6.door_Bottom_Left instanceof RemoteDoor))) {
_local6.door_Bottom_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Left);
}
if (((_local6.door_Bottom_Right != null) && (!_local6.door_Bottom_Right.orientedVertical)) && (!(_local6.door_Bottom_Right instanceof RemoteDoor))) {
_local6.door_Bottom_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Right);
}
}
}
} else if (_local4 == "L") {
if (_local3.wall_Left.isOpen) {
var _local6 = tiles[_local3.row - 1][_local3.col - 1];
if (_local6 != null) {
if (((_local6.door_Bottom_Left != null) && (!_local6.door_Bottom_Left.orientedVertical)) && (!(_local6.door_Bottom_Left instanceof RemoteDoor))) {
_local6.door_Bottom_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Left);
}
if (((_local6.door_Bottom_Right != null) && (!_local6.door_Bottom_Right.orientedVertical)) && (!(_local6.door_Bottom_Right instanceof RemoteDoor))) {
_local6.door_Bottom_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Right);
}
}
_local6 = tiles[_local3.row + 1][_local3.col - 1];
if (_local6 != null) {
if (((_local6.door_Top_Left != null) && (!_local6.door_Top_Left.orientedVertical)) && (!(_local6.door_Top_Left instanceof RemoteDoor))) {
_local6.door_Top_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Left);
}
if (((_local6.door_Top_Right != null) && (!_local6.door_Top_Right.orientedVertical)) && (!(_local6.door_Top_Right instanceof RemoteDoor))) {
_local6.door_Top_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Right);
}
}
} else {
var _local6 = tiles[_local3.row][_local3.col];
if (_local6 != null) {
if (((_local6.door_Top_Left != null) && (!_local6.door_Top_Left.orientedVertical)) && (!(_local6.door_Top_Left instanceof RemoteDoor))) {
_local6.door_Top_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Left);
}
if (((_local6.door_Bottom_Left != null) && (!_local6.door_Bottom_Left.orientedVertical)) && (!(_local6.door_Bottom_Left instanceof RemoteDoor))) {
_local6.door_Bottom_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Left);
}
}
}
} else if (_local4 == "R") {
if (_local3.wall_Right.isOpen) {
var _local6 = tiles[_local3.row - 1][_local3.col + 1];
if (_local6 != null) {
if (((_local6.door_Bottom_Left != null) && (!_local6.door_Bottom_Left.orientedVertical)) && (!(_local6.door_Bottom_Left instanceof RemoteDoor))) {
_local6.door_Bottom_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Left);
}
if (((_local6.door_Bottom_Right != null) && (!_local6.door_Bottom_Right.orientedVertical)) && (!(_local6.door_Bottom_Right instanceof RemoteDoor))) {
_local6.door_Bottom_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Right);
}
}
_local6 = tiles[_local3.row + 1][_local3.col + 1];
if (_local6 != null) {
if (((_local6.door_Top_Left != null) && (!_local6.door_Top_Left.orientedVertical)) && (!(_local6.door_Top_Left instanceof RemoteDoor))) {
_local6.door_Top_Left.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Left);
}
if (((_local6.door_Top_Right != null) && (!_local6.door_Top_Right.orientedVertical)) && (!(_local6.door_Top_Right instanceof RemoteDoor))) {
_local6.door_Top_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Right);
}
}
} else {
var _local6 = tiles[_local3.row][_local3.col];
if (_local6 != null) {
if (((_local6.door_Top_Right != null) && (!_local6.door_Top_Right.orientedVertical)) && (!(_local6.door_Top_Right instanceof RemoteDoor))) {
_local6.door_Top_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Top_Right);
}
if (((_local6.door_Bottom_Right != null) && (!_local6.door_Bottom_Right.orientedVertical)) && (!(_local6.door_Bottom_Right instanceof RemoteDoor))) {
_local6.door_Bottom_Right.openDoor();
activeDoorTiles.push(_local6);
game.addToUndoSpot(_local6.door_Bottom_Right);
}
}
}
}
}
}
function toggleRemotes() {
var _local2 = 0;
while (_local2 < remotes.length) {
remotes[_local2].toggle();
activeDoorTiles.push(remotes[_local2].parentTile);
_local2++;
}
}
function save() {
var _local4 = themeNumber.toString(36);
_local4 = _local4 + (player.row.toString(36) + player.col.toString(36));
_local4 = _local4 + (goal.row.toString(36) + goal.col.toString(36));
var _local3 = 0;
while (_local3 < tiles.length) {
var _local2 = 0;
while (_local2 < tiles[_local3].length) {
if (tiles[_local3][_local2] != null) {
_local4 = _local4 + (((("" + tiles[_local3][_local2].row.toString(36)) + tiles[_local3][_local2].col.toString(36)) + Number(tiles[_local3][_local2] instanceof FloorlessTile).toString(36)) + tiles[_local3][_local2].save());
}
_local2++;
}
_local3++;
}
return(_local4);
}
function destroy() {
LAYER_Tiles = (LAYER_Switches = (LAYER_SplitFloors = (LAYER_Pivots = (LAYER_Goal = (LAYER_Player = (LAYER_Doors = (LAYER_Walls = null)))))));
while (activeDoorTiles.length > 0) {
activeDoorTiles.pop();
}
activeDoorTiles = null;
while (remotes.length > 0) {
remotes.pop();
}
remotes = null;
var _local3 = 0;
while (_local3 < tiles.length) {
var _local2 = 0;
while (_local2 < tiles[_local3].length) {
if (tiles[_local3][_local2] != null) {
tiles[_local3][_local2].destroy();
tiles[_local3][_local2] = null;
}
_local2++;
}
_local3++;
}
tiles = null;
themeNumber = null;
tileSize = null;
player.destroy();
player = null;
goal.destroy();
goal = null;
clip.removeMovieClip();
clip = null;
}
function load(str) {
if (str.length < 4) {
load(Levels["L" + str]);
return(undefined);
}
LAYER_Tiles = 1000;
LAYER_Switches = 2000;
LAYER_SplitFloors = 3000;
LAYER_Pivots = 5000;
LAYER_Goal = 6000;
LAYER_Player = 7000;
LAYER_Doors = 8000;
LAYER_Walls = 9000;
while (activeDoorTiles.length > 0) {
activeDoorTiles.pop();
}
while (remotes.length > 0) {
remotes.pop();
}
var _local7 = 0;
while (_local7 < tiles.length) {
var _local6 = 0;
while (_local6 < tiles[_local7].length) {
if (tiles[_local7][_local6] != null) {
tiles[_local7][_local6].destroy();
tiles[_local7][_local6] = null;
}
_local6++;
}
_local7++;
}
player.destroy();
player = null;
goal.destroy();
goal = null;
themeNumber = _root.themeNum;
_root.bgGrid.gotoAndStop(themeNumber);
_root.bgColor.gotoAndStop(themeNumber);
_root.bgBorder.gotoAndStop(themeNumber);
player = new Player(Number(parseInt(str.charAt(1), 36)), Number(parseInt(str.charAt(2), 36)), game);
goal = new Goal(Number(parseInt(str.charAt(3), 36)), Number(parseInt(str.charAt(4), 36)), this);
var _local8 = "";
var _local3 = 5;
while (_local3 < str.length) {
_local7 = parseInt(str.charAt(_local3), 36);
var _local6 = parseInt(str.charAt(_local3 + 1), 36);
if (parseInt(str.charAt(_local3 + 2), 36) == "1") {
tiles[_local7][_local6] = new FloorlessTile(_local7, _local6, this);
} else {
tiles[_local7][_local6] = new Tile(_local7, _local6, this);
}
_local3 = _local3 + 3;
var _local4 = 0;
if (str.charAt(_local3) == "%") {
_local4 = 6;
} else if (str.charAt(_local3) == "^") {
_local4 = 7;
} else if (str.charAt(_local3) == "&") {
_local4 = 8;
}
if (str.charAt(_local3 + _local4) == "@") {
_local4 = _local4 + 3;
} else if (str.charAt(_local3 + _local4) == "#") {
_local4 = _local4 + 4;
} else {
_local4 = _local4 + 1;
}
tiles[_local7][_local6].load(str.substr(_local3, _local4));
_local3 = _local3 + (_local4 - 1);
_local3++;
}
}
}
Symbol 770 MovieClip [__Packages.Player] Frame 0
class Player
{
var game, clip, row, col;
function Player (r, c, g) {
game = g;
clip = g.level.clip.attachMovie("Player", "Player", g.level.LAYER_Player++);
clip.cacheAsBitmap;
row = r;
col = c;
clip._x = (col * g.level.tileSize) + (g.level.tileSize / 2);
clip._y = (row * g.level.tileSize) + (g.level.tileSize / 2);
clip.gotoAndStop(g.level.themeNumber);
clip.ani.gotoAndStop(1);
}
function destroy() {
clip.removeMovieClip();
clip = null;
row = (col = null);
}
function moveTo(r, c) {
row = r;
col = c;
clip._x = (col * game.level.tileSize) + (game.level.tileSize / 2);
clip._y = (row * game.level.tileSize) + (game.level.tileSize / 2);
}
function moveBy(r, c) {
var _local3 = game.level.tiles[row][col];
if (r != 0) {
if ((_local3 == null) || (game.level.tiles[row + r][col] == null)) {
} else if (r > 0) {
if ((((_local3.wall_Bottom == null) || ((_local3.wall_Bottom instanceof OneWayDoor) && (((_local3 == _local3.wall_Bottom.parentTile) && (!(_local3.wall_Bottom instanceof RemoteOneWayDoor))) || (_local3.wall_Bottom.isOpen)))) && ((_local3.door_Bottom_Left == null) || (_local3.door_Bottom_Left.orientedVertical))) && ((_local3.door_Bottom_Right == null) || (_local3.door_Bottom_Right.orientedVertical))) {
var _local4 = game.level.tiles[row + r][col];
game.addNewUndoSpot(_local3);
if (((_local4.door_Top_Left == null) || ((!(_local4.door_Top_Left instanceof RemoteDoor)) || (_local4.door_Top_Left.orientedVertical))) && ((_local4.door_Top_Right == null) || ((!(_local4.door_Top_Right instanceof RemoteDoor)) || (_local4.door_Top_Right.orientedVertical)))) {
if (((_local3.wall_Bottom != null) && (_local3.wall_Bottom instanceof OneWayDoor)) && (!(_local3.wall_Bottom instanceof RemoteOneWayDoor))) {
if (_local3 == _local3.wall_Bottom.parentTile) {
if (!_local3.wall_Bottom.isOpen) {
_local3.wall_Bottom.openDoor();
game.level.activeDoorTiles.push(_local3);
game.addToUndoSpot(_local3.wall_Bottom);
}
} else if (_local3.wall_Bottom.isOpen) {
_local3.wall_Bottom.closeDoor();
game.level.activeDoorTiles.push(_local3);
game.addToUndoSpot(_local3.wall_Bottom);
}
}
if (((_local3.door_Bottom_Left != null) && (!(_local3.door_Bottom_Left instanceof RemoteDoor))) && (_local3.door_Bottom_Left.orientedVertical)) {
_local3.door_Bottom_Left.closeDoor();
game.addToUndoSpot(_local3.door_Bottom_Left);
}
if (((_local3.door_Bottom_Right != null) && (!(_local3.door_Bottom_Right instanceof RemoteDoor))) && (_local3.door_Bottom_Right.orientedVertical)) {
_local3.door_Bottom_Right.closeDoor();
game.addToUndoSpot(_local3.door_Bottom_Right);
}
if ((_local3.splitFloor != null) && (!(_local3.splitFloor instanceof RemoteSplitFloor))) {
_local3.splitFloor.openFloor();
game.addToUndoSpot(_local3.splitFloor);
}
if (((_local3.theSwitch != null) && (_local3.theSwitch.orientedVertical)) && (!_local3.theSwitch.onOne)) {
_local3.theSwitch.toggleSwitch();
game.addToUndoSpot(_local3.theSwitch);
}
row = row + r;
clip._y = (row * game.level.tileSize) + (game.level.tileSize / 2);
if (game.numMovesMade < 999) {
game.numMovesMade++;
}
clip.ani.gotoAndPlay("Going Down");
_root.SOUND_playerMoving.start();
if ((_local4.door_Top_Left != null) && (!_local4.door_Top_Left.orientedVertical)) {
_local4.door_Top_Left.openDoor();
game.level.activeDoorTiles.push(_local4);
game.addToUndoSpot(_local4.door_Top_Left);
}
if ((_local4.door_Top_Right != null) && (!_local4.door_Top_Right.orientedVertical)) {
_local4.door_Top_Right.openDoor();
game.level.activeDoorTiles.push(_local4);
game.addToUndoSpot(_local4.door_Top_Right);
}
if (((_local4.theSwitch != null) && (_local4.theSwitch.orientedVertical)) && (!_local4.theSwitch.onOne)) {
_local4.theSwitch.toggleSwitch();
game.addToUndoSpot(_local4.theSwitch);
}
}
}
} else if (r < 0) {
if ((((_local3.wall_Top == null) || ((_local3.wall_Top instanceof OneWayDoor) && (((_local3 == _local3.wall_Top.parentTile) && (!(_local3.wall_Top instanceof RemoteOneWayDoor))) || (_local3.wall_Top.isOpen)))) && ((_local3.door_Top_Left == null) || (_local3.door_Top_Left.orientedVertical))) && ((_local3.door_Top_Right == null) || (_local3.door_Top_Right.orientedVertical))) {
var _local4 = game.level.tiles[row + r][col];
game.addNewUndoSpot(_local3);
if (((_local4.door_Bottom_Left == null) || ((!(_local4.door_Bottom_Left instanceof RemoteDoor)) || (_local4.door_Bottom_Left.orientedVertical))) && ((_local4.door_Bottom_Right == null) || ((!(_local4.door_Bottom_Right instanceof RemoteDoor)) || _local4.door_Bottom_Right.orientedVertical))) {
if (((_local3.wall_Top != null) && (_local3.wall_Top instanceof OneWayDoor)) && (!(_local3.wall_Top instanceof RemoteOneWayDoor))) {
if (_local3 == _local3.wall_Top.parentTile) {
if (!_local3.wall_Top.isOpen) {
_local3.wall_Top.openDoor();
game.level.activeDoorTiles.push(_local3);
game.addToUndoSpot(_local3.wall_Top);
}
} else if (_local3.wall_Top.isOpen) {
_local3.wall_Top.closeDoor();
game.level.activeDoorTiles.push(_local3);
game.addToUndoSpot(_local3.wall_Top);
}
}
if (((_local3.door_Top_Left != null) && (!(_local3.door_Top_Left instanceof RemoteDoor))) && (_local3.door_Top_Left.orientedVertical)) {
_local3.door_Top_Left.closeDoor();
game.addToUndoSpot(_local3.door_Top_Left);
}
if (((_local3.door_Top_Right != null) && (!(_local3.door_Top_Right instanceof RemoteDoor))) && (_local3.door_Top_Right.orientedVertical)) {
_local3.door_Top_Right.closeDoor();
game.addToUndoSpot(_local3.door_Top_Right);
}
if ((_local3.splitFloor != null) && (!(_local3.splitFloor instanceof RemoteSplitFloor))) {
_local3.splitFloor.openFloor();
game.addToUndoSpot(_local3.splitFloor);
}
if (((_local3.theSwitch != null) && (_local3.theSwitch.orientedVertical)) && (_local3.theSwitch.onOne)) {
_local3.theSwitch.toggleSwitch();
game.addToUndoSpot(_local3.theSwitch);
}
row = row + r;
clip._y = (row * game.level.tileSize) + (game.level.tileSize / 2);
if (game.numMovesMade < 999) {
game.numMovesMade++;
}
clip.ani.gotoAndPlay("Going Up");
_root.SOUND_playerMoving.start();
if ((_local4.door_Bottom_Left != null) && (!_local4.door_Bottom_Left.orientedVertical)) {
_local4.door_Bottom_Left.openDoor();
game.level.activeDoorTiles.push(_local4);
game.addToUndoSpot(_local4.door_Bottom_Left);
}
if ((_local4.door_Bottom_Right != null) && (!_local4.door_Bottom_Right.orientedVertical)) {
_local4.door_Bottom_Right.openDoor();
game.level.activeDoorTiles.push(_local4);
game.addToUndoSpot(_local4.door_Bottom_Right);
}
if (((_local4.theSwitch != null) && (_local4.theSwitch.orientedVertical)) && (_local4.theSwitch.onOne)) {
_local4.theSwitch.toggleSwitch();
game.addToUndoSpot(_local4.theSwitch);
}
}
}
}
}
if (c != 0) {
if ((_local3 == null) || (game.level.tiles[row][col + c] == null)) {
} else if (c > 0) {
if ((((_local3.wall_Right == null) || ((_local3.wall_Right instanceof OneWayDoor) && (((_local3 == _local3.wall_Right.parentTile) && (!(_local3.wall_Right instanceof RemoteOneWayDoor))) || (_local3.wall_Right.isOpen)))) && ((_local3.door_Top_Right == null) || (!_local3.door_Top_Right.orientedVertical))) && ((_local3.door_Bottom_Right == null) || (!_local3.door_Bottom_Right.orientedVertical))) {
var _local4 = game.level.tiles[row][col + c];
game.addNewUndoSpot(_local3);
if (((_local4.door_Bottom_Left == null) || ((!(_local4.door_Bottom_Left instanceof RemoteDoor)) || (!_local4.door_Bottom_Left.orientedVertical))) && ((_local4.door_Top_Left == null) || ((!(_local4.door_Top_Left instanceof RemoteDoor)) || (!_local4.door_Top_Left.orientedVertical)))) {
if (((_local3.wall_Right != null) && (_local3.wall_Right instanceof OneWayDoor)) && (!(_local3.wall_Right instanceof RemoteOneWayDoor))) {
if (_local3 == _local3.wall_Right.parentTile) {
if (!_local3.wall_Right.isOpen) {
_local3.wall_Right.openDoor();
game.level.activeDoorTiles.push(_local3);
game.addToUndoSpot(_local3.wall_Right);
}
} else if (_local3.wall_Right.isOpen) {
_local3.wall_Right.closeDoor();
game.level.activeDoorTiles.push(_local3);
game.addToUndoSpot(_local3.wall_Right);
}
}
if (((_local3.door_Top_Right != null) && (!(_local3.door_Top_Right instanceof RemoteDoor))) && (!_local3.door_Top_Right.orientedVertical)) {
_local3.door_Top_Right.closeDoor();
game.addToUndoSpot(_local3.door_Top_Right);
}
if (((_local3.door_Bottom_Right != null) && (!(_local3.door_Bottom_Right instanceof RemoteDoor))) && (!_local3.door_Bottom_Right.orientedVertical)) {
_local3.door_Bottom_Right.closeDoor();
game.addToUndoSpot(_local3.door_Bottom_Right);
}
if ((_local3.splitFloor != null) && (!(_local3.splitFloor instanceof RemoteSplitFloor))) {
_local3.splitFloor.openFloor();
game.addToUndoSpot(_local3.splitFloor);
}
if (((_local3.theSwitch != null) && (!_local3.theSwitch.orientedVertical)) && (!_local3.theSwitch.onOne)) {
_local3.theSwitch.toggleSwitch();
game.addToUndoSpot(_local3.theSwitch);
}
col = col + c;
clip._x = (col * game.level.tileSize) + (game.level.tileSize / 2);
if (game.numMovesMade < 999) {
game.numMovesMade++;
}
clip.ani.gotoAndPlay("Going Right");
_root.SOUND_playerMoving.start();
_local4 = game.level.tiles[row][col];
if ((_local4.door_Top_Left != null) && (_local4.door_Top_Left.orientedVertical)) {
_local4.door_Top_Left.openDoor();
game.level.activeDoorTiles.push(_local4);
game.addToUndoSpot(_local4.door_Top_Left);
}
if ((_local4.door_Bottom_Left != null) && (_local4.door_Bottom_Left.orientedVertical)) {
_local4.door_Bottom_Left.openDoor();
game.level.activeDoorTiles.push(_local4);
game.addToUndoSpot(_local4.door_Bottom_Left);
}
if (((_local4.theSwitch != null) && (!_local4.theSwitch.orientedVertical)) && (!_local4.theSwitch.onOne)) {
_local4.theSwitch.toggleSwitch();
game.addToUndoSpot(_local4.theSwitch);
}
}
}
} else if (c < 0) {
if ((((_local3.wall_Left == null) || ((_local3.wall_Left instanceof OneWayDoor) && (((_local3 == _local3.wall_Left.parentTile) && (!(_local3.wall_Left instanceof RemoteOneWayDoor))) || (_local3.wall_Left.isOpen)))) && ((_local3.door_Top_Left == null) || (!_local3.door_Top_Left.orientedVertical))) && ((_local3.door_Bottom_Left == null) || (!_local3.door_Bottom_Left.orientedVertical))) {
var _local4 = game.level.tiles[row][col + c];
game.addNewUndoSpot(_local3);
if (((_local4.door_Bottom_Right == null) || ((!(_local4.door_Bottom_Right instanceof RemoteDoor)) || (!_local4.door_Bottom_Right.orientedVertical))) && ((_local4.door_Top_Right == null) || ((!(_local4.door_Top_Right instanceof RemoteDoor)) || (!_local4.door_Top_Right.orientedVertical)))) {
if (((_local3.wall_Left != null) && (_local3.wall_Left instanceof OneWayDoor)) && (!(_local3.wall_Left instanceof RemoteOneWayDoor))) {
if (_local3 == _local3.wall_Left.parentTile) {
if (!_local3.wall_Left.isOpen) {
_local3.wall_Left.openDoor();
game.level.activeDoorTiles.push(_local3);
game.addToUndoSpot(_local3.wall_Left);
}
} else if (_local3.wall_Left.isOpen) {
_local3.wall_Left.closeDoor();
game.level.activeDoorTiles.push(_local3);
game.addToUndoSpot(_local3.wall_Left);
}
}
if (((_local3.door_Top_Left != null) && (!(_local3.door_Top_Left instanceof RemoteDoor))) && (!_local3.door_Top_Left.orientedVertical)) {
_local3.door_Top_Left.closeDoor();
game.addToUndoSpot(_local3.door_Top_Left);
}
if (((_local3.door_Bottom_Left != null) && (!(_local3.door_Bottom_Left instanceof RemoteDoor))) && (!_local3.door_Bottom_Left.orientedVertical)) {
_local3.door_Bottom_Left.closeDoor();
game.addToUndoSpot(_local3.door_Bottom_Left);
}
if ((_local3.splitFloor != null) && (!(_local3.splitFloor instanceof RemoteSplitFloor))) {
_local3.splitFloor.openFloor();
game.addToUndoSpot(_local3.splitFloor);
}
if (((_local3.theSwitch != null) && (!_local3.theSwitch.orientedVertical)) && (_local3.theSwitch.onOne)) {
_local3.theSwitch.toggleSwitch();
game.addToUndoSpot(_local3.theSwitch);
}
col = col + c;
clip._x = (col * game.level.tileSize) + (game.level.tileSize / 2);
if (game.numMovesMade < 999) {
game.numMovesMade++;
}
clip.ani.gotoAndPlay("Going Left");
_root.SOUND_playerMoving.start();
_local4 = game.level.tiles[row][col];
if ((_local4.door_Top_Right != null) && (_local4.door_Top_Right.orientedVertical)) {
_local4.door_Top_Right.openDoor();
game.level.activeDoorTiles.push(_local4);
game.addToUndoSpot(_local4.door_Top_Right);
}
if ((_local4.door_Bottom_Right != null) && (_local4.door_Bottom_Right.orientedVertical)) {
_local4.door_Bottom_Right.openDoor();
game.level.activeDoorTiles.push(_local4);
game.addToUndoSpot(_local4.door_Bottom_Right);
}
if (((_local4.theSwitch != null) && (!_local4.theSwitch.orientedVertical)) && (_local4.theSwitch.onOne)) {
_local4.theSwitch.toggleSwitch();
game.addToUndoSpot(_local4.theSwitch);
}
}
}
}
}
}
}
Symbol 771 MovieClip [__Packages.Tile] Frame 0
class Tile
{
var level, clip, row, col, wall_Left, wall_Right, wall_Top, wall_Bottom, door_Top_Left, door_Top_Right, door_Bottom_Left, door_Bottom_Right, splitFloor, theSwitch;
function Tile (r, c, l) {
level = l;
clip = l.clip.tiles.attachMovie("Tile", "Tile" + l.LAYER_Tiles, l.LAYER_Tiles++);
clip.cacheAsBitmap;
row = r;
col = c;
clip._x = (col * l.tileSize) + (l.tileSize / 2);
clip._y = (row * l.tileSize) + (l.tileSize / 2);
clip.bgGrid.eh.gotoAndStop(l.themeNumber);
clip.bgColor.gotoAndStop(l.themeNumber);
wall_Left = null;
wall_Right = null;
wall_Top = null;
wall_Bottom = null;
door_Top_Left = null;
door_Top_Right = null;
door_Bottom_Left = null;
door_Bottom_Right = null;
splitFloor = null;
theSwitch = null;
clip.editor._visible = false;
}
function destroy() {
clip.removeMovieClip();
clip = null;
row = (col = null);
wall_Left.destroy();
wall_Right.destroy();
wall_Top.destroy();
wall_Bottom.destroy();
wall_Left = (wall_Right = (wall_Top = (wall_Bottom = null)));
door_Top_Left.destroy();
door_Top_Right.destroy();
door_Bottom_Left.destroy();
door_Bottom_Right.destroy();
door_Top_Left = (door_Top_Right = (door_Bottom_Left = (door_Bottom_Right = null)));
splitFloor.destroy();
splitFloor = null;
theSwitch.destroy();
theSwitch = null;
}
function addWall(str) {
if (str == "Left") {
wall_Left = new Wall(clip._x - (level.tileSize / 2), clip._y, level);
wall_Left.clip._rotation = 90;
} else if (str == "Right") {
wall_Right = new Wall(clip._x + (level.tileSize / 2), clip._y, level);
wall_Right.clip._rotation = 90;
} else if (str == "Top") {
wall_Top = new Wall(clip._x, clip._y - (level.tileSize / 2), level);
} else if (str == "Bottom") {
wall_Bottom = new Wall(clip._x, clip._y + (level.tileSize / 2), level);
}
}
function addDoor(str, num) {
if (str == "Top_Left") {
door_Top_Left = new Door(clip._x - (level.tileSize / 2), clip._y - (level.tileSize / 2), level);
door_Top_Left.setDoor(Boolean(num), false);
} else if (str == "Top_Right") {
door_Top_Right = new Door(clip._x + (level.tileSize / 2), clip._y - (level.tileSize / 2), level);
door_Top_Right.clip._rotation = (door_Top_Right.pClip._rotation = 90);
door_Top_Right.setDoor(!Boolean(num), true);
} else if (str == "Bottom_Left") {
door_Bottom_Left = new Door(clip._x - (level.tileSize / 2), clip._y + (level.tileSize / 2), level);
door_Bottom_Left.clip._rotation = (door_Bottom_Left.pClip._rotation = -90);
door_Bottom_Left.setDoor(!Boolean(num), true);
} else if (str == "Bottom_Right") {
door_Bottom_Right = new Door(clip._x + (level.tileSize / 2), clip._y + (level.tileSize / 2), level);
door_Bottom_Right.clip._rotation = (door_Bottom_Right.pClip._rotation = 180);
door_Bottom_Right.setDoor(Boolean(num), false);
}
}
function addSplitFloor(num) {
splitFloor = new SplitFloor(clip._x, clip._y, level);
splitFloor.setFloor(Boolean(num));
}
function addSwitch(num) {
theSwitch = new Switch(clip._x, clip._y, level);
theSwitch.setSwitch(false, Boolean(num));
}
function save() {
var _local2 = "";
if (wall_Top != null) {
if (wall_Top instanceof RemoteOneWayDoor) {
if (wall_Top.parentTile == this) {
_local2 = _local2 + ("" + (wall_Top.clip.eh._currentframe + 4));
} else {
_local2 = _local2 + "1";
}
} else if (wall_Top instanceof OneWayDoor) {
if (wall_Top.parentTile == this) {
_local2 = _local2 + ("" + (wall_Top.clip.eh._currentframe + 2));
} else {
_local2 = _local2 + "1";
}
} else {
_local2 = _local2 + "2";
}
} else {
_local2 = _local2 + "1";
}
if (wall_Bottom != null) {
if (wall_Bottom instanceof RemoteOneWayDoor) {
if (wall_Bottom.parentTile == this) {
_local2 = _local2 + ("" + (wall_Bottom.clip.eh._currentframe + 3));
} else {
_local2 = _local2 + "0";
}
} else if (wall_Bottom instanceof OneWayDoor) {
if (wall_Bottom.parentTile == this) {
_local2 = _local2 + ("" + (wall_Bottom.clip.eh._currentframe + 1));
} else {
_local2 = _local2 + "0";
}
} else {
_local2 = _local2 + "1";
}
} else {
_local2 = _local2 + "0";
}
if (wall_Left != null) {
if (wall_Left instanceof RemoteOneWayDoor) {
if (wall_Left.parentTile == this) {
_local2 = _local2 + ("" + (wall_Left.clip.eh._currentframe + 3));
} else {
_local2 = _local2 + "0";
}
} else if (wall_Left instanceof OneWayDoor) {
if (wall_Left.parentTile == this) {
_local2 = _local2 + ("" + (wall_Left.clip.eh._currentframe + 1));
} else {
_local2 = _local2 + "0";
}
} else {
_local2 = _local2 + "1";
}
} else {
_local2 = _local2 + "0";
}
if (wall_Right != null) {
if (wall_Right instanceof RemoteOneWayDoor) {
if (wall_Right.parentTile == this) {
_local2 = _local2 + ("" + (wall_Right.clip.eh._currentframe + 3));
} else {
_local2 = _local2 + "0";
}
} else if (wall_Right instanceof OneWayDoor) {
if (wall_Right.parentTile == this) {
_local2 = _local2 + ("" + (wall_Right.clip.eh._currentframe + 1));
} else {
_local2 = _local2 + "0";
}
} else {
_local2 = _local2 + "1";
}
} else {
_local2 = _local2 + "0";
}
if (door_Top_Left == null) {
_local2 = _local2 + "0";
} else if (door_Top_Left instanceof RemoteDoor) {
_local2 = _local2 + ("" + (door_Top_Left.clip.eh._currentframe + 2));
} else {
_local2 = _local2 + ("" + door_Top_Left.clip.eh._currentframe);
}
if (door_Top_Right == null) {
_local2 = _local2 + "0";
} else if (door_Top_Right instanceof RemoteDoor) {
_local2 = _local2 + ("" + (door_Top_Right.clip.eh._currentframe + 2));
} else {
_local2 = _local2 + ("" + door_Top_Right.clip.eh._currentframe);
}
if (door_Bottom_Left == null) {
_local2 = _local2 + "0";
} else if (door_Bottom_Left instanceof RemoteDoor) {
_local2 = _local2 + ("" + (door_Bottom_Left.clip.eh._currentframe + 2));
} else {
_local2 = _local2 + ("" + door_Bottom_Left.clip.eh._currentframe);
}
if (door_Bottom_Right == null) {
_local2 = _local2 + "0";
} else if (door_Bottom_Right instanceof RemoteDoor) {
_local2 = _local2 + ("" + (door_Bottom_Right.clip.eh._currentframe + 2));
} else {
_local2 = _local2 + ("" + door_Bottom_Right.clip.eh._currentframe);
}
_local2 = Number(_local2).toString(36);
if (_local2.length == 5) {
_local2 = "%" + _local2;
} else if (_local2.length == 6) {
_local2 = "^" + _local2;
} else if (_local2.length == 7) {
_local2 = "&" + _local2;
}
var _local3 = "";
if (splitFloor == null) {
_local3 = _local3 + "1";
} else if (splitFloor instanceof RemoteSplitFloor) {
_local3 = _local3 + ("" + (splitFloor.clip.eh._currentframe + 3));
} else {
_local3 = _local3 + ("" + (splitFloor.clip.eh._currentframe + 1));
}
if (theSwitch == null) {
_local3 = _local3 + "0";
} else if (theSwitch.orientedVertical) {
_local3 = _local3 + ("" + (theSwitch.clip.eh._currentframe + 2));
} else {
_local3 = _local3 + ("" + theSwitch.clip.eh._currentframe);
}
_local3 = Number(_local3).toString(36);
if (_local3.length == 2) {
_local3 = "@" + _local3;
} else if (_local3.length == 3) {
_local3 = "#" + _local3;
}
_local2 = _local2 + _local3;
return(_local2);
}
function load(str) {
var _local4 = 0;
if (str.charAt(0) == "%") {
_local4 = 6;
} else if (str.charAt(0) == "^") {
_local4 = 7;
} else if (str.charAt(0) == "&") {
_local4 = 8;
}
var _local3 = "";
if (str.charAt(_local4) == "@") {
_local3 = String(parseInt(str.substr(_local4 + 1, 2), 36));
} else if (str.charAt(_local4) == "#") {
_local3 = "" + parseInt(str.substr(_local4 + 1, 3), 36);
} else {
_local3 = "" + parseInt(str.substr(_local4, 1), 36);
}
str = "" + parseInt(str.substr(1, _local4 - 1), 36);
if ((str.charAt(0) != "1") || (level.tiles[row - 1][col].wall_Bottom != null)) {
if (level.tiles[row - 1][col].wall_Bottom != null) {
wall_Top = level.tiles[row - 1][col].wall_Bottom;
} else if (str.charAt(0) == "2") {
addWall("Top");
} else if ((str.charAt(0) == "3") || (str.charAt(0) == "4")) {
wall_Top = new OneWayDoor(clip._x, clip._y - (level.tileSize / 2), level, this);
wall_Top.clip._rotation = (wall_Top.pClip._rotation = -90);
wall_Top.setDoor(Boolean(Number(str.charAt(0)) - 3));
if (level.tiles[row - 1][col] != null) {
level.tiles[row - 1][col].wall_Bottom = wall_Top;
}
} else if ((str.charAt(0) == "5") || (str.charAt(0) == "6")) {
wall_Top = new RemoteOneWayDoor(clip._x, clip._y - (level.tileSize / 2), level, this);
wall_Top.clip._rotation = (wall_Top.pClip._rotation = -90);
wall_Top.setDoor(Boolean(Number(str.charAt(0)) - 5));
if (level.tiles[row - 1][col] != null) {
level.tiles[row - 1][col].wall_Bottom = wall_Top;
}
}
}
if ((str.charAt(1) != "0") || (level.tiles[row + 1][col].wall_Top != null)) {
if (level.tiles[row + 1][col].wall_Top != null) {
wall_Bottom = level.tiles[row + 1][col].wall_Top;
} else if (str.charAt(1) == "1") {
addWall("Bottom");
} else if ((str.charAt(1) == "2") || (str.charAt(1) == "3")) {
wall_Bottom = new OneWayDoor(clip._x, clip._y + (level.tileSize / 2), level, this);
wall_Bottom.clip._rotation = (wall_Bottom.pClip._rotation = 90);
wall_Bottom.setDoor(Boolean(Number(str.charAt(1)) - 2));
} else if ((str.charAt(1) == "4") || (str.charAt(1) == "5")) {
wall_Bottom = new RemoteOneWayDoor(clip._x, clip._y + (level.tileSize / 2), level, this);
wall_Bottom.clip._rotation = (wall_Bottom.pClip._rotation = 90);
wall_Bottom.setDoor(Boolean(Number(str.charAt(1)) - 4));
}
}
if ((str.charAt(2) != "0") || (level.tiles[row][col - 1].wall_Right != null)) {
if (level.tiles[row][col - 1].wall_Right != null) {
wall_Left = level.tiles[row][col - 1].wall_Right;
} else if (str.charAt(2) == "1") {
addWall("Left");
} else if ((str.charAt(2) == "2") || (str.charAt(2) == "3")) {
wall_Left = new OneWayDoor(clip._x - (level.tileSize / 2), clip._y, level, this);
wall_Left.clip._rotation = (wall_Left.pClip._rotation = 180);
wall_Left.setDoor(Boolean(Number(str.charAt(2)) - 2));
if (level.tiles[row][col - 1] != null) {
level.tiles[row][col - 1].wall_Right = wall_Left;
}
} else if ((str.charAt(2) == "4") || (str.charAt(2) == "5")) {
wall_Left = new RemoteOneWayDoor(clip._x - (level.tileSize / 2), clip._y, level, this);
wall_Left.clip._rotation = (wall_Left.pClip._rotation = 180);
wall_Left.setDoor(Boolean(Number(str.charAt(2)) - 4));
if (level.tiles[row][col - 1] != null) {
level.tiles[row][col - 1].wall_Right = wall_Left;
}
}
}
if ((str.charAt(3) != "0") || (level.tiles[row][col + 1].wall_Left != null)) {
if (level.tiles[row][col + 1].wall_Left != null) {
wall_Right = level.tiles[row][col + 1].wall_Left;
} else if (str.charAt(3) == "1") {
addWall("Right");
} else if ((str.charAt(3) == "2") || (str.charAt(3) == "3")) {
wall_Right = new OneWayDoor(clip._x + (level.tileSize / 2), clip._y, level, this);
wall_Right.setDoor(Boolean(Number(str.charAt(3)) - 2));
} else if ((str.charAt(3) == "4") || (str.charAt(3) == "5")) {
wall_Right = new RemoteOneWayDoor(clip._x + (level.tileSize / 2), clip._y, level, this);
wall_Right.setDoor(Boolean(Number(str.charAt(3)) - 4));
}
}
if (str.charAt(4) != "0") {
if ((str.charAt(4) == "1") || (str.charAt(4) == "2")) {
addDoor("Top_Left", Number(str.charAt(4)) - 1);
} else if ((str.charAt(4) == "3") || (str.charAt(4) == "4")) {
door_Top_Left = new RemoteDoor(clip._x - (level.tileSize / 2), clip._y - (level.tileSize / 2), level, this);
door_Top_Left.setDoor(Boolean(Number(str.charAt(4)) - 3), false);
}
}
if (str.charAt(5) != "0") {
if ((str.charAt(5) == "1") || (str.charAt(5) == "2")) {
addDoor("Top_Right", Number(str.charAt(5)) - 1);
} else if ((str.charAt(5) == "3") || (str.charAt(5) == "4")) {
door_Top_Right = new RemoteDoor(clip._x + (level.tileSize / 2), clip._y - (level.tileSize / 2), level, this);
door_Top_Right.clip._rotation = (door_Top_Right.pClip._rotation = 90);
door_Top_Right.setDoor(!Boolean(Number(str.charAt(5)) - 3), true);
}
}
if (str.charAt(6) != "0") {
if ((str.charAt(6) == "1") || (str.charAt(6) == "2")) {
addDoor("Bottom_Left", Number(str.charAt(6)) - 1);
} else if ((str.charAt(6) == "3") || (str.charAt(6) == "4")) {
door_Bottom_Left = new RemoteDoor(clip._x - (level.tileSize / 2), clip._y + (level.tileSize / 2), level, this);
door_Bottom_Left.clip._rotation = (door_Bottom_Left.pClip._rotation = -90);
door_Bottom_Left.setDoor(!Boolean(Number(str.charAt(6)) - 3), true);
}
}
if (str.charAt(7) != "0") {
if ((str.charAt(7) == "1") || (str.charAt(7) == "2")) {
addDoor("Bottom_Right", Number(str.charAt(7)) - 1);
} else if ((str.charAt(7) == "3") || (str.charAt(7) == "4")) {
door_Bottom_Right = new RemoteDoor(clip._x + (level.tileSize / 2), clip._y + (level.tileSize / 2), level, this);
door_Bottom_Right.clip._rotation = (door_Bottom_Right.pClip._rotation = 180);
door_Bottom_Right.setDoor(Boolean(Number(str.charAt(7)) - 3), false);
}
}
if (_local3.charAt(0) != "1") {
if (Number(_local3.charAt(0)) < 4) {
addSplitFloor(Number(_local3.charAt(0)) - 2);
} else {
splitFloor = new RemoteSplitFloor(clip._x, clip._y, level, this);
splitFloor.setFloor(Boolean(Number(_local3.charAt(0)) - 4));
}
}
if (_local3.charAt(1) != "0") {
if (Number(_local3.charAt(1)) < 3) {
addSwitch(Number(_local3.charAt(1)) - 1);
} else {
addSwitch(Number(_local3.charAt(1)) - 3);
theSwitch.setSwitch(true, theSwitch.onOne);
}
}
}
}
Symbol 772 MovieClip [__Packages.Wall] Frame 0
class Wall
{
var clip, pClip;
function Wall (x, y, l) {
clip = l.clip.walls.attachMovie("Wall", "Wall" + l.LAYER_Walls, l.LAYER_Walls++);
clip.cacheAsBitmap;
clip._x = x;
clip._y = y;
pClip = null;
}
function destroy() {
clip.removeMovieClip();
clip = null;
pClip.removeMovieClip();
pClip = null;
}
function setDoor(isO) {
}
function closeDoor() {
}
function openDoor() {
}
function toggleDoor() {
}
}
Symbol 773 MovieClip [__Packages.Door] Frame 0
class Door
{
var clip, pClip, orientedVertical, rotated;
function Door (x, y, l) {
clip = l.clip.attachMovie("Door", "Door" + l.LAYER_Doors, l.LAYER_Doors++);
clip.cacheAsBitmap;
clip._x = x;
clip._y = y;
pClip = l.clip.attachMovie("Pivot", "Pivot" + l.LAYER_Pivots, l.LAYER_Pivots++);
pClip.cacheAsBitmap;
pClip._x = x;
pClip._y = y;
orientedVertical = false;
rotated = false;
clip.gotoAndStop(l.themeNumber);
setDoor(orientedVertical, rotated);
}
function destroy() {
clip.removeMovieClip();
clip = null;
pClip.removeMovieClip();
pClip = null;
orientedVertical = (rotated = null);
}
function setDoor(isVertical, isRotated) {
orientedVertical = isVertical;
rotated = isRotated;
if (rotated) {
clip.eh.gotoAndStop(Number(!orientedVertical) + 1);
} else {
clip.eh.gotoAndStop(Number(orientedVertical) + 1);
}
}
function closeDoor() {
orientedVertical = !orientedVertical;
if (rotated) {
clip.eh.gotoAndStop(Number(!orientedVertical) + 1);
} else {
clip.eh.gotoAndStop(Number(orientedVertical) + 1);
}
clip.eh.door.gotoAndPlay(2);
_root.SOUND_doorOpening.start();
}
function openDoor() {
orientedVertical = !orientedVertical;
if (rotated) {
clip.eh.gotoAndStop(Number(!orientedVertical) + 1);
} else {
clip.eh.gotoAndStop(Number(orientedVertical) + 1);
}
clip.eh.door.gotoAndPlay(2);
_root.SOUND_doorOpening.start();
}
function toggleDoor() {
orientedVertical = !orientedVertical;
if (rotated) {
clip.eh.gotoAndStop(Number(!orientedVertical) + 1);
} else {
clip.eh.gotoAndStop(Number(orientedVertical) + 1);
}
clip.eh.door.gotoAndPlay(2);
_root.SOUND_doorOpening.start();
}
function toggle() {
orientedVertical = !orientedVertical;
if (rotated) {
clip.eh.gotoAndStop(Number(!orientedVertical) + 1);
} else {
clip.eh.gotoAndStop(Number(orientedVertical) + 1);
}
clip.eh.door.gotoAndPlay(2);
_root.SOUND_doorOpening.start();
}
}
Symbol 774 MovieClip [__Packages.SplitFloor] Frame 0
class SplitFloor
{
var clip, isOpen;
function SplitFloor (x, y, l) {
clip = l.clip.attachMovie("SplitFloor", "SplitFloor" + l.LAYER_SplitFloors, l.LAYER_SplitFloors++);
clip.cacheAsBitmap;
clip._x = x;
clip._y = y;
isOpen = false;
clip.gotoAndStop(l.themeNumber);
clip.eh.gotoAndStop(Number(isOpen) + 1);
}
function destroy() {
clip.removeMovieClip();
clip = null;
isOpen = null;
}
function setFloor(isO) {
isOpen = isO;
clip.eh.gotoAndStop(Number(isOpen) + 1);
}
function openFloor() {
isOpen = true;
clip.eh.gotoAndStop(Number(isOpen) + 1);
clip.eh.door.gate.gotoAndPlay(2);
_root.SOUND_gateToggle.start();
}
function closeFloor() {
isOpen = false;
clip.eh.gotoAndStop(Number(isOpen) + 1);
clip.eh.door.gate.gotoAndPlay(2);
_root.SOUND_gateToggle.start();
}
function toggleFloor() {
isOpen = !isOpen;
clip.eh.gotoAndStop(Number(isOpen) + 1);
clip.eh.door.gate.gotoAndPlay(2);
_root.SOUND_gateToggle.start();
}
function toggle() {
isOpen = !isOpen;
clip.eh.gotoAndStop(Number(isOpen) + 1);
clip.eh.door.gate.gotoAndPlay(2);
_root.SOUND_gateToggle.start();
}
}
Symbol 775 MovieClip [__Packages.Switch] Frame 0
class Switch
{
var level, clip, orientedVertical, onOne;
function Switch (x, y, l) {
level = l;
clip = l.clip.attachMovie("LeverSwitch", "LeverSwitch" + l.LAYER_Switches, l.LAYER_Switches++);
clip.cacheAsBitmap;
clip._x = x;
clip._y = y;
orientedVertical = false;
onOne = false;
clip.gotoAndStop(l.themeNumber);
clip.eh.gotoAndStop(Number(onOne) + 1);
}
function setSwitch(isVertical, isOn) {
orientedVertical = isVertical;
onOne = isOn;
clip.eh.gotoAndStop(Number(onOne) + 1);
if (orientedVertical) {
clip._rotation = 90;
} else {
clip._rotation = 0;
}
}
function toggleSwitch() {
onOne = !onOne;
clip.eh.gotoAndStop(Number(onOne) + 1);
level.toggleRemotes();
clip.eh.state.gotoAndPlay(2);
_root.SOUND_switchToggled.start();
}
function toggle() {
onOne = !onOne;
clip.eh.gotoAndStop(Number(onOne) + 1);
level.toggleRemotes();
clip.eh.state.gotoAndPlay(2);
_root.SOUND_switchToggled.start();
}
function destroy() {
clip.removeMovieClip();
clip = null;
onOne = null;
}
}
Symbol 776 MovieClip [__Packages.OneWayDoor] Frame 0
class OneWayDoor extends Wall
{
var clip, pClip, parentTile, isOpen;
function OneWayDoor (x, y, l, tile) {
super();
clip = l.clip.attachMovie("OneWayDoor", "OneWayDoor" + l.LAYER_Doors, l.LAYER_Doors++);
clip.cacheAsBitmap;
clip._x = x;
clip._y = y;
pClip = l.clip.attachMovie("OneWayPivot", "OneWayPivot" + l.LAYER_Pivots, l.LAYER_Pivots++);
pClip.cacheAsBitmap;
pClip._x = x;
pClip._y = y;
parentTile = tile;
isOpen = false;
clip.gotoAndStop(l.themeNumber);
setDoor(isOpen);
}
function destroy() {
clip.removeMovieClip();
clip = null;
pClip.removeMovieClip();
pClip = null;
isOpen = null;
}
function setDoor(isO) {
isOpen = isO;
clip.eh.gotoAndStop(Number(isOpen) + 1);
}
function closeDoor() {
isOpen = false;
clip.eh.gotoAndStop(Number(isOpen) + 1);
clip.eh.door1.gotoAndPlay(2);
clip.eh.door2.gotoAndPlay(2);
_root.SOUND_parlorDoorOpening.start();
}
function openDoor() {
isOpen = true;
clip.eh.gotoAndStop(Number(isOpen) + 1);
clip.eh.door1.gotoAndPlay(2);
clip.eh.door2.gotoAndPlay(2);
_root.SOUND_parlorDoorOpening.start();
}
function toggleDoor() {
isOpen = !isOpen;
clip.eh.gotoAndStop(Number(isOpen) + 1);
clip.eh.door1.gotoAndPlay(2);
clip.eh.door2.gotoAndPlay(2);
_root.SOUND_parlorDoorOpening.start();
}
function toggle() {
isOpen = !isOpen;
clip.eh.gotoAndStop(Number(isOpen) + 1);
clip.eh.door1.gotoAndPlay(2);
clip.eh.door2.gotoAndPlay(2);
_root.SOUND_parlorDoorOpening.start();
}
}
Symbol 777 MovieClip [__Packages.RemoteOneWayDoor] Frame 0
class RemoteOneWayDoor extends OneWayDoor
{
var clip, setDoor, isOpen, parentTile;
function RemoteOneWayDoor (x, y, l, tile) {
super(x, y, l, tile);
clip.removeMovieClip();
clip = l.clip.attachMovie("RemoteOneWayDoor", "RemoteOneWayDoor" + l.LAYER_Doors, l.LAYER_Doors++);
clip.cacheAsBitmap;
clip._x = x;
clip._y = y;
clip.gotoAndStop(l.themeNumber);
setDoor(isOpen);
l.remotes.push(this);
}
function destroy() {
var _local3 = 0;
while (_local3 < parentTile.level.remotes.length) {
if (parentTile.level.remotes[_local3].clip == clip) {
parentTile.level.remotes.splice(_local3, 1);
break;
}
_local3++;
}
super.destroy();
}
}
Symbol 778 MovieClip [__Packages.RemoteDoor] Frame 0
class RemoteDoor extends Door
{
var clip, setDoor, orientedVertical, rotated, parentTile;
function RemoteDoor (x, y, l, tile) {
super(x, y, l);
clip.removeMovieClip();
clip = l.clip.attachMovie("RemoteDoor", "RemoteDoor" + l.LAYER_Doors, l.LAYER_Doors++);
clip.cacheAsBitmap;
clip._x = x;
clip._y = y;
clip.gotoAndStop(l.themeNumber);
setDoor(orientedVertical, rotated);
parentTile = tile;
l.remotes.push(this);
}
function destroy() {
var _local3 = 0;
while (_local3 < parentTile.level.remotes.length) {
if (parentTile.level.remotes[_local3].clip == clip) {
parentTile.level.remotes.splice(_local3, 1);
break;
}
_local3++;
}
super.destroy();
}
}
Symbol 779 MovieClip [__Packages.RemoteSplitFloor] Frame 0
class RemoteSplitFloor extends SplitFloor
{
var clip, isOpen, parentTile;
function RemoteSplitFloor (x, y, l, tile) {
super(x, y, l);
clip.removeMovieClip();
clip = l.clip.attachMovie("RemoteSplitFloor", "RemoteSplitFloor" + l.LAYER_SplitFloors, l.LAYER_SplitFloors++);
clip.cacheAsBitmap;
clip._x = x;
clip._y = y;
clip.gotoAndStop(l.themeNumber);
clip.eh.gotoAndStop(Number(isOpen) + 1);
parentTile = tile;
l.remotes.push(this);
}
function destroy() {
var _local3 = 0;
while (_local3 < parentTile.level.remotes.length) {
if (parentTile.level.remotes[_local3].clip == clip) {
parentTile.level.remotes.splice(_local3, 1);
break;
}
_local3++;
}
super.destroy();
}
}
Symbol 780 MovieClip [__Packages.Goal] Frame 0
class Goal
{
var level, clip, row, col;
function Goal (r, c, l) {
level = l;
clip = l.clip.attachMovie("Goal", "Goal" + l.LAYER_Goal, l.LAYER_Goal++);
clip.cacheAsBitmap;
row = r;
col = c;
clip._x = (col * l.tileSize) + (l.tileSize / 2);
clip._y = (row * l.tileSize) + (l.tileSize / 2);
clip.eh.gotoAndStop(l.themeNumber);
}
function moveTo(r, c) {
row = r;
col = c;
clip._x = (col * level.tileSize) + (level.tileSize / 2);
clip._y = (row * level.tileSize) + (level.tileSize / 2);
}
function destroy() {
clip.removeMovieClip();
clip = null;
row = (col = null);
}
}
Symbol 781 MovieClip [__Packages.FloorlessTile] Frame 0
class FloorlessTile extends Tile
{
var clip;
function FloorlessTile (r, c, l) {
super(r, c, l);
clip._alpha = 0;
}
}
Symbol 782 MovieClip [__Packages.Levels] Frame 0
class Levels
{
function Levels () {
}
static var L1 = "13259241%5yc1sa251%5yjrka260%byt9ca270%bwvtca320%byt9ca330%bwvtca360%60h7ka370%6jrnka380%bwvtea420%6lwtca430%5yjrka450%byt9wa460%6jzg4a480%60h7ka490%bwvtca530%6lxl4a540%bwo3ka550%5yjrka580%6lwtca590%6jzdca640%6lwtca650%6jzdca";
static var L2 = "16266250%byt9ca260%bwo3ma270%bwvtca330%byt9ca340%bwo3ma350%6jrnka360%6jrnka370%6jrqca380%bwo3ka390%bwvtca430%60h84a440%6jzdca480%60h7ka490%5yjs4a520%byt9ca530%5yjrka560%byt9ca570%bwo3ka580%6jt74a590%6jzdca620%6lwtca630%6jzdca660%6lwtca670%6jzdca";
static var L3 = "15335350%bz0z4a440%byt9ca450%5yctka460%bwvtca530%ck8v4a540%6jt74a550%6jsfca560%6jrqca570%cibf4a";
static var L4 = "15634340%bz0z4a350%byt9ca360%bwvtea440%60hd4a450%6jrnka460%5yjrua540%6lxl4a550%ci3uwa560%6jzdca";
static var L5 = "16439230%byt9ca240%bwvtca270%byt9ca280%bwvtca330%60h7la340%6jrqca350%bwo3ma360%ci3pca370%5yc7ca380%5yc4ka390%cibf4a420%byt9ca430%5yjrka450%60oxca470%60haca480%5yjx4a520%6lwtca530%6jrqca540%bwo3ka550%6jziwa570%6lwtca580%6jzdca640%6m4j4a";
static var L6 = "12754270%bz0z4a360%byt9ca370%5yjrla450%byt9ca460%6jsfca470%5yjrla540%ck8v4a550%6jsfca560%ci3pca570%6jzdca";
static var L7 = "14248370%byt9ca380%ci3pca390%bwvtca420%ckoaoa430%ci3pca440%bwo3ka450%c0yf6a460%ci3pca470%5yjrka480%ck8v4a490%5ylb4a540%6lwtca550%6jzdca570%iikwwa580%ci3pca590%6jzdca";
static var L8 = "16367250%byt9ca260%bwvtca330%bytewa340%ci3pca350%5yc1ua360%5yc1ua370%ci3pca380%d3r0wa430%60oxca450%60oxca460%60oxca480%60oxca530%60h7la540%ci3pca550%6k734a560%6jrnka570%bwo3la580%6jzdca630%6m4j4a670%6m4j4a";
static var L9 = "12457240%byt9ca250%cij4wa260%bwvtca340%77k4wa350%byt9ca360%6jrnka370%bwvtca440%6lwtca450%5yc4ka460%bwo3la470%igngwa550%6m4j4a560%6lwtca570%cibf4a";
static var L10 = "1414a220%byt9ca230%ci3pca240%bwvtca270%byt9ca280%ci3pca290%bwvtca320%60oxca330%byt9ca340%6jsfca350%ci3pca360%ci3pca370%6jrt4a380%bwvtca390%60oxca410%ckoaoa420%5yjrka430%60oxcd480%60oxce490%60h7ka4a0%cqw28a520%60oxca530%6lwtca540%bwo44a550%ci3pca560%ci3pca570%bwo3la580%6jzdca590%60oxca620%6lwtca630%ci3pca640%6jzdca670%6lwtca680%ci3pca690%6jzdca";
static var L11 = "16525250%ck8v4a260%bwy4oa360%60oxce450%byt9ca460%5ykjca550%60h7la560%6jrqca570%cibf4c650%6m4j4a";
static var L12 = "12252220%ck8v4a230%bwo3kb240%bwo3ka250%bwqeya260%ci3pca270%bwo3ka280%ci3pca290%bwvtca330%6lwtca340%6jrnka350%6jzdca370%60oxca390%60oxca430%byt9ca440%bwo3ka450%bwvtcc470%hxd0wa490%60oxcd520%clbg0a530%6jrnka540%6jrnka550%6jroea560%bx3j4a570%5yc1sa580%ci3pca590%6jzdca660%6lwtca670%6jzega";
static var L13 = "14376240%byt9ca250%bwvtca340%60hzca350%5yc1sc360%bwvtca430%ck8v4a440%6jrnka450%5yjrua460%6mroga470%bwvtca550%6mze8a560%bwvtca570%60h7ka580%bwvtca660%60h7la670%6jrnkc680%6jzdca760%6m4j4a";
static var L14 = "14535240%byt9ca250%bwo3la260%bwvtca340%60oxca350%6m4j4a360%60oxca430%byt9ca440%5yed7a450%ci3pca460%5yce0a470%bwvtca530%6lwtcb540%6jzdca560%6lwtca570%6jzdcc";
static var L15 = "14725250%ck8v4a260%bwywga340%byt9cc350%bwo3ua360%6jrt4a370%bwvtca440%60oxca450%60oxca470%60oxca540%6lwtca550%6jrnua560%ci3uwa570%6jzdca";
static var L16 = "13265230%byt9ca240%bwvtca280%bz8owa290%bwvtca320%ck8v4a330%6jrnkb340%5yc1sa350%c0yf4a360%ci3pcc370%bwo4ea380%6jrnka390%6jzdcb440%6lwtfa450%6jzdca470%60oxca560%byt9ca570%5yc7ca580%bwvtca650%ck8v4a660%6juqoa670%6jrnua680%6jzdcb";
static var L17 = "12262220%ck8v4a230%ci3pca240%bwvtca260%byt9ca270%ci3pcb280%bwvtca340%60hd4a350%ci3pca360%5yjrua380%60h7ka390%cibf4a430%ck8v4a440%5yjrka460%60h7ka470%ci3pcc480^123yfka540%60h7la550%ci3pca560%5ylb4a580%60h7ka590%cibf4a620%ck8v4a630%ci3pca640%6jzdca660%6lwtca670%ci3pcb680%6jzdca";
static var L18 = "15234250%bzgeoa260%bwvtca340%ck8v4a350%5yc22a360%6jro4a370%bwvtca430%byt9ca440%bwo3ma450%5yjx4a470%60haca480%bwvtca520%ck8v4a530%6jsfca540%6jrnma550%6jrqca560%ci3pca570%6k734a580%6jrnka590%cibf4a";
static var L19 = "12229220%ck8v4a230%bwvtca281%byt9c@14290%cibf4a330%60h7ka341%bwvtck371%byt9ck380%5yjrka430%6lwtca440%5yjs4a470%60h7ke481%6jzdck540%60h7ka550%bwo3ka561%bwo3kk570%5ykjca640%6lwtca651%6jrnkk660%6jrnka670%6jzdca";
static var L20 = "11527150%bz0z4a230%byt9ca240%bx3j4a250%5yjrka270%ck8v4a280%bwvtca331%60h7kk340%5yc1ta350%6jzdca380%60oxca430%60h7la440%5yjrka470%byt9ca480%5ykjwa530%6lwtca540%5yjs4a560%byt9ca570%5ycu4a581%6jzdck640%6lwtca650%ci3pca660%6jrnka670%6jzdca";
static var L21 = "13269240%byt9ca250%bwo3kd260%bwvtca320%ck8v4a330%ci3pca340%6jrnkb350%5yc1sa360%5yc1sb370%bwvtca450%60h7kd460%5yc1va470%6jzdca540%byt9ca550%5yed4a560%5yjrkd640%6lwtca650%5yc1sb660%5yc1sa670%bwo3kb680%ci40ga690%cibf4a750%6lwtca760%6jrnkd770%6jzdca";
static var L22 = "16369230%byt9cc240%ci3pca250%bwo4ea260%ci3s4a270%bwy4oa330%60oxca350%60oxca370%60oxca430%6lwtca440%bwo3ka450%6jrnke460%bwo6ca470%6jrnka480%bwvtca540%60oxca560%60oxca580%60oxca630%ck8v4a640%6jrnka650%ci3pca660%6jrnma670%ci3pca680%6jryoa690%cibf4a";
static var L23 = "13357240%byt9ca250%bwo3kd260%bwvtca330%byt9ca341%5yc1s@1e350%5yc2wa361%5yc1s@14370%bwvtca430%60h7kb440%5yc1sa451%5yc1s@14460%5yc1sa470%5yjrkc530%6lwtca541%5yc1s@14550%5yccwa561%5yc1s@1e570%6k1ooa640%6lwtca650%6jrnke660%6jzdca";
static var L24 = "17526250%byt9ca260%bwvtca340%bytc4a350%6jrvwa360%6jrvwa370%bwvtca440%60h7ka450%ci3pca460%ci3pcc470%5ykjca540%60hzca550%ci3pcc560%ci3pca570%5yjrka641%60hzc@14651%ci3pc@14661%ci3pc@14671%5ykjc@14740%6lwtca750%ci3pca760%ci3pca770%6jzdca";
static var L25 = "12545230%byt9ca240%ci3pca250%ci3pca260%ci3pca270%bwvtca330%60h7ma340%bwo3ka350%bwo44a360%bwvtca370%60oxca430%60oxca440%60oxca450%6m4j4a460%60oxca470%60oxca530%6lwtca540%6jrt4a550%ci3pca560%6jrt4a570%6jzdca";
static var L26 = "17175180%byt9ca190%bwvtca250%byt9ca260%bwo3ma270%ci3pca280%5yc1sa290%5yjrua320%byt9ca330%bwvtca340%byt9ca350%5ydlda360%6jzdca380%6lwtea390%5yjs4a420%60hd5a430%5yc4ka440%6jrnka450%6jzdca490%60h7ka4a0%bwvtca520%60h7ka530%5ykjca580%byt9ca590%6jsfca5a0%5yjs4a610%byt9wa620%5yc1sa630%5ykjca660%byt9ca670%bwo3ma680%6jsfca690%ci3pca6a0%6jzdca710%6lwtca720%6jrqca730%6jzdca750%ck8v4a760%6jsfda770%6jzdca";
static var L27 = "15547330%byt9cc340%bwo3na350%bwpn4a360%bwo3ka370%cibf4b430%6lwtca440%6jrvwa450%5yc1ta460%6jrvwa470%cibf4a550%6m4j4a";
static var L28 = "14643240%byt9ca250%ci3pca260%bwo3ua270%ci3pca280%d3r0wa340%60oxca360%60oxca380%60oxca430%ck8v4a440%5ylb4a460%60haca470%ci3pca480%5yjrka540%77k4wa560%60oxca580%60oxca640%6lwtca650%ci3pca660%6jrnka670%ci3pca680%igngwa";
static var L29 = "13239221%6jzdca230%byt9ca240%bwvtcd270%byt9wa280%bwvtca320%ck8v4a330%5yc22a340%5yjrka361%byt9c@1e370%5yjrka380%60haca390%cibf4a430%6lwtca440%5yc7ca450%ci3pca460%5yctka470%5yc7ca481%6jzdc@14540%6lwtea550%bwvtca560%60h7ma570%6jzdca650%6lwtca660%6jzdca";
static var L30 = "11268120%byt9ca130%bwvtca170%byt9ca180%bwvtca220%6lwtca230%5yc7ma240%bwo3ma250%ci3pca260%ci3pca270%5yc1sa280%5yc1ua290%bwvtca330%60h7la340%6jzdca370%6lwteb380%5yc1ta390%6jzdca430%60oxca481%77k4w@14520%byt9wa530%5yc1ta540%bwvtcd580%6lwtca590%bwvtca620%6lwtca630%5yc1sa640%5yc2ca651%ci3pc@14660%cij4wa670%bwvtca680%byt9ca690%5ylb4a730%6lwtca740%6jzdca770%6lwtca780%6jsfca790%6jzdca";
static var L31 = "12328220%byt9ca230%bwvtea280%byt9ca290%bwxcwa320%60h84a330%5yjs4a380%60hd4a390%5yjrka420%60h7ma430%6jrnka440%bwvtca470%byt9ca480%6jsfca490%5ylb4a510%byt9ca520%5yjrma540%60oxca560%byt9ca570%5ylb4a590%60h7la5a0%bwvtca610%6lxl4a620%6jrt4a630%ci3pca640%6jrqca650%ci3pca660%6jrnma670%6jrnka680%ci3pea690%6jrnka6a0%6jzdca";
static var L32 = "16539230%byt9cd240%ci3pca250%bwo3ka260%ci3pca270%bwo3ma280%ci3pca290%bwvtca330%60oxca350%60oxca370%60oxca390%60oxca410%byt9ca420%bwo3ma430%5yc4ka440%ci3pca450%757c4a460%ci3pca470%6scdga480%ci3pca490%6jzdca510%60ir4a521%5yc1s@14530%5ykjca550%60oxca610%6lwtca620%6k73ea630%6jrnka640%ci3pca650%6jzdca";
static var L33 = "13259230%byt9ca240%bwo3kd250%ciykga260%ci3pca270%bwo3kd280%bwvtca320%byt9ca330%5ydlca340%5ykjca370%60haca380%5yc4ka390%bwvtca421%60h7k@14431%5yc1s@1e441%5yjrk@14471%60h7k@1e481%5yc1s@14491%5yjrk@1e520%6lwtca530%5yc22a540%5yjrua570%60h7la580%5yc1ua590%6jzdca630%6lwtca640%6jrnke650%ci3pca660%csti8a670%6jrnke680%6jzdca";
static var L34 = "14447230%byt9ca240%ci3pca250%bwo3ua260%bwo6ca270%ci3qga280%bwvtca320%byt9cd330%5ykjca350%7ss0wa360%5yjrka380%60wnea390%bwvtca420%6lwtca430%5yjs4a440%byt9ca450%6jrnka460%6jzg4a470%bz0z4a480%60h7ma490%6jzdca530%6mjyoa540%5yjrka570%60haca580%6jzdca640%6lwtca650%ci3pca660%cme0wa670%6jzdca";
static var L35 = "14349230%byt9ca240%c0yhwa250%bwo6ca260%bwo3ka270%ci3pcb280%bwvtfa320%byt9ca330%5ydlca341%6k734@14350%5yc1sa361%5yjrkk380%60haca390%bwvtca420%60h7kc430%5ylb4a450%60hzca460%5yjrma480%60h7ma490%75ez4a520%6lwtca530%5yjrua551%60h7kk560%5yc1sa571%bwo3k@1e580%5yed4a590%6jzdca630%6lwtca640%ci3pca650%6o1z4a660%6jro4a670%6jrnla680%6jzdca";
static var L36 = "13259220%byt9ca231%ci3pc@14240%bwo3ua251%ci3pc@14260%bwo3la271%cij4w@14280%bwvtca320%6m4j4a340%60oxca360%60oxca380%60oxca430%byt9cb440%6jsfca450%bwo3ke460%6jrnkd470%bwo44a480%6jzdcc530%60oxca550%60oxca570%60oxca590%bz0z4a630%6lwtea641%ci3pc@1e650%6jrnka661%cme0w@1e670%6jrqca681%ci3pc@1e690%6jzdca";
}
Symbol 783 MovieClip [__Packages.StopWatch] Frame 0
class StopWatch
{
var timeStarted, timeStopped, active;
function StopWatch () {
timeStarted = getTimer();
timeStopped = 0;
active = false;
}
function destroy() {
timeStarted = (timeStopped = null);
active = null;
}
function start() {
timeStarted = getTimer();
timeStopped = 0;
active = true;
}
function stop() {
timeStopped = getTimer();
active = false;
}
function reset() {
timeStarted = getTimer();
timeStopped = 0;
}
function getTime() {
if (active) {
if ((getTimer() - timeStarted) > 999000) {
return(999000);
}
return(getTimer() - timeStarted);
}
if ((timeStopped - timeStarted) > 999000) {
return(999000);
}
return(timeStopped - timeStarted);
}
}
Symbol 784 MovieClip [__Packages.SlideAndShowTransition] Frame 0
class SlideAndShowTransition
{
var clip, themeNum, speed, fadingIn, fadingOut, transitioning;
function SlideAndShowTransition () {
clip = _root.attachMovie("BGMask", "BGMask0", 11100);
clip.cacheAsBitmap;
themeNum = _root.bgBorder._currentframe;
clip.eh.bgBorder.gotoAndStop(themeNum);
clip.eh.bgGrid.gotoAndStop(themeNum);
clip.eh.bgColor.gotoAndStop(themeNum);
speed = 1;
fadingIn = false;
fadingOut = false;
transitioning = false;
}
function destroy() {
clip.removeMovieClip();
clip = null;
speed = null;
fadingIn = null;
fadingOut = null;
transitioning = null;
}
function setUpForFadeIn() {
speed = 1;
clip.gotoAndStop(speed);
clip.eh.bgBorder.gotoAndStop(themeNum);
clip.eh.bgGrid.gotoAndStop(themeNum);
clip.eh.bgColor.gotoAndStop(themeNum);
fadingIn = true;
fadingOut = false;
transitioning = true;
}
function fadeIn() {
if (clip._currentframe < clip._totalframes) {
clip.gotoAndStop(speed);
clip.eh.bgBorder.gotoAndStop(themeNum);
clip.eh.bgGrid.gotoAndStop(themeNum);
clip.eh.bgColor.gotoAndStop(themeNum);
speed = speed + 1;
} else {
speed = clip._totalframes;
clip.gotoAndStop(speed);
fadingIn = false;
transitioning = false;
}
}
function setUpForFadeOut() {
speed = clip._totalframes;
clip.gotoAndStop(speed);
themeNum = _root.themeNum;
clip.eh.bgBorder.gotoAndStop(themeNum);
clip.eh.bgGrid.gotoAndStop(themeNum);
clip.eh.bgColor.gotoAndStop(themeNum);
fadingIn = false;
fadingOut = true;
transitioning = true;
}
function fadeOut() {
if (clip._currentframe > 1) {
clip.gotoAndStop(speed);
clip.eh.bgBorder.gotoAndStop(themeNum);
clip.eh.bgGrid.gotoAndStop(themeNum);
clip.eh.bgColor.gotoAndStop(themeNum);
speed = speed - 1;
} else {
speed = 1;
clip.gotoAndStop(speed);
clip.eh.bgBorder.gotoAndStop(themeNum);
clip.eh.bgGrid.gotoAndStop(themeNum);
clip.eh.bgColor.gotoAndStop(themeNum);
fadingOut = false;
}
}
}
Symbol 519 Button
on (press) {
getURL ("http://www.armorgames.com", "_blank");
}
Symbol 522 MovieClip Frame 1
_root.stop();
gotoAndPlay (2);
Symbol 522 MovieClip Frame 180
_root.nextFrame();
Symbol 527 MovieClip Frame 1
play();
Symbol 527 MovieClip Frame 7719
play();
Symbol 527 MovieClip Frame 14222
stop();
_root.whatShouldSoundDo();
Symbol 532 Button
on (press) {
_root.toggleSound();
}
Symbol 533 Button
on (press) {
_root.toggleSound();
}
Symbol 534 MovieClip Frame 1
stop();
Symbol 537 Button
on (press) {
_root.toggleTheme();
_root.SOUND_button.start();
}
Symbol 547 Button
on (press) {
_root.gotoLevelSelect();
_root.SOUND_button.start();
}
Symbol 550 Button
on (press) {
_root.gotoCredits();
_root.SOUND_button.start();
}
Symbol 553 Button
on (press) {
_root.gotoIPhone();
_root.SOUND_button.start();
}
Symbol 556 Button
on (press) {
getURL ("http://armorblog.com", "_blank");
_root.SOUND_button.start();
}
Symbol 559 Button
on (press) {
getURL ("http://armorgames.com", "_blank");
_root.SOUND_button.start();
}
Symbol 560 Button
on (press) {
getURL ("http://armorgames.com", "_blank");
_root.SOUND_button.start();
}
Symbol 563 Button
on (press) {
getURL ("http://oddfellowfloyd.newgrounds.com/", "_blank");
_root.SOUND_button.start();
}
Symbol 564 Button
on (press) {
getURL ("http://reasoner.newgrounds.com/", "_blank");
_root.SOUND_button.start();
}
Symbol 565 Button
on (press) {
getURL ("http://armorgames.com/user/soapaintnice", "_blank");
_root.SOUND_button.start();
}
Symbol 566 Button
on (press) {
getURL ("http://armorgames.com/user/DanielMcNeely", "_blank");
_root.SOUND_button.start();
}
Symbol 567 Button
on (press) {
getURL ("http://armorgames.com/", "_blank");
_root.SOUND_button.start();
}
Symbol 570 Button
on (press) {
_root.gotoMenu();
_root.SOUND_button.start();
}
Symbol 572 Button
on (press) {
getURL ("http://armorblog.com", "_blank");
_root.SOUND_button.start();
}
Symbol 654 MovieClip Frame 1
stop();
Symbol 654 MovieClip Frame 2
play();
Symbol 655 MovieClip Frame 1
stop();
Symbol 655 MovieClip Frame 2
play();
Symbol 656 MovieClip Frame 1
stop();
Symbol 656 MovieClip Frame 2
play();
Symbol 740 Button
on (press) {
_root.onButtonPress();
}
on (rollOver) {
_root.onButtonRollOver();
}
Symbol 744 MovieClip Frame 1
stop();
Symbol 744 MovieClip Frame 2
stop();
bgColor.gotoAndStop(_root.bgColor._currentframe);
bgGrid.gotoAndStop(_root.bgGrid._currentframe);
Symbol 744 MovieClip Frame 3
stop();
bgColor.gotoAndStop(_root.bgColor._currentframe);
bgGrid.gotoAndStop(_root.bgGrid._currentframe);
Symbol 744 MovieClip Frame 4
stop();
bgColor.gotoAndStop(_root.bgColor._currentframe);
bgGrid.gotoAndStop(_root.bgGrid._currentframe);
Symbol 747 Button
on (press) {
getURL ("http://armorgames.com/guide/Open-Doors-2", "_blank");
_root.SOUND_button.start();
}
Symbol 762 Button
on (press) {
_root.restart();
_root.SOUND_button.start();
}
Symbol 765 Button
on (press) {
_root.game.undo();
_root.SOUND_button.start();
}