Section 1
//button_retry_continue_8 (isora2_fla.button_retry_continue_8)
package isora2_fla {
import flash.display.*;
import flash.text.*;
public dynamic class button_retry_continue_8 extends MovieClip {
public var txtbox:TextField;
}
}//package isora2_fla
Section 2
//Hud_36 (isora2_fla.Hud_36)
package isora2_fla {
import flash.display.*;
import flash.text.*;
public dynamic class Hud_36 extends MovieClip {
public var txt_level:TextField;
public var thetime_txtbox:TextField;
public var score_txtbox:TextField;
}
}//package isora2_fla
Section 3
//level_tile_28 (isora2_fla.level_tile_28)
package isora2_fla {
import flash.display.*;
import flash.text.*;
public dynamic class level_tile_28 extends MovieClip {
public var txtbox:TextField;
}
}//package isora2_fla
Section 4
//MainTimeline (isora2_fla.MainTimeline)
package isora2_fla {
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.text.*;
import flash.utils.*;
import flash.net.*;
import flash.filters.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.geom.*;
import flash.printing.*;
import flash.system.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class MainTimeline extends MovieClip {
public var lt40:MovieClip;
public var lt41:MovieClip;
public var btn_highscores:SimpleButton;
public var lt43:MovieClip;
public var lt45:MovieClip;
public var lt46:MovieClip;
public var lt47:MovieClip;
public var lt49:MovieClip;
public var lt44:MovieClip;
public var lt48:MovieClip;
public var lt42:MovieClip;
public var lt50:MovieClip;
public var lt51:MovieClip;
public var lt52:MovieClip;
public var lt53:MovieClip;
public var lt54:MovieClip;
public var lt55:MovieClip;
public var lt56:MovieClip;
public var lt58:MovieClip;
public var lt59:MovieClip;
public var dynamicmenu:DynamicMenu;
public var lt57:MovieClip;
public var high_score_display:TextField;
public var lt60:MovieClip;
public var tileWidth:Number;
public var Beep:Sound;
public var UrbanSong:Sound;
public var Ready:Boolean;
public var CrimsonSong:Sound;
public var levelUnlocked:Number;
public var btn_music:SimpleButton;
public var Score:Number;
public var progressBar:MovieClip;
public var btn_instructions:SimpleButton;
public var controls:Boolean;
public var theTime:Number;
public var KeyLeft:Number;
public var btn_back:SimpleButton;
public var legitlogo:SimpleButton;
public var hud:MovieClip;
public var bitmapMC;
public var TitleArray:Array;
public var SongSelected:String;
public var TextArray:Array;
public var charPos:Array;
public var name_input:TextField;
public var KeyRight:Number;
public var btn_playmoregames:SimpleButton;
public var btn_controls:MovieClip;
public var KeyUp:Number;
public var Map:Array;
public var btn_play:SimpleButton;
public var timer:Timer;
public var btn_submit:SimpleButton;
public var saved_info:SharedObject;
public var TutorialArray:Array;
public var tileHeight:Number;
public var FirstTime:Boolean;
public var KeyDown:Number;
public var tutorial:MovieClip;
public var FutureSong:Sound;
public var lt10:MovieClip;
public var lt11:MovieClip;
public var lt12:MovieClip;
public var lt2:MovieClip;
public var lt4:MovieClip;
public var lt5:MovieClip;
public var lt7:MovieClip;
public var lt8:MovieClip;
public var lt13:MovieClip;
public var lt3:MovieClip;
public var lt15:MovieClip;
public var lt16:MovieClip;
public var lt6:MovieClip;
public var lt19:MovieClip;
public var logo:MovieClip;
public var btn_music_1:SimpleButton;
public var btn_music_2:SimpleButton;
public var lt17:MovieClip;
public var lt18:MovieClip;
public var lt9:MovieClip;
public var lt1:MovieClip;
public var MusicEnabled:Boolean;
public var lt14:MovieClip;
public var btn_music_3:SimpleButton;
public var lt22:MovieClip;
public var lt23:MovieClip;
public var lt20:MovieClip;
public var lt21:MovieClip;
public var lt29:MovieClip;
public var lt24:MovieClip;
public var lt26:MovieClip;
public var btn_credits:SimpleButton;
public var lt25:MovieClip;
public var lt28:MovieClip;
public var logo_timer:Timer;
public var lt30:MovieClip;
public var lt31:MovieClip;
public var lt32:MovieClip;
public var lt33:MovieClip;
public var lt34:MovieClip;
public var lt36:MovieClip;
public var lt38:MovieClip;
public var lt27:MovieClip;
public var lt35:MovieClip;
public var mapNumber:Number;
public var lt37:MovieClip;
public var HighScore:Number;
public var Victory:Boolean;
public var lt39:MovieClip;
public var StorePurple:Number;
public function MainTimeline(){
addFrameScript(0, frame1, 1, frame2, 2, frame3, 3, frame4, 4, frame5, 5, frame6, 6, frame7, 7, frame8, 8, frame9);
}
public function BitmapTransition():void{
var fade:Number;
var bitmapdata:BitmapData;
var bitmap:*;
var bitmapMC:*;
var ef:Function;
ef = function (_arg1:Event):void{
var _local2:*;
_local2 = new BlurFilter(fade, fade, 1);
bitmapMC.filters = [_local2];
fade++;
bitmapMC.alpha = (bitmapMC.alpha - 0.07);
if (bitmapMC.alpha <= 0){
stage.removeChild(bitmapMC);
bitmapMC.removeEventListener(Event.ENTER_FRAME, ef);
};
};
fade = 0;
bitmapdata = new BitmapData(550, 400, false);
bitmapdata.draw(stage, new Matrix());
bitmap = new Bitmap(bitmapdata);
bitmapMC = new MovieClip();
bitmapMC.addChild(bitmap);
stage.addChild(bitmapMC);
bitmapMC.addEventListener(Event.ENTER_FRAME, ef);
}
public function btn_moregames_click(_arg1:MouseEvent):void{
var _local2:URLRequest;
_local2 = new URLRequest("http://www.legitgames.com/");
navigateToURL(_local2);
}
public function menu_sound(_arg1:MouseEvent):void{
Beep.play();
}
public function btn_highscores_click(_arg1:MouseEvent):void{
stage.removeChild(dynamicmenu);
stage.removeChildAt(1);
stage.removeChild(bitmapMC);
BitmapTransition();
gotoAndStop("HIGHSCORES");
}
public function render(){
var _local1:MovieClip;
var _local2:MovieClip;
var _local3:Number;
var _local4:Number;
var _local5:*;
var _local6:*;
var _local7:MovieClip;
_local1 = new MovieClip();
_local2 = new charMC();
if (Ready){
stage.removeChildAt(1);
};
Ready = true;
stage.addChildAt(_local1, 1);
_local3 = Map[0].length;
_local4 = Map.length;
_local5 = 0;
while (_local5 < _local4) {
_local6 = 0;
while (_local6 < _local3) {
if ((((_local5 == charPos[1])) && ((_local6 == charPos[0])))){
_local2.y = ((tileWidth / 2) * (_local6 - _local5));
_local2.x = ((tileHeight / 2) * (_local6 + _local5));
_local1.addChildAt(_local2, _local6);
} else {
_local7 = new tile();
_local7.x = ((tileHeight / 2) * (_local6 + _local5));
_local7.y = ((tileWidth / 2) * (_local6 - _local5));
_local1.addChildAt(_local7, _local6);
_local1.x = 100;
_local7.gotoAndStop((Map[_local5][_local6] + 1));
};
_local6++;
};
_local5++;
};
position(_local1);
}
public function mapChange(){
var _local1:Boolean;
var _local2:*;
var _local3:Number;
var _local4:BitmapData;
var _local5:*;
var _local6:*;
switch (mapNumber){
case 1:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 0, 1, 1, 1, 0, 4, 4], [4, 4, 4, 0, 1, 0, 1, 0, 4, 4], [4, 4, 4, 0, 5, 1, 1, 0, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [4, 6];
break;
case 2:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 4, 4, 4], [4, 4, 4, 0, 1, 1, 0, 4, 4, 4], [4, 4, 4, 0, 1, 1, 0, 0, 4, 4], [4, 4, 4, 0, 1, 1, 1, 0, 4, 4], [4, 4, 4, 0, 1, 1, 5, 0, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [6, 6];
break;
case 3:
Map = [[0, 0, 0, 0, 0, 0, 4, 4], [0, 1, 1, 1, 1, 0, 0, 4], [0, 1, 1, 1, 1, 1, 0, 4], [0, 1, 0, 0, 0, 1, 0, 4], [0, 1, 0, 4, 0, 1, 0, 0], [0, 1, 0, 0, 0, 1, 1, 0], [0, 1, 1, 1, 1, 1, 5, 0], [0, 0, 0, 0, 0, 0, 0, 0]];
charPos = [6, 6];
break;
case 4:
Map = [[4, 0, 0, 0, 0, 0, 0, 0, 0], [4, 0, 1, 1, 1, 1, 1, 1, 0], [4, 0, 1, 1, 1, 5, 1, 1, 0], [0, 0, 0, 1, 1, 1, 1, 0, 0], [0, 1, 1, 1, 1, 1, 1, 0, 4], [0, 1, 1, 1, 1, 1, 1, 0, 4], [0, 0, 0, 0, 0, 1, 1, 0, 4], [4, 4, 4, 4, 0, 0, 0, 0, 4]];
charPos = [5, 2];
break;
case 5:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 0, 0, 0, 0, 4], [4, 4, 4, 4, 0, 0, 1, 1, 0, 4], [4, 4, 4, 0, 0, 0, 1, 1, 0, 4], [4, 4, 4, 0, 1, 1, 1, 1, 0, 4], [4, 4, 4, 0, 1, 1, 1, 1, 0, 4], [4, 4, 4, 0, 1, 1, 1, 5, 0, 4], [4, 4, 4, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [7, 7];
break;
case 6:
Map = [[0, 0, 0, 0, 0, 0, 0, 0], [0, 1, 1, 0, 0, 1, 1, 0], [0, 1, 1, 0, 1, 1, 1, 0], [0, 5, 1, 1, 1, 1, 1, 0], [0, 1, 1, 1, 1, 1, 0, 0], [0, 0, 0, 0, 0, 0, 0, 4]];
charPos = [1, 3];
break;
case 7:
Map = [[4, 4, 0, 0, 0, 0, 4, 4, 4, 4], [0, 0, 0, 1, 1, 0, 0, 0, 0, 0], [0, 1, 1, 1, 1, 1, 1, 1, 1, 0], [0, 1, 1, 5, 1, 1, 1, 1, 1, 0], [0, 0, 1, 1, 1, 1, 0, 1, 1, 0], [0, 0, 1, 1, 1, 1, 0, 1, 1, 0], [4, 0, 0, 0, 0, 0, 0, 0, 0, 0]];
charPos = [3, 3];
break;
case 8:
Map = [[0, 0, 0, 0, 0, 0, 0, 0, 4, 4], [0, 1, 1, 1, 1, 1, 1, 0, 0, 0], [0, 1, 1, 1, 1, 1, 1, 1, 1, 0], [0, 1, 1, 1, 5, 1, 1, 1, 1, 0], [0, 0, 0, 1, 1, 1, 1, 0, 0, 0], [4, 4, 0, 0, 1, 1, 0, 0, 4, 4], [4, 4, 4, 0, 1, 1, 0, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 4, 4, 4]];
charPos = [4, 3];
break;
case 9:
Map = [[0, 0, 0, 0, 0, 0, 0, 4, 4, 4], [0, 1, 2, 2, 1, 1, 0, 4, 4, 4], [0, 1, 1, 1, 1, 1, 0, 0, 4, 4], [0, 1, 1, 1, 1, 1, 1, 0, 0, 0], [0, 1, 1, 1, 1, 1, 1, 1, 1, 0], [0, 0, 0, 1, 1, 1, 1, 1, 1, 0], [4, 4, 0, 5, 1, 0, 0, 0, 0, 0], [4, 4, 0, 0, 0, 0, 4, 4, 4, 4]];
charPos = [3, 6];
break;
case 10:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 0, 1, 1, 1, 1, 0, 4], [4, 4, 4, 0, 1, 1, 5, 2, 0, 4], [4, 4, 4, 0, 1, 1, 1, 2, 0, 4], [4, 4, 4, 0, 1, 1, 1, 1, 0, 4], [4, 4, 4, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [6, 4];
break;
case 11:
Map = [[0, 0, 0, 0, 0], [0, 2, 2, 1, 0], [0, 2, 5, 1, 0], [0, 1, 1, 1, 0], [0, 0, 0, 0, 0]];
charPos = [2, 2];
break;
case 12:
Map = [[4, 4, 4, 4, 4, 4, 4, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0], [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0], [0, 1, 5, 1, 1, 1, 2, 2, 1, 1, 0], [0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0], [4, 4, 0, 1, 1, 1, 1, 0, 4, 4, 4], [4, 4, 0, 1, 2, 1, 0, 0, 4, 4, 4], [4, 4, 0, 1, 1, 0, 0, 4, 4, 4, 4], [4, 4, 0, 0, 0, 0, 4, 4, 4, 4, 4]];
charPos = [2, 3];
break;
case 13:
Map = [[4, 4, 0, 0, 0, 0, 4, 4, 4, 4], [0, 0, 0, 1, 1, 0, 4, 4, 4, 4], [0, 1, 1, 2, 2, 0, 4, 4, 4, 4], [0, 1, 1, 2, 2, 0, 0, 4, 4, 4], [0, 1, 1, 1, 5, 1, 0, 0, 0, 0], [0, 1, 2, 2, 1, 1, 2, 2, 1, 0], [0, 0, 0, 0, 1, 1, 2, 2, 1, 0], [4, 4, 4, 0, 0, 0, 0, 0, 0, 0]];
charPos = [4, 4];
break;
case 14:
Map = [[0, 0, 0, 0, 4, 4, 4, 4, 4], [0, 1, 1, 0, 0, 4, 4, 4, 4], [0, 1, 2, 1, 0, 0, 0, 0, 0], [0, 1, 1, 0, 0, 0, 1, 1, 0], [0, 1, 2, 1, 0, 0, 1, 1, 0], [0, 1, 1, 2, 2, 1, 1, 1, 0], [0, 1, 1, 2, 2, 1, 5, 1, 0], [0, 1, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 4, 4, 4, 4, 4]];
charPos = [6, 6];
break;
case 15:
Map = [[0, 0, 0, 4, 4, 4, 4, 4, 4], [0, 5, 0, 4, 4, 4, 4, 4, 4], [0, 2, 0, 0, 0, 0, 0, 0, 0], [0, 3, 2, 1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 1, 1, 0, 1, 0], [0, 1, 1, 1, 1, 1, 1, 1, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0]];
charPos = [1, 1];
break;
case 16:
Map = [[4, 4, 0, 0, 0, 4, 4, 4], [0, 0, 0, 1, 0, 0, 0, 4], [0, 1, 5, 2, 0, 1, 0, 0], [0, 1, 1, 1, 1, 3, 1, 0], [0, 0, 1, 1, 1, 1, 0, 0], [4, 0, 0, 0, 0, 0, 0, 4]];
charPos = [2, 2];
break;
case 17:
Map = [[0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 1, 1, 2, 1, 1, 1, 1, 0], [0, 1, 1, 3, 1, 1, 1, 5, 0], [0, 1, 1, 1, 1, 1, 1, 1, 0], [0, 0, 1, 1, 1, 1, 1, 1, 0], [4, 0, 1, 1, 0, 0, 1, 1, 0], [4, 0, 0, 0, 0, 0, 0, 0, 0]];
charPos = [7, 2];
break;
case 18:
Map = [[4, 4, 4, 0, 0, 0, 4, 4, 4], [0, 0, 0, 0, 1, 0, 0, 4, 4], [0, 1, 1, 1, 3, 1, 0, 0, 0], [0, 1, 1, 1, 1, 1, 1, 1, 0], [0, 0, 0, 1, 1, 1, 1, 1, 0], [4, 4, 0, 1, 1, 0, 1, 1, 0], [4, 4, 0, 5, 1, 2, 1, 1, 0], [4, 4, 0, 1, 1, 3, 1, 1, 0], [4, 4, 0, 1, 1, 1, 0, 0, 0], [4, 4, 0, 0, 0, 0, 0, 4, 4]];
charPos = [3, 6];
break;
case 19:
Map = [[4, 4, 4, 4, 4, 0, 0, 0, 0], [4, 4, 4, 4, 0, 0, 1, 1, 0], [0, 0, 0, 0, 0, 1, 1, 1, 0], [0, 1, 1, 1, 1, 2, 2, 1, 0], [0, 5, 1, 1, 1, 2, 3, 1, 0], [0, 1, 1, 1, 1, 0, 0, 0, 0], [0, 1, 1, 1, 3, 1, 0, 0, 4], [0, 1, 1, 0, 1, 0, 0, 4, 4], [0, 0, 0, 0, 0, 0, 4, 4, 4]];
charPos = [1, 4];
break;
case 20:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 0, 1, 6, 5, 0, 4], [4, 4, 4, 4, 0, 0, 1, 1, 0, 4], [4, 4, 4, 4, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [7, 4];
StorePurple = 1;
break;
case 21:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 0, 0, 0, 4, 4, 4, 4], [4, 4, 4, 0, 1, 0, 0, 0, 4, 4], [4, 4, 4, 0, 1, 1, 1, 0, 4, 4], [4, 4, 4, 0, 1, 0, 1, 0, 4, 4], [4, 4, 4, 0, 6, 1, 1, 0, 4, 4], [4, 4, 4, 0, 5, 0, 0, 0, 4, 4], [4, 4, 4, 0, 0, 0, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [4, 6];
StorePurple = 2;
break;
case 22:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 0, 0, 0, 0, 0, 4, 4, 4], [4, 4, 0, 5, 1, 1, 0, 4, 4, 4], [4, 4, 0, 1, 0, 1, 0, 4, 4, 4], [4, 4, 0, 1, 1, 6, 0, 4, 4, 4], [4, 4, 0, 1, 1, 1, 0, 4, 4, 4], [4, 4, 0, 1, 1, 1, 0, 4, 4, 4], [4, 4, 0, 1, 1, 1, 0, 4, 4, 4], [4, 4, 0, 0, 0, 0, 0, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [3, 2];
StorePurple = 1;
break;
case 23:
Map = [[4, 4, 4, 4, 4, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 1, 1, 0], [0, 1, 1, 2, 1, 1, 1, 1, 0], [0, 1, 1, 3, 1, 1, 1, 1, 0], [0, 1, 1, 5, 1, 1, 0, 0, 0], [0, 0, 0, 0, 1, 1, 0, 0, 4], [4, 0, 1, 1, 1, 2, 1, 0, 4], [4, 0, 1, 1, 1, 1, 0, 0, 4], [4, 0, 0, 0, 0, 0, 0, 4, 4]];
charPos = [3, 4];
break;
case 24:
Map = [[4, 4, 4, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 0, 1, 1, 0, 1, 0, 0], [4, 4, 4, 0, 1, 1, 1, 3, 1, 0], [4, 4, 4, 0, 1, 1, 1, 1, 0, 0], [0, 0, 0, 0, 1, 1, 1, 1, 0, 4], [0, 5, 1, 2, 1, 1, 1, 1, 0, 4], [0, 1, 1, 3, 1, 1, 1, 1, 0, 4], [0, 1, 1, 1, 0, 0, 0, 0, 0, 4], [0, 0, 0, 0, 0, 4, 4, 4, 4, 4]];
charPos = [1, 5];
break;
case 25:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 0, 0, 0, 0, 0, 0, 0, 0, 4], [4, 0, 1, 1, 1, 1, 1, 1, 0, 4], [4, 0, 1, 1, 1, 1, 1, 6, 0, 4], [4, 0, 0, 0, 0, 1, 0, 1, 0, 4], [4, 4, 4, 4, 0, 1, 2, 1, 0, 4], [4, 4, 4, 4, 0, 0, 5, 0, 0, 4], [4, 4, 4, 4, 4, 0, 0, 0, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [6, 6];
StorePurple = 1;
break;
case 26:
Map = [[4, 4, 4, 0, 0, 0, 0, 4, 4], [4, 4, 0, 0, 1, 1, 0, 0, 0], [0, 0, 0, 1, 1, 1, 1, 1, 0], [0, 1, 1, 2, 2, 5, 1, 1, 0], [0, 1, 1, 2, 3, 1, 0, 0, 0], [0, 1, 1, 1, 1, 0, 0, 4, 4], [0, 1, 1, 1, 1, 0, 4, 4, 4], [0, 1, 3, 1, 0, 0, 4, 4, 4], [0, 0, 1, 0, 0, 4, 4, 4, 4], [4, 0, 0, 0, 4, 4, 4, 4, 4]];
charPos = [5, 3];
break;
case 27:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 0, 0, 0, 0, 0, 4, 4, 4], [4, 4, 0, 7, 1, 1, 0, 4, 4, 4], [4, 4, 0, 0, 7, 1, 0, 4, 4, 4], [4, 4, 0, 0, 5, 1, 0, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [4, 5];
break;
case 28:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 0, 1, 1, 1, 0, 4, 4], [4, 4, 4, 0, 1, 5, 7, 0, 4, 4], [4, 4, 4, 0, 0, 1, 0, 0, 4, 4], [4, 4, 4, 0, 1, 1, 7, 0, 4, 4], [4, 4, 4, 0, 1, 1, 1, 0, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [5, 4];
break;
case 29:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 0, 0, 0, 0, 0], [4, 4, 4, 4, 4, 0, 7, 2, 1, 0], [4, 4, 4, 4, 4, 0, 2, 5, 2, 0], [4, 4, 4, 4, 4, 0, 1, 2, 7, 0], [4, 4, 4, 4, 4, 0, 0, 0, 0, 0], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [7, 6];
break;
case 30:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 0, 0, 0, 0, 0, 0, 4, 4], [4, 4, 0, 1, 1, 1, 7, 0, 4, 4], [4, 4, 0, 1, 1, 1, 0, 0, 4, 4], [4, 4, 0, 5, 2, 2, 7, 0, 4, 4], [4, 4, 0, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [3, 6];
break;
case 31:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 0, 0, 0, 4, 4, 4, 4, 4], [0, 0, 0, 7, 0, 0, 4, 4, 4, 4], [0, 5, 1, 6, 1, 0, 4, 4, 4, 4], [0, 1, 0, 1, 0, 0, 4, 4, 4, 4], [0, 7, 0, 0, 0, 4, 4, 4, 4, 4], [0, 0, 0, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [1, 3];
StorePurple = 2;
break;
case 32:
Map = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 1, 2, 2, 1, 2, 2, 1, 5, 0], [0, 1, 0, 0, 0, 0, 0, 1, 1, 0], [0, 2, 1, 0, 0, 0, 1, 1, 0, 0], [0, 1, 0, 0, 0, 1, 2, 2, 0, 0], [0, 1, 0, 0, 0, 0, 1, 3, 1, 0], [0, 1, 2, 1, 0, 0, 0, 0, 1, 0], [0, 2, 3, 2, 0, 2, 2, 1, 1, 0], [0, 2, 1, 1, 1, 1, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 4, 4, 4]];
charPos = [8, 1];
break;
case 33:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 0, 0, 0, 0, 0, 0, 0, 4], [4, 4, 0, 1, 1, 1, 1, 1, 0, 4], [4, 4, 0, 1, 7, 1, 7, 1, 0, 4], [4, 4, 0, 1, 1, 0, 1, 1, 0, 4], [4, 4, 0, 1, 1, 1, 1, 1, 0, 4], [4, 4, 0, 1, 1, 5, 1, 1, 0, 4], [4, 4, 0, 0, 0, 0, 0, 0, 0, 4]];
charPos = [5, 8];
break;
case 34:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [0, 0, 0, 0, 0, 0, 0, 0, 0, 4], [0, 5, 1, 1, 2, 1, 1, 1, 0, 4], [0, 1, 1, 0, 7, 0, 1, 1, 0, 4], [0, 1, 1, 0, 7, 0, 1, 1, 0, 4], [0, 1, 1, 1, 2, 1, 1, 1, 0, 4], [0, 0, 0, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [1, 2];
break;
case 35:
Map = [[4, 0, 0, 0, 0, 0, 0, 0, 0, 4], [4, 0, 1, 1, 1, 1, 1, 1, 0, 0], [4, 0, 1, 0, 0, 0, 0, 1, 1, 0], [0, 0, 1, 0, 7, 1, 0, 0, 1, 0], [0, 5, 3, 2, 6, 2, 1, 0, 1, 0], [0, 0, 1, 0, 7, 1, 0, 0, 1, 0], [4, 0, 1, 0, 0, 0, 0, 1, 1, 0], [4, 0, 1, 1, 1, 1, 1, 1, 0, 0], [4, 0, 0, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [1, 4];
StorePurple = 2;
break;
case 36:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 0, 0, 0, 0, 0, 0, 4, 4], [4, 0, 0, 1, 1, 1, 1, 0, 0, 4], [4, 0, 1, 1, 1, 6, 2, 1, 0, 4], [4, 0, 1, 1, 1, 7, 1, 1, 0, 4], [4, 0, 0, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 4, 4, 4], [4, 4, 4, 0, 5, 7, 0, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 4, 4, 4]];
charPos = [4, 8];
StorePurple = 1;
break;
case 37:
Map = [[0, 0, 0, 0, 0, 0, 0, 4, 4], [0, 1, 1, 1, 1, 1, 0, 4, 4], [0, 1, 0, 0, 0, 1, 0, 0, 0], [0, 1, 0, 1, 1, 1, 1, 1, 0], [0, 1, 0, 1, 2, 3, 2, 1, 0], [0, 1, 0, 1, 2, 5, 2, 1, 0], [0, 1, 1, 1, 2, 2, 2, 1, 0], [0, 0, 0, 1, 1, 1, 1, 1, 0], [4, 4, 0, 0, 0, 0, 0, 0, 0]];
charPos = [5, 5];
break;
case 38:
Map = [[0, 0, 0, 0, 0, 0, 0, 4, 4, 4], [0, 1, 1, 1, 1, 1, 0, 0, 4, 4], [0, 1, 1, 1, 7, 1, 1, 0, 4, 4], [0, 0, 1, 1, 0, 1, 1, 0, 0, 4], [4, 0, 1, 1, 1, 1, 1, 5, 0, 4], [4, 0, 0, 1, 1, 0, 1, 1, 0, 4], [4, 4, 0, 1, 1, 0, 1, 1, 0, 4], [4, 4, 0, 0, 1, 1, 7, 1, 0, 4], [4, 4, 4, 0, 0, 1, 1, 1, 0, 4], [4, 4, 4, 4, 0, 0, 0, 0, 0, 4]];
charPos = [7, 4];
break;
case 39:
Map = [[4, 4, 0, 0, 0, 0, 0, 0, 4, 4], [4, 4, 0, 1, 1, 1, 1, 0, 4, 4], [4, 4, 0, 1, 1, 1, 1, 0, 4, 4], [4, 4, 0, 0, 6, 1, 0, 0, 4, 4], [4, 4, 0, 1, 1, 5, 1, 0, 4, 4], [4, 4, 0, 1, 1, 0, 1, 0, 4, 4], [4, 4, 0, 1, 1, 1, 1, 0, 4, 4], [4, 4, 0, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [5, 4];
StorePurple = 1;
break;
case 40:
Map = [[4, 4, 4, 0, 0, 0, 0, 4, 4, 4], [4, 0, 0, 0, 2, 2, 0, 0, 0, 4], [4, 0, 5, 1, 1, 1, 1, 1, 0, 4], [0, 0, 1, 1, 1, 1, 0, 1, 0, 0], [0, 2, 1, 1, 0, 3, 3, 1, 2, 0], [0, 2, 1, 1, 3, 0, 1, 1, 2, 0], [0, 0, 1, 0, 3, 1, 2, 1, 0, 0], [4, 0, 1, 1, 1, 1, 1, 0, 0, 4], [4, 0, 0, 0, 2, 2, 0, 0, 0, 4], [4, 4, 4, 0, 0, 0, 0, 4, 4, 4]];
charPos = [2, 2];
break;
case 41:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 0, 0, 0, 0, 4], [4, 4, 4, 4, 0, 0, 1, 1, 0, 0], [4, 4, 4, 4, 0, 7, 6, 1, 1, 0], [4, 4, 4, 4, 0, 0, 1, 0, 1, 0], [4, 4, 4, 4, 4, 0, 1, 1, 1, 0], [4, 4, 4, 4, 4, 0, 1, 0, 0, 0], [4, 4, 4, 4, 4, 0, 5, 7, 0, 4], [4, 4, 4, 4, 4, 0, 0, 0, 0, 4]];
charPos = [6, 8];
StorePurple = 1;
break;
case 42:
Map = [[0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 2, 2, 2, 2, 2, 2, 2, 0], [0, 2, 2, 2, 2, 2, 2, 2, 0], [0, 2, 2, 2, 2, 2, 2, 2, 0], [0, 2, 2, 2, 5, 2, 2, 2, 0], [0, 2, 2, 2, 2, 2, 2, 2, 0], [0, 2, 2, 2, 2, 2, 2, 2, 0], [0, 1, 2, 2, 2, 2, 2, 2, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0]];
charPos = [4, 4];
break;
case 43:
Map = [[4, 4, 4, 0, 0, 0, 0, 4, 4, 4], [4, 4, 4, 0, 1, 1, 0, 0, 0, 4], [4, 4, 4, 0, 1, 5, 1, 1, 0, 4], [4, 4, 4, 0, 1, 1, 1, 1, 0, 4], [4, 4, 4, 0, 1, 6, 1, 0, 0, 4], [4, 4, 4, 0, 1, 1, 0, 0, 4, 4], [4, 4, 4, 0, 1, 1, 0, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [5, 2];
StorePurple = 1;
break;
case 44:
Map = [[4, 4, 0, 0, 0, 0, 0, 0, 4, 4], [4, 4, 0, 1, 1, 1, 1, 0, 4, 4], [4, 4, 0, 1, 1, 1, 1, 0, 4, 4], [4, 4, 0, 7, 1, 1, 7, 0, 4, 4], [4, 4, 0, 1, 1, 2, 5, 0, 4, 4], [4, 4, 0, 1, 1, 2, 2, 0, 4, 4], [4, 4, 0, 1, 1, 6, 1, 0, 4, 4], [4, 4, 0, 0, 0, 1, 1, 0, 4, 4], [4, 4, 4, 4, 0, 0, 0, 0, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [6, 4];
StorePurple = 1;
break;
case 45:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 0, 0, 0, 0, 0, 0, 0, 0, 0], [4, 0, 1, 1, 1, 1, 1, 1, 7, 0], [4, 0, 6, 1, 1, 1, 1, 1, 5, 0], [4, 0, 1, 1, 1, 1, 1, 1, 7, 0], [4, 0, 0, 0, 0, 0, 0, 0, 0, 0], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [8, 5];
StorePurple = 1;
break;
case 46:
Map = [[4, 0, 0, 0, 0, 0, 0, 0, 0, 0], [4, 0, 7, 1, 1, 1, 1, 1, 5, 0], [4, 0, 1, 1, 0, 1, 1, 1, 2, 0], [4, 0, 0, 0, 0, 0, 0, 1, 1, 0], [4, 4, 4, 4, 4, 4, 0, 1, 1, 0], [4, 4, 4, 4, 4, 4, 0, 0, 1, 0], [4, 4, 4, 4, 4, 4, 0, 1, 1, 0], [4, 4, 4, 4, 4, 4, 0, 1, 7, 0], [4, 4, 4, 4, 4, 4, 0, 0, 0, 0], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [8, 1];
break;
case 47:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 0, 1, 1, 1, 5, 0, 4], [4, 4, 4, 0, 1, 7, 1, 1, 0, 4], [4, 4, 4, 0, 7, 1, 1, 0, 0, 4], [4, 4, 4, 0, 6, 1, 0, 0, 4, 4], [4, 4, 4, 0, 1, 0, 0, 4, 4, 4], [4, 4, 4, 0, 0, 0, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [7, 2];
StorePurple = 1;
break;
case 48:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 0, 0, 0, 0, 0, 0, 4, 4], [4, 4, 0, 1, 1, 1, 0, 0, 4, 4], [4, 0, 0, 1, 1, 3, 1, 0, 4, 4], [4, 0, 7, 5, 7, 1, 1, 0, 4, 4], [4, 0, 1, 1, 1, 1, 1, 0, 4, 4], [4, 0, 0, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [3, 4];
StorePurple = 1;
break;
case 49:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 0, 0, 0, 0, 0, 0, 0, 0, 0], [4, 0, 5, 1, 1, 1, 1, 1, 1, 0], [4, 0, 1, 0, 0, 0, 0, 0, 1, 0], [4, 0, 1, 1, 1, 1, 1, 1, 1, 0], [4, 0, 0, 0, 0, 0, 0, 2, 6, 0], [4, 4, 4, 4, 0, 1, 1, 2, 1, 0], [4, 4, 4, 4, 0, 1, 0, 0, 1, 0], [4, 4, 4, 4, 0, 1, 1, 1, 1, 0], [4, 4, 4, 4, 0, 0, 0, 0, 0, 0]];
charPos = [2, 2];
StorePurple = 2;
break;
case 50:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 0, 0, 0, 0, 0, 0, 0, 0, 4], [4, 0, 1, 1, 1, 1, 1, 1, 0, 4], [4, 0, 1, 0, 1, 2, 5, 1, 0, 4], [4, 0, 1, 1, 2, 6, 1, 1, 0, 4], [4, 0, 0, 0, 1, 1, 1, 1, 0, 4], [4, 4, 4, 0, 0, 1, 1, 1, 0, 4], [4, 4, 4, 4, 0, 1, 1, 1, 0, 4], [4, 4, 4, 4, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [6, 3];
StorePurple = 1;
break;
case 51:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 0, 0, 0, 0, 0, 0, 0, 0, 0], [4, 0, 1, 1, 1, 1, 1, 1, 1, 0], [4, 0, 7, 1, 1, 5, 1, 1, 7, 0], [4, 0, 1, 1, 1, 1, 1, 1, 1, 0], [4, 0, 0, 0, 0, 0, 0, 0, 0, 0], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [5, 5];
break;
case 52:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 0, 0, 0, 0, 0, 0, 0, 4], [4, 4, 0, 1, 1, 1, 1, 7, 0, 4], [4, 4, 0, 1, 5, 1, 1, 1, 0, 4], [4, 4, 0, 1, 1, 1, 1, 1, 0, 4], [4, 4, 0, 1, 1, 1, 1, 1, 0, 4], [4, 4, 0, 0, 1, 6, 1, 0, 0, 4], [4, 4, 4, 0, 0, 1, 7, 0, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [4, 3];
StorePurple = 1;
break;
case 53:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 0, 4], [4, 0, 0, 0, 1, 1, 1, 1, 0, 4], [4, 0, 1, 0, 1, 2, 1, 1, 0, 4], [4, 0, 7, 0, 0, 7, 2, 1, 0, 4], [4, 0, 6, 0, 0, 5, 1, 1, 0, 4], [4, 0, 1, 0, 1, 2, 1, 1, 0, 4], [4, 0, 0, 0, 1, 1, 1, 1, 0, 4], [4, 4, 4, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [5, 5];
StorePurple = 1;
break;
case 54:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 0, 0, 0, 0, 0, 0, 0, 0, 4], [4, 0, 1, 1, 1, 1, 1, 1, 0, 4], [4, 0, 1, 1, 2, 2, 1, 1, 0, 4], [4, 0, 1, 2, 1, 1, 1, 1, 0, 4], [4, 0, 1, 1, 6, 5, 1, 1, 0, 4], [4, 0, 1, 2, 2, 1, 1, 1, 0, 4], [4, 0, 1, 1, 1, 1, 1, 1, 0, 4], [4, 0, 0, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [5, 5];
StorePurple = 1;
break;
case 55:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 4, 4], [4, 0, 0, 0, 1, 6, 1, 0, 0, 0], [4, 0, 1, 1, 2, 2, 2, 1, 1, 0], [4, 0, 1, 0, 1, 5, 2, 0, 1, 0], [4, 0, 1, 0, 0, 0, 1, 0, 1, 0], [4, 0, 1, 1, 1, 1, 1, 1, 1, 0], [4, 0, 0, 0, 0, 0, 0, 0, 0, 0], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [5, 5];
StorePurple = 1;
break;
case 56:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 0, 0, 0, 0, 0, 0, 0, 0, 4], [4, 0, 1, 1, 1, 1, 1, 1, 0, 4], [4, 0, 1, 0, 1, 1, 1, 1, 0, 4], [4, 0, 1, 1, 5, 1, 1, 1, 0, 4], [4, 0, 7, 1, 1, 6, 1, 7, 0, 4], [4, 0, 1, 1, 1, 1, 1, 1, 0, 4], [4, 0, 1, 1, 1, 1, 1, 1, 0, 4], [4, 0, 0, 0, 0, 0, 0, 0, 0, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [4, 4];
StorePurple = 1;
break;
case 57:
Map = [[4, 4, 4, 4, 4, 0, 0, 0, 0, 0], [4, 4, 4, 0, 0, 0, 2, 3, 7, 0], [4, 4, 4, 0, 1, 3, 2, 0, 0, 0], [0, 0, 0, 0, 2, 3, 3, 0, 4, 4], [0, 5, 2, 2, 3, 1, 3, 0, 4, 4], [0, 1, 3, 2, 3, 2, 1, 0, 4, 4], [0, 0, 0, 0, 3, 3, 3, 0, 4, 4], [4, 4, 4, 0, 0, 1, 3, 0, 0, 0], [4, 4, 4, 4, 0, 1, 1, 2, 7, 0], [4, 4, 4, 4, 0, 0, 0, 0, 0, 0]];
charPos = [1, 4];
break;
case 58:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 0, 0, 0, 0, 0, 0, 4, 4], [4, 4, 0, 7, 1, 1, 5, 0, 4, 4], [4, 4, 0, 1, 1, 1, 1, 0, 4, 4], [4, 4, 0, 1, 2, 6, 1, 0, 4, 4], [4, 4, 0, 1, 3, 2, 1, 0, 4, 4], [4, 4, 0, 0, 1, 7, 0, 0, 4, 4], [4, 4, 4, 0, 0, 0, 0, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [6, 2];
StorePurple = 1;
break;
case 59:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 0, 0, 0, 4, 4, 4], [4, 4, 4, 4, 0, 7, 0, 4, 4, 4], [4, 4, 4, 4, 0, 5, 0, 4, 4, 4], [4, 0, 0, 0, 0, 1, 0, 0, 0, 0], [4, 0, 1, 0, 1, 1, 1, 0, 7, 0], [4, 0, 6, 2, 2, 1, 2, 1, 2, 0], [4, 0, 1, 2, 1, 0, 1, 1, 1, 0], [4, 0, 0, 0, 0, 0, 0, 0, 0, 0]];
charPos = [5, 4];
StorePurple = 1;
break;
case 60:
Map = [[4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 0, 7, 5, 7, 0, 4, 4], [4, 4, 4, 0, 0, 0, 0, 0, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4], [4, 4, 4, 4, 4, 4, 4, 4, 4, 4]];
charPos = [5, 5];
break;
default:
trace("no more levels");
break;
};
_local1 = false;
_local2 = 0;
while (_local2 < TutorialArray.length) {
if (TutorialArray[_local2] == mapNumber){
if ((((mapNumber == levelUnlocked)) && (FirstTime))){
_local1 = true;
render();
_local3 = 3;
_local4 = new BitmapData(550, 400, false);
_local4.draw(stage, new Matrix());
_local5 = new Bitmap(_local4);
bitmapMC.addChild(_local5);
stage.addChild(bitmapMC);
_local6 = new BlurFilter(_local3, _local3, 5);
bitmapMC.filters = [_local6];
stage.removeEventListener(KeyboardEvent.KEY_DOWN, kd);
timer.stop();
stage.addChild(tutorial);
tutorial.btn_continue.buttonMode = true;
tutorial.btn_continue.useHandCursor = true;
tutorial.btn_continue.gotoAndStop(1);
tutorial.btn_continue.addChild(new cover2());
tutorial.btn_continue.addEventListener(MouseEvent.ROLL_OUT, roll_out);
tutorial.btn_continue.addEventListener(MouseEvent.ROLL_OVER, roll_over2);
tutorial.btn_continue.txtbox.text = "Continue";
tutorial.txt_title.text = TitleArray[_local2];
tutorial.txt_text.text = TextArray[_local2];
tutorial.btn_continue.addEventListener(MouseEvent.CLICK, btn_continue_click);
stage.addEventListener(KeyboardEvent.KEY_DOWN, PressSpace2);
};
};
_local2++;
};
if (!_local1){
BitmapTransition();
};
}
public function btn_retry_continue_CLICK(_arg1:MouseEvent):void{
RetryContinue();
}
public function AutoSave():void{
saved_info.data.Level = new Number(levelUnlocked);
saved_info.data.highscore = new Number(HighScore);
}
public function btn_continue_click(_arg1:MouseEvent):void{
stage.removeChild(tutorial);
stage.removeEventListener(KeyboardEvent.KEY_DOWN, PressSpace2);
stage.addEventListener(KeyboardEvent.KEY_DOWN, kd);
stage.removeChild(bitmapMC);
theTime = 0;
timer.start();
}
function frame5(){
stop();
LevelSelectInit();
}
public function btn_music_2_CLICK(_arg1:MouseEvent):void{
SongSelected = "Future";
if (MusicEnabled){
SoundMixer.stopAll();
FutureSong.play();
};
}
function frame7(){
stop();
btn_back.addEventListener(MouseEvent.CLICK, btn_back_click);
btn_back.addEventListener(MouseEvent.ROLL_OVER, menu_sound);
}
public function tim_sponsor(_arg1:TimerEvent):void{
logo_timer.removeEventListener(TimerEvent.TIMER, tim_sponsor);
BitmapTransition();
play();
}
public function checkGrid():void{
var _local1:Number;
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
_local1 = 0;
_local2 = charPos[0];
_local3 = charPos[1];
_local4 = Map[0].length;
_local5 = Map.length;
if (Map[_local3][_local2] == 5){
Victory = true;
_local3 = 0;
while (_local3 < _local5) {
_local2 = 0;
while (_local2 < _local4) {
if ((((((Map[_local3][_local2] == 1)) || ((Map[_local3][_local2] == 2)))) || ((Map[_local3][_local2] == 3)))){
Victory = false;
};
_local2++;
};
_local3++;
};
Cover(Victory);
} else {
if (Map[(_local3 + 1)][_local2] == 0){
_local1++;
} else {
if (Map[(_local3 + 1)][_local2] == 6){
if ((((((Map[(_local3 + 2)][_local2] == 7)) || ((Map[(_local3 + 2)][_local2] == 5)))) || ((Map[(_local3 + 2)][_local2] == 0)))){
_local1++;
};
};
};
if (Map[(_local3 - 1)][_local2] == 0){
_local1++;
} else {
if (Map[(_local3 - 1)][_local2] == 6){
if ((((((Map[(_local3 - 2)][_local2] == 7)) || ((Map[(_local3 - 2)][_local2] == 5)))) || ((Map[(_local3 - 2)][_local2] == 0)))){
_local1++;
};
};
};
if (Map[_local3][(_local2 + 1)] == 0){
_local1++;
} else {
if (Map[_local3][(_local2 + 1)] == 6){
if ((((((Map[_local3][(_local2 + 2)] == 7)) || ((Map[_local3][(_local2 + 2)] == 5)))) || ((Map[_local3][(_local2 + 2)] == 0)))){
_local1++;
};
};
};
if (Map[_local3][(_local2 - 1)] == 0){
_local1++;
} else {
if (Map[_local3][(_local2 - 1)] == 6){
if ((((((Map[_local3][(_local2 - 2)] == 7)) || ((Map[_local3][(_local2 - 2)] == 5)))) || ((Map[_local3][(_local2 - 2)] == 0)))){
_local1++;
};
};
};
if (_local1 >= 4){
Victory = false;
Cover(Victory);
};
};
}
function frame4(){
saved_info = SharedObject.getLocal("user_data");
mapNumber = 1;
HighScore = 0;
stop();
SoundMixer.stopAll();
btn_play.addEventListener(MouseEvent.CLICK, btn_play_click);
btn_play.addEventListener(MouseEvent.ROLL_OVER, menu_sound);
btn_instructions.addEventListener(MouseEvent.CLICK, btn_instructions_click);
btn_instructions.addEventListener(MouseEvent.ROLL_OVER, menu_sound);
btn_highscores.addEventListener(MouseEvent.CLICK, LegitHighscore);
btn_highscores.addEventListener(MouseEvent.ROLL_OVER, menu_sound);
btn_credits.addEventListener(MouseEvent.CLICK, btn_credits_click);
btn_credits.addEventListener(MouseEvent.ROLL_OVER, menu_sound);
btn_playmoregames.addEventListener(MouseEvent.CLICK, btn_moregames_click);
btn_playmoregames.addEventListener(MouseEvent.ROLL_OVER, menu_sound);
AutoLoad();
}
function frame1(){
stop();
levelUnlocked = 1;
FirstTime = true;
stage.quality = StageQuality.HIGH;
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.frameRate = 100;
this.addEventListener(Event.ENTER_FRAME, preloading, false, 0, true);
}
function frame3(){
stop();
logo_timer = new Timer(4000);
Beep = new beep();
legitlogo.addEventListener(MouseEvent.CLICK, btn_moregames_click, false, 0, true);
logo_timer.addEventListener(TimerEvent.TIMER, tim_sponsor, false, 0, true);
logo_timer.start();
}
public function btn_play_click(_arg1:MouseEvent):void{
BitmapTransition();
gotoAndStop("LEVELSELECT");
}
function frame8(){
stop();
btn_back.addEventListener(MouseEvent.CLICK, btn_back_click);
btn_back.addEventListener(MouseEvent.ROLL_OVER, menu_sound);
}
public function roll_out(_arg1:MouseEvent):void{
_arg1.target.gotoAndStop(1);
}
public function DisplayTime():void{
var _local1:String;
var _local2:String;
_local1 = "";
_local2 = "";
_local1 = String(Math.floor((theTime / 60)));
_local2 = String((theTime % 60));
if (Number(_local2) < 10){
_local2 = ("0" + _local2);
};
hud.thetime_txtbox.text = ((_local1 + " : ") + _local2);
}
function frame6(){
stop();
Map = [];
charPos = [];
TutorialArray = [1, 3, 6, 9, 15, 20, 27, 45, 60];
TitleArray = ["The beginning", "Highscore", "Tip", "Double Tiles", "Triple Tiles", "Purple Blocks", "Green Tiles", "Only 15 left", "The cake"];
TextArray = ["You control the red block with the arrow keys, you have to step on each tile once and come back where you started.", "When you quit, your levels stay unlocked but your score will be reset. To achieve the best highscore possible, beat as many levels as possible in a single play.", "You can press R at any time to reset a level", "These darker tiles have to be stepped on twice before they turn into blocks.", "This level has triple tiles, you have to step on them 3 times before they turn into blocks.", "This level contains purple blocks, they can be pushed, use this to your advantage.", "Green tiles are warps, stepping on one will bring you to the other one.", "Wow, I'm impressed you got so far but the next 15 levels aren't a piece of cake.", "... is a lie"];
tileWidth = 40;
tileHeight = 80;
dynamicmenu = new DynamicMenu();
tutorial = new Tutorial();
Victory = true;
Score = 0;
StorePurple = 1;
bitmapMC = new MovieClip();
controls = true;
MusicEnabled = true;
SongSelected = "Crimson";
CrimsonSong = new Crimson();
FutureSong = new Future();
UrbanSong = new Urban();
CrimsonSong.play();
KeyLeft = 37;
KeyUp = 38;
KeyRight = 39;
KeyDown = 40;
timer = new Timer(1000);
theTime = 0;
Ready = false;
btn_controls.buttonMode = true;
btn_controls.useHandCursor = true;
btn_controls.gotoAndStop(1);
btn_controls.addEventListener(MouseEvent.CLICK, btn_controls_CLICK);
btn_music.addEventListener(MouseEvent.CLICK, btn_music_CLICK);
btn_music_1.addEventListener(MouseEvent.CLICK, btn_music_1_CLICK);
btn_music_2.addEventListener(MouseEvent.CLICK, btn_music_2_CLICK);
btn_music_3.addEventListener(MouseEvent.CLICK, btn_music_3_CLICK);
mapChange();
render();
hud.txt_level.text = ("Level : " + String(mapNumber));
DisplayScore(false);
stage.addEventListener(KeyboardEvent.KEY_DOWN, kd, false, 0, true);
timer.addEventListener(TimerEvent.TIMER, tim, false, 0, true);
timer.start();
}
public function LegitHighscore(_arg1:MouseEvent):void{
var _local2:*;
_local2 = new URLRequest("http://www.legitgames.com/index.php?pageid=12");
navigateToURL(_local2);
}
public function tim(_arg1:TimerEvent):void{
theTime++;
DisplayTime();
}
function frame9(){
stop();
btn_back.addEventListener(MouseEvent.CLICK, btn_back_click);
btn_back.addEventListener(MouseEvent.ROLL_OVER, menu_sound);
btn_submit.addEventListener(MouseEvent.CLICK, btn_submit_click);
high_score_display.text = String(HighScore);
SoundMixer.stopAll();
}
function frame2(){
}
public function LevelSelectInit(){
var _local1:*;
var _local2:*;
var _local3:MovieClip;
_local1 = 1;
while (_local1 <= levelUnlocked) {
_local3 = root[("lt" + _local1)];
_local3.txtbox.text = String(_local1);
_local3.buttonMode = true;
_local3.useHandCursor = true;
_local3.addChild(new cover());
_local3.addEventListener(MouseEvent.ROLL_OVER, roll_over);
_local3.addEventListener(MouseEvent.ROLL_OUT, roll_out);
_local3.addEventListener(MouseEvent.MOUSE_DOWN, mouse_down);
_local3.stop();
_local1++;
};
_local2 = (levelUnlocked + 1);
while (_local2 < 61) {
root[("lt" + _local2)].txtbox.text = "?";
root[("lt" + _local2)].stop();
_local2++;
};
}
public function PressSpace(_arg1:KeyboardEvent):void{
var _local2:Number;
_local2 = _arg1.keyCode;
if ((((_local2 == 32)) || ((_local2 == 13)))){
RetryContinue();
};
}
public function kd(_arg1:KeyboardEvent):void{
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:Number;
var _local9:Number;
var _local10:Number;
_local2 = _arg1.keyCode;
_local3 = 0;
_local4 = 0;
_local5 = Map[0].length;
_local6 = Map.length;
_local7 = charPos[0];
_local8 = charPos[1];
_local9 = _local8;
_local10 = _local7;
if (_local2 == 82){
FirstTime = false;
DisplayTime();
theTime = 0;
mapChange();
render();
};
if (_local2 == KeyDown){
switch (Map[(_local8 - 1)][_local7]){
case 0:
break;
case 1:
var _local11 = charPos;
var _local12 = 1;
var _local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local8--;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 2:
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local8--;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 3:
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local8--;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 4:
break;
case 5:
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local8--;
render();
break;
case 6:
if ((((((Map[(_local8 - 2)][_local7] == 1)) || ((Map[(_local8 - 2)][_local7] == 2)))) || ((Map[(_local8 - 2)][_local7] == 3)))){
Map[(_local8 - 1)][_local7] = StorePurple;
StorePurple = Map[(_local8 - 2)][_local7];
Map[(_local8 - 2)][_local7] = 6;
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local8--;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
};
break;
case 7:
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local8--;
render();
BitmapTransition();
_local3 = 0;
while (_local3 < _local6) {
_local4 = 0;
while (_local4 < _local5) {
if ((((Map[_local3][_local4] == 7)) && (((!((_local3 == _local8))) || (!((_local4 == _local7))))))){
charPos = [_local4, _local3];
render();
};
_local4++;
};
_local3++;
};
break;
};
} else {
if (_local2 == KeyUp){
switch (Map[(_local8 + 1)][_local7]){
case 0:
break;
case 1:
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local8++;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 2:
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local8++;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 3:
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local8++;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 4:
break;
case 5:
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local8++;
render();
break;
case 6:
if ((((((Map[(_local8 + 2)][_local7] == 1)) || ((Map[(_local8 + 2)][_local7] == 2)))) || ((Map[(_local8 + 2)][_local7] == 3)))){
Map[(_local8 + 1)][_local7] = StorePurple;
StorePurple = Map[(_local8 + 2)][_local7];
Map[(_local8 + 2)][_local7] = 6;
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local8++;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
};
break;
case 7:
_local11 = charPos;
_local12 = 1;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local8++;
render();
BitmapTransition();
_local3 = 0;
while (_local3 < _local6) {
_local4 = 0;
while (_local4 < _local5) {
if ((((Map[_local3][_local4] == 7)) && (((!((_local3 == _local8))) || (!((_local4 == _local7))))))){
charPos = [_local4, _local3];
render();
};
_local4++;
};
_local3++;
};
break;
};
} else {
if (_local2 == KeyRight){
switch (Map[_local8][(_local7 + 1)]){
case 0:
break;
case 1:
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local7++;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 2:
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local7++;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 3:
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local7++;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 4:
break;
case 5:
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local7++;
render();
break;
case 6:
if ((((((Map[_local8][(_local7 + 2)] == 1)) || ((Map[_local8][(_local7 + 2)] == 2)))) || ((Map[_local8][(_local7 + 2)] == 3)))){
Map[_local8][(_local7 + 1)] = StorePurple;
StorePurple = Map[_local8][(_local7 + 2)];
Map[_local8][(_local7 + 2)] = 6;
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local7++;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
};
break;
case 7:
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] + 1);
_local11[_local12] = _local13;
_local7++;
render();
BitmapTransition();
_local3 = 0;
while (_local3 < _local6) {
_local4 = 0;
while (_local4 < _local5) {
if ((((Map[_local3][_local4] == 7)) && (((!((_local3 == _local8))) || (!((_local4 == _local7))))))){
charPos = [_local4, _local3];
render();
};
_local4++;
};
_local3++;
};
break;
};
} else {
if (_local2 == KeyLeft){
switch (Map[_local8][(_local7 - 1)]){
case 0:
break;
case 1:
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local7--;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 2:
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local7--;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 3:
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local7--;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
break;
case 4:
break;
case 5:
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local7--;
render();
break;
case 6:
if ((((((Map[_local8][(_local7 - 2)] == 1)) || ((Map[_local8][(_local7 - 2)] == 2)))) || ((Map[_local8][(_local7 - 2)] == 3)))){
Map[_local8][(_local7 - 1)] = StorePurple;
StorePurple = Map[_local8][(_local7 - 2)];
Map[_local8][(_local7 - 2)] = 6;
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local7--;
_local11 = Map[_local8];
_local12 = _local7;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
render();
};
break;
case 7:
_local11 = charPos;
_local12 = 0;
_local13 = (_local11[_local12] - 1);
_local11[_local12] = _local13;
_local7--;
render();
BitmapTransition();
_local3 = 0;
while (_local3 < _local6) {
_local4 = 0;
while (_local4 < _local5) {
if ((((Map[_local3][_local4] == 7)) && (((!((_local3 == _local8))) || (!((_local4 == _local7))))))){
charPos = [_local4, _local3];
render();
};
_local4++;
};
_local3++;
};
break;
};
};
};
};
};
if (((!((_local9 == _local8))) || (!((_local10 == _local7))))){
checkGrid();
};
}
public function btn_controls_CLICK(_arg1:MouseEvent):void{
if (controls){
controls = false;
KeyLeft = 38;
KeyUp = 39;
KeyRight = 40;
KeyDown = 37;
btn_controls.gotoAndStop(2);
} else {
controls = true;
KeyLeft = 37;
KeyUp = 38;
KeyRight = 39;
KeyDown = 40;
btn_controls.gotoAndStop(1);
};
}
public function btn_credits_click(_arg1:MouseEvent):void{
BitmapTransition();
gotoAndStop("CREDITS");
}
public function DisplayScore(_arg1):void{
var NewScore:Number;
var b:Number;
var ef:Function;
var increase = _arg1;
hud.score_txtbox.text = ("Score : " + String(Score));
NewScore = 0;
b = (120 - theTime);
if (b < 1){
b = 1;
};
dynamicmenu.txt_score.text = String(Score);
if (increase){
ef = function (_arg1:Event):void{
if (Number(dynamicmenu.txt_score.text) < Score){
NewScore = (Number(dynamicmenu.txt_score.text) + 1);
dynamicmenu.txt_score.text = String(NewScore);
};
};
NewScore = (b + (5 * mapNumber));
Score = (Score + NewScore);
if (Score > HighScore){
HighScore = Score;
};
dynamicmenu.addEventListener(Event.ENTER_FRAME, ef);
};
}
public function position(_arg1):void{
var _local2:MovieClip;
var _local3:*;
var _local4:Number;
var _local5:Number;
_local2 = _arg1;
_local2.x = -1337;
_local2.y = -1337;
_local3 = _local2.getBounds(this);
_local4 = ((400 - _local2.height) / 2);
_local5 = ((550 - _local2.width) / 2);
while (_local3.x < _local5) {
_local3 = _local2.getBounds(this);
_local2.x++;
};
while (_local3.y < _local4) {
_local3 = _local2.getBounds(this);
_local2.y++;
};
}
public function btn_instructions_click(_arg1:MouseEvent):void{
BitmapTransition();
gotoAndStop("INSTRUCTIONS");
}
public function btn_quit_CLICK(_arg1:MouseEvent):void{
if (Victory){
mapNumber++;
if (mapNumber > levelUnlocked){
levelUnlocked = mapNumber;
FirstTime = false;
};
AutoSave();
};
stage.removeChild(dynamicmenu);
stage.removeChildAt(1);
stage.removeChild(bitmapMC);
BitmapTransition();
gotoAndStop("MENU");
}
public function btn_music_1_CLICK(_arg1:MouseEvent):void{
SongSelected = "Crimson";
if (MusicEnabled){
SoundMixer.stopAll();
CrimsonSong.play();
};
}
public function preloading(_arg1:Event):void{
progressBar.scaleX = (this.loaderInfo.bytesLoaded / this.loaderInfo.bytesTotal);
if (this.loaderInfo.bytesLoaded == this.loaderInfo.bytesTotal){
BitmapTransition();
gotoAndPlay(2);
this.removeEventListener(Event.ENTER_FRAME, preloading);
};
}
public function RetryContinue():void{
stage.removeChild(dynamicmenu);
stage.removeEventListener(KeyboardEvent.KEY_DOWN, PressSpace);
stage.removeChildAt(1);
stage.removeChild(bitmapMC);
if (mapNumber == 60){
BitmapTransition();
gotoAndStop("HIGHSCORES");
} else {
timer.start();
theTime = 0;
DisplayTime();
DisplayScore(false);
if (Victory){
mapNumber++;
if (mapNumber > levelUnlocked){
levelUnlocked = mapNumber;
};
AutoSave();
hud.txt_level.text = ("Level : " + String(mapNumber));
};
FirstTime = true;
Ready = false;
mapChange();
render();
stage.addEventListener(KeyboardEvent.KEY_DOWN, kd, false, 0, true);
};
}
public function AutoLoad():void{
levelUnlocked = saved_info.data.Level;
HighScore = saved_info.data.highscore;
if (!HighScore){
HighScore = 0;
};
if (!levelUnlocked){
levelUnlocked = 1;
};
}
public function btn_music_CLICK(_arg1:MouseEvent):void{
if (MusicEnabled){
MusicEnabled = false;
SoundMixer.stopAll();
} else {
MusicEnabled = true;
switch (SongSelected){
case "Crimson":
CrimsonSong.play();
break;
case "Future":
FutureSong.play();
break;
case "Urban":
UrbanSong.play();
break;
default:
break;
};
};
}
public function roll_over(_arg1:MouseEvent):void{
Beep.play();
if (Number(_arg1.target.txtbox.text) <= levelUnlocked){
_arg1.target.gotoAndStop(2);
};
}
public function Cover(_arg1):void{
var _local2:String;
var _local3:Number;
var _local4:BitmapData;
var _local5:*;
var _local6:*;
_local2 = "Press space to ";
stage.removeEventListener(KeyboardEvent.KEY_DOWN, kd);
stage.addEventListener(KeyboardEvent.KEY_DOWN, PressSpace);
timer.stop();
DisplayScore(_arg1);
theTime = 0;
_local3 = 3;
_local4 = new BitmapData(550, 400, false);
_local4.draw(stage, new Matrix());
_local5 = new Bitmap(_local4);
bitmapMC.addChild(_local5);
stage.addChild(bitmapMC);
_local6 = new BlurFilter(_local3, _local3, 5);
bitmapMC.filters = [_local6];
stage.addChild(dynamicmenu);
dynamicmenu.btn_retry_continue.buttonMode = true;
dynamicmenu.btn_retry_continue.useHandCursor = true;
dynamicmenu.btn_retry_continue.gotoAndStop(1);
dynamicmenu.btn_retry_continue.addChild(new cover2());
dynamicmenu.btn_retry_continue.addEventListener(MouseEvent.ROLL_OUT, roll_out);
dynamicmenu.btn_retry_continue.addEventListener(MouseEvent.ROLL_OVER, roll_over2);
if (_arg1){
dynamicmenu.btn_submitscore.visible = false;
dynamicmenu.btn_retry_continue.y = 263.1;
dynamicmenu.btn_submitscore.x = 13;
dynamicmenu.btn_submitscore.y = 326.9;
dynamicmenu.btn_quit.y = 310.4;
dynamicmenu.btn_retry_continue.txtbox.text = "Continue";
dynamicmenu.pressspace.text = (_local2 + "continue");
dynamicmenu.txt_failsuccess.text = "SUCCESS !";
} else {
dynamicmenu.btn_submitscore.visible = true;
dynamicmenu.btn_retry_continue.y = 232.1;
dynamicmenu.btn_submitscore.x = 275;
dynamicmenu.btn_submitscore.y = 274.8;
dynamicmenu.btn_quit.y = 317.4;
dynamicmenu.btn_retry_continue.txtbox.text = "Try again";
dynamicmenu.pressspace.text = (_local2 + "try again");
dynamicmenu.txt_failsuccess.text = "FAIL !";
};
dynamicmenu.pressspace.y = (dynamicmenu.btn_retry_continue.y - 41.1);
dynamicmenu.btn_retry_continue.addEventListener(MouseEvent.CLICK, btn_retry_continue_CLICK);
dynamicmenu.btn_submitscore.addEventListener(MouseEvent.CLICK, btn_highscores_click);
dynamicmenu.btn_quit.addEventListener(MouseEvent.CLICK, btn_quit_CLICK);
dynamicmenu.btn_quit.addEventListener(MouseEvent.ROLL_OVER, menu_sound);
}
public function btn_submit_click(_arg1:MouseEvent):void{
var _local2:URLRequest;
var _local3:URLVariables;
_local2 = new URLRequest("http://www.legitgames.com/scores/scoreSystem/new_score_as3.php");
_local3 = new URLVariables();
_local3.playerName = String(name_input.text);
_local3.score = HighScore;
_local3.gameName = "isora2";
_local2.method = URLRequestMethod.POST;
_local2.data = _local3;
sendToURL(_local2);
_local2 = new URLRequest("http://www.legitgames.com/index.php?pageid=12");
navigateToURL(_local2);
HighScore = 0;
AutoSave();
BitmapTransition();
gotoAndStop("MENU");
}
public function btn_music_3_CLICK(_arg1:MouseEvent):void{
SongSelected = "Urban";
if (MusicEnabled){
SoundMixer.stopAll();
UrbanSong.play();
};
}
public function roll_over2(_arg1:MouseEvent):void{
Beep.play();
_arg1.target.gotoAndStop(2);
}
public function btn_back_click(_arg1:MouseEvent):void{
BitmapTransition();
gotoAndStop("MENU");
}
public function mouse_down(_arg1:MouseEvent):void{
mapNumber = Number(_arg1.target.parent.txtbox.text);
BitmapTransition();
gotoAndStop("GAME");
}
public function PressSpace2(_arg1:KeyboardEvent):void{
var _local2:Number;
_local2 = _arg1.keyCode;
if ((((_local2 == 13)) || ((_local2 == 32)))){
stage.removeChild(tutorial);
stage.removeEventListener(KeyboardEvent.KEY_DOWN, PressSpace2);
stage.addEventListener(KeyboardEvent.KEY_DOWN, kd);
stage.removeChild(bitmapMC);
theTime = 0;
timer.start();
};
}
}
}//package isora2_fla
Section 5
//beep (beep)
package {
import flash.media.*;
public dynamic class beep extends Sound {
}
}//package
Section 6
//charMC (charMC)
package {
import flash.display.*;
public dynamic class charMC extends MovieClip {
}
}//package
Section 7
//containerMC (containerMC)
package {
import flash.display.*;
public dynamic class containerMC extends MovieClip {
}
}//package
Section 8
//cover (cover)
package {
import flash.display.*;
public dynamic class cover extends MovieClip {
}
}//package
Section 9
//cover2 (cover2)
package {
import flash.display.*;
public dynamic class cover2 extends MovieClip {
}
}//package
Section 10
//Crimson (Crimson)
package {
import flash.media.*;
public dynamic class Crimson extends Sound {
}
}//package
Section 11
//DynamicMenu (DynamicMenu)
package {
import flash.display.*;
import flash.text.*;
public dynamic class DynamicMenu extends MovieClip {
public var txt_score:TextField;
public var btn_submitscore:SimpleButton;
public var btn_quit:SimpleButton;
public var btn_retry_continue:MovieClip;
public var pressspace:TextField;
public var txt_failsuccess:TextField;
}
}//package
Section 12
//Future (Future)
package {
import flash.media.*;
public dynamic class Future extends Sound {
}
}//package
Section 13
//tile (tile)
package {
import flash.display.*;
public dynamic class tile extends MovieClip {
}
}//package
Section 14
//Tutorial (Tutorial)
package {
import flash.display.*;
import flash.text.*;
public dynamic class Tutorial extends MovieClip {
public var btn_continue:MovieClip;
public var pressspace:TextField;
public var txt_text:TextField;
public var txt_title:TextField;
}
}//package
Section 15
//Urban (Urban)
package {
import flash.media.*;
public dynamic class Urban extends Sound {
}
}//package