Section 1
//audio_clips_41 (frog_feast_fla.audio_clips_41)
package frog_feast_fla {
import flash.display.*;
public dynamic class audio_clips_41 extends MovieClip {
public function audio_clips_41(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package frog_feast_fla
Section 2
//CancelButton_38 (frog_feast_fla.CancelButton_38)
package frog_feast_fla {
import flash.display.*;
import flash.text.*;
public dynamic class CancelButton_38 extends MovieClip {
public var message_text:TextField;
}
}//package frog_feast_fla
Section 3
//content_holder_8 (frog_feast_fla.content_holder_8)
package frog_feast_fla {
import flash.display.*;
public dynamic class content_holder_8 extends MovieClip {
public function content_holder_8(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package frog_feast_fla
Section 4
//damage_meter_22 (frog_feast_fla.damage_meter_22)
package frog_feast_fla {
import flash.display.*;
public dynamic class damage_meter_22 extends MovieClip {
public var green:MovieClip;
public var yellow:MovieClip;
public var red:MovieClip;
}
}//package frog_feast_fla
Section 5
//LoadBar_6 (frog_feast_fla.LoadBar_6)
package frog_feast_fla {
import flash.display.*;
public dynamic class LoadBar_6 extends MovieClip {
public var Fill:MovieClip;
}
}//package frog_feast_fla
Section 6
//NonobaSubmitBox_33 (frog_feast_fla.NonobaSubmitBox_33)
package frog_feast_fla {
import flash.display.*;
import flash.text.*;
public dynamic class NonobaSubmitBox_33 extends MovieClip {
public var score:TextField;
public var Continue:MovieClip;
}
}//package frog_feast_fla
Section 7
//PointText_56 (frog_feast_fla.PointText_56)
package frog_feast_fla {
import flash.display.*;
import flash.text.*;
public dynamic class PointText_56 extends MovieClip {
public var PointText:TextField;
}
}//package frog_feast_fla
Section 8
//PreloaderScreen_1 (frog_feast_fla.PreloaderScreen_1)
package frog_feast_fla {
import flash.display.*;
public dynamic class PreloaderScreen_1 extends MovieClip {
public var loader:LoadBarSymbol;
}
}//package frog_feast_fla
Section 9
//SmallzSubmitBox_36 (frog_feast_fla.SmallzSubmitBox_36)
package frog_feast_fla {
import flash.display.*;
import flash.text.*;
public dynamic class SmallzSubmitBox_36 extends MovieClip {
public var Submit:MovieClip;
public var user_name:TextField;
public var message_text:TextField;
public var score:TextField;
public var Cancel:MovieClip;
}
}//package frog_feast_fla
Section 10
//SubmitButton_39 (frog_feast_fla.SubmitButton_39)
package frog_feast_fla {
import flash.display.*;
import flash.text.*;
public dynamic class SubmitButton_39 extends MovieClip {
public var message_text:TextField;
}
}//package frog_feast_fla
Section 11
//submitcancelButton_35 (frog_feast_fla.submitcancelButton_35)
package frog_feast_fla {
import flash.display.*;
import flash.text.*;
public dynamic class submitcancelButton_35 extends MovieClip {
public var message_text:TextField;
}
}//package frog_feast_fla
Section 12
//AchievementBox (AchievementBox)
package {
import flash.geom.*;
import flash.display.*;
import flash.text.*;
import flash.utils.*;
public class AchievementBox extends MovieClip {
public var _duration:Number;
public var _isComplete:Boolean;
public var _type:int;
public var achievement_text:TextField;
public var _speed:Number;
public var _scale:Number;
public var _initTime:Number;
public var _spawnState:Boolean;// = true
public var user_name:TextField;
public var _state:String;
public var _defaultAchievementText:String;// = "You know how we do!"
public var _defaultDuration:Number;// = 3
public var _scaleSpeed:Number;// = 250
public var _defalutLoc:Point;
public function AchievementBox():void{
_scaleSpeed = 250;
_defaultDuration = 3;
_defalutLoc = new Point(0, 0);
_defaultAchievementText = "You know how we do!";
_spawnState = true;
super();
deactivate();
}
public function startTimer():void{
_initTime = getTimer();
}
public function activate():void{
_state = "Active";
visible = true;
_spawnState = false;
}
public function transitionIn():void{
_scale = 0.01;
scaleX = _scale;
scaleY = _scale;
_state = "Grow";
}
public function deactivate():void{
_state = "Inactive";
visible = false;
_isComplete = true;
}
public function transitionOut():void{
_state = "Shrink";
}
public function update(_arg1:Number):void{
switch (_state){
case "Active":
if (isDone()){
transitionOut();
};
break;
case "Grow":
_scale = (_scale + ((_arg1 * _scaleSpeed) / 100));
if (_scale >= 1){
_scale = 1;
startTimer();
_state = "Active";
};
scaleX = _scale;
scaleY = _scale;
break;
case "Shrink":
_scale = (_scale - ((_arg1 * _scaleSpeed) / 100));
if (_scale <= 0.1){
_scale = 1;
deactivate();
};
scaleX = _scale;
scaleY = _scale;
break;
case "Inactive":
break;
};
}
public function isDone():Boolean{
var _local1:Boolean;
_local1 = false;
if (GameManager.elapsedTime(_initTime) >= _duration){
_local1 = true;
};
return (_local1);
}
}
}//package
Section 13
//AchievementBoxManager (AchievementBoxManager)
package {
import flash.display.*;
public class AchievementBoxManager extends MovieClip {
public var active:Array;
public var clips:Array;
public function AchievementBoxManager():void{
clips = new Array();
active = new Array();
super();
}
public function init(_arg1:Number):void{
var _local2:int;
_local2 = 0;
while (_local2 < _arg1) {
clips[_local2] = new AchievementBox();
clips[_local2].alpha = 0.95;
addChild(clips[_local2]);
_local2++;
};
}
public function inactiveAchievementBox():int{
var _local1:int;
var _local2:int;
var _local3:int;
_local2 = -1;
_local3 = clips.length;
_local1 = 0;
while (_local1 < _local3) {
if (clips[_local1]._spawnState){
_local2 = _local1;
break;
};
_local1++;
};
return (_local2);
}
public function deactivateAllAchievementBoxes():void{
var _local1:int;
var _local2:int;
_local2 = clips.length;
_local1 = 0;
while (_local1 < _local2) {
clips[_local1].deactivate();
clips[_local1]._spawnState = true;
_local1++;
};
active = new Array();
}
public function spawn(_arg1:String, _arg2:Number):void{
var clipIndex:int;
var achievementText = _arg1;
var duration = _arg2;
clipIndex = inactiveAchievementBox();
if (clipIndex >= 0){
var _local4 = clips[clipIndex];
with (_local4) {
activate();
scaleX = 1;
scaleY = 1;
x = (15 + (201 * clipIndex));
y = (480 - (height + 25));
user_name.text = GameManager._userName;
achievement_text.text = achievementText;
_duration = duration;
transitionIn();
_isComplete = false;
active.push(clips[clipIndex]);
};
};
}
public function update(_arg1:Number):void{
var index:int;
var clipCount:int;
var elapsedTime = _arg1;
clipCount = active.length;
index = 0;
while (index < clipCount) {
var _local3 = active[index];
with (_local3) {
if (_state == "Inactive"){
_spawnState = true;
active.splice(index, 1);
index--;
clipCount--;
} else {
update(elapsedTime);
};
};
index = (index + 1);
};
}
}
}//package
Section 14
//AchievementRecord (AchievementRecord)
package {
public class AchievementRecord {
public var _experiencePoints:int;
public var _achievementKey:String;
public var _achievementName:String;
public var _isAchieved:Boolean;
public function AchievementRecord(_arg1:String, _arg2:String, _arg3:int):void{
_achievementName = _arg1;
_achievementKey = _arg2;
_experiencePoints = _arg3;
_isAchieved = false;
}
}
}//package
Section 15
//Background (Background)
package {
import flash.display.*;
public dynamic class Background extends MovieClip {
}
}//package
Section 16
//CreditsScreen (CreditsScreen)
package {
import flash.events.*;
import flash.display.*;
public class CreditsScreen extends MovieClip {
public var _state:String;
public var Continue:MovieClip;
public function CreditsScreen():void{
x = 0;
y = 0;
_state = "Inactive";
visible = false;
}
public function activate():void{
_state = "Active";
visible = true;
}
public function check_rollovers(){
if (Continue.hitTestPoint(mouseX, mouseY)){
Continue.scaleX = 1.25;
Continue.scaleY = 1.25;
} else {
Continue.scaleX = 1;
Continue.scaleY = 1;
};
}
public function menu_mouseUp(_arg1:MouseEvent){
if (Continue.hitTestPoint(_arg1.stageX, _arg1.stageY)){
deactivate();
GameManager.gameState = "MainMenu";
};
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update():void{
switch (_state){
case "Active":
break;
};
}
}
}//package
Section 17
//Fly (Fly)
package {
import flash.geom.*;
import flash.display.*;
import flash.utils.*;
public class Fly extends MovieClip {
public var _type:int;
public var _speed:Number;
public var _scale:Number;
public var _targetLoc:Point;
public var _spawnState:Boolean;// = true
public var _idleDuration:Number;
public var _lastDistance:Number;
public var fly:MovieClip;
public var _state:String;
public var _idleChance:Number;
public var _idleInitTime:Number;
public var _facing:Number;
public function Fly():void{
_spawnState = true;
super();
deactivate();
}
public function activate():void{
_state = "Active";
visible = true;
_spawnState = false;
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update(_arg1:Number):void{
var _local2:Number;
var _local3:Number;
switch (_state){
case "Active":
x = (x + ((_speed * _arg1) * Math.cos(_facing)));
y = (y + ((_speed * _arg1) * Math.sin(_facing)));
_local2 = smallzMath.pDistance(new Point(x, y), _targetLoc);
if (_local2 > _lastDistance){
if (_type == 4){
deactivate();
} else {
_local3 = ((Math.random() * 100) + 1);
if (_local3 < _idleChance){
_idleInitTime = getTimer();
_state = "SetIdle";
} else {
_state = "GetNewPath";
};
};
};
_lastDistance = _local2;
break;
case "Idle":
if (GameManager.elapsedTime(_idleInitTime) > _idleDuration){
_state = "GetNewPath";
};
break;
case "GetNewPath":
break;
default:
break;
};
}
}
}//package
Section 18
//FlyManager (FlyManager)
package {
import flash.geom.*;
import flash.display.*;
import flash.utils.*;
public class FlyManager extends MovieClip {
public var active:Array;
public var PlayerFrog:Frog;
public var flies:Array;
public var LevelControl:LevelManager;
public var spawnInitTime:Number;
public var multiplier:int;// = 0
public var spawnDelay:Number;// = 16
public function FlyManager():void{
flies = new Array();
active = new Array();
spawnDelay = 16;
spawnInitTime = getTimer();
multiplier = 0;
super();
}
public function inactiveFly():int{
var _local1:int;
var _local2:int;
var _local3:int;
_local2 = -1;
_local3 = flies.length;
_local1 = 0;
while (_local1 < _local3) {
if (flies[_local1]._spawnState){
_local2 = _local1;
break;
};
_local1++;
};
return (_local2);
}
public function init(_arg1:Number, _arg2:LevelManager, _arg3:Frog):void{
var _local4:int;
LevelControl = _arg2;
PlayerFrog = _arg3;
_local4 = 0;
while (_local4 < _arg1) {
flies[_local4] = new Fly();
addChild(flies[_local4]);
flies[_local4].gotoAndStop(1);
_local4++;
};
}
public function getRandomPoint():Point{
var _local1:Point;
var _local2:Boolean;
var _local3:Number;
var _local4:int;
var _local5:int;
_local1 = new Point(0, 0);
_local2 = false;
_local5 = 100;
while (((!(_local2)) && ((_local4 < _local5)))) {
_local1.x = (Math.random() * GameManager.screenWidth);
_local1.y = (Math.random() * GameManager.screenHeight);
_local3 = smallzMath.pDistance(GameManager.centerLoc, _local1);
if (_local3 > 80){
_local2 = true;
};
};
return (_local1);
}
public function spawnSpeedy():void{
var flyIndex:int;
flyIndex = inactiveFly();
if (flyIndex >= 0){
var _local2 = flies[flyIndex];
with (_local2) {
activate();
x = -(width);
y = ((Math.random() * (GameManager.screenHeight - 100)) + 50);
_type = 4;
gotoAndStop(_type);
_targetLoc = new Point(0, 0);
_targetLoc.x = (GameManager.screenWidth + width);
_targetLoc.y = y;
_lastDistance = smallzMath.pDistance(new Point(x, y), _targetLoc);
_facing = smallzMath.pGetAngle(new Point(x, y), _targetLoc);
rotation = (((_facing / Math.PI) * 180) + 90);
_speed = 400;
_scale = 0.5;
scaleX = _scale;
scaleY = _scale;
active.push(flies[flyIndex]);
};
};
}
public function spawn(_arg1:int):void{
var flyIndex:int;
var targetLoc:Point;
var flyColor = _arg1;
flyIndex = inactiveFly();
targetLoc = getRandomPoint();
if (flyIndex >= 0){
var _local3 = flies[flyIndex];
with (_local3) {
activate();
x = targetLoc.x;
y = targetLoc.y;
_type = flyColor;
gotoAndStop(_type);
getNewPath(flies[flyIndex]);
_idleChance = LevelControl._flyIdleChance;
_speed = ((Math.random() * (LevelControl._flyMaxSpeed - LevelControl._flyMinSpeed)) + LevelControl._flyMinSpeed);
_scale = (((Math.random() * 20) + 40) / 100);
scaleX = _scale;
scaleY = _scale;
active.push(flies[flyIndex]);
};
};
}
public function spawnFlies():void{
var _local1:int;
_local1 = 0;
while (_local1 < LevelControl._blueFlies) {
spawn(1);
_local1++;
};
_local1 = 0;
while (_local1 < LevelControl._redFlies) {
spawn(2);
_local1++;
};
_local1 = 0;
while (_local1 < LevelControl._greenFlies) {
spawn(3);
_local1++;
};
spawnInitTime = getTimer();
}
public function spawnCheck():void{
if (GameManager.elapsedTime(spawnInitTime) > spawnDelay){
spawnInitTime = getTimer();
spawnSpeedy();
};
}
public function getNewPath(_arg1:Fly):void{
var targetFly = _arg1;
var _local3 = targetFly;
with (_local3) {
_targetLoc = getRandomPoint();
_lastdistance = smallzMath.pDistance(new Point(x, y), _targetLoc);
_facing = smallzMath.pGetAngle(new Point(x, y), _targetLoc);
rotation = (((_facing / Math.PI) * 180) + 90);
};
}
public function checkCollisionTongue(_arg1:ScorePopUpManager):void{
var index:int;
var count:int;
var distance:Number;
var pointDistance:Number;
var tongueAngle:Number;
var earnedPoints:*;
var scoreString:String;
var ScorePopUpControl = _arg1;
count = active.length;
earnedPoints = 50;
if ((((PlayerFrog._state == "TongueOut")) || ((PlayerFrog._state == "TongueRetract")))){
index = 0;
while (index < count) {
var _local3 = active[index];
with (_local3) {
switch (_state){
case "Active":
case "Idle":
pointDistance = smallzMath.pDistance(new Point(0, 0), PlayerFrog._tongueLoc);
distance = smallzMath.pDistance(new Point(x, y), new Point((PlayerFrog.x + PlayerFrog._tongueLoc.x), (PlayerFrog.y + PlayerFrog._tongueLoc.y)));
if ((((distance < 20)) && ((pointDistance > 40)))){
_state = "OnTongue";
if (PlayerFrog._lastColor == _type){
multiplier++;
} else {
if (_type != 4){
PlayerFrog._lastColor = _type;
multiplier = 1;
};
};
switch (_type){
case 1:
PlayerFrog._blueCaught++;
break;
case 2:
PlayerFrog._redCaught++;
break;
case 3:
GameManager.incrementHealth(5);
PlayerFrog._greenCaught++;
break;
case 4:
PlayerFrog._speedyCaught++;
break;
};
earnedPoints = (int(pointDistance) * 5);
earnedPoints = (multiplier * earnedPoints);
if (earnedPoints > GameManager._mostPoints){
GameManager._mostPoints = earnedPoints;
};
if (_type == 4){
earnedPoints = 25000;
};
GameManager.playerScore = (GameManager.playerScore + earnedPoints);
if ((((multiplier > 1)) && (!((_type == 4))))){
scoreString = ((("x" + multiplier) + " ") + earnedPoints);
} else {
scoreString = earnedPoints;
};
ScorePopUpControl.activate(new Point(x, y), scoreString);
};
break;
};
};
index = (index + 1);
};
};
}
public function update(_arg1:Number):void{
var index:int;
var flyCount:int;
var elapsedTime = _arg1;
flyCount = active.length;
index = 0;
while (index < flyCount) {
var _local3 = active[index];
with (_local3) {
if (_state == "Inactive"){
_spawnState = true;
active.splice(index, 1);
index--;
flyCount--;
} else {
update(elapsedTime);
switch (_state){
case "SetIdle":
_idleDuration = (((Math.random() * (LevelControl._flyMaxIdle - LevelControl._flyMinIdle)) + LevelControl._flyMinIdle) * 0.15);
_state = "Idle";
break;
case "GetNewPath":
getNewPath(active[index]);
_state = "Active";
break;
case "OnTongue":
x = (PlayerFrog.x + PlayerFrog._tongueLoc.x);
y = (PlayerFrog.y + PlayerFrog._tongueLoc.y);
if (PlayerFrog.body.hitTestObject(active[index])){
deactivate();
};
break;
};
};
};
index = (index + 1);
};
}
public function deactivateAllFlies():void{
var _local1:int;
var _local2:int;
_local2 = flies.length;
_local1 = 0;
while (_local1 < _local2) {
flies[_local1].deactivate();
flies[_local1]._spawnState = true;
_local1++;
};
active = new Array();
}
}
}//package
Section 19
//Frog (Frog)
package {
import flash.geom.*;
import flash.display.*;
public class Frog extends MovieClip {
public var _tongueSpeed:Number;// = 900
public var _speedyCaught:int;
public var _tongueTargetLoc:Point;
public var _blueCaught:int;
public var _hornetsCaught:int;
public var _tongue:Shape;
public var _tongueLoc:Point;
public var _scale:Number;
public var _targetLoc:Point;
public var _tongueLastDistance:Number;
public var _tongueAngle:Number;
public var _state:String;
public var _greenCaught:int;
public var body:MovieClip;
public var _caught:int;
public var _shots:int;
public var _redCaught:int;
public var _facing:Number;
public var _lastColor:int;
public function Frog():void{
_tongueSpeed = 900;
super();
addFrameScript(0, frame1);
_tongue = new Shape();
addChildAt(_tongue, 0);
_tongue.x = -(x);
_tongue.y = -(y);
deactivate();
}
public function activate():void{
_state = "Active";
visible = true;
resetStatVariables();
_lastColor = 0;
}
public function shootTongue(_arg1:Point){
frog_feast.Swipe.play();
_shots++;
_tongueTargetLoc = _arg1;
_tongueTargetLoc.x = (_tongueTargetLoc.x - x);
_tongueTargetLoc.y = (_tongueTargetLoc.y - y);
_tongueLoc = new Point(0, 0);
_tongueAngle = smallzMath.pGetAngle(_tongueLoc, _tongueTargetLoc);
resetStatVariables();
_state = "TongueOut";
}
public function position(_arg1:Number, _arg2:Number):void{
x = _arg1;
y = _arg2;
}
public function handleSpecialBonuses():void{
var _local1:int;
var _local2:int;
_local1 = (((_redCaught + _blueCaught) + _greenCaught) + _speedyCaught);
_local2 = ((_local1 - 1) * 2500);
GameManager._totalBlue = (GameManager._totalBlue + _blueCaught);
GameManager._totalRed = (GameManager._totalRed + _redCaught);
GameManager._totalGreen = (GameManager._totalGreen + _greenCaught);
GameManager._speedyCount = (GameManager._speedyCount + _speedyCaught);
if (_local1 > 0){
frog_feast.Gulp.play();
_caught++;
} else {
_lastColor = 0;
};
if (_local1 > 1){
GameManager.playerScore = (GameManager.playerScore + _local2);
GameManager.specialBonus(String(((("x" + _local1) + " Bonus ") + _local2)));
};
}
function frame1(){
stop();
}
public function resetStatVariables():void{
_redCaught = 0;
_blueCaught = 0;
_greenCaught = 0;
_hornetsCaught = 0;
_speedyCaught = 0;
}
public function drawTongue():void{
var _local2 = _tongue.graphics;
with (_local2) {
clear();
lineStyle(5, 0xFF0000);
moveTo(0, 0);
lineTo(_tongueLoc.x, _tongueLoc.y);
};
_tongue.rotation = -(rotation);
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function clearTongue():void{
_tongue.graphics.clear();
}
public function update(_arg1:Number):void{
var _local2:Number;
var _local3:Number;
switch (_state){
case "Active":
_targetLoc = new Point(stage.mouseX, stage.mouseY);
_facing = smallzMath.pGetAngle(new Point(x, y), _targetLoc);
rotation = (((_facing / Math.PI) * 180) + 90);
break;
case "TongueOut":
_tongueLoc.x = (_tongueLoc.x + ((_tongueSpeed * _arg1) * Math.cos(_tongueAngle)));
_tongueLoc.y = (_tongueLoc.y + ((_tongueSpeed * _arg1) * Math.sin(_tongueAngle)));
_local3 = (smallzMath.pDistance(new Point(0, 0), _tongueTargetLoc) + 30);
_local2 = smallzMath.pDistance(new Point(0, 0), _tongueLoc);
if (_local2 > _local3){
_state = "TongueRetract";
} else {
drawTongue();
};
break;
case "TongueRetract":
_tongueLoc.x = (_tongueLoc.x - ((_tongueSpeed * _arg1) * Math.cos(_tongueAngle)));
_tongueLoc.y = (_tongueLoc.y - ((_tongueSpeed * _arg1) * Math.sin(_tongueAngle)));
_local3 = smallzMath.pDistance(new Point(0, 0), _tongueTargetLoc);
_local2 = smallzMath.pDistance(_tongueTargetLoc, _tongueLoc);
if (_local2 > _local3){
clearTongue();
handleSpecialBonuses();
GameManager._slurpPct = ("Slurp %" + int(((_caught / _shots) * 100)));
_state = "Active";
} else {
drawTongue();
};
break;
};
}
}
}//package
Section 20
//frog_feast (frog_feast)
package {
import flash.events.*;
import flash.geom.*;
import flash.display.*;
import flash.text.*;
import flash.net.*;
import flash.system.*;
import flash.ui.*;
public dynamic class frog_feast extends MovieClip {
private var Hornet_Count:int;// = 22
public var NonobaControl:NonobaManager;
private var faultCount:int;// = 0
private var load_percent:Number;
private var Fly_Count:int;// = 50
private var UI_MainMenu:MainMenuScreen;
public var PopUp_UI:PopUp;
public var FPS_Display:smallzFPS;
private var UI_HighScores:HighScoresScreen;
private var UI_Submit:SubmitScoreScreen;
private var PlayerFrog:Frog;
public var KeyboardControl:smallzKeyboardManager;
private var TheBackground:Background;
private var UI_Pause:PauseScreen;
public var LevelControl:LevelManager;
public var MessageControl:MessageManager;
public var HornetControl:HornetManager;
private var cursorTarget:TongueTarget;
public var FlyControl:FlyManager;
private var UI_Instructions:InstructionsScreen;
public var HighScoreControl:HighScoreManager;
public var ScorePopUpControl:ScorePopUpManager;
private var Soundtrack:SoundtrackMusic;
private var UI_Credits:CreditsScreen;
private var PlayerPad:Pad;
private var UI_Game:GameUIScreen;
public var load_screen:MovieClip;
public static var Gulp:Gulp_sfx;
public static var Debug:smallzDebug;
public static var Swipe:Swipe_sfx;
public function frog_feast(){
Fly_Count = 50;
Hornet_Count = 22;
faultCount = 0;
super();
addFrameScript(0, frame1, 2, frame3, 3, frame4);
Security.allowDomain("*");
Security.allowInsecureDomain("*");
Security.loadPolicyFile("http://games.smallzworld.com/crossdomain.xml");
}
public function preload(){
stop();
this.addEventListener(Event.ENTER_FRAME, showProgress);
}
public function mouseUp_handler(_arg1:MouseEvent){
var _local2:URLRequest;
switch (GameManager.gameState){
case "Game":
if (PlayerFrog._state == "Active"){
PlayerFrog.shootTongue(new Point(mouseX, mouseY));
};
break;
case "LevelPrompt":
PopUp_UI._duration = 0;
break;
case "MainMenu":
UI_MainMenu.menu_mouseUp(_arg1);
if (MessageControl.messagePod.hitTestPoint(mouseX, mouseY)){
_local2 = new URLRequest(MessageControl.messagePod._linkURL);
navigateToURL(_local2);
};
if (GameManager.gameState != "MainMenu"){
MessageControl.messagePod.visible = false;
};
break;
case "Instructions":
UI_Instructions.menu_mouseUp(_arg1);
break;
case "Credits":
UI_Credits.menu_mouseUp(_arg1);
break;
case "Pause":
UI_Pause.menu_mouseUp(_arg1);
break;
case "HighScores":
UI_HighScores.menu_mouseUp(_arg1);
break;
case "GameOver":
UI_Submit.menu_mouseUp(_arg1);
break;
};
}
private function checkEndGameAchievements():void{
if (!NonobaControl.isAchieved("high1")){
if (GameManager.playerScore >= 500000){
NonobaControl.markAchievement("high1");
};
};
if (!NonobaControl.isAchieved("high2")){
if (GameManager.playerScore >= 250000){
NonobaControl.markAchievement("high2");
};
};
if (!NonobaControl.isAchieved("high3")){
if (GameManager.playerScore >= 75000){
NonobaControl.markAchievement("high3");
};
};
}
private function checkAchievements():void{
if (!NonobaControl.isAchieved("speedy10")){
if (GameManager._speedyCount >= 10){
NonobaControl.markAchievement("speedy10");
};
};
if (!NonobaControl.isAchieved("bluefly")){
if (PlayerFrog._blueCaught >= 1){
NonobaControl.markAchievement("bluefly");
};
};
if (!NonobaControl.isAchieved("redfly")){
if (PlayerFrog._redCaught >= 1){
NonobaControl.markAchievement("redfly");
};
};
if (!NonobaControl.isAchieved("greenfly")){
if (PlayerFrog._greenCaught >= 1){
NonobaControl.markAchievement("greenfly");
};
};
if (!NonobaControl.isAchieved("bluetwo")){
if (PlayerFrog._blueCaught >= 2){
NonobaControl.markAchievement("bluetwo");
};
};
if (!NonobaControl.isAchieved("redtwo")){
if (PlayerFrog._redCaught >= 2){
NonobaControl.markAchievement("redtwo");
};
};
if (!NonobaControl.isAchieved("greentwo")){
if (PlayerFrog._greenCaught >= 2){
NonobaControl.markAchievement("greentwo");
};
};
if (!NonobaControl.isAchieved("blue100")){
if (GameManager._totalBlue >= 100){
NonobaControl.markAchievement("blue100");
};
};
if (!NonobaControl.isAchieved("red100")){
if (GameManager._totalBlue >= 100){
NonobaControl.markAchievement("red100");
};
};
if (!NonobaControl.isAchieved("green100")){
if (GameManager._totalBlue >= 100){
NonobaControl.markAchievement("green100");
};
};
if (!NonobaControl.isAchieved("bigcatch")){
if (GameManager._mostPoints >= 5000){
NonobaControl.markAchievement("bigcatch");
};
};
if (!NonobaControl.isAchieved("monstercatch")){
if (GameManager._mostPoints >= 10000){
NonobaControl.markAchievement("monstercatch");
};
};
if (!NonobaControl.isAchieved("epiccatch")){
if (GameManager._mostPoints >= 15000){
NonobaControl.markAchievement("epiccatch");
};
};
}
public function initApplication(){
var _local1:int;
Soundtrack = new SoundtrackMusic();
Gulp = new Gulp_sfx();
Swipe = new Swipe_sfx();
TheBackground = new Background();
addChild(TheBackground);
TheBackground.x = 0;
TheBackground.y = 0;
TheBackground.cacheAsBitmap = true;
LevelControl = new LevelManager();
UI_Game = new GameUIScreen();
addChild(UI_Game);
NonobaControl = new NonobaManager();
addChild(NonobaControl);
PlayerPad = new Pad();
addChild(PlayerPad);
PlayerFrog = new Frog();
addChild(PlayerFrog);
PlayerFrog.cacheAsBitmap = true;
FlyControl = new FlyManager();
addChild(FlyControl);
FlyControl.init(Fly_Count, LevelControl, PlayerFrog);
HornetControl = new HornetManager();
addChild(HornetControl);
HornetControl.init(Hornet_Count, LevelControl, PlayerFrog);
UI_MainMenu = new MainMenuScreen();
addChild(UI_MainMenu);
UI_Instructions = new InstructionsScreen();
addChild(UI_Instructions);
UI_Credits = new CreditsScreen();
addChild(UI_Credits);
UI_Pause = new PauseScreen();
addChild(UI_Pause);
UI_HighScores = new HighScoresScreen();
addChild(UI_HighScores);
UI_Submit = new SubmitScoreScreen();
addChild(UI_Submit);
ScorePopUpControl = new ScorePopUpManager();
addChild(ScorePopUpControl);
ScorePopUpControl.init(15);
PopUp_UI = new PopUp();
addChild(PopUp_UI);
MessageControl = new MessageManager();
addChild(MessageControl.messagePod);
FPS_Display = new smallzFPS(10, 75, 20);
HighScoreControl = new HighScoreManager();
KeyboardControl = new smallzKeyboardManager();
addChild(KeyboardControl);
KeyboardControl.init();
stage.addEventListener(Event.ENTER_FRAME, mainLoop);
stage.addEventListener(MouseEvent.MOUSE_UP, mouseUp_handler);
stage.focus = this;
NonobaControl._userName = "Init it";
if (GameManager.isNonoba){
NonobaControl.getUsername();
defineAchievements();
UI_MainMenu.LeaderBoards.visible = false;
UI_MainMenu.HighScores.visible = false;
};
cursorTarget = new TongueTarget();
addChild(cursorTarget);
Mouse.hide();
GameManager.initScorePopUpManager(ScorePopUpControl);
Soundtrack.play(0, 999);
}
private function checkEndLevelAchievements():void{
var _local1:int;
if (!NonobaControl.isAchieved("quickdraw")){
if ((((GameManager._totalLevelTime <= 300)) && ((LevelControl._currentLevel == 10)))){
NonobaControl.markAchievement("quickdraw");
};
};
_local1 = int(((PlayerFrog._caught / PlayerFrog._shots) * 100));
if (!NonobaControl.isAchieved("perfect5")){
if ((((_local1 == 60)) && ((LevelControl._currentLevel == 5)))){
NonobaControl.markAchievement("perfect5");
};
};
if (!NonobaControl.isAchieved("slurpnovice")){
if ((((_local1 >= 60)) && ((LevelControl._currentLevel >= 10)))){
NonobaControl.markAchievement("slurpnovice");
};
};
if (!NonobaControl.isAchieved("slurpamatuer")){
if ((((_local1 >= 70)) && ((LevelControl._currentLevel >= 10)))){
NonobaControl.markAchievement("slurpamatuer");
};
};
if (!NonobaControl.isAchieved("slurppro")){
if ((((_local1 >= 80)) && ((LevelControl._currentLevel >= 10)))){
NonobaControl.markAchievement("slurppro");
};
};
if (!NonobaControl.isAchieved("slurpmaster")){
if ((((_local1 >= 90)) && ((LevelControl._currentLevel >= 10)))){
NonobaControl.markAchievement("slurpmaster");
};
};
if (!NonobaControl.isAchieved("hornetfree10")){
if ((((GameManager._totalHornets == 0)) && ((LevelControl._currentLevel == 10)))){
NonobaControl.markAchievement("hornetfree10");
};
};
}
function frame3(){
stop();
}
public function showProgress(_arg1:Event):void{
load_percent = Math.round(((this.loaderInfo.bytesLoaded / this.loaderInfo.bytesTotal) * 100));
load_screen.loader.load_bar.Fill.width = (198 * (load_percent / 100));
if (this.loaderInfo.bytesLoaded == this.loaderInfo.bytesTotal){
this.removeEventListener(Event.ENTER_FRAME, showProgress);
load_screen.visible = false;
showAds(GameManager.mochiID, GameManager.isMochi);
};
}
function frame1(){
preload();
}
private function defineAchievements():void{
NonobaControl.addAchievement("Blue Fly", "bluefly", 1);
NonobaControl.addAchievement("Red Fly", "redfly", 1);
NonobaControl.addAchievement("Green Fly", "greenfly", 1);
NonobaControl.addAchievement("Blue Two", "bluetwo", 2);
NonobaControl.addAchievement("Red Two", "redtwo", 2);
NonobaControl.addAchievement("Green Two", "greentwo", 2);
NonobaControl.addAchievement("Blue 100", "blue100", 3);
NonobaControl.addAchievement("Red 100", "red100", 3);
NonobaControl.addAchievement("Green 100", "green100", 3);
NonobaControl.addAchievement("Perfect 5", "perfect5", 5);
NonobaControl.addAchievement("Hornet Free", "hornetfree10", 5);
NonobaControl.addAchievement("Quick Draw", "quickdraw", 5);
NonobaControl.addAchievement("Slurp Master", "slurpmaster", 5);
NonobaControl.addAchievement("Slurp Pro", "slurppro", 3);
NonobaControl.addAchievement("Slurp Amatuer", "slurpamatuer", 2);
NonobaControl.addAchievement("Slurp Novice", "slurpnovice", 1);
NonobaControl.addAchievement("Big Catch", "bigcatch", 1);
NonobaControl.addAchievement("Monster Catch", "monstercatch", 5);
NonobaControl.addAchievement("Epic Catch", "epiccatch", 10);
NonobaControl.addAchievement("Speedy 10", "speedy10", 5);
NonobaControl.addAchievement("Score 500K", "high1", 5);
NonobaControl.addAchievement("Score 250k", "high2", 3);
NonobaControl.addAchievement("Score 75K", "high3", 1);
}
public function adFinished():void{
GameManager.isStarted = true;
load_screen.visible = false;
GameManager.gameState = "MainMenu";
gotoAndPlay(2);
initApplication();
}
function frame4(){
gotoAndPlay(2);
}
private function processInput(_arg1:Number){
if (KeyboardControl.isPressed(37)){
};
if (KeyboardControl.isPressed(38)){
};
if (KeyboardControl.isPressed(39)){
};
if (KeyboardControl.isPressed(40)){
};
if (KeyboardControl.isPressed(32)){
NonobaControl.toggleDebugBox();
};
}
public function showAds(_arg1:String, _arg2:Boolean){
stop();
if (_arg2){
MochiAd.showPreGameAd({clip:root, id:_arg1, res:"640x480", ad_finished:adFinished});
} else {
adFinished();
};
}
private function mainLoop(_arg1:Event){
var _local2:Number;
var _local3:String;
_local2 = GameManager.clockPulse();
cursorTarget.x = stage.mouseX;
cursorTarget.y = stage.mouseY;
if (_local2 > 0.07){
faultCount++;
_local2 = 0.07;
if (faultCount > 10){
stage.quality = StageQuality.LOW;
GameManager._detailLevel = "low detail";
UI_Game.level.text = ((("Level " + LevelControl._currentLevel) + " ") + GameManager._detailLevel);
};
};
processInput(_local2);
FPS_Display.update();
if (GameManager.isNonoba){
NonobaControl.AchievementBoxControl.update(_local2);
};
switch (GameManager.gameState){
case "Game":
if (UI_Game._state == "Inactive"){
UI_Game.activate();
PlayerPad.activate();
PlayerPad.position(GameManager.centerLoc.x, GameManager.centerLoc.y);
PlayerFrog.activate();
PlayerFrog.position(GameManager.centerLoc.x, GameManager.centerLoc.y);
};
FlyControl.update(_local2);
HornetControl.update(_local2);
PlayerFrog.update(_local2);
HornetControl.checkCollisionTongue(ScorePopUpControl);
FlyControl.checkCollisionTongue(ScorePopUpControl);
ScorePopUpControl.update(_local2);
if (LevelControl._speedy){
FlyControl.spawnCheck();
};
UI_Game.score.text = ("Score " + GameManager.playerScore);
UI_Game.slurp_pct.text = GameManager._slurpPct;
UI_Game.game_clock.text = ("Time Remaining " + GameManager.timeString((LevelControl._duration - LevelControl.timerValue())));
UI_Game.update_damage_meter((GameManager.health / 100));
if ((((FlyControl.multiplier > 0)) && ((PlayerFrog._lastColor > 0)))){
UI_Game.fly.visible = true;
UI_Game.multiplier.visible = true;
UI_Game.fly.gotoAndStop(PlayerFrog._lastColor);
UI_Game.multiplier.text = ("x" + FlyControl.multiplier);
} else {
UI_Game.fly.visible = false;
UI_Game.multiplier.visible = false;
};
if (((GameManager.isNonoba) && (GameManager._nonobaAchievementsEnabled))){
checkAchievements();
NonobaControl.updateDebugBox();
};
if ((((FlyControl.active.length == 0)) && ((PlayerFrog._state == "Active")))){
GameManager._totalLevelTime = (GameManager._totalLevelTime + (LevelControl._duration - LevelControl.timerValue()));
if (((GameManager.isNonoba) && (GameManager._nonobaAchievementsEnabled))){
checkEndLevelAchievements();
};
LevelControl.nextLevel();
GameManager.gameState = "LevelSetup";
};
if ((((GameManager.health == 0)) || ((LevelControl.timerValue() > LevelControl._duration)))){
if (PlayerFrog._state == "Active"){
GameManager.gameState = "GameOver";
};
};
break;
case "MainMenu":
if (UI_MainMenu._state == "Inactive"){
UI_MainMenu.activate();
UI_Game.deactivate();
if (!MessageControl._messageLoaded){
MessageControl.load_message(GameManager.gameID);
};
};
if (MessageControl._messageLoaded){
MessageControl.display_message(163, 145);
};
if (GameManager.isNonoba){
UI_MainMenu.nonoba_text.text = (("Welcome " + NonobaControl._userName) + "!\nGood luck in Frog Feast, and don't forget to check out my profile for new games!");
} else {
UI_MainMenu.nonoba_text.visible = false;
};
UI_MainMenu.check_rollovers();
break;
case "LevelSetup":
FlyControl.deactivateAllFlies();
HornetControl.deactivateAllHornets();
LevelControl.initLevel();
UI_Game.game_clock.text = ("Time Remaining " + GameManager.timeString(LevelControl._duration));
UI_Game.level.text = ((("Level " + LevelControl._currentLevel) + " ") + GameManager._detailLevel);
GameManager.gameState = "LevelPrompt";
break;
case "LevelPrompt":
if (PopUp_UI._state == "Inactive"){
PopUp_UI.activate(LevelControl._caption, LevelControl._description, new Point(GameManager.centerLoc.x, GameManager.centerLoc.y), 300);
};
PopUp_UI.update(_local2);
if (PopUp_UI._isComplete){
FlyControl.spawnFlies();
HornetControl.spawnHornets();
LevelControl.startTimer();
GameManager.gameState = "Game";
};
break;
case "Instructions":
if (UI_Instructions._state == "Inactive"){
UI_Instructions.activate();
};
UI_Instructions.check_rollovers();
break;
case "Credits":
if (UI_Credits._state == "Inactive"){
UI_Credits.activate();
};
UI_Credits.check_rollovers();
break;
case "GameOver":
if (UI_Submit._state == "Inactive"){
UI_Submit.activate();
if (GameManager.isNonoba){
if (GameManager._nonobaAchievementsEnabled){
checkEndGameAchievements();
};
if (GameManager._nonobaHighScoresEnabled){
NonobaControl.saveHighscore("highscores", GameManager.playerScore);
};
};
};
UI_Submit.check_rollovers();
break;
case "Pause":
if (UI_Pause._state == "Inactive"){
UI_Pause.activate();
};
break;
case "SaveHighScore":
if (GameManager._highScoresEnabled){
if (GameManager.isNonoba){
_local3 = ("Nonoba - " + GameManager._userName);
} else {
_local3 = GameManager._userName;
};
HighScoreControl.save_highscore(GameManager.gameID, 0, _local3, LevelControl._currentLevel, GameManager.playerScore, 0, "No Comment");
if (GameManager.isMochi){
MochiAd.showInterLevelAd({clip:root, id:GameManager.mochiID, res:"640x480"});
};
};
break;
case "HighScores":
if (UI_HighScores._state == "Inactive"){
UI_HighScores.activate();
HighScoreControl.load_highscores(GameManager.gameID);
};
if (GameManager._highScoresLoaded){
UI_HighScores.update();
GameManager._highScoresLoaded = false;
};
UI_HighScores.check_rollovers();
break;
case "Reset":
GameManager.resetGame();
NonobaControl.resetAchievements();
LevelControl._currentLevel = 1;
PlayerFrog._shots = 0;
PlayerFrog._caught = 0;
GameManager.gameState = "LevelSetup";
break;
};
}
}
}//package
Section 21
//GameManager (GameManager)
package {
import flash.geom.*;
import flash.utils.*;
public class GameManager {
public static var _highScores:Array;
public static var ScorePopUpControl:ScorePopUpManager;
public static var level:int = 1;
public static var _totalRed:int;
public static var gameID:int = 18;
public static var _nonobaHighScoresEnabled:Boolean = false;
public static var _nonobaDebuggerEnabled:Boolean = false;
public static var _highScoresLoaded:Boolean = false;
public static var centerLoc:Point = new Point((screenWidth / 2), (screenHeight / 2));
public static var _totalLevelTime:Number;
public static var playerScore:uint = 0;
public static var Debug:Boolean = false;
public static var screenWidth:Number = 640;
public static var _nonobaAchievementsEnabled:Boolean = false;
public static var isMochi:Boolean = true;
public static var screenHeight:Number = 480;
public static var _totalHornets:int;
public static var _totalGreen:int;
public static var gameState:String = "MainMenu";
public static var clockPulseInitTime:Number = getTimer();
public static var isNonoba:Boolean = false;
public static var _userName:String;
public static var _totalBlue:int;
public static var _nonobaSendEnabled:Boolean = false;
public static var health:Number = 100;
public static var mochiID:String = "797ecf18f008e440";
public static var _speedyCount:int;
public static var _highScoresEnabled:Boolean = true;
public static var _mostPoints:int;
public static var _slurpPct:String;
public static var isStarted:Boolean = false;
public static var _detailLevel:String = "";
public static var initTime:Number;
public function GameManager():void{
}
public static function specialBonus(_arg1:String):void{
ScorePopUpControl.activate(centerLoc, _arg1);
}
public static function clockPulse():Number{
var _local1:Number;
_local1 = elapsedTime(clockPulseInitTime);
clockPulseInitTime = getTimer();
return (_local1);
}
public static function decrementHealth(_arg1:Number):void{
health = (health - _arg1);
if (health < 0){
health = 0;
};
}
public static function initScorePopUpManager(_arg1:ScorePopUpManager):void{
ScorePopUpControl = _arg1;
}
public static function scorePopUp(_arg1:String, _arg2:Point):void{
ScorePopUpControl.activate(_arg2, _arg1);
}
public static function timeString(_arg1:int):String{
var _local2:int;
var _local3:String;
_local2 = Math.floor((_arg1 / 60));
_arg1 = (_arg1 - (_local2 * 60));
_local3 = ((_local2 + ":") + String((_arg1 + 100)).substr(1, 2));
return (_local3);
}
public static function resetGame():void{
playerScore = 0;
health = 100;
_slurpPct = "";
gameState = "Game";
_totalBlue = 0;
_totalRed = 0;
_totalGreen = 0;
_totalLevelTime = 0;
_speedyCount = 0;
_mostPoints = 0;
_totalHornets = 0;
}
public static function incrementScore(_arg1:int):void{
playerScore = (playerScore + _arg1);
}
public static function incrementHealth(_arg1:Number):void{
health = (health + _arg1);
if (health > 100){
health = 100;
};
}
public static function elapsedTime(_arg1:Number):Number{
var _local2:Number;
_local2 = ((getTimer() - _arg1) / 1000);
return (_local2);
}
}
}//package
Section 22
//GameUIScreen (GameUIScreen)
package {
import flash.display.*;
import flash.text.*;
public class GameUIScreen extends MovieClip {
public var damage:MovieClip;
public var level:TextField;
public var game_clock:TextField;
public var fly:Fly;
public var score:TextField;
public var _state:String;
public var slurp_pct:TextField;
public var multiplier:TextField;
public function GameUIScreen():void{
x = 0;
y = 0;
deactivate();
}
public function activate():void{
_state = "Active";
visible = true;
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update_damage_meter(_arg1:Number):void{
if (_arg1 > 0.66){
damage.green.visible = true;
damage.red.visible = false;
damage.yellow.visible = false;
damage.green.width = (200 * _arg1);
};
if ((((_arg1 > 0.33)) && ((_arg1 <= 0.66)))){
damage.yellow.visible = true;
damage.green.visible = false;
damage.red.visible = false;
damage.yellow.width = (200 * _arg1);
};
if (_arg1 <= 0.33){
damage.red.visible = true;
damage.green.visible = false;
damage.yellow.visible = false;
damage.red.width = (200 * _arg1);
};
}
public function update():void{
switch (_state){
case "Active":
break;
};
}
}
}//package
Section 23
//GrayBallSymbol (GrayBallSymbol)
package {
import flash.display.*;
public dynamic class GrayBallSymbol extends MovieClip {
}
}//package
Section 24
//Gulp_sfx (Gulp_sfx)
package {
import flash.media.*;
public dynamic class Gulp_sfx extends Sound {
}
}//package
Section 25
//HighScoreListingSymbol (HighScoreListingSymbol)
package {
import flash.display.*;
import flash.text.*;
public dynamic class HighScoreListingSymbol extends MovieClip {
public var User:TextField;
public var Rank:TextField;
public var Score:TextField;
}
}//package
Section 26
//HighScoreManager (HighScoreManager)
package {
import flash.events.*;
import flash.display.*;
import flash.net.*;
public class HighScoreManager extends MovieClip {
public function HighScoreManager():void{
}
public function load_highscores(_arg1:int):void{
var _local2:URLRequest;
var _local3:URLVariables;
var _local4:URLLoader;
_local2 = new URLRequest("http://games.smallzworld.com/RecordManagement.php");
_local3 = new URLVariables();
_local3.Routine = "AS3LoadHighScores";
_local3.Game_ID = _arg1;
_local2.data = _local3;
_local4 = new URLLoader();
_local4.dataFormat = URLLoaderDataFormat.VARIABLES;
_local4.addEventListener(Event.COMPLETE, highscores_handler);
_local4.load(_local2);
GameManager.gameState = "Loading";
GameManager._highScoresLoaded = false;
}
private function highscores_handler(_arg1:Event):void{
var _local2:URLLoader;
var _local3:int;
var _local4:Array;
_local2 = URLLoader(_arg1.target);
_local4 = new Array();
_local3 = 1;
while (_local3 <= 10) {
if (_local2.data[("Score_" + _local3)]){
_local4[(_local3 - 1)] = new HighScoreRecord(_local3, _local2.data[("User_" + _local3)], _local2.data[("Score_" + _local3)], 0, "");
};
_local3++;
};
GameManager._highScores = _local4;
GameManager._highScoresLoaded = true;
GameManager.gameState = "HighScores";
}
public function save_highscore(_arg1:int, _arg2:int, _arg3:String, _arg4:int, _arg5:int, _arg6:int, _arg7:String):void{
var _local8:URLRequest;
var _local9:URLVariables;
var _local10:URLLoader;
_local8 = new URLRequest("http://games.smallzworld.com/RecordManagement.php");
_local9 = new URLVariables();
_local9.Routine = "AddHighScore";
_local9.Game_ID = _arg1;
_local9.Profile_ID = _arg2;
_local9.UserName = _arg3;
_local9.Level = _arg4;
_local9.Score = _arg5;
_local9.TimeScore = _arg6;
_local9.Comment = _arg7;
_local8.data = _local9;
_local10 = new URLLoader();
_local10.dataFormat = URLLoaderDataFormat.VARIABLES;
_local10.addEventListener(Event.COMPLETE, save_highscore_handler);
_local10.load(_local8);
GameManager.gameState = "Saving";
}
private function save_highscore_handler(_arg1:Event):void{
var _local2:URLLoader;
var _local3:int;
_local2 = URLLoader(_arg1.target);
GameManager.gameState = "MainMenu";
}
}
}//package
Section 27
//HighScoreRecord (HighScoreRecord)
package {
public class HighScoreRecord {
public var _comment:String;
public var _level:int;
public var _rank:int;
public var _user:String;
public var _score:Number;
public function HighScoreRecord(_arg1:int, _arg2:String, _arg3:Number, _arg4:int, _arg5:String):void{
_rank = _arg1;
_user = _arg2;
_score = _arg3;
_level = _arg4;
_comment = _arg5;
}
}
}//package
Section 28
//HighScoresScreen (HighScoresScreen)
package {
import flash.events.*;
import flash.display.*;
public class HighScoresScreen extends MovieClip {
public var score_10:HighScoreListingSymbol;
public var _state:String;
public var score_2:HighScoreListingSymbol;
public var score_6:HighScoreListingSymbol;
public var score_7:HighScoreListingSymbol;
public var score_9:HighScoreListingSymbol;
public var score_3:HighScoreListingSymbol;
public var Continue:MovieClip;
public var score_5:HighScoreListingSymbol;
public var score_8:HighScoreListingSymbol;
public var score_1:HighScoreListingSymbol;
public var score_4:HighScoreListingSymbol;
public function HighScoresScreen():void{
x = 0;
y = 0;
_state = "Inactive";
visible = false;
}
public function activate():void{
var _local1:int;
_state = "Active";
visible = true;
_local1 = 1;
while (_local1 <= 10) {
this[("score_" + _local1)].visible = false;
_local1++;
};
}
public function check_rollovers():void{
if (Continue.hitTestPoint(mouseX, mouseY)){
Continue.scaleX = 1.25;
Continue.scaleY = 1.25;
} else {
Continue.scaleX = 1;
Continue.scaleY = 1;
};
}
public function menu_mouseUp(_arg1:MouseEvent):void{
if (Continue.hitTestPoint(_arg1.stageX, _arg1.stageY)){
deactivate();
GameManager.gameState = "MainMenu";
};
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update():void{
var index:int;
var score_count:int;
var score_index:int;
score_count = GameManager._highScores.length;
index = 0;
while (index < score_count) {
var _local2 = GameManager;
with (_local2) {
score_index = (index + 1);
this[("score_" + score_index)].Rank.text = String(_highScores[index]._rank);
this[("score_" + score_index)].Score.text = String(_highScores[index]._score);
this[("score_" + score_index)].User.text = _highScores[index]._user;
this[("score_" + score_index)].visible = true;
};
index = (index + 1);
};
}
}
}//package
Section 29
//Hornet (Hornet)
package {
import flash.geom.*;
import flash.display.*;
import flash.utils.*;
public class Hornet extends MovieClip {
public var _type:int;
public var _speed:Number;
public var _scale:Number;
public var _targetLoc:Point;
public var _spawnState:Boolean;// = true
public var _idleDuration:Number;
public var _lastDistance:Number;
public var _state:String;
public var _idleChance:Number;
public var _idleInitTime:Number;
public var _facing:Number;
public function Hornet():void{
_spawnState = true;
super();
deactivate();
}
public function activate():void{
_state = "Active";
visible = true;
_spawnState = false;
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update(_arg1:Number):void{
var _local2:Number;
var _local3:Number;
switch (_state){
case "Active":
x = (x + ((_speed * _arg1) * Math.cos(_facing)));
y = (y + ((_speed * _arg1) * Math.sin(_facing)));
_local2 = smallzMath.pDistance(new Point(x, y), _targetLoc);
if (_local2 > _lastDistance){
_local3 = ((Math.random() * 100) + 1);
if (_local3 < _idleChance){
_idleInitTime = getTimer();
_state = "SetIdle";
} else {
_state = "GetNewPath";
};
};
_lastDistance = _local2;
break;
case "Idle":
if (GameManager.elapsedTime(_idleInitTime) > _idleDuration){
_state = "GetNewPath";
};
break;
case "GetNewPath":
break;
default:
break;
};
}
}
}//package
Section 30
//HornetManager (HornetManager)
package {
import flash.geom.*;
import flash.display.*;
import flash.utils.*;
public class HornetManager extends MovieClip {
public var active:Array;
public var PlayerFrog:Frog;
public var hornets:Array;
public var lastColor:int;// = 0
public var LevelControl:LevelManager;
public var spawnInitTime:Number;
public var multiplier:int;// = 0
public var spawnDelay:Number;// = 1.25
public function HornetManager():void{
hornets = new Array();
active = new Array();
spawnDelay = 1.25;
spawnInitTime = getTimer();
lastColor = 0;
multiplier = 0;
super();
}
public function init(_arg1:Number, _arg2:LevelManager, _arg3:Frog):void{
var _local4:int;
PlayerFrog = _arg3;
LevelControl = _arg2;
_local4 = 0;
while (_local4 < _arg1) {
hornets[_local4] = new Hornet();
addChild(hornets[_local4]);
hornets[_local4].gotoAndStop(1);
_local4++;
};
}
public function deactivateAllHornets():void{
var _local1:int;
var _local2:int;
_local2 = hornets.length;
_local1 = 0;
while (_local1 < _local2) {
hornets[_local1].deactivate();
hornets[_local1]._spawnState = true;
_local1++;
};
active = new Array();
}
public function getRandomPoint():Point{
var _local1:Point;
var _local2:Boolean;
var _local3:Number;
var _local4:int;
var _local5:int;
_local1 = new Point(0, 0);
_local2 = false;
_local5 = 100;
while (((!(_local2)) && ((_local4 < _local5)))) {
_local1.x = (Math.random() * GameManager.screenWidth);
_local1.y = (Math.random() * GameManager.screenHeight);
_local3 = smallzMath.pDistance(GameManager.centerLoc, _local1);
if (_local3 > 80){
_local2 = true;
};
};
return (_local1);
}
public function spawn():void{
var hornetIndex:int;
var targetLoc:Point;
hornetIndex = inactiveHornet();
targetLoc = getRandomPoint();
if (hornetIndex >= 0){
var _local2 = hornets[hornetIndex];
with (_local2) {
activate();
x = targetLoc.x;
y = targetLoc.y;
_idleChance = LevelControl._hornetIdleChance;
getNewPath(hornets[hornetIndex]);
_speed = ((Math.random() * (LevelControl._hornetMaxSpeed - LevelControl._hornetMinSpeed)) + LevelControl._hornetMinSpeed);
_scale = (((Math.random() * 20) + 45) / 100);
scaleX = _scale;
scaleY = _scale;
active.push(hornets[hornetIndex]);
};
};
}
public function spawnHornets():void{
var _local1:int;
_local1 = 0;
while (_local1 < LevelControl._hornets) {
spawn();
_local1++;
};
}
public function spawnCheck():void{
if (GameManager.elapsedTime(spawnInitTime) > spawnDelay){
spawnInitTime = getTimer();
spawn();
};
}
public function getNewPath(_arg1:Hornet):void{
var targetHornet = _arg1;
var _local3 = targetHornet;
with (_local3) {
_targetLoc = getRandomPoint();
_lastdistance = smallzMath.pDistance(new Point(x, y), _targetLoc);
_facing = smallzMath.pGetAngle(new Point(x, y), _targetLoc);
rotation = (((_facing / Math.PI) * 180) + 90);
};
}
public function checkCollisionTongue(_arg1:ScorePopUpManager):void{
var index:int;
var count:int;
var distance:Number;
var pointDistance:Number;
var tongueAngle:Number;
var earnedPoints:*;
var ScorePopUpControl = _arg1;
count = active.length;
earnedPoints = 50;
if ((((PlayerFrog._state == "TongueOut")) || ((PlayerFrog._state == "TongueRetract")))){
index = 0;
while (index < count) {
var _local3 = active[index];
with (_local3) {
switch (_state){
case "Active":
pointDistance = smallzMath.pDistance(new Point(0, 0), PlayerFrog._tongueLoc);
distance = smallzMath.pDistance(new Point(x, y), new Point((PlayerFrog.x + PlayerFrog._tongueLoc.x), (PlayerFrog.y + PlayerFrog._tongueLoc.y)));
if ((((distance < 15)) && ((pointDistance > 40)))){
_state = "OnTongue";
GameManager._totalHornets++;
};
break;
};
};
index = (index + 1);
};
};
}
public function inactiveHornet():int{
var _local1:int;
var _local2:int;
var _local3:int;
_local2 = -1;
_local3 = hornets.length;
_local1 = 0;
while (_local1 < _local3) {
if (hornets[_local1]._spawnState){
_local2 = _local1;
break;
};
_local1++;
};
return (_local2);
}
public function update(_arg1:Number):void{
var index:int;
var hornetCount:int;
var elapsedTime = _arg1;
hornetCount = active.length;
index = 0;
while (index < hornetCount) {
var _local3 = active[index];
with (_local3) {
if (_state == "Inactive"){
_spawnState = true;
active.splice(index, 1);
index--;
hornetCount--;
} else {
update(elapsedTime);
switch (_state){
case "SetIdle":
_idleDuration = (((Math.random() * (LevelControl._hornetMaxIdle - LevelControl._hornetMinIdle)) + LevelControl._hornetMinIdle) * 0.15);
_state = "Idle";
break;
case "GetNewPath":
getNewPath(active[index]);
_state = "Active";
break;
case "OnTongue":
x = (PlayerFrog.x + PlayerFrog._tongueLoc.x);
y = (PlayerFrog.y + PlayerFrog._tongueLoc.y);
if (PlayerFrog.body.hitTestObject(active[index])){
GameManager.decrementHealth(20);
deactivate();
};
break;
};
};
};
index = (index + 1);
};
}
}
}//package
Section 31
//InstructionsScreen (InstructionsScreen)
package {
import flash.events.*;
import flash.display.*;
public class InstructionsScreen extends MovieClip {
public var _state:String;
public var Continue:MovieClip;
public function InstructionsScreen():void{
x = 0;
y = 0;
_state = "Inactive";
visible = false;
}
public function activate():void{
_state = "Active";
visible = true;
}
public function check_rollovers():void{
if (Continue.hitTestPoint(mouseX, mouseY)){
Continue.scaleX = 1.25;
Continue.scaleY = 1.25;
} else {
Continue.scaleX = 1;
Continue.scaleY = 1;
};
}
public function menu_mouseUp(_arg1:MouseEvent):void{
if (Continue.hitTestPoint(_arg1.stageX, _arg1.stageY)){
deactivate();
GameManager.gameState = "MainMenu";
};
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update():void{
switch (_state){
case "Active":
break;
};
}
}
}//package
Section 32
//LevelManager (LevelManager)
package {
import flash.utils.*;
public class LevelManager {
public var _speedy:Boolean;
public var _hornets:int;
public var _flyMaxIdle:Number;
public var _hornetMinSpeed:Number;
public var _hornetMaxIdle:Number;
public var _flyMaxSpeed:Number;
public var _blueFlies:int;
public var _hornetIdleChance:Number;
public var _redFlies:int;
public var _caption:String;
public var _flyMinSpeed:Number;
public var _currentLevel:int;
public var _greenFlies:int;
public var _flyMinIdle:Number;
public var _duration:Number;
public var _hornetMaxSpeed:Number;
public var _hornetMinIdle:Number;
public var _timerInit:Number;
public var _flyCount:int;
public var _flyIdleChance:Number;
public var _description:String;
public function LevelManager():void{
}
public function startTimer():void{
_timerInit = getTimer();
}
public function nextLevel():void{
_currentLevel++;
}
public function initLevel():void{
switch (_currentLevel){
case 1:
_duration = 20;
_caption = "Level 1\nEasy Street";
_description = "You have 20 seconds to catch all 6 flies.\n\nThese flies are simple to catch!\n\nThe farther away the fly is, the more points you score!";
_blueFlies = 2;
_redFlies = 2;
_greenFlies = 2;
_flyMinSpeed = 50;
_flyMaxSpeed = 75;
_hornetMinSpeed = 50;
_hornetMaxSpeed = 75;
_flyIdleChance = 80;
_flyMinIdle = 1;
_flyMaxIdle = 5;
_hornetIdleChance = 80;
_hornetMinIdle = 1;
_hornetMaxIdle = 5;
_hornets = 0;
_speedy = true;
break;
case 2:
_duration = 20;
_caption = "Level 2\nHornet Time";
_description = "Oy my gosh... \n\nA hornet has buzzed into our pond.\n\nHornets can hurt our frog friend and deplete his health.\n\nIt'd probably be best to avoid slurping them up!";
_blueFlies = 3;
_redFlies = 3;
_greenFlies = 3;
_flyMinSpeed = 50;
_flyMaxSpeed = 75;
_hornetMinSpeed = 50;
_hornetMaxSpeed = 75;
_flyIdleChance = 80;
_flyMinIdle = 1;
_flyMaxIdle = 5;
_hornetIdleChance = 80;
_hornetMinIdle = 1;
_hornetMaxIdle = 5;
_hornets = 1;
_speedy = true;
break;
case 3:
_duration = 30;
_caption = "Level 3\nFaster Flies";
_description = "Now the flies are just a little bit faster. \n\nCatching the same color fly consecutively earns you a multiplier.\n\nMultipliers can earn you better scores!";
_blueFlies = 5;
_redFlies = 5;
_greenFlies = 5;
_flyMinSpeed = 75;
_flyMaxSpeed = 125;
_hornetMinSpeed = 50;
_hornetMaxSpeed = 75;
_flyIdleChance = 80;
_flyMinIdle = 1;
_flyMaxIdle = 4;
_hornetIdleChance = 80;
_hornetMinIdle = 1;
_hornetMaxIdle = 5;
_hornets = 2;
_speedy = true;
break;
case 4:
_duration = 30;
_caption = "Level 4\nTime Limit";
_description = "Now there are 18 flies for you to catch.\n\nYou only have 30 seconds, so lets see if you can eat them all before time expires!";
_blueFlies = 6;
_redFlies = 6;
_greenFlies = 6;
_flyMinSpeed = 75;
_flyMaxSpeed = 125;
_hornetMinSpeed = 50;
_hornetMaxSpeed = 75;
_flyIdleChance = 80;
_flyMinIdle = 1;
_flyMaxIdle = 4;
_hornetIdleChance = 80;
_hornetMinIdle = 1;
_hornetMaxIdle = 5;
_hornets = 2;
_speedy = true;
break;
case 5:
_duration = 45;
_caption = "Level 5\nMore Hornets!";
_description = "Ok, lets toss 2 more hornets into the mix.\n\nBe careful not to catch a hornet!";
_blueFlies = 7;
_redFlies = 7;
_greenFlies = 7;
_flyMinSpeed = 75;
_flyMaxSpeed = 125;
_hornetMinSpeed = 50;
_hornetMaxSpeed = 75;
_flyIdleChance = 80;
_flyMinIdle = 1;
_flyMaxIdle = 3;
_hornetIdleChance = 80;
_hornetMinIdle = 1;
_hornetMaxIdle = 5;
_hornets = 4;
_speedy = true;
break;
case 6:
_duration = 45;
_caption = "Level 6\nSpeedy!";
_description = "Have you seen Speedy ?\n\nSpeedy is a black fly, who speeds by every so often!\n\nIf you catch him, you get 25,000 points!";
_blueFlies = 8;
_redFlies = 8;
_greenFlies = 8;
_flyMinSpeed = 75;
_flyMaxSpeed = 150;
_hornetMinSpeed = 50;
_hornetMaxSpeed = 75;
_flyIdleChance = 80;
_flyMinIdle = 1;
_flyMaxIdle = 3;
_hornetIdleChance = 80;
_hornetMinIdle = 1;
_hornetMaxIdle = 5;
_hornets = 5;
_speedy = true;
break;
case 7:
_duration = 45;
_caption = "Level 7\nNeed Health ?";
_description = "Now there are 8 hornets!\n\nDid you know that green flies give you health!";
_blueFlies = 8;
_redFlies = 8;
_greenFlies = 8;
_flyMinSpeed = 75;
_flyMaxSpeed = 150;
_hornetMinSpeed = 50;
_hornetMaxSpeed = 75;
_flyIdleChance = 80;
_flyMinIdle = 1;
_flyMaxIdle = 2;
_hornetIdleChance = 80;
_hornetMinIdle = 1;
_hornetMaxIdle = 5;
_hornets = 8;
_speedy = true;
break;
case 8:
_duration = 60;
_caption = "Level 8\nYou know how we do...";
_description = "You can't expect me to come up with something new to say every level!\n\nJust focus on not dying ok ?";
_blueFlies = 8;
_redFlies = 8;
_greenFlies = 8;
_flyMinSpeed = 75;
_flyMaxSpeed = 175;
_hornetMinSpeed = 50;
_hornetMaxSpeed = 75;
_flyIdleChance = 80;
_flyMinIdle = 1;
_flyMaxIdle = 2;
_hornetIdleChance = 80;
_hornetMinIdle = 1;
_hornetMaxIdle = 5;
_hornets = 8;
_speedy = true;
break;
case 9:
_duration = 60;
_caption = "Level 9\nDid you know ?";
_description = "It's been said that speedy comes about every 16 seconds.\n\nThat might help you catch him!\n\n He's worth 25,0000 points for heavens sake!";
_blueFlies = 9;
_redFlies = 9;
_greenFlies = 9;
_flyMinSpeed = 75;
_flyMaxSpeed = 175;
_hornetMinSpeed = 50;
_hornetMaxSpeed = 75;
_flyIdleChance = 80;
_flyMinIdle = 1;
_flyMaxIdle = 2;
_hornetIdleChance = 80;
_hornetMinIdle = 1;
_hornetMaxIdle = 5;
_hornets = 9;
_speedy = true;
break;
case 10:
_duration = 60;
_caption = "Level 10\nHave you ever ate a bug ?";
_description = "They don't really taste that good, unless you are a frog!";
_blueFlies = 10;
_redFlies = 10;
_greenFlies = 10;
_flyMinSpeed = 75;
_flyMaxSpeed = 175;
_hornetMinSpeed = 50;
_hornetMaxSpeed = 75;
_flyIdleChance = 80;
_flyMinIdle = 1;
_flyMaxIdle = 2;
_hornetIdleChance = 80;
_hornetMinIdle = 1;
_hornetMaxIdle = 3;
_hornets = 9;
_speedy = true;
break;
default:
_caption = (("Level " + _currentLevel) + "\nThis level is harder!");
_description = "How much longer can you keep this up ?";
_blueFlies = (10 + (_currentLevel - 10));
_redFlies = (10 + (_currentLevel - 10));
_greenFlies = (10 + (_currentLevel - 10));
_duration = (int((((_redFlies + _blueFlies) + _greenFlies) / 9)) * 20);
_flyMinSpeed = 75;
_flyMaxSpeed = (200 + ((_currentLevel - 10) * 5));
_hornetMinSpeed = 50;
_hornetMaxSpeed = (75 + ((_currentLevel - 10) * 5));
_flyIdleChance = 50;
_flyMinIdle = 1;
_flyMaxIdle = 2;
_hornetIdleChance = 50;
_hornetMinIdle = 1;
_hornetMaxIdle = 2;
_hornets = (9 + (_currentLevel - 10));
_speedy = true;
break;
};
}
public function timerValue():Number{
var _local1:Number;
_local1 = GameManager.elapsedTime(_timerInit);
return (_local1);
}
}
}//package
Section 33
//LoadBarSymbol (LoadBarSymbol)
package {
import flash.display.*;
public dynamic class LoadBarSymbol extends MovieClip {
public var load_bar:MovieClip;
}
}//package
Section 34
//MainMenuScreen (MainMenuScreen)
package {
import flash.events.*;
import flash.display.*;
import flash.text.*;
import flash.net.*;
public class MainMenuScreen extends MovieClip {
public var _smallzScale:Number;
public var PlayGame:MovieClip;
public var HighScores:MovieClip;
public var _state:String;
public var Credits:MovieClip;
public var nonoba_text:TextField;
public var Instructions:MovieClip;
public var LeaderBoards:MovieClip;
public var Smallzworld:MovieClip;
public function MainMenuScreen():void{
x = 0;
y = 0;
_state = "Inactive";
visible = false;
_smallzScale = Smallzworld.scaleX;
}
public function activate():void{
_state = "Active";
visible = true;
}
public function check_rollovers():void{
if (PlayGame.hitTestPoint(mouseX, mouseY)){
PlayGame.scaleX = 1.25;
PlayGame.scaleY = 1.25;
} else {
PlayGame.scaleX = 1;
PlayGame.scaleY = 1;
};
if (Instructions.hitTestPoint(mouseX, mouseY)){
Instructions.scaleX = 1.25;
Instructions.scaleY = 1.25;
} else {
Instructions.scaleX = 1;
Instructions.scaleY = 1;
};
if (Credits.hitTestPoint(mouseX, mouseY)){
Credits.scaleX = 1.25;
Credits.scaleY = 1.25;
} else {
Credits.scaleX = 1;
Credits.scaleY = 1;
};
if (HighScores.hitTestPoint(mouseX, mouseY)){
HighScores.scaleX = 1.25;
HighScores.scaleY = 1.25;
} else {
HighScores.scaleX = 1;
HighScores.scaleY = 1;
};
if (Smallzworld.hitTestPoint(mouseX, mouseY)){
Smallzworld.scaleX = (_smallzScale + 0.05);
Smallzworld.scaleY = (_smallzScale + 0.05);
} else {
Smallzworld.scaleX = _smallzScale;
Smallzworld.scaleY = _smallzScale;
};
if (LeaderBoards.hitTestPoint(mouseX, mouseY)){
LeaderBoards.scaleX = 1.25;
LeaderBoards.scaleY = 1.25;
} else {
LeaderBoards.scaleX = 1;
LeaderBoards.scaleY = 1;
};
}
public function menu_mouseUp(_arg1:MouseEvent){
var _local2:URLRequest;
var _local3:URLRequest;
if (PlayGame.hitTestPoint(_arg1.stageX, _arg1.stageY)){
deactivate();
GameManager.gameState = "Reset";
};
if (Instructions.hitTestPoint(_arg1.stageX, _arg1.stageY)){
deactivate();
GameManager.gameState = "Instructions";
};
if (Credits.hitTestPoint(_arg1.stageX, _arg1.stageY)){
deactivate();
GameManager.gameState = "Credits";
};
if (((HighScores.hitTestPoint(_arg1.stageX, _arg1.stageY)) && (!(GameManager.isNonoba)))){
deactivate();
GameManager.gameState = "HighScores";
};
if (((LeaderBoards.hitTestPoint(_arg1.stageX, _arg1.stageY)) && (!(GameManager.isNonoba)))){
_local2 = new URLRequest(("http://games.smallzworld.com/Main.php?PageType=DisplayHighScores&Game_ID=" + GameManager.gameID));
navigateToURL(_local2);
};
if (Smallzworld.hitTestPoint(_arg1.stageX, _arg1.stageY)){
_local3 = new URLRequest("http://games.smallzworld.com/");
navigateToURL(_local3);
};
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update():void{
switch (_state){
case "Active":
break;
};
}
}
}//package
Section 35
//Message (Message)
package {
import flash.events.*;
import flash.display.*;
import flash.text.*;
import flash.net.*;
public class Message extends MovieClip {
public var loader:Loader;
public var _messageText:String;
public var imageIcon:MovieClip;
public var message_text:TextField;
public var _imageLoaded:Boolean;// = false
public var _imageURL:String;
public var _state:String;
public var _linkURL:String;
public function Message():void{
_imageLoaded = false;
loader = new Loader();
super();
_state = "Inactive";
visible = false;
}
public function activate():void{
_state = "Active";
visible = true;
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function display_message(_arg1:Number, _arg2:Number, _arg3:String, _arg4:String):void{
var _local5:URLRequest;
if (imageIcon){
removeChild(imageIcon);
};
imageIcon = new MovieClip();
addChild(imageIcon);
loader = new Loader();
if (_arg4 == ""){
_arg4 = "http://www.smallzworld.com/media/images/avatars/smallz_avatar.jpg";
};
_local5 = new URLRequest((_arg4 + "?hey=1"));
loader.contentLoaderInfo.addEventListener(Event.COMPLETE, iconLoaded);
activate();
message_text.text = _arg3;
x = _arg1;
y = _arg2;
loader.load(_local5);
}
private function iconLoaded(_arg1:Event):void{
var _local2:String;
imageIcon.addChild(loader.content);
imageIcon.x = 50;
imageIcon.y = 40;
_local2 = _imageURL.substr((_imageURL.length - 3), 3);
if (_local2 != "swf"){
imageIcon.width = 60;
imageIcon.height = 60;
};
}
}
}//package
Section 36
//MessageManager (MessageManager)
package {
import flash.events.*;
import flash.net.*;
public class MessageManager {
public var _messageLoaded;// = false
public var messagePod:Message;
public function MessageManager():void{
_messageLoaded = false;
super();
messagePod = new Message();
}
private function message_handler(_arg1:Event):void{
var _local2:URLLoader;
var _local3:int;
_local2 = URLLoader(_arg1.target);
if (_local2.data.MessageText){
messagePod._messageText = _local2.data.MessageText;
messagePod._linkURL = _local2.data.LinkURL;
messagePod._imageURL = _local2.data.ImageURL;
};
_messageLoaded = true;
}
public function load_message(_arg1:int):void{
var _local2:URLRequest;
var _local3:URLVariables;
var _local4:URLLoader;
_local2 = new URLRequest("http://games.smallzworld.com/RecordManagement.php");
_local3 = new URLVariables();
_local3.Routine = "AS3Message";
_local3.Game_ID = _arg1;
_local2.data = _local3;
_local4 = new URLLoader();
_local4.dataFormat = URLLoaderDataFormat.VARIABLES;
_local4.addEventListener(Event.COMPLETE, message_handler);
_local4.load(_local2);
GameManager.gameState = "MainMenu";
_messageLoaded = false;
}
public function display_message(_arg1:Number, _arg2:Number){
messagePod.display_message(_arg1, _arg2, messagePod._messageText, messagePod._imageURL);
_messageLoaded = false;
}
}
}//package
Section 37
//MochiAd (MochiAd)
package {
import flash.events.*;
import flash.display.*;
import flash.utils.*;
import flash.net.*;
import flash.system.*;
public class MochiAd {
public static function getVersion():String{
return ("2.5");
}
public static function showClickAwayAd(_arg1:Object):void{
var DEFAULTS:Object;
var clip:Object;
var ad_timeout:Number;
var mc:MovieClip;
var wh:Array;
var w:Number;
var h:Number;
var chk:MovieClip;
var sendHostProgress:Boolean;
var options = _arg1;
DEFAULTS = {ad_timeout:2000, regpt:"o", method:"showClickAwayAd", res:"300x250", no_bg:true, ad_started:function ():void{
}, ad_finished:function ():void{
}, ad_loaded:function (_arg1:Number, _arg2:Number):void{
}, ad_failed:function ():void{
}, ad_skipped:function ():void{
}};
options = MochiAd._parseOptions(options, DEFAULTS);
clip = options.clip;
ad_timeout = options.ad_timeout;
delete options.ad_timeout;
if (!MochiAd.load(options)){
options.ad_failed();
options.ad_finished();
return;
};
options.ad_started();
mc = clip._mochiad;
mc["onUnload"] = function ():void{
MochiAd._cleanup(mc);
options.ad_finished();
};
wh = MochiAd._getRes(options, clip);
w = wh[0];
h = wh[1];
mc.x = (w * 0.5);
mc.y = (h * 0.5);
chk = createEmptyMovieClip(mc, "_mochiad_wait", 3);
chk.ad_timeout = ad_timeout;
chk.started = getTimer();
chk.showing = false;
mc.unloadAd = function ():void{
MochiAd.unload(clip);
};
mc.adLoaded = options.ad_loaded;
mc.adSkipped = options.ad_skipped;
mc.rpc = function (_arg1:Number, _arg2:Object):void{
MochiAd.rpc(clip, _arg1, _arg2);
};
sendHostProgress = false;
mc.regContLC = function (_arg1:String):void{
mc._containerLCName = _arg1;
};
chk["onEnterFrame"] = function ():void{
var _local1:Object;
var _local2:Number;
var _local3:Boolean;
var _local4:Number;
if (!this.parent){
delete this.onEnterFrame;
return;
};
_local1 = this.parent._mochiad_ctr;
_local2 = (getTimer() - this.started);
_local3 = false;
if (!chk.showing){
_local4 = this.parent._mochiad_ctr.contentLoaderInfo.bytesTotal;
if (_local4 > 0){
chk.showing = true;
_local3 = true;
chk.started = getTimer();
} else {
if (_local2 > chk.ad_timeout){
options.ad_failed();
_local3 = true;
};
};
};
if (this.root == null){
_local3 = true;
};
if (_local3){
delete this.onEnterFrame;
};
};
doOnEnterFrame(chk);
}
public static function _isNetworkAvailable():Boolean{
return (!((Security.sandboxType == "localWithFile")));
}
public static function _allowDomains(_arg1:String):String{
var _local2:String;
_local2 = _arg1.split("/")[2].split(":")[0];
Security.allowDomain("*");
Security.allowDomain(_local2);
Security.allowInsecureDomain("*");
Security.allowInsecureDomain(_local2);
return (_local2);
}
public static function unload(_arg1:Object):Boolean{
if (((_arg1.clip) && (_arg1.clip._mochiad))){
_arg1 = _arg1.clip;
};
if (_arg1.origFrameRate != undefined){
_arg1.stage.frameRate = _arg1.origFrameRate;
};
if (!_arg1._mochiad){
return (false);
};
if (_arg1._mochiad._containerLCName != undefined){
_arg1._mochiad.lc.send(_arg1._mochiad._containerLCName, "notify", {id:"unload"});
};
if (_arg1._mochiad.onUnload){
_arg1._mochiad.onUnload();
};
delete _arg1._mochiad_loaded;
delete _arg1._mochiad;
return (true);
}
public static function showInterLevelAd(_arg1:Object):void{
var DEFAULTS:Object;
var clip:Object;
var ad_msec:Number;
var ad_timeout:Number;
var fadeout_time:Number;
var mc:MovieClip;
var wh:Array;
var w:Number;
var h:Number;
var chk:MovieClip;
var options = _arg1;
DEFAULTS = {ad_timeout:2000, fadeout_time:250, regpt:"o", method:"showTimedAd", ad_started:function ():void{
if ((this.clip is MovieClip)){
this.clip.stop();
} else {
throw (new Error("MochiAd.showInterLevelAd requires a clip that is a MovieClip or is an instance of a class that extends MovieClip. If your clip is a Sprite, then you must provide custom ad_started and ad_finished handlers."));
};
}, ad_finished:function ():void{
if ((this.clip is MovieClip)){
this.clip.play();
} else {
throw (new Error("MochiAd.showInterLevelAd requires a clip that is a MovieClip or is an instance of a class that extends MovieClip. If your clip is a Sprite, then you must provide custom ad_started and ad_finished handlers."));
};
}, ad_loaded:function (_arg1:Number, _arg2:Number):void{
}, ad_failed:function ():void{
}, ad_skipped:function ():void{
}};
options = MochiAd._parseOptions(options, DEFAULTS);
clip = options.clip;
ad_msec = 11000;
ad_timeout = options.ad_timeout;
delete options.ad_timeout;
fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!MochiAd.load(options)){
options.ad_failed();
options.ad_finished();
return;
};
options.ad_started();
mc = clip._mochiad;
mc["onUnload"] = function ():void{
MochiAd._cleanup(mc);
options.ad_finished();
};
wh = MochiAd._getRes(options, clip);
w = wh[0];
h = wh[1];
mc.x = (w * 0.5);
mc.y = (h * 0.5);
chk = createEmptyMovieClip(mc, "_mochiad_wait", 3);
chk.ad_msec = ad_msec;
chk.ad_timeout = ad_timeout;
chk.started = getTimer();
chk.showing = false;
chk.fadeout_time = fadeout_time;
chk.fadeFunction = function ():void{
var _local1:Number;
if (!this.parent){
delete this.onEnterFrame;
delete this.fadeFunction;
return;
};
_local1 = (100 * (1 - ((getTimer() - this.fadeout_start) / this.fadeout_time)));
if (_local1 > 0){
this.parent.alpha = (_local1 * 0.01);
} else {
MochiAd.unload(clip);
delete this["onEnterFrame"];
};
};
mc.unloadAd = function ():void{
MochiAd.unload(clip);
};
mc.adLoaded = options.ad_loaded;
mc.adSkipped = options.ad_skipped;
mc.adjustProgress = function (_arg1:Number):void{
var _local2:Object;
_local2 = mc._mochiad_wait;
_local2.server_control = true;
_local2.showing = true;
_local2.started = getTimer();
_local2.ad_msec = (_arg1 - 250);
};
mc.rpc = function (_arg1:Number, _arg2:Object):void{
MochiAd.rpc(clip, _arg1, _arg2);
};
chk["onEnterFrame"] = function ():void{
var _local1:Object;
var _local2:Number;
var _local3:Boolean;
var _local4:Number;
if (!this.parent){
delete this.onEnterFrame;
delete this.fadeFunction;
return;
};
_local1 = this.parent._mochiad_ctr;
_local2 = (getTimer() - this.started);
_local3 = false;
if (!chk.showing){
_local4 = this.parent._mochiad_ctr.contentLoaderInfo.bytesTotal;
if (_local4 > 0){
chk.showing = true;
chk.started = getTimer();
MochiAd.adShowing(clip);
} else {
if (_local2 > chk.ad_timeout){
options.ad_failed();
_local3 = true;
};
};
};
if (_local2 > chk.ad_msec){
_local3 = true;
};
if (_local3){
if (this.server_control){
delete this.onEnterFrame;
} else {
this.fadeout_start = getTimer();
this.onEnterFrame = this.fadeFunction;
};
};
};
doOnEnterFrame(chk);
}
public static function _parseOptions(_arg1:Object, _arg2:Object):Object{
var _local3:Object;
var _local4:String;
var _local5:Array;
var _local6:Number;
var _local7:Array;
_local3 = {};
for (_local4 in _arg2) {
_local3[_local4] = _arg2[_local4];
};
if (_arg1){
for (_local4 in _arg1) {
_local3[_local4] = _arg1[_local4];
};
};
if (_local3.clip == undefined){
throw (new Error("MochiAd is missing the 'clip' parameter. This should be a MovieClip, Sprite or an instance of a class that extends MovieClip or Sprite."));
};
_arg1 = _local3.clip.loaderInfo.parameters.mochiad_options;
if (_arg1){
_local5 = _arg1.split("&");
_local6 = 0;
while (_local6 < _local5.length) {
_local7 = _local5[_local6].split("=");
_local3[unescape(_local7[0])] = unescape(_local7[1]);
_local6++;
};
};
if (_local3.id == "test"){
};
return (_local3);
}
public static function _cleanup(_arg1:Object):void{
var idx:Number;
var k:String;
var lc:LocalConnection;
var f:Function;
var mc = _arg1;
if (("lc" in mc)){
lc = mc.lc;
f = function ():void{
try {
lc.client = null;
lc.close();
} catch(e:Error) {
};
};
setTimeout(f, 0);
};
idx = DisplayObjectContainer(mc).numChildren;
while (idx > 0) {
idx = (idx - 1);
DisplayObjectContainer(mc).removeChildAt(idx);
};
for (k in mc) {
delete mc[k];
};
}
public static function load(_arg1:Object):MovieClip{
var DEFAULTS:Object;
var clip:Object;
var depth:Number;
var mc:MovieClip;
var wh:Array;
var lv:URLVariables;
var k:String;
var server:String;
var hostname:String;
var lc:LocalConnection;
var name:String;
var loader:Loader;
var g:Function;
var req:URLRequest;
var v:Object;
var options = _arg1;
DEFAULTS = {server:"http://x.mochiads.com/srv/1/", method:"load", depth:10333, id:"_UNKNOWN_"};
options = MochiAd._parseOptions(options, DEFAULTS);
options.swfv = 9;
options.mav = MochiAd.getVersion();
clip = options.clip;
if (!MochiAd._isNetworkAvailable()){
return (null);
};
try {
if (clip._mochiad_loaded){
return (null);
};
} catch(e:Error) {
throw (new Error("MochiAd requires a clip that is an instance of a dynamic class. If your class extends Sprite or MovieClip, you must make it dynamic."));
};
depth = options.depth;
delete options.depth;
mc = createEmptyMovieClip(clip, "_mochiad", depth);
wh = MochiAd._getRes(options, clip);
options.res = ((wh[0] + "x") + wh[1]);
options.server = (options.server + options.id);
delete options.id;
clip._mochiad_loaded = true;
if (clip.loaderInfo.loaderURL.indexOf("http") == 0){
options.as3_swf = clip.loaderInfo.loaderURL;
};
lv = new URLVariables();
for (k in options) {
v = options[k];
if (!(v is Function)){
lv[k] = v;
};
};
server = lv.server;
delete lv.server;
hostname = _allowDomains(server);
lc = new LocalConnection();
lc.client = mc;
name = ["", Math.floor(new Date().getTime()), Math.floor((Math.random() * 999999))].join("_");
lc.allowDomain("*", "localhost");
lc.allowInsecureDomain("*", "localhost");
lc.connect(name);
mc.lc = lc;
mc.lcName = name;
lv.lc = name;
lv.st = getTimer();
loader = new Loader();
g = function (_arg1:Object):void{
_arg1.target.removeEventListener(_arg1.type, arguments.callee);
MochiAd.unload(clip);
};
loader.contentLoaderInfo.addEventListener(Event.UNLOAD, g);
req = new URLRequest((server + ".swf"));
req.contentType = "application/x-www-form-urlencoded";
req.method = URLRequestMethod.POST;
req.data = lv;
loader.load(req);
mc.addChild(loader);
mc._mochiad_ctr = loader;
return (mc);
}
public static function runMethod(_arg1:Object, _arg2:String, _arg3:Array):Object{
var _local4:Array;
var _local5:Number;
_local4 = _arg2.split(".");
_local5 = 0;
while (_local5 < (_local4.length - 1)) {
if ((((_arg1[_local4[_local5]] == undefined)) || ((_arg1[_local4[_local5]] == null)))){
return (undefined);
};
_arg1 = _arg1[_local4[_local5]];
_local5++;
};
if (typeof(_arg1[_local4[_local5]]) == "function"){
return (_arg1[_local4[_local5]].apply(_arg1, _arg3));
};
return (undefined);
}
public static function createEmptyMovieClip(_arg1:Object, _arg2:String, _arg3:Number):MovieClip{
var _local4:MovieClip;
_local4 = new MovieClip();
if (((false) && (_arg3))){
_arg1.addChildAt(_local4, _arg3);
} else {
_arg1.addChild(_local4);
};
_arg1[_arg2] = _local4;
_local4["_name"] = _arg2;
return (_local4);
}
public static function _getRes(_arg1:Object, _arg2:Object):Array{
var _local3:Object;
var _local4:Number;
var _local5:Number;
var _local6:Array;
_local3 = _arg2.getBounds(_arg2.root);
_local4 = 0;
_local5 = 0;
if (typeof(_arg1.res) != "undefined"){
_local6 = _arg1.res.split("x");
_local4 = parseFloat(_local6[0]);
_local5 = parseFloat(_local6[1]);
} else {
_local4 = (_local3.xMax - _local3.xMin);
_local5 = (_local3.yMax - _local3.yMin);
};
if ((((_local4 == 0)) || ((_local5 == 0)))){
_local4 = _arg2.stage.stageWidth;
_local5 = _arg2.stage.stageHeight;
};
return ([_local4, _local5]);
}
public static function adShowing(_arg1:Object):void{
_arg1.origFrameRate = _arg1.stage.frameRate;
_arg1.stage.frameRate = 30;
}
public static function getValue(_arg1:Object, _arg2:String):Object{
var _local3:Array;
var _local4:Number;
_local3 = _arg2.split(".");
_local4 = 0;
while (_local4 < (_local3.length - 1)) {
if ((((_arg1[_local3[_local4]] == undefined)) || ((_arg1[_local3[_local4]] == null)))){
return (undefined);
};
_arg1 = _arg1[_local3[_local4]];
_local4++;
};
return (_arg1[_local3[_local4]]);
}
public static function rpc(_arg1:Object, _arg2:Number, _arg3:Object):void{
var _local4:Object;
var _local5:Object;
switch (_arg3.id){
case "setValue":
MochiAd.setValue(_arg1, _arg3.objectName, _arg3.value);
break;
case "getValue":
_local4 = MochiAd.getValue(_arg1, _arg3.objectName);
_arg1._mochiad.lc.send(_arg1._mochiad._containerLCName, "rpcResult", _arg2, _local4);
break;
case "runMethod":
_local5 = MochiAd.runMethod(_arg1, _arg3.method, _arg3.args);
_arg1._mochiad.lc.send(_arg1._mochiad._containerLCName, "rpcResult", _arg2, _local5);
break;
};
}
public static function setValue(_arg1:Object, _arg2:String, _arg3:Object):void{
var _local4:Array;
var _local5:Number;
_local4 = _arg2.split(".");
_local5 = 0;
while (_local5 < (_local4.length - 1)) {
if ((((_arg1[_local4[_local5]] == undefined)) || ((_arg1[_local4[_local5]] == null)))){
return;
};
_arg1 = _arg1[_local4[_local5]];
_local5++;
};
_arg1[_local4[_local5]] = _arg3;
}
public static function showPreGameAd(_arg1:Object):void{
var DEFAULTS:Object;
var clip:Object;
var ad_msec:Number;
var ad_timeout:Number;
var fadeout_time:Number;
var mc:MovieClip;
var wh:Array;
var w:Number;
var h:Number;
var chk:MovieClip;
var bar:MovieClip;
var bar_color:Number;
var bar_background:Number;
var bar_outline:Number;
var backing_mc:MovieClip;
var backing:Object;
var inside_mc:MovieClip;
var inside:Object;
var outline_mc:MovieClip;
var outline:Object;
var complete:Boolean;
var unloaded:Boolean;
var f:Function;
var sendHostProgress:Boolean;
var r:MovieClip;
var options = _arg1;
DEFAULTS = {ad_timeout:3000, fadeout_time:250, regpt:"o", method:"showPreloaderAd", color:0xFF8A00, background:16777161, outline:13994812, no_progress_bar:false, ad_started:function ():void{
if ((this.clip is MovieClip)){
this.clip.stop();
} else {
throw (new Error("MochiAd.showPreGameAd requires a clip that is a MovieClip or is an instance of a class that extends MovieClip. If your clip is a Sprite, then you must provide custom ad_started and ad_finished handlers."));
};
}, ad_finished:function ():void{
if ((this.clip is MovieClip)){
this.clip.play();
} else {
throw (new Error("MochiAd.showPreGameAd requires a clip that is a MovieClip or is an instance of a class that extends MovieClip. If your clip is a Sprite, then you must provide custom ad_started and ad_finished handlers."));
};
}, ad_loaded:function (_arg1:Number, _arg2:Number):void{
}, ad_failed:function ():void{
}, ad_skipped:function ():void{
}, ad_progress:function (_arg1:Number):void{
}};
options = MochiAd._parseOptions(options, DEFAULTS);
if ("c862232051e0a94e1c3609b3916ddb17".substr(0) == "dfeada81ac97cde83665f81c12da7def"){
options.ad_started();
setTimeout(options.ad_finished, 100);
return;
};
clip = options.clip;
ad_msec = 11000;
ad_timeout = options.ad_timeout;
delete options.ad_timeout;
fadeout_time = options.fadeout_time;
delete options.fadeout_time;
if (!MochiAd.load(options)){
options.ad_failed();
options.ad_finished();
return;
};
options.ad_started();
mc = clip._mochiad;
mc["onUnload"] = function ():void{
var fn:Function;
MochiAd._cleanup(mc);
fn = function ():void{
options.ad_finished();
};
setTimeout(fn, 100);
};
wh = MochiAd._getRes(options, clip);
w = wh[0];
h = wh[1];
mc.x = (w * 0.5);
mc.y = (h * 0.5);
chk = createEmptyMovieClip(mc, "_mochiad_wait", 3);
chk.x = (w * -0.5);
chk.y = (h * -0.5);
bar = createEmptyMovieClip(chk, "_mochiad_bar", 4);
if (options.no_progress_bar){
bar.visible = false;
delete options.no_progress_bar;
} else {
bar.x = 10;
bar.y = (h - 20);
};
bar_color = options.color;
delete options.color;
bar_background = options.background;
delete options.background;
bar_outline = options.outline;
delete options.outline;
backing_mc = createEmptyMovieClip(bar, "_outline", 1);
backing = backing_mc.graphics;
backing.beginFill(bar_background);
backing.moveTo(0, 0);
backing.lineTo((w - 20), 0);
backing.lineTo((w - 20), 10);
backing.lineTo(0, 10);
backing.lineTo(0, 0);
backing.endFill();
inside_mc = createEmptyMovieClip(bar, "_inside", 2);
inside = inside_mc.graphics;
inside.beginFill(bar_color);
inside.moveTo(0, 0);
inside.lineTo((w - 20), 0);
inside.lineTo((w - 20), 10);
inside.lineTo(0, 10);
inside.lineTo(0, 0);
inside.endFill();
inside_mc.scaleX = 0;
outline_mc = createEmptyMovieClip(bar, "_outline", 3);
outline = outline_mc.graphics;
outline.lineStyle(0, bar_outline, 100);
outline.moveTo(0, 0);
outline.lineTo((w - 20), 0);
outline.lineTo((w - 20), 10);
outline.lineTo(0, 10);
outline.lineTo(0, 0);
chk.ad_msec = ad_msec;
chk.ad_timeout = ad_timeout;
chk.started = getTimer();
chk.showing = false;
chk.last_pcnt = 0;
chk.fadeout_time = fadeout_time;
chk.fadeFunction = function ():void{
var _local1:Number;
_local1 = (100 * (1 - ((getTimer() - this.fadeout_start) / this.fadeout_time)));
if (_local1 > 0){
this.parent.alpha = (_local1 * 0.01);
} else {
MochiAd.unload(clip);
delete this["onEnterFrame"];
};
};
complete = false;
unloaded = false;
f = function (_arg1:Event):void{
_arg1.target.removeEventListener(_arg1.type, arguments.callee);
complete = true;
if (unloaded){
MochiAd.unload(clip);
};
};
clip.loaderInfo.addEventListener(Event.COMPLETE, f);
if ((clip.root is MovieClip)){
r = (clip.root as MovieClip);
if (r.framesLoaded >= r.totalFrames){
complete = true;
};
};
mc.unloadAd = function ():void{
unloaded = true;
if (complete){
MochiAd.unload(clip);
};
};
mc.adLoaded = options.ad_loaded;
mc.adSkipped = options.ad_skipped;
mc.adjustProgress = function (_arg1:Number):void{
var _local2:Object;
_local2 = mc._mochiad_wait;
_local2.server_control = true;
_local2.showing = true;
_local2.started = getTimer();
_local2.ad_msec = _arg1;
};
mc.rpc = function (_arg1:Number, _arg2:Object):void{
MochiAd.rpc(clip, _arg1, _arg2);
};
mc.rpcTestFn = function (_arg1:String):Object{
return (_arg1);
};
mc.regContLC = function (_arg1:String):void{
mc._containerLCName = _arg1;
};
sendHostProgress = false;
mc.sendHostLoadProgress = function (_arg1:String):void{
sendHostProgress = true;
};
chk["onEnterFrame"] = function ():void{
var _local1:Object;
var _local2:Object;
var _local3:Number;
var _local4:Boolean;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:Number;
var _local9:Object;
var _local10:Number;
var _local11:Number;
if (((!(this.parent)) || (!(this.parent.parent)))){
delete this["onEnterFrame"];
return;
};
_local1 = this.parent.parent.root;
_local2 = this.parent._mochiad_ctr;
_local3 = (getTimer() - this.started);
_local4 = false;
_local5 = _local1.loaderInfo.bytesTotal;
_local6 = _local1.loaderInfo.bytesLoaded;
if (complete){
_local6 = Math.max(1, _local6);
_local5 = _local6;
};
_local7 = ((100 * _local6) / _local5);
_local8 = ((100 * _local3) / chk.ad_msec);
_local9 = this._mochiad_bar._inside;
_local10 = Math.min(100, Math.min(((_local7) || (0)), _local8));
_local10 = Math.max(this.last_pcnt, _local10);
this.last_pcnt = _local10;
_local9.scaleX = (_local10 * 0.01);
options.ad_progress(_local10);
if (sendHostProgress){
clip._mochiad.lc.send(clip._mochiad._containerLCName, "notify", {id:"hostLoadPcnt", pcnt:_local7});
if (_local7 == 100){
sendHostProgress = false;
};
};
if (!chk.showing){
_local11 = this.parent._mochiad_ctr.contentLoaderInfo.bytesTotal;
if (_local11 > 0){
chk.showing = true;
chk.started = getTimer();
MochiAd.adShowing(clip);
} else {
if ((((_local3 > chk.ad_timeout)) && ((_local7 == 100)))){
options.ad_failed();
_local4 = true;
};
};
};
if (_local3 > chk.ad_msec){
_local4 = true;
};
if (((complete) && (_local4))){
if (this.server_control){
delete this.onEnterFrame;
} else {
this.fadeout_start = getTimer();
this.onEnterFrame = chk.fadeFunction;
};
};
};
doOnEnterFrame(chk);
}
public static function showPreloaderAd(_arg1:Object):void{
MochiAd.showPreGameAd(_arg1);
}
public static function showTimedAd(_arg1:Object):void{
MochiAd.showInterLevelAd(_arg1);
}
public static function doOnEnterFrame(_arg1:MovieClip):void{
var f:Function;
var mc = _arg1;
f = function (_arg1:Object):void{
if (((("onEnterFrame" in mc)) && (mc.onEnterFrame))){
mc.onEnterFrame();
} else {
_arg1.target.removeEventListener(_arg1.type, arguments.callee);
};
};
mc.addEventListener(Event.ENTER_FRAME, f);
}
}
}//package
Section 38
//MyArial (MyArial)
package {
import flash.text.*;
public dynamic class MyArial extends Font {
}
}//package
Section 39
//NonobaAPI (NonobaAPI)
package {
import flash.events.*;
import flash.display.*;
import flash.net.*;
import flash.system.*;
public class NonobaAPI {
public static const SUCCESS:String = "success";
public static const ERROR:String = "error";
public static const NOT_LOGGED_IN:String = "user not logged in";
private static var isInited:Boolean = false;
private static var cachedRequests:Array = [];
private static var api:Object;
private static var loading:Boolean = false;
private static var failed:Boolean = false;
public function NonobaAPI(){
throw (new Error("You cannot create an instance of the NonobaAPI class!"));
}
public static function SubmitScore(_arg1:Stage, _arg2:String, _arg3:Number, _arg4:Function=null){
var stage = _arg1;
var key = _arg2;
var score = _arg3;
var callback = _arg4;
if (!isInited){
init(stage);
};
if (failed){
if (callback != null){
callback(ERROR);
};
return;
};
if (((api.content) && (api.content.SubmitScore))){
api.content.SubmitScore(stage, key, score, callback);
} else {
cachedRequests.push(function (){
SubmitScore(stage, key, score, callback);
});
};
}
private static function handleLoadCompleate(_arg1:Event){
emptyQueue();
}
private static function emptyQueue(){
var _local1:int;
_local1 = 0;
while (_local1 < cachedRequests.length) {
var _local2 = cachedRequests;
_local2[_local1]();
_local1++;
};
cachedRequests = [];
}
private static function init(_arg1:Stage){
var _local2:Object;
var _local3:URLRequest;
isInited = true;
_local2 = LoaderInfo(_arg1.root.loaderInfo).parameters;
if (!_local2.nonoba$apicodeas3){
enterErrorState();
return;
};
Security.allowDomain("*");
Security.allowInsecureDomain("*");
api = new Loader();
_local3 = new URLRequest(_local2.nonoba$apicodeas3);
api.contentLoaderInfo.addEventListener(Event.COMPLETE, handleLoadCompleate);
api.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, enterErrorState);
api.load(_local3);
}
private static function enterErrorState(_arg1:Event=null){
failed = true;
emptyQueue();
}
public static function GetUserData(_arg1:Stage, _arg2:String, _arg3:Function=null){
var stage = _arg1;
var key = _arg2;
var callback = _arg3;
if (!isInited){
init(stage);
};
if (failed){
if (callback != null){
callback(ERROR);
};
return;
};
if (((api.content) && (api.content.GetUserData))){
api.content.GetUserData(stage, key, callback);
} else {
cachedRequests.push(function (){
GetUserData(stage, key, callback);
});
};
}
public static function AwardAchievement(_arg1:Stage, _arg2:String, _arg3:Function=null){
var stage = _arg1;
var key = _arg2;
var callback = _arg3;
if (!isInited){
init(stage);
};
if (failed){
if (callback != null){
callback(ERROR, 0);
};
return;
};
if (((api.content) && (api.content.AwardAchievement))){
api.content.AwardAchievement(stage, key, callback);
} else {
cachedRequests.push(function (){
AwardAchievement(stage, key, callback);
});
};
}
public static function GetUsername(_arg1:Stage, _arg2:Function=null){
var stage = _arg1;
var callback = _arg2;
if (!isInited){
init(stage);
};
if (failed){
if (callback != null){
callback(ERROR, "");
};
return;
};
if (((api.content) && (api.content.GetUsername))){
api.content.GetUsername(stage, callback);
} else {
cachedRequests.push(function (){
GetUsername(stage, callback);
});
};
}
public static function SetUserData(_arg1:Stage, _arg2:String, _arg3:String, _arg4:Function=null){
var stage = _arg1;
var key = _arg2;
var value = _arg3;
var callback = _arg4;
if (!isInited){
init(stage);
};
if (failed){
if (callback != null){
callback(ERROR);
};
return;
};
if (((api.content) && (api.content.SetUserData))){
api.content.SetUserData(stage, key, value, callback);
} else {
cachedRequests.push(function (){
SetUserData(stage, key, value, callback);
});
};
}
}
}//package
Section 40
//NonobaDebugBox (NonobaDebugBox)
package {
import flash.display.*;
import flash.text.*;
public dynamic class NonobaDebugBox extends MovieClip {
public var log:TextField;
}
}//package
Section 41
//NonobaManager (NonobaManager)
package {
import flash.display.*;
import flash.utils.*;
public class NonobaManager extends MovieClip {
public var _achievements:Array;
public var _userName:String;// = "Default"
public var AchievementBoxControl:AchievementBoxManager;
public var _state:String;
public var _debugToggleDelay:Number;// = 0.25
public var _debugBox:NonobaDebugBox;
public var _debugToggleInitTime:Number;
public function NonobaManager():void{
_userName = "Default";
_achievements = new Array();
_debugToggleDelay = 0.25;
super();
AchievementBoxControl = new AchievementBoxManager();
addChild(AchievementBoxControl);
AchievementBoxControl.init(15);
if (GameManager._nonobaDebuggerEnabled){
_debugBox = new NonobaDebugBox();
addChild(_debugBox);
_debugToggleInitTime = getTimer();
};
}
public function toggleDebugBox():void{
if (((GameManager.isNonoba) && (GameManager._nonobaDebuggerEnabled))){
if (GameManager.elapsedTime(_debugToggleInitTime) > _debugToggleDelay){
if (_debugBox.visible){
_debugBox.visible = false;
} else {
_debugBox.visible = true;
};
_debugToggleInitTime = getTimer();
};
};
}
public function resetAchievements():void{
var _local1:int;
var _local2:int;
_local2 = _achievements.length;
_local1 = 0;
while (_local1 < _local2) {
_achievements[_local1]._isAchieved = false;
_local1++;
};
}
public function markAchievement(_arg1:String):void{
var _local2:int;
var _local3:int;
_local3 = _achievements.length;
_local2 = 0;
while (_local2 < _local3) {
if (_achievements[_local2]._achievementKey == _arg1){
setAchievement(_arg1);
_achievements[_local2]._isAchieved = true;
spawnAchievementBox((("Congrats, you achieved " + _achievements[_local2]._achievementName) + "!"), 3);
break;
};
_local2++;
};
}
public function getUsername():void{
_userName = "Error Clown Sent";
NonobaAPI.GetUsername(stage, function (_arg1:String, _arg2:String){
switch (_arg1){
case NonobaAPI.SUCCESS:
_userName = _arg2;
break;
case NonobaAPI.NOT_LOGGED_IN:
_arg2 = "Clown";
break;
case NonobaAPI.ERROR:
_arg2 = "Error Clown";
break;
};
_userName = _arg2;
GameManager._userName = _userName;
});
}
public function updateDebugBox():void{
if (((GameManager.isNonoba) && (GameManager._nonobaDebuggerEnabled))){
_debugBox.log.text = (achievementsLogString() + String(((((GameManager._totalBlue + " : ") + GameManager._totalRed) + " : ") + GameManager._totalGreen)));
};
}
public function spawnAchievementBox(_arg1:String, _arg2:Number):void{
AchievementBoxControl.spawn(_arg1, _arg2);
}
public function setAchievement(_arg1:String):void{
var achievementKey = _arg1;
if (GameManager._nonobaSendEnabled){
NonobaAPI.AwardAchievement(this.stage, achievementKey, function (_arg1:String, _arg2:Number){
switch (_arg1){
case NonobaAPI.SUCCESS:
break;
case NonobaAPI.NOT_LOGGED_IN:
break;
case NonobaAPI.ERROR:
break;
};
});
};
}
public function isAchieved(_arg1:String):Boolean{
var _local2:int;
var _local3:int;
var _local4:Boolean;
_local3 = _achievements.length;
_local2 = 0;
while (_local2 < _local3) {
if (_achievements[_local2]._achievementKey == _arg1){
_local4 = _achievements[_local2]._isAchieved;
break;
};
_local2++;
};
return (_local4);
}
public function saveHighscore(_arg1:String, _arg2:Number):void{
var keyName = _arg1;
var playerScore = _arg2;
if (GameManager._nonobaSendEnabled){
NonobaAPI.SubmitScore(this.stage, keyName, playerScore, function (_arg1:String){
switch (_arg1){
case NonobaAPI.SUCCESS:
break;
case NonobaAPI.NOT_LOGGED_IN:
break;
case NonobaAPI.ERROR:
break;
};
});
};
}
public function achievementsLogString():String{
var _local1:String;
var _local2:int;
var _local3:int;
_local1 = "";
_local3 = _achievements.length;
_local2 = 0;
while (_local2 < _local3) {
_local1 = ((((_local1 + _achievements[_local2]._achievementName) + " : ") + String(_achievements[_local2]._isAchieved)) + "\n");
_local2++;
};
return (_local1);
}
public function addAchievement(_arg1:String, _arg2:String, _arg3:int):void{
_achievements[_achievements.length] = new AchievementRecord(_arg1, _arg2, _arg3);
}
}
}//package
Section 42
//Orb (Orb)
package {
import flash.display.*;
public class Orb extends MovieClip {
public var _type:int;
public var _speed:Number;
public var _scale:Number;
public var _spawnState:Boolean;// = true
public var _state:String;
public function Orb():void{
_spawnState = true;
super();
deactivate();
}
public function activate():void{
_state = "Active";
visible = true;
_spawnState = false;
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update(_arg1:Number):void{
switch (_state){
case "Player":
x = stage.mouseX;
y = stage.mouseY;
break;
case "Active":
break;
};
}
}
}//package
Section 43
//Pad (Pad)
package {
import flash.display.*;
public class Pad extends MovieClip {
public var _scale:Number;
public var _state:String;
public function Pad():void{
deactivate();
}
public function activate():void{
_state = "Active";
visible = true;
}
public function position(_arg1:Number, _arg2:Number):void{
x = _arg1;
y = _arg2;
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update(_arg1:Number):void{
switch (_state){
case "Active":
break;
};
}
}
}//package
Section 44
//PauseScreen (PauseScreen)
package {
import flash.events.*;
import flash.display.*;
public class PauseScreen extends MovieClip {
public var _state:String;
public var Continue:MovieClip;
public function PauseScreen():void{
x = 0;
y = 0;
_state = "Inactive";
visible = false;
}
public function activate():void{
_state = "Active";
visible = true;
}
public function menu_mouseUp(_arg1:MouseEvent):void{
if (Continue.hitTestPoint(_arg1.stageX, _arg1.stageY)){
deactivate();
GameManager.gameState = "MainMenu";
};
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update():void{
switch (_state){
case "Active":
break;
};
}
}
}//package
Section 45
//PopUp (PopUp)
package {
import flash.geom.*;
import flash.display.*;
import flash.text.*;
import flash.utils.*;
public class PopUp extends MovieClip {
public var _duration:Number;
public var _isComplete:Boolean;
public var box_text:TextField;
public var _scale:Number;
public var _initTime:Number;
public var _state:String;
public var _defaultCaption:String;// = "You know how we do!"
public var title_text:TextField;
public var _defaultDuration:Number;// = 3
public var _scaleSpeed:Number;// = 250
public var _defalutLoc:Point;
public var _defaultBody:String;// = "This is where you put popup text"
public function PopUp():void{
_scaleSpeed = 250;
_defaultDuration = 3;
_defalutLoc = new Point(0, 0);
_defaultCaption = "You know how we do!";
_defaultBody = "This is where you put popup text";
super();
deactivate();
}
public function startTimer():void{
_initTime = getTimer();
}
public function activate(_arg1, _arg2:String, _arg3:Point, _arg4:Number):void{
x = _arg3.x;
y = _arg3.y;
_state = "Active";
title_text.text = _arg1;
box_text.text = _arg2;
_duration = _arg4;
transitionIn();
_isComplete = false;
visible = true;
}
public function transitionIn():void{
_scale = 0.01;
scaleX = _scale;
scaleY = _scale;
_state = "Grow";
}
public function deactivate():void{
_state = "Inactive";
visible = false;
_isComplete = true;
}
public function transitionOut():void{
_state = "Shrink";
}
public function update(_arg1:Number):void{
switch (_state){
case "Active":
if (isDone()){
transitionOut();
};
break;
case "Grow":
_scale = (_scale + ((_arg1 * _scaleSpeed) / 100));
if (_scale >= 1){
_scale = 1;
startTimer();
_state = "Active";
};
scaleX = _scale;
scaleY = _scale;
break;
case "Shrink":
_scale = (_scale - ((_arg1 * _scaleSpeed) / 100));
if (_scale <= 0.1){
_scale = 1;
deactivate();
};
scaleX = _scale;
scaleY = _scale;
break;
case "Inactive":
break;
};
}
public function isDone():Boolean{
var _local1:Boolean;
_local1 = false;
if (GameManager.elapsedTime(_initTime) >= _duration){
_local1 = true;
};
return (_local1);
}
}
}//package
Section 46
//ScorePopUp (ScorePopUp)
package {
import flash.display.*;
import classes.smallz.*;
import classes.game.*;
public class ScorePopUp extends MovieClip {
public var _speed;// = 35
public var _spawnState:Boolean;// = true
public var _state:String;
public var _scoreValue:String;
public var PointText:MovieClip;
public function ScorePopUp():void{
_speed = 35;
_spawnState = true;
super();
addFrameScript(44, frame45);
deactivate();
}
public function activate():void{
visible = true;
_state = "Active";
_spawnState = false;
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
function frame45(){
this.stop();
}
public function update(_arg1:Number):void{
switch (_state){
case "Active":
y = (y - (_arg1 * _speed));
if (PointText){
if (PointText.PointText){
PointText.PointText.text = _scoreValue;
};
};
if (currentFrame == totalFrames){
deactivate();
};
break;
};
}
}
}//package
Section 47
//ScorePopUpManager (ScorePopUpManager)
package {
import flash.geom.*;
import flash.display.*;
import classes.game.*;
public class ScorePopUpManager extends MovieClip {
public var active:Array;
public var popups:Array;
public var _scale:Number;// = 0.5
public function ScorePopUpManager():void{
popups = new Array();
active = new Array();
_scale = 0.5;
super();
}
public function inactive_popup():int{
var _local1:int;
var _local2:int;
var _local3:int;
_local2 = -1;
_local3 = popups.length;
_local1 = 0;
while (_local1 < _local3) {
if (popups[_local1]._spawnState){
_local2 = _local1;
break;
};
_local1++;
};
return (_local2);
}
public function activate(_arg1:Point, _arg2:String):void{
var popupIndex:int;
var screenLoc = _arg1;
var scoreString = _arg2;
popupIndex = inactive_popup();
if (popupIndex >= 0){
active.push(popups[popupIndex]);
var _local4 = popups[popupIndex];
with (_local4) {
activate();
x = screenLoc.x;
y = screenLoc.y;
scaleX = _scale;
scaleY = _scale;
_scoreValue = scoreString;
gotoAndPlay(1);
};
};
}
public function init(_arg1:int){
var _local2:int;
_local2 = 0;
while (_local2 < _arg1) {
popups[_local2] = new ScorePopUp();
addChild(popups[_local2]);
_local2++;
};
}
public function deactivateAllPopups():void{
var _local1:int;
var _local2:int;
_local2 = popups.length;
_local1 = 0;
while (_local1 < _local2) {
popups[_local1].deactivate();
popups[_local1]._spawnState = true;
_local1++;
};
active = new Array();
}
public function update(_arg1:Number):void{
var index:int;
var popupCount:int;
var elapsedTime = _arg1;
popupCount = active.length;
index = 0;
while (index < popupCount) {
var _local3 = active[index];
with (_local3) {
if (_state == "Inactive"){
_spawnState = true;
active.splice(index, 1);
index--;
popupCount--;
} else {
update(elapsedTime);
};
};
index = (index + 1);
};
}
}
}//package
Section 48
//smallzDebug (smallzDebug)
package {
import flash.text.*;
import flash.filters.*;
public class smallzDebug {
private var _log:Array;
private var _active:Boolean;
public var _window:TextField;
public function smallzDebug(_arg1:Number, _arg2:Number, _arg3:Boolean):void{
var _local4:DropShadowFilter;
var _local5:GlowFilter;
var _local6:TextFormat;
super();
_local4 = new DropShadowFilter(2, 45, 0, 25, 3, 3, 2, 2);
_local5 = new GlowFilter(0, 100, 2, 2, 2000, 1, false, false);
_active = _arg3;
_window = new TextField();
_window.x = _arg1;
_window.y = _arg2;
_window.multiline = true;
_window.wordWrap = true;
_window.width = 640;
_window.height = 480;
_window.selectable = false;
_window.text = "";
_window.filters = [_local5];
_log = new Array();
_local6 = new TextFormat();
_local6.font = "Arial";
_local6.bold = true;
_local6.size = 16;
_local6.color = 0xFFFFFF;
_window.defaultTextFormat = _local6;
}
public function update():void{
var _local1:int;
if (_active){
if (!_window.visible){
_window.visible = true;
};
_window.text = "";
_local1 = 0;
while (_local1 <= (_log.length - 1)) {
_window.appendText(_log[_local1]);
_window.appendText("\n");
_local1++;
};
} else {
if (_window.visible){
_window.visible = false;
};
};
}
public function add_trace(_arg1:String):void{
if (GameManager.Debug){
_log.push(_arg1);
};
}
public function clear_log():void{
var _local1:int;
var _local2:int;
_local2 = _log.length;
_local1 = 0;
while (_local1 < _local2) {
_log.pop();
_local1++;
};
}
public function deactivate():void{
_active = false;
}
public function activate():void{
_active = true;
}
}
}//package
Section 49
//smallzFPS (smallzFPS)
package {
import flash.text.*;
import flash.utils.*;
public class smallzFPS {
private var _frameCount:int;
private var _initTime:Number;
private var _fps:Number;
private var _curTime:Number;
private var _sampleSize:int;
public var _fpsCounter:TextField;
public function smallzFPS(_arg1:Number, _arg2:Number, _arg3:int):void{
var _local4:Font;
var _local5:TextFormat;
super();
_local4 = new MyArial();
_local5 = new TextFormat();
_local5.font = _local4.fontName;
_local5.bold = true;
_local5.size = 14;
_local5.color = 0xFFFFFF;
_initTime = getTimer();
_sampleSize = _arg3;
_frameCount = 0;
_fps = 0;
_fpsCounter = new TextField();
_fpsCounter.embedFonts = true;
_fpsCounter.defaultTextFormat = _local5;
_fpsCounter.x = _arg1;
_fpsCounter.y = _arg2;
}
public function get_fps():Number{
return (_fps);
}
public function update(){
var _local1:Number;
_frameCount++;
_curTime = getTimer();
if (_frameCount == _sampleSize){
_local1 = (_curTime - _initTime);
_fps = ((_frameCount / _local1) * 1000);
_initTime = _curTime;
_frameCount = 0;
_fpsCounter.text = String(("FPS : " + int(_fps)));
};
}
}
}//package
Section 50
//smallzKeyboardManager (smallzKeyboardManager)
package {
import flash.events.*;
import flash.display.*;
public class smallzKeyboardManager extends Sprite {
public var pressed:Array;
public function smallzKeyboardManager(){
pressed = new Array();
super();
}
public function init(){
stage.addEventListener(KeyboardEvent.KEY_DOWN, keyPressed);
stage.addEventListener(KeyboardEvent.KEY_UP, keyReleased);
}
public function kill(){
stage.removeEventListener(KeyboardEvent.KEY_DOWN, keyPressed);
stage.removeEventListener(KeyboardEvent.KEY_UP, keyReleased);
}
public function isPressed(_arg1:int){
if (pressed.indexOf(_arg1) == -1){
return (false);
};
return (true);
}
public function keyPressed(_arg1:KeyboardEvent){
var _local2:int;
_local2 = pressed.indexOf(_arg1.keyCode);
if (_local2 == -1){
pressed.push(_arg1.keyCode);
};
}
public function keyReleased(_arg1:KeyboardEvent){
var _local2:int;
_local2 = pressed.indexOf(_arg1.keyCode);
if (_local2 != -1){
pressed.splice(_local2, 1);
};
}
}
}//package
Section 51
//smallzMath (smallzMath)
package {
import flash.geom.*;
public class smallzMath {
public static function random_point(_arg1:Number, _arg2:Number):Point{
var _local3:Point;
_local3 = new Point(0, 0);
_local3.x = (Math.random() * _arg1);
_local3.y = (Math.random() * _arg2);
return (_local3);
}
public static function pGetAngle(_arg1:Point, _arg2:Point):Number{
return (Math.atan2((_arg2.y - _arg1.y), (_arg2.x - _arg1.x)));
}
public static function pDistance(_arg1:Point, _arg2:Point):Number{
var _local3:Number;
_local3 = Math.sqrt((((_arg1.x - _arg2.x) * (_arg1.x - _arg2.x)) + ((_arg1.y - _arg2.y) * (_arg1.y - _arg2.y))));
return (_local3);
}
public static function getDistance(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
var _local5:Number;
_local5 = Math.sqrt((((_arg1 - _arg3) * (_arg1 - _arg3)) + ((_arg2 - _arg4) * (_arg2 - _arg4))));
return (_local5);
}
public static function get_angle_point(_arg1:Point, _arg2:Point):Number{
return (Math.atan2((_arg2.y - _arg1.y), (_arg2.x - _arg1.x)));
}
public static function getAngle(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return (Math.atan2((_arg4 - _arg2), (_arg3 - _arg1)));
}
}
}//package
Section 52
//SoundtrackMusic (SoundtrackMusic)
package {
import flash.media.*;
public dynamic class SoundtrackMusic extends Sound {
}
}//package
Section 53
//SubmitScoreScreen (SubmitScoreScreen)
package {
import flash.events.*;
import flash.display.*;
public class SubmitScoreScreen extends MovieClip {
public var _state:String;
public var nonoba_box:MovieClip;
public var smallz_box:MovieClip;
public function SubmitScoreScreen():void{
x = 0;
y = 0;
_state = "Inactive";
visible = false;
}
public function activate():void{
_state = "Active";
visible = true;
if (GameManager.isNonoba){
nonoba_box.visible = true;
smallz_box.visible = false;
nonoba_box.x = 190;
nonoba_box.y = 180;
nonoba_box.score.text = ("Final Score " + String(GameManager.playerScore));
} else {
nonoba_box.visible = false;
smallz_box.visible = true;
smallz_box.x = 190;
smallz_box.y = 180;
smallz_box.score.text = ("Final Score " + String(GameManager.playerScore));
};
}
public function check_rollovers():void{
if (GameManager.isNonoba){
if (nonoba_box.Continue.hitTestPoint(mouseX, mouseY)){
nonoba_box.Continue.scaleX = 1.25;
nonoba_box.Continue.scaleY = 1.25;
} else {
nonoba_box.Continue.scaleX = 1;
nonoba_box.Continue.scaleY = 1;
};
} else {
if (smallz_box.Submit.hitTestPoint(mouseX, mouseY)){
smallz_box.Submit.scaleX = 1.25;
smallz_box.Submit.scaleY = 1.25;
} else {
smallz_box.Submit.scaleX = 1;
smallz_box.Submit.scaleY = 1;
};
if (smallz_box.Cancel.hitTestPoint(mouseX, mouseY)){
smallz_box.Cancel.scaleX = 1.25;
smallz_box.Cancel.scaleY = 1.25;
} else {
smallz_box.Cancel.scaleX = 1;
smallz_box.Cancel.scaleY = 1;
};
};
}
public function menu_mouseUp(_arg1:MouseEvent):void{
if (GameManager.isNonoba){
if (nonoba_box.Continue.hitTestPoint(_arg1.stageX, _arg1.stageY)){
deactivate();
GameManager.gameState = "SaveHighScore";
};
} else {
if (smallz_box.Cancel.hitTestPoint(_arg1.stageX, _arg1.stageY)){
deactivate();
GameManager.gameState = "MainMenu";
};
if (((smallz_box.Submit.hitTestPoint(_arg1.stageX, _arg1.stageY)) && (smallz_box.Submit.visible))){
deactivate();
GameManager._userName = smallz_box.user_name.text;
GameManager.gameState = "SaveHighScore";
};
};
}
public function deactivate():void{
_state = "Inactive";
visible = false;
}
public function update():void{
switch (_state){
case "Active":
break;
};
}
}
}//package
Section 54
//Swipe_sfx (Swipe_sfx)
package {
import flash.media.*;
public dynamic class Swipe_sfx extends Sound {
}
}//package
Section 55
//TongueTarget (TongueTarget)
package {
import flash.display.*;
public dynamic class TongueTarget extends MovieClip {
}
}//package