Section 1
//qPic (Engine.qPic)
package Engine {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import Games.tripline.*;
public dynamic class qPic extends MovieClip {
private static var _Domain:String;
private static var _MainApp:qPic;
private static var _ScreenX:Number;
private static var _ScreenY:Number;
public static var LongestFrameTime:Number = 1000;
private static var _ScreenHalfY:Number;
private static var _ScreenHalfX:Number;
private static var LastTime:Number = 0;
private static var _Scene:DisplayObjectContainer;
public static var Games:Array = new Array();
private static var _SceneBack:DisplayObjectContainer;
public static var FrameTime:Number = 0;
private static var _SceneFront:DisplayObjectContainer;
public function qPic(){
super();
addEventListener(Event.ENTER_FRAME, Init);
}
public function Init(_event:Event):void{
removeEventListener(Event.ENTER_FRAME, Init);
_MainApp = (_event.target as qPic);
_SceneBack = new Sprite();
_SceneBack.mouseEnabled = false;
_Scene = new Sprite();
_Scene.mouseEnabled = false;
_SceneFront = new Sprite();
_SceneFront.mouseEnabled = false;
_MainApp.addChild(_SceneBack);
_MainApp.addChild(_Scene);
_MainApp.addChild(_SceneFront);
_ScreenX = stage.stageWidth;
_ScreenY = stage.stageHeight;
_ScreenHalfX = (_ScreenX / 2);
_ScreenHalfY = (_ScreenY / 2);
_Domain = stage.loaderInfo.url.split("://")[1].split("/")[0];
LastTime = getTimer();
aPicInit.Locking();
qPicKeyListener.Start();
qPicProcessor.Start();
qPicMouse.Start();
aPicInit.Start();
FocusScene();
addEventListener(Event.ENTER_FRAME, ClearLoader);
}
public function onEnterFrame(_event:Event):void{
qPicProcessor.Main();
}
public function ClearLoader(_event:Event):void{
var xobj:DisplayObject;
removeEventListener(Event.ENTER_FRAME, ClearLoader);
qPicProcessor.Main();
var i:int;
while (i < _MainApp.parent.numChildren) {
xobj = _MainApp.parent.getChildAt(i);
if (xobj == _MainApp){
i++;
} else {
_MainApp.parent.removeChildAt(i);
};
};
addEventListener(Event.ENTER_FRAME, onEnterFrame);
}
public static function get MainApp():qPic{
return (_MainApp);
}
public static function get ScreenX():Number{
return (_ScreenX);
}
public static function get ScreenY():Number{
return (_ScreenY);
}
public static function FocusScene():void{
qPic.Scene.stage.focus = qPic.Scene.stage;
}
public static function get ScreenHalfX():Number{
return (_ScreenHalfX);
}
public static function get SceneFront():DisplayObjectContainer{
return (_SceneFront);
}
public static function SiT(n:Number):Number{
return (((n * FrameTime) / 1000));
}
public static function ClearScene():void{
while (qPic.Scene.numChildren > 0) {
qPic.Scene.removeChildAt(0);
};
}
public static function get Domain():String{
return (_Domain);
}
public static function UpdateTime():void{
var currTime:Number = getTimer();
FrameTime = Math.min((currTime - LastTime), LongestFrameTime);
LastTime = currTime;
}
public static function get Scene():DisplayObjectContainer{
return (_Scene);
}
public static function get ScreenHalfY():Number{
return (_ScreenHalfY);
}
public static function get SceneBack():DisplayObjectContainer{
return (_SceneBack);
}
public static function ClearFrontScene():void{
while (qPic.SceneFront.numChildren > 0) {
qPic.SceneFront.removeChildAt(0);
};
}
public static function ClearBackScene():void{
while (qPic.SceneBack.numChildren > 0) {
qPic.SceneBack.removeChildAt(0);
};
}
}
}//package Engine
Section 2
//qPicKeyListener (Engine.qPicKeyListener)
package Engine {
import flash.events.*;
public class qPicKeyListener {
private static var KeyPressed:Array = new Array();
private static var isCanPrintMessages:Boolean = false;
private static var isKeyPressed:Array = new Array(0x0100);
public function qPicKeyListener(){
super();
}
public static function SetIsCanPrintMessages(val:Boolean):void{
isCanPrintMessages = val;
}
public static function print():void{
trace(KeyPressed);
}
public static function Start():void{
qPic.Scene.stage.addEventListener(KeyboardEvent.KEY_DOWN, onKeyDown);
qPic.Scene.stage.addEventListener(KeyboardEvent.KEY_UP, onKeyUp);
qPic.Scene.stage.addEventListener(MouseEvent.MOUSE_DOWN, onMouseKeyDown);
qPic.Scene.stage.addEventListener(MouseEvent.MOUSE_UP, onMouseKeyUp);
var i:uint;
while (i < 0x0100) {
isKeyPressed[i] = false;
i++;
};
}
public static function onKeyUp(event:KeyboardEvent):void{
var i:uint;
if (isKeyPressed[event.keyCode]){
isKeyPressed[event.keyCode] = false;
if (isCanPrintMessages){
trace(("Key up: " + event.keyCode));
};
i = 0;
while (i < KeyPressed.length) {
if (KeyPressed[i] == event.keyCode){
KeyPressed.splice(i, 1);
i--;
};
i++;
};
qPicProcessor.KeyIsUp(event.keyCode);
};
}
public static function IsKeyPressed(keyKode:uint):Boolean{
return (isKeyPressed[keyKode]);
}
public static function onKeyDown(event:KeyboardEvent):void{
if (!isKeyPressed[event.keyCode]){
isKeyPressed[event.keyCode] = true;
if (isCanPrintMessages){
trace(("Key down: " + event.keyCode));
};
KeyPressed.push(event.keyCode);
qPicProcessor.KeyIsDown(event.keyCode);
};
}
public static function onMouseKeyUp(event:MouseEvent):void{
var i:uint;
var keyCode:uint = qPicKeys.LMOUSE;
if (isKeyPressed[keyCode]){
isKeyPressed[keyCode] = false;
if (isCanPrintMessages){
trace(("Key up: " + keyCode));
};
i = 0;
while (i < KeyPressed.length) {
if (KeyPressed[i] == keyCode){
KeyPressed.splice(i, 1);
i--;
};
i++;
};
qPicProcessor.KeyIsUp(keyCode);
};
}
public static function ProcessingKeyPressed():void{
var i:uint;
while (i < KeyPressed.length) {
qPicProcessor.KeyIsStayDown(KeyPressed[i]);
i++;
};
}
public static function onMouseKeyDown(event:MouseEvent):void{
var keyCode:uint = qPicKeys.LMOUSE;
if (!isKeyPressed[keyCode]){
isKeyPressed[keyCode] = true;
if (isCanPrintMessages){
trace(("Key down: " + keyCode));
};
KeyPressed.push(keyCode);
qPicProcessor.KeyIsDown(keyCode);
};
}
}
}//package Engine
Section 3
//qPicKeys (Engine.qPicKeys)
package Engine {
public class qPicKeys {
public static const LEFT:uint = 37;
public static const SUBTRACT:uint = 109;
public static const MULTIPLY:uint = 106;
public static const SCRLOCK:uint = 145;
public static const DECIMAL:uint = 110;
public static const CONTROL:uint = 17;
public static const A:uint = 65;
public static const B:uint = 66;
public static const C:uint = 67;
public static const E:uint = 69;
public static const F:uint = 70;
public static const G:uint = 71;
public static const H:uint = 72;
public static const I:uint = 73;
public static const J:uint = 74;
public static const D:uint = 68;
public static const L:uint = 76;
public static const M:uint = 77;
public static const N:uint = 78;
public static const O:uint = 79;
public static const Q:uint = 81;
public static const S:uint = 83;
public static const U:uint = 85;
public static const P:uint = 80;
public static const R:uint = 82;
public static const T:uint = 84;
public static const V:uint = 86;
public static const X:uint = 88;
public static const Z:uint = 90;
public static const K:uint = 75;
public static const ESC:uint = 27;
public static const SPACEBAR:uint = 32;
public static const W:uint = 87;
public static const Y:uint = 89;
public static const BACKSPACE:uint = 8;
public static const SHIFT:uint = 16;
public static const TAB:uint = 9;
public static const DIVIDE:uint = 111;
public static const ADD:uint = 107;
public static const NUMPAD0:uint = 96;
public static const NUMPAD2:uint = 98;
public static const NUMPAD4:uint = 100;
public static const NUMPAD6:uint = 102;
public static const NUMPAD1:uint = 97;
public static const NUMPAD3:uint = 99;
public static const NUMPAD5:uint = 101;
public static const NUMPAD7:uint = 103;
public static const NUMPAD9:uint = 105;
public static const PAGEUP:uint = 33;
public static const UP:uint = 38;
public static const DOWN:uint = 40;
public static const NUMPAD8:uint = 104;
public static const UPER0:uint = 48;
public static const UPER1:uint = 49;
public static const UPER2:uint = 50;
public static const UPER3:uint = 51;
public static const UPER4:uint = 52;
public static const UPER5:uint = 53;
public static const UPER6:uint = 54;
public static const UPER7:uint = 55;
public static const UPER8:uint = 56;
public static const UPER9:uint = 57;
public static const ENTER:uint = 13;
public static const LMOUSE:uint = 1;
public static const END:uint = 35;
public static const PAGEDOWN:uint = 34;
public static const DELETE:uint = 46;
public static const INSERT:uint = 45;
public static const NUMLOCK:uint = 144;
public static const CAPSLOCK:uint = 20;
public static const PAUSE:uint = 19;
public static const HOME:uint = 36;
public static const RIGHT:uint = 39;
public function qPicKeys(){
super();
}
}
}//package Engine
Section 4
//qPicLoading (Engine.qPicLoading)
package Engine {
import flash.display.*;
public class qPicLoading {
public var IsCanRunGame:Boolean;// = true
public function qPicLoading(){
super();
}
public function Init(MainSprite:DisplayObject):void{
}
public function DeInit():void{
}
public function Update(percent:Number):void{
}
public function ProgressFinished():void{
}
}
}//package Engine
Section 5
//qPicMouse (Engine.qPicMouse)
package Engine {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.ui.*;
public class qPicMouse {
public static var Position:Point;
private static var IsCustomMouse:Boolean = false;
private static var CursorShift:Point;
public static var Direct:Point;
private static var Cursor:DisplayObjectContainer;
private static var IsInit:Boolean = false;
public function qPicMouse(){
super();
}
public static function Update():void{
if (!IsInit){
return;
};
Direct.x = (qPic.Scene.mouseX - Position.x);
Direct.y = (qPic.Scene.mouseY - Position.y);
Position.x = qPic.Scene.mouseX;
Position.y = qPic.Scene.mouseY;
if (IsCustomMouse){
Cursor.x = ((Position.x + CursorShift.x) + qPic.Scene.x);
Cursor.y = ((Position.y + CursorShift.y) + qPic.Scene.y);
};
}
private static function mouseClick(evt:Event):void{
Cursor.visible = true;
Mouse.hide();
}
private static function mouseBack(e:Event):void{
Cursor.visible = true;
Mouse.hide();
qPic.Scene.stage.removeEventListener(MouseEvent.MOUSE_MOVE, mouseBack);
}
public static function SetSystemCursor():void{
if (IsCustomMouse){
qPic.Scene.stage.addEventListener(MouseEvent.CLICK, mouseClick);
qPic.Scene.stage.addEventListener(Event.MOUSE_LEAVE, mouseLeave);
};
IsCustomMouse = false;
Mouse.show();
}
public static function Print():void{
trace(((("Mouse - " + Position.x) + ":") + Position.y));
trace(((("MDirect - " + Direct.x) + ":") + Direct.y));
}
public static function Start():void{
IsInit = true;
Position = new Point();
Direct = new Point();
}
public static function SetGameCursor(GameCursor:DisplayObjectContainer, ShiftX:Number=0, ShiftY:Number=0):void{
IsCustomMouse = true;
CursorShift = new Point(ShiftX, ShiftY);
Cursor = GameCursor;
Cursor.mouseEnabled = false;
Cursor.mouseChildren = false;
Mouse.hide();
qPic.Scene.stage.addEventListener(MouseEvent.CLICK, mouseClick);
qPic.Scene.stage.addEventListener(Event.MOUSE_LEAVE, mouseLeave);
}
private static function mouseLeave(e:Event):void{
Cursor.visible = false;
qPic.Scene.stage.addEventListener(MouseEvent.MOUSE_MOVE, mouseBack);
}
}
}//package Engine
Section 6
//qPicProcess (Engine.qPicProcess)
package Engine {
public class qPicProcess {
public function qPicProcess(){
super();
}
public function Init():void{
}
public function DeInit():void{
}
public function onKeyDown(key:uint):void{
}
public function Processing():void{
}
public function DeActivate():void{
}
public function sendSignal(sigType:Number, sigNum:Number):void{
}
public function Activate():void{
}
public function onKeyStayDown(key:uint):void{
}
public function onKeyUp(key:uint):void{
}
}
}//package Engine
Section 7
//qPicProcessor (Engine.qPicProcessor)
package Engine {
import flash.display.*;
import flash.text.*;
public class qPicProcessor {
private static var IsCanRun:Boolean = false;
private static var ActiveProcesses:Array;
private static var LockedUrl:Array = new Array();
private static var LockedGoToUrl:Array = new Array();
private static var Processes:Array;
public function qPicProcessor(){
super();
}
public static function Start():void{
var tfield:TextField;
var format:TextFormat;
var i:uint;
var ramka:Sprite;
qPic.ClearScene();
CheckIsCanRun();
if (IsCanRun){
ActiveProcesses = new Array();
Processes = new Array();
} else {
tfield = new TextField();
tfield.autoSize = TextFieldAutoSize.LEFT;
tfield.multiline = true;
format = new TextFormat();
format.align = "center";
format.size = 16;
tfield.defaultTextFormat = format;
tfield.htmlText = "Sorry, but this game can't run here.<br>Please, visite:";
i = 0;
while (i < LockedUrl.length) {
tfield.htmlText = (tfield.htmlText + (((("<a target=\"_blank\" href=\"http://" + LockedGoToUrl[i]) + "\">") + LockedUrl[i]) + "</a>"));
i++;
};
tfield.x = ((qPic.ScreenX - tfield.textWidth) / 2);
tfield.y = ((qPic.ScreenY - tfield.textHeight) / 2);
ramka = new Sprite();
ramka.graphics.lineStyle(1, 0);
ramka.graphics.beginFill(6399951);
ramka.graphics.lineTo((tfield.textWidth + 20), 0);
ramka.graphics.lineTo((tfield.textWidth + 20), (tfield.textHeight + 20));
ramka.graphics.lineTo(0, (tfield.textHeight + 20));
ramka.graphics.lineTo(0, 0);
ramka.graphics.endFill();
ramka.x = ((qPic.ScreenX - ramka.width) / 2);
ramka.y = ((qPic.ScreenY - ramka.height) / 2);
qPic.Scene.addChild(ramka);
qPic.Scene.addChild(tfield);
};
}
private static function DeleteFromProcesses(proc:qPicProcess):uint{
if (!IsCanRun){
return (0);
};
var result:uint;
var i:uint;
while (i < Processes.length) {
if (Processes[i] == proc){
Processes.splice(i, 1);
i--;
result++;
};
i++;
};
return (result);
}
public static function AddLockedUrl(url:String, gotourl:String=""):void{
LockedUrl.push(url);
LockedGoToUrl.push(gotourl);
IsCanRun = false;
}
public static function StartProcess(proc:qPicProcess):uint{
if (!IsCanRun){
return (0);
};
if (DeleteFromProcesses(proc) == 0){
proc.Init();
};
Processes.push(proc);
return ((Processes.length - 1));
}
public static function KeyIsDown(key:uint):void{
var i:uint;
if (!IsCanRun){
return;
};
while (i < ActiveProcesses.length) {
Processes[ActiveProcesses[i]].onKeyDown(key);
i++;
};
}
public static function KeyIsUp(key:uint):void{
var i:uint;
if (!IsCanRun){
return;
};
while (i < ActiveProcesses.length) {
Processes[ActiveProcesses[i]].onKeyUp(key);
i++;
};
}
public static function GetProcess(nProc:uint):qPicProcess{
return (Processes[nProc]);
}
public static function DeActivateProcess(nProc:uint):void{
if (!IsCanRun){
return;
};
if (nProc >= Processes.length){
return;
};
if (DeleteFromActiveProcesses(nProc) != 0){
Processes[nProc].DeActivate();
};
}
public static function ActivateProcess(nProc:uint):void{
if (!IsCanRun){
return;
};
if (nProc >= Processes.length){
return;
};
if (DeleteFromActiveProcesses(nProc) == 0){
Processes[nProc].Activate();
};
ActiveProcesses.unshift(nProc);
}
public static function Main():void{
if (!IsCanRun){
return;
};
qPicKeyListener.ProcessingKeyPressed();
var i:uint;
while (i < ActiveProcesses.length) {
Processes[ActiveProcesses[i]].Processing();
i++;
};
qPic.UpdateTime();
qPicMouse.Update();
}
public static function KeyIsStayDown(key:uint):void{
var i:uint;
if (!IsCanRun){
return;
};
while (i < ActiveProcesses.length) {
Processes[ActiveProcesses[i]].onKeyStayDown(key);
i++;
};
}
public static function StopProcess(nProc:uint):void{
if (!IsCanRun){
return;
};
if (nProc >= Processes.length){
return;
};
DeActivateProcess(nProc);
Processes[nProc].DeInit();
DeleteFromProcesses(Processes[nProc]);
}
private static function DeleteFromActiveProcesses(nProc:uint):uint{
if (!IsCanRun){
return (0);
};
var result:uint;
var i:uint;
while (i < ActiveProcesses.length) {
if (ActiveProcesses[i] == nProc){
ActiveProcesses.splice(i, 1);
i--;
result++;
};
i++;
};
return (result);
}
private static function CheckIsCanRun():void{
var i:uint;
if (LockedUrl.length == 0){
IsCanRun = true;
} else {
i = 0;
while ((((i < LockedUrl.length)) && (!(IsCanRun)))) {
if (LockedUrl[i] == qPic.Domain){
IsCanRun = true;
};
i++;
};
};
}
public static function DeleteLockedUrl(url:String):void{
var i:uint;
while (i < LockedUrl.length) {
if (LockedUrl[i] == url){
LockedUrl.splice(i, 1);
LockedGoToUrl.splice(i, 1);
i--;
};
i++;
};
}
}
}//package Engine
Section 8
//Figura (Games.tripline.Figures.Figura)
package Games.tripline.Figures {
import flash.display.*;
public class Figura extends Sprite {
protected var _Type:String;
protected var _Y:Number;
protected var isChose:Boolean;// = false
protected var _X:Number;
public function Figura(){
super();
}
public function filled():void{
}
public function GetChose():Boolean{
return (isChose);
}
public function GetType():String{
return (_Type);
}
public function SetChose(i:Boolean):void{
isChose = i;
}
public function chose():void{
}
}
}//package Games.tripline.Figures
Section 9
//Figura_Blue (Games.tripline.Figures.Figura_Blue)
package Games.tripline.Figures {
import flash.display.*;
import Games.tripline.*;
public class Figura_Blue extends Figura {
protected var _sprite:Sprite;
protected var _dispObj:DisplayObject;
public function Figura_Blue(){
super();
_Type = "blue";
_sprite = new Sprite();
var pic:DisplayObject = new Res.FiguraEmpty();
pic.width = Level.FigSize;
pic.height = Level.FigSize;
pic.x = (-(Level.FigSize) / 2);
pic.y = (-(Level.FigSize) / 2);
_sprite.addChild(pic);
_dispObj = new Res.FiguraBlue();
_dispObj.width = Level.FigSize;
_dispObj.height = Level.FigSize;
_dispObj.x = (-(Level.FigSize) / 2);
_dispObj.y = (-(Level.FigSize) / 2);
_sprite.addChild(_dispObj);
this.addChild(_sprite);
}
override public function filled():void{
}
override public function chose():void{
_sprite.removeChild(_dispObj);
isChose = true;
}
}
}//package Games.tripline.Figures
Section 10
//Figura_EmptyObject (Games.tripline.Figures.Figura_EmptyObject)
package Games.tripline.Figures {
import flash.display.*;
import Games.tripline.*;
public class Figura_EmptyObject extends Figura {
protected var _sprite:Sprite;
public function Figura_EmptyObject(){
super();
_Type = "empty";
_sprite = new Sprite();
var pic:DisplayObject = new Res.FiguraEmpty();
pic.width = Level.FigSize;
pic.height = Level.FigSize;
pic.x = (-(Level.FigSize) / 2);
pic.y = (-(Level.FigSize) / 2);
_sprite.addChild(pic);
this.addChild(_sprite);
}
}
}//package Games.tripline.Figures
Section 11
//Figura_Green (Games.tripline.Figures.Figura_Green)
package Games.tripline.Figures {
import flash.display.*;
import Games.tripline.*;
public class Figura_Green extends Figura {
protected var _sprite:Sprite;
protected var _dispObj:DisplayObject;
public function Figura_Green(){
super();
_Type = "green";
_sprite = new Sprite();
var pic:DisplayObject = new Res.FiguraEmpty();
pic.width = Level.FigSize;
pic.height = Level.FigSize;
pic.x = (-(Level.FigSize) / 2);
pic.y = (-(Level.FigSize) / 2);
_sprite.addChild(pic);
_dispObj = new Res.FiguraGreen();
_dispObj.width = Level.FigSize;
_dispObj.height = Level.FigSize;
_dispObj.x = (-(Level.FigSize) / 2);
_dispObj.y = (-(Level.FigSize) / 2);
_sprite.addChild(_dispObj);
this.addChild(_sprite);
}
override public function filled():void{
}
override public function chose():void{
_sprite.removeChild(_dispObj);
isChose = true;
}
public function GetRad():Number{
return (10);
}
}
}//package Games.tripline.Figures
Section 12
//Figura_MegaEmptyObject (Games.tripline.Figures.Figura_MegaEmptyObject)
package Games.tripline.Figures {
import flash.display.*;
public class Figura_MegaEmptyObject extends Figura {
protected var _sprite:Sprite;
public function Figura_MegaEmptyObject(){
super();
_Type = "empty";
_sprite = new Sprite();
this.addChild(_sprite);
}
}
}//package Games.tripline.Figures
Section 13
//Figura_Orange (Games.tripline.Figures.Figura_Orange)
package Games.tripline.Figures {
import flash.display.*;
import Games.tripline.*;
public class Figura_Orange extends Figura {
protected var _sprite:Sprite;
protected var _dispObj:DisplayObject;
public function Figura_Orange(){
super();
_Type = "orange";
_sprite = new Sprite();
var pic:DisplayObject = new Res.FiguraEmpty();
pic.width = Level.FigSize;
pic.height = Level.FigSize;
pic.x = (-(Level.FigSize) / 2);
pic.y = (-(Level.FigSize) / 2);
_sprite.addChild(pic);
_dispObj = new Res.FiguraOrange();
_dispObj.width = Level.FigSize;
_dispObj.height = Level.FigSize;
_dispObj.x = (-(Level.FigSize) / 2);
_dispObj.y = (-(Level.FigSize) / 2);
_sprite.addChild(_dispObj);
this.addChild(_sprite);
}
override public function filled():void{
}
override public function chose():void{
_sprite.removeChild(_dispObj);
isChose = true;
}
}
}//package Games.tripline.Figures
Section 14
//Figura_Wall (Games.tripline.Figures.Figura_Wall)
package Games.tripline.Figures {
import flash.display.*;
import Games.tripline.*;
public class Figura_Wall extends Figura {
private var _sprite:Sprite;
private var _dispObj:DisplayObject;
public function Figura_Wall(){
super();
_Type = "wall";
_sprite = new Sprite();
_dispObj = new Res.FiguraWall();
_dispObj.width = Level.FigSize;
_dispObj.height = Level.FigSize;
_dispObj.x = (-(Level.FigSize) / 2);
_dispObj.y = (-(Level.FigSize) / 2);
_sprite.addChild(_dispObj);
this.addChild(_sprite);
isChose = true;
}
}
}//package Games.tripline.Figures
Section 15
//TextLabel (Games.tripline.Other.TextLabel)
package Games.tripline.Other {
import flash.text.*;
import Games.tripline.*;
public class TextLabel extends TextField {
public function TextLabel(sizef:Number, col:Number){
super();
this.autoSize = TextFieldAutoSize.LEFT;
this.embedFonts = true;
this.multiline = true;
this.selectable = false;
var mFont:Font = (Res.MyEmbeddedFont as Font);
var TextLabelFormat:TextFormat = new TextFormat();
TextLabelFormat.color = col;
TextLabelFormat.font = "MyFontFamily";
TextLabelFormat.size = sizef;
TextLabelFormat.align = TextFormatAlign.CENTER;
this.defaultTextFormat = TextLabelFormat;
}
public function SetPos(posX:Number, posY:Number):void{
this.x = (posX - (this.width / 2));
this.y = (posY - (this.height / 2));
}
public function SetStrAndPos(str:String, posX:Number, posY:Number):void{
SetStr(str);
SetPos(posX, posY);
}
public function SetPosByCorner(px:Number, py:Number, cx:Number=0, cy:Number=0):void{
if (cx < -1){
cx = -1;
} else {
if (cx > 1){
cx = 1;
};
};
if (cy < -1){
cy = -1;
} else {
if (cy > 1){
cy = 1;
};
};
cx = ((cx + 1) / 2);
cy = ((cy + 1) / 2);
this.x = (px - (cx * this.width));
this.y = (py - (cy * this.height));
}
public function SetStr(str:String):void{
this.text = str;
}
}
}//package Games.tripline.Other
Section 16
//aPicInit (Games.tripline.aPicInit)
package Games.tripline {
import Engine.*;
import mochi.as3.*;
public class aPicInit {
public function aPicInit(){
super();
}
public static function Start():void{
qPic.Games["SponsorSplash"] = qPicProcessor.StartProcess(new GameBeforSponsor());
qPic.Games["Menu"] = qPicProcessor.StartProcess(new Menu());
qPic.Games["Game"] = qPicProcessor.StartProcess(new Game());
qPic.Games["LevelSelect"] = qPicProcessor.StartProcess(new LevelSelect());
qPic.Games["HighScores"] = qPicProcessor.StartProcess(new HighScoreScreen());
qPic.Games["SendScores"] = qPicProcessor.StartProcess(new SendScore());
qPicProcessor.ActivateProcess(qPic.Games["SponsorSplash"]);
}
public static function Locking():void{
}
}
}//package Games.tripline
Section 17
//aPicLoading (Games.tripline.aPicLoading)
package Games.tripline {
import flash.events.*;
import flash.display.*;
import flash.text.*;
import flash.geom.*;
import flash.utils.*;
import Engine.*;
import flash.net.*;
import flash.ui.*;
public class aPicLoading extends qPicLoading {
public var Color:Number;// = 4448255
private var DeltaTime:Number;
private var CurrentProcent:Number;
private var backGround:Sprite;
private var _loadingButton:Sprite;
private var Screen:Point;
private var StartedTime:Number;
private var _loadingStrip:Sprite;
public var MainDO:DisplayObject;
private var PlayButton:DisplayObject;
private var IsLoaded:Boolean;
private var gameLogo:DisplayObject;
public var BgColor:Number;// = 0
public static var GameLogoPicture:Class = aPicLoading_GameLogoPicture;
public static var BackPic:Class = aPicLoading_BackPic;
public static var PlayButtonPic:Class = aPicLoading_PlayButtonPic;
private static var TimeWait:Number = 1000;
public static var Pustota:Class = aPicLoading_Pustota;
public static var SponsorButtonPic:Class = aPicLoading_SponsorButtonPic;
public function aPicLoading(){
Screen = new Point(640, 480);
super();
}
public function PressStartButton(event:MouseEvent):void{
this.IsCanRunGame = true;
}
public function InMenuSomething(e:Event):Boolean{
var url:String = Labels.GoToSite;
var request:URLRequest = new URLRequest(url);
navigateToURL(request, "_blank");
return (true);
}
private function SetDefaultTextLabelSetting(tf:TextField, sizef:Number):void{
tf.autoSize = TextFieldAutoSize.LEFT;
tf.embedFonts = false;
tf.multiline = true;
tf.selectable = false;
var TextLabelFormat:TextFormat = new TextFormat();
TextLabelFormat.color = Color;
TextLabelFormat.font = "MyFontFamily";
TextLabelFormat.size = sizef;
TextLabelFormat.align = TextFormatAlign.CENTER;
tf.defaultTextFormat = TextLabelFormat;
}
private function SetTextLabelString(tf:TextField, str:String, posX:Number=-1, posY:Number=-1):void{
tf.text = str;
if (((!((posX == -1))) || (!((posY == -1))))){
tf.x = (posX - (tf.width / 2));
tf.y = (posY - (tf.height / 2));
};
}
override public function ProgressFinished():void{
IsLoaded = true;
}
override public function DeInit():void{
}
public function GoSponsorBaby(event:MouseEvent):void{
var url:String = Labels.GoToSite;
var request:URLRequest = new URLRequest(url);
navigateToURL(request, "_blank");
}
override public function Update(percent:Number):void{
CurrentProcent = percent;
}
public function Updating(e:Event):void{
if (DeltaTime <= TimeWait){
DeltaTime = (getTimer() - StartedTime);
};
if ((((DeltaTime >= TimeWait)) && (IsLoaded))){
PlayButton = new PlayButtonPic();
PlayButton.addEventListener(MouseEvent.CLICK, PressStartButton);
PlayButton.x = _loadingButton.x;
PlayButton.y = _loadingButton.y;
(MainDO as Sprite).addChild(PlayButton);
_loadingButton.visible = false;
(MainDO as Sprite).removeEventListener(Event.ENTER_FRAME, Updating);
};
var LinePercent:Number = Math.min(CurrentProcent, (DeltaTime / TimeWait));
var LineXdelta:Number = 15;
var LineHeight:Number = 5;
_loadingStrip.graphics.clear();
_loadingStrip.graphics.lineStyle(0, Color, 0);
_loadingStrip.graphics.beginFill(Color);
_loadingStrip.graphics.drawRect(LineXdelta, ((_loadingButton.height / 2) - (LineHeight / 2)), ((_loadingButton.width - (2 * LineXdelta)) * LinePercent), LineHeight);
_loadingStrip.graphics.endFill();
_loadingStrip.graphics.lineStyle(0, Color, 1);
_loadingStrip.graphics.drawRect(LineXdelta, ((_loadingButton.height / 2) - (LineHeight / 2)), (_loadingButton.width - (2 * LineXdelta)), LineHeight);
}
override public function Init(MainSprite:DisplayObject):void{
MainDO = MainSprite;
IsCanRunGame = false;
var MENU:ContextMenu = new ContextMenu();
MENU.hideBuiltInItems();
var Functioned1:ContextMenuItem = new ContextMenuItem("Visite sponsor site");
Functioned1.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, InMenuSomething);
var Functioned2:ContextMenuItem = new ContextMenuItem("www.gamesfree.com");
Functioned2.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, InMenuSomething);
MENU.customItems.push(Functioned1);
MENU.customItems.push(Functioned2);
(MainSprite.root as Object).contextMenu = MENU;
(MainDO as Sprite).addEventListener(Event.ENTER_FRAME, Updating);
backGround = new Sprite();
var Back:DisplayObject = new BackPic();
backGround.addChild(Back);
(MainDO as Sprite).addChild(backGround);
gameLogo = new GameLogoPicture();
gameLogo.x = ((Screen.x / 2) - (gameLogo.width / 2));
gameLogo.y = (((Screen.y / 2) - (gameLogo.height / 2)) - 40);
(MainDO as Sprite).addChild(gameLogo);
_loadingButton = new Pustota();
_loadingButton.y = ((gameLogo.y + gameLogo.height) + 20);
_loadingButton.x = ((Screen.x / 2) - (_loadingButton.width / 2));
_loadingStrip = new Sprite();
_loadingButton.addChild(_loadingStrip);
(MainDO as Sprite).addChild(_loadingButton);
var SponsorLogo:DisplayObject = new SponsorButtonPic();
SponsorLogo.addEventListener(MouseEvent.CLICK, GoSponsorBaby);
SponsorLogo.x = ((Screen.x - SponsorLogo.width) - 10);
SponsorLogo.y = 14;
(MainDO as Sprite).addChild(SponsorLogo);
StartedTime = getTimer();
DeltaTime = 0;
CurrentProcent = 0;
}
private function CreateMenuButton(str:String, sizef:Number, buttonFunct:Function=null):SimpleButton{
var tf:TextField;
var sb:SimpleButton = new SimpleButton();
tf = new TextField();
SetDefaultTextLabelSetting(tf, sizef);
SetTextLabelString(tf, str, 0, 0);
tf.alpha = 0.7;
if (buttonFunct == null){
tf.alpha = 0.25;
};
sb.upState = tf;
tf = new TextField();
SetDefaultTextLabelSetting(tf, sizef);
SetTextLabelString(tf, str, 0, 0);
if (buttonFunct == null){
tf.alpha = 0.25;
};
sb.overState = tf;
tf = new TextField();
SetDefaultTextLabelSetting(tf, sizef);
SetTextLabelString(tf, str, 0, 0);
tf.alpha = 0.9;
if (buttonFunct == null){
tf.alpha = 0.25;
};
sb.downState = tf;
sb.hitTestState = sb.overState;
if (buttonFunct != null){
sb.addEventListener(MouseEvent.CLICK, buttonFunct);
};
return (sb);
}
}
}//package Games.tripline
Section 18
//aPicLoading_BackPic (Games.tripline.aPicLoading_BackPic)
package Games.tripline {
import mx.core.*;
public class aPicLoading_BackPic extends BitmapAsset {
}
}//package Games.tripline
Section 19
//aPicLoading_GameLogoPicture (Games.tripline.aPicLoading_GameLogoPicture)
package Games.tripline {
import mx.core.*;
import flash.utils.*;
public class aPicLoading_GameLogoPicture extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function aPicLoading_GameLogoPicture(){
dataClass = aPicLoading_GameLogoPicture_dataClass;
super();
initialWidth = (5180 / 20);
initialHeight = (3860 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 20
//aPicLoading_GameLogoPicture_dataClass (Games.tripline.aPicLoading_GameLogoPicture_dataClass)
package Games.tripline {
import mx.core.*;
public class aPicLoading_GameLogoPicture_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 21
//aPicLoading_PlayButtonPic (Games.tripline.aPicLoading_PlayButtonPic)
package Games.tripline {
import mx.core.*;
import flash.utils.*;
public class aPicLoading_PlayButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function aPicLoading_PlayButtonPic(){
dataClass = aPicLoading_PlayButtonPic_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (800 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 22
//aPicLoading_PlayButtonPic_dataClass (Games.tripline.aPicLoading_PlayButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class aPicLoading_PlayButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 23
//aPicLoading_Pustota (Games.tripline.aPicLoading_Pustota)
package Games.tripline {
import mx.core.*;
import flash.utils.*;
public class aPicLoading_Pustota extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function aPicLoading_Pustota(){
dataClass = aPicLoading_Pustota_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 24
//aPicLoading_Pustota_dataClass (Games.tripline.aPicLoading_Pustota_dataClass)
package Games.tripline {
import mx.core.*;
public class aPicLoading_Pustota_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 25
//aPicLoading_SponsorButtonPic (Games.tripline.aPicLoading_SponsorButtonPic)
package Games.tripline {
import mx.core.*;
import flash.utils.*;
public class aPicLoading_SponsorButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function aPicLoading_SponsorButtonPic(){
dataClass = aPicLoading_SponsorButtonPic_dataClass;
super();
initialWidth = (940 / 20);
initialHeight = (940 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 26
//aPicLoading_SponsorButtonPic_dataClass (Games.tripline.aPicLoading_SponsorButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class aPicLoading_SponsorButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 27
//Button (Games.tripline.Button)
package Games.tripline {
import flash.display.*;
import flash.text.*;
public class Button extends SimpleButton {
private var _text:String;// = "button"
private var _fontSize:int;
private var _tf:TextField;
public var userData:Object;// = null
public function Button(text:String, size:int):void{
super();
_text = text;
_fontSize = size;
upState = CreateUpState();
overState = CreateOverState();
downState = CreateDownState();
hitTestState = upState;
}
private function CreateDownState():Sprite{
var _sprite:Sprite = new Sprite();
_tf = new TextField();
_tf = SetText(_text, 4448255);
_sprite.addChild(_tf);
_sprite.alpha = 1;
_tf.x = (_tf.x + 2);
_tf.y = (_tf.y + 2);
return (_sprite);
}
private function CreateOverState():Sprite{
var _sprite:Sprite = new Sprite();
_sprite.addChild(SetText(_text, 4448255));
_sprite.alpha = 0.9;
return (_sprite);
}
public function GetText():String{
return (_text);
}
public function SetText(str:String, textcolor:Number):TextField{
var formatter:TextFormat;
formatter = new TextFormat();
formatter.font = "MyFontFamily";
formatter.size = _fontSize;
formatter.color = textcolor;
var mFont:Font = (Res.MyEmbeddedFont as Font);
_tf = new TextField();
_tf.text = str;
_tf.autoSize = TextFieldAutoSize.LEFT;
_tf.setTextFormat(formatter);
_tf.embedFonts = true;
return (_tf);
}
public function SetNewText(str:String):void{
_text = str;
}
public function UnLockButton():void{
hitTestState = upState;
}
private function CreateUpState():Sprite{
var _sprite:Sprite = new Sprite();
_sprite.addChild(SetText(_text, 11773837));
_sprite.alpha = 0.7;
return (_sprite);
}
public function LockButton():void{
hitTestState = null;
}
}
}//package Games.tripline
Section 28
//ButtonWithPic (Games.tripline.ButtonWithPic)
package Games.tripline {
import Engine.*;
import flash.display.*;
import flash.events.*;
public class ButtonWithPic extends SimpleButton {
public var ReverseBut:ButtonWithPic;
private var _ButType:String;
public function ButtonWithPic(buttonType:String, posX:Number, posY:Number){
super();
_ButType = buttonType;
if (_ButType == "MusicOn"){
ReverseBut = new ButtonWithPic("MusicOff", posX, posY);
};
if (_ButType == "SoundOn"){
ReverseBut = new ButtonWithPic("SoundOff", posX, posY);
};
if (ReverseBut != null){
ReverseBut.ReverseBut = this;
};
upState = CreateUpState();
overState = CreateOverState();
downState = CreateDownState();
hitTestState = upState;
this.x = posX;
this.y = posY;
this.addEventListener(MouseEvent.CLICK, onSoundButtonClick);
}
private function CreateOverState():Sprite{
var _sprite:Sprite = new Sprite();
var CopyPic:DisplayObject = GetPicture(_ButType);
_sprite.addChild(CopyPic);
_sprite.alpha = 0.9;
return (_sprite);
}
private function CreateDownState():Sprite{
var _sprite:Sprite = new Sprite();
var CopyPic:DisplayObject = GetPicture(_ButType);
_sprite.addChild(CopyPic);
_sprite.alpha = 1;
_sprite.x = (_sprite.x + 2);
_sprite.y = (_sprite.y + 2);
return (_sprite);
}
private function CreateUpState():Sprite{
var _sprite:Sprite = new Sprite();
var CopyPic:DisplayObject = GetPicture(_ButType);
_sprite.addChild(CopyPic);
_sprite.alpha = 0.7;
return (_sprite);
}
public function onSoundButtonClick(event:MouseEvent):void{
if (_ButType == "MusicOn"){
Menu.GameMusicVolume = 0;
};
if (_ButType == "MusicOff"){
Menu.GameMusicVolume = 1;
};
if (_ButType == "SoundOn"){
Menu.GameEffectsVolume = 0;
};
if (_ButType == "SoundOff"){
Menu.GameEffectsVolume = 1;
};
this.parent.addChildAt(ReverseBut, this.parent.getChildIndex(this));
this.parent.removeChild(this);
if (this == Menu.MusicButton){
Menu.MusicButton = ReverseBut;
} else {
Menu.EffectsButton = ReverseBut;
};
Menu.UpdateMusic();
qPic.FocusScene();
}
public function GetPicture(buttonType:String):DisplayObject{
var Pic:DisplayObject;
var koef:Number = 0.5;
if (buttonType == "MusicOn"){
Pic = new Res.musicOn();
Pic.scaleX = koef;
Pic.scaleY = koef;
} else {
if (buttonType == "MusicOff"){
Pic = new Res.musicOff();
Pic.scaleX = koef;
Pic.scaleY = koef;
} else {
if (buttonType == "SoundOn"){
Pic = new Res.soundOn();
Pic.scaleX = koef;
Pic.scaleY = koef;
} else {
if (buttonType == "SoundOff"){
Pic = new Res.soundOff();
Pic.scaleX = koef;
Pic.scaleY = koef;
};
};
};
};
return (Pic);
}
}
}//package Games.tripline
Section 29
//Game (Games.tripline.Game)
package Games.tripline {
import Engine.*;
import flash.display.*;
import flash.events.*;
import flash.media.*;
import flash.geom.*;
import flash.net.*;
public class Game extends qPicProcess {
public var ScoreBack:DisplayObjectContainer;
public var ArrowDelay:Number;// = 0
public var solutionBut:DisplayObject;
public var AttCurScale:Number;
public var HelpTime:Number;
public var AttCurDirect:Number;
protected var LabelScore:DisplayObject;
public var Helping:DisplayObject;
public var menuBut:DisplayObject;
public var NextLevelTime:Number;
public var NextLevelTimeMax:Number;// = 300
public var level1:Level;
protected var LabelScorePrivious:DisplayObject;
protected var HelpLine:DisplayObject;
public var nextLevBut:DisplayObject;
public var restartBut:DisplayObject;
public var PrevScore:Number;
public static var MrBobHaveOrangeOne:int = 9;
public static var _mode:String = "easy";
public static var MrBobNeedNewEmpty:int = 0;
public static var LevelReady:Boolean = false;
public static var MrBobHaveGreenTwo:int = 8;
public static var AngleEnd:Number = 0;
private static var MrBob:Array;
public static var ScoreLevel:Number = 0;
public static var PictureForRotation:DisplayObject = null;
public static var MrBobHaveBlueTwo:int = 6;
public static var MrBobHaveGreenOne:int = 7;
public static var MrBobHaveError:int = 4;
public static var MrBobNeedNewOrange:int = 3;
private static var MrBobState:int = 0;
public static var MrBobNeedNewGreen:int = 2;
public static var CurrLevelNumber:int = 1;
public static var PointEnd:Point = null;
public static var maxTime:Number = 250;
public static var MrBobHaveBlueOne:int = 5;
public static var ScaleStart:Number = 0;
public static var PointStart:Point = null;
public static var MrBobNeedNewBlue:int = 1;
public static var MrBobHaveOrangeTwo:int = 10;
public static var ScaleEnd:Number = 0;
public static var Time:Number = 500;
public static var OutFiguresTime:Number = 0;
public static var AngleStart:Number = 0;
public static var IsNeedAttention:Boolean;
public static var PictureForScale:DisplayObject;
public function Game(){
super();
}
override public function onKeyDown(key:uint):void{
var _local3:SoundChannel;
var NeedUpdateScore = !(level1.IsLevelDone());
switch (key){
case qPicKeys.LMOUSE:
_local3 = new Res.MouseClick().play(0, 1);
_local3.soundTransform = new SoundTransform((0.5 * Menu.GameEffectsVolume));
if (((!((Helping == null))) && ((Helping.scaleX >= 1)))){
qPic.Scene.removeChild(Helping);
Helping = null;
};
break;
case qPicKeys.R:
onMouseClickRestart(null);
break;
case qPicKeys.ENTER:
onMouseClickNext(null);
break;
case qPicKeys.W:
case qPicKeys.UP:
if (Helping == null){
KeyboardControl.Pressed(KeyboardControl.UP);
};
ArrowDelay = 0;
break;
case qPicKeys.S:
case qPicKeys.DOWN:
if (Helping == null){
KeyboardControl.Pressed(KeyboardControl.DOWN);
};
ArrowDelay = 0;
break;
case qPicKeys.A:
case qPicKeys.LEFT:
if (Helping == null){
KeyboardControl.Pressed(KeyboardControl.LEFT);
};
ArrowDelay = 0;
break;
case qPicKeys.D:
case qPicKeys.RIGHT:
if (Helping == null){
KeyboardControl.Pressed(KeyboardControl.RIGHT);
};
ArrowDelay = 0;
break;
};
if (NeedUpdateScore){
UpdateScores();
};
}
override public function onKeyUp(key:uint):void{
if (key == qPicKeys.LMOUSE){
level1.IsNeedMoveAuto = false;
};
switch (key){
case qPicKeys.W:
case qPicKeys.UP:
KeyboardControl.UnPressed(KeyboardControl.UP);
break;
case qPicKeys.S:
case qPicKeys.DOWN:
KeyboardControl.UnPressed(KeyboardControl.DOWN);
break;
case qPicKeys.A:
case qPicKeys.LEFT:
KeyboardControl.UnPressed(KeyboardControl.LEFT);
break;
case qPicKeys.D:
case qPicKeys.RIGHT:
KeyboardControl.UnPressed(KeyboardControl.RIGHT);
break;
};
}
public function onMouseClickNext(event:MouseEvent):void{
if (((level1.IsLevelDone()) && ((CurrLevelNumber < Menu.Save.NumOfLevels(_mode))))){
CurrLevelNumber++;
qPic.FocusScene();
Activate();
};
}
public function onMouseClickSend(event:MouseEvent):void{
qPicProcessor.ActivateProcess(qPic.Games["SendScores"]);
qPicProcessor.DeActivateProcess(qPic.Games["Game"]);
qPic.FocusScene();
}
public function onSolutionClick(event:MouseEvent):void{
var url:String = Labels.GoToSolution;
var request:URLRequest = new URLRequest(url);
navigateToURL(request, "_blank");
}
override public function Activate():void{
var connector:DisplayObject;
var decor:DisplayObject;
var ScorePrevBack:DisplayObject;
PointEnd = null;
SetMrBob(MrBobNeedNewEmpty);
Menu.Save.SaveContinue(_mode, CurrLevelNumber);
ScoreLevel = (10000 + (CurrLevelNumber * 200));
qPic.ClearScene();
if (_mode == "easy"){
level1 = new Level();
} else {
if (_mode == "hard"){
level1 = new LevelHard();
};
};
level1.CreateLevel(CurrLevelNumber);
PointEnd = new Point(level1._cursor.x, level1._cursor.y);
if (Menu.Save.IsLevelDone(_mode, CurrLevelNumber)){
ScorePrevBack = new Res.ScoreBoard();
ScorePrevBack.width = (ScorePrevBack.width * 1.1);
ScorePrevBack.height = (ScorePrevBack.height * 0.75);
ScorePrevBack.x = (qPic.ScreenHalfX - ((ScorePrevBack.width * 1.1) / 2));
ScorePrevBack.y = ((qPic.ScreenY - 20) - ((ScorePrevBack.height * 0.75) / 2));
qPic.Scene.addChild(ScorePrevBack);
LabelScorePrivious = LevelSelect.CreateLabel(("Best score: " + Menu.Save.GetLevelScore(_mode, CurrLevelNumber).toString()), 15);
LabelScorePrivious.x = (qPic.ScreenHalfX - (LabelScorePrivious.width / 2));
LabelScorePrivious.y = ((qPic.ScreenY - 20) - (LabelScorePrivious.height / 2));
qPic.Scene.addChild(LabelScorePrivious);
};
ScoreBack = new Res.ScoreBoard();
ScoreBack.width = (ScoreBack.width * 1.5);
ScoreBack.x = (qPic.ScreenHalfX - ((ScoreBack.width * 1.5) / 2));
ScoreBack.y = ((qPic.ScreenY - 50) - (ScoreBack.height / 2));
qPic.Scene.addChild(ScoreBack);
connector = new Res.ButtonConnector();
connector.scaleX = 1.5;
connector.scaleY = 1.5;
connector.x = (ScoreBack.x + (ScoreBack.width * 1.5));
connector.y = (ScoreBack.y + ((42 - (27 * 1.5)) / 2));
qPic.Scene.addChild(connector);
connector = new Res.ButtonConnector();
connector.scaleX = -1.5;
connector.scaleY = 1.5;
connector.x = ScoreBack.x;
connector.y = (ScoreBack.y + ((42 - (27 * 1.5)) / 2));
qPic.Scene.addChild(connector);
onKeyDown(qPicKeys.SPACEBAR);
nextLevBut = new Res.NextLevelButtonPic();
nextLevBut.scaleX = 1.5;
nextLevBut.scaleY = 1.5;
nextLevBut.x = qPic.ScreenX;
nextLevBut.y = (qPic.ScreenHalfY - ((nextLevBut.height * 1.5) / 2));
nextLevBut.addEventListener(MouseEvent.CLICK, onMouseClickNext);
var koef:Number = 0.75;
restartBut = new Res.RestartButtonPic();
restartBut.addEventListener(MouseEvent.CLICK, onMouseClickRestart);
restartBut.scaleX = koef;
restartBut.scaleY = koef;
restartBut.x = ((qPic.ScreenX - (restartBut.width * koef)) - 10);
restartBut.y = ((qPic.ScreenY - (restartBut.height * koef)) - 10);
qPic.Scene.addChild(restartBut);
connector = new Res.ButtonConnector();
connector.scaleX = koef;
connector.scaleY = koef;
connector.x = (restartBut.x + (restartBut.width * koef));
connector.y = (restartBut.y + (((42 - 27) * koef) / 2));
qPic.Scene.addChild(connector);
connector = new Res.ButtonConnector();
connector.scaleX = -(koef);
connector.scaleY = koef;
connector.x = restartBut.x;
connector.y = (restartBut.y + (((42 - 27) * koef) / 2));
qPic.Scene.addChild(connector);
menuBut = new Res.MenuButtonPic();
menuBut.addEventListener(MouseEvent.CLICK, onMouseClickMenu);
menuBut.x = 10;
menuBut.y = 10;
menuBut.scaleX = koef;
menuBut.scaleY = koef;
qPic.Scene.addChild(menuBut);
connector = new Res.ButtonConnector();
connector.scaleX = koef;
connector.scaleY = koef;
connector.x = (menuBut.x + (menuBut.width * koef));
connector.y = (menuBut.y + (((42 - 27) * koef) / 2));
qPic.Scene.addChild(connector);
connector = new Res.ButtonConnector();
connector.scaleX = -(koef);
connector.scaleY = koef;
connector.x = menuBut.x;
connector.y = ((menuBut.y + (((42 - 27) * koef) / 2)) - ((menuBut.height + 15) * koef));
qPic.Scene.addChild(connector);
solutionBut = new Res.SolutionButtonPic();
solutionBut.addEventListener(MouseEvent.CLICK, onSolutionClick);
solutionBut.scaleX = koef;
solutionBut.scaleY = koef;
solutionBut.x = menuBut.x;
solutionBut.y = ((menuBut.x + (menuBut.height * koef)) + (15 * koef));
qPic.Scene.addChild(solutionBut);
qPic.Scene.addChild(Menu.EffectsButton);
qPic.Scene.addChild(Menu.MusicButton);
qPic.Scene.addChild(Menu.SponsorMiniButton);
decor = new Res.Gears();
decor.x = 0;
decor.y = (qPic.ScreenY - decor.height);
qPic.Scene.addChild(decor);
var i:int;
while (i < MrBob.length) {
qPic.Scene.addChild(MrBob[i]);
i++;
};
decor = new Res.Locker();
decor.x = (180 - decor.width);
decor.y = (qPic.ScreenY - decor.height);
qPic.Scene.addChild(decor);
if ((((CurrLevelNumber <= 1)) || ((((CurrLevelNumber <= 3)) && ((_slot1._mode == "easy")))))){
koef = 0;
if (CurrLevelNumber == 1){
Helping = new Res.HelpTipLev1();
};
if (CurrLevelNumber == 2){
Helping = new Res.HelpTipLev2();
};
if (CurrLevelNumber == 3){
Helping = new Res.HelpTipLev3();
};
if (_slot1._mode != "easy"){
Helping = new Res.HelpTipHard();
};
Helping.scaleX = koef;
Helping.scaleY = koef;
Helping.x = (qPic.ScreenHalfX - ((Helping.width * koef) / 2));
Helping.y = (qPic.ScreenHalfY - ((Helping.height * koef) / 2));
qPic.Scene.addChild(Helping);
HelpTime = 0;
} else {
Helping = null;
};
PrevScore = 0;
qPic.FocusScene();
Menu.PlayGameMusic();
IsNeedAttention = (CurrLevelNumber == 1);
if (IsNeedAttention){
AttCurScale = 1;
AttCurDirect = 1;
};
}
public function onMouseClickRestart(event:MouseEvent):void{
if (CurrLevelNumber <= Menu.Save.NumOfLevels(_mode)){
Activate();
qPic.FocusScene();
};
}
public function UpdateScores():void{
if (CurrLevelNumber <= Menu.Save.NumOfLevels(_mode)){
if (LabelScore != null){
if (LabelScore.parent != null){
LabelScore.parent.removeChild(LabelScore);
};
};
LabelScore = LevelSelect.CreateLabel(("Score: " + ScoreLevel.toString()), 20);
qPic.Scene.addChild(LabelScore);
LabelScore.x = (qPic.ScreenHalfX - (LabelScore.width / 2));
LabelScore.y = ((qPic.ScreenY - 50) - (LabelScore.height / 2));
};
}
public function onMouseClickMenu(event:MouseEvent):void{
qPicProcessor.ActivateProcess(qPic.Games["Menu"]);
qPicProcessor.DeActivateProcess(qPic.Games["Game"]);
qPic.FocusScene();
}
override public function Init():void{
MrBob = new Array();
MrBob.push(new Res.BobNewEmpty());
MrBob.push(new Res.BobNewBlue());
MrBob.push(new Res.BobNewGreen());
MrBob.push(new Res.BobNewOrange());
MrBob.push(new Res.BobError());
MrBob.push(new Res.BobHaveBlue1());
MrBob.push(new Res.BobHaveBlue2());
MrBob.push(new Res.BobHaveGreen1());
MrBob.push(new Res.BobHaveGreen2());
MrBob.push(new Res.BobHaveOrange1());
MrBob.push(new Res.BobHaveOrange2());
var i:int;
while (i < MrBob.length) {
MrBob[i].x = (180 - MrBob[i].width);
MrBob[i].y = (qPic.ScreenY - MrBob[i].height);
i++;
};
SetMrBob(MrBobNeedNewEmpty);
}
override public function Processing():void{
var helpkoef:Number;
var CenterPoint:Point;
var Board:DisplayObject;
var GamiLogo:DisplayObject;
var TotalScore:Number;
var Label:DisplayObject;
var Label2:DisplayObject;
var ButtonBack:DisplayObject;
var connector:DisplayObject;
if (ArrowDelay > 0){
ArrowDelay = (ArrowDelay - qPic.FrameTime);
};
if (IsNeedAttention){
AttCurScale = (AttCurScale + (AttCurDirect * qPic.SiT(2)));
if (AttCurScale >= 1.5){
AttCurScale = 1.5;
AttCurDirect = -1;
};
if (AttCurScale <= 1){
AttCurScale = 1;
AttCurDirect = 1;
};
level1._cursor.scaleX = AttCurScale;
level1._cursor.scaleY = AttCurScale;
};
level1.CheckDrag();
if (ScoreLevel != PrevScore){
PrevScore = ScoreLevel;
UpdateScores();
};
if (Helping != null){
HelpTime = (HelpTime + qPic.FrameTime);
helpkoef = ((HelpTime * 2) / 1000);
if (helpkoef > 1.5){
helpkoef = 1.5;
};
Helping.scaleX = helpkoef;
Helping.scaleY = helpkoef;
Helping.x = (qPic.ScreenHalfX - (Helping.width / 2));
Helping.y = (qPic.ScreenHalfY - (Helping.height / 2));
};
if (nextLevBut.parent != null){
if (NextLevelTime < NextLevelTimeMax){
NextLevelTime = (NextLevelTime + qPic.FrameTime);
if (NextLevelTime > NextLevelTimeMax){
NextLevelTime = NextLevelTimeMax;
};
nextLevBut.x = (qPic.ScreenX + (((-(nextLevBut.width) - 10) * NextLevelTime) / NextLevelTimeMax));
};
};
if ((((((MrBobState == MrBobNeedNewBlue)) || ((MrBobState == MrBobNeedNewGreen)))) || ((MrBobState == MrBobNeedNewOrange)))){
OutFiguresTime = (OutFiguresTime + qPic.FrameTime);
if (OutFiguresTime >= 1000){
SetMrBob(MrBobNeedNewEmpty);
};
} else {
OutFiguresTime = 0;
};
if (Time < maxTime){
if (Math.abs((AngleEnd - AngleStart)) > 90){
if (AngleEnd < 0){
AngleEnd = (AngleEnd + 360);
};
if (AngleStart < 0){
AngleStart = (AngleStart + 360);
};
};
Time = (Time + qPic.FrameTime);
if (Time > maxTime){
Time = maxTime;
};
PictureForRotation.rotation = AngleEnd;
PictureForRotation.x = (PointStart.x + (((PointEnd.x - PointStart.x) * Time) / maxTime));
PictureForRotation.y = (PointStart.y + (((PointEnd.y - PointStart.y) * Time) / maxTime));
PictureForScale.scaleY = (ScaleStart + (((ScaleEnd - ScaleStart) * Time) / maxTime));
};
if ((((((nextLevBut.parent == null)) && (level1.IsLevelDone()))) && ((CurrLevelNumber < Menu.Save.NumOfLevels(_mode))))){
qPic.Scene.addChild(nextLevBut);
NextLevelTime = 0;
};
if (((((!((restartBut.parent == null))) && (level1.IsLevelDone()))) && ((CurrLevelNumber == Menu.Save.NumOfLevels(_mode))))){
qPic.ClearScene();
CenterPoint = new Point(qPic.ScreenHalfX, (qPic.ScreenHalfY + 50));
Board = new Res.SelectLevelBack();
Board.x = (CenterPoint.x - (Board.width / 2));
Board.scaleY = 0.75;
Board.y = (CenterPoint.y - ((Board.height * 0.75) / 2));
qPic.Scene.addChild(Board);
GamiLogo = new Res.GameLogo();
GamiLogo.x = (CenterPoint.x - (GamiLogo.width / 2));
GamiLogo.y = ((Board.y - (GamiLogo.height / 2)) - 60);
qPic.Scene.addChild(GamiLogo);
TotalScore = Menu.Save.TotalScore(_mode);
Label = LevelSelect.CreateLabel("WIN!", 100);
Label2 = LevelSelect.CreateLabel(("Total score: " + TotalScore.toString()), 30);
ButtonBack = new Res.SendButtonPic();
ButtonBack.x = (qPic.ScreenHalfX - (ButtonBack.width / 2));
ButtonBack.y = 420;
qPic.Scene.addChild(ButtonBack);
connector = new Res.ButtonConnector();
connector.x = (ButtonBack.x + ButtonBack.width);
connector.y = (ButtonBack.y + ((42 - 27) / 2));
qPic.Scene.addChild(connector);
connector = new Res.ButtonConnector();
connector.scaleX = -1;
connector.x = ButtonBack.x;
connector.y = (ButtonBack.y + ((42 - 27) / 2));
qPic.Scene.addChild(connector);
Label.x = (CenterPoint.x - (Label.width / 2));
Label.y = ((CenterPoint.y - 30) - (Label.height / 2));
Label2.x = (CenterPoint.x - (Label2.width / 2));
Label2.y = (((Label.y + Label.height) + 30) - (Label2.height / 2));
qPic.Scene.addChild(Label);
qPic.Scene.addChild(Label2);
ButtonBack.addEventListener(MouseEvent.CLICK, onMouseClickSend);
Menu.Save.ClearContinue();
};
}
override public function onKeyStayDown(key:uint):void{
if (ArrowDelay <= 0){
ArrowDelay = 250;
switch (KeyboardControl.GetCurr()){
case KeyboardControl.UP:
level1.Move_Up();
break;
case KeyboardControl.DOWN:
level1.Move_Down();
break;
case KeyboardControl.LEFT:
level1.Move_Left();
break;
case KeyboardControl.RIGHT:
level1.Move_Right();
break;
};
};
}
public static function SetMrBob(state:int):void{
var prev:DisplayObject;
var sChannel:SoundChannel;
MrBobState = state;
if ((((((MrBobState == MrBobNeedNewBlue)) || ((MrBobState == MrBobNeedNewGreen)))) || ((MrBobState == MrBobNeedNewOrange)))){
prev = MrBob[MrBobState];
if (MrBobState == MrBobNeedNewBlue){
MrBob[MrBobState] = new Res.BobNewBlue();
};
if (MrBobState == MrBobNeedNewGreen){
MrBob[MrBobState] = new Res.BobNewGreen();
};
if (MrBobState == MrBobNeedNewOrange){
MrBob[MrBobState] = new Res.BobNewOrange();
};
MrBob[MrBobState].x = prev.x;
MrBob[MrBobState].y = prev.y;
qPic.Scene.addChildAt(MrBob[MrBobState], qPic.Scene.getChildIndex(MrBob[MrBobNeedNewEmpty]));
} else {
if (MrBob[MrBobNeedNewBlue].parent != null){
MrBob[MrBobNeedNewBlue].parent.removeChild(MrBob[MrBobNeedNewBlue]);
};
if (MrBob[MrBobNeedNewGreen].parent != null){
MrBob[MrBobNeedNewGreen].parent.removeChild(MrBob[MrBobNeedNewGreen]);
};
if (MrBob[MrBobNeedNewOrange].parent != null){
MrBob[MrBobNeedNewOrange].parent.removeChild(MrBob[MrBobNeedNewOrange]);
};
};
if (MrBobState == MrBobHaveError){
sChannel = new Res.GemError().play(0, 1);
sChannel.soundTransform = new SoundTransform((2 * Menu.GameEffectsVolume));
};
MrBob[MrBobState].visible = true;
var i:int;
while (i < MrBob.length) {
MrBob[i].visible = (MrBobState == i);
i++;
};
}
public static function GetScoreLevel():Number{
return (ScoreLevel);
}
public static function SetScoreLevel(n:Number):void{
if (n >= 0){
ScoreLevel = n;
};
}
}
}//package Games.tripline
Section 30
//GameBeforSponsor (Games.tripline.GameBeforSponsor)
package Games.tripline {
import Engine.*;
import flash.display.*;
import flash.events.*;
import flash.net.*;
public class GameBeforSponsor extends qPicProcess {
public var SplashingButton:SimpleButton;
public var Splashing:DisplayObject;
public var CurrTime:Number;// = -1
public function GameBeforSponsor(){
super();
}
public function GoSponsorBaby(event:MouseEvent):void{
var url:String = Labels.GoToSite;
var request:URLRequest = new URLRequest(url);
navigateToURL(request, "_blank");
}
override public function Init():void{
var pic:Sprite = new Sprite();
var g:Graphics = pic.graphics;
g.beginFill(0xFFFFFF, 0);
g.lineStyle(0, 0, 0);
g.drawRect(0, 0, qPic.ScreenX, qPic.ScreenY);
g.endFill();
SplashingButton = new SimpleButton();
SplashingButton.upState = pic;
SplashingButton.downState = SplashingButton.upState;
SplashingButton.overState = SplashingButton.upState;
SplashingButton.hitTestState = SplashingButton.upState;
SplashingButton.addEventListener(MouseEvent.CLICK, GoSponsorBaby);
Splashing = new Res.Splash();
}
override public function Processing():void{
if (CurrTime >= 0){
CurrTime = (CurrTime + qPic.FrameTime);
};
if (CurrTime >= 5500){
qPicProcessor.DeActivateProcess(qPic.Games["SponsorSplash"]);
qPicProcessor.ActivateProcess(qPic.Games["Menu"]);
};
if (CurrTime < 0){
CurrTime = 0;
};
}
override public function DeActivate():void{
if (Splashing.parent != null){
Splashing.parent.removeChild(Splashing);
};
if (SplashingButton.parent != null){
SplashingButton.parent.removeChild(SplashingButton);
};
Splashing = null;
}
override public function Activate():void{
qPic.SceneFront.addChild(Splashing);
qPic.SceneFront.addChild(SplashingButton);
}
}
}//package Games.tripline
Section 31
//HighScoreScreen (Games.tripline.HighScoreScreen)
package Games.tripline {
import Engine.*;
import flash.display.*;
import flash.events.*;
import Games.tripline.Other.*;
import flash.media.*;
import flash.geom.*;
import flash.net.*;
import flash.system.*;
public class HighScoreScreen extends qPicProcess {
public var IsPrintedScores:Boolean;// = false
public var TopPlayersName:Array;
public var menuBut:DisplayObject;
public var TopPlayersScores:Array;
public var IsLoadedScores:Boolean;// = false
public function HighScoreScreen(){
TopPlayersName = [];
TopPlayersScores = [];
super();
}
public function handleComplete(event:Event):void{
var loader:URLLoader = URLLoader(event.target);
if (loader.data.name1 != null){
TopPlayersName[1] = loader.data.name1;
};
if (loader.data.score1 != null){
TopPlayersScores[1] = loader.data.score1;
};
if (loader.data.name2 != null){
TopPlayersName[2] = loader.data.name2;
};
if (loader.data.score2 != null){
TopPlayersScores[2] = loader.data.score2;
};
if (loader.data.name3 != null){
TopPlayersName[3] = loader.data.name3;
};
if (loader.data.score3 != null){
TopPlayersScores[3] = loader.data.score3;
};
if (loader.data.name4 != null){
TopPlayersName[4] = loader.data.name4;
};
if (loader.data.score4 != null){
TopPlayersScores[4] = loader.data.score4;
};
if (loader.data.name5 != null){
TopPlayersName[5] = loader.data.name5;
};
if (loader.data.score5 != null){
TopPlayersScores[5] = loader.data.score5;
};
if (loader.data.name6 != null){
TopPlayersName[6] = loader.data.name6;
};
if (loader.data.score6 != null){
TopPlayersScores[6] = loader.data.score6;
};
if (loader.data.name7 != null){
TopPlayersName[7] = loader.data.name7;
};
if (loader.data.score7 != null){
TopPlayersScores[7] = loader.data.score7;
};
if (loader.data.name8 != null){
TopPlayersName[8] = loader.data.name8;
};
if (loader.data.score8 != null){
TopPlayersScores[8] = loader.data.score8;
};
if (loader.data.name9 != null){
TopPlayersName[9] = loader.data.name9;
};
if (loader.data.score9 != null){
TopPlayersScores[9] = loader.data.score9;
};
if (loader.data.name10 != null){
TopPlayersName[10] = loader.data.name10;
};
if (loader.data.score10 != null){
TopPlayersScores[10] = loader.data.score10;
};
if (loader.data.name11 != null){
TopPlayersName[11] = loader.data.name11;
};
if (loader.data.score11 != null){
TopPlayersScores[11] = loader.data.score11;
};
if (loader.data.name12 != null){
TopPlayersName[12] = loader.data.name12;
};
if (loader.data.score12 != null){
TopPlayersScores[12] = loader.data.score12;
};
if (loader.data.name13 != null){
TopPlayersName[13] = loader.data.name13;
};
if (loader.data.score13 != null){
TopPlayersScores[13] = loader.data.score13;
};
if (loader.data.name14 != null){
TopPlayersName[14] = loader.data.name14;
};
if (loader.data.score14 != null){
TopPlayersScores[14] = loader.data.score14;
};
if (loader.data.name15 != null){
TopPlayersName[15] = loader.data.name15;
};
if (loader.data.score15 != null){
TopPlayersScores[15] = loader.data.score15;
};
if (loader.data.name16 != null){
TopPlayersName[16] = loader.data.name16;
};
if (loader.data.score16 != null){
TopPlayersScores[16] = loader.data.score16;
};
if (loader.data.name17 != null){
TopPlayersName[17] = loader.data.name17;
};
if (loader.data.score17 != null){
TopPlayersScores[17] = loader.data.score17;
};
if (loader.data.name18 != null){
TopPlayersName[18] = loader.data.name18;
};
if (loader.data.score18 != null){
TopPlayersScores[18] = loader.data.score18;
};
if (loader.data.name19 != null){
TopPlayersName[19] = loader.data.name19;
};
if (loader.data.score19 != null){
TopPlayersScores[19] = loader.data.score19;
};
if (loader.data.name20 != null){
TopPlayersName[20] = loader.data.name20;
};
if (loader.data.score20 != null){
TopPlayersScores[20] = loader.data.score20;
};
IsLoadedScores = true;
}
override public function onKeyDown(key:uint):void{
var sChannel:SoundChannel;
if (key == qPicKeys.LMOUSE){
sChannel = new Res.MouseClick().play(0, 1);
sChannel.soundTransform = new SoundTransform((0.5 * Menu.GameEffectsVolume));
};
}
public function LoadDataAboutScores():void{
Security.allowDomain("*");
Security.loadPolicyFile("http://hiscore.gamesfree.com/crossdomain.xml");
var loadmode = 1;
var request:URLRequest = new URLRequest("http://hiscore.gamesfree.com/mrbob_get.php");
var loader:URLLoader = new URLLoader();
loader.dataFormat = URLLoaderDataFormat.VARIABLES;
request.data = ("m=" + loadmode);
request.method = URLRequestMethod.POST;
loader.addEventListener(Event.COMPLETE, handleComplete);
loader.addEventListener(IOErrorEvent.IO_ERROR, onIOError);
loader.load(request);
}
public function onMenuClick(event:MouseEvent):void{
qPicProcessor.ActivateProcess(qPic.Games["Menu"]);
qPicProcessor.DeActivateProcess(qPic.Games["HighScores"]);
qPic.FocusScene();
}
override public function Init():void{
var i:Number = 1;
while (i <= 20) {
TopPlayersName[i] = "...";
TopPlayersScores[i] = 0;
i++;
};
}
public function onIOError(event:IOErrorEvent):void{
trace("Error loading URL.");
}
override public function Processing():void{
var i:Number;
var playername:TextLabel;
if (((!(IsPrintedScores)) && (IsLoadedScores))){
i = 1;
while (i <= 20) {
playername = new TextLabel(12, 0xFFFFFF);
playername.SetStr((((((((i < 10)) ? "0" : "" + i) + ".") + TopPlayersName[i]) + " - ") + TopPlayersScores[i]));
playername.SetPosByCorner(((i <= 10)) ? (qPic.ScreenHalfX - 200) : qPic.ScreenHalfX, (qPic.ScreenHalfY + (playername.height * ((i - 1) % 10))), -1, 0);
qPic.Scene.addChild(playername);
i++;
};
IsPrintedScores = true;
};
}
override public function Activate():void{
qPic.ClearScene();
var koef:Number = 1;
menuBut = new Res.MenuButtonPic();
menuBut.addEventListener(MouseEvent.CLICK, onMenuClick);
menuBut.x = 10;
menuBut.y = 10;
menuBut.scaleX = koef;
menuBut.scaleY = koef;
qPic.Scene.addChild(menuBut);
var connector:DisplayObject = new Res.ButtonConnector();
connector.scaleX = koef;
connector.scaleY = koef;
connector.x = (menuBut.x + (menuBut.width * koef));
connector.y = ((menuBut.y + (((42 - 27) * koef) / 2)) - ((menuBut.height + 15) * koef));
qPic.Scene.addChild(connector);
connector = new Res.ButtonConnector();
connector.scaleX = -(koef);
connector.scaleY = koef;
connector.x = menuBut.x;
connector.y = ((menuBut.y + (((42 - 27) * koef) / 2)) - ((menuBut.height + 15) * koef));
qPic.Scene.addChild(connector);
koef = 1;
var tower1:DisplayObject = new Res.GemTower();
var tower2:DisplayObject = new Res.GemTower();
tower1.scaleX = -1;
tower1.x = ((tower1.width - 30) * koef);
tower1.y = (qPic.ScreenY - ((tower1.height - 10) * koef));
tower2.x = (qPic.ScreenX - ((tower2.width - 30) * koef));
tower2.y = (qPic.ScreenY - ((tower2.height - 10) * koef));
qPic.Scene.addChild(tower1);
qPic.Scene.addChild(tower2);
var CenterPoint:Point = new Point(qPic.ScreenHalfX, (qPic.ScreenHalfY + 50));
var Board:DisplayObject = new Res.SelectLevelBack();
Board.x = (CenterPoint.x - ((Board.width * 1.2) / 2));
Board.scaleY = 0.8;
Board.scaleX = 1.2;
Board.y = (CenterPoint.y - ((Board.height * 0.75) / 2));
qPic.Scene.addChild(Board);
var GamiLogo:DisplayObject = new Res.GameLogo();
GamiLogo.x = (CenterPoint.x - (GamiLogo.width / 2));
GamiLogo.y = ((Board.y - (GamiLogo.height / 2)) - 60);
qPic.Scene.addChild(GamiLogo);
var Label:DisplayObject = LevelSelect.CreateLabel("TOP 20 MINERS - HALL OF FAME", 20);
Label.x = (CenterPoint.x - (Label.width / 2));
Label.y = ((GamiLogo.y + GamiLogo.height) + 5);
qPic.Scene.addChild(Label);
IsLoadedScores = false;
IsPrintedScores = false;
LoadDataAboutScores();
qPic.Scene.addChild(Menu.EffectsButton);
qPic.Scene.addChild(Menu.MusicButton);
qPic.Scene.addChild(Menu.SponsorMiniButton);
}
}
}//package Games.tripline
Section 32
//KeyboardControl (Games.tripline.KeyboardControl)
package Games.tripline {
public class KeyboardControl {
public static var DOWN:String = "DOWN";
public static var LEFT:String = "LEFT";
private static var Priority1:String = NONE;
private static var Priority3:String = NONE;
private static var Priority2:String = NONE;
private static var Priority4:String = NONE;
public static var UP:String = "UP";
public static var RIGHT:String = "RIGHT";
public static var NONE:String = "NONE";
public function KeyboardControl(){
super();
}
public static function UnPressed(p:String):void{
if (!IsGoodData(p)){
return;
};
if (Priority4 == p){
Priority4 = NONE;
};
if (Priority3 == p){
Priority3 = Priority4;
Priority4 = NONE;
};
if (Priority2 == p){
Priority2 = Priority3;
Priority3 = Priority4;
Priority4 = NONE;
};
if (Priority1 == p){
Priority1 = Priority2;
Priority2 = Priority3;
Priority3 = Priority4;
Priority4 = NONE;
};
}
public static function Pressed(p:String):void{
if (!IsGoodData(p)){
return;
};
UnPressed(p);
Priority4 = Priority3;
Priority3 = Priority2;
Priority2 = Priority1;
Priority1 = p;
}
public static function GetCurr():String{
return (Priority1);
}
private static function IsGoodData(p:String):Boolean{
if ((((((((((p == UP)) || ((p == DOWN)))) || ((p == LEFT)))) || ((p == RIGHT)))) || ((p == NONE)))){
return (true);
};
return (false);
}
}
}//package Games.tripline
Section 33
//Labels (Games.tripline.Labels)
package Games.tripline {
public class Labels {
public static var GoToSite:String = "http://www.gamesfree.com/";
public static var GoToSolution:String = "http://www.gamesfree.com/game/mr_bob_walkthrough.html";
public function Labels(){
super();
}
}
}//package Games.tripline
Section 34
//Level (Games.tripline.Level)
package Games.tripline {
import Engine.*;
import flash.display.*;
import flash.events.*;
import Games.tripline.Figures.*;
import flash.media.*;
import flash.geom.*;
public class Level {
public var IsNeedMoveAuto:Boolean;
private var YStart:Number;
protected var Level1:Array;
protected var _block:Array;
protected var _num_of_bloocks_done:int;// = 0
public var IsGameLose:Boolean;// = false
private var X:Number;
private var Y:Number;
protected var _isLevelDone:Boolean;// = false
protected var CursorPosInMassX:int;
protected var CursorPosInMassY:int;
protected var _displObj:DisplayObject;
protected var Y_pos_of_cursor:int;// = 1
public var prevline:DisplayObjectContainer;// = null
private var XStart:Number;
protected var X_pos_of_cursor:int;// = 1
public var _cursor:Sprite;
protected var MaxNumOfBlocks:int;
public static var FigSize:int = 25;
public function Level(){
_block = new Array();
X = qPic.ScreenHalfX;
Y = qPic.ScreenHalfY;
YStart = Y;
XStart = X;
super();
}
public function DrawLevel():void{
var j:int;
var MaxLength:int;
var MaxHeigth:int;
MaxHeigth = Level1.length;
var k:int;
while (k < (Level1.length - 1)) {
if (Level1[k].length > MaxLength){
MaxLength = Level1[k].length;
};
k++;
};
MaxHeigth = (MaxHeigth / 2);
MaxLength = (MaxLength / 2);
X = (X - (FigSize * MaxLength));
Y = (Y - (FigSize * MaxHeigth));
X = 180;
while ((Y + ((FigSize * 2) * MaxHeigth)) <= 290) {
Y = (Y + FigSize);
};
XStart = X;
YStart = Y;
var i:int;
while (i < Level1.length) {
j = 0;
while (j < Level1[i].length) {
qPic.Scene.addChild(Level1[i][j]);
Level1[i][j].x = X;
Level1[i][j].y = Y;
X = (X + FigSize);
j++;
};
X = XStart;
Y = (Y + FigSize);
i++;
};
_cursor = new Sprite();
_displObj = new Res.RopeEnd();
_cursor.addChild(_displObj);
_cursor.x = (XStart + (Y_pos_of_cursor * FigSize));
_cursor.y = (YStart + (X_pos_of_cursor * FigSize));
_cursor.rotation = 90;
if (((!((Level1[X_pos_of_cursor][Y_pos_of_cursor].GetType() == "empty"))) && (!((Level1[X_pos_of_cursor][Y_pos_of_cursor].GetType() == "wall"))))){
Level1[X_pos_of_cursor][Y_pos_of_cursor].SetChose(true);
block_check(Level1[X_pos_of_cursor][Y_pos_of_cursor]);
};
IsNeedMoveAuto = false;
qPic.Scene.addChild(_cursor);
_cursor.addEventListener(MouseEvent.MOUSE_DOWN, startDrag);
_cursor.addEventListener(MouseEvent.MOUSE_UP, endDrag);
}
public function CheckDrag():void{
if (IsNeedMoveAuto){
Game.IsNeedAttention = false;
_cursor.scaleX = 1.5;
_cursor.scaleY = 1.5;
} else {
if (!Game.IsNeedAttention){
_cursor.scaleX = 1;
_cursor.scaleY = 1;
};
};
if (IsLevelDone()){
return;
};
if (IsNeedMoveAuto){
if (Math.abs((Game.PointEnd.x - qPicMouse.Position.x)) > (FigSize * 2)){
IsNeedMoveAuto = false;
};
if (Math.abs((Game.PointEnd.y - qPicMouse.Position.y)) > (FigSize * 2)){
IsNeedMoveAuto = false;
};
if (!IsNeedMoveAuto){
return;
};
if ((qPicMouse.Position.x - Game.PointEnd.x) > (FigSize * 0.5)){
Move_Right();
return;
};
if ((qPicMouse.Position.x - Game.PointEnd.x) < (-(FigSize) * 0.5)){
Move_Left();
return;
};
if ((qPicMouse.Position.y - Game.PointEnd.y) > (FigSize * 0.5)){
Move_Down();
return;
};
if ((qPicMouse.Position.y - Game.PointEnd.y) < (-(FigSize) * 0.5)){
Move_Up();
return;
};
};
}
public function CreateLevel(N:int):void{
if (N == 1){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 1;
X_pos_of_cursor = 2;
Y_pos_of_cursor = 1;
};
if (N == 2){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 1, 0]);
Level1.push([2, 2, 2, 2, 2, 2, 0, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 2;
X_pos_of_cursor = 1;
Y_pos_of_cursor = 1;
};
if (N == 3){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 7, 1, 9, 1, 7, 1, 9, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 2;
};
if (N == 4){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 9, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 9, 1, 9, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 4;
};
if (N == 5){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 5;
};
if (N == 6){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 7, 1, 7, 1, 0, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 0, 0, 0, 0, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0, 2, 2, 0, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 0, 2, 2, 0, 0, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0, 2, 2, 0, 0, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 6;
};
if (N == 7){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 8, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 7, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 9, 1, 9, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 9, 1, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0, 2, 2, 2, 2]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2]);
MaxNumOfBlocks = 6;
};
if (N == 8){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 7, 1, 7, 1, 7, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 9, 1, 8, 1, 9, 1, 9, 1, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 2, 2]);
Level1.push([0, 1, 8, 1, 8, 1, 8, 1, 7, 1, 0, 0, 0, 2, 2]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 2, 2, 2, 2]);
Level1.push([0, 1, 8, 1, 7, 1, 7, 1, 0, 0, 0, 2, 2, 2, 2]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0, 2, 2, 2, 2, 2, 2]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2]);
MaxNumOfBlocks = 6;
};
if (N == 9){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 8, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 7, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 9, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0, 2, 2, 2, 2]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2]);
MaxNumOfBlocks = 6;
};
if (N == 10){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 8, 1, 7, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 7, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 8, 1, 7, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 1, 7, 1, 8, 1, 8, 1, 0, 0, 0, 0, 0]);
Level1.push([2, 2, 0, 1, 1, 1, 1, 1, 1, 1, 0, 2, 2, 2, 2]);
Level1.push([2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2]);
MaxNumOfBlocks = 7;
};
if (N == 11){
Level1 = new Array();
Level1.push([2, 2, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([2, 2, 0, 1, 9, 1, 9, 1, 0]);
Level1.push([2, 2, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 1, 9, 1, 7, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 7, 1, 7, 1, 9, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 9, 1, 9, 1, 9, 1, 9, 1, 7, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 1, 9, 1, 7, 1, 0, 0, 0, 0, 0, 0]);
Level1.push([2, 2, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([2, 2, 0, 1, 7, 1, 7, 1, 0]);
Level1.push([2, 2, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 7;
X_pos_of_cursor = 1;
Y_pos_of_cursor = 3;
};
if (N == 12){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 8, 1, 7, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 8, 1, 7, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 9, 1, 8, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 7, 1, 7, 1, 7, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 8;
};
if (N == 13){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 7, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 7, 1, 8, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 8, 1, 8, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 9, 1, 9, 1, 9, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 8;
};
if (N == 14){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
X_pos_of_cursor = 5;
Y_pos_of_cursor = 4;
MaxNumOfBlocks = 10;
};
if (N == 15){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 8, 1, 8, 1, 8, 1, 8, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 8, 1, 8, 1, 7, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 9, 1, 7, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 9, 1, 9, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 8, 1, 8, 1, 8, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
if (N == 16){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 8, 1, 7, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 8, 1, 7, 1, 9, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 9, 1, 7, 1, 8, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 9, 1, 7, 1, 8, 1, 7, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 8, 1, 7, 1, 7, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
if (N == 17){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 8, 1, 8, 1, 8, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 7, 1, 7, 1, 7, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 8, 1, 7, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 8, 1, 9, 1, 7, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 9, 1, 9, 1, 7, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
if (N == 18){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 7, 1, 7, 1, 7, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 9, 1, 8, 1, 7, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 9, 1, 8, 1, 7, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 9, 1, 8, 1, 7, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 7, 1, 8, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
if (N == 19){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 7, 1, 7, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 9, 1, 9, 1, 9, 1, 8, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 9, 1, 7, 1, 7, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 7, 1, 9, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 7, 1, 7, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
if (N == 20){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 9, 1, 8, 1, 8, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 9, 1, 7, 1, 8, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 9, 1, 7, 1, 7, 1, 7, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 7, 1, 7, 1, 8, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 7, 1, 8, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
X_pos_of_cursor = 1;
Y_pos_of_cursor = 1;
};
if (N == 21){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 8, 1, 8, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 9, 1, 8, 1, 9, 1, 9, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 8, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 7, 1, 7, 1, 8, 1, 8, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 7, 1, 9, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
CreateMap();
}
public function block_check(new_fig:Figura):void{
var bsound:SoundChannel;
new_fig.chose();
if (IsGameLose){
return;
};
if (new_fig.GetType() != "empty"){
if (_block[0] == null){
_block[0] = new_fig;
if (new_fig.GetType() == "blue"){
Game.SetMrBob(Game.MrBobHaveBlueOne);
};
if (new_fig.GetType() == "green"){
Game.SetMrBob(Game.MrBobHaveGreenOne);
};
if (new_fig.GetType() == "orange"){
Game.SetMrBob(Game.MrBobHaveOrangeOne);
};
} else {
if (_block[1] == null){
if (new_fig.GetType() == _block[0].GetType()){
_block[1] = new_fig;
if (new_fig.GetType() == "blue"){
Game.SetMrBob(Game.MrBobHaveBlueTwo);
};
if (new_fig.GetType() == "green"){
Game.SetMrBob(Game.MrBobHaveGreenTwo);
};
if (new_fig.GetType() == "orange"){
Game.SetMrBob(Game.MrBobHaveOrangeTwo);
};
} else {
Game.SetMrBob(Game.MrBobHaveError);
IsGameLose = true;
};
} else {
if (_block[2] == null){
if (new_fig.GetType() == _block[0].GetType()){
_block[2] = new_fig;
_block[0].filled();
_block[1].filled();
_block[2].filled();
bsound = new Res.BlockCheck().play(0, 1);
bsound.soundTransform = new SoundTransform((1 * Menu.GameEffectsVolume));
_block[0] = null;
_block[1] = null;
_block[2] = null;
_num_of_bloocks_done++;
if (_num_of_bloocks_done == MaxNumOfBlocks){
bsound = new Res.EndLevel().play(0, 1);
bsound.soundTransform = new SoundTransform((1 * Menu.GameEffectsVolume));
_isLevelDone = true;
Menu.Save.LevelDone(Game._mode, Game.CurrLevelNumber, Game.GetScoreLevel());
};
if (new_fig.GetType() == "blue"){
Game.SetMrBob(Game.MrBobNeedNewBlue);
};
if (new_fig.GetType() == "green"){
Game.SetMrBob(Game.MrBobNeedNewGreen);
};
if (new_fig.GetType() == "orange"){
Game.SetMrBob(Game.MrBobNeedNewOrange);
};
} else {
Game.SetMrBob(Game.MrBobHaveError);
IsGameLose = true;
};
};
};
};
};
}
public function Move_Left():void{
if (_isLevelDone != true){
Move(-1, 0);
};
}
public function CreateMap():void{
var j:int;
var i:int;
while (i < Level1.length) {
j = 0;
while (j < Level1[i].length) {
if (Level1[i][j] == 0){
Level1[i][j] = new Figura_Wall();
};
if (Level1[i][j] == 1){
Level1[i][j] = new Figura_EmptyObject();
};
if (Level1[i][j] == 2){
Level1[i][j] = new Figura_MegaEmptyObject();
};
if (Level1[i][j] == 9){
Level1[i][j] = new Figura_Green();
};
if (Level1[i][j] == 8){
Level1[i][j] = new Figura_Blue();
};
if (Level1[i][j] == 7){
Level1[i][j] = new Figura_Orange();
};
j++;
};
i++;
};
DrawLevel();
}
public function Move_Down():void{
if (_isLevelDone != true){
Move(0, 1);
};
}
public function Move_Up():void{
if (_isLevelDone != true){
Move(0, -1);
};
}
public function endDrag(event:MouseEvent):void{
IsNeedMoveAuto = false;
}
public function startDrag(event:MouseEvent):void{
IsNeedMoveAuto = true;
}
public function Move(x:int, y:int):void{
var _curX:int;
var _curY:int;
var _newX:int;
var _newY:int;
var bsound:SoundChannel;
var prevrotation:Number;
var nextrotation:Number;
var picnode:DisplayObject;
Game.IsNeedAttention = false;
if (Game.Time < Game.maxTime){
Game.PictureForRotation.x = Game.PointEnd.x;
Game.PictureForRotation.y = Game.PointEnd.y;
Game.PictureForRotation.rotation = Game.AngleEnd;
Game.PictureForScale.scaleY = Game.ScaleEnd;
};
var _lines:Sprite = new Sprite();
var _line:DisplayObject = new Res.Rope();
_line.height = FigSize;
_line.width = ((8 * FigSize) / 30);
_line.rotation = -90;
if (Level1[(X_pos_of_cursor + y)][(Y_pos_of_cursor + x)].GetChose() == false){
Game.Time = 0;
Game.PictureForRotation = _cursor;
Level1[X_pos_of_cursor][Y_pos_of_cursor].SetChose(true);
X_pos_of_cursor = (X_pos_of_cursor + y);
Y_pos_of_cursor = (Y_pos_of_cursor + x);
bsound = new Res.SoundStep().play(0, 1);
bsound.soundTransform = new SoundTransform((0.1 * Menu.GameEffectsVolume));
Game.SetScoreLevel((Game.GetScoreLevel() - 50));
_curX = _cursor.x;
_curY = _cursor.y;
Game.PointStart = new Point(_cursor.x, _cursor.y);
_newX = (_cursor.x + (x * FigSize));
_newY = (_cursor.y + (y * FigSize));
Game.PointEnd = new Point(_newX, _newY);
prevrotation = _cursor.rotation;
_cursor.rotation = (((Math.atan2(y, x) * 180) / Math.PI) + 90);
nextrotation = _cursor.rotation;
_cursor.rotation = prevrotation;
Game.AngleStart = prevrotation;
Game.AngleEnd = nextrotation;
if (_newY < _curY){
_lines.rotation = -90;
};
if (_newY > _curY){
_lines.rotation = 90;
};
if (_newX < _curX){
_lines.rotation = 180;
};
_lines.addChild(_line);
if (((!((prevrotation == nextrotation))) || ((prevline == null)))){
qPic.Scene.addChildAt(_lines, qPic.Scene.getChildIndex(_cursor));
Game.PictureForScale = _line;
_line.scaleY = 0;
Game.ScaleStart = 0;
Game.ScaleEnd = 1;
if (prevline == null){
picnode = new Res.RopeFirstNode();
picnode.scaleX = (FigSize / 30);
picnode.scaleY = (FigSize / 30);
picnode.x = (-(FigSize) / 2);
picnode.y = (-(FigSize) / 2);
_lines.addChild(picnode);
} else {
_lines.addChild(new Res.RopeNode());
};
prevline = _lines;
} else {
Game.PictureForScale = prevline.getChildAt(0);
Game.ScaleStart = Game.PictureForScale.scaleY;
Game.ScaleEnd = (Game.ScaleStart + 1);
};
_lines.x = _curX;
_lines.y = _curY;
block_check(Level1[X_pos_of_cursor][Y_pos_of_cursor]);
};
}
public function IsLevelDone():Boolean{
return (_isLevelDone);
}
public function Move_Right():void{
if (_isLevelDone != true){
Move(1, 0);
};
}
}
}//package Games.tripline
Section 35
//LevelHard (Games.tripline.LevelHard)
package Games.tripline {
public class LevelHard extends Level {
public function LevelHard(){
super();
X_pos_of_cursor = 2;
Y_pos_of_cursor = 2;
}
override public function CreateLevel(N:int):void{
if (N == 1){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 7, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 3;
};
if (N == 2){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 9, 1, 8, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 9, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 7, 1, 9, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 3;
X_pos_of_cursor = 2;
Y_pos_of_cursor = 3;
};
if (N == 3){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 7, 1, 9, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 9, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 9, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 7, 1, 7, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 4;
};
if (N == 4){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 7, 1, 7, 1, 9, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 9, 1, 9, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 8, 1, 8, 1, 8, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 4;
};
if (N == 5){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 7, 1, 7, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 8, 1, 8, 0]);
Level1.push([0, 1, 1, 0, 1, 0, 0]);
Level1.push([0, 9, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 8, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 7, 1, 8, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 5;
};
if (N == 6){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 8, 1, 7, 0, 7, 1, 9, 1, 9, 0, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 8, 1, 7, 1, 8, 1, 7, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 7, 1, 8, 1, 8, 1, 7, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 9, 0, 9, 1, 9, 1, 8, 1, 8, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 8;
};
if (N == 7){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 8, 1, 8, 1, 8, 1, 7, 1, 7, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 9, 1, 9, 1, 7, 0, 8, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0]);
Level1.push([0, 7, 1, 7, 0, 8, 1, 7, 1, 7, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0]);
Level1.push([0, 0, 0, 7, 1, 8, 1, 8, 1, 0, 0, 0, 0]);
Level1.push([2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2]);
MaxNumOfBlocks = 7;
};
if (N == 8){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 7, 1, 7, 1, 0, 1, 8, 1, 8, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 7, 1, 0, 0, 0, 0, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0, 2, 2, 0, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 0, 2, 2, 0, 0, 1, 7, 1, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 6;
};
if (N == 9){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0]);
Level1.push([0, 9, 0, 9, 0, 9, 1, 9, 1, 9, 0, 9, 0]);
Level1.push([0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0]);
Level1.push([0, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0]);
Level1.push([0, 9, 1, 9, 1, 9, 1, 9, 0, 9, 1, 9, 0]);
Level1.push([0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0]);
Level1.push([0, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
X_pos_of_cursor = 5;
Y_pos_of_cursor = 4;
MaxNumOfBlocks = 10;
};
if (N == 10){
Level1 = new Array();
Level1.push([2, 2, 0, 0, 0, 0, 0, 0]);
Level1.push([2, 2, 0, 1, 9, 1, 9, 0]);
Level1.push([2, 2, 0, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 1, 9, 1, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 8, 1, 7, 1, 7, 1, 9, 1, 7, 1, 7, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 9, 1, 9, 1, 9, 1, 9, 1, 7, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 0, 0, 1, 9, 1, 7, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([2, 2, 0, 1, 1, 1, 1, 0]);
Level1.push([2, 2, 0, 1, 7, 1, 7, 0]);
Level1.push([2, 2, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 7;
X_pos_of_cursor = 2;
Y_pos_of_cursor = 4;
};
if (N == 11){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 9, 1, 9, 1, 7, 1, 7, 0, 7, 1, 9, 1, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 1, 8, 1, 9, 1, 8, 0, 9, 1, 9, 1, 0, 0, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 2, 2]);
Level1.push([0, 1, 8, 1, 8, 0, 8, 1, 7, 1, 0, 0, 0, 2, 2]);
Level1.push([0, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 2, 2, 2, 2]);
Level1.push([0, 1, 8, 1, 7, 1, 7, 1, 0, 0, 0, 2, 2, 2, 2]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0, 2, 2, 2, 2, 2, 2]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2]);
MaxNumOfBlocks = 6;
};
if (N == 12){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 9, 1, 8, 1, 8, 1, 8, 1, 8, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 9, 1, 8, 1, 8, 1, 7, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 7, 1, 9, 1, 7, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 7, 1, 9, 1, 9, 1, 7, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 7, 1, 8, 1, 8, 1, 8, 1, 7, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
if (N == 13){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 9, 1, 9, 1, 8, 1, 7, 1, 7, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 8, 1, 7, 1, 9, 1, 7, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 7, 1, 9, 1, 7, 1, 8, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 9, 1, 7, 1, 8, 1, 7, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 8, 1, 8, 1, 7, 1, 7, 1, 9, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
if (N == 14){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 9, 1, 9, 1, 8, 1, 8, 1, 8, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 7, 1, 7, 1, 7, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 7, 1, 8, 1, 7, 1, 7, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 8, 1, 9, 1, 7, 1, 7, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 9, 1, 9, 1, 7, 1, 8, 1, 8, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
if (N == 15){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 8, 1, 8, 1, 7, 1, 7, 1, 7, 1, 9, 0]);
Level1.push([0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 7, 1, 9, 1, 8, 1, 7, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0]);
Level1.push([0, 7, 1, 9, 1, 8, 1, 7, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 9, 1, 8, 1, 7, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 7, 1, 7, 1, 8, 1, 8, 1, 8, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
if (N == 16){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 8, 1, 7, 1, 7, 1, 7, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 9, 1, 9, 1, 9, 1, 8, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 9, 1, 7, 1, 7, 1, 8, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 9, 1, 7, 1, 9, 1, 8, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 9, 1, 7, 1, 7, 1, 7, 1, 8, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
if (N == 17){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 8, 1, 8, 1, 8, 1, 7, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 0, 7, 1, 7, 0, 7, 1, 7, 0]);
Level1.push([0, 1, 0, 1, 1, 1, 0, 0, 1, 1, 0]);
Level1.push([0, 8, 0, 7, 1, 9, 0, 9, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 8, 1, 9, 1, 0, 0, 0, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0]);
X_pos_of_cursor = 1;
Y_pos_of_cursor = 1;
MaxNumOfBlocks = 6;
};
if (N == 18){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 9, 1, 8, 1, 8, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 7, 1, 7, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 0, 1, 0, 1, 0]);
Level1.push([0, 8, 1, 9, 0, 7, 1, 8, 0]);
Level1.push([0, 1, 0, 1, 1, 1, 0, 1, 0]);
Level1.push([0, 8, 0, 7, 1, 7, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 0, 1, 1, 0]);
Level1.push([0, 8, 1, 7, 1, 0, 0, 0, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 2, 2]);
MaxNumOfBlocks = 6;
};
if (N == 19){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 8, 1, 7, 1, 8, 1, 7, 1, 7, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 7, 1, 8, 1, 7, 1, 7, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 7, 1, 9, 1, 8, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 9, 1, 7, 1, 7, 1, 7, 1, 9, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 8;
};
if (N == 20){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 7, 1, 7, 1, 9, 0, 8, 1, 8, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 9, 1, 7, 0, 8, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 0]);
Level1.push([0, 8, 1, 9, 1, 7, 1, 7, 1, 7, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 8, 1, 8, 1, 7, 0, 7, 1, 8, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 7, 1, 7, 0, 8, 1, 7, 1, 7, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
X_pos_of_cursor = 3;
Y_pos_of_cursor = 1;
};
if (N == 21){
Level1 = new Array();
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Level1.push([0, 7, 1, 7, 1, 8, 1, 8, 1, 8, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 7, 1, 9, 1, 8, 1, 9, 1, 9, 1, 8, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 9, 1, 8, 1, 9, 1, 9, 1, 9, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 7, 1, 7, 1, 8, 1, 8, 1, 7, 0]);
Level1.push([0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0]);
Level1.push([0, 9, 1, 9, 1, 7, 1, 9, 1, 7, 1, 7, 0]);
Level1.push([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
MaxNumOfBlocks = 10;
};
CreateMap();
}
}
}//package Games.tripline
Section 36
//LevelSave (Games.tripline.LevelSave)
package Games.tripline {
import flash.net.*;
public class LevelSave {
public var ContinueMode:String;
private var EasyLevels:Array;
private var HardLevels:Array;
public var ContinueLevel:Number;
public static var SharedStr:String = "TriclareSave1";
public function LevelSave(){
super();
Load();
}
public function ClearContinue():void{
SaveContinue(null, Number.NaN);
}
public function GetLevelScore(mode:String, n:Number):Number{
if (mode == "easy"){
return (EasyLevels[n]);
};
return (HardLevels[n]);
}
public function LevelDone(mode:String, n:Number, score:Number):void{
if (mode == "easy"){
EasyLevels[n] = Math.max(score, EasyLevels[n]);
} else {
HardLevels[n] = Math.max(score, HardLevels[n]);
};
trace("saved");
PleaseSave();
}
private function PleaseSave():void{
var LocalData:SharedObject = SharedObject.getLocal(SharedStr);
LocalData.data.EasyLevels = EasyLevels;
LocalData.data.HardLevels = HardLevels;
LocalData.data.ContinueLevel = ContinueLevel;
LocalData.data.ContinueMode = ContinueMode;
LocalData.flush();
}
public function MaxLevelDone(mode:String):Number{
var n = 1;
while (n <= NumOfLevels(mode)) {
if (!IsLevelDone(mode, n)){
return (Math.max(1, n));
};
n++;
};
return (NumOfLevels(mode));
}
public function SaveContinue(mode:String, n:Number):void{
ContinueMode = mode;
ContinueLevel = n;
PleaseSave();
}
public function NumOfLevels(mode:String):Number{
return (21);
}
public function Load():void{
var LocalData:SharedObject = SharedObject.getLocal(SharedStr);
EasyLevels = LocalData.data.EasyLevels;
if (EasyLevels == null){
EasyLevels = new Array();
ResetProgress("easy");
};
HardLevels = LocalData.data.HardLevels;
if (HardLevels == null){
HardLevels = new Array();
ResetProgress("hard");
};
ContinueLevel = LocalData.data.ContinueLevel;
ContinueMode = LocalData.data.ContinueMode;
}
public function TotalScore(mode:String):Number{
var result:Number = 0;
var i = 1;
while (i <= MaxLevelDone(mode)) {
result = (result + GetLevelScore(mode, i));
i++;
};
return (result);
}
public function IsLevelDone(mode:String, n:Number):Boolean{
if (mode == "easy"){
return ((EasyLevels[n] > 0));
};
return ((HardLevels[n] > 0));
}
public function ResetProgress(mode:String):void{
var i = 1;
while (i <= NumOfLevels(mode)) {
if (mode == "easy"){
EasyLevels[i] = 0;
} else {
HardLevels[i] = 0;
};
i++;
};
if (ContinueMode == mode){
ContinueMode = null;
ContinueLevel = Number.NaN;
};
PleaseSave();
}
}
}//package Games.tripline
Section 37
//LevelSelect (Games.tripline.LevelSelect)
package Games.tripline {
import Engine.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.media.*;
public class LevelSelect extends qPicProcess {
public var BackEndX:Number;
public var SelectStartX:Number;
public var LevelSelectTimemax:Number;// = 250
public var levelsOpen:int;// = 1
public var BackStartX:Number;
public var backBut:DisplayObject;
public var backselect:DisplayObjectContainer;
public var SelectEndX:Number;
public var Name:DisplayObject;
public var LevelSelectTime:Number;// = 0
public var numOfButt:Number;
public var resetBut:DisplayObject;
public var buttonLevel:Button;
public static var levelsArray:Array;
public function LevelSelect(){
Name = CreateLabel("Select level", 40);
super();
}
override public function onKeyDown(key:uint):void{
var sChannel:SoundChannel;
if (key == qPicKeys.LMOUSE){
sChannel = new Res.MouseClick().play(0, 1);
sChannel.soundTransform = new SoundTransform((0.5 * Menu.GameEffectsVolume));
};
}
public function onBackClick(event:MouseEvent):void{
qPicProcessor.ActivateProcess(qPic.Games["Menu"]);
qPicProcessor.DeActivateProcess(qPic.Games["LevelSelect"]);
qPic.FocusScene();
}
override public function Processing():void{
if (LevelSelectTime < LevelSelectTimemax){
LevelSelectTime = (LevelSelectTime + qPic.FrameTime);
LevelSelectTime = Math.min(LevelSelectTime, LevelSelectTimemax);
backselect.x = (SelectStartX + (((SelectEndX - SelectStartX) * LevelSelectTime) / LevelSelectTimemax));
backBut.x = (BackStartX + (((BackEndX - BackStartX) * LevelSelectTime) / LevelSelectTimemax));
};
}
public function onMouseClickSend(event:MouseEvent):void{
qPicProcessor.ActivateProcess(qPic.Games["SendScores"]);
qPicProcessor.DeActivateProcess(qPic.Games["LevelSelect"]);
qPic.FocusScene();
}
override public function Activate():void{
var Label:DisplayObject;
qPic.ClearScene();
Name.x = (qPic.ScreenHalfX - (Name.width / 2));
Name.y = 50;
var StartDraw:Number = 45;
var drawX:Number = StartDraw;
var drawY:Number = 60;
var StepLeft:Number = 50;
var StepDown:Number = 50;
backselect = new Res.SelectLevelBack();
SelectStartX = qPic.ScreenX;
SelectEndX = (240 - 45);
LevelSelectTime = 0;
backselect.x = SelectStartX;
backselect.y = (qPic.ScreenHalfY - (backselect.height / 2));
var i = 1;
while (i <= Menu.Save.NumOfLevels(Game._mode)) {
buttonLevel = new Button(i.toString(), 30);
buttonLevel.userData = i;
buttonLevel.x = drawX;
buttonLevel.y = drawY;
if (i <= Menu.Save.MaxLevelDone(Game._mode)){
buttonLevel.addEventListener(MouseEvent.CLICK, onMouseClick);
} else {
buttonLevel.LockButton();
buttonLevel.alpha = 0.4;
};
backselect.addChild(buttonLevel);
if (drawX < ((StepLeft * 5) + StartDraw)){
drawX = (drawX + StepLeft);
} else {
drawX = StartDraw;
drawY = (drawY + StepDown);
};
i++;
};
var SendButton:DisplayObject = new Res.SendButtonPic();
SendButton.x = ((backselect.width / 2) - (SendButton.width / 2));
SendButton.y = ((backselect.height + 5) - (SendButton.height / 2));
SendButton.addEventListener(MouseEvent.CLICK, onMouseClickSend);
backselect.addChild(SendButton);
Label = CreateLabel(("Total score: " + Menu.Save.TotalScore(Game._mode)), 25);
backselect.addChild(Label);
Label.x = ((backselect.width / 2) - (Label.width / 2));
Label.y = ((backselect.height - Label.height) - 20);
resetBut = new Res.ResetButtonPic();
resetBut.scaleX = 0.75;
resetBut.scaleY = 0.75;
resetBut.x = ((drawX + ((buttonLevel.width + (StepLeft * 2)) / 2)) - ((resetBut.width * resetBut.scaleX) / 2));
resetBut.y = ((drawY + (buttonLevel.height / 2)) - ((resetBut.height * resetBut.scaleY) / 2));
backselect.addChild(resetBut);
backBut = new Res.BackButtonPic();
BackStartX = -(backBut.width);
BackEndX = 40;
backBut.scaleX = 1.5;
backBut.scaleY = 1.5;
backBut.x = BackStartX;
backBut.y = ((qPic.ScreenHalfY - 50) - (backBut.height / 2));
qPic.Scene.addChild(backBut);
qPic.Scene.addChild(backselect);
resetBut.addEventListener(MouseEvent.CLICK, onResetClick);
backBut.addEventListener(MouseEvent.CLICK, onBackClick);
qPic.Scene.addChild(Menu.EffectsButton);
qPic.Scene.addChild(Menu.MusicButton);
qPic.Scene.addChild(Menu.SponsorMiniButton);
}
public function onMouseClick(event:MouseEvent):void{
var ThisButton:Button = (event.target as Button);
if ((ThisButton.userData is Number)){
Game.CurrLevelNumber = (ThisButton.userData as int);
qPicProcessor.ActivateProcess(qPic.Games["Game"]);
qPicProcessor.DeActivateProcess(qPic.Games["LevelSelect"]);
qPic.FocusScene();
};
}
public function onResetClick(event:MouseEvent):void{
Menu.Save.ResetProgress(Game._mode);
Activate();
LevelSelectTime = (LevelSelectTimemax - 1);
}
public static function CreateLabel(str:String, font:int):TextField{
var formatter:TextFormat;
var _tf:TextField;
formatter = new TextFormat();
formatter.font = "MyFontFamily";
formatter.size = font;
formatter.align;
formatter.color = 0xFFFFFF;
var mFont:Font = (Res.MyEmbeddedFont as Font);
_tf = new TextField();
_tf.text = str;
_tf.autoSize = TextFieldAutoSize.CENTER;
_tf.setTextFormat(formatter);
_tf.embedFonts = true;
_tf.selectable = false;
return (_tf);
}
}
}//package Games.tripline
Section 38
//Menu (Games.tripline.Menu)
package Games.tripline {
import Engine.*;
import flash.display.*;
import flash.events.*;
import flash.media.*;
import flash.net.*;
public class Menu extends qPicProcess {
public var connector1:DisplayObject;
public var connector2:DisplayObject;
public var GameLogoTime3max:Number;// = 500
public var hardButt:DisplayObject;
public var GameLogoTime1:Number;// = 0
public var GameLogoTime2:Number;// = 0
public var GameLogoTime3:Number;// = 0
public var connectorMore1:DisplayObject;
public var easyButt:DisplayObject;
public var connectorMore2:DisplayObject;
public var moregamesButt:DisplayObject;
public var connectorHighscores1:DisplayObject;
public var GameLogoTime2max:Number;// = 1500
public var tower1:DisplayObject;
public var tower2:DisplayObject;
public var SponsorButton:DisplayObject;
public var connectorHighscores2:DisplayObject;
public var GameLogoPos1:Number;
public var GameLogoPos2:Number;
public var GameLogoPos3:Number;
public var GameLogoTime1max:Number;// = 500
public var GameLogo:DisplayObject;
public var contButt:DisplayObject;
public var highscoresButt:DisplayObject;
public static var SponsorMiniButton:DisplayObject;
public static var MenuBackSoundChannel:SoundChannel;
public static var GameEffectsVolume:Number = 1;
public static var GameMusicVolume:Number = 1;
public static var EffectsButton:ButtonWithPic;
public static var MusicButton:ButtonWithPic;
public static var GameBackSoundChannel:SoundChannel;
public static var Save:LevelSave;
public function Menu(){
GameLogo = new Res.GameLogo();
tower1 = new Res.GemTower();
tower2 = new Res.GemTower();
connector1 = new Res.ButtonConnector();
connector2 = new Res.ButtonConnector();
connectorHighscores1 = new Res.ButtonConnector();
connectorHighscores2 = new Res.ButtonConnector();
connectorMore1 = new Res.ButtonConnector();
connectorMore2 = new Res.ButtonConnector();
super();
}
public function onClickMoreGames(event:MouseEvent):void{
var url:String = Labels.GoToSite;
var request:URLRequest = new URLRequest(url);
navigateToURL(request, "_blank");
}
override public function Activate():void{
PlayMenuMusic();
qPic.ClearScene();
GameLogo.y = GameLogoPos1;
qPic.Scene.addChild(GameLogo);
GameLogoTime1 = 0;
GameLogoTime2 = 0;
GameLogoTime3 = 0;
easyButt = new Res.ButtonEasyMode();
hardButt = new Res.ButtonHardMode();
contButt = new Res.ButtonContinue();
highscoresButt = new Res.HighScoresButtonPic();
moregamesButt = new Res.MoreGameButtonPic();
easyButt.addEventListener(MouseEvent.CLICK, onMouseClick1);
hardButt.addEventListener(MouseEvent.CLICK, onMouseClick2);
contButt.addEventListener(MouseEvent.CLICK, onMouseClickCont);
highscoresButt.addEventListener(MouseEvent.CLICK, onClickHighScores);
moregamesButt.addEventListener(MouseEvent.CLICK, onClickMoreGames);
tower1.scaleX = -1;
tower1.x = 0;
tower1.y = qPic.ScreenY;
tower2.x = qPic.ScreenX;
tower2.y = qPic.ScreenY;
qPic.Scene.addChild(tower1);
qPic.Scene.addChild(tower2);
qPic.Scene.addChild(EffectsButton);
qPic.Scene.addChild(MusicButton);
qPic.Scene.addChild(SponsorMiniButton);
qPic.Scene.addChild(SponsorButton);
}
public function onClickSendScores(event:MouseEvent):void{
qPicProcessor.DeActivateProcess(qPic.Games["Menu"]);
qPicProcessor.ActivateProcess(qPic.Games["HighScores"]);
}
public function onClickHighScores(event:MouseEvent):void{
qPicProcessor.DeActivateProcess(qPic.Games["Menu"]);
qPicProcessor.ActivateProcess(qPic.Games["HighScores"]);
}
override public function Init():void{
GameLogo.x = (qPic.ScreenHalfX - (GameLogo.width / 2));
GameLogoPos1 = -(GameLogo.height);
GameLogoPos2 = (qPic.ScreenHalfY - (GameLogo.height / 2));
GameLogoPos3 = 35;
Save = new LevelSave();
SponsorMiniButton = new Res.SponsorButtonPic();
SponsorMiniButton.addEventListener(MouseEvent.CLICK, onClickToSponsor);
EffectsButton = new ButtonWithPic("SoundOn", (640 - 43), 95);
MusicButton = new ButtonWithPic("MusicOn", (640 - 45), 65);
SponsorMiniButton.x = ((qPic.ScreenX - SponsorMiniButton.width) - 10);
SponsorMiniButton.y = 10;
qPic.SceneBack.addChild(new Res.TotalBack());
SponsorButton = new Res.SponsorLogoButton();
SponsorButton.addEventListener(MouseEvent.CLICK, onClickMoreGames);
SponsorButton.x = (qPic.ScreenHalfX - (SponsorButton.width / 2));
SponsorButton.y = (qPic.ScreenY - 115);
}
override public function Processing():void{
var currscale:Number;
var koef:Number;
if (GameLogoTime1 < GameLogoTime1max){
if (GameLogoTime1 > 0){
GameLogoTime1 = (GameLogoTime1 + qPic.FrameTime);
} else {
GameLogoTime1 = 1;
};
if (GameLogoTime1 > GameLogoTime1max){
GameLogoTime1 = GameLogoTime1max;
};
GameLogo.y = (GameLogoPos1 + (((GameLogoPos2 - GameLogoPos1) * GameLogoTime1) / GameLogoTime1max));
return;
};
if (GameLogoTime2 < GameLogoTime2max){
GameLogoTime2 = (GameLogoTime2 + qPic.FrameTime);
if (GameLogoTime2 >= GameLogoTime2max){
GameLogoTime2 = GameLogoTime2max;
};
currscale = Math.min(1.5, (2 - (Math.abs(((GameLogoTime2max / 2) - GameLogoTime2)) / (GameLogoTime2max / 2))));
GameLogo.scaleX = currscale;
GameLogo.scaleY = currscale;
GameLogo.x = (qPic.ScreenHalfX - (GameLogo.width / 2));
GameLogo.y = (qPic.ScreenHalfY - (GameLogo.height / 2));
if (GameLogoTime2 >= GameLogoTime2max){
GameLogoTime2max = 0;
};
return;
};
if (GameLogoTime3 < GameLogoTime3max){
GameLogoTime3 = (GameLogoTime3 + qPic.FrameTime);
if (GameLogoTime3 >= GameLogoTime3max){
GameLogoTime1max = 100;
GameLogoTime3max = 300;
GameLogoTime3 = GameLogoTime3max;
};
GameLogo.y = (GameLogoPos2 + (((GameLogoPos3 - GameLogoPos2) * GameLogoTime3) / GameLogoTime3max));
koef = (GameLogoTime3 / GameLogoTime3max);
tower1.x = ((tower1.width - 20) * koef);
tower1.y = (qPic.ScreenY - ((tower1.height - 10) * koef));
tower2.x = (qPic.ScreenX - ((tower2.width - 20) * koef));
tower2.y = (qPic.ScreenY - ((tower2.height - 10) * koef));
easyButt.y = ((GameLogo.y + (GameLogo.height / 2)) + (((GameLogo.height / 2) + 15) * koef));
hardButt.y = (easyButt.y + ((easyButt.height + 15) * koef));
contButt.y = ((GameLogo.y + GameLogo.height) - (hardButt.height + 15));
contButt.x = (GameLogo.x + ((GameLogo.width - 30) * koef));
highscoresButt.y = (-(highscoresButt.height) + ((15 + highscoresButt.height) * koef));
connectorHighscores1.y = (highscoresButt.y + ((42 + 27) / 2));
connectorHighscores2.y = (highscoresButt.y + ((42 + 27) / 2));
moregamesButt.y = (qPic.ScreenY - ((15 + moregamesButt.height) * koef));
connectorMore1.y = (moregamesButt.y + ((42 - 27) / 2));
connectorMore2.y = (moregamesButt.y + ((42 - 27) / 2));
connector1.y = ((easyButt.y + ((42 - 27) / 2)) - ((easyButt.height + 15) * koef));
connector2.y = ((hardButt.y + ((42 - 27) / 2)) - ((easyButt.height + 15) * koef));
connector1.scaleY = koef;
connector2.scaleY = koef;
if (easyButt.parent == null){
easyButt.x = (qPic.ScreenHalfX - (easyButt.width / 2));
hardButt.x = (qPic.ScreenHalfX - (hardButt.width / 2));
highscoresButt.x = 15;
connectorHighscores1.x = (highscoresButt.x + highscoresButt.width);
connectorHighscores2.x = highscoresButt.x;
moregamesButt.x = (qPic.ScreenHalfX - (moregamesButt.width / 2));
connectorMore1.x = (moregamesButt.x + easyButt.width);
connectorMore2.x = moregamesButt.x;
connectorMore2.scaleX = -1;
connector1.x = (easyButt.x + easyButt.width);
connector2.x = hardButt.x;
connector2.scaleX = -1;
qPic.Scene.addChildAt(connector1, qPic.Scene.getChildIndex(GameLogo));
qPic.Scene.addChildAt(connector2, qPic.Scene.getChildIndex(GameLogo));
qPic.Scene.addChild(connectorMore1);
qPic.Scene.addChild(connectorMore2);
qPic.Scene.addChild(moregamesButt);
connectorHighscores1.scaleY = -1;
qPic.Scene.addChild(connectorHighscores1);
connectorHighscores2.scaleY = -1;
connectorHighscores2.scaleX = -1;
qPic.Scene.addChild(connectorHighscores2);
qPic.Scene.addChild(highscoresButt);
if (Save.ContinueMode != null){
qPic.Scene.addChildAt(contButt, qPic.Scene.getChildIndex(GameLogo));
};
qPic.Scene.addChildAt(hardButt, qPic.Scene.getChildIndex(GameLogo));
qPic.Scene.addChildAt(easyButt, qPic.Scene.getChildIndex(GameLogo));
};
return;
};
}
public function onClickToSponsor(e:Event):void{
var url:String = Labels.GoToSite;
var request:URLRequest = new URLRequest(url);
navigateToURL(request, "_blank");
}
override public function onKeyDown(key:uint):void{
var sChannel:SoundChannel;
if (key == qPicKeys.LMOUSE){
sChannel = new Res.MouseClick().play(0, 1);
sChannel.soundTransform = new SoundTransform((0.5 * GameEffectsVolume));
};
}
public function onMouseClick1(event:MouseEvent):void{
Game._mode = "easy";
if (Save.MaxLevelDone(Game._mode) > 1){
qPicProcessor.ActivateProcess(qPic.Games["LevelSelect"]);
} else {
Game.CurrLevelNumber = 1;
qPicProcessor.ActivateProcess(qPic.Games["Game"]);
};
qPicProcessor.DeActivateProcess(qPic.Games["Menu"]);
qPic.FocusScene();
}
public function onMouseClick2(event:MouseEvent):void{
Game._mode = "hard";
if (Save.MaxLevelDone(Game._mode) > 1){
qPicProcessor.ActivateProcess(qPic.Games["LevelSelect"]);
} else {
Game.CurrLevelNumber = 1;
qPicProcessor.ActivateProcess(qPic.Games["Game"]);
};
qPicProcessor.DeActivateProcess(qPic.Games["Menu"]);
qPic.FocusScene();
}
public function onMouseClickCont(event:MouseEvent):void{
if (((!((Save.ContinueMode == null))) && (!(isNaN(Save.ContinueLevel))))){
Game._mode = Save.ContinueMode;
Game.CurrLevelNumber = Save.ContinueLevel;
qPicProcessor.ActivateProcess(qPic.Games["Game"]);
qPicProcessor.DeActivateProcess(qPic.Games["Menu"]);
};
}
public static function StopMenuMusic():void{
if (MenuBackSoundChannel == null){
return;
};
MenuBackSoundChannel.stop();
MenuBackSoundChannel = null;
}
public static function UpdateMusic():void{
if (MenuBackSoundChannel != null){
MenuBackSoundChannel.soundTransform = new SoundTransform((0.5 * GameMusicVolume));
};
if (GameBackSoundChannel != null){
GameBackSoundChannel.soundTransform = new SoundTransform((0.5 * GameMusicVolume));
};
}
public static function StopGameMusic():void{
if (GameBackSoundChannel == null){
return;
};
GameBackSoundChannel.stop();
GameBackSoundChannel = null;
}
public static function PlayMenuMusic():void{
if (MenuBackSoundChannel != null){
return;
};
StopGameMusic();
MenuBackSoundChannel = new Res.MenuMusic().play(0, int.MAX_VALUE);
UpdateMusic();
}
public static function PlayGameMusic():void{
if (GameBackSoundChannel != null){
return;
};
StopMenuMusic();
GameBackSoundChannel = new Res.GameMusic().play(0, int.MAX_VALUE);
UpdateMusic();
}
}
}//package Games.tripline
Section 39
//Res (Games.tripline.Res)
package Games.tripline {
public final class Res {
public static var MouseClick:Class = Res_MouseClick;
public static var musicOff:Class = Res_musicOff;
public static var Back2:Class = Res_Back2;
public static var Back3:Class = Res_Back3;
public static var Back1:Class = Res_Back1;
public static var GemError:Class = Res_GemError;
public static var GemTower:Class = Res_GemTower;
public static var SponsorButtonPic:Class = Res_SponsorButtonPic;
public static var ButtonContinue:Class = Res_ButtonContinue;
public static var ButtonConnector:Class = Res_ButtonConnector;
public static var TotalBack:Class = Res_TotalBack;
public static var FiguraEmpty:Class = Res_FiguraEmpty;
public static var SendButtonPic:Class = Res_SendButtonPic;
public static var Figura1:Class = Res_Figura1;
public static var GameMusic:Class = Res_GameMusic;
public static var ButtonEasyMode:Class = Res_ButtonEasyMode;
public static var Locker:Class = Res_Locker;
public static var RopeNode:Class = Res_RopeNode;
public static var Rope:Class = Res_Rope;
public static var BobNewEmpty:Class = Res_BobNewEmpty;
public static var MenuButtonPic:Class = Res_MenuButtonPic;
public static var soundOn:Class = Res_soundOn;
public static var HelpTipLev3:Class = Res_HelpTipLev3;
public static var FiguraOrange:Class = Res_FiguraOrange;
public static var SponsorLogoButton:Class = Res_SponsorLogoButton;
public static var SoundStep:Class = Res_SoundStep;
public static var HelpTipLev1:Class = Res_HelpTipLev1;
public static var HelpTipLev2:Class = Res_HelpTipLev2;
public static var SolutionButtonPic:Class = Res_SolutionButtonPic;
public static var BobHaveOrange2:Class = Res_BobHaveOrange2;
public static var BobHaveOrange1:Class = Res_BobHaveOrange1;
public static var BobError:Class = Res_BobError;
public static var RopeEnd:Class = Res_RopeEnd;
public static var FiguraBlue:Class = Res_FiguraBlue;
public static var BobHaveBlue2:Class = Res_BobHaveBlue2;
public static var BobHaveBlue1:Class = Res_BobHaveBlue1;
public static var HelpTipHard:Class = Res_HelpTipHard;
public static var Splash:Class = Res_Splash;
public static var EndLevel:Class = Res_EndLevel;
public static var BobHaveGreen1:Class = Res_BobHaveGreen1;
public static var BobHaveGreen2:Class = Res_BobHaveGreen2;
public static var ResetButtonPic:Class = Res_ResetButtonPic;
public static var ScoreBoard:Class = Res_ScoreBoard;
public static var BlockCheck:Class = Res_BlockCheck;
public static var ButtonHardMode:Class = Res_ButtonHardMode;
public static var Gears:Class = Res_Gears;
public static var BackButtonPic:Class = Res_BackButtonPic;
public static var HighScoresButtonPic:Class = Res_HighScoresButtonPic;
public static var MoreGameButtonPic:Class = Res_MoreGameButtonPic;
public static var TopPlayers:Class = Res_TopPlayers;
public static var BobNewBlue:Class = Res_BobNewBlue;
public static var NextLevelButtonPic:Class = Res_NextLevelButtonPic;
public static var RestartButtonPic:Class = Res_RestartButtonPic;
public static var SelectLevelBack:Class = Res_SelectLevelBack;
public static var BobNewOrange:Class = Res_BobNewOrange;
public static var GameLogo:Class = Res_GameLogo;
public static var soundOff:Class = Res_soundOff;
public static var FiguraGreen:Class = Res_FiguraGreen;
public static var musicOn:Class = Res_musicOn;
public static var MyEmbeddedFont:Class = Res_MyEmbeddedFont;
public static var MenuMusic:Class = Res_MenuMusic;
public static var RopeFirstNode:Class = Res_RopeFirstNode;
public static var FiguraWall:Class = Res_FiguraWall;
public static var BobNewGreen:Class = Res_BobNewGreen;
public function Res(){
super();
}
}
}//package Games.tripline
Section 40
//Res_Back1 (Games.tripline.Res_Back1)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_Back1 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_Back1(){
dataClass = Res_Back1_dataClass;
super();
initialWidth = (15320 / 20);
initialHeight = (5760 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 41
//Res_Back1_dataClass (Games.tripline.Res_Back1_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_Back1_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 42
//Res_Back2 (Games.tripline.Res_Back2)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_Back2 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_Back2(){
dataClass = Res_Back2_dataClass;
super();
initialWidth = (20700 / 20);
initialHeight = (7780 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 43
//Res_Back2_dataClass (Games.tripline.Res_Back2_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_Back2_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 44
//Res_Back3 (Games.tripline.Res_Back3)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_Back3 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_Back3(){
dataClass = Res_Back3_dataClass;
super();
initialWidth = (24520 / 20);
initialHeight = (9220 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 45
//Res_Back3_dataClass (Games.tripline.Res_Back3_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_Back3_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 46
//Res_BackButtonPic (Games.tripline.Res_BackButtonPic)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BackButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BackButtonPic(){
dataClass = Res_BackButtonPic_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 47
//Res_BackButtonPic_dataClass (Games.tripline.Res_BackButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BackButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 48
//Res_BlockCheck (Games.tripline.Res_BlockCheck)
package Games.tripline {
import mx.core.*;
public class Res_BlockCheck extends SoundAsset {
}
}//package Games.tripline
Section 49
//Res_BobError (Games.tripline.Res_BobError)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobError extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobError(){
dataClass = Res_BobError_dataClass;
super();
initialWidth = (3460 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 50
//Res_BobError_dataClass (Games.tripline.Res_BobError_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobError_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 51
//Res_BobHaveBlue1 (Games.tripline.Res_BobHaveBlue1)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobHaveBlue1 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobHaveBlue1(){
dataClass = Res_BobHaveBlue1_dataClass;
super();
initialWidth = (3160 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 52
//Res_BobHaveBlue1_dataClass (Games.tripline.Res_BobHaveBlue1_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobHaveBlue1_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 53
//Res_BobHaveBlue2 (Games.tripline.Res_BobHaveBlue2)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobHaveBlue2 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobHaveBlue2(){
dataClass = Res_BobHaveBlue2_dataClass;
super();
initialWidth = (3160 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 54
//Res_BobHaveBlue2_dataClass (Games.tripline.Res_BobHaveBlue2_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobHaveBlue2_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 55
//Res_BobHaveGreen1 (Games.tripline.Res_BobHaveGreen1)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobHaveGreen1 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobHaveGreen1(){
dataClass = Res_BobHaveGreen1_dataClass;
super();
initialWidth = (3160 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 56
//Res_BobHaveGreen1_dataClass (Games.tripline.Res_BobHaveGreen1_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobHaveGreen1_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 57
//Res_BobHaveGreen2 (Games.tripline.Res_BobHaveGreen2)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobHaveGreen2 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobHaveGreen2(){
dataClass = Res_BobHaveGreen2_dataClass;
super();
initialWidth = (3160 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 58
//Res_BobHaveGreen2_dataClass (Games.tripline.Res_BobHaveGreen2_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobHaveGreen2_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 59
//Res_BobHaveOrange1 (Games.tripline.Res_BobHaveOrange1)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobHaveOrange1 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobHaveOrange1(){
dataClass = Res_BobHaveOrange1_dataClass;
super();
initialWidth = (3160 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 60
//Res_BobHaveOrange1_dataClass (Games.tripline.Res_BobHaveOrange1_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobHaveOrange1_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 61
//Res_BobHaveOrange2 (Games.tripline.Res_BobHaveOrange2)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobHaveOrange2 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobHaveOrange2(){
dataClass = Res_BobHaveOrange2_dataClass;
super();
initialWidth = (3160 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 62
//Res_BobHaveOrange2_dataClass (Games.tripline.Res_BobHaveOrange2_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobHaveOrange2_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 63
//Res_BobNewBlue (Games.tripline.Res_BobNewBlue)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobNewBlue extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobNewBlue(){
dataClass = Res_BobNewBlue_dataClass;
super();
initialWidth = (3340 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 64
//Res_BobNewBlue_dataClass (Games.tripline.Res_BobNewBlue_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobNewBlue_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 65
//Res_BobNewEmpty (Games.tripline.Res_BobNewEmpty)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobNewEmpty extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobNewEmpty(){
dataClass = Res_BobNewEmpty_dataClass;
super();
initialWidth = (3160 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 66
//Res_BobNewEmpty_dataClass (Games.tripline.Res_BobNewEmpty_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobNewEmpty_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 67
//Res_BobNewGreen (Games.tripline.Res_BobNewGreen)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobNewGreen extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobNewGreen(){
dataClass = Res_BobNewGreen_dataClass;
super();
initialWidth = (3340 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 68
//Res_BobNewGreen_dataClass (Games.tripline.Res_BobNewGreen_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobNewGreen_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 69
//Res_BobNewOrange (Games.tripline.Res_BobNewOrange)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_BobNewOrange extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_BobNewOrange(){
dataClass = Res_BobNewOrange_dataClass;
super();
initialWidth = (3340 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 70
//Res_BobNewOrange_dataClass (Games.tripline.Res_BobNewOrange_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_BobNewOrange_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 71
//Res_ButtonConnector (Games.tripline.Res_ButtonConnector)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_ButtonConnector extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_ButtonConnector(){
dataClass = Res_ButtonConnector_dataClass;
super();
initialWidth = (440 / 20);
initialHeight = (1560 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 72
//Res_ButtonConnector_dataClass (Games.tripline.Res_ButtonConnector_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_ButtonConnector_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 73
//Res_ButtonContinue (Games.tripline.Res_ButtonContinue)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_ButtonContinue extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_ButtonContinue(){
dataClass = Res_ButtonContinue_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 74
//Res_ButtonContinue_dataClass (Games.tripline.Res_ButtonContinue_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_ButtonContinue_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 75
//Res_ButtonEasyMode (Games.tripline.Res_ButtonEasyMode)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_ButtonEasyMode extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_ButtonEasyMode(){
dataClass = Res_ButtonEasyMode_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 76
//Res_ButtonEasyMode_dataClass (Games.tripline.Res_ButtonEasyMode_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_ButtonEasyMode_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 77
//Res_ButtonHardMode (Games.tripline.Res_ButtonHardMode)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_ButtonHardMode extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_ButtonHardMode(){
dataClass = Res_ButtonHardMode_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 78
//Res_ButtonHardMode_dataClass (Games.tripline.Res_ButtonHardMode_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_ButtonHardMode_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 79
//Res_EndLevel (Games.tripline.Res_EndLevel)
package Games.tripline {
import mx.core.*;
public class Res_EndLevel extends SoundAsset {
}
}//package Games.tripline
Section 80
//Res_Figura1 (Games.tripline.Res_Figura1)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_Figura1 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_Figura1(){
dataClass = Res_Figura1_dataClass;
super();
initialWidth = (600 / 20);
initialHeight = (600 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 81
//Res_Figura1_dataClass (Games.tripline.Res_Figura1_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_Figura1_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 82
//Res_FiguraBlue (Games.tripline.Res_FiguraBlue)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_FiguraBlue extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_FiguraBlue(){
dataClass = Res_FiguraBlue_dataClass;
super();
initialWidth = (600 / 20);
initialHeight = (600 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 83
//Res_FiguraBlue_dataClass (Games.tripline.Res_FiguraBlue_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_FiguraBlue_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 84
//Res_FiguraEmpty (Games.tripline.Res_FiguraEmpty)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_FiguraEmpty extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_FiguraEmpty(){
dataClass = Res_FiguraEmpty_dataClass;
super();
initialWidth = (600 / 20);
initialHeight = (600 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 85
//Res_FiguraEmpty_dataClass (Games.tripline.Res_FiguraEmpty_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_FiguraEmpty_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 86
//Res_FiguraGreen (Games.tripline.Res_FiguraGreen)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_FiguraGreen extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_FiguraGreen(){
dataClass = Res_FiguraGreen_dataClass;
super();
initialWidth = (600 / 20);
initialHeight = (600 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 87
//Res_FiguraGreen_dataClass (Games.tripline.Res_FiguraGreen_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_FiguraGreen_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 88
//Res_FiguraOrange (Games.tripline.Res_FiguraOrange)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_FiguraOrange extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_FiguraOrange(){
dataClass = Res_FiguraOrange_dataClass;
super();
initialWidth = (600 / 20);
initialHeight = (600 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 89
//Res_FiguraOrange_dataClass (Games.tripline.Res_FiguraOrange_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_FiguraOrange_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 90
//Res_FiguraWall (Games.tripline.Res_FiguraWall)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_FiguraWall extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_FiguraWall(){
dataClass = Res_FiguraWall_dataClass;
super();
initialWidth = (600 / 20);
initialHeight = (600 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 91
//Res_FiguraWall_dataClass (Games.tripline.Res_FiguraWall_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_FiguraWall_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 92
//Res_GameLogo (Games.tripline.Res_GameLogo)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_GameLogo extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_GameLogo(){
dataClass = Res_GameLogo_dataClass;
super();
initialWidth = (5180 / 20);
initialHeight = (3860 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 93
//Res_GameLogo_dataClass (Games.tripline.Res_GameLogo_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_GameLogo_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 94
//Res_GameMusic (Games.tripline.Res_GameMusic)
package Games.tripline {
import mx.core.*;
public class Res_GameMusic extends SoundAsset {
}
}//package Games.tripline
Section 95
//Res_Gears (Games.tripline.Res_Gears)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_Gears extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_Gears(){
dataClass = Res_Gears_dataClass;
super();
initialWidth = (0x0500 / 20);
initialHeight = (1300 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 96
//Res_Gears_dataClass (Games.tripline.Res_Gears_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_Gears_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 97
//Res_GemError (Games.tripline.Res_GemError)
package Games.tripline {
import mx.core.*;
public class Res_GemError extends SoundAsset {
}
}//package Games.tripline
Section 98
//Res_GemTower (Games.tripline.Res_GemTower)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_GemTower extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_GemTower(){
dataClass = Res_GemTower_dataClass;
super();
initialWidth = (3160 / 20);
initialHeight = (3980 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 99
//Res_GemTower_dataClass (Games.tripline.Res_GemTower_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_GemTower_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 100
//Res_HelpTipHard (Games.tripline.Res_HelpTipHard)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_HelpTipHard extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_HelpTipHard(){
dataClass = Res_HelpTipHard_dataClass;
super();
initialWidth = (5460 / 20);
initialHeight = (4440 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 101
//Res_HelpTipHard_dataClass (Games.tripline.Res_HelpTipHard_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_HelpTipHard_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 102
//Res_HelpTipLev1 (Games.tripline.Res_HelpTipLev1)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_HelpTipLev1 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_HelpTipLev1(){
dataClass = Res_HelpTipLev1_dataClass;
super();
initialWidth = (5460 / 20);
initialHeight = (4440 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 103
//Res_HelpTipLev1_dataClass (Games.tripline.Res_HelpTipLev1_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_HelpTipLev1_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 104
//Res_HelpTipLev2 (Games.tripline.Res_HelpTipLev2)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_HelpTipLev2 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_HelpTipLev2(){
dataClass = Res_HelpTipLev2_dataClass;
super();
initialWidth = (5460 / 20);
initialHeight = (4440 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 105
//Res_HelpTipLev2_dataClass (Games.tripline.Res_HelpTipLev2_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_HelpTipLev2_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 106
//Res_HelpTipLev3 (Games.tripline.Res_HelpTipLev3)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_HelpTipLev3 extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_HelpTipLev3(){
dataClass = Res_HelpTipLev3_dataClass;
super();
initialWidth = (5460 / 20);
initialHeight = (4440 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 107
//Res_HelpTipLev3_dataClass (Games.tripline.Res_HelpTipLev3_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_HelpTipLev3_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 108
//Res_HighScoresButtonPic (Games.tripline.Res_HighScoresButtonPic)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_HighScoresButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_HighScoresButtonPic(){
dataClass = Res_HighScoresButtonPic_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 109
//Res_HighScoresButtonPic_dataClass (Games.tripline.Res_HighScoresButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_HighScoresButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 110
//Res_Locker (Games.tripline.Res_Locker)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_Locker extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_Locker(){
dataClass = Res_Locker_dataClass;
super();
initialWidth = (1020 / 20);
initialHeight = (1420 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 111
//Res_Locker_dataClass (Games.tripline.Res_Locker_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_Locker_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 112
//Res_MenuButtonPic (Games.tripline.Res_MenuButtonPic)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_MenuButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_MenuButtonPic(){
dataClass = Res_MenuButtonPic_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 113
//Res_MenuButtonPic_dataClass (Games.tripline.Res_MenuButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_MenuButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 114
//Res_MenuMusic (Games.tripline.Res_MenuMusic)
package Games.tripline {
import mx.core.*;
public class Res_MenuMusic extends SoundAsset {
}
}//package Games.tripline
Section 115
//Res_MoreGameButtonPic (Games.tripline.Res_MoreGameButtonPic)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_MoreGameButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_MoreGameButtonPic(){
dataClass = Res_MoreGameButtonPic_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 116
//Res_MoreGameButtonPic_dataClass (Games.tripline.Res_MoreGameButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_MoreGameButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 117
//Res_MouseClick (Games.tripline.Res_MouseClick)
package Games.tripline {
import mx.core.*;
public class Res_MouseClick extends SoundAsset {
}
}//package Games.tripline
Section 118
//Res_musicOff (Games.tripline.Res_musicOff)
package Games.tripline {
import mx.core.*;
public class Res_musicOff extends BitmapAsset {
}
}//package Games.tripline
Section 119
//Res_musicOn (Games.tripline.Res_musicOn)
package Games.tripline {
import mx.core.*;
public class Res_musicOn extends BitmapAsset {
}
}//package Games.tripline
Section 120
//Res_MyEmbeddedFont (Games.tripline.Res_MyEmbeddedFont)
package Games.tripline {
import mx.core.*;
public class Res_MyEmbeddedFont extends FontAsset {
}
}//package Games.tripline
Section 121
//Res_NextLevelButtonPic (Games.tripline.Res_NextLevelButtonPic)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_NextLevelButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_NextLevelButtonPic(){
dataClass = Res_NextLevelButtonPic_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 122
//Res_NextLevelButtonPic_dataClass (Games.tripline.Res_NextLevelButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_NextLevelButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 123
//Res_ResetButtonPic (Games.tripline.Res_ResetButtonPic)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_ResetButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_ResetButtonPic(){
dataClass = Res_ResetButtonPic_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 124
//Res_ResetButtonPic_dataClass (Games.tripline.Res_ResetButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_ResetButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 125
//Res_RestartButtonPic (Games.tripline.Res_RestartButtonPic)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_RestartButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_RestartButtonPic(){
dataClass = Res_RestartButtonPic_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 126
//Res_RestartButtonPic_dataClass (Games.tripline.Res_RestartButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_RestartButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 127
//Res_Rope (Games.tripline.Res_Rope)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_Rope extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_Rope(){
dataClass = Res_Rope_dataClass;
super();
initialWidth = (160 / 20);
initialHeight = (6000 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 128
//Res_Rope_dataClass (Games.tripline.Res_Rope_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_Rope_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 129
//Res_RopeEnd (Games.tripline.Res_RopeEnd)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_RopeEnd extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_RopeEnd(){
dataClass = Res_RopeEnd_dataClass;
super();
initialWidth = (420 / 20);
initialHeight = (300 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 130
//Res_RopeEnd_dataClass (Games.tripline.Res_RopeEnd_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_RopeEnd_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 131
//Res_RopeFirstNode (Games.tripline.Res_RopeFirstNode)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_RopeFirstNode extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_RopeFirstNode(){
dataClass = Res_RopeFirstNode_dataClass;
super();
initialWidth = (600 / 20);
initialHeight = (600 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 132
//Res_RopeFirstNode_dataClass (Games.tripline.Res_RopeFirstNode_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_RopeFirstNode_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 133
//Res_RopeNode (Games.tripline.Res_RopeNode)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_RopeNode extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_RopeNode(){
dataClass = Res_RopeNode_dataClass;
super();
initialWidth = (220 / 20);
initialHeight = (220 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 134
//Res_RopeNode_dataClass (Games.tripline.Res_RopeNode_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_RopeNode_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 135
//Res_ScoreBoard (Games.tripline.Res_ScoreBoard)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_ScoreBoard extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_ScoreBoard(){
dataClass = Res_ScoreBoard_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 136
//Res_ScoreBoard_dataClass (Games.tripline.Res_ScoreBoard_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_ScoreBoard_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 137
//Res_SelectLevelBack (Games.tripline.Res_SelectLevelBack)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_SelectLevelBack extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_SelectLevelBack(){
dataClass = Res_SelectLevelBack_dataClass;
super();
initialWidth = (7320 / 20);
initialHeight = (6580 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 138
//Res_SelectLevelBack_dataClass (Games.tripline.Res_SelectLevelBack_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_SelectLevelBack_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 139
//Res_SendButtonPic (Games.tripline.Res_SendButtonPic)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_SendButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_SendButtonPic(){
dataClass = Res_SendButtonPic_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 140
//Res_SendButtonPic_dataClass (Games.tripline.Res_SendButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_SendButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 141
//Res_SolutionButtonPic (Games.tripline.Res_SolutionButtonPic)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_SolutionButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_SolutionButtonPic(){
dataClass = Res_SolutionButtonPic_dataClass;
super();
initialWidth = (0x0A00 / 20);
initialHeight = (840 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 142
//Res_SolutionButtonPic_dataClass (Games.tripline.Res_SolutionButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_SolutionButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 143
//Res_soundOff (Games.tripline.Res_soundOff)
package Games.tripline {
import mx.core.*;
public class Res_soundOff extends BitmapAsset {
}
}//package Games.tripline
Section 144
//Res_soundOn (Games.tripline.Res_soundOn)
package Games.tripline {
import mx.core.*;
public class Res_soundOn extends BitmapAsset {
}
}//package Games.tripline
Section 145
//Res_SoundStep (Games.tripline.Res_SoundStep)
package Games.tripline {
import mx.core.*;
public class Res_SoundStep extends SoundAsset {
}
}//package Games.tripline
Section 146
//Res_Splash (Games.tripline.Res_Splash)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_Splash extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_Splash(){
dataClass = Res_Splash_dataClass;
super();
initialWidth = (12860 / 20);
initialHeight = (9640 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 147
//Res_Splash_dataClass (Games.tripline.Res_Splash_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_Splash_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 148
//Res_SponsorButtonPic (Games.tripline.Res_SponsorButtonPic)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_SponsorButtonPic extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_SponsorButtonPic(){
dataClass = Res_SponsorButtonPic_dataClass;
super();
initialWidth = (940 / 20);
initialHeight = (940 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 149
//Res_SponsorButtonPic_dataClass (Games.tripline.Res_SponsorButtonPic_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_SponsorButtonPic_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 150
//Res_SponsorLogoButton (Games.tripline.Res_SponsorLogoButton)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_SponsorLogoButton extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_SponsorLogoButton(){
dataClass = Res_SponsorLogoButton_dataClass;
super();
initialWidth = (3120 / 20);
initialHeight = (860 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 151
//Res_SponsorLogoButton_dataClass (Games.tripline.Res_SponsorLogoButton_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_SponsorLogoButton_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 152
//Res_TopPlayers (Games.tripline.Res_TopPlayers)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_TopPlayers extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_TopPlayers(){
dataClass = Res_TopPlayers_dataClass;
super();
initialWidth = (8980 / 20);
initialHeight = (4960 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 153
//Res_TopPlayers_dataClass (Games.tripline.Res_TopPlayers_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_TopPlayers_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 154
//Res_TotalBack (Games.tripline.Res_TotalBack)
package Games.tripline {
import flash.utils.*;
import mx.core.*;
public class Res_TotalBack extends MovieClipLoaderAsset {
public var dataClass:Class;
private static var bytes:ByteArray = null;
public function Res_TotalBack(){
dataClass = Res_TotalBack_dataClass;
super();
initialWidth = (0x3200 / 20);
initialHeight = (9600 / 20);
}
override public function get movieClipData():ByteArray{
if (bytes == null){
bytes = ByteArray(new dataClass());
};
return (bytes);
}
}
}//package Games.tripline
Section 155
//Res_TotalBack_dataClass (Games.tripline.Res_TotalBack_dataClass)
package Games.tripline {
import mx.core.*;
public class Res_TotalBack_dataClass extends ByteArrayAsset {
}
}//package Games.tripline
Section 156
//SendScore (Games.tripline.SendScore)
package Games.tripline {
import Engine.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
import Games.tripline.Other.*;
import flash.media.*;
import flash.geom.*;
import flash.net.*;
import flash.system.*;
public class SendScore extends qPicProcess {
public var HeroName:TextLabel;
public var IsSendedAlready:Boolean;// = false
public var menuBut:DisplayObject;
public var SendButton:Sprite;
public var InputerText:TextLabel;
public static var DefaultNameValue:String = "Type your name!";
private static var hexChars:String = "0123456789abcdef";
public function SendScore(){
super();
}
public function goodjob(e:Event):void{
qPicProcessor.ActivateProcess(qPic.Games["HighScores"]);
qPicProcessor.DeActivateProcess(qPic.Games["SendScores"]);
}
override public function onKeyDown(key:uint):void{
var sChannel:SoundChannel;
if (key == qPicKeys.LMOUSE){
sChannel = new Res.MouseClick().play(0, 1);
sChannel.soundTransform = new SoundTransform((0.5 * Menu.GameEffectsVolume));
};
}
override public function Activate():void{
qPic.ClearScene();
var koef:Number = 1;
menuBut = new Res.MenuButtonPic();
menuBut.addEventListener(MouseEvent.CLICK, onMenuClick);
menuBut.x = 10;
menuBut.y = 10;
menuBut.scaleX = koef;
menuBut.scaleY = koef;
qPic.Scene.addChild(menuBut);
var connector:DisplayObject = new Res.ButtonConnector();
connector.scaleX = koef;
connector.scaleY = koef;
connector.x = (menuBut.x + (menuBut.width * koef));
connector.y = ((menuBut.y + (((42 - 27) * koef) / 2)) - ((menuBut.height + 15) * koef));
qPic.Scene.addChild(connector);
connector = new Res.ButtonConnector();
connector.scaleX = -(koef);
connector.scaleY = koef;
connector.x = menuBut.x;
connector.y = ((menuBut.y + (((42 - 27) * koef) / 2)) - ((menuBut.height + 15) * koef));
qPic.Scene.addChild(connector);
koef = 1;
var tower1:DisplayObject = new Res.GemTower();
var tower2:DisplayObject = new Res.GemTower();
tower1.scaleX = -1;
tower1.x = ((tower1.width - 30) * koef);
tower1.y = (qPic.ScreenY - ((tower1.height - 10) * koef));
tower2.x = (qPic.ScreenX - ((tower2.width - 30) * koef));
tower2.y = (qPic.ScreenY - ((tower2.height - 10) * koef));
qPic.Scene.addChild(tower1);
qPic.Scene.addChild(tower2);
var CenterPoint:Point = new Point(qPic.ScreenHalfX, (qPic.ScreenHalfY + 50));
var Board:DisplayObject = new Res.SelectLevelBack();
Board.x = (CenterPoint.x - ((Board.width * 1.2) / 2));
Board.scaleY = 0.8;
Board.scaleX = 1.2;
Board.y = (CenterPoint.y - ((Board.height * 0.75) / 2));
qPic.Scene.addChild(Board);
var GamiLogo:DisplayObject = new Res.GameLogo();
GamiLogo.x = (CenterPoint.x - (GamiLogo.width / 2));
GamiLogo.y = ((Board.y - (GamiLogo.height / 2)) - 60);
qPic.Scene.addChild(GamiLogo);
var Label:DisplayObject = LevelSelect.CreateLabel("Send scores:", 30);
Label.x = (CenterPoint.x - (Label.width / 2));
Label.y = ((GamiLogo.y + GamiLogo.height) + 5);
qPic.Scene.addChild(Label);
var scoreEasyLabel:TextLabel = new TextLabel(14, 0xFFFFFF);
scoreEasyLabel.SetStr(("Easy mode - " + Menu.Save.TotalScore("easy")));
scoreEasyLabel.SetPosByCorner(qPic.ScreenHalfX, (Label.y + Label.height), 0, -1);
qPic.Scene.addChild(scoreEasyLabel);
var scoreHardLabel:TextLabel = new TextLabel(14, 0xFFFFFF);
scoreHardLabel.SetStr(("Hard mode - " + Menu.Save.TotalScore("hard")));
scoreHardLabel.SetPosByCorner(qPic.ScreenHalfX, (scoreEasyLabel.y + scoreEasyLabel.height), 0, -1);
qPic.Scene.addChild(scoreHardLabel);
var TotalScore:Number = (Menu.Save.TotalScore("easy") + Menu.Save.TotalScore("hard"));
var scoreTotalLabel:TextLabel = new TextLabel(20, 0xFFFFFF);
scoreTotalLabel.SetStr(("Total score - " + TotalScore));
scoreTotalLabel.SetPosByCorner(qPic.ScreenHalfX, (scoreHardLabel.y + scoreHardLabel.height), 0, -1);
qPic.Scene.addChild(scoreTotalLabel);
HeroName = new TextLabel(30, 0xFFFFFF);
HeroName.SetStr("Name: ");
HeroName.SetPosByCorner((qPic.ScreenHalfX - 90), (scoreTotalLabel.y + scoreTotalLabel.height), 0, -1);
qPic.Scene.addChild(HeroName);
InputerText = new TextLabel(30, 0xFFFFFF);
InputerText.selectable = true;
InputerText.type = TextFieldType.INPUT;
InputerText.SetStr(DefaultNameValue);
InputerText.addEventListener(MouseEvent.CLICK, onInputerClick);
InputerText.SetPosByCorner((HeroName.x + HeroName.width), HeroName.y, -1, -1);
qPic.Scene.addChild(InputerText);
SendButton = new Res.SendButtonPic();
SendButton.x = (qPic.ScreenHalfX - (SendButton.width / 2));
SendButton.y = ((InputerText.y + InputerText.height) + 10);
SendButton.addEventListener(MouseEvent.CLICK, onSend);
qPic.Scene.addChild(SendButton);
qPic.Scene.addChild(Menu.EffectsButton);
qPic.Scene.addChild(Menu.MusicButton);
qPic.Scene.addChild(Menu.SponsorMiniButton);
IsSendedAlready = false;
}
override public function Init():void{
}
public function onMenuClick(event:MouseEvent):void{
qPicProcessor.ActivateProcess(qPic.Games["Menu"]);
qPicProcessor.DeActivateProcess(qPic.Games["SendScores"]);
qPic.FocusScene();
}
override public function Processing():void{
if (InputerText.text.length > 15){
InputerText.text = InputerText.text.substr(0, 15);
};
HeroName.SetPosByCorner((qPic.ScreenHalfX - ((HeroName.width + InputerText.width) / 2)), HeroName.y, -1, -1);
InputerText.SetPosByCorner((HeroName.x + HeroName.width), HeroName.y, -1, -1);
if ((((InputerText.text == DefaultNameValue)) || ((InputerText.text == "")))){
SendButton.visible = false;
} else {
SendButton.visible = true;
};
}
public function GiveMeMD5(s:String):String{
var ba:ByteArray = new ByteArray();
ba.writeUTFBytes(s);
return (hashBinary(ba));
}
public function onSend(event:MouseEvent):void{
if (IsSendedAlready){
return;
};
IsSendedAlready = true;
Security.allowDomain("*");
Security.loadPolicyFile("http://hiscore.gamesfree.com/crossdomain.xml");
var Name:String = InputerText.text;
var Score:Number = (Menu.Save.TotalScore("easy") + Menu.Save.TotalScore("hard"));
var variables:URLVariables = new URLVariables();
variables.n = Name;
variables.s = Score;
variables.k = GiveMeMD5(("" + (Score + 1518)));
variables.m = 1;
trace(variables);
var request:URLRequest = new URLRequest("http://hiscore.gamesfree.com/mrbob_submit.php");
request.method = "POST";
request.data = variables;
var loader:URLLoader = new URLLoader();
loader.load(request);
loader.addEventListener(Event.COMPLETE, goodjob);
}
public function onInputerClick(event:MouseEvent):void{
if (InputerText.text == DefaultNameValue){
InputerText.text = "";
};
}
private static function ff(a:int, b:int, c:int, d:int, x:int, s:int, t:int):int{
return (transform(f, a, b, c, d, x, s, t));
}
private static function f(x:int, y:int, z:int):int{
return (((x & y) | (~(x) & z)));
}
private static function hh(a:int, b:int, c:int, d:int, x:int, s:int, t:int):int{
return (transform(h, a, b, c, d, x, s, t));
}
private static function h(x:int, y:int, z:int):int{
return (((x ^ y) ^ z));
}
private static function i(x:int, y:int, z:int):int{
return ((y ^ (x | ~(z))));
}
private static function transform(func:Function, a:int, b:int, c:int, d:int, x:int, s:int, t:int):int{
var tmp:int = (((a + int(func(b, c, d))) + x) + t);
return ((rol(tmp, s) + b));
}
public static function toHex(n:int, bigEndian:Boolean=false):String{
var i:int;
var x:int;
var s:String = "";
if (bigEndian){
i = 0;
while (i < 4) {
s = (s + (hexChars.charAt(((n >> (((3 - i) * 8) + 4)) & 15)) + hexChars.charAt(((n >> ((3 - i) * 8)) & 15))));
i++;
};
} else {
x = 0;
while (x < 4) {
s = (s + (hexChars.charAt(((n >> ((x * 8) + 4)) & 15)) + hexChars.charAt(((n >> (x * 8)) & 15))));
x++;
};
};
return (s);
}
private static function g(x:int, y:int, z:int):int{
return (((x & z) | (y & ~(z))));
}
private static function gg(a:int, b:int, c:int, d:int, x:int, s:int, t:int):int{
return (transform(g, a, b, c, d, x, s, t));
}
private static function createBlocks(s:ByteArray):Array{
var blocks:Array = new Array();
var len:int = (s.length * 8);
var mask = 0xFF;
var i:int;
while (i < len) {
blocks[(i >> 5)] = (blocks[(i >> 5)] | ((s[(i / 8)] & mask) << (i % 32)));
i = (i + 8);
};
blocks[(len >> 5)] = (blocks[(len >> 5)] | (128 << (len % 32)));
blocks[((((len + 64) >>> 9) << 4) + 14)] = len;
return (blocks);
}
public static function hashBinary(s:ByteArray):String{
var aa:int;
var bb:int;
var cc:int;
var dd:int;
var a = 1732584193;
var b = -271733879;
var c = -1732584194;
var d = 271733878;
var x:Array = createBlocks(s);
var len:int = x.length;
var i:int;
while (i < len) {
aa = a;
bb = b;
cc = c;
dd = d;
a = ff(a, b, c, d, x[(i + 0)], 7, -680876936);
d = ff(d, a, b, c, x[(i + 1)], 12, -389564586);
c = ff(c, d, a, b, x[(i + 2)], 17, 606105819);
b = ff(b, c, d, a, x[(i + 3)], 22, -1044525330);
a = ff(a, b, c, d, x[(i + 4)], 7, -176418897);
d = ff(d, a, b, c, x[(i + 5)], 12, 1200080426);
c = ff(c, d, a, b, x[(i + 6)], 17, -1473231341);
b = ff(b, c, d, a, x[(i + 7)], 22, -45705983);
a = ff(a, b, c, d, x[(i + 8)], 7, 1770035416);
d = ff(d, a, b, c, x[(i + 9)], 12, -1958414417);
c = ff(c, d, a, b, x[(i + 10)], 17, -42063);
b = ff(b, c, d, a, x[(i + 11)], 22, -1990404162);
a = ff(a, b, c, d, x[(i + 12)], 7, 1804603682);
d = ff(d, a, b, c, x[(i + 13)], 12, -40341101);
c = ff(c, d, a, b, x[(i + 14)], 17, -1502002290);
b = ff(b, c, d, a, x[(i + 15)], 22, 1236535329);
a = gg(a, b, c, d, x[(i + 1)], 5, -165796510);
d = gg(d, a, b, c, x[(i + 6)], 9, -1069501632);
c = gg(c, d, a, b, x[(i + 11)], 14, 643717713);
b = gg(b, c, d, a, x[(i + 0)], 20, -373897302);
a = gg(a, b, c, d, x[(i + 5)], 5, -701558691);
d = gg(d, a, b, c, x[(i + 10)], 9, 38016083);
c = gg(c, d, a, b, x[(i + 15)], 14, -660478335);
b = gg(b, c, d, a, x[(i + 4)], 20, -405537848);
a = gg(a, b, c, d, x[(i + 9)], 5, 568446438);
d = gg(d, a, b, c, x[(i + 14)], 9, -1019803690);
c = gg(c, d, a, b, x[(i + 3)], 14, -187363961);
b = gg(b, c, d, a, x[(i + 8)], 20, 1163531501);
a = gg(a, b, c, d, x[(i + 13)], 5, -1444681467);
d = gg(d, a, b, c, x[(i + 2)], 9, -51403784);
c = gg(c, d, a, b, x[(i + 7)], 14, 1735328473);
b = gg(b, c, d, a, x[(i + 12)], 20, -1926607734);
a = hh(a, b, c, d, x[(i + 5)], 4, -378558);
d = hh(d, a, b, c, x[(i + 8)], 11, -2022574463);
c = hh(c, d, a, b, x[(i + 11)], 16, 1839030562);
b = hh(b, c, d, a, x[(i + 14)], 23, -35309556);
a = hh(a, b, c, d, x[(i + 1)], 4, -1530992060);
d = hh(d, a, b, c, x[(i + 4)], 11, 1272893353);
c = hh(c, d, a, b, x[(i + 7)], 16, -155497632);
b = hh(b, c, d, a, x[(i + 10)], 23, -1094730640);
a = hh(a, b, c, d, x[(i + 13)], 4, 681279174);
d = hh(d, a, b, c, x[(i + 0)], 11, -358537222);
c = hh(c, d, a, b, x[(i + 3)], 16, -722521979);
b = hh(b, c, d, a, x[(i + 6)], 23, 76029189);
a = hh(a, b, c, d, x[(i + 9)], 4, -640364487);
d = hh(d, a, b, c, x[(i + 12)], 11, -421815835);
c = hh(c, d, a, b, x[(i + 15)], 16, 530742520);
b = hh(b, c, d, a, x[(i + 2)], 23, -995338651);
a = ii(a, b, c, d, x[(i + 0)], 6, -198630844);
d = ii(d, a, b, c, x[(i + 7)], 10, 1126891415);
c = ii(c, d, a, b, x[(i + 14)], 15, -1416354905);
b = ii(b, c, d, a, x[(i + 5)], 21, -57434055);
a = ii(a, b, c, d, x[(i + 12)], 6, 1700485571);
d = ii(d, a, b, c, x[(i + 3)], 10, -1894986606);
c = ii(c, d, a, b, x[(i + 10)], 15, -1051523);
b = ii(b, c, d, a, x[(i + 1)], 21, -2054922799);
a = ii(a, b, c, d, x[(i + 8)], 6, 1873313359);
d = ii(d, a, b, c, x[(i + 15)], 10, -30611744);
c = ii(c, d, a, b, x[(i + 6)], 15, -1560198380);
b = ii(b, c, d, a, x[(i + 13)], 21, 1309151649);
a = ii(a, b, c, d, x[(i + 4)], 6, -145523070);
d = ii(d, a, b, c, x[(i + 11)], 10, -1120210379);
c = ii(c, d, a, b, x[(i + 2)], 15, 718787259);
b = ii(b, c, d, a, x[(i + 9)], 21, -343485551);
a = (a + aa);
b = (b + bb);
c = (c + cc);
d = (d + dd);
i = (i + 16);
};
return ((((toHex(a) + toHex(b)) + toHex(c)) + toHex(d)));
}
private static function ii(a:int, b:int, c:int, d:int, x:int, s:int, t:int):int{
return (transform(i, a, b, c, d, x, s, t));
}
public static function rol(x:int, n:int):int{
return (((x << n) | (x >>> (32 - n))));
}
}
}//package Games.tripline
Section 157
//BitmapAsset (mx.core.BitmapAsset)
package mx.core {
import flash.display.*;
public class BitmapAsset extends FlexBitmap implements IFlexAsset, IFlexDisplayObject {
mx_internal static const VERSION:String = "3.4.1.10084";
public function BitmapAsset(bitmapData:BitmapData=null, pixelSnapping:String="auto", smoothing:Boolean=false){
super(bitmapData, pixelSnapping, smoothing);
}
public function get measuredWidth():Number{
if (bitmapData){
return (bitmapData.width);
};
return (0);
}
public function get measuredHeight():Number{
if (bitmapData){
return (bitmapData.height);
};
return (0);
}
public function setActualSize(newWidth:Number, newHeight:Number):void{
width = newWidth;
height = newHeight;
}
public function move(x:Number, y:Number):void{
this.x = x;
this.y = y;
}
}
}//package mx.core
Section 158
//ByteArrayAsset (mx.core.ByteArrayAsset)
package mx.core {
import flash.utils.*;
public class ByteArrayAsset extends ByteArray implements IFlexAsset {
mx_internal static const VERSION:String = "3.4.1.10084";
public function ByteArrayAsset(){
super();
}
}
}//package mx.core
Section 159
//EdgeMetrics (mx.core.EdgeMetrics)
package mx.core {
public class EdgeMetrics {
public var top:Number;
public var left:Number;
public var bottom:Number;
public var right:Number;
mx_internal static const VERSION:String = "3.4.1.10084";
public static const EMPTY:EdgeMetrics = new EdgeMetrics(0, 0, 0, 0);
;
public function EdgeMetrics(left:Number=0, top:Number=0, right:Number=0, bottom:Number=0){
super();
this.left = left;
this.top = top;
this.right = right;
this.bottom = bottom;
}
public function clone():EdgeMetrics{
return (new EdgeMetrics(left, top, right, bottom));
}
}
}//package mx.core
Section 160
//FlexBitmap (mx.core.FlexBitmap)
package mx.core {
import flash.display.*;
import mx.utils.*;
public class FlexBitmap extends Bitmap {
mx_internal static const VERSION:String = "3.4.1.10084";
public function FlexBitmap(bitmapData:BitmapData=null, pixelSnapping:String="auto", smoothing:Boolean=false){
var bitmapData = bitmapData;
var pixelSnapping = pixelSnapping;
var smoothing = smoothing;
super(bitmapData, pixelSnapping, smoothing);
name = NameUtil.createUniqueName(this);
//unresolved jump
var _slot1 = e;
}
override public function toString():String{
return (NameUtil.displayObjectToString(this));
}
}
}//package mx.core
Section 161
//FlexMovieClip (mx.core.FlexMovieClip)
package mx.core {
import flash.display.*;
import mx.utils.*;
public class FlexMovieClip extends MovieClip {
mx_internal static const VERSION:String = "3.4.1.10084";
public function FlexMovieClip(){
super();
name = NameUtil.createUniqueName(this);
//unresolved jump
var _slot1 = e;
}
override public function toString():String{
return (NameUtil.displayObjectToString(this));
}
}
}//package mx.core
Section 162
//FontAsset (mx.core.FontAsset)
package mx.core {
import flash.text.*;
public class FontAsset extends Font implements IFlexAsset {
mx_internal static const VERSION:String = "3.4.1.10084";
public function FontAsset(){
super();
}
}
}//package mx.core
Section 163
//IBorder (mx.core.IBorder)
package mx.core {
public interface IBorder {
function get borderMetrics():EdgeMetrics;
}
}//package mx.core
Section 164
//IFlexAsset (mx.core.IFlexAsset)
package mx.core {
public interface IFlexAsset {
}
}//package mx.core
Section 165
//IFlexDisplayObject (mx.core.IFlexDisplayObject)
package mx.core {
import flash.events.*;
import flash.display.*;
import flash.geom.*;
import flash.accessibility.*;
public interface IFlexDisplayObject extends IBitmapDrawable, IEventDispatcher {
function get visible():Boolean;
function get rotation():Number;
function localToGlobal(void:Point):Point;
function get name():String;
function set width(flash.display:Number):void;
function get measuredHeight():Number;
function get blendMode():String;
function get scale9Grid():Rectangle;
function set name(flash.display:String):void;
function set scaleX(flash.display:Number):void;
function set scaleY(flash.display:Number):void;
function get measuredWidth():Number;
function get accessibilityProperties():AccessibilityProperties;
function set scrollRect(flash.display:Rectangle):void;
function get cacheAsBitmap():Boolean;
function globalToLocal(void:Point):Point;
function get height():Number;
function set blendMode(flash.display:String):void;
function get parent():DisplayObjectContainer;
function getBounds(String:DisplayObject):Rectangle;
function get opaqueBackground():Object;
function set scale9Grid(flash.display:Rectangle):void;
function setActualSize(_arg1:Number, _arg2:Number):void;
function set alpha(flash.display:Number):void;
function set accessibilityProperties(flash.display:AccessibilityProperties):void;
function get width():Number;
function hitTestPoint(_arg1:Number, _arg2:Number, _arg3:Boolean=false):Boolean;
function set cacheAsBitmap(flash.display:Boolean):void;
function get scaleX():Number;
function get scaleY():Number;
function get scrollRect():Rectangle;
function get mouseX():Number;
function get mouseY():Number;
function set height(flash.display:Number):void;
function set mask(flash.display:DisplayObject):void;
function getRect(String:DisplayObject):Rectangle;
function get alpha():Number;
function set transform(flash.display:Transform):void;
function move(_arg1:Number, _arg2:Number):void;
function get loaderInfo():LoaderInfo;
function get root():DisplayObject;
function hitTestObject(mx.core:IFlexDisplayObject/mx.core:IFlexDisplayObject:stage/get:DisplayObject):Boolean;
function set opaqueBackground(flash.display:Object):void;
function set visible(flash.display:Boolean):void;
function get mask():DisplayObject;
function set x(flash.display:Number):void;
function set y(flash.display:Number):void;
function get transform():Transform;
function set filters(flash.display:Array):void;
function get x():Number;
function get y():Number;
function get filters():Array;
function set rotation(flash.display:Number):void;
function get stage():Stage;
}
}//package mx.core
Section 166
//IRepeaterClient (mx.core.IRepeaterClient)
package mx.core {
public interface IRepeaterClient {
function get instanceIndices():Array;
function set instanceIndices(C:\autobuild\3.4.0\frameworks\projects\framework\src;mx\core;IRepeaterClient.as:Array):void;
function get isDocument():Boolean;
function set repeaters(C:\autobuild\3.4.0\frameworks\projects\framework\src;mx\core;IRepeaterClient.as:Array):void;
function initializeRepeaterArrays(C:\autobuild\3.4.0\frameworks\projects\framework\src;mx\core;IRepeaterClient.as:IRepeaterClient):void;
function get repeaters():Array;
function set repeaterIndices(C:\autobuild\3.4.0\frameworks\projects\framework\src;mx\core;IRepeaterClient.as:Array):void;
function get repeaterIndices():Array;
}
}//package mx.core
Section 167
//MovieClipAsset (mx.core.MovieClipAsset)
package mx.core {
public class MovieClipAsset extends FlexMovieClip implements IFlexAsset, IFlexDisplayObject, IBorder {
private var _measuredHeight:Number;
private var _measuredWidth:Number;
mx_internal static const VERSION:String = "3.4.1.10084";
public function MovieClipAsset(){
super();
_measuredWidth = width;
_measuredHeight = height;
}
public function get measuredWidth():Number{
return (_measuredWidth);
}
public function get measuredHeight():Number{
return (_measuredHeight);
}
public function setActualSize(newWidth:Number, newHeight:Number):void{
width = newWidth;
height = newHeight;
}
public function move(x:Number, y:Number):void{
this.x = x;
this.y = y;
}
public function get borderMetrics():EdgeMetrics{
if (scale9Grid == null){
return (EdgeMetrics.EMPTY);
};
return (new EdgeMetrics(scale9Grid.left, scale9Grid.top, Math.ceil((measuredWidth - scale9Grid.right)), Math.ceil((measuredHeight - scale9Grid.bottom))));
}
}
}//package mx.core
Section 168
//MovieClipLoaderAsset (mx.core.MovieClipLoaderAsset)
package mx.core {
import flash.events.*;
import flash.display.*;
import flash.utils.*;
import flash.system.*;
public class MovieClipLoaderAsset extends MovieClipAsset implements IFlexAsset, IFlexDisplayObject {
protected var initialHeight:Number;// = 0
private var loader:Loader;// = null
private var initialized:Boolean;// = false
protected var initialWidth:Number;// = 0
private var requestedHeight:Number;
private var requestedWidth:Number;
mx_internal static const VERSION:String = "3.4.1.10084";
public function MovieClipLoaderAsset(){
super();
var loaderContext:LoaderContext = new LoaderContext();
loaderContext.applicationDomain = new ApplicationDomain(ApplicationDomain.currentDomain);
if (("allowLoadBytesCodeExecution" in loaderContext)){
loaderContext["allowLoadBytesCodeExecution"] = true;
};
loader = new Loader();
loader.contentLoaderInfo.addEventListener(Event.COMPLETE, completeHandler);
loader.loadBytes(movieClipData, loaderContext);
addChild(loader);
}
override public function get width():Number{
if (!initialized){
return (initialWidth);
};
return (super.width);
}
override public function set width(value:Number):void{
if (!initialized){
requestedWidth = value;
} else {
loader.width = value;
};
}
override public function get measuredHeight():Number{
return (initialHeight);
}
private function completeHandler(event:Event):void{
initialized = true;
initialWidth = loader.width;
initialHeight = loader.height;
if (!isNaN(requestedWidth)){
loader.width = requestedWidth;
};
if (!isNaN(requestedHeight)){
loader.height = requestedHeight;
};
dispatchEvent(event);
}
override public function set height(value:Number):void{
if (!initialized){
requestedHeight = value;
} else {
loader.height = value;
};
}
override public function get measuredWidth():Number{
return (initialWidth);
}
override public function get height():Number{
if (!initialized){
return (initialHeight);
};
return (super.height);
}
public function get movieClipData():ByteArray{
return (null);
}
}
}//package mx.core
Section 169
//mx_internal (mx.core.mx_internal)
package mx.core {
public namespace mx_internal = "http://www.adobe.com/2006/flex/mx/internal";
}//package mx.core
Section 170
//SoundAsset (mx.core.SoundAsset)
package mx.core {
import flash.media.*;
public class SoundAsset extends Sound implements IFlexAsset {
mx_internal static const VERSION:String = "3.4.1.10084";
public function SoundAsset(){
super();
}
}
}//package mx.core
Section 171
//NameUtil (mx.utils.NameUtil)
package mx.utils {
import flash.display.*;
import mx.core.*;
import flash.utils.*;
public class NameUtil {
mx_internal static const VERSION:String = "3.4.1.10084";
private static var counter:int = 0;
public function NameUtil(){
super();
}
public static function displayObjectToString(displayObject:DisplayObject):String{
var result:String;
var o:DisplayObject;
var s:String;
var indices:Array;
var displayObject = displayObject;
o = displayObject;
while (o != null) {
if (((((o.parent) && (o.stage))) && ((o.parent == o.stage)))){
break;
};
s = o.name;
if ((o is IRepeaterClient)){
indices = IRepeaterClient(o).instanceIndices;
if (indices){
s = (s + (("[" + indices.join("][")) + "]"));
};
};
result = ((result == null)) ? s : ((s + ".") + result);
o = o.parent;
};
//unresolved jump
var _slot1 = e;
return (result);
}
public static function createUniqueName(object:Object):String{
if (!object){
return (null);
};
var name:String = getQualifiedClassName(object);
var index:int = name.indexOf("::");
if (index != -1){
name = name.substr((index + 2));
};
var charCode:int = name.charCodeAt((name.length - 1));
if ((((charCode >= 48)) && ((charCode <= 57)))){
name = (name + "_");
};
return ((name + counter++));
}
}
}//package mx.utils
Section 172
//qPicPreLoader (qPicPreLoader)
package {
import flash.events.*;
import flash.display.*;
import flash.text.*;
import flash.utils.*;
import Engine.*;
import Games.tripline.*;
public dynamic class qPicPreLoader extends MovieClip {
private var _percentLoaded:Number;
private var _infoField:TextField;
private var LoadProgram:qPicLoading;
public function qPicPreLoader(){
super();
LoadProgram = new aPicLoading();
LoadProgram.Init(this);
loaderInfo.addEventListener(ProgressEvent.PROGRESS, onRootLoaderProgress);
loaderInfo.addEventListener(Event.COMPLETE, onRootLoaderComplete);
loaderInfo.addEventListener(Event.ENTER_FRAME, onRootLoaderEnterFrame);
}
private function onRootLoaderProgress(event:ProgressEvent):void{
var bytesLoaded:Number = event.target.bytesLoaded;
var totalBytes:Number = event.target.bytesTotal;
_percentLoaded = (bytesLoaded / totalBytes);
LoadProgram.Update(_percentLoaded);
}
private function onRootLoaderComplete(event:Event):void{
loaderInfo.removeEventListener(ProgressEvent.PROGRESS, onRootLoaderProgress);
loaderInfo.removeEventListener(Event.COMPLETE, onRootLoaderComplete);
loaderInfo.removeEventListener(Event.ENTER_FRAME, onRootLoaderComplete);
LoadProgram.ProgressFinished();
addEventListener(Event.ENTER_FRAME, onRootLoaderCheckStart);
}
private function onRootLoaderCheckStart(event:Event):void{
if (LoadProgram.IsCanRunGame){
StartGame();
removeEventListener(Event.ENTER_FRAME, onRootLoaderCheckStart);
};
}
private function StartGame():void{
var app:Object;
LoadProgram.DeInit();
nextFrame();
var mainClass:Class = Class(getDefinitionByName("Engine.qPic"));
if (mainClass){
app = new (mainClass);
addChild((app as DisplayObject));
};
}
private function onRootLoaderEnterFrame(event:Event):void{
if (_percentLoaded > 99.9){
loaderInfo.removeEventListener(Event.ENTER_FRAME, onRootLoaderEnterFrame);
onRootLoaderComplete(event);
};
}
}
}//package