Section 1
//MD5 (com.adobe.crypto.MD5)
package com.adobe.crypto {
import com.adobe.utils.*;
public class MD5 {
public function MD5(){
super();
}
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 createBlocks(s:String):Array{
var blocks:Array;
var len:int;
var mask:int;
var i:int;
blocks = new Array();
len = (s.length * 8);
mask = 0xFF;
i = 0;
while (i < len) {
blocks[(i >> 5)] = (blocks[(i >> 5)] | ((s.charCodeAt((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);
}
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));
}
private static function f(x:int, y:int, z:int):int{
return (((x & y) | (~(x) & z)));
}
private static function g(x:int, y:int, z:int):int{
return (((x & z) | (y & ~(z))));
}
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;
tmp = (((a + int(func(b, c, d))) + x) + t);
return ((IntUtil.rol(tmp, s) + b));
}
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));
}
public static function hash(s:String):String{
var a:int;
var b:int;
var c:int;
var d:int;
var aa:int;
var bb:int;
var cc:int;
var dd:int;
var x:Array;
var len:int;
var i:int;
a = 1732584193;
b = -271733879;
c = -1732584194;
d = 271733878;
x = createBlocks(s);
len = x.length;
i = 0;
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 ((((IntUtil.toHex(a) + IntUtil.toHex(b)) + IntUtil.toHex(c)) + IntUtil.toHex(d)));
}
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));
}
}
}//package com.adobe.crypto
Section 2
//IntUtil (com.adobe.utils.IntUtil)
package com.adobe.utils {
public class IntUtil {
private static var hexChars:String = "0123456789abcdef";
public function IntUtil(){
super();
}
public static function toHex(n:int, bigEndian:Boolean=false):String{
var s:String;
var i:int;
var x:int;
s = "";
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);
}
public static function ror(x:int, n:int):uint{
var nn:int;
nn = (32 - n);
return (((x << nn) | (x >>> (32 - nn))));
}
public static function rol(x:int, n:int):int{
return (((x << n) | (x >>> (32 - n))));
}
}
}//package com.adobe.utils
Section 3
//Music (com.sounds.Music)
package com.sounds {
import flash.display.*;
import flash.media.*;
public class Music extends Sprite {
private static var sound:SoundChannel = new SoundChannel();
private static var ob:Object = new Object();
private static var count:uint = 0;
private static var pulse:Sound;
private static var soundTransform:SoundTransform;
private static var blip1:Sound;
private static var blip2:Sound;
private static var blip4:Sound;
private static var blip5:Sound;
private static var blip6:Sound;
private static var blip8:Sound;
private static var blip3:Sound;
private static var blip9:Sound;
private static var endCount:uint = 56;
private static var blip7:Sound;
public function Music(){
super();
}
public static function playTitle():void{
var r:uint;
var c:uint;
r = (Math.random() * 100);
if ((((r < 20)) && ((((count == (endCount / 2))) || ((count == endCount)))))){
r = ((Math.random() * 6) + 1);
sound = ob[("blip" + r)].play(0, 0, soundTransform);
};
c = (endCount / 4);
if ((((r < 20)) && ((((count == c)) || ((count == (c * 3))))))){
r = ((Math.random() * 7) + 1);
sound = ob[("bleep" + r)].play(0, 0, soundTransform);
};
if (count == endCount){
sound = ob.blip2.play(0, 0, soundTransform);
};
}
public static function playMusic(type:String="title"){
count++;
switch (type){
case "title":
playTitle();
break;
case "inGame":
playInGame();
break;
};
if (count == endCount){
count = 0;
};
}
public static function playInGame():void{
}
public static function init():void{
pulse = new s_pulse();
ob.blip1 = new s_blip1();
ob.blip2 = new s_blip2();
ob.blip3 = new s_blip3();
ob.blip4 = new s_blip4();
ob.blip5 = new s_blip5();
ob.blip6 = new s_blip6();
ob.blip7 = new s_blip7();
ob.blip8 = new s_blip8();
ob.blip9 = new s_blip9();
ob.bleep1 = new s_bleep1();
ob.bleep2 = new s_bleep2();
ob.bleep3 = new s_bleep3();
ob.bleep4 = new s_bleep4();
ob.bleep5 = new s_bleep5();
ob.bleep6 = new s_bleep6();
ob.bleep7 = new s_bleep7();
soundTransform = new SoundTransform(1);
}
public static function stopSound():void{
if (sound){
sound.stop();
};
}
}
}//package com.sounds
Section 4
//Sounds (com.sounds.Sounds)
package com.sounds {
import flash.display.*;
import flash.media.*;
import com.*;
public class Sounds extends Sprite {
public static var madeit:Sound;
public static var bounce:Sound;
public static var enemyhit:Sound;
public static var click:Sound;
public static var coin:Sound;
public static var hit:Sound;
private static var sound:SoundChannel = new SoundChannel();
public static var squeak:Sound;
private static var soundTransform:SoundTransform;
public static var shoot:Sound;
public static var boost:Sound;
public static var collect:Sound;
public static var jump:Sound;
public static var music:Sound;
public static var coin2:Sound;
public static var wallhit1:Sound;
public static var wallhit2:Sound;
public static var wallhit3:Sound;
private static var vol:Number = 1;
public static var explode_tnt1:Sound;
public static var explode_tnt2:Sound;
public static var hitbyspikes:Sound;
public static var explode_tnt3:Sound;
public static var bounceSmall:Sound;
public static var blip1:Sound;
public static var explode_brick:Sound;
public static var explode_crate:Sound;
public static var gameover:Sound;
public static var snd:Sound;
private static var soundsArray:Array = new Array();
public static var enemyshoot1:Sound;
public static var enemyshoot2:Sound;
public function Sounds(){
super();
}
public static function init():void{
blip1 = new s_blip1();
jump = new s_jump();
boost = new sound_jump();
coin = new sound_coin();
coin2 = new sound_coin2();
collect = new sound_collect();
click = new sound_click();
squeak = new sound_squeak();
bounce = new sound_bounce();
bounceSmall = new sound_bounceSmall();
shoot = new s_shoot();
hitbyspikes = new s_hitbyspikes();
hit = new s_hit();
madeit = new s_madeit();
explode_brick = new s_explode_brick();
explode_crate = new s_explode_crate();
explode_tnt1 = new s_explode_tnt1();
explode_tnt2 = new s_explode_tnt2();
explode_tnt3 = new s_explode_tnt3();
enemyshoot1 = new s_enemyshoot1();
enemyshoot2 = new s_enemyshoot2();
enemyhit = new s_enemyhit();
wallhit1 = new s_wallhit1();
wallhit2 = new s_wallhit2();
wallhit3 = new s_wallhit3();
vol = 1.2;
soundTransform = new SoundTransform(vol);
}
public static function playSound(snd:Sound=null, num:uint=0, _vol:Number=1.2):void{
var sndb:Boolean;
var i:uint;
sndb = true;
i = 0;
while (i < soundsArray.length) {
if (soundsArray[i] == snd){
sndb = false;
break;
};
i++;
};
if (((sndb) && (Globals.soundOn))){
if (vol != _vol){
vol = _vol;
soundTransform.volume = vol;
};
sound = snd.play(0, num, soundTransform);
soundsArray.push(snd);
};
}
public static function stopSound():void{
if (sound){
sound.stop();
};
}
public static function flushSoundsArray():void{
soundsArray = [];
}
}
}//package com.sounds
Section 5
//GameLose (com.Ui.GameLose)
package com.Ui {
import flash.events.*;
import flash.display.*;
import net.*;
import flash.text.*;
import com.*;
public class GameLose extends Sprite {
public var btn_playmore:btn_playmore_;
public var btn_replay:btn_replay_;
public var btn_mainMenu:btn_mainMenu_;
public var score_txt:TextField;
public function GameLose():void{
super();
btn_mainMenu.addEventListener(MouseEvent.CLICK, mainMenu, false, 0, true);
btn_replay.addEventListener(MouseEvent.CLICK, replay, false, 0, true);
btn_playmore.addEventListener(MouseEvent.CLICK, URLCaller.sponsorLink, false, 0, true);
score_txt.text = ("" + Globals.score);
}
private function submitscore(e:MouseEvent):void{
URLCaller.submitScore(Globals.score);
}
private function mainMenu(e:MouseEvent):void{
Globals.quit = true;
parent.removeChild(this);
}
private function replay(e:MouseEvent):void{
Globals.quit = true;
Globals.replay = true;
parent.removeChild(this);
}
}
}//package com.Ui
Section 6
//GameWin (com.Ui.GameWin)
package com.Ui {
import flash.events.*;
import flash.display.*;
import net.*;
import flash.text.*;
import com.*;
import com.sounds.*;
public class GameWin extends Sprite {
public var btn_playmore:btn_playmore_;
public var btn_replay:btn_replay_;
public var btn_mainMenu:btn_mainMenu_;
public var score_txt:TextField;
public function GameWin():void{
super();
btn_mainMenu.addEventListener(MouseEvent.CLICK, mainMenu, false, 0, true);
btn_replay.addEventListener(MouseEvent.CLICK, replay, false, 0, true);
btn_playmore.addEventListener(MouseEvent.CLICK, URLCaller.sponsorLink, false, 0, true);
Sounds.stopSound();
score_txt.text = ("" + Globals.score);
}
private function submitscore(e:MouseEvent):void{
URLCaller.submitScore(Globals.score);
}
private function mainMenu(e:MouseEvent):void{
Globals.quit = true;
parent.removeChild(this);
}
private function replay(e:MouseEvent):void{
Globals.quit = true;
Globals.replay = true;
parent.removeChild(this);
}
}
}//package com.Ui
Section 7
//Hud (com.Ui.Hud)
package com.Ui {
import flash.events.*;
import flash.display.*;
import net.*;
import flash.text.*;
import com.*;
public class Hud extends Sprite {
public var time_txt:TextField;
public var level_txt:TextField;
public var lives_txt:TextField;
public var pausedScreen:PausedScreen_;
public var score_txt:TextField;
public var btn_pause:btn_pausegame_;
public var score:uint;// = 0
public var btn_logo:btn_logolink_smaller_;
public function Hud():void{
score = 0;
super();
pausedScreen.visible = false;
btn_pause.addEventListener(MouseEvent.CLICK, pauseGame, false, 0, true);
btn_logo.addEventListener(MouseEvent.CLICK, URLCaller.sponsorLink, false, 0, true);
}
private function pauseGame(e:MouseEvent):void{
if (!Globals.paused){
Globals.paused = true;
pausedScreen.visible = true;
};
}
public function init():void{
updateScore();
this.visible = true;
}
private function updateScore():void{
updateDisplay();
}
public function addScore(num:uint):void{
Globals.score = (Globals.score + num);
updateScore();
}
public function updateDisplay():void{
score_txt.text = ("SCORE: " + Globals.score);
level_txt.text = ("LEVEL: " + Globals.level);
lives_txt.text = ("x " + Globals.lives);
time_txt.text = ("" + Globals.time);
}
}
}//package com.Ui
Section 8
//Instructions (com.Ui.Instructions)
package com.Ui {
import flash.events.*;
import flash.display.*;
import net.*;
public class Instructions extends Sprite {
public var btn_mainMenu:btn_mainMenu_;
public var startGameFunction:Function;
public var titleAnim:MovieClip;
public var btn_logo:btn_logolink_;
public var btn_start:btn_startGame;
public function Instructions():void{
super();
btn_mainMenu.addEventListener(MouseEvent.CLICK, mainMenu, false, 0, true);
btn_start.addEventListener(MouseEvent.CLICK, startGame, false, 0, true);
btn_logo.addEventListener(MouseEvent.CLICK, URLCaller.mainLink, false, 0, true);
}
private function startGame(e:MouseEvent):void{
startGameFunction();
parent.removeChild(this);
}
private function killMe():void{
btn_mainMenu.removeEventListener(MouseEvent.CLICK, mainMenu);
btn_start.removeEventListener(MouseEvent.CLICK, startGame);
btn_logo.removeEventListener(MouseEvent.CLICK, URLCaller.mainLink);
}
private function mainMenu(e:MouseEvent):void{
parent.removeChild(this);
}
}
}//package com.Ui
Section 9
//LevelPopUp (com.Ui.LevelPopUp)
package com.Ui {
import gs.*;
import flash.display.*;
import flash.text.*;
public class LevelPopUp extends Sprite {
public var txt:TextField;
public function LevelPopUp():void{
super();
}
public function init(_txt:String):void{
txt.text = _txt;
this.x = 325;
this.y = 300;
this.alpha = 0;
TweenLite.to(this, 0.3, {delay:0.2, alpha:1, y:250, onComplete:PhaseTwo});
}
private function KillMe():void{
parent.removeChild(this);
}
private function PhaseTwo():void{
TweenLite.to(this, 0.3, {delay:1, alpha:0, y:200, onComplete:KillMe});
}
}
}//package com.Ui
Section 10
//MyContextMenu (com.Ui.MyContextMenu)
package com.Ui {
import flash.events.*;
import flash.display.*;
import net.*;
import flash.ui.*;
public class MyContextMenu extends Sprite {
public function MyContextMenu():void{
super();
}
public function init(target):void{
var my_menu:ContextMenu;
var my_sponsor:*;
var my_moregames:*;
var my_copyright:*;
my_menu = new ContextMenu();
my_menu.hideBuiltInItems();
my_sponsor = new ContextMenuItem("Sponsored by: Stickpage.com");
my_moregames = new ContextMenuItem("Play More Stick Games");
my_copyright = new ContextMenuItem("Copyright - 2009 - thistler");
my_sponsor.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, gotoSponsor, false, 0, true);
my_moregames.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, gotoSponsor, false, 0, true);
my_copyright.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, gotoSite, false, 0, true);
my_menu.customItems.push(my_sponsor, my_moregames, my_copyright);
target.contextMenu = my_menu;
}
function gotoSponsor(e:ContextMenuEvent):void{
URLCaller.sponsorLink();
}
function gotoSite(e:ContextMenuEvent):void{
URLCaller.mainLink();
}
}
}//package com.Ui
Section 11
//PausedScreen (com.Ui.PausedScreen)
package com.Ui {
import flash.events.*;
import flash.display.*;
import net.*;
import com.*;
import com.sounds.*;
public class PausedScreen extends Sprite {
public var btn_playmore:btn_playmore_;
public var btn_quality:btn_music_;
public var btn_quit:btn_quit_;
public var btn_resume:btn_reume_;
public var btn_sound:btn_music_;
public var btn_music:btn_music_;
public function PausedScreen():void{
super();
btn_resume.addEventListener(MouseEvent.CLICK, resumeGame, false, 0, true);
btn_quit.addEventListener(MouseEvent.CLICK, quitGame, false, 0, true);
btn_playmore.addEventListener(MouseEvent.CLICK, URLCaller.sponsorLink, false, 0, true);
btn_music.addEventListener(MouseEvent.CLICK, MusicOnOff, false, 0, true);
btn_sound.addEventListener(MouseEvent.CLICK, SoundOnOff, false, 0, true);
btn_quality.addEventListener(MouseEvent.CLICK, QualityChange, false, 0, true);
btn_sound.txt.text = "SOUND EFFECTS: ON";
btn_quality.txt.text = "QUALITY: HIGH";
}
private function MusicOnOff(e:MouseEvent):void{
if (Globals.musicOn){
Globals.musicOn = false;
btn_music.txt.text = "MUSIC: OFF";
Music.stopSound();
} else {
Globals.musicOn = true;
btn_music.txt.text = "MUSIC: ON";
};
}
private function QualityChange(e:MouseEvent):void{
if (Globals.quality == "HIGH"){
Globals.quality = "MEDIUM";
} else {
if (Globals.quality == "MEDIUM"){
Globals.quality = "LOW";
} else {
if (Globals.quality == "LOW"){
Globals.quality = "HIGH";
};
};
};
Globals.qual(Globals.quality);
btn_quality.txt.text = ("QUALITY: " + Globals.quality);
}
private function SoundOnOff(e:MouseEvent):void{
if (Globals.soundOn){
Globals.soundOn = false;
btn_sound.txt.text = "SOUND EFFECTS: OFF";
Sounds.stopSound();
} else {
Globals.soundOn = true;
btn_sound.txt.text = "SOUND EFFECTS: ON";
};
}
private function resumeGame(e:MouseEvent):void{
this.visible = false;
Globals.paused = false;
}
private function quitGame(e:MouseEvent):void{
Globals.quit = true;
this.visible = false;
}
}
}//package com.Ui
Section 12
//ScreenTransition (com.Ui.ScreenTransition)
package com.Ui {
import gs.*;
import flash.display.*;
public class ScreenTransition extends Sprite {
public var function2:Function;// = null
public var function1:Function;// = null
public function ScreenTransition():void{
function1 = null;
function2 = null;
super();
}
public function init(f1:Function=null, f2:Function=null):void{
function1 = f1;
function2 = f2;
this.alpha = 0;
TweenLite.to(this, 0.3, {alpha:1, onComplete:endFirstTween});
}
public function fadeOut():void{
TweenLite.to(this, 0.3, {alpha:0, onComplete:killMe});
}
private function killMe():void{
parent.removeChild(this);
}
private function endFirstTween():void{
if (function2 != null){
function2();
};
function1();
}
}
}//package com.Ui
Section 13
//TallyScore (com.Ui.TallyScore)
package com.Ui {
import flash.events.*;
import gs.*;
import flash.display.*;
import flash.text.*;
import com.*;
import com.sounds.*;
public class TallyScore extends Sprite {
public var time_txt:TextField;
public var star_txt:TextField;
public var score_txt:TextField;
var timeBonusAmount:uint;// = 0
public var updateHud:Function;
public var btn_next:Btn_next;
public function TallyScore():void{
timeBonusAmount = 0;
super();
this.alpha = 0;
TweenLite.to(this, 0.3, {alpha:1, onComplete:init});
Sounds.stopSound();
btn_next.visible = false;
}
private function init():void{
btn_next.addEventListener(MouseEvent.CLICK, nextLevel, false, 0, true);
this.score_txt.text = ("" + Globals.score);
if (Globals.stars == Globals.totalstars){
starBonus();
} else {
star_txt.text = "0 - COLLECT ALL THE COINS TO GET A BONUS!";
timeBonus();
};
}
private function timeBonus():void{
if (Globals.time > 0){
timeBonusAmount = (timeBonusAmount + Globals.timeBonusAmount);
Globals.score = (Globals.score + Globals.timeBonusAmount);
};
time_txt.text = ("" + timeBonusAmount);
score_txt.text = ("" + Globals.score);
if (Globals.time > 0){
TweenLite.to(this, 0.02, {onComplete:timeBonus});
} else {
btn_next.visible = true;
};
if (Globals.time > 0){
Globals.time--;
};
Sounds.playSound(Sounds.coin2, 0);
if (Globals.time == 0){
Sounds.playSound(Sounds.jump, 0, 0.5);
};
updateHud();
}
public function nextLevel(e:MouseEvent):void{
Globals.finishedLevel = false;
Globals.startLevel = true;
Globals.level++;
}
public function killMe():void{
removeEventListener(MouseEvent.CLICK, nextLevel);
parent.removeChild(this);
}
private function starBonus():void{
Globals.score = (Globals.score + (Globals.starBonusAmount * Globals.level));
star_txt.text = ("" + (Globals.starBonusAmount * Globals.level));
score_txt.text = ("" + Globals.score);
timeBonus();
}
}
}//package com.Ui
Section 14
//TitleScreen (com.Ui.TitleScreen)
package com.Ui {
import flash.events.*;
import gs.*;
import flash.display.*;
import net.*;
import com.*;
public class TitleScreen extends Sprite {
public var btn_playmore:btn_playmore_;
public var btn_startGame_:btn_startGame;
private var startGame:Function;
public var btn_copy:SimpleButton;
public var titleAnim:MovieClip;
public var btn_instructions:btn_instructions_;
public var btn_logo:btn_logolink_;
var newY;
var instructions:Instructions_;
public var neon:MovieClip;
public function TitleScreen():void{
super();
neon.alpha = 0;
}
public function init(_startGame:Function):void{
startGame = _startGame;
btn_startGame_.addEventListener(MouseEvent.CLICK, startGameEvent, false, 0, true);
btn_playmore.addEventListener(MouseEvent.CLICK, URLCaller.sponsorLink, false, 0, true);
btn_logo.addEventListener(MouseEvent.CLICK, URLCaller.sponsorLink, false, 0, true);
btn_instructions.addEventListener(MouseEvent.CLICK, viewInstructions, false, 0, true);
this.btn_copy.addEventListener(MouseEvent.CLICK, URLCaller.mainLink, false, 0, true);
btn_startGame_.addEventListener(MouseEvent.ROLL_OVER, rolly);
btn_playmore.addEventListener(MouseEvent.ROLL_OVER, rolly);
btn_instructions.addEventListener(MouseEvent.ROLL_OVER, rolly);
btn_startGame_.addEventListener(MouseEvent.ROLL_OUT, rollyOut);
btn_playmore.addEventListener(MouseEvent.ROLL_OUT, rollyOut);
btn_instructions.addEventListener(MouseEvent.ROLL_OUT, rollyOut);
}
private function rollyOut(e:MouseEvent):void{
TweenLite.to(neon, 0.3, {alpha:0, y:newY});
}
private function startGameEvent(e:MouseEvent):void{
Globals.lives = Globals.livesStart;
Globals.level = Globals.levelStart;
this.visible = false;
titleAnim.stop();
startGame();
}
private function rolly(e:MouseEvent):void{
newY = (e.target.y - 1);
TweenLite.to(neon, 0.3, {alpha:1, y:newY});
}
private function viewInstructions(e:MouseEvent):void{
instructions = new Instructions_();
instructions.startGameFunction = startGame;
addChild(instructions);
}
}
}//package com.Ui
Section 15
//Globals (com.Globals)
package com {
import flash.display.*;
public class Globals extends Sprite {
public static var totalcupcakes:uint = 0;
public static var gamework;
public static var level:uint = 1;
public static var lives:int = 10;
public static var score:uint = 0;
public static var ID:uint = 1;
public static var totalstars:uint = 0;
public static var starBonusAmount:uint = 150;
public static var livesStart:uint = 10;
public static var paused:Boolean = true;
public static var finishedLevel:Boolean = false;
public static var levelStart:uint = 1;
public static var cupcakes:uint = 0;
public static var time:uint = 90;
public static var quit:Boolean = false;
public static var startLevel:Boolean = false;
public static var totalLevels:uint = 24;
public static var soundOn:Boolean = true;
public static var qual:Function;
public static var timeBonusAmount:uint = 5;
public static var stars:uint = 0;
public static var musicOn:Boolean = true;
public static var replay:Boolean = false;
public static var totallyFinishedLevel:Boolean = false;
public static var player;
public static var platform;
public static var quality:String = "HIGH";
public function Globals(){
super();
}
}
}//package com
Section 16
//Map (com.Map)
package com {
import flash.events.*;
import flash.display.*;
public class Map extends Sprite {
public static var mapHeight:uint;
public static var maps:Object;
public static var mapWidth:uint;
public function Map():void{
super();
}
public static function init(_width, _height):void{
mapWidth = _width;
mapHeight = _height;
maps = new Object();
maps.test = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 1], [1, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 1], [1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 1], [1, 3, 4, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,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, 0, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 1, 21, 21, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 13, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
}
public static function GetBlankMap():Array{
var newMapArray:Array;
var newLine:Array;
var bottomLine:Array;
var i:uint;
newMapArray = new Array();
newLine = new Array();
bottomLine = new Array();
i = 0;
while (i < mapWidth) {
if ((((i == 0)) || ((i == (mapWidth - 1))))){
newLine.push(1);
} else {
newLine.push(0);
};
i++;
};
i = 0;
while (i < mapWidth) {
bottomLine.push(1);
i++;
};
i = 0;
while (i < mapHeight) {
if (i == (mapWidth - 1)){
newMapArray.push(bottomLine);
} else {
newMapArray.push(newLine);
};
i++;
};
return (newMapArray);
}
private static function mainloop(e:Event):void{
}
}
}//package com
Section 17
//TweenLite (gs.TweenLite)
package gs {
import flash.events.*;
import flash.display.*;
import flash.geom.*;
import flash.utils.*;
public class TweenLite {
public var delay:Number;
protected var _hasUpdate:Boolean;
public var started:Boolean;
protected var _subTweens:Array;
public var initted:Boolean;
public var active:Boolean;
public var startTime:Number;
public var target:Object;
public var duration:Number;
protected var _hst:Boolean;
protected var _isDisplayObject:Boolean;
public var gc:Boolean;
public var vars:Object;
public var ease:Function;
public var tweens:Array;
protected var _specialVars:Object;
public var combinedTimeScale:Number;
public var initTime:Number;
private static var _timer:Timer = new Timer(2000);
private static var _classInitted:Boolean;
public static var defaultEase:Function = TweenLite.easeOut;
public static var version:Number = 9.3;
public static var masterList:Dictionary = new Dictionary(false);
public static var currentTime:uint;
public static var overwriteManager:Object;
public static var killDelayedCallsTo:Function = TweenLite.killTweensOf;
public static var timingSprite:Sprite = new Sprite();
public function TweenLite($target:Object, $duration:Number, $vars:Object){
var mode:int;
super();
if ($target == null){
return;
};
if (!_classInitted){
currentTime = getTimer();
timingSprite.addEventListener(Event.ENTER_FRAME, updateAll, false, 0, true);
if (overwriteManager == null){
overwriteManager = {mode:1, enabled:false};
};
_timer.addEventListener("timer", killGarbage, false, 0, true);
_timer.start();
_classInitted = true;
};
this.vars = $vars;
this.duration = (($duration) || (0.001));
this.delay = (($vars.delay) || (0));
this.combinedTimeScale = (($vars.timeScale) || (1));
this.active = Boolean(((($duration == 0)) && ((this.delay == 0))));
this.target = $target;
_isDisplayObject = Boolean(((($target is DisplayObject)) || ($target.hasOwnProperty("isTweenProxy"))));
if (!(this.vars.ease is Function)){
this.vars.ease = defaultEase;
};
if (this.vars.easeParams != null){
this.vars.proxiedEase = this.vars.ease;
this.vars.ease = easeProxy;
};
this.ease = this.vars.ease;
if (!isNaN(Number(this.vars.autoAlpha))){
this.vars.alpha = Number(this.vars.autoAlpha);
this.vars.visible = Boolean((this.vars.alpha > 0));
};
_specialVars = ((this.vars.isTV)==true) ? this.vars.exposedProps : this.vars;
this.tweens = [];
_subTweens = [];
_hst = (this.initted = false);
this.initTime = currentTime;
this.startTime = (this.initTime + (this.delay * 1000));
mode = (((($vars.overwrite == undefined)) || (((!(overwriteManager.enabled)) && (($vars.overwrite > 1)))))) ? overwriteManager.mode : int($vars.overwrite);
if ((((masterList[$target] == undefined)) || (((!(($target == null))) && ((mode == 1)))))){
masterList[$target] = [];
};
masterList[$target].push(this);
if ((((((this.vars.runBackwards == true)) && (!((this.vars.renderOnStart == true))))) || (this.active))){
initTweenVals();
if (this.active){
render((this.startTime + 1));
} else {
render(this.startTime);
};
if (((((!((_specialVars.visible == null))) && ((this.vars.runBackwards == true)))) && (_isDisplayObject))){
this.target.visible = _specialVars.visible;
};
};
}
public function set enabled($b:Boolean):void{
var a:Array;
var found:Boolean;
var i:int;
if ($b){
if (masterList[this.target] == undefined){
masterList[this.target] = [this];
} else {
a = masterList[this.target];
i = (a.length - 1);
while (i > -1) {
if (a[i] == this){
found = true;
break;
};
i--;
};
if (!found){
masterList[this.target].push(this);
};
};
};
this.gc = ($b) ? false : true;
if (this.gc){
this.active = false;
} else {
this.active = this.started;
};
}
public function render($t:uint):void{
var time:Number;
var factor:Number;
var tp:Object;
var i:int;
time = (($t - this.startTime) * 0.001);
if (time >= this.duration){
time = this.duration;
factor = ((((this.ease == this.vars.ease)) || ((this.duration == 0.001)))) ? 1 : 0;
} else {
factor = this.ease(time, 0, 1, this.duration);
};
i = (this.tweens.length - 1);
while (i > -1) {
tp = this.tweens[i];
tp[0][tp[1]] = (tp[2] + (factor * tp[3]));
i--;
};
if (_hst){
i = (_subTweens.length - 1);
while (i > -1) {
_subTweens[i].proxy(_subTweens[i], time);
i--;
};
};
if (_hasUpdate){
this.vars.onUpdate.apply(null, this.vars.onUpdateParams);
};
if (time == this.duration){
complete(true);
};
}
public function activate():void{
this.started = (this.active = true);
if (!this.initted){
initTweenVals();
};
if (this.vars.onStart != null){
this.vars.onStart.apply(null, this.vars.onStartParams);
};
if (this.duration == 0.001){
this.startTime = (this.startTime - 1);
};
}
public function clear():void{
this.tweens = [];
_subTweens = [];
this.vars = {};
_hst = (_hasUpdate = false);
}
protected function addSubTween($name:String, $proxy:Function, $target:Object, $props:Object, $info:Object=null):void{
var p:String;
_subTweens[_subTweens.length] = {name:$name, proxy:$proxy, target:$target, info:$info};
for (p in $props) {
if (typeof($props[p]) == "number"){
this.tweens[this.tweens.length] = [$target, p, $target[p], ($props[p] - $target[p]), $name];
} else {
this.tweens[this.tweens.length] = [$target, p, $target[p], Number($props[p]), $name];
};
};
_hst = true;
}
public function initTweenVals($hrp:Boolean=false, $reservedProps:String=""):void{
var p:String;
var i:int;
var endArray:Array;
var clr:ColorTransform;
var endClr:ColorTransform;
var tp:Object;
if (((!($hrp)) && (overwriteManager.enabled))){
overwriteManager.manageOverwrites(this, masterList[this.target]);
};
if ((this.target is Array)){
endArray = ((this.vars.endArray) || ([]));
i = 0;
while (i < endArray.length) {
if (((!((this.target[i] == endArray[i]))) && (!((this.target[i] == undefined))))){
this.tweens[this.tweens.length] = [this.target, i.toString(), this.target[i], (endArray[i] - this.target[i]), i.toString()];
};
i++;
};
} else {
if (((((!((typeof(_specialVars.tint) == "undefined"))) || ((this.vars.removeTint == true)))) && (this.target.hasOwnProperty("transform")))){
clr = this.target.transform.colorTransform;
endClr = new ColorTransform();
if (_specialVars.alpha != undefined){
endClr.alphaMultiplier = _specialVars.alpha;
delete _specialVars.alpha;
} else {
endClr.alphaMultiplier = this.target.alpha;
};
if (((!((this.vars.removeTint == true))) && (((((!((_specialVars.tint == null))) && (!((_specialVars.tint == ""))))) || ((_specialVars.tint == 0)))))){
endClr.color = _specialVars.tint;
};
addSubTween("tint", tintProxy, {progress:0}, {progress:1}, {target:this.target, color:clr, endColor:endClr});
};
if (((!((_specialVars.frame == null))) && (_isDisplayObject))){
addSubTween("frame", frameProxy, {frame:this.target.currentFrame}, {frame:_specialVars.frame}, {target:this.target});
};
if (((!(isNaN(this.vars.volume))) && (this.target.hasOwnProperty("soundTransform")))){
addSubTween("volume", volumeProxy, this.target.soundTransform, {volume:this.vars.volume}, {target:this.target});
};
if (((!((_specialVars.visible == null))) && (_isDisplayObject))){
addSubTween("visible", visibleProxy, {}, {}, {tween:this});
};
for (p in _specialVars) {
if ((((((((((((((((((((((((((((((((((((p == "ease")) || ((p == "delay")))) || ((p == "overwrite")))) || ((p == "onComplete")))) || ((p == "onCompleteParams")))) || ((p == "runBackwards")))) || ((p == "visible")))) || ((p == "autoOverwrite")))) || ((p == "persist")))) || ((p == "onUpdate")))) || ((p == "onUpdateParams")))) || ((p == "autoAlpha")))) || ((p == "onStart")))) || ((p == "onStartParams")))) || ((p == "renderOnStart")))) || ((p == "proxiedEase")))) || ((p == "easeParams")))) || ((($hrp) && (!(($reservedProps.indexOf(((" " + p) + " ")) == -1))))))){
} else {
if (((!(((_isDisplayObject) && ((((((p == "tint")) || ((p == "removeTint")))) || ((p == "frame"))))))) && (!((((p == "volume")) && (this.target.hasOwnProperty("soundTransform"))))))){
if (typeof(_specialVars[p]) == "number"){
this.tweens[this.tweens.length] = [this.target, p, this.target[p], (_specialVars[p] - this.target[p]), p];
} else {
this.tweens[this.tweens.length] = [this.target, p, this.target[p], Number(_specialVars[p]), p];
};
};
};
};
};
if (this.vars.runBackwards == true){
i = (this.tweens.length - 1);
while (i > -1) {
tp = this.tweens[i];
tp[2] = (tp[2] + tp[3]);
tp[3] = (tp[3] * -1);
i--;
};
};
if (this.vars.onUpdate != null){
_hasUpdate = true;
};
this.initted = true;
}
protected function easeProxy($t:Number, $b:Number, $c:Number, $d:Number):Number{
return (this.vars.proxiedEase.apply(null, arguments.concat(this.vars.easeParams)));
}
public function killVars($vars:Object):void{
if (overwriteManager.enabled){
overwriteManager.killVars($vars, this.vars, this.tweens, _subTweens, []);
};
}
public function get enabled():Boolean{
return ((this.gc) ? false : true);
}
public function complete($skipRender:Boolean=false):void{
if (!$skipRender){
if (!this.initted){
initTweenVals();
};
this.startTime = (currentTime - ((this.duration * 1000) / this.combinedTimeScale));
render(currentTime);
return;
};
if (this.vars.persist != true){
this.enabled = false;
};
if (this.vars.onComplete != null){
this.vars.onComplete.apply(null, this.vars.onCompleteParams);
};
}
public static function frameProxy($o:Object, $time:Number=0):void{
$o.info.target.gotoAndStop(Math.round($o.target.frame));
}
public static function removeTween($t:TweenLite, $clear:Boolean=true):void{
if ($t != null){
if ($clear){
$t.clear();
};
$t.enabled = false;
};
}
public static function visibleProxy($o:Object, $time:Number):void{
var t:TweenLite;
t = $o.info.tween;
if (t.duration == $time){
if (((!((t.vars.runBackwards == true))) && ((t.ease == t.vars.ease)))){
t.target.visible = t.vars.visible;
};
} else {
if (t.target.visible != true){
t.target.visible = true;
};
};
}
public static function killTweensOf($target:Object=null, $complete:Boolean=false):void{
var a:Array;
var i:int;
var tween:TweenLite;
if (((!(($target == null))) && (!((masterList[$target] == undefined))))){
a = masterList[$target];
i = (a.length - 1);
while (i > -1) {
tween = a[i];
if ((($complete) && (!(tween.gc)))){
tween.complete(false);
};
tween.clear();
i--;
};
delete masterList[$target];
};
}
public static function updateAll($e:Event=null):void{
var t:uint;
var ml:Dictionary;
var a:Array;
var i:int;
var tween:TweenLite;
t = (currentTime = getTimer());
ml = masterList;
for each (a in ml) {
i = (a.length - 1);
while (i > -1) {
tween = a[i];
if (tween == null){
} else {
if (tween.active){
tween.render(t);
} else {
if (tween.gc){
a.splice(i, 1);
} else {
if (t >= tween.startTime){
tween.activate();
tween.render(t);
};
};
};
};
i--;
};
};
}
public static function delayedCall($delay:Number, $onComplete:Function, $onCompleteParams:Array=null):TweenLite{
return (new TweenLite($onComplete, 0, {delay:$delay, onComplete:$onComplete, onCompleteParams:$onCompleteParams, overwrite:0}));
}
public static function from($target:Object, $duration:Number, $vars:Object):TweenLite{
$vars.runBackwards = true;
return (new TweenLite($target, $duration, $vars));
}
public static function easeOut($t:Number, $b:Number, $c:Number, $d:Number):Number{
$t = ($t / $d);
return ((((-($c) * $t) * ($t - 2)) + $b));
}
public static function tintProxy($o:Object, $time:Number=0):void{
var n:Number;
var r:Number;
var sc:Object;
var ec:Object;
n = $o.target.progress;
r = (1 - n);
sc = $o.info.color;
ec = $o.info.endColor;
$o.info.target.transform.colorTransform = new ColorTransform(((sc.redMultiplier * r) + (ec.redMultiplier * n)), ((sc.greenMultiplier * r) + (ec.greenMultiplier * n)), ((sc.blueMultiplier * r) + (ec.blueMultiplier * n)), ((sc.alphaMultiplier * r) + (ec.alphaMultiplier * n)), ((sc.redOffset * r) + (ec.redOffset * n)), ((sc.greenOffset * r) + (ec.greenOffset * n)), ((sc.blueOffset * r) + (ec.blueOffset * n)), ((sc.alphaOffset * r) + (ec.alphaOffset * n)));
}
public static function volumeProxy($o:Object, $time:Number=0):void{
$o.info.target.soundTransform = $o.target;
}
protected static function killGarbage($e:TimerEvent):void{
var ml:Dictionary;
var tgt:Object;
var a:Array;
ml = masterList;
for (tgt in ml) {
if (ml[tgt].length == 0){
delete ml[tgt];
};
};
}
public static function to($target:Object, $duration:Number, $vars:Object):TweenLite{
return (new TweenLite($target, $duration, $vars));
}
}
}//package gs
Section 18
//URLCaller (net.URLCaller)
package net {
import flash.events.*;
import com.adobe.crypto.*;
import com.*;
import flash.net.*;
public class URLCaller {
public function URLCaller(){
super();
}
public static function getURL(url:String, window:String="_blank"):void{
navigateToURL(new URLRequest(url), window);
}
public static function mainLink(e:MouseEvent=null):void{
getURL("http://www.thistler.net");
}
public static function sponsorLink(e:MouseEvent=null):void{
getURL("http://www.stickpage.com");
}
public static function submitScore(score:Number):void{
var hashKey:String;
hashKey = MD5.hash((((("gameid=" + Globals.ID) + "&hiscore=") + score) + "cutefreegames.com/"));
getURL(((((("http://http://www.thistler.net/highscores.php?gameid=" + Globals.ID) + "&hiscore=") + score) + "&hash=") + hashKey));
}
}
}//package net
Section 19
//SWFConsole (rl.dev.SWFConsole)
package rl.dev {
import flash.events.*;
import flash.display.*;
import flash.text.*;
import flash.utils.*;
import flash.system.*;
public class SWFConsole extends Sprite {
private static const INPUT_BG_HEIGHT:int = 20;
private static const _FPS_REFRESH_RATE:uint = 1000;
private static const SCROLLHANDLE_COLOUR:int = 0xFFFFFF;
private static const HEADER_HEIGHT:int = 20;
private static const SCROLLHANDLE_WIDTH:int = 10;
private static const TEXT_COLOUR:int = 0xFFFFFF;
private static const HEADER_BG_ALPHA:Number = 0.6;
private static const SCROLLTRACK_ALPHA:Number = 0.5;
private static const SCROLLBUTTON_ALPHA:Number = 0.9;
private static const _HISTORY_STATES:uint = 20;
private static const BACKGROUND_HEIGHT:int = 200;
private static const INPUTAREA_BG_HEIGHT:int = 30;
private static const SCROLLHANDLE_HEIGHT:int = 60;
private static const UPDATE_INTERVAL:int = 1000;
private static const SCROLLTRACK_WIDTH:int = 10;
private static const SCROLLTRACK_COLOUR:int = 0;
private static const INPUT_BG_COLOUR:int = 0xFFFFFF;
private static const SCROLLHANDLE_ALPHA:Number = 0.9;
private static const VERSION:String = "1.0";
private static const INPUT_BG_ALPHA:Number = 0.2;
private static const SHADOW_COLOUR:int = 0;
private static const SCROLLBUTTON_COLOUR:int = 0xFFFFFF;
private static const INPUTAREA_BG_ALPHA:Number = 0.7;
private static const HEADER_BG_COLOUR:int = 0;
private static const WELCOME_MESSAGE:String = "============================================================
New features:
- Resource Monitor - type !resmon to activate
============================================================";
private static const BACKGROUND_ALPHA:Number = 0.7;
private static const BACKGROUND_COLOUR:int = 0;
private static const INPUTAREA_BG_COLOUR:int = 0;
private static var _scrollButtonDown:Sprite;
private static var _enabled:Boolean = false;
private static var _stageHeight:Number;
private static var _stageWidth:Number;
private static var _headerText:TextField;
private static var _percent:Number;
private static var _text:TextField;
private static var _lastcommands:Array;
private static var _avg:Number = 0;
private static var _traceEnabled:Boolean = false;
private static var _textFormat:TextFormat;
private static var _fpsBg:Shape;
private static var _fps:Sprite;
private static var _memUsage:Sprite;
private static var _outputMask:Shape;
private static var _scrollHandle:Sprite;
private static var _fpsTimer:Timer;
private static var _txt_avgfps:TextField;
private static var _timer:Timer;
private static var _txt_mem:TextField;
public static var _activated:Boolean = false;
private static var _history:Array;
private static var _headerTextFormat:TextFormat;
private static var _txt_fps:TextField;
private static var _inputAreaBg:Shape;
private static var _fpsValue:uint = 0;
private static var _inputBg:Shape;
private static var _headerTextShadow:TextField;
private static var _scrollButtonUp:Sprite;
private static var _scrollButtonDownShape:Shape;
private static var _min:Number;
private static var _max:Number;
private static var _stageFrameRate:uint;
private static var _scrollButtonUpShape:Shape;
private static var _scrollTrack:Shape;
private static var _offset:Number;
private static var _inputText:TextField;
private static var _scrollHandleShape:Shape;
private static var _headerTextShadowFormat:TextFormat;
private static var _frames:uint = 0;
private static var _bg:Shape;
private static var _headerbg:Shape;
private static var _lastcommandsindex:Number;
private static var _memBg:Shape;
public function SWFConsole(stageWidth:Number, stageHeight:Number, traceEnabled=false){
super();
_stageWidth = stageWidth;
_stageHeight = stageHeight;
_traceEnabled = traceEnabled;
if (stage){
_init();
} else {
addEventListener(Event.ADDED_TO_STAGE, _init, false, 0, true);
};
}
private function _findChar(command:String, char:String):Boolean{
var i:*;
i = 0;
while (i < command.length) {
if (command.charAt(i) == char){
return (true);
};
i++;
};
return (false);
}
private function _createScrollHandle():void{
_scrollHandleShape = new Shape();
_scrollHandleShape.graphics.beginFill(SCROLLHANDLE_COLOUR, SCROLLHANDLE_ALPHA);
_scrollHandleShape.graphics.drawRect(0, 0, SCROLLHANDLE_WIDTH, SCROLLHANDLE_HEIGHT);
_scrollHandleShape.graphics.endFill();
_scrollHandleShape.cacheAsBitmap = true;
_scrollHandle = new Sprite();
_scrollHandle.addChild(_scrollHandleShape);
_scrollHandle.x = (_scrollTrack.x - (SCROLLHANDLE_WIDTH - SCROLLTRACK_WIDTH));
_scrollHandle.y = _scrollTrack.y;
addChild(_scrollHandle);
}
private function _processCommand(command:String):void{
output(("> " + command));
_lastcommands.push(command);
_lastcommandsindex = (_lastcommands.length - 1);
command = _removeWhitespace(command);
if (command == ""){
return;
};
if (command.charAt(0) == "!"){
_runCommand(command);
} else {
if (_findChar(command, "(")){
_runFunc(command);
} else {
_runProperty(command);
};
};
}
private function _recurseChildren(dispObj:Object, child:String):Object{
var target:Object;
var i:*;
if ((((((dispObj.hasOwnProperty("numChildren") == false)) || ((dispObj.numChildren == null)))) || ((dispObj.numChildren == 0)))){
return (target);
};
i = 0;
while (i < dispObj.numChildren) {
if (dispObj.getChildAt(i).name == child){
return (dispObj.getChildAt(i));
};
if (target == null){
target = _recurseChildren((dispObj.getChildAt(i) as Object), child);
};
i++;
};
return (target);
}
private function _createScrollBar():void{
_createScrollTrack();
_createScrollButtons();
_createScrollHandle();
_scrollTrack.visible = false;
_scrollButtonUp.visible = false;
_scrollButtonDown.visible = false;
_scrollHandle.visible = false;
_min = _scrollTrack.y;
_max = ((_scrollTrack.y + _scrollTrack.height) - _scrollHandle.height);
_scrollHandle.buttonMode = true;
_scrollHandle.addEventListener(MouseEvent.MOUSE_DOWN, _handleDown, false, 0, true);
stage.addEventListener(MouseEvent.MOUSE_UP, _handleUp, false, 0, true);
addEventListener(MouseEvent.MOUSE_WHEEL, _scrollWheel, false, 0, true);
}
private function _handleUp(e:MouseEvent):void{
stage.removeEventListener(MouseEvent.MOUSE_MOVE, _handleMove);
}
private function _createScrollTrack():void{
_scrollTrack = new Shape();
_scrollTrack.graphics.beginFill(SCROLLTRACK_COLOUR, SCROLLTRACK_ALPHA);
_scrollTrack.graphics.drawRect(0, 0, SCROLLTRACK_WIDTH, (BACKGROUND_HEIGHT - 60));
_scrollTrack.graphics.endFill();
_scrollTrack.x = (stage.stageWidth - 30);
_scrollTrack.y = (HEADER_HEIGHT + 30);
_scrollTrack.cacheAsBitmap = true;
addChild(_scrollTrack);
}
public function hide():void{
alpha = 0;
visible = false;
}
private function _keyListener(e:KeyboardEvent):void{
if (_activated){
switch (e.keyCode){
case 192:
if (_enabled){
hide();
} else {
_inputText.text = "";
show();
stage.focus = _inputText;
};
_enabled = !(_enabled);
break;
case 13:
_processCommand(_inputText.text);
_inputText.text = "";
break;
case 38:
if (_lastcommands.length > 0){
_inputText.text = _lastcommands[_lastcommandsindex];
_inputText.setSelection(_inputText.length, _inputText.length);
_lastcommandsindex--;
if (_lastcommandsindex < 0){
_lastcommandsindex = 0;
};
};
break;
};
};
}
private function _calculateFPS(e:TimerEvent):void{
var i:uint;
_fpsValue = ((_frames)>_stageFrameRate) ? _stageFrameRate : _frames;
_txt_fps.text = ("FPS: " + String(_fpsValue));
_frames = 0;
_history.unshift(_fpsValue);
if (_history.length > _HISTORY_STATES){
_history.pop();
};
_avg = 0;
i = 0;
while (i < _history.length) {
_avg = (_avg + _history[i]);
i++;
};
_txt_avgfps.text = ("AVG: " + String(Math.round((_avg / _history.length))));
}
private function _removeWhitespace(str:String):String{
var tempStr:String;
var i:*;
tempStr = "";
i = 0;
while (i < str.length) {
if (str.charAt(i) != " "){
tempStr = (tempStr + str.charAt(i));
};
i++;
};
return (tempStr);
}
private function _handleDown(e:MouseEvent):void{
stage.addEventListener(MouseEvent.MOUSE_MOVE, _handleMove, false, 0, true);
_offset = (mouseY - _scrollHandle.y);
}
private function _createHeader():void{
_headerbg = new Shape();
_headerbg.graphics.beginFill(HEADER_BG_COLOUR, HEADER_BG_ALPHA);
_headerbg.graphics.drawRect(0, 0, stage.stageWidth, HEADER_HEIGHT);
_headerbg.graphics.endFill();
_headerbg.cacheAsBitmap = true;
addChild(_headerbg);
_headerTextShadowFormat = new TextFormat();
_headerTextShadowFormat.font = "_typewriter";
_headerTextShadowFormat.color = SHADOW_COLOUR;
_headerTextShadowFormat.italic = true;
_headerTextShadow = new TextField();
_headerTextShadow.x = 12;
_headerTextShadow.y = 2;
_headerTextShadow.height = HEADER_HEIGHT;
_headerTextShadow.autoSize = TextFieldAutoSize.LEFT;
_headerTextShadow.multiline = false;
_headerTextShadow.defaultTextFormat = _headerTextShadowFormat;
_headerTextShadow.text = ("SWFConsole v" + VERSION);
_headerTextFormat = new TextFormat();
_headerTextFormat.font = "_typewriter";
_headerTextFormat.color = TEXT_COLOUR;
_headerTextFormat.bold;
_headerTextFormat.italic = true;
_headerText = new TextField();
_headerText.x = 10;
_headerText.height = HEADER_HEIGHT;
_headerText.autoSize = TextFieldAutoSize.LEFT;
_headerText.multiline = false;
_headerText.defaultTextFormat = _headerTextFormat;
_headerText.text = ("SWFConsole v" + VERSION);
addChild(_headerTextShadow);
addChild(_headerText);
}
private function _createScrollButtons():void{
_scrollButtonUpShape = new Shape();
_scrollButtonDownShape = new Shape();
_createScrollButtonShape(_scrollButtonUpShape);
_createScrollButtonShape(_scrollButtonDownShape);
_scrollButtonUp = new Sprite();
_scrollButtonUp.addChild(_scrollButtonUpShape);
_scrollButtonUp.x = (stage.stageWidth - 30);
_scrollButtonUp.y = 40;
_scrollButtonUp.buttonMode = true;
_scrollButtonUp.addEventListener(MouseEvent.MOUSE_DOWN, _scrollButtonUpDown, false, 0, true);
addChild(_scrollButtonUp);
_scrollButtonDown = new Sprite();
_scrollButtonDown.addChild(_scrollButtonDownShape);
_scrollButtonDown.scaleY = -1;
_scrollButtonDown.x = (stage.stageWidth - 30);
_scrollButtonDown.y = ((_scrollTrack.y + _scrollTrack.height) + 10);
_scrollButtonDown.buttonMode = true;
_scrollButtonDown.addEventListener(MouseEvent.MOUSE_DOWN, _scrollButtonDownDown, false, 0, true);
addChild(_scrollButtonDown);
}
private function _relocate(e:Event):void{
_headerbg.width = stage.stageWidth;
_bg.width = stage.stageWidth;
_text.width = (stage.stageWidth - 50);
_outputMask.width = (stage.stageWidth - 50);
_inputText.width = (stage.stageWidth - 50);
_inputAreaBg.width = stage.stageWidth;
_inputBg.width = (stage.stageWidth - 50);
_scrollTrack.x = Math.ceil((stage.stageWidth - 30));
_scrollButtonUp.x = Math.ceil((stage.stageWidth - 30));
_scrollButtonDown.x = Math.ceil((stage.stageWidth - 30));
_scrollHandle.x = Math.ceil((stage.stageWidth - 30));
x = Math.ceil((-((stage.stageWidth - _stageWidth)) * 0.5));
y = Math.ceil((-((stage.stageHeight - _stageHeight)) * 0.5));
if (_fps){
_fps.x = Math.ceil(((-((stage.stageWidth - _stageWidth)) * 0.5) + (stage.stageWidth - _fps.width)));
_fps.y = Math.ceil(((-((stage.stageHeight - _stageHeight)) * 0.5) + (stage.stageHeight - _fps.height)));
};
if (_memUsage){
_memUsage.x = Math.ceil(((-((stage.stageWidth - _stageWidth)) * 0.5) + (stage.stageWidth - _memUsage.width)));
_memUsage.y = Math.ceil((((-((stage.stageHeight - _stageHeight)) * 0.5) + (stage.stageHeight - _memUsage.height)) - 32));
};
}
private function _createScrollButtonShape(container:Shape):void{
container.graphics.beginFill(SCROLLBUTTON_COLOUR, SCROLLBUTTON_ALPHA);
container.graphics.moveTo(0, 0);
container.graphics.lineTo(5, -8);
container.graphics.lineTo(10, 0);
container.graphics.lineTo(0, 0);
container.graphics.endFill();
container.cacheAsBitmap = true;
}
private function _removeChar(str:String, char:String):String{
var tempStr:String;
var i:*;
tempStr = "";
i = 0;
while (i < str.length) {
if (str.charAt(i) != char){
tempStr = (tempStr + str.charAt(i));
};
i++;
};
return (tempStr);
}
private function _createBackground():void{
_bg = new Shape();
_bg.graphics.beginFill(BACKGROUND_COLOUR, BACKGROUND_ALPHA);
_bg.graphics.drawRect(0, 0, stage.stageWidth, BACKGROUND_HEIGHT);
_bg.graphics.endFill();
_bg.cacheAsBitmap = true;
_bg.y = HEADER_HEIGHT;
addChild(_bg);
}
private function _createOutputArea():void{
_text = new TextField();
_text.width = (stage.stageWidth - 50);
_text.x = 10;
_text.y = HEADER_HEIGHT;
_text.height = BACKGROUND_HEIGHT;
_text.multiline = true;
_text.wordWrap = true;
_text.autoSize = TextFieldAutoSize.LEFT;
_textFormat = new TextFormat();
_textFormat.color = TEXT_COLOUR;
_textFormat.font = "_typewriter";
_text.defaultTextFormat = _textFormat;
addChild(_text);
_outputMask = new Shape();
_outputMask.graphics.beginFill(0xFF00FF);
_outputMask.graphics.drawRect(0, 0, (stage.stageWidth - 50), BACKGROUND_HEIGHT);
_outputMask.graphics.endFill();
_outputMask.x = 10;
_outputMask.y = HEADER_HEIGHT;
addChild(_outputMask);
_text.mask = _outputMask;
}
private function _initFPS(){
var format:TextFormat;
_fps = new Sprite();
stage.addChild(_fps);
_stageFrameRate = stage.frameRate;
_history = new Array();
_txt_fps = new TextField();
_txt_fps.width = 100;
_txt_fps.height = 16;
_txt_fps.border = false;
_txt_fps.selectable = false;
_txt_avgfps = new TextField();
_txt_avgfps.width = 100;
_txt_avgfps.height = 16;
_txt_avgfps.border = false;
_txt_avgfps.selectable = false;
format = new TextFormat();
format.font = "Verdana";
format.color = 0xFFCC00;
format.size = 10;
_txt_fps.defaultTextFormat = format;
_txt_avgfps.defaultTextFormat = format;
_txt_fps.text = ("FPS: " + _stageFrameRate);
_txt_avgfps.text = ("AVG: " + _stageFrameRate);
_txt_fps.x = (_txt_fps.width - _txt_avgfps.width);
_txt_avgfps.x = 0;
_txt_avgfps.y = _txt_fps.height;
_fps.addChild(_txt_fps);
_fps.addChild(_txt_avgfps);
_fpsBg = new Shape();
_fpsBg.graphics.beginFill(0, 0.7);
_fpsBg.graphics.drawRect(0, 0, _fps.width, _fps.height);
_fpsBg.graphics.endFill();
_fps.addChildAt(_fpsBg, 0);
_fps.x = Math.ceil(((-((stage.stageWidth - _stageWidth)) * 0.5) + (stage.stageWidth - _fps.width)));
_fps.y = Math.ceil(((-((stage.stageHeight - _stageHeight)) * 0.5) + (stage.stageHeight - _fps.height)));
_fpsTimer = new Timer(_FPS_REFRESH_RATE);
_fpsTimer.addEventListener(TimerEvent.TIMER, _calculateFPS, false, 0, true);
_fpsTimer.start();
addEventListener(Event.ENTER_FRAME, _updateFrames, false, 0, true);
}
private function _updateFrames(e:Event):void{
_frames++;
}
private function _runFunc(command:String):void{
var instanceSplit:Array;
var functionSplit:Array;
var parametersSplit:Array;
var instance:Object;
var command = command;
if (_findChar(command, ".")){
instanceSplit = command.split(".");
instance = _recurseChildren(stage, instanceSplit[0]);
functionSplit = instanceSplit[1].split("(");
parametersSplit = functionSplit[1].split(")");
if (instance){
if (instance.hasOwnProperty(functionSplit[0])){
if (parametersSplit[0] == ""){
output(instance[functionSplit[0]]());
} else {
if (_findChar(parametersSplit[0], "\"")){
parametersSplit[0] = _removeChar(parametersSplit[0], "\"");
};
output(instance[functionSplit[0]](parametersSplit[0]));
};
//unresolved jump
var _slot1 = e;
output(_slot1);
} else {
output(((("Function " + functionSplit[0]) + " not found on ") + instanceSplit[0]));
};
} else {
output("Instance not found");
};
} else {
functionSplit = command.split("(");
parametersSplit = functionSplit[1].split(")");
if (stage.hasOwnProperty(functionSplit[0])){
if (parametersSplit[0] == ""){
output(stage[functionSplit[0]]());
} else {
if (_findChar(parametersSplit[0], "\"")){
parametersSplit[0] = _removeChar(parametersSplit[0], "\"");
};
output(stage[functionSplit[0]](parametersSplit[0]));
};
//unresolved jump
var _slot1 = e;
output(_slot1);
} else {
output(((("Function " + functionSplit[0]) + " not found on ") + instanceSplit[0]));
};
};
}
private function _scrollButtonUpDown(e:MouseEvent):void{
_percent = (_percent - 0.1);
if (_percent < 0){
_percent = 0;
};
_text.y = (_headerbg.height + (-(_percent) * (_text.height - _outputMask.height)));
_scrollHandle.y = (_min + ((_max - _min) * _percent));
}
private function _createInputArea():void{
_inputAreaBg = new Shape();
_inputAreaBg.graphics.beginFill(INPUTAREA_BG_COLOUR, INPUTAREA_BG_ALPHA);
_inputAreaBg.graphics.drawRect(0, 0, stage.stageWidth, INPUTAREA_BG_HEIGHT);
_inputAreaBg.graphics.endFill();
_inputAreaBg.y = (HEADER_HEIGHT + BACKGROUND_HEIGHT);
addChild(_inputAreaBg);
_inputBg = new Shape();
_inputBg.graphics.beginFill(INPUT_BG_COLOUR, INPUT_BG_ALPHA);
_inputBg.graphics.drawRect(0, 0, (stage.stageWidth - 50), INPUT_BG_HEIGHT);
_inputBg.graphics.endFill();
_inputBg.x = 10;
_inputBg.y = (_inputAreaBg.y + 5);
addChild(_inputBg);
_inputText = new TextField();
_inputText.width = (stage.stageWidth - 50);
_inputText.x = 10;
_inputText.y = (_inputAreaBg.y + 5);
_inputText.height = INPUT_BG_HEIGHT;
_inputText.multiline = false;
_inputText.type = TextFieldType.INPUT;
_inputText.restrict = "^`";
_inputText.defaultTextFormat = _textFormat;
addChild(_inputText);
}
private function _runProperty(command:String):void{
var instanceSplit:Array;
var propertySplit:Array;
var instance:Object;
var command = command;
if (_findChar(command, "=")){
propertySplit = command.split("=");
if (_findChar(propertySplit[0], ".")){
instanceSplit = propertySplit[0].split(".");
instance = _recurseChildren(stage, instanceSplit[0]);
if (instance){
if (instance.hasOwnProperty(instanceSplit[1])){
if (propertySplit[1] == "false"){
propertySplit[1] = false;
};
instance[instanceSplit[1]] = propertySplit[1];
} else {
output(((("Property " + instanceSplit[1]) + " not found on ") + instanceSplit[0]));
};
} else {
output("Instance not found");
};
} else {
if (stage.hasOwnProperty(propertySplit[0])){
if (propertySplit[1] == "false"){
propertySplit[1] = false;
};
stage[propertySplit[0]] = propertySplit[1];
//unresolved jump
var _slot1 = e;
output("*** ERROR: this property of stage cannot be set ***");
} else {
output((("Property " + propertySplit[0]) + " not found on stage"));
};
};
} else {
if (_findChar(command, ".")){
instanceSplit = command.split(".");
instance = _recurseChildren(stage, instanceSplit[0]);
if (instance){
if (instance.hasOwnProperty(instanceSplit[1])){
output(((((instance.name + ".") + instanceSplit[1]) + " = ") + instance[instanceSplit[1]]));
} else {
output(((("Property " + instanceSplit[1]) + " not found on ") + instanceSplit[0]));
};
} else {
output("Instance not found");
};
} else {
if (stage.hasOwnProperty(command)){
output(((("stage." + command) + " = ") + stage[command]));
} else {
output((("Property " + command) + " not found on stage"));
};
};
};
}
private function _scrollButtonDownDown(e:MouseEvent):void{
_percent = (_percent + 0.1);
if (_percent > 1){
_percent = 1;
};
_text.y = (_headerbg.height + (-(_percent) * (_text.height - _outputMask.height)));
_scrollHandle.y = (_min + ((_max - _min) * _percent));
}
private function _handleMove(e:MouseEvent):void{
_scrollHandle.y = (mouseY - _offset);
if (_scrollHandle.y <= _min){
_scrollHandle.y = _min;
};
if (_scrollHandle.y >= _max){
_scrollHandle.y = _max;
};
_percent = ((_scrollHandle.y - _min) / (_max - _min));
if (_text.height > _outputMask.height){
_text.y = (_headerbg.height + (-(_percent) * (_text.height - _outputMask.height)));
};
e.updateAfterEvent();
}
private function _scrollWheel(e:MouseEvent):void{
if (_scrollButtonDown.visible){
if (e.delta > 0){
_percent = (_percent - 0.1);
if (_percent < 0){
_percent = 0;
};
} else {
if (e.delta < 0){
_percent = (_percent + 0.1);
if (_percent > 1){
_percent = 1;
};
};
};
_text.y = (_headerbg.height + (-(_percent) * (_text.height - _outputMask.height)));
_scrollHandle.y = (_min + ((_max - _min) * _percent));
};
}
private function _initMemUsage():void{
var format:TextFormat;
_memUsage = new Sprite();
stage.addChild(_memUsage);
_txt_mem = new TextField();
_txt_mem.width = 100;
_txt_mem.height = 16;
_txt_mem.border = false;
_txt_mem.selectable = false;
format = new TextFormat();
format.font = "Verdana";
format.color = 6750054;
format.size = 10;
_txt_mem.defaultTextFormat = format;
_txt_mem.text = "MEM: 0 MB";
_memUsage.addChild(_txt_mem);
_memBg = new Shape();
_memBg.graphics.beginFill(0, 0.7);
_memBg.graphics.drawRect(0, 0, _memUsage.width, _memUsage.height);
_memBg.graphics.endFill();
_memUsage.addChildAt(_memBg, 0);
_memUsage.x = Math.ceil(((-((stage.stageWidth - _stageWidth)) * 0.5) + (stage.stageWidth - _memUsage.width)));
_memUsage.y = Math.ceil((((-((stage.stageHeight - _stageHeight)) * 0.5) + (stage.stageHeight - _memUsage.height)) - 32));
_timer = new Timer(UPDATE_INTERVAL);
_timer.addEventListener(TimerEvent.TIMER, displayUsage, false, 0, true);
_timer.start();
}
private function _runCommand(command:String):void{
if (command.substr(0, 7).toLowerCase() == "!resmon"){
if (command.charAt(7) == "0"){
if (_fps != null){
_fps.visible = false;
};
if (_memUsage != null){
_memUsage.visible = false;
};
output("*** RESOURCE MONITOR DISABLED ***");
} else {
if (_fps == null){
_initFPS();
} else {
_fps.visible = true;
};
if (_memUsage == null){
_initMemUsage();
} else {
_memUsage.visible = true;
};
output("*** RESOURCE MONITOR ENABLED ***");
};
return;
};
output("Invalid command");
}
private function _init(e:Event=null):void{
removeEventListener(Event.ADDED_TO_STAGE, _init);
hide();
_createHeader();
_createBackground();
_createOutputArea();
_createScrollBar();
_createInputArea();
x = -(Math.ceil(((stage.stageWidth - _stageWidth) * 0.5)));
y = -(Math.ceil(((stage.stageHeight - _stageHeight) * 0.5)));
_activated = true;
_lastcommands = new Array();
_lastcommandsindex = 0;
output(WELCOME_MESSAGE);
stage.addEventListener(KeyboardEvent.KEY_UP, _keyListener, false, 0, true);
stage.addEventListener(Event.RESIZE, _relocate, false, 0, true);
}
public function show():void{
alpha = 1;
visible = true;
stage.focus = _inputText;
}
private function displayUsage(e:TimerEvent):void{
_txt_mem.text = ("MEM: " + String((Number(((System.totalMemory / 0x0400) / 0x0400)).toFixed(2) + "MB")));
}
public static function output(o:Object):void{
if (_activated){
_text.appendText((String(o) + "\n"));
if (_text.height > _outputMask.height){
_text.y = (_headerbg.height - (_text.height - _outputMask.height));
_scrollHandle.y = _max;
_percent = 1;
if (!_scrollButtonDown.visible){
_scrollTrack.visible = true;
_scrollButtonUp.visible = true;
_scrollButtonDown.visible = true;
_scrollHandle.visible = true;
};
};
};
if (_traceEnabled){
};
}
}
}//package rl.dev
Section 20
//AdvancedButton (rl.display.AdvancedButton)
package rl.display {
import flash.events.*;
import gs.*;
import flash.text.*;
import com.sounds.*;
public class AdvancedButton extends AdvancedMovieClip {
public var _rollOver:Boolean;// = true
public var txt:TextField;
public var selected:Boolean;// = false
public function AdvancedButton(){
selected = false;
_rollOver = true;
super();
addEventListener(Event.ADDED, _init, false, 0, true);
}
protected function _buttonOut(e:MouseEvent):void{
if (((!(selected)) && ((this.totalFrames > 2)))){
TweenLite.to(this, 0.5, {frame:1});
} else {
if (!selected){
this.gotoAndStop(1);
};
};
}
public function _setSelected(_b:Boolean):void{
this.selected = _b;
if (this.selected == false){
TweenLite.to(this, 0.5, {delay:0.2, frame:1});
} else {
TweenLite.to(this, 0.5, {delay:0.2, frame:this.totalFrames});
};
}
private function _buttonClick(e:MouseEvent):void{
Sounds.click.play();
}
protected function _buttonOver(e:MouseEvent):void{
if (((_rollOver) && ((this.totalFrames > 2)))){
TweenLite.to(this, (this.totalFrames / 30), {frame:this.totalFrames});
} else {
if (_rollOver){
this.gotoAndStop(2);
};
};
}
private function _init(e:Event=null):void{
removeEventListener(Event.ADDED_TO_STAGE, _init);
buttonMode = true;
addEventListener(MouseEvent.ROLL_OVER, _buttonOver, false, 0, true);
addEventListener(MouseEvent.ROLL_OUT, _buttonOut, false, 0, true);
addEventListener(MouseEvent.CLICK, _buttonClick, false, 0, true);
this.gotoAndStop(1);
}
override public function destroy():void{
removeEventListener(MouseEvent.ROLL_OVER, _buttonOver);
removeEventListener(MouseEvent.ROLL_OUT, _buttonOut);
super.destroy();
}
}
}//package rl.display
Section 21
//AdvancedMovieClip (rl.display.AdvancedMovieClip)
package rl.display {
import flash.display.*;
public class AdvancedMovieClip extends MovieClip {
private var _eventListeners:Array;
public function AdvancedMovieClip(){
super();
stop();
_eventListeners = new Array();
}
public function destroy():void{
var i:*;
i = 0;
while (i < _eventListeners.length) {
removeEventListener(_eventListeners[i]._type, _eventListeners[i]._listener);
i++;
};
(parent as Object).removeChild(this);
delete ??getglobalscope
[this];
}
override public function addEventListener(type:String, listener:Function, useCapture:Boolean=false, priority:int=0, useWeakReference:Boolean=false):void{
super.addEventListener(type, listener, useCapture, priority, useWeakReference);
_eventListeners.push({_type:type, _listener:listener});
}
public function hide():void{
visible = false;
alpha = 0;
}
public function get o_parent():Object{
return ((parent as Object));
}
public function show():void{
visible = true;
alpha = 1;
}
}
}//package rl.display
Section 22
//Action_5 (RunAndGun_fla.Action_5)
package RunAndGun_fla {
import flash.events.*;
import flash.display.*;
import flash.geom.*;
import flash.media.*;
import flash.text.*;
import flash.net.*;
import flash.utils.*;
import flash.ui.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.printing.*;
import flash.xml.*;
public dynamic class Action_5 extends MovieClip {
public function Action_5(){
super();
addFrameScript(0, frame1);
}
public function onComplete(event:Event):void{
MovieClip(parent).gotoAndPlay("loaded");
}
public function progressHandler(event:ProgressEvent):void{
var PercentLoaded:int;
PercentLoaded = Math.round(((event.target.bytesLoaded / event.target.bytesTotal) * 100));
MovieClip(parent).gotoAndStop(PercentLoaded);
}
function frame1(){
MovieClip(root).stop();
if (root.loaderInfo.bytesLoaded == root.loaderInfo.bytesTotal){
MovieClip(parent).gotoAndPlay("loaded");
};
root.loaderInfo.addEventListener(ProgressEvent.PROGRESS, progressHandler);
root.loaderInfo.addEventListener(Event.COMPLETE, onComplete);
}
}
}//package RunAndGun_fla
Section 23
//hit_84 (RunAndGun_fla.hit_84)
package RunAndGun_fla {
import flash.display.*;
public dynamic class hit_84 extends MovieClip {
public function hit_84(){
super();
addFrameScript(4, frame5);
}
function frame5(){
stop();
}
}
}//package RunAndGun_fla
Section 24
//jumpup_83 (RunAndGun_fla.jumpup_83)
package RunAndGun_fla {
import flash.display.*;
public dynamic class jumpup_83 extends MovieClip {
public function jumpup_83(){
super();
addFrameScript(3, frame4);
}
function frame4(){
stop();
}
}
}//package RunAndGun_fla
Section 25
//MainTimeline (RunAndGun_fla.MainTimeline)
package RunAndGun_fla {
import flash.display.*;
import com.Ui.*;
import com.*;
public dynamic class MainTimeline extends MovieClip {
public var myContextMenu:MyContextMenu;
public function MainTimeline(){
super();
addFrameScript(0, frame1, 3, frame4);
}
public function qualityFunction(q:String="LOW"):void{
stage.quality = q;
}
function frame1(){
myContextMenu = new MyContextMenu();
myContextMenu.init(this);
stop();
}
function frame4(){
Globals.qual = qualityFunction;
qualityFunction("HIGH");
}
}
}//package RunAndGun_fla
Section 26
//moveclips_7 (RunAndGun_fla.moveclips_7)
package RunAndGun_fla {
import flash.display.*;
public dynamic class moveclips_7 extends MovieClip {
public function moveclips_7(){
super();
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package RunAndGun_fla
Section 27
//spaceman_jumping_70 (RunAndGun_fla.spaceman_jumping_70)
package RunAndGun_fla {
import flash.display.*;
public dynamic class spaceman_jumping_70 extends MovieClip {
public function spaceman_jumping_70(){
super();
addFrameScript(44, frame45);
}
function frame45(){
stop();
}
}
}//package RunAndGun_fla
Section 28
//tired_87 (RunAndGun_fla.tired_87)
package RunAndGun_fla {
import flash.display.*;
public dynamic class tired_87 extends MovieClip {
public function tired_87(){
super();
addFrameScript(41, frame42);
}
function frame42(){
stop();
}
}
}//package RunAndGun_fla
Section 29
//victory_86 (RunAndGun_fla.victory_86)
package RunAndGun_fla {
import flash.display.*;
public dynamic class victory_86 extends MovieClip {
public function victory_86(){
super();
addFrameScript(19, frame20);
}
function frame20(){
stop();
}
}
}//package RunAndGun_fla
Section 30
//X_LOAD_3 (RunAndGun_fla.X_LOAD_3)
package RunAndGun_fla {
import flash.events.*;
import flash.display.*;
public dynamic class X_LOAD_3 extends MovieClip {
public var NGButton:SimpleButton;
public function X_LOAD_3(){
super();
addFrameScript(100, frame101, 122, frame123, 136, frame137);
}
public function PlayMovie(event:Event){
gotoAndStop("end");
MovieClip(root).gotoAndStop("gameplay");
}
function frame101(){
play();
}
function frame123(){
NGButton.addEventListener(MouseEvent.CLICK, PlayMovie);
}
function frame137(){
stop();
}
}
}//package RunAndGun_fla
Section 31
//MyCamera (th.GameFramework.Display.MyCamera)
package th.GameFramework.Display {
import flash.display.*;
import flash.geom.*;
public class MyCamera extends Sprite {
private static var stageH:uint;
public static var screen;
public static var p:Point;
public static var target;
private static var stageW:uint;
public function MyCamera():void{
super();
}
public static function snap(targ:Point):void{
var newX:int;
var newY:int;
newX = ((targ.x * -1) + (stageW / 2));
newY = ((targ.y * -1) + (stageH / 2));
if (newX > 0){
newX = 0;
};
if (newX < ((p.x * -1) + stageW)){
newX = ((p.x * -1) + stageW);
};
if (newY > 0){
newY = 0;
};
if (newY < ((p.y * -1) + stageH)){
newY = ((p.y * -1) + stageH);
};
screen.x = newX;
screen.y = newY;
}
public static function init(_p:Point, _s:Point):void{
p = _p;
stageH = _s.y;
stageW = _s.x;
}
public static function mainloop():void{
var newX:int;
var newY:int;
newX = ((target.x * -1) + (stageW / 2));
newY = ((target.y * -1) + (stageH / 2));
if (newX > 0){
newX = 0;
};
if (newX < ((p.x * -1) + stageW)){
newX = ((p.x * -1) + stageW);
};
if (newY > 0){
newY = 0;
};
if (newY < ((p.y * -1) + stageH)){
newY = ((p.y * -1) + stageH);
};
screen.x = (screen.x + Math.floor(((newX - screen.x) / 10)));
screen.y = (screen.y + Math.floor(((newY - screen.y) / 10)));
}
public static function isInFrame(targ:Point):Boolean{
if ((((((((targ.x > (screen.x * -1))) && ((targ.x < ((screen.x * -1) + stageW))))) && ((targ.y > (screen.y * -1))))) && ((targ.y < ((screen.y * -1) + stageH))))){
return (true);
};
return (false);
}
}
}//package th.GameFramework.Display
Section 32
//ScorePopUp (th.GameFramework.Display.ScorePopUp)
package th.GameFramework.Display {
import gs.*;
import flash.display.*;
import flash.geom.*;
import flash.text.*;
public class ScorePopUp extends Sprite {
public var score_txt:TextField;
public function ScorePopUp():void{
super();
}
public function init(p:Point, myText:String):void{
var newY:int;
this.score_txt.text = myText;
this.x = p.x;
this.y = p.y;
newY = (y - 50);
TweenLite.to(this, 2, {y:newY, alpha:0.5, onComplete:phase2});
this.cacheAsBitmap = true;
}
private function phase2():void{
var newY:int;
newY = (y - 10);
TweenLite.to(this, 0.1, {y:newY, alpha:0, onComplete:killMe});
}
private function killMe():void{
parent.removeChild(this);
}
}
}//package th.GameFramework.Display
Section 33
//BasicHitDetection (th.GameFramework.HitDetection.BasicHitDetection)
package th.GameFramework.HitDetection {
import flash.display.*;
public class BasicHitDetection extends Sprite {
public static var gameObjects:Array;
public static var threshold:uint = 25;
public function BasicHitDetection():void{
super();
}
public static function init(_ar:Array):void{
gameObjects = _ar;
}
public static function checkHit(_myOb):Object{
var spriteOb:Object;
var i:uint;
i = 0;
while (i < gameObjects.length) {
spriteOb = gameObjects[i];
if (((!((spriteOb.type == _myOb.type))) && (!(spriteOb.hit)))){
if ((((((((_myOb.x > (spriteOb.x - threshold))) && ((_myOb.x < (spriteOb.x + threshold))))) && ((_myOb.y > (spriteOb.y - (threshold * 2)))))) && ((_myOb.y < (spriteOb.y + 1))))){
return (spriteOb);
};
if ((((((((_myOb.x > (spriteOb.x - threshold))) && ((_myOb.x < (spriteOb.x + threshold))))) && (((_myOb.y - threshold) > (spriteOb.y - (threshold * 2)))))) && (((_myOb.y - threshold) < (spriteOb.y + 1))))){
return (spriteOb);
};
};
i++;
};
return (false);
}
public static function checkSwing(_myOb):Object{
var spriteOb:Object;
var i:uint;
i = 0;
while (i < gameObjects.length) {
spriteOb = gameObjects[i];
if (((!((spriteOb.type == _myOb.type))) && (!(spriteOb.hit)))){
if (((((((((_myOb.x + (25 * _myOb.dir)) > (spriteOb.x - threshold))) && (((_myOb.x + (25 * _myOb.dir)) < (spriteOb.x + threshold))))) && ((_myOb.y > (spriteOb.y - (threshold * 2)))))) && ((_myOb.y < (spriteOb.y + 1))))){
return (spriteOb);
};
if (((((((((_myOb.x + (25 * _myOb.dir)) > (spriteOb.x - threshold))) && (((_myOb.x + (25 * _myOb.dir)) < (spriteOb.x + threshold))))) && (((_myOb.y - threshold) > (spriteOb.y - (threshold * 2)))))) && (((_myOb.y - threshold) < (spriteOb.y + 1))))){
return (spriteOb);
};
};
i++;
};
return (false);
}
}
}//package th.GameFramework.HitDetection
Section 34
//Key (th.GameFramework.Key.Key)
package th.GameFramework.Key {
import flash.events.*;
import flash.display.*;
import rl.dev.*;
public class Key extends Sprite {
public static var traceKey:Boolean = false;
public static var isDown:Object;
public function Key():void{
super();
}
public static function init(targ:Stage, _trace:Boolean=false):void{
traceKey = _trace;
isDown = new Object();
targ.addEventListener(KeyboardEvent.KEY_DOWN, keyDownEvent, false, 0, true);
targ.addEventListener(KeyboardEvent.KEY_UP, keyUpEvent, false, 0, true);
}
private static function keyUpEvent(e:KeyboardEvent):void{
isDown[("k_" + e.keyCode)] = false;
if (traceKey){
SWFConsole.output(((e.keyCode + " = ") + isDown[("k_" + e.keyCode)]));
};
}
private static function keyDownEvent(e:KeyboardEvent):void{
isDown[("k_" + e.keyCode)] = true;
if (traceKey){
SWFConsole.output(((e.keyCode + " = ") + isDown[("k_" + e.keyCode)]));
};
}
public static function reset():void{
isDown = null;
isDown = new Object();
}
}
}//package th.GameFramework.Key
Section 35
//Bullet (th.GameFramework.Platformer.Sprites.Bullet)
package th.GameFramework.Platformer.Sprites {
import gs.*;
import flash.display.*;
import flash.geom.*;
import com.*;
import com.sounds.*;
import th.utilities.*;
import th.GameFramework.Tiles.*;
public class Bullet extends MovieClip {
var ySpeed:Number;
var speed:uint;// = 10
var master:Boolean;// = true
private var hits:uint;// = 0
public var type:String;// = "bullet"
var xSpeed:Number;
public var alive:Boolean;// = true
var angle:Number;
var ob:Object;
public function Bullet(num:int=1):void{
hits = 0;
speed = 10;
ob = new Object();
alive = true;
type = "bullet";
master = true;
super();
this.gotoAndStop(num);
ob.height = 0;
ob.width = 0;
ob.shave = 0;
ob.upleft = true;
ob.downleft = true;
ob.upright = true;
ob.downright = true;
ob.downY = 0;
ob.upY = 0;
ob.leftX = 0;
ob.rightX = 0;
this.cacheAsBitmap = true;
}
private function checkHitAnything():Boolean{
var str:String;
str = ((("t_" + Math.floor((y / 20))) + "_") + Math.floor((x / 20)));
if (Tile.ob[str]){
if (Tile.ob[str].solid){
return (true);
};
if (!Tile.ob[str].walkable){
return (true);
};
};
return (false);
}
public function init(ang:Number, frm:uint):void{
this.rotation = ang;
if (frm == 2){
speed = 5;
master = false;
};
gotoAndStop(frm);
xSpeed = (speed * Math.cos(((ang * Math.PI) / 180)));
ySpeed = (speed * Math.sin(((ang * Math.PI) / 180)));
this.cacheAsBitmap = true;
}
private function playHitWall():void{
var r:uint;
r = ((Math.random() * 3) + 1);
Sounds.playSound(Sounds[("wallhit" + r)], 0);
}
private function checkMaster():void{
if (((((((((ob.downright) && (ob.upright))) && (ob.downleft))) && (ob.downright))) && (alive))){
moveBullet();
if (checkHitAnything()){
hits = 1;
Globals.platform.shootTile(new Point(x, y));
alive = false;
TweenLite.to(this, 0.3, {scaleX:2, scaleY:2, alpha:0, onComplete:killMe});
playHitWall();
};
};
}
public function moveBullet():void{
x = (x + xSpeed);
y = (y + ySpeed);
}
public function killMe():void{
alive = false;
}
private function checkSlave():void{
if (((((((((((((ob.downright) && (ob.upright))) && (ob.downleft))) && (ob.downright))) && (alive))) || (checkTile("evilEye")))) || (checkTile("arrow")))){
moveBullet();
if (GetDistance._get(new Point(x, y), new Point(Globals.player.x, (Globals.player.y - 10))) < 10){
Globals.player.resetToStart();
};
} else {
if (hits < 1){
hits++;
} else {
if (((alive) && ((hits > 0)))){
Globals.platform.shootTile(new Point(x, y));
alive = false;
TweenLite.to(this, 0.3, {scaleX:2, scaleY:2, alpha:0, onComplete:killMe});
};
};
};
}
public function checkTile(str:String):Boolean{
return (Tile.ob[((("t_" + ob.upY) + "_") + ob.leftX)][str]);
}
public function mainLoop():Boolean{
if (((!(Globals.paused)) && (alive))){
Tile.getMyCorners(x, y, ob);
if (master){
checkMaster();
} else {
checkSlave();
};
};
return (alive);
}
}
}//package th.GameFramework.Platformer.Sprites
Section 36
//Enemy (th.GameFramework.Platformer.Sprites.Enemy)
package th.GameFramework.Platformer.Sprites {
import flash.display.*;
import flash.geom.*;
import th.GameFramework.Display.*;
import rl.dev.*;
import com.*;
import th.GameFramework.Tiles.*;
public class Enemy extends Sprite {
public var xx:int;
private var spriteWidth:int;
public var id:uint;// = 1
public var yy:int;
private var canJump:Boolean;// = true
private var jumping:Boolean;// = true
public var type:String;// = "enemy"
public var patrol:Boolean;// = false
public var clip:MovieClip;
public var shave:int;// = 20
private var gravity:Number;// = 1.6
private var speed:Number;// = 0
private var map:Object;
public var headShave:int;// = 5
private var hitTimer:uint;// = 0
public var walking:Boolean;// = true
public var marshie:MovieClip;
public var score:uint;// = 200
var spriteArray:Array;
private var run:Boolean;// = false
public var dir:int;// = 1
private var jumpTopSpeed:int;// = 20
public var hit:Boolean;// = false
private var jumpSpeed:Number;// = 0
private var alive:Boolean;// = true
private var jumpStartSpeed:Number;// = -5
private var ob:Object;
private var topRunSpeed:int;// = 4
private var topSpeed:int;// = 2
public function Enemy():void{
alive = true;
id = 1;
score = 200;
hitTimer = 0;
type = "enemy";
hit = false;
clip = new MovieClip();
marshie = new MovieClip();
dir = 1;
shave = 20;
headShave = 5;
topSpeed = 2;
topRunSpeed = 4;
speed = 0;
jumpTopSpeed = 20;
jumpStartSpeed = -5;
jumpSpeed = 0;
canJump = true;
run = false;
gravity = 1.6;
jumping = true;
walking = true;
patrol = false;
ob = new Object();
super();
}
public function init(_map:Object, _stats:Object):void{
if (Globals.level > 20){
topSpeed = 5;
} else {
if (Globals.level > 12){
topSpeed = 3;
};
};
patrol = _stats.patrol;
spriteArray = _stats.spriteArray;
map = _map;
x = (xx = (_stats.x + 25));
y = (yy = (_stats.y + 50));
dir = _stats.dir;
jumping = false;
walking = true;
spriteWidth = map.tileW;
ob.height = (spriteWidth - headShave);
ob.width = ((spriteWidth / 2) - shave);
ob.shave = shave;
ob.upleft = true;
ob.downleft = true;
ob.upright = true;
ob.downright = true;
ob.downY = 0;
ob.upY = 0;
ob.leftX = 0;
ob.rightX = 0;
clip = marshie;
jump();
}
public function movePlayer():void{
var newX:int;
var newY:int;
var reduceSpeed:Number;
var Testyy:*;
if (!hit){
newX = xx;
newY = yy;
if (walking){
walk(dir);
};
if (jumping){
newY = (yy + jumpSpeed);
Tile.getMyCorners(xx, newY, ob);
if ((((((jumpSpeed < 0)) && (((!(ob.upleft)) || (!(ob.upright)))))) && (!(Tile.isCloud(xx, (newY - map.tileW)))))){
jumpSpeed = 0;
yy = (((Math.floor((newY / map.tileW)) * map.tileH) + ob.height) + 2);
} else {
yy = newY;
if (jumpSpeed < jumpTopSpeed){
jumpSpeed = (jumpSpeed + gravity);
};
gotoFrame(marshie, 2);
};
Tile.getMyCorners(xx, newY, ob);
if ((((((jumpSpeed > 0)) && (jumping))) && (((((!(ob.downleft)) || (!(ob.downright)))) || (Tile.isCloud(xx, newY)))))){
jumping = false;
Testyy = (Math.floor((newY / map.tileW)) * map.tileW);
if (Testyy < y){
jumping = true;
} else {
yy = Testyy;
};
gotoFrame(marshie, 1);
};
};
Tile.getMyCorners(xx, (yy + 1), ob);
if (((((((((walking) && (!(jumping)))) && (ob.downleft))) && (ob.downright))) && (!(Tile.isCloud(xx, (yy + 1)))))){
if (!patrol){
jumpSpeed = 0;
jumping = true;
SWFConsole.output("FALLING YAAAAAA");
} else {
dir = (dir * -1);
xx = (xx + (dir * (8 + topSpeed)));
speed = 0;
};
};
reduceSpeed = 0.4;
if (((((!(jumping)) && (!(walking)))) && ((Math.abs(speed) < 0.6)))){
speed = 0;
};
if (((!(walking)) && ((((((speed < 0)) && ((dir == -1)))) || ((((speed > 0)) && ((dir == 1)))))))){
if (!walking){
walk(dir, false);
};
reduceSpeed = 0.5;
};
if (speed < 0){
speed = (speed + reduceSpeed);
};
if (speed > 0){
speed = (speed - reduceSpeed);
};
ob.xtile = Math.floor((xx / map.tileW));
ob.ytile = Math.floor((yy / map.tileH));
clip.scaleX = dir;
} else {
if (((hit) && (alive))){
hitTimer++;
if (hitTimer > 10){
walking = true;
killMe();
alive = false;
} else {
if (hitTimer > 3){
gotoFrame(marshie, 4);
};
};
};
};
}
public function destroyMe():void{
removeChild(marshie);
parent.removeChild(this);
}
public function jump():void{
if (((!(jumping)) && (canJump))){
gotoFrame(marshie, 2);
jumping = true;
canJump = false;
jumpSpeed = jumpStartSpeed;
if (Math.abs(speed) > 6){
jumpSpeed = (jumpStartSpeed - (Math.abs(speed) / 3));
};
};
}
public function killMe():void{
var i:uint;
i = 0;
while (i < spriteArray.lengthl) {
if (spriteArray[i].name == this.name){
spriteArray.splice(i, 1);
break;
};
i++;
};
parent.removeChild(this);
}
public function walk(_dir:int=1, calculateSpeed:Boolean=true):void{
var newX:*;
var canWalk:Boolean;
var fastestSpeed:uint;
if (!hit){
newX = xx;
canWalk = false;
fastestSpeed = topSpeed;
if (run){
fastestSpeed = topRunSpeed;
};
if (calculateSpeed){
walking = true;
};
if (calculateSpeed){
if ((((speed < fastestSpeed)) && ((speed > (fastestSpeed * -1))))){
speed = (speed + (0.6 * dir));
};
};
newX = (xx + speed);
Tile.getMyCorners(newX, (yy - 1), ob);
if (dir == 1){
if (((ob.downright) && (ob.upright))){
xx = (xx + speed);
} else {
speed = 0;
dir = -1;
};
} else {
if (dir == -1){
if (((ob.downleft) && (ob.upleft))){
xx = (xx + speed);
} else {
speed = 0;
dir = 1;
};
};
};
ob.xtile = Math.floor((xx / map.tileW));
ob.ytile = Math.floor((yy / map.tileH));
gotoFrame(marshie, 2);
marshie.scaleX = dir;
};
}
private function gotoFrame(_clip:MovieClip, f:uint):void{
if (_clip.currentFrame != f){
_clip.gotoAndStop(f);
};
}
public function hitMe():void{
var scorePopUp:ScorePopUp;
gotoFrame(marshie, 3);
walking = false;
jumping = false;
hit = true;
hitTimer = 0;
SWFConsole.output("HIT MEEEEEE");
scorePopUp = new ScorePopUp();
scorePopUp.init(new Point(x, y), (score + " pts"));
parent.addChild(scorePopUp);
}
}
}//package th.GameFramework.Platformer.Sprites
Section 37
//Player (th.GameFramework.Platformer.Sprites.Player)
package th.GameFramework.Platformer.Sprites {
import gs.*;
import flash.display.*;
import flash.geom.*;
import rl.dev.*;
import com.*;
import com.sounds.*;
import th.utilities.*;
import th.GameFramework.Tiles.*;
import th.GameFramework.Key.*;
public class Player extends Sprite {
public var xx:int;// = 30
private var spriteWidth:int;
private var ob:Object;
public var id:uint;// = 0
private var canJump:Boolean;// = false
public var yy:int;// = 30
public var jumping:Boolean;// = true
public var invincible:Boolean;// = true
public var startY:int;// = 30
public var type:String;// = "player"
public var startX:int;// = 30
public var shave:int;// = 5
private var gravity:Number;// = 0.9
private var speed:Number;// = 0
private var map:Object;
public var headShave:int;// = 0
private var updateHud:Function;
private var addScore:Function;
public var walking:Boolean;// = false
private var bounce:uint;// = 0
public var hit:Boolean;// = false
private var run:Boolean;// = false
public var dir:int;// = 1
private var jumpTopSpeed:int;// = 15
private var jumpSpeed:Number;// = 0
public var bunnyMc:MovieClip;
private var jumpStartSpeed:Number;// = -10
private var invincibleCounter:uint;// = 0
private var canLimbo:Boolean;// = true
private var topRunSpeed:int;// = 6
private var topSpeed:int;// = 5
private var limbo:Boolean;// = false
public function Player():void{
hit = false;
id = 0;
invincible = true;
invincibleCounter = 0;
type = "player";
bunnyMc = new MovieClip();
xx = 30;
yy = 30;
startX = 30;
startY = 30;
dir = 1;
shave = 5;
headShave = 0;
topSpeed = 5;
topRunSpeed = 6;
speed = 0;
jumpTopSpeed = 15;
jumpStartSpeed = -10;
jumpSpeed = 0;
canJump = false;
run = false;
gravity = 0.9;
bounce = 0;
limbo = false;
canLimbo = true;
jumping = true;
walking = false;
ob = new Object();
super();
}
public function movePlayer():void{
var newX:int;
var newY:int;
var reduceSpeed:Number;
var Testyy:*;
if (!Globals.paused){
newX = xx;
newY = yy;
if (jumping){
newY = (yy + jumpSpeed);
Tile.getMyCorners(xx, newY, ob);
if ((((((jumpSpeed < 0)) && (((!(ob.upleft)) || (!(ob.upright)))))) && (!(Tile.isCloud(xx, (newY - map.tileW)))))){
jumpSpeed = 0;
yy = (((Math.floor((newY / map.tileW)) * map.tileH) + ob.height) + 2);
SWFConsole.output("hit head");
} else {
yy = newY;
gotoFrame(bunnyMc, 3);
};
if (jumpSpeed < jumpTopSpeed){
jumpSpeed = (jumpSpeed + gravity);
};
Tile.getMyCorners(xx, newY, ob);
if ((((((jumpSpeed > 0)) && (jumping))) && (((((!(ob.downleft)) || (!(ob.downright)))) || (Tile.isCloud(xx, newY)))))){
jumping = false;
Testyy = (Math.floor((newY / map.tileW)) * map.tileW);
if (Testyy < y){
jumping = true;
} else {
yy = Testyy;
};
SWFConsole.output("land on tile");
gotoFrame(bunnyMc, 1);
};
};
Tile.getMyCorners(xx, (yy + 1), ob);
if (((((((!(jumping)) && (ob.downleft))) && (ob.downright))) && (!(Tile.isCloud(xx, (yy + 1)))))){
jumpSpeed = 0;
jumping = true;
};
reduceSpeed = 0.6;
if (((!(walking)) && ((Math.abs(speed) < 1)))){
speed = 0;
};
if (((!(walking)) && ((((speed > 0)) || ((speed < 0)))))){
if (!walking){
walk(dir, false);
};
reduceSpeed = 1;
};
if (speed < 0){
speed = (speed + reduceSpeed);
};
if (speed > 0){
speed = (speed - reduceSpeed);
};
checkKeys();
ob.xtile = Math.floor((xx / map.tileW));
ob.ytile = Math.floor((yy / map.tileH));
if (parent.mouseX < xx){
bunnyMc.scaleX = -1;
} else {
bunnyMc.scaleX = 1;
};
if (((invincible) && (!(Globals.paused)))){
doInvincible();
} else {
this.visible = true;
};
checkHitBySpikes();
checkHitBoosts();
if (!jumping){
checkHitPerishableTile();
};
checkIfReachGoal();
checkPickUpCoin();
};
}
public function init(_map:Object, stat:Object):void{
addScore = stat.scoreFunction;
updateHud = stat.updateHud;
map = _map;
x = startX;
y = startY;
jumping = false;
walking = false;
spriteWidth = map.tileW;
ob.height = ((spriteWidth - headShave) - 2);
ob.width = ((spriteWidth / 2) - shave);
ob.shave = shave;
ob.upleft = true;
ob.downleft = true;
ob.upright = true;
ob.downright = true;
ob.downY = 0;
ob.upY = 0;
ob.leftX = 0;
ob.rightX = 0;
}
private function checkKeys():void{
if (((!(Key.isDown["k_65"])) && (!(Key.isDown["k_68"])))){
walking = false;
if (!jumping){
gotoFrame(bunnyMc, 1);
};
};
if (!Key.isDown["k_87"]){
if (jumpSpeed < 0){
jumpSpeed = (jumpSpeed + gravity);
};
canJump = true;
};
}
private function doInvincible():void{
invincibleCounter++;
if (OddOrEven.isEven(invincibleCounter)){
if (this.visible){
this.visible = false;
} else {
this.visible = true;
};
};
if (invincibleCounter > 60){
invincible = false;
this.visible = true;
};
}
public function destroyMe():void{
removeChild(bunnyMc);
parent.removeChild(this);
}
public function jump(jspeed:Number=-10):void{
if (((!(jumping)) && (canJump))){
SWFConsole.output("JUMPING START");
Sounds.playSound(Sounds.jump, 0);
gotoFrame(bunnyMc, 3);
jumping = true;
canJump = false;
jumpSpeed = jspeed;
if ((((Math.abs(speed) > 6)) && (!((jumpSpeed == 0))))){
jumpSpeed = (jumpStartSpeed - (Math.abs(speed) / 3));
};
jumpSpeed = (jumpSpeed - bounce);
SWFConsole.output(("speed = " + Math.abs(speed)));
SWFConsole.output(("jumpspeed = " + jumpSpeed));
bounce = 0;
};
}
public function setStart(p:Point):void{
startY = (yy = (y = p.y));
startX = (xx = (x = p.x));
}
private function finishDive():void{
limbo = false;
}
public function dive():void{
if (((((!(jumping)) && (!(limbo)))) && (canLimbo))){
gotoFrame(bunnyMc, 4);
limbo = true;
canLimbo = false;
TweenLite.to(bunnyMc, 0, {delay:1.5, onComplete:finishDive});
speed = ((topSpeed * dir) * 2);
};
}
public function shoot():void{
}
public function resetToStart():void{
if (((!(hit)) && (!(invincible)))){
bunnyMc.alpha = 0;
TweenLite.to(this, 1, {onComplete:doReset});
Globals.platform.addSparks(new Point(xx, (yy - 10)), 1, 15);
Globals.platform.addSparks(new Point(xx, (yy - 10)), 7, 10);
Sounds.playSound(Sounds.hitbyspikes, 0);
hit = true;
};
}
private function pickUpCoin():void{
SWFConsole.output("COIN");
Globals.platform.clearTile(Math.floor((xx / 20)), Math.floor(((yy - 5) / 20)));
Globals.platform.addScore(new Point(xx, (yy - 10)), 50);
Sounds.playSound(Sounds.coin, 0);
Globals.stars++;
}
private function checkIfReachGoal():void{
var newY:*;
if (((((Tile._is(xx, (yy - 2), "goal")) && (!(Globals.finishedLevel)))) && (!(hit)))){
newY = (y - 20);
Globals.paused = true;
TweenLite.to(this, 1, {y:newY, onComplete:finishLevel1});
Sounds.playSound(Sounds.madeit, 0);
};
}
public function hitByEnemy():void{
resetInvincible();
}
private function checkPickUpCoin():void{
if (Tile._is(xx, (yy - 5), "coin")){
pickUpCoin();
};
}
private function checkHitBoosts():void{
if (Tile._is(xx, (yy - 5), "boostR")){
speed = 18;
dir = 1;
Sounds.playSound(Sounds.blip1, 0);
};
if (Tile._is(xx, (yy - 5), "boostL")){
speed = -18;
dir = -1;
Sounds.playSound(Sounds.blip1, 0);
};
if (Tile._is(xx, (yy - 5), "boost")){
if (!jumping){
jump(-20);
} else {
jumpSpeed = -20;
};
Sounds.playSound(Sounds.boost, 0);
};
}
public function doReset():void{
Globals.lives--;
if (Globals.lives < 0){
Globals.quit = true;
} else {
Globals.gamework.hud.updateDisplay();
hit = false;
yy = (y = startY);
xx = (x = startX);
bunnyMc.alpha = 1;
resetInvincible();
};
}
public function finishLevel2():void{
Globals.finishedLevel = true;
}
public function finishLevel1():void{
var newY:int;
var levelPopUp:LevelPopUp_;
Globals.paused = true;
newY = (yy - 10);
TweenLite.to(this, 2, {yy:newY, onComplete:finishLevel2});
levelPopUp = new LevelPopUp_();
levelPopUp.init("WELL DONE!");
parent.parent.parent.addChild(levelPopUp);
}
private function checkHitPerishableTile():void{
if (Tile._is(xx, yy, "crumble")){
Globals.platform.crumbleTile(new Point(xx, yy));
};
}
private function finishedHit():void{
var gameLose:GameLose_;
if (Globals.lives > 0){
Globals.lives--;
updateHud();
hit = false;
y = (yy = startY);
x = (xx = startX);
Globals.paused = false;
resetInvincible();
} else {
gameLose = new GameLose_();
parent.addChild(gameLose);
};
}
public function walk(_dir:int=1, calculateSpeed:Boolean=true):void{
var newX:*;
var canWalk:Boolean;
var fastestSpeed:uint;
newX = xx;
canWalk = false;
fastestSpeed = topSpeed;
if (run){
fastestSpeed = topRunSpeed;
};
if (calculateSpeed){
walking = true;
};
dir = _dir;
if (calculateSpeed){
if ((((speed < fastestSpeed)) && ((speed > (fastestSpeed * -1))))){
speed = (speed + (1 * dir));
};
};
newX = (xx + speed);
Tile.getMyCorners(newX, (yy - 1), ob);
if (dir == 1){
if (((((ob.downright) && (ob.upright))) && (ob.downleft))){
xx = (xx + speed);
} else {
speed = 0;
};
};
if (dir == -1){
if (((((ob.downleft) && (ob.upleft))) && (ob.downright))){
xx = (xx + speed);
} else {
speed = 0;
};
};
ob.xtile = Math.floor((xx / map.tileW));
ob.ytile = Math.floor((yy / map.tileH));
if (!jumping){
gotoFrame(bunnyMc, 2);
};
}
public function gotoFrame(clip:MovieClip, f:uint):void{
if (((((!((clip.currentFrame == f))) && (!((clip.currentFrame == 5))))) && (!(limbo)))){
clip.gotoAndStop(f);
};
}
public function hitEnemy(hitOb:Object):void{
}
public function resetInvincible():void{
invincible = true;
invincibleCounter = 0;
}
public function getShootSpeeds():Number{
var newPoint:Point;
var adjside:*;
var oppside:*;
var angle:*;
adjside = (parent.mouseX - xx);
oppside = (-1 * (parent.mouseY - (yy - 15)));
angle = Math.atan2(oppside, adjside);
angle = Math.round(((angle / Math.PI) * 180));
return ((-1 * angle));
}
private function checkHitBySpikes():void{
if (Tile.isSpike(xx, (yy - 5))){
invincible = false;
resetToStart();
};
}
private function checkHitWall(xxx, yyy):Boolean{
var tempx:uint;
var tempy:uint;
var tileName:String;
tempx = (xxx / map.tileW);
tempy = (yyy / map.tileW);
tileName = ((("t_" + tempx) + "_") + tempy);
if (Tile.ob[tileName]){
if (Tile.ob[tileName].walkable){
return (true);
};
};
return (false);
}
}
}//package th.GameFramework.Platformer.Sprites
Section 38
//Spark (th.GameFramework.Platformer.Sprites.Spark)
package th.GameFramework.Platformer.Sprites {
import flash.events.*;
import flash.display.*;
import com.*;
import th.GameFramework.Tiles.*;
public class Spark extends MovieClip {
var ySpeed:Number;
var speed:uint;// = 15
var master:Boolean;// = true
private var hits:uint;// = 0
var rotating:Boolean;// = false
public var type:String;// = "spark"
var xSpeed:Number;
public var alive:Boolean;// = true
var angle:Number;
var ob:Object;
public function Spark():void{
hits = 0;
speed = 15;
ob = new Object();
alive = true;
type = "spark";
master = true;
rotating = false;
super();
ob.height = 0;
ob.width = 0;
ob.shave = 0;
ob.upleft = true;
ob.downleft = true;
ob.upright = true;
ob.downright = true;
ob.downY = 0;
ob.upY = 0;
ob.leftX = 0;
ob.rightX = 0;
}
public function init(ang:Number, frm:uint):void{
this.rotation = ang;
if ((((frm == 2)) || ((frm == 1)))){
speed = 2;
rotating = true;
};
if (frm == 3){
speed = 8;
};
if (frm == 4){
speed = 10;
};
if (frm == 6){
speed = 15;
};
if (frm == 7){
speed = 5;
};
this.gotoAndStop(frm);
xSpeed = (speed * Math.cos(((ang * Math.PI) / 180)));
ySpeed = (speed * Math.sin(((ang * Math.PI) / 180)));
this.cacheAsBitmap = true;
this.cacheAsBitmap = true;
}
private function checkSpark():void{
if (((((((((((ob.downright) && (ob.upright))) && (ob.downleft))) && (ob.downright))) && (alive))) && ((alpha > 0.5)))){
moveBullet();
alpha = (alpha - 0.02);
if (alpha <= 0.5){
hits = 1;
};
} else {
if (hits < 1){
hits++;
} else {
if (((alive) && ((hits > 0)))){
alive = false;
killMe();
};
};
};
}
public function moveBullet():void{
x = (x + xSpeed);
y = (y + ySpeed);
}
public function killMe():void{
alive = false;
}
public function mainLoop(e:Event=null):void{
if (((!(Globals.paused)) && (alive))){
Tile.getMyCorners(x, y, ob);
checkSpark();
if (rotating){
rotation = (rotation + 15);
};
};
}
}
}//package th.GameFramework.Platformer.Sprites
Section 39
//TileSprite (th.GameFramework.Platformer.Sprites.TileSprite)
package th.GameFramework.Platformer.Sprites {
import gs.*;
import flash.display.*;
import flash.geom.*;
import th.GameFramework.Display.*;
import com.*;
import com.sounds.*;
import th.GameFramework.Tiles.*;
public class TileSprite {
private var strength:Number;// = 5
private var bullet:Bullet;
public var name:String;// = ""
public var alive:Boolean;// = true
public var tweenSprite:Object;
public var perish:Boolean;// = false
public var tileMc:MovieClip;
public var aboutToCrumble:Boolean;// = false
public var p:Point;
public var crumbled:Boolean;// = false
public var type:String;// = ""
public function TileSprite(){
strength = 5;
alive = true;
name = "";
perish = false;
type = "";
crumbled = false;
aboutToCrumble = false;
tweenSprite = new Object();
super();
}
private function blowTNT(str:String):Boolean{
if (((((Tile.ob[str].crate) || (Tile.ob[str].brick))) || (Tile.ob[str].tnt))){
return (true);
};
return (false);
}
private function commitCrumble():void{
crumbled = true;
TweenLite.to(tileMc, 1, {delay:5, alpha:1, onComplete:resetCrumbled});
Tile.ob[tileMc.name].walkable = true;
}
public function hitMe(_strength:Number=1):void{
strength = (strength - _strength);
if (strength < 0){
addSparks();
killMe();
};
}
public function killMe():void{
var r:uint;
if (type == "tnt"){
Globals.platform.addScore(new Point((tileMc.x + 10), (tileMc.y + 10)), 200);
r = ((Math.random() * 3) + 1);
Sounds.playSound(Sounds[("explode_tnt" + r)], 0);
};
if (type == "crate"){
Globals.platform.addScore(new Point((tileMc.x + 10), (tileMc.y + 10)), 100);
Sounds.playSound(Sounds.explode_crate, 0);
};
if (type == "brick"){
Globals.platform.addScore(new Point((tileMc.x + 10), (tileMc.y + 10)), 500);
Sounds.playSound(Sounds.explode_brick, 0);
};
if (type == "evil_eye"){
Globals.platform.addScore(new Point((tileMc.x + 10), (tileMc.y + 10)), 1000);
Sounds.playSound(Sounds.enemyhit, 0);
};
if (type == "tnt"){
checkTNT();
};
Tile.resetTile(new Point(Math.floor((tileMc.x / 20)), Math.floor((tileMc.y / 20))));
this.alive = false;
type = "";
removeAll();
tileMc.parent.removeChild(tileMc);
}
public function init(_type:String="", _tileMc:MovieClip=null):void{
crumbled = false;
aboutToCrumble = false;
perish = false;
tileMc = _tileMc;
type = _type;
switch (_type){
case "evil_eye":
perish = true;
strength = 9;
TweenLite.to(this, 0, {delay:5, onComplete:fireWeapon});
break;
case "crate":
perish = true;
strength = 2;
break;
case "tnt":
perish = true;
type = "tnt";
strength = 1;
break;
case "arrow":
TweenLite.to(this, 0, {delay:5, onComplete:fireWeapon});
break;
};
}
private function checkTNT():void{
var str:String;
var y:uint;
var x:uint;
y = tileMc.y;
x = tileMc.x;
str = ((("t_" + Math.floor(((y + 20) / 20))) + "_") + Math.floor((x / 20)));
if (blowTNT(str)){
Globals.platform.blowTile(str, p);
};
str = ((("t_" + Math.floor(((y - 20) / 20))) + "_") + Math.floor((x / 20)));
if (blowTNT(str)){
Globals.platform.blowTile(str, p);
};
str = ((("t_" + Math.floor((y / 20))) + "_") + Math.floor(((x - 20) / 20)));
if (blowTNT(str)){
Globals.platform.blowTile(str, p);
};
str = ((("t_" + Math.floor((y / 20))) + "_") + Math.floor(((x + 20) / 20)));
if (blowTNT(str)){
Globals.platform.blowTile(str, p);
};
str = ((("t_" + Math.floor(((y + 20) / 20))) + "_") + Math.floor(((x - 20) / 20)));
if (blowTNT(str)){
Globals.platform.blowTile(str, p);
};
str = ((("t_" + Math.floor(((y + 20) / 20))) + "_") + Math.floor(((x + 20) / 20)));
if (blowTNT(str)){
Globals.platform.blowTile(str, p);
};
str = ((("t_" + Math.floor(((y - 20) / 20))) + "_") + Math.floor(((x + 20) / 20)));
if (blowTNT(str)){
Globals.platform.blowTile(str, p);
};
str = ((("t_" + Math.floor(((y - 20) / 20))) + "_") + Math.floor(((x - 20) / 20)));
if (blowTNT(str)){
Globals.platform.blowTile(str, p);
};
}
private function resetCrumbled():void{
crumbled = (aboutToCrumble = false);
Tile.ob[tileMc.name].walkable = false;
}
private function checkLevelOver():void{
if (Globals.finishedLevel){
alive = false;
tileMc.parent.removeChild(tileMc);
};
}
private function fireWeapon():void{
var rnd:Number;
if (alive){
checkLevelOver();
};
if (((alive) && ((type == "evil_eye")))){
if (MyCamera.isInFrame(new Point(tileMc.x, tileMc.y))){
Globals.gamework.enemyShoot(new Point((tileMc.x + 10), (tileMc.y + 10)));
};
rnd = ((Math.random() * 3) + 5);
TweenLite.to(this, 0, {delay:rnd, onComplete:fireWeapon});
} else {
if (((alive) && ((type == "arrow")))){
if (MyCamera.isInFrame(new Point(tileMc.x, tileMc.y))){
if (tileMc.currentFrame == 15){
Globals.gamework.enemyArrow(new Point((tileMc.x + 10), (tileMc.y + 10)), 0);
};
if (tileMc.currentFrame == 16){
Globals.gamework.enemyArrow(new Point((tileMc.x + 10), (tileMc.y + 10)), 180);
};
if (tileMc.currentFrame == 17){
Globals.gamework.enemyArrow(new Point((tileMc.x + 10), (tileMc.y + 10)), 270);
};
if (tileMc.currentFrame == 18){
Globals.gamework.enemyArrow(new Point((tileMc.x + 10), (tileMc.y + 10)), 90);
};
};
TweenLite.to(this, 0, {delay:3, onComplete:fireWeapon});
};
};
}
public function startCrumble():void{
if (((!(crumbled)) && (!(aboutToCrumble)))){
aboutToCrumble = true;
TweenLite.to(tileMc, 0.3, {alpha:0, delay:2, onComplete:commitCrumble});
};
}
public function removeAll():void{
this.alive = false;
type = "";
bullet = null;
p = null;
tweenSprite = null;
}
private function addSparks():void{
if (type != "brick"){
Globals.platform.addSparks(new Point((tileMc.x + 10), (tileMc.y + 10)), 3, 6);
};
Globals.platform.addSparks(new Point((tileMc.x + 10), (tileMc.y + 10)), 4, 5);
if ((((type == "evil_eye")) || ((type == "tnt")))){
Globals.platform.addSparks(new Point((tileMc.x + 10), (tileMc.y + 10)), 2, 10);
};
if (type == "tnt"){
Globals.platform.addSparks(new Point((tileMc.x + 10), (tileMc.y + 10)), 6, 10);
};
}
}
}//package th.GameFramework.Platformer.Sprites
Section 40
//Platformer (th.GameFramework.Platformer.Platformer)
package th.GameFramework.Platformer {
import gs.*;
import flash.display.*;
import flash.geom.*;
import th.GameFramework.Platformer.Sprites.*;
import rl.dev.*;
import com.*;
public class Platformer extends Sprite {
public var playerStart:Point;
public var sparks:Array;
var map:Object;
public var tileObs:Array;
var tweenObs:Array;
var newSprite:Sprite;
public var bullets:Array;
var backgroundImage:Bitmap;
var tilesArray:Array;
public var alive:Boolean;// = false
public function Platformer():void{
tilesArray = new Array();
tweenObs = new Array();
alive = false;
bullets = new Array();
sparks = new Array();
super();
}
private function tileHit(tileX:uint, tileY:uint):void{
var tileImage:TileSprite;
var i:uint;
i = 0;
while (i < tileObs.length) {
tileImage = tileObs[i];
if ((((((tileImage.tileMc.name == ((("t_" + tileY) + "_") + tileX))) && (tileImage.alive))) && (tileImage.perish))){
tileImage.tileMc.alpha = 0.5;
TweenLite.to(tileImage.tileMc, 0.3, {alpha:1});
tileImage.p = new Point(tileX, tileY);
tileImage.hitMe();
break;
};
i++;
};
}
public function init(_map:Object, _type:String):void{
clearBullets();
clearTweenObs();
bullets = [];
tileObs = [];
tweenObs = [];
map = _map;
SWFConsole.output("loaded platformer engine");
switch (_type){
case "bitmap":
generateTilesArray();
generateMap(map);
break;
case "mc":
generateMapMcs(map);
break;
};
alive = true;
}
private function clearTweenObs():void{
var i:uint;
i = 0;
while (i < tweenObs.length) {
delete tweenObs[i];
i++;
};
tweenObs = [];
}
private function generateTilesArray():void{
}
public function disposeBitmap():void{
var tileImage:TileSprite;
var i:uint;
var t:uint;
alive = false;
i = 0;
while (i < tileObs.length) {
tileImage = tileObs[i];
TweenLite.to(tileImage, 0, {});
TweenLite.to(tileImage.tileMc, 0, {});
tileImage.removeAll();
tileImage.alive = false;
tileImage = null;
i++;
};
i = 0;
while (i < newSprite.numChildren) {
newSprite.removeChildAt(0);
i++;
};
t = 0;
while (t < tweenObs.length) {
TweenLite.to(tweenObs[t], 0, {});
tweenObs[t] = null;
t++;
};
tileObs = [];
tilesArray = [];
playerStart = null;
tweenObs = [];
alive = false;
removeChild(newSprite);
tileObs = [];
}
public function addSparks(p:Point, frm:Number, num:uint):void{
Globals.gamework.addSparks(p, frm, num);
}
private function createTileOb(_type:String, _tile):void{
var tileSprite:TileSprite;
tileSprite = new TileSprite();
tileSprite.init(_type, _tile);
tileObs.push(tileSprite);
}
public function moveSparks():void{
var bullet:Spark;
var num:uint;
var i:uint;
num = sparks.length;
i = 0;
while (i < num) {
bullet = sparks[i];
if (bullet){
if (bullet.alive){
bullet.mainLoop();
} else {
bullet.parent.removeChild(bullet);
sparks.splice(i, 1);
i--;
};
};
i++;
};
}
public function addScore(p:Point, pnts:uint):void{
Globals.gamework.hud.addScore(pnts);
}
public function shootTile(p:Point):void{
var tileX:uint;
var tileY:uint;
tileX = Math.floor((p.x / 20));
tileY = Math.floor((p.y / 20));
tileHit(tileX, tileY);
}
private function generateMapMcs(map:Object):void{
var tileImage:TilesMc;
var n:uint;
var i:uint;
var j:uint;
newSprite = new Sprite();
i = 0;
while (i < map.mapArray[0].length) {
j = 0;
while (j < map.mapArray.length) {
n = map.mapArray[j][i];
if ((((((n < 22)) && (!((n == 0))))) && (!((n == 12))))){
tileImage = new TilesMc();
tileImage.name = ((("t_" + j) + "_") + i);
tileImage.x = (i * map.tileW);
tileImage.y = (j * map.tileW);
tileImage.gotoAndStop(n);
tileImage.cacheAsBitmap = true;
newSprite.addChild(tileImage);
if (n == 1){
createTileOb("solid", tileImage);
};
if (n == 4){
createTileOb("tnt", tileImage);
};
if (n == 9){
createTileOb("evil_eye", tileImage);
};
if (n == 10){
createTileOb("crumble", tileImage);
};
if (n == 3){
createTileOb("brick", tileImage);
};
if (n == 14){
createTileOb("crate", tileImage);
};
if (n == 15){
createTileOb("arrow", tileImage);
};
if (n == 16){
createTileOb("arrow", tileImage);
};
if (n == 17){
createTileOb("arrow", tileImage);
};
if (n == 18){
createTileOb("arrow", tileImage);
};
if (n == 21){
Globals.totalstars++;
createTileOb("coin", tileImage);
};
} else {
if (n == 12){
playerStart = new Point(((i * map.tileW) + 10), (j * map.tileW));
};
};
j++;
};
i++;
};
addChild(newSprite);
}
public function crumbleTile(p:Point):void{
var tileX:uint;
var tileY:uint;
tileX = Math.floor((p.x / 20));
tileY = Math.floor((p.y / 20));
setCrumbleTile(tileX, tileY);
}
public function blowTile(str:String, p:Point):void{
var rnd:uint;
var tweenOb:Object;
rnd = (Math.random() * tileObs.length);
tweenOb = new Object();
tweenObs.push(tweenOb);
TweenLite.to(tweenOb, 0.1, {onComplete:waitcheck, onCompleteParams:[str, p]});
}
private function clearBullets():void{
var num:uint;
var i:uint;
num = bullets.length;
i = 0;
while (i < num) {
bullets[i].killMe();
bullets.splice(i, 1);
i++;
};
num = sparks.length;
i = 0;
while (i < num) {
sparks[i].killMe();
sparks.splice(i, 1);
i++;
};
}
public function moveBullets():void{
var bullet:Bullet;
var num:uint;
var i:uint;
num = bullets.length;
i = 0;
while (i < num) {
bullet = bullets[i];
if (bullet){
if (bullet.mainLoop()){
} else {
bullet.parent.removeChild(bullet);
bullets.splice(i, 1);
i--;
};
};
i++;
};
}
public function clearTile(tileX:uint, tileY:uint):void{
var tileImage:TileSprite;
var i:uint;
i = 0;
while (i < tileObs.length) {
tileImage = tileObs[i];
if ((((tileImage.tileMc.name == ((("t_" + tileY) + "_") + tileX))) && (tileImage.alive))){
tileImage.p = new Point(tileX, tileY);
tileImage.killMe();
break;
};
i++;
};
}
private function waitcheck(str:String, p:Point):void{
var tileImage:TileSprite;
var i:uint;
i = 0;
while (i < tileObs.length) {
tileImage = tileObs[i];
if ((((tileImage.tileMc.name == str)) && (tileImage.alive))){
tileImage.p = p;
tileImage.perish = true;
tileImage.hitMe(100);
break;
};
i++;
};
}
private function generateMap(map:Object):void{
var backgroundData:BitmapData;
var scrollx:int;
var scrolly:int;
var myMatrix:Matrix;
var i:uint;
var j:uint;
backgroundData = new BitmapData((map.mapArray[0].length * map.tileW), (map.mapArray.length * map.tileW), true, 0xFFFFFF);
backgroundImage = new Bitmap(backgroundData);
i = 0;
while (i < map.mapArray[0].length) {
j = 0;
while (j < map.mapArray.length) {
if (map.mapArray[j][i] < 21){
scrollx = (i * map.tileW);
scrolly = (j * map.tileW);
myMatrix = new Matrix();
myMatrix.tx = scrollx;
myMatrix.ty = scrolly;
backgroundImage.bitmapData.draw(tilesArray[map.mapArray[j][i]], myMatrix);
};
j++;
};
i++;
};
addChild(backgroundImage);
}
private function setCrumbleTile(tileX:uint, tileY:uint):void{
var tileImage:TileSprite;
var i:uint;
i = 0;
while (i < tileObs.length) {
tileImage = tileObs[i];
if ((((tileImage.tileMc.name == ((("t_" + tileY) + "_") + tileX))) && (!(tileImage.crumbled)))){
tileImage.tileMc.alpha = 0.5;
tileImage.p = new Point(tileX, tileY);
tileImage.startCrumble();
break;
};
i++;
};
}
}
}//package th.GameFramework.Platformer
Section 41
//Tile (th.GameFramework.Tiles.Tile)
package th.GameFramework.Tiles {
import flash.display.*;
import flash.geom.*;
public class Tile extends Sprite {
public static var ob:Object;
public static var map:Object;
public function Tile():void{
super();
}
public static function _is(xx, yy, str):Boolean{
if (ob[((("t_" + Math.floor((yy / map.tileW))) + "_") + Math.floor((xx / map.tileW)))]){
if (ob[((("t_" + Math.floor((yy / map.tileW))) + "_") + Math.floor((xx / map.tileW)))][str]){
return (true);
};
};
return (false);
}
public static function isSpike(xx, yy):Boolean{
if (ob[((("t_" + Math.floor((yy / map.tileW))) + "_") + Math.floor((xx / map.tileW)))]){
if (ob[((("t_" + Math.floor((yy / map.tileW))) + "_") + Math.floor((xx / map.tileW)))].spike){
return (true);
};
};
return (false);
}
public static function clearOutTiles():void{
var str:String;
var xx:uint;
var yy:uint;
var i:uint;
var j:uint;
i = 0;
while (i < map.mapArray[0].length) {
j = 0;
while (j < map.mapArray.length) {
xx = i;
yy = j;
str = ((("t_" + yy) + "_") + xx);
if (Tile.ob[str]){
resetTiley(str);
};
j++;
};
i++;
};
}
private static function createTileObject(str:String, num:uint):void{
ob[str] = new Object();
ob[str].num = num;
ob[str].walkable = false;
ob[str].cloud = false;
ob[str].evilEye = false;
ob[str].arrow = false;
ob[str].wallBreak = false;
ob[str].wallBreak = false;
ob[str].spike = false;
ob[str].crumble = false;
ob[str].boost = false;
ob[str].tnt = false;
ob[str].crate = false;
ob[str].solid = false;
ob[str].brick = false;
ob[str].boostR = false;
ob[str].boostL = false;
ob[str].goal = false;
ob[str].coin = false;
if ((((num == 0)) || ((num > 10)))){
ob[str].walkable = true;
ob[str].solid = false;
};
if (num == 1){
ob[str].solid = true;
ob[str].walkable = false;
};
if (num == 2){
ob[str].cloud = true;
ob[str].walkable = true;
};
if (num == 3){
ob[str].brick = true;
};
if (num == 4){
ob[str].tnt = true;
};
if ((((num > 4)) && ((num < 9)))){
ob[str].walkable = true;
ob[str].spike = true;
};
if (num == 9){
ob[str].evilEye = true;
};
if (num == 10){
ob[str].crumble = true;
ob[str].walkable = false;
};
if (num == 11){
ob[str].boost = true;
};
if (num == 13){
ob[str].goal = true;
};
if (num == 14){
ob[str].crate = true;
ob[str].walkable = false;
};
if ((((num > 14)) && ((num < 19)))){
ob[str].walkable = false;
ob[str].solid = false;
ob[str].arrow = true;
};
if (num == 20){
ob[str].boostL = true;
};
if (num == 19){
ob[str].boostR = true;
};
if (num == 21){
ob[str].coin = true;
ob[str].walkable = true;
};
}
public static function isCloud(xx, yy):Boolean{
if (ob[((("t_" + Math.floor((yy / map.tileW))) + "_") + Math.floor((xx / map.tileW)))]){
if (ob[((("t_" + Math.floor((yy / map.tileW))) + "_") + Math.floor((xx / map.tileW)))].cloud){
return (true);
};
};
return (false);
}
public static function generateTiles(_map:Object):void{
var xx:uint;
var yy:uint;
var i:uint;
var j:uint;
ob = new Object();
map = _map;
clearOutTiles();
i = 0;
while (i < map.mapArray[0].length) {
j = 0;
while (j < map.mapArray.length) {
xx = i;
yy = j;
createTileObject(((("t_" + yy) + "_") + xx), map.mapArray[j][i]);
j++;
};
i++;
};
}
public static function getMyCorners(xx, yy, _ob){
_ob.downY = Math.floor((yy / map.tileH));
_ob.upY = Math.floor(((yy - _ob.height) / map.tileH));
_ob.leftX = Math.floor(((xx - _ob.width) / map.tileH));
_ob.rightX = Math.floor(((xx + _ob.width) / map.tileH));
if (ob[((("t_" + _ob.upY) + "_") + _ob.leftX)]){
_ob.upleft = ob[((("t_" + _ob.upY) + "_") + _ob.leftX)].walkable;
};
if (ob[((("t_" + _ob.downY) + "_") + _ob.leftX)]){
_ob.downleft = ob[((("t_" + _ob.downY) + "_") + _ob.leftX)].walkable;
};
if (ob[((("t_" + _ob.upY) + "_") + _ob.rightX)]){
_ob.upright = ob[((("t_" + _ob.upY) + "_") + _ob.rightX)].walkable;
};
if (ob[((("t_" + _ob.downY) + "_") + _ob.rightX)]){
_ob.downright = ob[((("t_" + _ob.downY) + "_") + _ob.rightX)].walkable;
};
}
public static function isLimbo(xx, yy):Boolean{
if (ob[((("t_" + Math.floor((yy / map.tileW))) + "_") + Math.floor((xx / map.tileW)))]){
if (ob[((("t_" + Math.floor((yy / map.tileW))) + "_") + Math.floor((xx / map.tileW)))].limbo){
return (true);
};
};
return (false);
}
public static function resetTile(p:Point):void{
var str:String;
str = ((("t_" + p.y) + "_") + p.x);
resetTiley(str);
}
private static function resetTiley(str:String):void{
ob[str].walkable = true;
ob[str].cloud = false;
ob[str].evilEye = false;
ob[str].wallBreak = false;
ob[str].wallBreak = false;
ob[str].spike = false;
ob[str].crumble = false;
ob[str].boost = false;
ob[str].tnt = false;
ob[str].crate = false;
ob[str].solid = false;
ob[str].brick = false;
ob[str].boostR = false;
ob[str].boostL = false;
ob[str].goal = false;
ob[str].coin = false;
ob[str].arrow = false;
}
}
}//package th.GameFramework.Tiles
Section 42
//GetDistance (th.utilities.GetDistance)
package th.utilities {
import flash.display.*;
import flash.geom.*;
public class GetDistance extends Sprite {
public function GetDistance(){
super();
}
public static function _get(p1:Point, p2:Point):Number{
var dist:*;
var dx:*;
var dy:Number;
dx = (p2.x - p1.x);
dy = (p2.y - p1.y);
dist = Math.sqrt(((dx * dx) + (dy * dy)));
return (dist);
}
}
}//package th.utilities
Section 43
//LoadSwf (th.utilities.LoadSwf)
package th.utilities {
import flash.events.*;
import flash.display.*;
import rl.dev.*;
import flash.net.*;
public class LoadSwf extends Sprite {
public static var callBack:Function;
private static var targetClip:String;
private static var targ:Object;
private static var fileString:String;
private static var swfLoader:Loader;
public static var loadedSwf:MovieClip = new MovieClip();
public function LoadSwf():void{
super();
}
private static function onIOError(e:IOErrorEvent):void{
SWFConsole.output(e);
}
public static function load(swf:String, _targ:Object, _targetClip:String, _callBack:Function):void{
var imagePath:String;
var file:String;
targ = _targ;
targetClip = _targetClip;
callBack = _callBack;
imagePath = "";
file = (swf + ".swf");
fileString = file;
swfLoader = new Loader();
swfLoader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, onIOError, false, 0, true);
swfLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, onSwfLoad, false, 0, true);
swfLoader.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, swfProgress, false, 0, true);
swfLoader.load(new URLRequest((imagePath + file)));
}
public static function gotoFrame(f:uint):void{
if (loadedSwf.currentFrame != f){
loadedSwf.gotoAndStop(f);
};
}
private static function swfProgress(e:ProgressEvent):void{
var goFrame:int;
goFrame = (100 * (e.bytesLoaded / e.bytesTotal));
}
public static function init(swf:String):void{
}
private static function onSwfLoad(e:Event=null, swfOb:Object=null):void{
var swfCard:Object;
var targOb:LoaderInfo;
swfLoader.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, onIOError);
swfLoader.contentLoaderInfo.removeEventListener(Event.COMPLETE, onSwfLoad);
swfLoader.contentLoaderInfo.removeEventListener(ProgressEvent.PROGRESS, swfProgress);
targOb = (e.target as LoaderInfo);
swfCard = targOb.content;
swfCard[targetClip].x = (swfCard[targetClip].y = 0);
swfCache._push(fileString, targOb);
targ.addChild(swfCard[targetClip]);
targ[targetClip] = swfCard[targetClip];
if (callBack != null){
callBack();
};
}
}
}//package th.utilities
Section 44
//OddOrEven (th.utilities.OddOrEven)
package th.utilities {
import flash.display.*;
public class OddOrEven extends Sprite {
public function OddOrEven(){
super();
}
public function OddOrEvent():void{
}
public static function isEven(n:Number):Boolean{
var myModulo:Number;
myModulo = (n % 2);
if (myModulo == 1){
return (true);
};
return (false);
}
}
}//package th.utilities
Section 45
//swfCache (th.utilities.swfCache)
package th.utilities {
import flash.display.*;
import rl.dev.*;
public class swfCache extends Sprite {
public static var cacheArray:Array;
public function swfCache():void{
super();
}
public static function init():void{
cacheArray = new Array();
}
public static function _get(file:String):Object{
var newOb:Object;
var i:uint;
newOb = new Object();
i = 0;
while (i < cacheArray.length) {
if (cacheArray[i].file == file){
return (cacheArray[i].swf);
};
i++;
};
SWFConsole.output((("didnt find your file:" + file) + " in swfcache"));
return (newOb);
}
public static function _check(file:String):Boolean{
var i:uint;
i = 0;
while (i < cacheArray.length) {
if (cacheArray[i].file == file){
return (true);
};
SWFConsole.output((" ------------------ cache file = " + cacheArray[i].file));
i++;
};
return (false);
}
public static function _push(file:String, swf:Object):void{
var cacheOb:Object;
cacheOb = new Object();
cacheOb.file = file;
cacheOb.swf = swf;
cacheArray.push(cacheOb);
SWFConsole.output((" ------------------ cache file pushed = " + file));
}
}
}//package th.utilities
Section 46
//btn_highscores_ (btn_highscores_)
package {
import rl.display.*;
public dynamic class btn_highscores_ extends AdvancedButton {
public function btn_highscores_(){
super();
}
}
}//package
Section 47
//btn_instructions_ (btn_instructions_)
package {
import rl.display.*;
public dynamic class btn_instructions_ extends AdvancedButton {
public function btn_instructions_(){
super();
}
}
}//package
Section 48
//btn_logolink_ (btn_logolink_)
package {
import rl.display.*;
public dynamic class btn_logolink_ extends AdvancedButton {
public function btn_logolink_(){
super();
}
}
}//package
Section 49
//btn_logolink_smaller_ (btn_logolink_smaller_)
package {
import rl.display.*;
public dynamic class btn_logolink_smaller_ extends AdvancedButton {
public function btn_logolink_smaller_(){
super();
}
}
}//package
Section 50
//btn_mainMenu_ (btn_mainMenu_)
package {
import rl.display.*;
public dynamic class btn_mainMenu_ extends AdvancedButton {
public function btn_mainMenu_(){
super();
}
}
}//package
Section 51
//btn_music_ (btn_music_)
package {
import rl.display.*;
public dynamic class btn_music_ extends AdvancedButton {
public function btn_music_(){
super();
}
}
}//package
Section 52
//Btn_next (Btn_next)
package {
import rl.display.*;
public dynamic class Btn_next extends AdvancedButton {
public function Btn_next(){
super();
}
}
}//package
Section 53
//btn_pausegame_ (btn_pausegame_)
package {
import rl.display.*;
public dynamic class btn_pausegame_ extends AdvancedButton {
public function btn_pausegame_(){
super();
}
}
}//package
Section 54
//btn_playmore_ (btn_playmore_)
package {
import rl.display.*;
public dynamic class btn_playmore_ extends AdvancedButton {
public function btn_playmore_(){
super();
}
}
}//package
Section 55
//btn_quit_ (btn_quit_)
package {
import rl.display.*;
public dynamic class btn_quit_ extends AdvancedButton {
public function btn_quit_(){
super();
}
}
}//package
Section 56
//btn_replay_ (btn_replay_)
package {
import rl.display.*;
public dynamic class btn_replay_ extends AdvancedButton {
public function btn_replay_(){
super();
}
}
}//package
Section 57
//btn_reume_ (btn_reume_)
package {
import rl.display.*;
public dynamic class btn_reume_ extends AdvancedButton {
public function btn_reume_(){
super();
}
}
}//package
Section 58
//btn_startGame (btn_startGame)
package {
import rl.display.*;
public dynamic class btn_startGame extends AdvancedButton {
public function btn_startGame(){
super();
}
}
}//package
Section 59
//btn_submitscore_ (btn_submitscore_)
package {
import rl.display.*;
public dynamic class btn_submitscore_ extends AdvancedButton {
public function btn_submitscore_(){
super();
}
}
}//package
Section 60
//Bullet (Bullet)
package {
import th.GameFramework.Platformer.Sprites.*;
public dynamic class Bullet extends Bullet {
public function Bullet(){
super();
}
}
}//package
Section 61
//bunnycharacter (bunnycharacter)
package {
import flash.display.*;
public dynamic class bunnycharacter extends MovieClip {
public function bunnycharacter(){
super();
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package
Section 62
//Crosshairs (Crosshairs)
package {
import flash.display.*;
public dynamic class Crosshairs extends MovieClip {
public function Crosshairs(){
super();
}
}
}//package
Section 63
//GameFrameWork (GameFrameWork)
package {
import flash.events.*;
import flash.display.*;
import flash.geom.*;
import th.GameFramework.Platformer.Sprites.*;
import th.GameFramework.Display.*;
import th.GameFramework.Platformer.*;
import rl.dev.*;
import com.*;
import com.sounds.*;
import th.utilities.*;
import th.GameFramework.Tiles.*;
import th.GameFramework.Key.*;
import th.GameFramework.HitDetection.*;
import flash.net.*;
import flash.ui.*;
public class GameFrameWork extends MovieClip {
var sharedObject:SharedObject;
public var hud:Hud;
public var crosshair:Crosshairs;
var gameLose:GameLose_;
public var gcnum:uint;// = 0
var titleScreen:TitleScreen;
var map:Object;
var _output:SWFConsole;
var gameWin:GameWin_;
var container:Sprite;
var tallyScore:TallyScore;
public var enemy:Enemy;
var platformer:Platformer;
var levelPopUp:LevelPopUp_;
var gameContainer:Sprite;
var spritesArray:Array;
var ob:Object;
public var player:Player;
public var screenTransition:ScreenTransition_;
var timeInt:uint;// = 0
public function GameFrameWork():void{
gameContainer = new Sprite();
container = new Sprite();
platformer = new Platformer();
spritesArray = new Array();
map = new Object();
ob = new Object();
timeInt = 0;
gcnum = 0;
super();
Globals.gamework = this;
hud.visible = false;
stage.addEventListener(MouseEvent.CLICK, clickMouse, false, 0, true);
init();
Music.init();
}
private function createEnemy(p:Point, dir:int):void{
}
public function init(e:Event=null):void{
addEventListener(Event.ENTER_FRAME, mainLoop, false, 0, true);
gameContainer = new Sprite();
titleScreen = new TitleScreen();
titleScreen.init(addScreenTransition);
addChild(titleScreen);
addChild(gameContainer);
swfCache.init();
Key.init(stage);
Sounds.init();
Mouse.hide();
stage.addEventListener(MouseEvent.MOUSE_MOVE, mouseMoveHandler);
crosshair = new Crosshairs();
crosshair.mouseEnabled = false;
addChild(crosshair);
}
private function checkKeys():void{
if (((Key.isDown["k_65"]) && (Key.isDown["k_68"]))){
walkFalse();
} else {
if (Key.isDown["k_65"]){
player.walk(-1);
} else {
if (Key.isDown["k_68"]){
player.walk(1);
};
};
};
if (Key.isDown["k_87"]){
player.jump();
};
}
private function checkFinishedLevel():void{
if (Globals.finishedLevel){
Globals.finishedLevel = false;
Globals.paused = true;
tallyScore = new TallyScore();
tallyScore.updateHud = hud.updateDisplay;
addChild(tallyScore);
};
}
public function GC():void{
var lc1:LocalConnection;
var lc2:LocalConnection;
lc1 = new LocalConnection();
lc2 = new LocalConnection();
lc1.connect("name");
lc2.connect("name");
//unresolved jump
var _slot1 = e;
}
private function mainLoop(e:Event):void{
if (Globals.quit){
Globals.quit = false;
if (Globals.lives > 0){
quitGame();
} else {
addGameLose();
};
Globals.lives = Globals.livesStart;
Globals.level = Globals.levelStart;
Globals.score = 0;
if (Globals.replay){
Globals.replay = false;
startLevel();
} else {
clearLevel();
};
};
if (!Globals.paused){
platformer.moveBullets();
platformer.moveSparks();
checkKeys();
updateSprites();
MyCamera.mainloop();
timeInt++;
if (timeInt == 30){
timeInt = 0;
if (Globals.time > 0){
Globals.time--;
};
hud.updateDisplay();
};
gcnum++;
if (gcnum > 200){
gcnum = 0;
GC();
Mouse.hide();
};
};
checkFinishedLevel();
if (Globals.startLevel){
SWFConsole.output("StartLevel = false yo");
Globals.startLevel = false;
if (Globals.level < Globals.totalLevels){
addScreenTransition(tallyScore.killMe);
} else {
addGameFinished();
};
};
if (((!(titleScreen.visible)) && (Globals.musicOn))){
Music.playMusic();
};
Sounds.flushSoundsArray();
}
public function addSparks(p:Point, frm:Number, num:uint):void{
var spark:SparkMc;
var angDivide:int;
var ang:int;
var i:uint;
angDivide = (360 / num);
ang = angDivide;
i = 0;
while (i < num) {
spark = new SparkMc();
spark.init(ang, frm);
spark.x = p.x;
spark.y = p.y;
platformer.addChild(spark);
platformer.sparks.push(spark);
ang = (ang + angDivide);
i++;
};
}
private function loadStars():void{
var xx:int;
var yy:int;
var i:uint;
var j:uint;
i = 0;
while (i < map.obArray[0].length) {
j = 0;
while (j < map.obArray.length) {
xx = ((i * 50) + 25);
yy = ((j * 50) + 50);
if (map.obArray[j][i] == 26){
addStar(new Point(xx, yy));
};
if (map.obArray[j][i] == 27){
addCupCake(new Point(xx, yy));
};
j++;
};
i++;
};
hud.init();
}
public function shoot():void{
var bullet:Bullet;
bullet = new Bullet();
bullet.x = player.x;
bullet.platformer = platformer;
bullet.y = (player.y - 15);
platformer.addChild(bullet);
bullet.init(player.getShootSpeeds(), 1);
platformer.bullets.push(bullet);
}
public function enemyArrow(ep:Point, angle:uint):void{
var bullet:Bullet;
bullet = new Bullet();
bullet.x = ep.x;
bullet.platformer = platformer;
bullet.y = ep.y;
platformer.addChild(bullet);
platformer.bullets.push(bullet);
bullet.init(angle, 2);
Sounds.playSound(Sounds.enemyshoot2, 0);
}
private function mouseMoveHandler(e:MouseEvent):void{
crosshair.x = mouseX;
crosshair.y = mouseY;
setChildIndex(crosshair, (numChildren - 1));
}
public function enemyShoot(ep:Point):void{
var bullet:Bullet;
bullet = new Bullet();
bullet.x = ep.x;
bullet.platformer = platformer;
bullet.y = ep.y;
platformer.addChild(bullet);
bullet.init(getShootSpeeds(ep), 2);
platformer.bullets.push(bullet);
Sounds.playSound(Sounds.enemyshoot1, 0);
}
private function startLevel(e:MouseEvent=null, clr:Boolean=true):void{
var mapLevel:uint;
var bunnyMc:SpaceMan;
SWFConsole.output("START LEVEL");
titleScreen.visible = false;
clearLevel();
mapLevel = Globals.level;
Globals.cupcakes = 0;
Globals.stars = 0;
Globals.totalstars = 0;
Globals.totalcupcakes = 0;
spritesArray = new Array();
map.mapArray = [[1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1], [1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 2, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1], [1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 2, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
map.tileW = (map.tileH = 20);
Map.init(20, 20);
map.mapArray = Map.maps.test;
map.mapArray = Map.maps[("map" + mapLevel)];
removeEventListener(Event.ADDED_TO_STAGE, init);
SWFConsole.output("gotcha");
platformer = new Platformer();
Globals.platform = platformer;
platformer.init(map, "mc");
container.addChild(platformer);
Tile.generateTiles(map);
ob.height = 4;
player = new Player();
Globals.player = player;
player.init(map, {scoreFunction:hud.addScore, updateHud:hud.updateDisplay});
player.setStart(platformer.playerStart);
player.id = 0;
container.addChild(player);
spritesArray.push(player);
setChildIndex(hud, (numChildren - 1));
bunnyMc = new SpaceMan();
player.addChild(bunnyMc);
player.bunnyMc = bunnyMc;
BasicHitDetection.init(spritesArray);
MyCamera.init(new Point(container.width, container.height), new Point(660, 406));
MyCamera.screen = container;
MyCamera.target = player;
gameContainer.addChild(container);
container.focusRect = false;
container.stage.focus = container;
Globals.paused = false;
levelPopUp = new LevelPopUp_();
levelPopUp.init(("LEVEL " + Globals.level));
addChild(levelPopUp);
titleScreen.titleAnim.stop();
hud.init();
gameContainer.y = 50;
screenTransition.fadeOut();
Key.reset();
}
public function loadSprite(ob):void{
LoadSwf.load("bunnytemp", ob, "marshie", null);
}
private function createEnemies():void{
}
private function clearLevel():void{
var s:uint;
var num:uint;
var p:uint;
var c:uint;
SWFConsole.output("CLEARING LEVEL");
s = 0;
while (s < spritesArray.length) {
spritesArray[s].parent.removeChild(spritesArray[s]);
s++;
};
spritesArray = [];
timeInt = 0;
Globals.time = 60;
if (platformer.alive){
platformer.disposeBitmap();
container.removeChild(platformer);
};
num = platformer.numChildren;
p = 0;
while (p < num) {
platformer.removeChildAt(0);
p++;
};
num = container.numChildren;
c = 0;
while (c < num) {
container.removeChildAt(0);
c++;
};
num = gameContainer.numChildren;
c = 0;
while (c < num) {
gameContainer.removeChildAt(0);
c++;
};
Sounds.stopSound();
titleScreen.titleAnim.play();
Tile.ob = new Object();
GC();
}
public function addScreenTransition(f:Function=null):void{
screenTransition = new ScreenTransition_();
this.addChild(screenTransition);
screenTransition.init(startLevel, f);
setChildIndex(screenTransition, (numChildren - 1));
}
private function addStar(p:Point):void{
}
private function addGameFinished():void{
gameWin = new GameWin_();
addChild(gameWin);
}
private function addCupCake(p:Point):void{
}
public function getShootSpeeds(p:Point):Number{
var newPoint:Point;
var adjside:*;
var oppside:*;
var angle:*;
adjside = (player.x - p.x);
oppside = (-1 * ((player.y - 10) - p.y));
angle = Math.atan2(oppside, adjside);
angle = Math.round(((angle / Math.PI) * 180));
return ((-1 * angle));
}
private function checkTile(pnt:Point):void{
var xx:uint;
var yy:uint;
var tileName:String;
xx = (pnt.x / map.tileW);
yy = (pnt.y / map.tileW);
tileName = ((("t_" + xx) + "_") + yy);
Tile.getMyCorners(mouseX, mouseY, ob);
}
private function walkFalse():void{
player.walking = false;
}
private function updateSprites():void{
var spriteOb:Object;
var i:uint;
i = 0;
while (i < spritesArray.length) {
spriteOb = spritesArray[i];
if (spriteOb.type == "player"){
if (((BasicHitDetection.checkHit(spriteOb)) && (!(spriteOb.hit)))){
spriteOb.hitEnemy(BasicHitDetection.checkHit(spriteOb));
};
};
if ((((spriteOb.type == "player")) || ((spriteOb.type == "enemy")))){
spriteOb.movePlayer();
spriteOb.x = spriteOb.xx;
spriteOb.y = spriteOb.yy;
};
i++;
};
}
private function addGameLose():void{
gameLose = new GameLose_();
addChild(gameLose);
}
private function quitGame():void{
hud.visible = false;
titleScreen.visible = true;
Globals.score = 0;
}
private function clickMouse(e:MouseEvent):void{
if (((!(Globals.paused)) && ((Globals.lives > -1)))){
shoot();
Sounds.playSound(Sounds.shoot, 0);
};
}
}
}//package
Section 64
//gameframework_ (gameframework_)
package {
public dynamic class gameframework_ extends GameFrameWork {
public function gameframework_(){
super();
}
}
}//package
Section 65
//GameLose_ (GameLose_)
package {
import com.Ui.*;
public dynamic class GameLose_ extends GameLose {
public function GameLose_(){
super();
}
}
}//package
Section 66
//GameWin_ (GameWin_)
package {
import com.Ui.*;
public dynamic class GameWin_ extends GameWin {
public function GameWin_(){
super();
}
}
}//package
Section 67
//Hud (Hud)
package {
import com.Ui.*;
public dynamic class Hud extends Hud {
public function Hud(){
super();
}
}
}//package
Section 68
//Instructions_ (Instructions_)
package {
import com.Ui.*;
public dynamic class Instructions_ extends Instructions {
public function Instructions_(){
super();
}
}
}//package
Section 69
//LevelPopUp_ (LevelPopUp_)
package {
import com.Ui.*;
public dynamic class LevelPopUp_ extends LevelPopUp {
public function LevelPopUp_(){
super();
}
}
}//package
Section 70
//PausedScreen_ (PausedScreen_)
package {
import com.Ui.*;
public dynamic class PausedScreen_ extends PausedScreen {
public function PausedScreen_(){
super();
}
}
}//package
Section 71
//s_bleep1 (s_bleep1)
package {
import flash.media.*;
public dynamic class s_bleep1 extends Sound {
public function s_bleep1(){
super();
}
}
}//package
Section 72
//s_bleep2 (s_bleep2)
package {
import flash.media.*;
public dynamic class s_bleep2 extends Sound {
public function s_bleep2(){
super();
}
}
}//package
Section 73
//s_bleep3 (s_bleep3)
package {
import flash.media.*;
public dynamic class s_bleep3 extends Sound {
public function s_bleep3(){
super();
}
}
}//package
Section 74
//s_bleep4 (s_bleep4)
package {
import flash.media.*;
public dynamic class s_bleep4 extends Sound {
public function s_bleep4(){
super();
}
}
}//package
Section 75
//s_bleep5 (s_bleep5)
package {
import flash.media.*;
public dynamic class s_bleep5 extends Sound {
public function s_bleep5(){
super();
}
}
}//package
Section 76
//s_bleep6 (s_bleep6)
package {
import flash.media.*;
public dynamic class s_bleep6 extends Sound {
public function s_bleep6(){
super();
}
}
}//package
Section 77
//s_bleep7 (s_bleep7)
package {
import flash.media.*;
public dynamic class s_bleep7 extends Sound {
public function s_bleep7(){
super();
}
}
}//package
Section 78
//s_blip1 (s_blip1)
package {
import flash.media.*;
public dynamic class s_blip1 extends Sound {
public function s_blip1(){
super();
}
}
}//package
Section 79
//s_blip2 (s_blip2)
package {
import flash.media.*;
public dynamic class s_blip2 extends Sound {
public function s_blip2(){
super();
}
}
}//package
Section 80
//s_blip3 (s_blip3)
package {
import flash.media.*;
public dynamic class s_blip3 extends Sound {
public function s_blip3(){
super();
}
}
}//package
Section 81
//s_blip4 (s_blip4)
package {
import flash.media.*;
public dynamic class s_blip4 extends Sound {
public function s_blip4(){
super();
}
}
}//package
Section 82
//s_blip5 (s_blip5)
package {
import flash.media.*;
public dynamic class s_blip5 extends Sound {
public function s_blip5(){
super();
}
}
}//package
Section 83
//s_blip6 (s_blip6)
package {
import flash.media.*;
public dynamic class s_blip6 extends Sound {
public function s_blip6(){
super();
}
}
}//package
Section 84
//s_blip7 (s_blip7)
package {
import flash.media.*;
public dynamic class s_blip7 extends Sound {
public function s_blip7(){
super();
}
}
}//package
Section 85
//s_blip8 (s_blip8)
package {
import flash.media.*;
public dynamic class s_blip8 extends Sound {
public function s_blip8(){
super();
}
}
}//package
Section 86
//s_blip9 (s_blip9)
package {
import flash.media.*;
public dynamic class s_blip9 extends Sound {
public function s_blip9(){
super();
}
}
}//package
Section 87
//s_enemyhit (s_enemyhit)
package {
import flash.media.*;
public dynamic class s_enemyhit extends Sound {
public function s_enemyhit(){
super();
}
}
}//package
Section 88
//s_enemyshoot1 (s_enemyshoot1)
package {
import flash.media.*;
public dynamic class s_enemyshoot1 extends Sound {
public function s_enemyshoot1(){
super();
}
}
}//package
Section 89
//s_enemyshoot2 (s_enemyshoot2)
package {
import flash.media.*;
public dynamic class s_enemyshoot2 extends Sound {
public function s_enemyshoot2(){
super();
}
}
}//package
Section 90
//s_explode_brick (s_explode_brick)
package {
import flash.media.*;
public dynamic class s_explode_brick extends Sound {
public function s_explode_brick(){
super();
}
}
}//package
Section 91
//s_explode_crate (s_explode_crate)
package {
import flash.media.*;
public dynamic class s_explode_crate extends Sound {
public function s_explode_crate(){
super();
}
}
}//package
Section 92
//s_explode_tnt1 (s_explode_tnt1)
package {
import flash.media.*;
public dynamic class s_explode_tnt1 extends Sound {
public function s_explode_tnt1(){
super();
}
}
}//package
Section 93
//s_explode_tnt2 (s_explode_tnt2)
package {
import flash.media.*;
public dynamic class s_explode_tnt2 extends Sound {
public function s_explode_tnt2(){
super();
}
}
}//package
Section 94
//s_explode_tnt3 (s_explode_tnt3)
package {
import flash.media.*;
public dynamic class s_explode_tnt3 extends Sound {
public function s_explode_tnt3(){
super();
}
}
}//package
Section 95
//s_hit (s_hit)
package {
import flash.media.*;
public dynamic class s_hit extends Sound {
public function s_hit(){
super();
}
}
}//package
Section 96
//s_hitbyspikes (s_hitbyspikes)
package {
import flash.media.*;
public dynamic class s_hitbyspikes extends Sound {
public function s_hitbyspikes(){
super();
}
}
}//package
Section 97
//s_jump (s_jump)
package {
import flash.media.*;
public dynamic class s_jump extends Sound {
public function s_jump(){
super();
}
}
}//package
Section 98
//s_madeit (s_madeit)
package {
import flash.media.*;
public dynamic class s_madeit extends Sound {
public function s_madeit(){
super();
}
}
}//package
Section 99
//s_pulse (s_pulse)
package {
import flash.media.*;
public dynamic class s_pulse extends Sound {
public function s_pulse(){
super();
}
}
}//package
Section 100
//s_shoot (s_shoot)
package {
import flash.media.*;
public dynamic class s_shoot extends Sound {
public function s_shoot(){
super();
}
}
}//package
Section 101
//s_wallhit1 (s_wallhit1)
package {
import flash.media.*;
public dynamic class s_wallhit1 extends Sound {
public function s_wallhit1(){
super();
}
}
}//package
Section 102
//s_wallhit2 (s_wallhit2)
package {
import flash.media.*;
public dynamic class s_wallhit2 extends Sound {
public function s_wallhit2(){
super();
}
}
}//package
Section 103
//s_wallhit3 (s_wallhit3)
package {
import flash.media.*;
public dynamic class s_wallhit3 extends Sound {
public function s_wallhit3(){
super();
}
}
}//package
Section 104
//ScorePopUpMC (ScorePopUpMC)
package {
import th.GameFramework.Display.*;
public dynamic class ScorePopUpMC extends ScorePopUp {
public function ScorePopUpMC(){
super();
}
}
}//package
Section 105
//ScreenTransition_ (ScreenTransition_)
package {
import com.Ui.*;
public dynamic class ScreenTransition_ extends ScreenTransition {
public function ScreenTransition_(){
super();
}
}
}//package
Section 106
//sound_bounce (sound_bounce)
package {
import flash.media.*;
public dynamic class sound_bounce extends Sound {
public function sound_bounce(){
super();
}
}
}//package
Section 107
//sound_bounceSmall (sound_bounceSmall)
package {
import flash.media.*;
public dynamic class sound_bounceSmall extends Sound {
public function sound_bounceSmall(){
super();
}
}
}//package
Section 108
//sound_click (sound_click)
package {
import flash.media.*;
public dynamic class sound_click extends Sound {
public function sound_click(){
super();
}
}
}//package
Section 109
//sound_clickClose (sound_clickClose)
package {
import flash.media.*;
public dynamic class sound_clickClose extends Sound {
public function sound_clickClose(){
super();
}
}
}//package
Section 110
//sound_coin (sound_coin)
package {
import flash.media.*;
public dynamic class sound_coin extends Sound {
public function sound_coin(){
super();
}
}
}//package
Section 111
//sound_coin2 (sound_coin2)
package {
import flash.media.*;
public dynamic class sound_coin2 extends Sound {
public function sound_coin2(){
super();
}
}
}//package
Section 112
//sound_collect (sound_collect)
package {
import flash.media.*;
public dynamic class sound_collect extends Sound {
public function sound_collect(){
super();
}
}
}//package
Section 113
//sound_jump (sound_jump)
package {
import flash.media.*;
public dynamic class sound_jump extends Sound {
public function sound_jump(){
super();
}
}
}//package
Section 114
//sound_squeak (sound_squeak)
package {
import flash.media.*;
public dynamic class sound_squeak extends Sound {
public function sound_squeak(){
super();
}
}
}//package
Section 115
//SpaceMan (SpaceMan)
package {
import flash.display.*;
public dynamic class SpaceMan extends MovieClip {
public function SpaceMan(){
super();
addFrameScript(1, frame2);
}
function frame2(){
stop();
}
}
}//package
Section 116
//SparkMc (SparkMc)
package {
import th.GameFramework.Platformer.Sprites.*;
public dynamic class SparkMc extends Spark {
public function SparkMc(){
super();
}
}
}//package
Section 117
//TallyScore (TallyScore)
package {
import com.Ui.*;
public dynamic class TallyScore extends TallyScore {
public function TallyScore(){
super();
}
}
}//package
Section 118
//TilesMc (TilesMc)
package {
import flash.display.*;
public dynamic class TilesMc extends MovieClip {
public function TilesMc(){
super();
}
}
}//package
Section 119
//TitleScreen (TitleScreen)
package {
import com.Ui.*;
public dynamic class TitleScreen extends TitleScreen {
public function TitleScreen(){
super();
}
}
}//package