Section 1
//BagsSubControl (com.whirled.game.BagsSubControl)
package com.whirled.game {
import com.whirled.*;
public class BagsSubControl extends AbstractSubControl {
public static const SHOW_TO_ALL:int = 0;
public function BagsSubControl(_arg1:AbstractControl){
super(_arg1);
}
public function create(_arg1:String, _arg2:Array):void{
populate(_arg1, _arg2, true);
}
public function deal(_arg1:String, _arg2:int, _arg3:String, _arg4:Function=null, _arg5:int=0):void{
getFrom(_arg1, _arg2, _arg3, _arg5, true, _arg4);
}
public function addTo(_arg1:String, _arg2:Array):void{
populate(_arg1, _arg2, false);
}
protected function getFrom(_arg1:String, _arg2:int, _arg3:String, _arg4:int, _arg5:Boolean, _arg6:Function):void{
callHostCode("getFromCollection_v2", _arg1, _arg2, _arg3, _arg4, _arg5, _arg6);
}
public function pick(_arg1:String, _arg2:int, _arg3:String, _arg4:int=0):void{
getFrom(_arg1, _arg2, _arg3, _arg4, false, null);
}
protected function populate(_arg1:String, _arg2:Array, _arg3:Boolean):void{
callHostCode("populateCollection_v1", _arg1, _arg2, _arg3);
}
public function merge(_arg1:String, _arg2:String):void{
callHostCode("mergeCollection_v1", _arg1, _arg2);
}
}
}//package com.whirled.game
Section 2
//CoinsAwardedEvent (com.whirled.game.CoinsAwardedEvent)
package com.whirled.game {
import flash.events.*;
public class CoinsAwardedEvent extends Event {
protected var _amount:int;
protected var _percentile:int;
public static const COINS_AWARDED:String = "CoinsAwarded";
public function CoinsAwardedEvent(_arg1:int, _arg2:int){
super(COINS_AWARDED, false, true);
_amount = _arg1;
_percentile = _arg2;
}
override public function toString():String{
return ((((((("CoinsAwardedEvent [type=" + type) + ", amount=") + _amount) + ", percentile=") + _percentile) + "]"));
}
public function get percentile():int{
return (_percentile);
}
public function get amount():int{
return (_amount);
}
override public function clone():Event{
return (new CoinsAwardedEvent(_amount, _percentile));
}
}
}//package com.whirled.game
Section 3
//GameContentEvent (com.whirled.game.GameContentEvent)
package com.whirled.game {
import flash.events.*;
public class GameContentEvent extends Event {
protected var _playerId:int;
protected var _contentIdent:String;
protected var _contentType:String;
public static const LEVEL_PACK:String = "level_pack";
public static const ITEM_PACK:String = "item_pack";
public static const PLAYER_CONTENT_ADDED:String = "PlayerContentAdded";
public function GameContentEvent(_arg1:String, _arg2:String, _arg3:String, _arg4:int=0){
super(_arg1);
_contentType = _arg2;
_contentIdent = _arg3;
_playerId = _arg4;
}
public function get contentType():String{
return (_contentType);
}
public function get playerId():int{
return (_playerId);
}
override public function clone():Event{
return (new GameContentEvent(type, _contentType, _contentIdent, _playerId));
}
public function get contentIdent():String{
return (_contentIdent);
}
override public function toString():String{
return ((((((((("[GameContentEvent type=" + type) + ", ctype=") + _contentType) + ", cident=") + _contentIdent) + ", pid=") + _playerId) + "]"));
}
}
}//package com.whirled.game
Section 4
//GameControl (com.whirled.game.GameControl)
package com.whirled.game {
import flash.display.*;
import flash.events.*;
import com.whirled.*;
public class GameControl extends AbstractControl {
protected var _servicesCtrl:ServicesSubControl;
protected var _playerCtrl:PlayerSubControl;
protected var _connected:Boolean;
protected var _gameCtrl:GameSubControl;
protected var _localCtrl:LocalSubControl;
protected var _netCtrl:NetSubControl;
public static const LEVEL_PACK_SHOP:String = "level_packs";
public static const FURNITURE_SHOP:String = "furniture";
public static const ITEM_PACK_SHOP:String = "item_packs";
public static const PET_SHOP:String = "pets";
public static const TOY_SHOP:String = "toys";
public static const AVATAR_SHOP:String = "avatars";
public static const BACKDROP_SHOP:String = "backdrops";
public function GameControl(_arg1:DisplayObject, _arg2:Boolean=true){
super(_arg1, {autoReady_v1:_arg2});
_arg1.root.addEventListener(MouseEvent.CLICK, handleRootClick);
}
public function get net():NetSubControl{
return (_netCtrl);
}
public function get player():PlayerSubControl{
return (_playerCtrl);
}
override protected function setUserProps(_arg1:Object):void{
super.setUserProps(_arg1);
_arg1["connectionClosed_v1"] = connectionClosed_v1;
}
public function get services():ServicesSubControl{
return (_servicesCtrl);
}
public function get local():LocalSubControl{
return (_localCtrl);
}
public function get game():GameSubControl{
return (_gameCtrl);
}
private function connectionClosed_v1():void{
_connected = false;
}
override protected function createSubControls():Array{
return ([(_localCtrl = new LocalSubControl(this)), (_netCtrl = new NetSubControl(this)), (_playerCtrl = new PlayerSubControl(this)), (_gameCtrl = new GameSubControl(this)), (_servicesCtrl = new ServicesSubControl(this))]);
}
override protected function gotHostProps(_arg1:Object):void{
super.gotHostProps(_arg1);
_connected = !((_arg1.gameData == null));
}
protected function handleRootClick(_arg1:MouseEvent):void{
var evt = _arg1;
if (!isConnected()){
return;
};
try {
if ((((evt.target.stage == null)) || (!((evt.target.stage.focus == null))))){
return;
};
} catch(err:SecurityError) {
};
callHostCode("focusContainer_v1");
}
override public function isConnected():Boolean{
return (_connected);
}
}
}//package com.whirled.game
Section 5
//GameSubControl (com.whirled.game.GameSubControl)
package com.whirled.game {
import com.whirled.*;
public class GameSubControl extends AbstractSubControl {
protected var _gameConfig:Object;
protected var _seatingCtrl:SeatingSubControl;
public static const SERVER_AGENT_ID:int = -2147483648;
public static const WINNERS_TAKE_ALL:int = 1;
public static const PROPORTIONAL:int = 3;
public static const TO_EACH_THEIR_OWN:int = 2;
public static const CASCADING_PAYOUT:int = 0;
public function GameSubControl(_arg1:GameControl){
_gameConfig = {};
super(_arg1);
}
private function occupantChanged_v1(_arg1:int, _arg2:Boolean, _arg3:Boolean):void{
dispatch(new OccupantChangedEvent((_arg3) ? OccupantChangedEvent.OCCUPANT_ENTERED : OccupantChangedEvent.OCCUPANT_LEFT, _arg1, _arg2));
}
public function getOccupantIds():Array{
return ((callHostCode("getOccupants_v1") as Array));
}
public function getTurnHolderId():int{
return (int(callHostCode("getTurnHolder_v1")));
}
private function gameStateChanged_v1(_arg1:Boolean):void{
dispatch(new StateChangedEvent((_arg1) ? StateChangedEvent.GAME_STARTED : StateChangedEvent.GAME_ENDED));
}
public function endGameWithScore(_arg1:int, _arg2:int=0):void{
endGameWithScores([getMyId()], [_arg1], TO_EACH_THEIR_OWN, _arg2);
}
public function isMyTurn():Boolean{
return (Boolean(callHostCode("isMyTurn_v1")));
}
public function startNextTurn(_arg1:int=0):void{
callHostCode("startNextTurn_v1", _arg1);
}
public function loadItemPackData(_arg1:String, _arg2:Function, _arg3:Function):void{
if (_arg2 == null){
throw (new Error("The onLoaded callback may not be null"));
};
callHostCode("loadItemPackData_v1", _arg1, _arg2, _arg3);
}
override protected function setUserProps(_arg1:Object):void{
super.setUserProps(_arg1);
_arg1["controlDidChange_v1"] = controlDidChange_v1;
_arg1["turnDidChange_v1"] = turnDidChange_v1;
_arg1["gameStateChanged_v1"] = gameStateChanged_v1;
_arg1["roundStateChanged_v1"] = roundStateChanged_v1;
_arg1["occupantChanged_v1"] = occupantChanged_v1;
_arg1["userChat_v1"] = userChat_v1;
}
public function restartGameIn(_arg1:int):void{
if (_seatingCtrl != null){
throw (new Error("restartGameIn() is only applicable to party games."));
};
callHostCode("restartGameIn_v1", _arg1);
}
private function controlDidChange_v1():void{
dispatch(new StateChangedEvent(StateChangedEvent.CONTROL_CHANGED));
}
public function amInControl():Boolean{
return ((getControllerId() == getMyId()));
}
public function amServerAgent():Boolean{
return ((getMyId() == SERVER_AGENT_ID));
}
public function getConfig():Object{
return (_gameConfig);
}
public function get seating():SeatingSubControl{
return (_seatingCtrl);
}
public function loadLevelPackData(_arg1:String, _arg2:Function, _arg3:Function):void{
if (_arg2 == null){
throw (new Error("The onLoaded callback may not be null"));
};
callHostCode("loadLevelPackData_v1", _arg1, _arg2, _arg3);
}
public function playerReady():void{
if (_seatingCtrl == null){
throw (new Error("playerReady() is only applicable to seated games."));
};
callHostCode("playerReady_v1");
}
public function isInPlay():Boolean{
return (Boolean(callHostCode("isInPlay_v1")));
}
public function endGameWithWinners(_arg1:Array, _arg2:Array, _arg3:int):void{
callHostCode("endGameWithWinners_v1", _arg1, _arg2, _arg3);
}
public function getLevelPacks():Array{
return ((callHostCode("getLevelPacks_v2") as Array));
}
public function getRound():int{
return (int(callHostCode("getRound_v1")));
}
public function endGameWithScores(_arg1:Array, _arg2:Array, _arg3:int, _arg4:int=0):void{
callHostCode("endGameWithScores_v1", _arg1, _arg2, _arg3, _arg4);
}
public function getControllerId():int{
return (int(callHostCode("getControllerId_v1")));
}
public function getMyId():int{
return (int(callHostCode("getMyId_v1")));
}
public function systemMessage(_arg1:String):void{
callHostCode("sendChat_v1", _arg1);
}
public function getOccupantName(_arg1:int):String{
return (String(callHostCode("getOccupantName_v1", _arg1)));
}
private function roundStateChanged_v1(_arg1:Boolean):void{
dispatch(new StateChangedEvent((_arg1) ? StateChangedEvent.ROUND_STARTED : StateChangedEvent.ROUND_ENDED));
}
private function turnDidChange_v1():void{
dispatch(new StateChangedEvent(StateChangedEvent.TURN_CHANGED));
}
public function getItemPacks():Array{
return ((callHostCode("getItemPacks_v1") as Array));
}
public function endRound(_arg1:int=0):void{
callHostCode("endRound_v1", _arg1);
}
private function userChat_v1(_arg1:int, _arg2:String):void{
dispatch(new UserChatEvent(_arg1, _arg2));
}
override protected function createSubControls():Array{
return ([(_seatingCtrl = new SeatingSubControl(_parent, this))]);
}
override protected function gotHostProps(_arg1:Object):void{
var o = _arg1;
super.gotHostProps(o);
_gameConfig = o.gameConfig;
try {
if (o["gameInfo"]["type"] == "party"){
_seatingCtrl = null;
_subControls = null;
};
} catch(er:Error) {
};
}
}
}//package com.whirled.game
Section 6
//LocalSubControl (com.whirled.game.LocalSubControl)
package com.whirled.game {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import com.whirled.*;
public class LocalSubControl extends AbstractSubControl {
public function LocalSubControl(_arg1:GameControl){
super(_arg1);
}
public function feedback(_arg1:String):void{
callHostCode("localChat_v1", _arg1);
}
public function getHeadShot(_arg1:int):DisplayObject{
return ((callHostCode("getHeadShot_v2", _arg1) as DisplayObject));
}
override public function removeEventListener(_arg1:String, _arg2:Function, _arg3:Boolean=false):void{
super.removeEventListener(_arg1, _arg2, _arg3);
switch (_arg1){
case KeyboardEvent.KEY_UP:
case KeyboardEvent.KEY_DOWN:
if (!hasEventListener(_arg1)){
callHostCode("alterKeyEvents_v1", _arg1, false);
};
break;
};
}
override public function addEventListener(_arg1:String, _arg2:Function, _arg3:Boolean=false, _arg4:int=0, _arg5:Boolean=false):void{
super.addEventListener(_arg1, _arg2, _arg3, _arg4, _arg5);
switch (_arg1){
case KeyboardEvent.KEY_UP:
case KeyboardEvent.KEY_DOWN:
if (hasEventListener(_arg1)){
callHostCode("alterKeyEvents_v1", _arg1, true);
};
break;
};
}
private function sizeChanged_v1(_arg1:Point):void{
dispatch(new SizeChangedEvent(_arg1));
}
public function clearScores(_arg1:Object=null, _arg2:Boolean=false):void{
callHostCode("clearScores_v1", _arg1, _arg2);
}
public function setOccupantsLabel(_arg1:String):void{
callHostCode("setOccupantsLabel_v1", _arg1);
}
override protected function setUserProps(_arg1:Object):void{
super.setUserProps(_arg1);
_arg1["dispatchEvent_v1"] = dispatch;
_arg1["sizeChanged_v1"] = sizeChanged_v1;
}
public function setPlayerScores(_arg1:Array, _arg2:Array=null):void{
callHostCode("setPlayerScores_v1", _arg1, _arg2);
}
public function showGameShop(_arg1:String, _arg2:int=0):void{
callHostCode("showGameShop_v1", _arg1, _arg2);
}
public function setShowReplay(_arg1:Boolean):void{
callHostCode("setShowReplay_v1", _arg1);
}
public function setStageQuality(_arg1:String="medium"):void{
callHostCode("setStageQuality_v1", _arg1);
}
public function setFrameRate(_arg1:Number=30):void{
callHostCode("setFrameRate_v1", _arg1);
}
public function setMappedScores(_arg1:Object):void{
callHostCode("setMappedScores_v1", _arg1);
}
public function getSize():Point{
return ((callHostCode("getSize_v1") as Point));
}
public function filter(_arg1:String):String{
return ((callHostCode("filter_v1", _arg1) as String));
}
}
}//package com.whirled.game
Section 7
//NetSubControl (com.whirled.game.NetSubControl)
package com.whirled.game {
import flash.utils.*;
import com.whirled.*;
import com.whirled.net.*;
import com.whirled.net.impl.*;
public class NetSubControl extends AbstractSubControl implements PropertySubControl {
protected var _playersMsgCtrl:MessageSubControl;
protected var _gameData:Object;
protected var _agentMsgCtrl:MessageSubControl;
protected var _playerCtrls:Dictionary;
public static const TO_SERVER_AGENT:int = -2147483648;
public static const TO_ALL:int = 0;
public function NetSubControl(_arg1:GameControl){
_playerCtrls = new Dictionary();
super(_arg1);
}
public function getTargetId():int{
return (0);
}
public function get agent():MessageSubControl{
return (_agentMsgCtrl);
}
private function messageReceived_v2(_arg1:String, _arg2:Object, _arg3:int):void{
dispatch(new MessageReceivedEvent(_arg1, _arg2, _arg3));
}
override protected function setUserProps(_arg1:Object):void{
super.setUserProps(_arg1);
_arg1["propertyWasSet_v2"] = propertyWasSet_v2;
_arg1["messageReceived_v2"] = messageReceived_v2;
}
public function get players():MessageSubControl{
return (_playersMsgCtrl);
}
public function setIn(_arg1:String, _arg2:int, _arg3:Object, _arg4:Boolean=false):void{
callHostCode("setProperty_v2", _arg1, _arg3, _arg2, false, _arg4);
}
public function setAt(_arg1:String, _arg2:int, _arg3:Object, _arg4:Boolean=false):void{
callHostCode("setProperty_v2", _arg1, _arg3, _arg2, true, _arg4);
}
public function getPropertyNames(_arg1:String=""):Array{
var _local2:Array;
var _local3:String;
_local2 = [];
for (_local3 in _gameData) {
if (_local3.lastIndexOf(_arg1, 0) == 0){
_local2.push(_local3);
};
};
return (_local2);
}
protected function getPlayerMessager(_arg1:int):MessageSubControl{
var ctrl:MessageSubControl;
var playerId = _arg1;
ctrl = _playerCtrls[playerId];
if (ctrl == null){
ctrl = (_playerCtrls[playerId] = new MessageSubControlAdapter(_parent, function (_arg1:String, _arg2:Object):void{
sendMessage(_arg1, _arg2, playerId);
}));
};
return (ctrl);
}
public function testAndSet(_arg1:String, _arg2:Object, _arg3:Object):void{
callHostCode("testAndSetProperty_v1", _arg1, _arg2, _arg3);
}
public function get(_arg1:String):Object{
checkIsConnected();
return (_gameData[_arg1]);
}
public function sendMessage(_arg1:String, _arg2:Object, _arg3:int=0):void{
callHostCode("sendMessage_v2", _arg1, _arg2, _arg3);
}
public function set(_arg1:String, _arg2:Object, _arg3:Boolean=false):void{
callHostCode("setProperty_v2", _arg1, _arg2, null, false, _arg3);
}
public function getPlayer(_arg1:int):MessageSubControl{
return (getPlayerMessager(_arg1));
}
private function propertyWasSet_v2(_arg1:String, _arg2:Object, _arg3:Object, _arg4:Object):void{
if (_arg4 == null){
dispatch(new PropertyChangedEvent(PropertyChangedEvent.PROPERTY_CHANGED, _arg1, _arg2, _arg3));
} else {
dispatch(new ElementChangedEvent(ElementChangedEvent.ELEMENT_CHANGED, _arg1, _arg2, _arg3, int(_arg4)));
};
}
override protected function createSubControls():Array{
_agentMsgCtrl = new MessageSubControlAdapter(_parent, function (_arg1:String, _arg2:Object):void{
sendMessage(_arg1, _arg2, TO_SERVER_AGENT);
});
_playersMsgCtrl = new MessageSubControlAdapter(_parent, function (_arg1:String, _arg2:Object):void{
sendMessage(_arg1, _arg2, TO_ALL);
});
return ([_agentMsgCtrl, _playersMsgCtrl]);
}
override protected function gotHostProps(_arg1:Object):void{
super.gotHostProps(_arg1);
_gameData = _arg1.gameData;
}
}
}//package com.whirled.game
Section 8
//OccupantChangedEvent (com.whirled.game.OccupantChangedEvent)
package com.whirled.game {
import flash.events.*;
public class OccupantChangedEvent extends Event {
protected var _player:Boolean;
protected var _occupantId:int;
public static const OCCUPANT_LEFT:String = "OccupantLeft";
public static const OCCUPANT_ENTERED:String = "OccupantEntered";
public function OccupantChangedEvent(_arg1:String, _arg2:int, _arg3:Boolean){
super(_arg1);
_occupantId = _arg2;
_player = _arg3;
}
override public function toString():String{
return ((((((("[OccupantChangedEvent type=" + type) + ", occupantId=") + _occupantId) + ", player=") + _player) + "]"));
}
public function get player():Boolean{
return (_player);
}
public function get occupantId():int{
return (_occupantId);
}
override public function clone():Event{
return (new OccupantChangedEvent(type, _occupantId, _player));
}
}
}//package com.whirled.game
Section 9
//PlayerSubControl (com.whirled.game.PlayerSubControl)
package com.whirled.game {
import com.whirled.*;
public class PlayerSubControl extends AbstractSubControl {
public static const CURRENT_USER:int = 0;
public function PlayerSubControl(_arg1:GameControl){
super(_arg1);
}
private function flowAwarded_v1(_arg1:int, _arg2:int):Boolean{
var _local3:CoinsAwardedEvent;
_local3 = new CoinsAwardedEvent(_arg1, _arg2);
dispatch(_local3);
return (_local3.isDefaultPrevented());
}
public function getPlayerItemPacks(_arg1:int=0):Array{
return ((callHostCode("getPlayerItemPacks_v1", _arg1) as Array));
}
public function getCookie(_arg1:Function, _arg2:int=0):void{
callHostCode("getCookie_v1", _arg1, _arg2);
}
private function notifyGameContentAdded_v1(_arg1:String, _arg2:String, _arg3:int):void{
dispatch(new GameContentEvent(GameContentEvent.PLAYER_CONTENT_ADDED, _arg1, _arg2, _arg3));
}
override protected function setUserProps(_arg1:Object):void{
super.setUserProps(_arg1);
_arg1["flowAwarded_v1"] = flowAwarded_v1;
_arg1["notifyGameContentAdded_v1"] = notifyGameContentAdded_v1;
}
public function holdsTrophy(_arg1:String, _arg2:int=0):Boolean{
return ((callHostCode("holdsTrophy_v1", _arg1, _arg2) as Boolean));
}
public function getPlayerLevelPacks(_arg1:int=0):Array{
return ((callHostCode("getPlayerLevelPacks_v1", _arg1) as Array));
}
public function setCookie(_arg1:Object, _arg2:int=0):Boolean{
return (Boolean(callHostCode("setCookie_v1", _arg1, _arg2)));
}
public function awardTrophy(_arg1:String, _arg2:int=0):Boolean{
return ((callHostCode("awardTrophy_v1", _arg1, _arg2) as Boolean));
}
public function awardPrize(_arg1:String, _arg2:int=0):void{
callHostCode("awardPrize_v1", _arg1, _arg2);
}
}
}//package com.whirled.game
Section 10
//SeatingSubControl (com.whirled.game.SeatingSubControl)
package com.whirled.game {
import com.whirled.*;
public class SeatingSubControl extends AbstractSubControl {
protected var _game:GameSubControl;
public function SeatingSubControl(_arg1:AbstractControl, _arg2:GameSubControl){
super(_arg1);
_game = _arg2;
}
public function getPlayerNames():Array{
return (getPlayerIds().map(function (_arg1:int, _arg2, _arg3):String{
return (((_arg1)==0) ? null : _game.getOccupantName(_arg1));
}));
}
public function getPlayerIds():Array{
return ((callHostCode("getPlayers_v1") as Array));
}
public function getMyPosition():int{
return (int(callHostCode("getMyPosition_v1")));
}
public function getPlayerPosition(_arg1:int):int{
return (int(callHostCode("getPlayerPosition_v1", _arg1)));
}
}
}//package com.whirled.game
Section 11
//ServicesSubControl (com.whirled.game.ServicesSubControl)
package com.whirled.game {
import com.whirled.*;
public class ServicesSubControl extends AbstractSubControl {
protected var _bagsCtrl:BagsSubControl;
public function ServicesSubControl(_arg1:GameControl){
super(_arg1);
}
public function stopTicker(_arg1:String):void{
startTicker(_arg1, 0);
}
public function startTicker(_arg1:String, _arg2:int):void{
callHostCode("setTicker_v1", _arg1, _arg2);
}
override protected function createSubControls():Array{
return ([(_bagsCtrl = new BagsSubControl(_parent))]);
}
public function checkDictionaryWord(_arg1:String, _arg2:String, _arg3:String, _arg4:Function):void{
callHostCode("checkDictionaryWord_v2", _arg1, _arg2, _arg3, _arg4);
}
public function get bags():BagsSubControl{
return (_bagsCtrl);
}
public function getDictionaryLetterSet(_arg1:String, _arg2:String, _arg3:int, _arg4:Function):void{
callHostCode("getDictionaryLetterSet_v2", _arg1, _arg2, _arg3, _arg4);
}
public function getDictionaryWords(_arg1:String, _arg2:String, _arg3:int, _arg4:Function):void{
callHostCode("getDictionaryWords_v1", _arg1, _arg2, _arg3, _arg4);
}
}
}//package com.whirled.game
Section 12
//SizeChangedEvent (com.whirled.game.SizeChangedEvent)
package com.whirled.game {
import flash.events.*;
import flash.geom.*;
public class SizeChangedEvent extends Event {
protected var _size:Point;
public static const SIZE_CHANGED:String = "SizeChanged";
public function SizeChangedEvent(_arg1:Point){
super(SIZE_CHANGED);
_size = _arg1;
}
override public function toString():String{
return ((("[SizeChangedEvent size=" + _size) + "]"));
}
public function get size():Point{
return (_size);
}
override public function clone():Event{
return (new SizeChangedEvent(_size.clone()));
}
}
}//package com.whirled.game
Section 13
//StateChangedEvent (com.whirled.game.StateChangedEvent)
package com.whirled.game {
import flash.events.*;
public class StateChangedEvent extends Event {
public static const CONTROL_CHANGED:String = "ControlChanged";
public static const ROUND_ENDED:String = "RoundEnded";
public static const GAME_ENDED:String = "GameEnded";
public static const ROUND_STARTED:String = "RoundStarted";
public static const GAME_STARTED:String = "GameStarted";
public static const TURN_CHANGED:String = "TurnChanged";
public function StateChangedEvent(_arg1:String){
super(_arg1);
}
override public function toString():String{
return ((("[StateChangedEvent type=" + type) + "]"));
}
override public function clone():Event{
return (new StateChangedEvent(type));
}
}
}//package com.whirled.game
Section 14
//UserChatEvent (com.whirled.game.UserChatEvent)
package com.whirled.game {
import flash.events.*;
public class UserChatEvent extends Event {
protected var _message:String;
protected var _speaker:int;
public static const USER_CHAT:String = "UserChat";
public function UserChatEvent(_arg1:int, _arg2:String){
super(USER_CHAT);
_speaker = _arg1;
_message = _arg2;
}
override public function toString():String{
return ((((("[UserChatEvent speaker=" + _speaker) + ", message=") + _message) + "]"));
}
public function get message():String{
return (_message);
}
override public function clone():Event{
return (new UserChatEvent(_speaker, _message));
}
public function get speaker():int{
return (_speaker);
}
}
}//package com.whirled.game
Section 15
//MessageSubControlAdapter (com.whirled.net.impl.MessageSubControlAdapter)
package com.whirled.net.impl {
import com.whirled.*;
import com.whirled.net.*;
public class MessageSubControlAdapter extends AbstractSubControl implements MessageSubControl {
protected var _sendMessage:Function;
public function MessageSubControlAdapter(_arg1:AbstractControl, _arg2:Function){
super(_arg1);
_sendMessage = _arg2;
}
public function sendMessage(_arg1:String, _arg2:Object=null):void{
_sendMessage(_arg1, _arg2);
}
}
}//package com.whirled.net.impl
Section 16
//ElementChangedEvent (com.whirled.net.ElementChangedEvent)
package com.whirled.net {
import flash.events.*;
public class ElementChangedEvent extends PropertyChangedEvent {
protected var _key:int;
public static const ELEMENT_CHANGED:String = "ElemChanged";
public function ElementChangedEvent(_arg1:String, _arg2:String, _arg3:Object, _arg4:Object, _arg5:int){
super(_arg1, _arg2, _arg3, _arg4);
_key = _arg5;
}
public function get index():int{
return (_key);
}
override public function clone():Event{
return (new ElementChangedEvent(type, _name, _newValue, _oldValue, _key));
}
public function get key():int{
return (_key);
}
override public function toString():String{
return ((((((("[ElementChangedEvent name=" + _name) + ", value=") + _newValue) + ", key=") + _key) + "]"));
}
}
}//package com.whirled.net
Section 17
//MessageReceivedEvent (com.whirled.net.MessageReceivedEvent)
package com.whirled.net {
import flash.events.*;
public class MessageReceivedEvent extends Event {
protected var _senderId:int;
protected var _name:String;
protected var _value:Object;
protected static const SERVER_AGENT_ID:int = -2147483648;
protected static const SERVER_ID:int = 0;
public static const MESSAGE_RECEIVED:String = "MsgReceived";
public function MessageReceivedEvent(_arg1:String, _arg2:Object, _arg3:int){
super(MESSAGE_RECEIVED);
_name = _arg1;
_value = _arg2;
_senderId = _arg3;
}
public function get name():String{
return (_name);
}
public function isFromServer():Boolean{
return ((((_senderId == SERVER_ID)) || ((_senderId == SERVER_AGENT_ID))));
}
override public function clone():Event{
return (new MessageReceivedEvent(_name, _value, _senderId));
}
override public function toString():String{
return ((((((("[MessageReceivedEvent name=" + _name) + ", value=") + _value) + ", sender=") + _senderId) + "]"));
}
public function get senderId():int{
return (_senderId);
}
public function get value():Object{
return (_value);
}
}
}//package com.whirled.net
Section 18
//MessageSubControl (com.whirled.net.MessageSubControl)
package com.whirled.net {
public interface MessageSubControl {
function sendMessage(_arg1:String, _arg2:Object=null):void;
}
}//package com.whirled.net
Section 19
//PropertyChangedEvent (com.whirled.net.PropertyChangedEvent)
package com.whirled.net {
import flash.events.*;
public class PropertyChangedEvent extends Event {
protected var _newValue:Object;
protected var _oldValue:Object;
protected var _name:String;
public static const PROPERTY_CHANGED:String = "PropChanged";
public function PropertyChangedEvent(_arg1:String, _arg2:String, _arg3:Object, _arg4:Object){
super(_arg1);
_name = _arg2;
_newValue = _arg3;
_oldValue = _arg4;
}
public function get oldValue():Object{
return (_oldValue);
}
public function get name():String{
return (_name);
}
override public function clone():Event{
return (new PropertyChangedEvent(type, _name, _newValue, _oldValue));
}
override public function toString():String{
return ((((("[PropertyChangedEvent name=" + _name) + ", value=") + _newValue) + "]"));
}
public function get newValue():Object{
return (_newValue);
}
}
}//package com.whirled.net
Section 20
//PropertyGetSubControl (com.whirled.net.PropertyGetSubControl)
package com.whirled.net {
import flash.events.*;
public interface PropertyGetSubControl extends IEventDispatcher {
function getTargetId():int;
function get(_arg1:String):Object;
function getPropertyNames(_arg1:String=""):Array;
}
}//package com.whirled.net
Section 21
//PropertySubControl (com.whirled.net.PropertySubControl)
package com.whirled.net {
public interface PropertySubControl extends PropertyGetSubControl {
function set(_arg1:String, _arg2:Object, _arg3:Boolean=false):void;
function setIn(_arg1:String, _arg2:int, _arg3:Object, _arg4:Boolean=false):void;
function setAt(_arg1:String, _arg2:int, _arg3:Object, _arg4:Boolean=false):void;
}
}//package com.whirled.net
Section 22
//AbstractControl (com.whirled.AbstractControl)
package com.whirled {
import flash.display.*;
import flash.events.*;
import flash.errors.*;
public class AbstractControl extends EventDispatcher {
protected var _subControls:Array;
protected var _funcs:Object;
public function AbstractControl(_arg1:DisplayObject, _arg2:Object=null){
var _local3:Object;
var _local4:ConnectEvent;
var _local5:Object;
super();
_subControls = createSubControls();
if ((this is AbstractSubControl)){
return;
};
if (_arg1.root == null){
throw (new Error("Display object used to instantiate a control must be on the stage"));
};
_arg1.root.loaderInfo.addEventListener(Event.UNLOAD, handleUnload, false, 0, true);
_local3 = ((_arg2)!=null) ? _arg2 : new Object();
setUserProps(_local3);
_local4 = new ConnectEvent();
_local4.props.userProps = _local3;
_arg1.root.loaderInfo.sharedEvents.dispatchEvent(_local4);
if (Boolean(_local4.props.alreadyConnected)){
throw (new Error("You've already set up a Control instance. There should only be one."));
};
_local5 = _local4.props.hostProps;
if (_local5 != null){
gotHostProps(_local5);
};
}
override public function dispatchEvent(_arg1:Event):Boolean{
throw (new IllegalOperationError());
}
protected function dispatch(_arg1:Event):void{
var event = _arg1;
try {
super.dispatchEvent(event);
} catch(err:Error) {
};
}
protected function handleUnload(_arg1:Event):void{
dispatch(_arg1);
}
override public function removeEventListener(_arg1:String, _arg2:Function, _arg3:Boolean=false):void{
super.removeEventListener(_arg1, _arg2, _arg3);
}
override public function addEventListener(_arg1:String, _arg2:Function, _arg3:Boolean=false, _arg4:int=0, _arg5:Boolean=false):void{
super.addEventListener(_arg1, _arg2, _arg3, _arg4, _arg5);
}
protected function checkIsConnected():void{
if (!isConnected()){
throw (new IllegalOperationError(("The control is not connected to the host framework, please check isConnected(). " + "If false, your SWF is being viewed standalone and should adjust.")));
};
}
protected function setUserProps(_arg1:Object):void{
var _local2:AbstractSubControl;
for each (_local2 in _subControls) {
_local2.setUserPropsFriend(_arg1);
};
}
public function doBatch(_arg1:Function, ... _args):void{
var fn = _arg1;
var args = _args;
callHostCode("startTransaction");
try {
fn.apply(null, args);
} finally {
callHostCode("commitTransaction");
};
}
function callHostCodeFriend(_arg1:String, _arg2:Array){
_arg2.unshift(_arg1);
return (callHostCode.apply(this, _arg2));
}
protected function callHostCode(_arg1:String, ... _args){
var func:Function;
var name = _arg1;
var args = _args;
if (_funcs != null){
try {
func = (_funcs[name] as Function);
if (func == null){
} else {
return (func.apply(null, args));
};
} catch(err:Error) {
throw (new Error(("Unable to call host code: " + err.message)));
};
} else {
checkIsConnected();
};
return (undefined);
}
protected function createSubControls():Array{
return (null);
}
protected function gotHostProps(_arg1:Object):void{
var _local2:AbstractSubControl;
_funcs = _arg1;
for each (_local2 in _subControls) {
_local2.gotHostPropsFriend(_arg1);
};
}
public function isConnected():Boolean{
return (!((_funcs == null)));
}
}
}//package com.whirled
import flash.events.*;
class ConnectEvent extends Event {
public var props:Object;
private function ConnectEvent(_arg1:Object=null){
super("controlConnect", true, false);
props = ((_arg1) || ({}));
}
override public function clone():Event{
return (new ConnectEvent(props));
}
}
Section 23
//AbstractSubControl (com.whirled.AbstractSubControl)
package com.whirled {
import flash.events.*;
public class AbstractSubControl extends AbstractControl {
protected var _parent:AbstractControl;
public function AbstractSubControl(_arg1:AbstractControl){
_parent = _arg1;
_parent.addEventListener(Event.UNLOAD, handleUnload, false, 0, true);
super(null);
}
function gotHostPropsFriend(_arg1:Object):void{
gotHostProps(_arg1);
}
function setUserPropsFriend(_arg1:Object):void{
setUserProps(_arg1);
}
override public function doBatch(_arg1:Function, ... _args):void{
_args.unshift(_arg1);
_parent.doBatch.apply(null, _args);
}
override protected function callHostCode(_arg1:String, ... _args){
return (_parent.callHostCodeFriend(_arg1, _args));
}
override public function isConnected():Boolean{
return (_parent.isConnected());
}
}
}//package com.whirled
Section 24
//Animator (fl.motion.Animator)
package fl.motion {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
public class Animator extends EventDispatcher {
private var targetState:Object;
public var transformationPoint:Point;
private var _isPlaying:Boolean;// = false
private var _time:int;// = -1
private var _target:DisplayObject;
public var repeatCount:int;// = 1
private var _lastRenderedTime:int;// = -1
private var playCount:int;// = 0
private var _motion:Motion;
public var orientToPath:Boolean;// = false
public var autoRewind:Boolean;// = false
public var positionMatrix:Matrix;
private static var enterFrameBeacon:MovieClip = new MovieClip();
public function Animator(_arg1:XML=null, _arg2:DisplayObject=null){
orientToPath = false;
autoRewind = false;
repeatCount = 1;
_isPlaying = false;
_lastRenderedTime = -1;
_time = -1;
playCount = 0;
super();
this.motion = new Motion(_arg1);
this.target = _arg2;
}
public function stop():void{
enterFrameBeacon.removeEventListener(Event.ENTER_FRAME, this.enterFrameHandler);
this._isPlaying = false;
this.playCount = 0;
this.rewind();
this.dispatchEvent(new MotionEvent(MotionEvent.MOTION_END));
}
public function get target():DisplayObject{
return (this._target);
}
public function set time(_arg1:int):void{
var _local2:Motion;
var _local3:Keyframe;
var _local4:Boolean;
var _local5:Number;
var _local6:Number;
var _local7:Point;
var _local8:Number;
var _local9:Number;
var _local10:Number;
var _local11:Number;
var _local12:Matrix;
var _local13:Point;
var _local14:Number;
var _local15:Number;
var _local16:ColorTransform;
var _local17:Number;
var _local18:Number;
var _local19:Number;
if (_arg1 == this._time){
return;
};
_local2 = this.motion;
if (_arg1 > (_local2.duration - 1)){
_arg1 = (_local2.duration - 1);
} else {
if (_arg1 < 0){
_arg1 = 0;
};
};
this._time = _arg1;
this.dispatchEvent(new MotionEvent(MotionEvent.TIME_CHANGE));
_local3 = _local2.getCurrentKeyframe(_arg1);
_local4 = (((_local3.index == this._lastRenderedTime)) && (!(_local3.tweens.length)));
if (_local4){
return;
};
this._target.visible = false;
if (!_local3.blank){
_local5 = _local2.getValue(_arg1, Tweenables.X);
_local6 = _local2.getValue(_arg1, Tweenables.Y);
_local7 = new Point(_local5, _local6);
if (this.positionMatrix){
_local7 = this.positionMatrix.transformPoint(_local7);
};
_local7.x = (_local7.x + this.targetState.x);
_local7.y = (_local7.y + this.targetState.y);
_local8 = (_local2.getValue(_arg1, Tweenables.SCALE_X) * this.targetState.scaleX);
_local9 = (_local2.getValue(_arg1, Tweenables.SCALE_Y) * this.targetState.scaleY);
_local10 = 0;
_local11 = 0;
if (this.orientToPath){
_local17 = _local2.getValue((_arg1 + 1), Tweenables.X);
_local18 = _local2.getValue((_arg1 + 1), Tweenables.Y);
_local19 = (Math.atan2((_local18 - _local6), (_local17 - _local5)) * (180 / Math.PI));
if (!isNaN(_local19)){
_local10 = (_local19 + this.targetState.skewX);
_local11 = (_local19 + this.targetState.skewY);
};
} else {
_local10 = (_local2.getValue(_arg1, Tweenables.SKEW_X) + this.targetState.skewX);
_local11 = (_local2.getValue(_arg1, Tweenables.SKEW_Y) + this.targetState.skewY);
};
_local12 = new Matrix((_local8 * Math.cos((_local11 * (Math.PI / 180)))), (_local8 * Math.sin((_local11 * (Math.PI / 180)))), (-(_local9) * Math.sin((_local10 * (Math.PI / 180)))), (_local9 * Math.cos((_local10 * (Math.PI / 180)))), _local7.x, _local7.y);
_local13 = _local12.transformPoint(this.targetState.transformPointInternal);
_local14 = (_local12.tx - _local13.x);
_local15 = (_local12.ty - _local13.y);
_local12.tx = (_local12.tx + _local14);
_local12.ty = (_local12.ty + _local15);
this._target.rotation = _local11;
this._target.transform.matrix = _local12;
this._target.scaleX = _local8;
this._target.scaleY = _local9;
_local16 = _local2.getColorTransform(_arg1);
if (_local16){
this._target.transform.colorTransform = _local16;
};
this._target.filters = _local2.getFilters(_arg1);
this._target.blendMode = _local3.blendMode;
this._target.cacheAsBitmap = _local3.cacheAsBitmap;
this._target.visible = true;
};
this._lastRenderedTime = this._time;
this.dispatchEvent(new MotionEvent(MotionEvent.MOTION_UPDATE));
}
private function enterFrameHandler(_arg1:Event):void{
this.nextFrame();
}
public function set target(_arg1:DisplayObject):void{
var _local2:Object;
var _local3:Number;
var _local4:Number;
var _local5:Point;
if (!_arg1){
return;
};
this._target = _arg1;
this.targetState = {};
this.targetState.scaleX = this._target.scaleX;
this.targetState.scaleY = this._target.scaleY;
this.targetState.skewX = MatrixTransformer.getSkewX(this._target.transform.matrix);
this.targetState.skewY = MatrixTransformer.getSkewY(this._target.transform.matrix);
this.targetState.matrix = this._target.transform.matrix;
_local2 = (this.targetState.bounds = this._target.getBounds(this._target));
if (this.transformationPoint){
_local3 = ((this.transformationPoint.x * _local2.width) + _local2.left);
_local4 = ((this.transformationPoint.y * _local2.height) + _local2.top);
this.targetState.transformPointInternal = new Point(_local3, _local4);
_local5 = this.targetState.matrix.transformPoint(this.targetState.transformPointInternal);
this.targetState.x = _local5.x;
this.targetState.y = _local5.y;
} else {
this.targetState.transformPointInternal = new Point(0, 0);
this.targetState.x = this._target.x;
this.targetState.y = this._target.y;
};
}
public function get isPlaying():Boolean{
return (_isPlaying);
}
public function resume():void{
enterFrameBeacon.addEventListener(Event.ENTER_FRAME, this.enterFrameHandler, false, 0, true);
this._isPlaying = true;
}
private function handleLastFrame():void{
this.playCount++;
if ((((this.repeatCount == 0)) || ((this.playCount < this.repeatCount)))){
this.rewind();
} else {
this.end();
};
}
public function get motion():Motion{
return (this._motion);
}
public function nextFrame():void{
if (this.time >= (this.motion.duration - 1)){
this.handleLastFrame();
} else {
this.time++;
};
}
public function play():void{
if (!this._isPlaying){
enterFrameBeacon.addEventListener(Event.ENTER_FRAME, this.enterFrameHandler, false, 0, true);
this._isPlaying = true;
};
this.playCount = 0;
this.rewind();
this.dispatchEvent(new MotionEvent(MotionEvent.MOTION_START));
}
public function rewind():void{
this.time = 0;
}
public function end():void{
enterFrameBeacon.removeEventListener(Event.ENTER_FRAME, this.enterFrameHandler);
this._isPlaying = false;
this.playCount = 0;
if (this.autoRewind){
this.rewind();
} else {
if (this.time != (this.motion.duration - 1)){
this.time = (this.motion.duration - 1);
};
};
this.dispatchEvent(new MotionEvent(MotionEvent.MOTION_END));
}
public function get time():int{
return (this._time);
}
public function pause():void{
enterFrameBeacon.removeEventListener(Event.ENTER_FRAME, this.enterFrameHandler);
this._isPlaying = false;
}
public function set motion(_arg1:Motion):void{
this._motion = _arg1;
if (((_arg1.source) && (_arg1.source.transformationPoint))){
this.transformationPoint = _arg1.source.transformationPoint.clone();
};
}
public static function fromXMLString(_arg1:String, _arg2:DisplayObject=null):Animator{
return (new Animator(new XML(_arg1), _arg2));
}
}
}//package fl.motion
Section 25
//BezierEase (fl.motion.BezierEase)
package fl.motion {
import flash.geom.*;
public class BezierEase implements ITween {
public var points:Array;
private var firstNode:Point;
private var _target:String;// = ""
private var lastNode:Point;
public function BezierEase(_arg1:XML=null){
_target = "";
super();
this.points = [];
this.parseXML(_arg1);
}
public function set target(_arg1:String):void{
this._target = _arg1;
}
public function get target():String{
return (this._target);
}
public function getValue(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
var _local5:Number;
var _local6:Array;
var _local7:Number;
if (_arg4 <= 0){
return (NaN);
};
_local5 = (_arg1 / _arg4);
if (_local5 <= 0){
return (_arg2);
};
if (_local5 >= 1){
return ((_arg2 + _arg3));
};
this.firstNode = new Point(0, _arg2);
this.lastNode = new Point(1, (_arg2 + _arg3));
_local6 = [this.firstNode].concat(this.points);
_local6.push(this.lastNode);
_local7 = CustomEase.getYForPercent(_local5, _local6);
return (_local7);
}
private function parseXML(_arg1:XML=null):BezierEase{
var _local2:XMLList;
var _local3:XML;
if (!_arg1){
return (this);
};
if (_arg1.@target.length()){
this.target = _arg1.@target;
};
_local2 = _arg1.elements();
for each (_local3 in _local2) {
this.points.push(new Point(Number(_local3.@x), Number(_local3.@y)));
};
return (this);
}
}
}//package fl.motion
Section 26
//BezierSegment (fl.motion.BezierSegment)
package fl.motion {
import flash.geom.*;
public class BezierSegment {
public var a:Point;
public var c:Point;
public var b:Point;
public var d:Point;
public function BezierSegment(_arg1:Point, _arg2:Point, _arg3:Point, _arg4:Point){
this.a = _arg1;
this.b = _arg2;
this.c = _arg3;
this.d = _arg4;
}
public function getYForX(_arg1:Number, _arg2:Array=null):Number{
var _local3:Array;
var _local4:Number;
var _local5:Number;
var _local6:Number;
if (this.a.x < this.d.x){
if (_arg1 <= (this.a.x + 1E-16)){
return (this.a.y);
};
if (_arg1 >= (this.d.x - 1E-16)){
return (this.d.y);
};
} else {
if (_arg1 >= (this.a.x + 1E-16)){
return (this.a.y);
};
if (_arg1 <= (this.d.x - 1E-16)){
return (this.d.y);
};
};
if (!_arg2){
_arg2 = getCubicCoefficients(this.a.x, this.b.x, this.c.x, this.d.x);
};
_local3 = getCubicRoots(_arg2[0], _arg2[1], _arg2[2], (_arg2[3] - _arg1));
_local4 = NaN;
if (_local3.length == 0){
_local4 = 0;
} else {
if (_local3.length == 1){
_local4 = _local3[0];
} else {
for each (_local6 in _local3) {
if ((((0 <= _local6)) && ((_local6 <= 1)))){
_local4 = _local6;
break;
};
};
};
};
if (isNaN(_local4)){
return (NaN);
};
_local5 = getSingleValue(_local4, this.a.y, this.b.y, this.c.y, this.d.y);
return (_local5);
}
public function getValue(_arg1:Number):Point{
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
_local2 = this.a.x;
_local3 = (((((_arg1 * _arg1) * (this.d.x - _local2)) + ((3 * (1 - _arg1)) * ((_arg1 * (this.c.x - _local2)) + ((1 - _arg1) * (this.b.x - _local2))))) * _arg1) + _local2);
_local4 = this.a.y;
_local5 = (((((_arg1 * _arg1) * (this.d.y - _local4)) + ((3 * (1 - _arg1)) * ((_arg1 * (this.c.y - _local4)) + ((1 - _arg1) * (this.b.y - _local4))))) * _arg1) + _local4);
return (new Point(_local3, _local5));
}
public static function getCubicCoefficients(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Array{
return ([(((-(_arg1) + (3 * _arg2)) - (3 * _arg3)) + _arg4), (((3 * _arg1) - (6 * _arg2)) + (3 * _arg3)), ((-3 * _arg1) + (3 * _arg2)), _arg1]);
}
public static function getSingleValue(_arg1:Number, _arg2:Number=0, _arg3:Number=0, _arg4:Number=0, _arg5:Number=0):Number{
return ((((((_arg1 * _arg1) * (_arg5 - _arg2)) + ((3 * (1 - _arg1)) * ((_arg1 * (_arg4 - _arg2)) + ((1 - _arg1) * (_arg3 - _arg2))))) * _arg1) + _arg2));
}
public static function getCubicRoots(_arg1:Number=0, _arg2:Number=0, _arg3:Number=0, _arg4:Number=0):Array{
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:Number;
var _local9:Number;
var _local10:Number;
var _local11:Number;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local15:int;
var _local16:Number;
if (!_arg1){
return (BezierSegment.getQuadraticRoots(_arg2, _arg3, _arg4));
};
if (_arg1 != 1){
_arg2 = (_arg2 / _arg1);
_arg3 = (_arg3 / _arg1);
_arg4 = (_arg4 / _arg1);
};
_local5 = (((_arg2 * _arg2) - (3 * _arg3)) / 9);
_local6 = (((((_arg2 * _arg2) - (3 * _arg3)) / 9) * _local5) * _local5);
_local7 = ((((((2 * _arg2) * _arg2) * _arg2) - ((9 * _arg2) * _arg3)) + (27 * _arg4)) / 54);
_local8 = (_local6 - (_local7 * _local7));
if (_local8 >= 0){
if (!_local5){
return ([0]);
};
_local9 = Math.acos((_local7 / Math.sqrt(_local6)));
_local10 = Math.sqrt(_local5);
_local11 = (((-2 * _local10) * Math.cos((_local9 / 3))) - (_arg2 / 3));
_local12 = (((-2 * _local10) * Math.cos(((_local9 + (2 * Math.PI)) / 3))) - (_arg2 / 3));
_local13 = (((-2 * _local10) * Math.cos(((_local9 + (4 * Math.PI)) / 3))) - (_arg2 / 3));
return ([_local11, _local12, _local13]);
//unresolved jump
};
_local14 = Math.pow((Math.sqrt(-(_local8)) + Math.abs(_local7)), (1 / 3));
_local15 = ((_local7)>0) ? 1 : ((_local7 < 0)) ? -1 : 0;
_local16 = ((-(_local15) * (_local14 + (_local5 / _local14))) - (_arg2 / 3));
return ([_local16]);
}
public static function getQuadraticRoots(_arg1:Number, _arg2:Number, _arg3:Number):Array{
var _local4:Array;
var _local5:Number;
var _local6:int;
var _local7:Number;
_local4 = [];
if (!_arg1){
if (!_arg2){
return ([]);
};
_local4[0] = (-(_arg3) / _arg2);
return (_local4);
};
_local5 = ((_arg2 * _arg2) - ((4 * _arg1) * _arg3));
_local6 = ((_local5)>0) ? 1 : ((_local5 < 0)) ? -1 : 0;
if (_local6 < 0){
return ([]);
};
if (!_local6){
_local4[0] = (-(_arg2) / (2 * _arg1));
} else {
_local4[0] = (_local4[1] = (-(_arg2) / (2 * _arg1)));
_local7 = (Math.sqrt(_local5) / (2 * _arg1));
_local4[0] = (_local4[0] - _local7);
_local4[1] = (_local4[1] + _local7);
};
return (_local4);
}
}
}//package fl.motion
Section 27
//Color (fl.motion.Color)
package fl.motion {
import flash.display.*;
import flash.geom.*;
public class Color extends ColorTransform {
private var _tintMultiplier:Number;// = 0
private var _tintColor:Number;// = 0
public function Color(_arg1:Number=1, _arg2:Number=1, _arg3:Number=1, _arg4:Number=1, _arg5:Number=0, _arg6:Number=0, _arg7:Number=0, _arg8:Number=0){
_tintColor = 0;
_tintMultiplier = 0;
super(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7, _arg8);
}
public function setTint(_arg1:uint, _arg2:Number):void{
var _local3:uint;
var _local4:uint;
var _local5:uint;
this._tintColor = _arg1;
this._tintMultiplier = _arg2;
this.redMultiplier = (this.greenMultiplier = (this.blueMultiplier = (1 - _arg2)));
_local3 = ((_arg1 >> 16) & 0xFF);
_local4 = ((_arg1 >> 8) & 0xFF);
_local5 = (_arg1 & 0xFF);
this.redOffset = Math.round((_local3 * _arg2));
this.greenOffset = Math.round((_local4 * _arg2));
this.blueOffset = Math.round((_local5 * _arg2));
}
public function set tintColor(_arg1:uint):void{
this.setTint(_arg1, this.tintMultiplier);
}
public function get brightness():Number{
return ((this.redOffset) ? (1 - this.redMultiplier) : (this.redMultiplier - 1));
}
private function deriveTintColor():uint{
var _local1:Number;
var _local2:uint;
var _local3:uint;
var _local4:uint;
var _local5:uint;
_local1 = (1 / this.tintMultiplier);
_local2 = Math.round((this.redOffset * _local1));
_local3 = Math.round((this.greenOffset * _local1));
_local4 = Math.round((this.blueOffset * _local1));
_local5 = (((_local2 << 16) | (_local3 << 8)) | _local4);
return (_local5);
}
public function get tintMultiplier():Number{
return (this._tintMultiplier);
}
public function get tintColor():uint{
return (this._tintColor);
}
public function set brightness(_arg1:Number):void{
var _local2:Number;
var _local3:Number;
if (_arg1 > 1){
_arg1 = 1;
} else {
if (_arg1 < -1){
_arg1 = -1;
};
};
_local2 = (1 - Math.abs(_arg1));
_local3 = 0;
if (_arg1 > 0){
_local3 = (_arg1 * 0xFF);
};
this.redMultiplier = (this.greenMultiplier = (this.blueMultiplier = _local2));
this.redOffset = (this.greenOffset = (this.blueOffset = _local3));
}
public function set tintMultiplier(_arg1:Number):void{
this.setTint(this.tintColor, _arg1);
}
private function parseXML(_arg1:XML=null):Color{
var _local2:XML;
var _local3:XML;
var _local4:String;
var _local5:uint;
if (!_arg1){
return (this);
};
_local2 = _arg1.elements()[0];
if (!_local2){
return (this);
};
for each (_local3 in _local2.attributes()) {
_local4 = _local3.localName();
if (_local4 == "tintColor"){
_local5 = (Number(_local3.toString()) as uint);
this.tintColor = _local5;
} else {
this[_local4] = Number(_local3.toString());
};
};
return (this);
}
public static function interpolateColor(_arg1:uint, _arg2:uint, _arg3:Number):uint{
var _local4:Number;
var _local5:uint;
var _local6:uint;
var _local7:uint;
var _local8:uint;
var _local9:uint;
var _local10:uint;
var _local11:uint;
var _local12:uint;
var _local13:uint;
var _local14:uint;
var _local15:uint;
var _local16:uint;
var _local17:uint;
_local4 = (1 - _arg3);
_local5 = ((_arg1 >> 24) & 0xFF);
_local6 = ((_arg1 >> 16) & 0xFF);
_local7 = ((_arg1 >> 8) & 0xFF);
_local8 = (_arg1 & 0xFF);
_local9 = ((_arg2 >> 24) & 0xFF);
_local10 = ((_arg2 >> 16) & 0xFF);
_local11 = ((_arg2 >> 8) & 0xFF);
_local12 = (_arg2 & 0xFF);
_local13 = ((_local5 * _local4) + (_local9 * _arg3));
_local14 = ((_local6 * _local4) + (_local10 * _arg3));
_local15 = ((_local7 * _local4) + (_local11 * _arg3));
_local16 = ((_local8 * _local4) + (_local12 * _arg3));
_local17 = ((((_local13 << 24) | (_local14 << 16)) | (_local15 << 8)) | _local16);
return (_local17);
}
public static function interpolateTransform(_arg1:ColorTransform, _arg2:ColorTransform, _arg3:Number):ColorTransform{
var _local4:Number;
var _local5:ColorTransform;
_local4 = (1 - _arg3);
_local5 = new ColorTransform(((_arg1.redMultiplier * _local4) + (_arg2.redMultiplier * _arg3)), ((_arg1.greenMultiplier * _local4) + (_arg2.greenMultiplier * _arg3)), ((_arg1.blueMultiplier * _local4) + (_arg2.blueMultiplier * _arg3)), ((_arg1.alphaMultiplier * _local4) + (_arg2.alphaMultiplier * _arg3)), ((_arg1.redOffset * _local4) + (_arg2.redOffset * _arg3)), ((_arg1.greenOffset * _local4) + (_arg2.greenOffset * _arg3)), ((_arg1.blueOffset * _local4) + (_arg2.blueOffset * _arg3)), ((_arg1.alphaOffset * _local4) + (_arg2.alphaOffset * _arg3)));
return (_local5);
}
public static function fromXML(_arg1:XML):Color{
return (Color(new (Color).parseXML(_arg1)));
}
}
}//package fl.motion
Section 28
//CustomEase (fl.motion.CustomEase)
package fl.motion {
import flash.geom.*;
public class CustomEase implements ITween {
public var points:Array;
private var firstNode:Point;
private var _target:String;// = ""
private var lastNode:Point;
public function CustomEase(_arg1:XML=null){
_target = "";
super();
this.points = [];
this.parseXML(_arg1);
this.firstNode = new Point(0, 0);
this.lastNode = new Point(1, 1);
}
public function set target(_arg1:String):void{
this._target = _arg1;
}
public function get target():String{
return (this._target);
}
public function getValue(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
var _local5:Number;
var _local6:Array;
var _local7:Number;
if (_arg4 <= 0){
return (NaN);
};
_local5 = (_arg1 / _arg4);
if (_local5 <= 0){
return (_arg2);
};
if (_local5 >= 1){
return ((_arg2 + _arg3));
};
_local6 = [this.firstNode].concat(this.points);
_local6.push(this.lastNode);
_local7 = getYForPercent(_local5, _local6);
return ((_arg2 + (_local7 * _arg3)));
}
private function parseXML(_arg1:XML=null):CustomEase{
var _local2:XMLList;
var _local3:XML;
if (!_arg1){
return (this);
};
if (_arg1.@target.length()){
this.target = _arg1.@target;
};
_local2 = _arg1.elements();
for each (_local3 in _local2) {
this.points.push(new Point(Number(_local3.@x), Number(_local3.@y)));
};
return (this);
}
static function getYForPercent(_arg1:Number, _arg2:Array):Number{
var _local3:BezierSegment;
var _local4:Array;
var _local5:int;
var _local6:BezierSegment;
var _local7:Number;
var _local8:int;
var _local9:BezierSegment;
_local3 = new BezierSegment(_arg2[0], _arg2[1], _arg2[2], _arg2[3]);
_local4 = [_local3];
_local5 = 3;
while (_local5 < (_arg2.length - 3)) {
_local4.push(new BezierSegment(_arg2[_local5], _arg2[(_local5 + 1)], _arg2[(_local5 + 2)], _arg2[(_local5 + 3)]));
_local5 = (_local5 + 3);
};
_local6 = _local3;
if (_arg2.length >= 5){
_local8 = 0;
while (_local8 < _local4.length) {
_local9 = _local4[_local8];
if ((((_local9.a.x <= _arg1)) && ((_arg1 <= _local9.d.x)))){
_local6 = _local9;
break;
};
_local8++;
};
};
_local7 = _local6.getYForX(_arg1);
return (_local7);
}
}
}//package fl.motion
Section 29
//FunctionEase (fl.motion.FunctionEase)
package fl.motion {
import flash.utils.*;
public class FunctionEase implements ITween {
private var _functionName:String;// = ""
public var parameters:Array;// = null
private var _target:String;// = ""
public var easingFunction:Function;// = null
public function FunctionEase(_arg1:XML=null){
_functionName = "";
easingFunction = null;
parameters = null;
_target = "";
super();
this.parseXML(_arg1);
}
public function get functionName():String{
return (this._functionName);
}
public function set functionName(_arg1:String):void{
var _local2:Array;
var _local3:String;
var _local4:String;
var _local5:Class;
_local2 = _arg1.split(".");
_local3 = _local2.pop();
_local4 = _local2.join(".");
_local5 = (getDefinitionByName(_local4) as Class);
if ((_local5[_local3] is Function)){
this.easingFunction = _local5[_local3];
this._functionName = _arg1;
};
}
public function set target(_arg1:String):void{
this._target = _arg1;
}
public function get target():String{
return (this._target);
}
public function getValue(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
var _local5:Array;
if ((this.parameters is Array)){
_local5 = [_arg1, _arg2, _arg3, _arg4].concat(this.parameters);
return (this.easingFunction.apply(null, _local5));
};
return (this.easingFunction(_arg1, _arg2, _arg3, _arg4));
}
private function parseXML(_arg1:XML=null):FunctionEase{
if (!_arg1){
return (this);
};
if (_arg1.@functionName.length()){
this.functionName = _arg1.@functionName;
};
return (this);
}
}
}//package fl.motion
Section 30
//ITween (fl.motion.ITween)
package fl.motion {
public interface ITween {
function get target():String;
function set target(_arg1:String):void;
function getValue(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number;
}
}//package fl.motion
Section 31
//Keyframe (fl.motion.Keyframe)
package fl.motion {
import flash.display.*;
import flash.utils.*;
import flash.filters.*;
public class Keyframe {
public var skewX:Number;// = NAN
public var blendMode:String;
public var skewY:Number;// = NAN
public var firstFrame:String;
public var tweenScale:Boolean;// = true
public var cacheAsBitmap:Boolean;// = false
public var rotateTimes:uint;// = 0
public var tweenSync:Boolean;// = false
public var loop:String;
public var scaleX:Number;// = NAN
private var _index:int;// = -1
public var blank:Boolean;// = false
public var tweenSnap:Boolean;// = false
public var scaleY:Number;// = NAN
public var color:Color;
public var rotateDirection:String;
public var orientToPath:Boolean;// = false
public var tweens:Array;
public var label:String;// = ""
public var x:Number;// = NAN
public var y:Number;// = NAN
public var filters:Array;
public function Keyframe(_arg1:XML=null){
_index = -1;
x = NaN;
y = NaN;
scaleX = NaN;
scaleY = NaN;
skewX = NaN;
skewY = NaN;
label = "";
tweenScale = true;
tweenSnap = false;
tweenSync = false;
cacheAsBitmap = false;
blendMode = BlendMode.NORMAL;
rotateDirection = RotateDirection.AUTO;
rotateTimes = 0;
orientToPath = false;
blank = false;
super();
this.tweens = [];
this.filters = [];
this.parseXML(_arg1);
}
public function set index(_arg1:int):void{
this._index = ((_arg1)<0) ? 0 : _arg1;
if (this._index == 0){
this.setDefaults();
};
}
public function getTween(_arg1:String=""):ITween{
var _local2:ITween;
for each (_local2 in this.tweens) {
if ((((((((_local2.target == _arg1)) || ((((_local2.target == "rotation")) && ((((_arg1 == "skewX")) || ((_arg1 == "skewY")))))))) || ((((_local2.target == "position")) && ((((_arg1 == "x")) || ((_arg1 == "y")))))))) || ((((_local2.target == "scale")) && ((((_arg1 == "scaleX")) || ((_arg1 == "scaleY")))))))){
return (_local2);
};
};
return (null);
}
public function setValue(_arg1:String, _arg2:Number):void{
this[_arg1] = _arg2;
}
public function getValue(_arg1:String):Number{
return (Number(this[_arg1]));
}
public function get index():int{
return (this._index);
}
private function setDefaults():void{
if (isNaN(this.x)){
this.x = 0;
};
if (isNaN(this.y)){
this.y = 0;
};
if (isNaN(this.scaleX)){
this.scaleX = 1;
};
if (isNaN(this.scaleY)){
this.scaleY = 1;
};
if (isNaN(this.skewX)){
this.skewX = 0;
};
if (isNaN(this.skewY)){
this.skewY = 0;
};
if (!this.color){
this.color = new Color();
};
}
public function affectsTweenable(_arg1:String=""):Boolean{
return (((((((((((!(_arg1)) || (!(isNaN(this[_arg1]))))) || ((((_arg1 == "color")) && (this.color))))) || ((((_arg1 == "filters")) && (this.filters.length))))) || (this.blank))) || (this.getTween())));
}
private function parseXML(_arg1:XML=null):Keyframe{
var indexString:String;
var indexValue:int;
var tweenableNames:Array;
var tweenableName:String;
var elements:XMLList;
var filtersArray:Array;
var child:XML;
var attribute:XML;
var attributeValue:String;
var name:String;
var tweenChildren:XMLList;
var tweenChild:XML;
var tweenName:String;
var filtersChildren:XMLList;
var filterXML:XML;
var filterName:String;
var filterClassName:String;
var filterClass:Object;
var filterInstance:BitmapFilter;
var filterTypeInfo:XML;
var accessorList:XMLList;
var ratios:Array;
var attrib:XML;
var attribName:String;
var accessor:XML;
var attribType:String;
var attribValue:String;
var uintValue:uint;
var valuesArray:Array;
var xml = _arg1;
if (!xml){
return (this);
};
indexString = xml.@index.toXMLString();
indexValue = parseInt(indexString);
if (indexString){
this.index = indexValue;
} else {
throw (new Error("<Keyframe> is missing the required attribute \"index\"."));
};
if (xml.@label.length()){
this.label = xml.@label;
};
if (xml.@tweenScale.length()){
this.tweenScale = (xml.@tweenScale.toString() == "true");
};
if (xml.@tweenSnap.length()){
this.tweenSnap = (xml.@tweenSnap.toString() == "true");
};
if (xml.@tweenSync.length()){
this.tweenSync = (xml.@tweenSync.toString() == "true");
};
if (xml.@blendMode.length()){
this.blendMode = xml.@blendMode;
};
if (xml.@cacheAsBitmap.length()){
this.cacheAsBitmap = (xml.@cacheAsBitmap.toString() == "true");
};
if (xml.@rotateDirection.length()){
this.rotateDirection = xml.@rotateDirection;
};
if (xml.@rotateTimes.length()){
this.rotateTimes = parseInt(xml.@rotateTimes);
};
if (xml.@orientToPath.length()){
this.orientToPath = (xml.@orientToPath.toString() == "true");
};
if (xml.@blank.length()){
this.blank = (xml.@blank.toString() == "true");
};
tweenableNames = ["x", "y", "scaleX", "scaleY", "rotation", "skewX", "skewY"];
for each (tweenableName in tweenableNames) {
attribute = xml.attribute(tweenableName)[0];
if (!attribute){
} else {
attributeValue = attribute.toString();
if (attributeValue){
this[tweenableName] = Number(attributeValue);
};
};
};
elements = xml.elements();
filtersArray = [];
for each (child in elements) {
name = child.localName();
if (name == "tweens"){
tweenChildren = child.elements();
for each (tweenChild in tweenChildren) {
tweenName = tweenChild.localName();
if (tweenName == "SimpleEase"){
this.tweens.push(new SimpleEase(tweenChild));
} else {
if (tweenName == "CustomEase"){
this.tweens.push(new CustomEase(tweenChild));
} else {
if (tweenName == "BezierEase"){
this.tweens.push(new BezierEase(tweenChild));
} else {
if (tweenName == "FunctionEase"){
this.tweens.push(new FunctionEase(tweenChild));
};
};
};
};
};
} else {
if (name == "filters"){
filtersChildren = child.elements();
for each (filterXML in filtersChildren) {
filterName = filterXML.localName();
filterClassName = ("flash.filters." + filterName);
if (filterName == "AdjustColorFilter"){
} else {
filterClass = getDefinitionByName(filterClassName);
filterInstance = new (filterClass);
filterTypeInfo = describeType(filterInstance);
accessorList = filterTypeInfo.accessor;
ratios = [];
for each (attrib in filterXML.attributes()) {
attribName = attrib.localName();
accessor = accessorList.(@name == attribName)[0];
attribType = accessor.@type;
attribValue = attrib.toString();
if (attribType == "int"){
filterInstance[attribName] = parseInt(attribValue);
} else {
if (attribType == "uint"){
filterInstance[attribName] = (parseInt(attribValue) as uint);
uintValue = (parseInt(attribValue) as uint);
} else {
if (attribType == "Number"){
filterInstance[attribName] = Number(attribValue);
} else {
if (attribType == "Boolean"){
filterInstance[attribName] = (attribValue == "true");
} else {
if (attribType == "Array"){
attribValue = attribValue.substring(1, (attribValue.length - 1));
valuesArray = null;
if ((((attribName == "ratios")) || ((attribName == "colors")))){
valuesArray = splitUint(attribValue);
} else {
if (attribName == "alphas"){
valuesArray = splitNumber(attribValue);
};
};
if (attribName == "ratios"){
ratios = valuesArray;
} else {
if (valuesArray){
filterInstance[attribName] = valuesArray;
};
};
} else {
if (attribType == "String"){
filterInstance[attribName] = attribValue;
};
};
};
};
};
};
};
if (ratios.length){
filterInstance["ratios"] = ratios;
};
filtersArray.push(filterInstance);
};
};
} else {
if (name == "color"){
this.color = Color.fromXML(child);
};
};
};
this.filters = filtersArray;
};
return (this);
}
public function set rotation(_arg1:Number):void{
if (((isNaN(this.skewX)) || (isNaN(this.skewY)))){
this.skewX = _arg1;
} else {
this.skewX = (this.skewX + (_arg1 - this.skewY));
};
this.skewY = _arg1;
}
public function get rotation():Number{
return (this.skewY);
}
private static function splitNumber(_arg1:String):Array{
var _local2:Array;
var _local3:int;
_local2 = _arg1.split(",");
_local3 = 0;
while (_local3 < _local2.length) {
_local2[_local3] = Number(_local2[_local3]);
_local3++;
};
return (_local2);
}
private static function splitUint(_arg1:String):Array{
var _local2:Array;
var _local3:int;
_local2 = _arg1.split(",");
_local3 = 0;
while (_local3 < _local2.length) {
_local2[_local3] = (parseInt(_local2[_local3]) as uint);
_local3++;
};
return (_local2);
}
private static function splitInt(_arg1:String):Array{
var _local2:Array;
var _local3:int;
_local2 = _arg1.split(",");
_local3 = 0;
while (_local3 < _local2.length) {
_local2[_local3] = (parseInt(_local2[_local3]) as int);
_local3++;
};
return (_local2);
}
}
}//package fl.motion
Section 32
//MatrixTransformer (fl.motion.MatrixTransformer)
package fl.motion {
import flash.geom.*;
public class MatrixTransformer {
public static function getSkewY(_arg1:Matrix):Number{
return ((Math.atan2(_arg1.b, _arg1.a) * (180 / Math.PI)));
}
public static function getScaleX(_arg1:Matrix):Number{
return (Math.sqrt(((_arg1.a * _arg1.a) + (_arg1.b * _arg1.b))));
}
public static function getScaleY(_arg1:Matrix):Number{
return (Math.sqrt(((_arg1.c * _arg1.c) + (_arg1.d * _arg1.d))));
}
public static function setSkewXRadians(_arg1:Matrix, _arg2:Number):void{
var _local3:Number;
_local3 = getScaleY(_arg1);
_arg1.c = (-(_local3) * Math.sin(_arg2));
_arg1.d = (_local3 * Math.cos(_arg2));
}
public static function setRotation(_arg1:Matrix, _arg2:Number):void{
setRotationRadians(_arg1, (_arg2 * (Math.PI / 180)));
}
public static function rotateAroundInternalPoint(_arg1:Matrix, _arg2:Number, _arg3:Number, _arg4:Number):void{
var _local5:Point;
_local5 = new Point(_arg2, _arg3);
_local5 = _arg1.transformPoint(_local5);
_arg1.tx = (_arg1.tx - _local5.x);
_arg1.ty = (_arg1.ty - _local5.y);
_arg1.rotate((_arg4 * (Math.PI / 180)));
_arg1.tx = (_arg1.tx + _local5.x);
_arg1.ty = (_arg1.ty + _local5.y);
}
public static function setSkewX(_arg1:Matrix, _arg2:Number):void{
setSkewXRadians(_arg1, (_arg2 * (Math.PI / 180)));
}
public static function setSkewY(_arg1:Matrix, _arg2:Number):void{
setSkewYRadians(_arg1, (_arg2 * (Math.PI / 180)));
}
public static function setScaleX(_arg1:Matrix, _arg2:Number):void{
var _local3:Number;
var _local4:Number;
var _local5:Number;
_local3 = getScaleX(_arg1);
if (_local3){
_local4 = (_arg2 / _local3);
_arg1.a = (_arg1.a * _local4);
_arg1.b = (_arg1.b * _local4);
} else {
_local5 = getSkewYRadians(_arg1);
_arg1.a = (Math.cos(_local5) * _arg2);
_arg1.b = (Math.sin(_local5) * _arg2);
};
}
public static function setScaleY(_arg1:Matrix, _arg2:Number):void{
var _local3:Number;
var _local4:Number;
var _local5:Number;
_local3 = getScaleY(_arg1);
if (_local3){
_local4 = (_arg2 / _local3);
_arg1.c = (_arg1.c * _local4);
_arg1.d = (_arg1.d * _local4);
} else {
_local5 = getSkewXRadians(_arg1);
_arg1.c = (-(Math.sin(_local5)) * _arg2);
_arg1.d = (Math.cos(_local5) * _arg2);
};
}
public static function setRotationRadians(_arg1:Matrix, _arg2:Number):void{
var _local3:Number;
var _local4:Number;
_local3 = getRotationRadians(_arg1);
_local4 = getSkewXRadians(_arg1);
setSkewXRadians(_arg1, ((_local4 + _arg2) - _local3));
setSkewYRadians(_arg1, _arg2);
}
public static function setSkewYRadians(_arg1:Matrix, _arg2:Number):void{
var _local3:Number;
_local3 = getScaleX(_arg1);
_arg1.a = (_local3 * Math.cos(_arg2));
_arg1.b = (_local3 * Math.sin(_arg2));
}
public static function getSkewX(_arg1:Matrix):Number{
return ((Math.atan2(-(_arg1.c), _arg1.d) * (180 / Math.PI)));
}
public static function getSkewYRadians(_arg1:Matrix):Number{
return (Math.atan2(_arg1.b, _arg1.a));
}
public static function getSkewXRadians(_arg1:Matrix):Number{
return (Math.atan2(-(_arg1.c), _arg1.d));
}
public static function getRotation(_arg1:Matrix):Number{
return ((getRotationRadians(_arg1) * (180 / Math.PI)));
}
public static function rotateAroundExternalPoint(_arg1:Matrix, _arg2:Number, _arg3:Number, _arg4:Number):void{
_arg1.tx = (_arg1.tx - _arg2);
_arg1.ty = (_arg1.ty - _arg3);
_arg1.rotate((_arg4 * (Math.PI / 180)));
_arg1.tx = (_arg1.tx + _arg2);
_arg1.ty = (_arg1.ty + _arg3);
}
public static function getRotationRadians(_arg1:Matrix):Number{
return (getSkewYRadians(_arg1));
}
public static function matchInternalPointWithExternal(_arg1:Matrix, _arg2:Point, _arg3:Point):void{
var _local4:Point;
var _local5:Number;
var _local6:Number;
_local4 = _arg1.transformPoint(_arg2);
_local5 = (_arg3.x - _local4.x);
_local6 = (_arg3.y - _local4.y);
_arg1.tx = (_arg1.tx + _local5);
_arg1.ty = (_arg1.ty + _local6);
}
}
}//package fl.motion
Section 33
//Motion (fl.motion.Motion)
package fl.motion {
import flash.utils.*;
import flash.geom.*;
import flash.filters.*;
public class Motion {
private var _keyframesCompact:Array;
public var keyframes:Array;
public var source:Source;
private var _duration:int;// = 0
private static var typeCache:Object = {};
public function Motion(_arg1:XML=null){
var _local2:Keyframe;
_duration = 0;
super();
this.keyframes = [];
this.parseXML(_arg1);
if (!this.source){
this.source = new Source();
};
if (this.duration == 0){
_local2 = new Keyframe();
_local2.index = 0;
this.addKeyframe(_local2);
};
}
public function getFilters(_arg1:Number):Array{
var _local2:Array;
var _local3:Keyframe;
var _local4:Array;
var _local5:Number;
var _local6:ITween;
var _local7:Keyframe;
var _local8:Array;
var _local9:Number;
var _local10:Number;
_local2 = null;
_local3 = this.getCurrentKeyframe(_arg1, "filters");
if (((!(_local3)) || (!(_local3.filters.length)))){
return ([]);
};
_local4 = _local3.filters;
_local5 = (_arg1 - _local3.index);
_local6 = ((_local3.getTween("filters")) || (_local3.getTween()));
if ((((_local5 == 0)) || (!(_local6)))){
_local2 = _local4;
} else {
if (_local6){
_local7 = this.getNextKeyframe(_arg1, "filters");
if (((!(_local7)) || (!(_local7.filters.length)))){
_local2 = _local4;
} else {
_local8 = _local7.filters;
_local9 = (_local7.index - _local3.index);
_local10 = _local6.getValue(_local5, 0, 1, _local9);
_local2 = interpolateFilters(_local4, _local8, _local10);
};
};
};
return (_local2);
}
public function getCurrentKeyframe(_arg1:int, _arg2:String=""):Keyframe{
var _local3:int;
var _local4:Keyframe;
if (((((isNaN(_arg1)) || ((_arg1 < 0)))) || ((_arg1 > (this.duration - 1))))){
return (null);
};
_local3 = _arg1;
while (_local3 > 0) {
_local4 = this.keyframes[_local3];
if (((_local4) && (_local4.affectsTweenable(_arg2)))){
return (_local4);
};
_local3--;
};
return (this.keyframes[0]);
}
public function get duration():int{
if (this._duration < this.keyframes.length){
this._duration = this.keyframes.length;
};
return (this._duration);
}
public function get keyframesCompact():Array{
var _local1:Keyframe;
this._keyframesCompact = [];
for each (_local1 in this.keyframes) {
if (_local1){
this._keyframesCompact.push(_local1);
};
};
return (this._keyframesCompact);
}
private function parseXML(_arg1:XML):Motion{
var _local2:XMLList;
var _local3:Number;
var _local4:XML;
var _local5:XML;
if (!_arg1){
return (this);
};
if (_arg1.@duration.length()){
this._duration = parseInt(_arg1.@duration);
};
_local2 = _arg1.elements();
_local3 = 0;
while (_local3 < _local2.length()) {
_local4 = _local2[_local3];
if (_local4.localName() == "source"){
_local5 = _local4.children()[0];
this.source = new Source(_local5);
} else {
if (_local4.localName() == "Keyframe"){
this.addKeyframe(new Keyframe(_local4));
};
};
_local3++;
};
return (this);
}
public function set duration(_arg1:int):void{
if (_arg1 < this.keyframes.length){
_arg1 = this.keyframes.length;
};
this._duration = _arg1;
}
private function indexOutOfRange(_arg1:int):Boolean{
return (((((isNaN(_arg1)) || ((_arg1 < 0)))) || ((_arg1 > (this.duration - 1)))));
}
public function addKeyframe(_arg1:Keyframe):void{
this.keyframes[_arg1.index] = _arg1;
if (this.duration < this.keyframes.length){
this.duration = this.keyframes.length;
};
}
public function setValue(_arg1:int, _arg2:String, _arg3:Number):void{
var _local4:Keyframe;
if (_arg1 == 0){
return;
};
_local4 = this.keyframes[_arg1];
if (!_local4){
_local4 = new Keyframe();
_local4.index = _arg1;
this.addKeyframe(_local4);
};
_local4.setValue(_arg2, _arg3);
}
public function getNextKeyframe(_arg1:int, _arg2:String=""):Keyframe{
var _local3:int;
var _local4:Keyframe;
if (((((isNaN(_arg1)) || ((_arg1 < 0)))) || ((_arg1 > (this.duration - 1))))){
return (null);
};
_local3 = (_arg1 + 1);
while (_local3 < this.keyframes.length) {
_local4 = this.keyframes[_local3];
if (((_local4) && (_local4.affectsTweenable(_arg2)))){
return (_local4);
};
_local3++;
};
return (null);
}
public function getValue(_arg1:Number, _arg2:String):Number{
var _local3:Number;
var _local4:Keyframe;
var _local5:Number;
var _local6:Number;
var _local7:ITween;
var _local8:String;
var _local9:Keyframe;
var _local10:Number;
var _local11:Number;
var _local12:Number;
_local3 = NaN;
_local4 = this.getCurrentKeyframe(_arg1, _arg2);
if (((!(_local4)) || (_local4.blank))){
return (NaN);
};
_local5 = _local4.getValue(_arg2);
if (((isNaN(_local5)) && ((_local4.index > 0)))){
_local5 = this.getValue((_local4.index - 1), _arg2);
};
if (isNaN(_local5)){
return (NaN);
};
_local6 = (_arg1 - _local4.index);
if (_local6 == 0){
return (_local5);
};
_local7 = ((_local4.getTween(_arg2)) || (_local4.getTween()));
if (((((!(_local7)) || (((!(_local4.tweenScale)) && ((((_arg2 == Tweenables.SCALE_X)) || ((_arg2 == Tweenables.SCALE_Y)))))))) || ((((_local4.rotateDirection == RotateDirection.NONE)) && ((((((_arg2 == Tweenables.ROTATION)) || ((_arg2 == Tweenables.SKEW_X)))) || ((_arg2 == Tweenables.SKEW_Y)))))))){
return (_local5);
};
_local8 = _arg2;
if (_local7.target == ""){
_local8 = "";
};
_local9 = this.getNextKeyframe(_arg1, _local8);
if (((!(_local9)) || (_local9.blank))){
return (_local5);
};
_local10 = _local9.getValue(_arg2);
if (isNaN(_local10)){
_local10 = _local5;
};
_local11 = (_local10 - _local5);
if ((((((_arg2 == Tweenables.SKEW_X)) || ((_arg2 == Tweenables.SKEW_Y)))) || ((_arg2 == Tweenables.ROTATION)))){
if (_local4.rotateDirection == RotateDirection.AUTO){
_local11 = (_local11 % 360);
if (_local11 > 180){
_local11 = (_local11 - 360);
} else {
if (_local11 < -180){
_local11 = (_local11 + 360);
};
};
} else {
if (_local4.rotateDirection == RotateDirection.CW){
if (_local11 < 0){
_local11 = ((_local11 % 360) + 360);
};
_local11 = (_local11 + (_local4.rotateTimes * 360));
} else {
if (_local11 > 0){
_local11 = ((_local11 % 360) - 360);
};
_local11 = (_local11 - (_local4.rotateTimes * 360));
};
};
};
_local12 = (_local9.index - _local4.index);
_local3 = _local7.getValue(_local6, _local5, _local11, _local12);
return (_local3);
}
public function set keyframesCompact(_arg1:Array):void{
var _local2:Keyframe;
this._keyframesCompact = _arg1.concat();
this.keyframes = [];
for each (_local2 in this._keyframesCompact) {
this.addKeyframe(_local2);
};
}
public function getColorTransform(_arg1:int):ColorTransform{
var _local2:ColorTransform;
var _local3:Keyframe;
var _local4:ColorTransform;
var _local5:Number;
var _local6:ITween;
var _local7:Keyframe;
var _local8:ColorTransform;
var _local9:Number;
var _local10:Number;
_local2 = null;
_local3 = this.getCurrentKeyframe(_arg1, "color");
if (((!(_local3)) || (!(_local3.color)))){
return (null);
};
_local4 = _local3.color;
_local5 = (_arg1 - _local3.index);
_local6 = ((((_local3.getTween("color")) || (_local3.getTween("alpha")))) || (_local3.getTween()));
if ((((_local5 == 0)) || (!(_local6)))){
_local2 = _local4;
} else {
if (_local6){
_local7 = this.getNextKeyframe(_arg1, "color");
if (((!(_local7)) || (!(_local7.color)))){
_local2 = _local4;
} else {
_local8 = _local7.color;
_local9 = (_local7.index - _local3.index);
_local10 = _local6.getValue(_local5, 0, 1, _local9);
_local2 = Color.interpolateTransform(_local4, _local8, _local10);
};
};
};
return (_local2);
}
private static function getTypeInfo(_arg1):XML{
var _local2:String;
_local2 = "";
if ((_arg1 is String)){
_local2 = _arg1;
} else {
_local2 = getQualifiedClassName(_arg1);
};
if ((_local2 in typeCache)){
return (typeCache[_local2]);
};
if ((_arg1 is String)){
_arg1 = getDefinitionByName(_arg1);
};
return ((typeCache[_local2] = describeType(_arg1)));
}
public static function interpolateFilter(_arg1:BitmapFilter, _arg2:BitmapFilter, _arg3:Number):BitmapFilter{
var _local4:Number;
var _local5:BitmapFilter;
var _local6:XML;
var _local7:XMLList;
var _local8:XML;
var _local9:String;
var _local10:String;
var _local11:uint;
var _local12:uint;
var _local13:uint;
var _local14:Array;
var _local15:Array;
var _local16:Array;
var _local17:int;
var _local18:int;
var _local19:int;
var _local20:int;
var _local21:int;
var _local22:Number;
var _local23:uint;
var _local24:Number;
var _local25:int;
var _local26:Number;
var _local27:uint;
var _local28:Number;
var _local29:int;
var _local30:uint;
var _local31:Number;
if (((!(_arg2)) || (!((_arg1["constructor"] == _arg2["constructor"]))))){
return (_arg1);
};
if (_arg3 > 1){
_arg3 = 1;
} else {
if (_arg3 < 0){
_arg3 = 0;
};
};
_local4 = (1 - _arg3);
_local5 = _arg1.clone();
_local6 = getTypeInfo(_arg1);
_local7 = _local6.accessor;
for each (_local8 in _local7) {
_local9 = _local8.@name.toString();
_local10 = _local8.@type;
if ((((_local10 == "Number")) || ((_local10 == "int")))){
_local5[_local9] = ((_arg1[_local9] * _local4) + (_arg2[_local9] * _arg3));
} else {
if (_local10 == "uint"){
switch (_local9){
case "color":
case "highlightColor":
case "shadowColor":
_local11 = _arg1[_local9];
_local12 = _arg2[_local9];
_local13 = Color.interpolateColor(_local11, _local12, _arg3);
_local5[_local9] = _local13;
break;
default:
_local5[_local9] = ((_arg1[_local9] * _local4) + (_arg2[_local9] * _arg3));
break;
};
};
};
};
if ((((_arg1 is GradientGlowFilter)) || ((_arg1 is GradientBevelFilter)))){
_local14 = [];
_local15 = [];
_local16 = [];
_local17 = _arg1["ratios"].length;
_local18 = _arg2["ratios"].length;
_local19 = Math.max(_local17, _local18);
_local20 = 0;
while (_local20 < _local19) {
_local21 = Math.min(_local20, (_local17 - 1));
_local22 = _arg1["ratios"][_local21];
_local23 = _arg1["colors"][_local21];
_local24 = _arg1["alphas"][_local21];
_local25 = Math.min(_local20, (_local18 - 1));
_local26 = _arg2["ratios"][_local25];
_local27 = _arg2["colors"][_local25];
_local28 = _arg2["alphas"][_local25];
_local29 = ((_local22 * _local4) + (_local26 * _arg3));
_local30 = Color.interpolateColor(_local23, _local27, _arg3);
_local31 = ((_local24 * _local4) + (_local28 * _arg3));
_local14[_local20] = _local29;
_local15[_local20] = _local30;
_local16[_local20] = _local31;
_local20++;
};
_local5["colors"] = _local15;
_local5["alphas"] = _local16;
_local5["ratios"] = _local14;
};
return (_local5);
}
public static function interpolateFilters(_arg1:Array, _arg2:Array, _arg3:Number):Array{
var _local4:Array;
var _local5:int;
var _local6:BitmapFilter;
var _local7:BitmapFilter;
var _local8:BitmapFilter;
if (_arg1.length != _arg2.length){
return (null);
};
_local4 = [];
_local5 = 0;
while (_local5 < _arg1.length) {
_local6 = _arg1[_local5];
_local7 = _arg2[_local5];
_local8 = interpolateFilter(_local6, _local7, _arg3);
if (_local8){
_local4.push(_local8);
};
_local5++;
};
return (_local4);
}
public static function fromXMLString(_arg1:String):Motion{
var _local2:XML;
_local2 = new XML(_arg1);
return (new Motion(_local2));
}
}
}//package fl.motion
Section 34
//MotionEvent (fl.motion.MotionEvent)
package fl.motion {
import flash.events.*;
public class MotionEvent extends Event {
public static const MOTION_UPDATE:String = "motionUpdate";
public static const TIME_CHANGE:String = "timeChange";
public static const MOTION_START:String = "motionStart";
public static const MOTION_END:String = "motionEnd";
public function MotionEvent(_arg1:String, _arg2:Boolean=false, _arg3:Boolean=false){
super(_arg1, _arg2, _arg3);
}
override public function clone():Event{
return (new MotionEvent(this.type, this.bubbles, this.cancelable));
}
}
}//package fl.motion
Section 35
//RotateDirection (fl.motion.RotateDirection)
package fl.motion {
public class RotateDirection {
public static const CW:String = "cw";
public static const CCW:String = "ccw";
public static const NONE:String = "none";
public static const AUTO:String = "auto";
}
}//package fl.motion
Section 36
//SimpleEase (fl.motion.SimpleEase)
package fl.motion {
public class SimpleEase implements ITween {
private var _ease:Number;// = 0
private var _target:String;// = ""
public function SimpleEase(_arg1:XML=null){
_ease = 0;
_target = "";
super();
this.parseXML(_arg1);
}
public function set target(_arg1:String):void{
this._target = _arg1;
}
private function parseXML(_arg1:XML=null):SimpleEase{
if (_arg1){
if (_arg1.@ease.length()){
this.ease = Number(_arg1.@ease);
};
};
return (this);
}
public function get ease():Number{
return (this._ease);
}
public function get target():String{
return (this._target);
}
public function getValue(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return (easeQuadPercent(_arg1, _arg2, _arg3, _arg4, this.ease));
}
public function set ease(_arg1:Number):void{
this._ease = ((_arg1 > 1)) ? 1 : ((_arg1 < -1)) ? -1 : (isNaN(_arg1)) ? 0 : _arg1;
}
public static function easeQuadPercent(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number):Number{
if (_arg4 <= 0){
return (NaN);
};
if (_arg1 <= 0){
return (_arg2);
};
_arg1 = (_arg1 / _arg4);
if (_arg1 >= 1){
return ((_arg2 + _arg3));
};
if (!_arg5){
return (((_arg3 * _arg1) + _arg2));
};
if (_arg5 > 1){
_arg5 = 1;
} else {
if (_arg5 < -1){
_arg5 = -1;
};
};
if (_arg5 < 0){
return ((((_arg3 * _arg1) * ((_arg1 * -(_arg5)) + (1 + _arg5))) + _arg2));
};
return ((((_arg3 * _arg1) * (((2 - _arg1) * _arg5) + (1 - _arg5))) + _arg2));
}
public static function easeNone(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg4 <= 0){
return (NaN);
};
if (_arg1 <= 0){
return (_arg2);
};
if (_arg1 >= _arg4){
return ((_arg2 + _arg3));
};
return ((((_arg3 * _arg1) / _arg4) + _arg2));
}
}
}//package fl.motion
Section 37
//Source (fl.motion.Source)
package fl.motion {
import flash.geom.*;
public class Source {
public var instanceName:String;// = ""
public var symbolName:String;// = ""
public var dimensions:Rectangle;
public var scaleX:Number;// = 1
public var skewY:Number;// = 0
public var skewX:Number;// = 0
public var scaleY:Number;// = 1
public var elementType:String;// = ""
public var transformationPoint:Point;
public var linkageID:String;// = ""
public var frameRate:Number;// = NAN
public var x:Number;// = 0
public var y:Number;// = 0
public var rotation:Number;// = 0
public function Source(_arg1:XML=null){
frameRate = NaN;
elementType = "";
symbolName = "";
instanceName = "";
linkageID = "";
x = 0;
y = 0;
scaleX = 1;
scaleY = 1;
skewX = 0;
skewY = 0;
rotation = 0;
super();
this.parseXML(_arg1);
}
private function parseXML(_arg1:XML=null):Source{
var _local2:XMLList;
var _local3:XML;
var _local4:XML;
var _local5:XML;
if (!_arg1){
return (this);
};
if (_arg1.@instanceName){
this.instanceName = String(_arg1.@instanceName);
};
if (_arg1.@symbolName){
this.symbolName = String(_arg1.@symbolName);
};
if (_arg1.@linkageID){
this.linkageID = String(_arg1.@linkageID);
};
if (!isNaN(_arg1.@frameRate)){
this.frameRate = Number(_arg1.@frameRate);
};
_local2 = _arg1.elements();
for each (_local3 in _local2) {
if (_local3.localName() == "transformationPoint"){
_local4 = _local3.children()[0];
this.transformationPoint = new Point(Number(_local4.@x), Number(_local4.@y));
} else {
if (_local3.localName() == "dimensions"){
_local5 = _local3.children()[0];
this.dimensions = new Rectangle(Number(_local5.@left), Number(_local5.@top), Number(_local5.@width), Number(_local5.@height));
};
};
};
return (this);
}
}
}//package fl.motion
Section 38
//Tweenables (fl.motion.Tweenables)
package fl.motion {
public class Tweenables {
public static const SCALE_X:String = "scaleX";
public static const SCALE_Y:String = "scaleY";
public static const SKEW_X:String = "skewX";
public static const SKEW_Y:String = "skewY";
public static const X:String = "x";
public static const Y:String = "y";
public static const ROTATION:String = "rotation";
}
}//package fl.motion
Section 39
//ActiveX (mdm.ActiveX)
package mdm {
public final class ActiveX {
private var resolver:mdm_ActiveX;// = null
public function ActiveX(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String):void{
resolver = null;
super();
resolver = new mdm_ActiveX(_arg1, _arg2, _arg3, _arg4, _arg5);
}
public function get y():Number{
return (resolver.y);
}
public function hide(_arg1:Boolean=true):void{
resolver.hide();
}
public function loadObject(_arg1:String, _arg2:Boolean=true):void{
resolver.loadObject(_arg1);
}
public function set y(_arg1:Number):void{
resolver.y = _arg1;
}
public function doVerbInPlaceActivate(_arg1:Boolean=true):void{
resolver.doVerbInPlaceActivate();
}
public function runMethod(_arg1:String, _arg2:Number, _arg3:Boolean=true):void{
resolver.runMethod(_arg1, _arg2);
}
public function get width():Number{
return (resolver.width);
}
public function set height(_arg1:Number):void{
resolver.height = _arg1;
}
public function addMethodParam(_arg1:Number, _arg2:String, _arg3:String, _arg4:Boolean=true):void{
resolver.addMethodParam(_arg1, _arg2, _arg3);
}
public function setProperty(_arg1:String, _arg2:String, _arg3:String, _arg4:Boolean):void{
resolver.setProperty(_arg1, _arg2, _arg3);
}
public function doVerbPrimary(_arg1:Boolean=true):void{
resolver.doVerbPrimary();
}
public function getProperty(_arg1:String):String{
return (resolver.getProperty(_arg1));
}
public function doVerbCustom(_arg1:String, _arg2:Boolean=true):void{
resolver.doVerbCustom(_arg1);
}
public function saveObject(_arg1:String, _arg2:Boolean=true):void{
resolver.saveObject(_arg1);
}
public function set width(_arg1:Number):void{
resolver.width = _arg1;
}
public function set visible(_arg1:Boolean):void{
resolver.visible = _arg1;
}
public function doVerbShow(_arg1:Boolean=true):void{
resolver.doVerbShow();
}
public function doVerbHide(_arg1:Boolean=true):void{
resolver.doVerbHide();
}
public function get height():Number{
return (resolver.height);
}
public function set x(_arg1:Number):void{
resolver.x = _arg1;
}
public function doVerbUIActivate(_arg1:Boolean=true):void{
resolver.doVerbUIActivate();
}
public function get visible():Boolean{
return (resolver.visible);
}
public function doVerbOpen(_arg1:Boolean=true):void{
resolver.doVerbOpen();
}
public function runMethodRet(_arg1:String, _arg2:Number):String{
return (resolver.runMethodRet(_arg1, _arg2));
}
public function close(_arg1:Boolean=true):void{
resolver.close();
}
public function doVerbDiscardUndoState(_arg1:Boolean=true):void{
resolver.doVerbDiscardUndoState();
}
public function saveDoc(_arg1:String, _arg2:Boolean=true):void{
resolver.saveDoc(_arg1);
}
public function show(_arg1:Boolean=true):void{
resolver.show();
}
public function get x():Number{
return (resolver.x);
}
}
}//package mdm
dynamic class mdm_ActiveX extends mdm_resolver {
private function mdm_ActiveX(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String):void{
var _local6:Array;
super();
SetClassName("mdm.ActiveX");
_local6 = new Array();
_local6.push(-1, _arg1, _arg2, _arg3, _arg4, _arg5);
SetDynamic(CallSync("create", _local6));
}
}
Section 40
//Alert2 (mdm.Alert2)
package mdm {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.geom.*;
import flash.filters.*;
public final class Alert2 {
private static var btnWidth:int = 45;
private static var btnHeight:int = 21;
private static var stage:Stage;
private static function createBtn(_arg1:int):SimpleButton{
var _local2:Array;
var _local3:Array;
var _local4:Array;
var _local5:Matrix;
var _local6:Sprite;
var _local7:Sprite;
var _local8:Sprite;
var _local9:SimpleButton;
_local2 = new Array();
_local3 = new Array(1, 1, 1);
_local4 = new Array(0, 128, 0xFF);
_local5 = new Matrix();
_local5.createGradientBox(btnWidth, btnHeight, (Math.PI / 2), 0, 0);
_local6 = new Sprite();
_local2 = [0xFFFFFF, _arg1, 0xFFFFFF];
_local6.graphics.lineStyle(1);
_local6.graphics.beginGradientFill(GradientType.LINEAR, _local2, _local3, _local4, _local5);
_local6.graphics.drawRect(0, 0, btnWidth, btnHeight);
_local6.addChild(getTextField("OK", true));
_local7 = new Sprite();
_local2 = [0xFFFFFF, brightenColour(_arg1, 50), 0xFFFFFF];
_local7.graphics.lineStyle(1);
_local7.graphics.beginGradientFill(GradientType.LINEAR, _local2, _local3, _local4, _local5);
_local7.graphics.drawRect(0, 0, btnWidth, btnHeight);
_local7.addChild(getTextField("OK", true));
_local8 = new Sprite();
_local2 = [0, brightenColour(_arg1, 50), 0];
_local8.graphics.lineStyle(1);
_local8.graphics.beginGradientFill(GradientType.LINEAR, _local2, _local3, _local4, _local5);
_local8.graphics.drawRect(0, 0, btnWidth, btnHeight);
_local8.addChild(getTextField("OK", true));
_local9 = new SimpleButton(_local6, _local7, _local8, _local7);
return (_local9);
}
private static function doStopDrag(_arg1:MouseEvent):void{
if (_arg1.target.name != "textfield"){
if (_arg1.target.name == "alert"){
_arg1.target.stopDrag();
};
};
}
private static function closeAlert(_arg1:MouseEvent):void{
var _local2:*;
var _local3:*;
var _local4:Sprite;
_local2 = _arg1.target;
_local2.removeEventListener(MouseEvent.CLICK, closeAlert);
_local3 = _arg1.target.parent;
_local3.removeEventListener(MouseEvent.CLICK, doStartDrag);
_local3.removeEventListener(MouseEvent.CLICK, doStopDrag);
_local4 = _arg1.target.parent.parent.parent;
removeBlockingListeners(_local4);
_local4.parent.removeChild(_local4);
}
private static function createPrompt(_arg1:String, _arg2:int):Sprite{
var _local3:Sprite;
_local3 = new Sprite();
_local3.addEventListener(MouseEvent.MOUSE_DOWN, doStartDrag);
_local3.addEventListener(MouseEvent.MOUSE_UP, doStopDrag);
_local3.addChild(getPrompt(_arg1, _arg2));
_local3.x = ((stage.stageWidth / 2) - (_local3.width / 2));
_local3.y = ((stage.stageHeight / 2) - (_local3.height / 2));
_local3.filters = [getFilter(_arg2), getBlurFilter(_arg2)];
return (_local3);
}
private static function brightenColour(_arg1:int, _arg2:int):int{
var _local3:Array;
var _local4:int;
var _local5:int;
var _local6:int;
_local3 = hexToRGB(_arg1);
_local4 = keepInBounds((_local3[0] + _arg2));
_local5 = keepInBounds((_local3[1] + _arg2));
_local6 = keepInBounds((_local3[2] + _arg2));
return (RGBToHex(_local4, _local5, _local6));
}
public static function init(_arg1:Stage):void{
stage = _arg1;
}
private static function createBackground(_arg1:int):Sprite{
var _local2:BitmapData;
var _local3:Bitmap;
var _local4:Sprite;
_local2 = new BitmapData(stage.stageWidth, stage.stageHeight, true, (4278190080 + _arg1));
_local3 = new Bitmap(_local2);
_local4 = new Sprite();
_local4.addChild(_local3);
_local4.alpha = 0.3;
return (_local4);
}
private static function assignListeners(_arg1:Sprite, _arg2:Function, _arg3:Boolean):void{
var Background:*;
var Prompt:*;
var OKbutton:*;
var myFunction:Function;
var myAlert = _arg1;
var callback = _arg2;
var blockMouse = _arg3;
Background = myAlert.getChildAt(1);
Prompt = Background.getChildAt(0);
OKbutton = Prompt.getChildAt(2);
if (callback != null){
myFunction = function (_arg1:MouseEvent):void{
OKbutton.removeEventListener(MouseEvent.CLICK, myFunction);
closeAlert(_arg1);
callback();
};
OKbutton.addEventListener(MouseEvent.CLICK, myFunction);
} else {
OKbutton.addEventListener(MouseEvent.CLICK, closeAlert);
};
if (blockMouse){
myAlert.addEventListener(MouseEvent.CLICK, stopEvents);
myAlert.doubleClickEnabled = true;
myAlert.addEventListener(MouseEvent.DOUBLE_CLICK, stopEvents);
myAlert.addEventListener(MouseEvent.MOUSE_MOVE, stopEvents);
myAlert.addEventListener(MouseEvent.MOUSE_DOWN, stopEvents);
myAlert.addEventListener(MouseEvent.MOUSE_OUT, stopEvents);
myAlert.addEventListener(MouseEvent.MOUSE_OVER, stopEvents);
myAlert.addEventListener(MouseEvent.MOUSE_UP, stopEvents);
myAlert.addEventListener(MouseEvent.MOUSE_WHEEL, stopEvents);
myAlert.addEventListener(MouseEvent.ROLL_OUT, stopEvents);
myAlert.addEventListener(MouseEvent.ROLL_OVER, stopEvents);
};
}
private static function getPrompt(_arg1:String, _arg2:int):Sprite{
var _local3:Sprite;
var _local4:TextField;
var _local5:*;
var _local6:*;
var _local7:BitmapData;
var _local8:Bitmap;
var _local9:SimpleButton;
_local3 = new Sprite();
_local3.addEventListener(MouseEvent.MOUSE_DOWN, doStartDrag);
_local3.addEventListener(MouseEvent.MOUSE_UP, doStopDrag);
_local3.name = "alert";
_local4 = getTextField(_arg1);
_local5 = (_local4.width + 10);
_local6 = (_local4.height + 55);
if (_local5 < 150){
_local5 = 150;
};
if (_local6 < 100){
_local6 = 100;
};
if (_local6 > stage.stageHeight){
_local6 = (stage.stageHeight - 20);
_local4.autoSize = TextFieldAutoSize.NONE;
_local4.height = (stage.stageHeight - 40);
};
_local7 = new BitmapData(_local5, _local6, true, (4278190080 + _arg2));
_local8 = new Bitmap(_local7);
_local3.addChild(_local8);
_local4.x = ((_local3.width / 2) - (_local4.width / 2));
_local4.y = (((_local3.height / 2) - (_local4.height / 2)) - 10);
_local3.addChild(_local4);
_local9 = createBtn(_arg2);
_local9.x = ((_local3.width / 2) - (_local9.width / 2));
_local9.y = (_local3.height - 35);
_local3.addChild(_local9);
return (_local3);
}
private static function getTextField(_arg1:String, _arg2:Boolean=false):TextField{
var _local3:TextField;
_local3 = new TextField();
_local3.name = "textfield";
_local3.multiline = true;
_local3.selectable = false;
_local3.autoSize = TextFieldAutoSize.CENTER;
if (_arg2){
_arg1 = (("<b>" + _arg1) + "</b>");
};
_local3.htmlText = (("<font face=\"Verdana\">" + _arg1) + "</font>");
_local3.x = ((btnWidth / 2) - (_local3.width / 2));
_local3.y = ((btnHeight / 2) - (_local3.height / 2));
return (_local3);
}
private static function keepInBounds(_arg1:int):int{
if (_arg1 < 0){
_arg1 = 0;
};
if (_arg1 > 0xFF){
_arg1 = 0xFF;
};
return (_arg1);
}
private static function removeBlockingListeners(_arg1:Sprite):void{
_arg1.removeEventListener(MouseEvent.CLICK, stopEvents);
_arg1.removeEventListener(MouseEvent.DOUBLE_CLICK, stopEvents);
_arg1.removeEventListener(MouseEvent.MOUSE_MOVE, stopEvents);
_arg1.removeEventListener(MouseEvent.MOUSE_DOWN, stopEvents);
_arg1.removeEventListener(MouseEvent.MOUSE_OUT, stopEvents);
_arg1.removeEventListener(MouseEvent.MOUSE_OVER, stopEvents);
_arg1.removeEventListener(MouseEvent.MOUSE_UP, stopEvents);
_arg1.removeEventListener(MouseEvent.MOUSE_WHEEL, stopEvents);
_arg1.removeEventListener(MouseEvent.ROLL_OUT, stopEvents);
_arg1.removeEventListener(MouseEvent.ROLL_OVER, stopEvents);
}
private static function doStartDrag(_arg1:MouseEvent):void{
if (_arg1.target.name != "textfield"){
if (_arg1.target.name == "alert"){
_arg1.target.startDrag();
};
};
}
private static function getFilter(_arg1:int){
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Boolean;
var _local8:Boolean;
var _local9:Number;
_local2 = 0xFFFFFF;
_local3 = 0.8;
_local4 = 15;
_local5 = 15;
_local6 = 0.7;
_local7 = true;
_local8 = false;
_local9 = BitmapFilterQuality.HIGH;
return (new GlowFilter(_local2, _local3, _local4, _local5, _local6, _local9, _local7, _local8));
}
private static function RGBToHex(_arg1:int, _arg2:int, _arg3:int):int{
var _local4:uint;
_local4 = ((_arg1 & 0xFF) << 16);
_local4 = (_local4 + ((_arg2 & 0xFF) << 8));
_local4 = (_local4 + (_arg3 & 0xFF));
return (_local4);
}
private static function getBlurFilter(_arg1:int){
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:Number;
var _local9:Boolean;
var _local10:Boolean;
var _local11:Number;
_local2 = 0;
_local3 = 45;
_local4 = 0.6;
_local5 = 8;
_local6 = 8;
_local7 = 4;
_local8 = 1.3;
_local9 = false;
_local10 = false;
_local11 = BitmapFilterQuality.LOW;
return (new DropShadowFilter(_local7, _local3, _local2, _local4, _local5, _local6, _local8, _local11, _local9, _local10));
}
public static function hexToRGB(_arg1:uint):Array{
var _local2:Array;
var _local3:uint;
_local2 = new Array();
_local2.push((_arg1 >> 16));
_local3 = (_arg1 ^ (_local2[0] << 16));
_local2.push((_local3 >> 8));
_local2.push((_local3 ^ (_local2[1] << 8)));
return (_local2);
}
private static function stopEvents(_arg1:MouseEvent):void{
_arg1.stopImmediatePropagation();
}
public static function show(_arg1="Made by Dark Vyper", _arg2:Function=null, _arg3:int=10380027, _arg4:Boolean=true):void{
var _local5:Sprite;
if (stage == null){
return;
};
_local5 = new Sprite();
_local5.addChild(createBackground(_arg3));
_local5.addChild(createPrompt(_arg1.toString(), _arg3));
assignListeners(_local5, _arg2, _arg4);
stage.addChild(_local5);
}
}
}//package mdm
Section 41
//AppleScript (mdm.AppleScript)
package mdm {
public final class AppleScript {
private static var resolver:mdm_AppleScript = null;
public function AppleScript():void{
}
private static function internal_resolver():mdm_AppleScript{
if (resolver == null){
resolver = new mdm_AppleScript();
};
return (resolver);
}
public static function getProperty(_arg1:String):String{
return (internal_resolver().getProperty(_arg1));
}
public static function setScript(_arg1:String):void{
internal_resolver().setScript(_arg1);
}
public static function runEvent(_arg1:String, ... _args):String{
return (internal_resolver().runEvent(_arg1, _args));
}
public static function run():Boolean{
return (internal_resolver().run());
}
public static function getResult():String{
return (internal_resolver().getResult());
}
public static function setProperty(_arg1:String, _arg2:String):void{
internal_resolver().setProperty(_arg1, _arg2);
}
public static function getCompilationError():String{
return (internal_resolver().getCompilationError());
}
public static function getLastError():String{
return (internal_resolver().getLastError());
}
public static function compileScript():Boolean{
return (internal_resolver().compileScript());
}
}
}//package mdm
dynamic class mdm_AppleScript extends mdm_resolver {
private function mdm_AppleScript():void{
SetClassName("mdm.AppleScript");
}
}
Section 42
//Application (mdm.Application)
package mdm {
public var Application:internalApplication = new internalApplication();
}//package mdm
Section 43
//ASYNC (mdm.ASYNC)
package mdm {
public var ASYNC = {async:true};
}//package mdm
Section 44
//Audio (mdm.Audio)
package mdm {
public final class Audio {
private static var resolver:mdm_Audio = null;
public function Audio():void{
}
public static function isRecording():Boolean{
return (internal_resolver().isRecording());
}
private static function internal_resolver():mdm_Audio{
if (resolver == null){
resolver = new mdm_Audio();
};
return (resolver);
}
public static function startRecordingWithAutoOff(_arg1:String, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number):void{
internal_resolver().startRecordingWithAudioOff(_arg1, _arg2, _arg3, _arg4, _arg5);
}
public static function stopRecording():void{
internal_resolver().stopRecording();
}
public static function startRecording(_arg1:String, _arg2:Number, _arg3:Number):void{
internal_resolver().startRecording(_arg1, _arg2, _arg3);
}
}
}//package mdm
dynamic class mdm_Audio extends mdm_resolver {
private function mdm_Audio():void{
SetClassName("mdm.Audio");
}
}
Section 45
//Browser (mdm.Browser)
package mdm {
public final class Browser {
private var resolver:mdm_Browser;// = null
public function Browser(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String, _arg6:Boolean=false):void{
resolver = null;
super();
resolver = new mdm_Browser(this, _arg1, _arg2, _arg3, _arg4, _arg5, _arg6);
}
public function get y():Number{
return (internal_resolver().y);
}
public function hide(_arg1:Boolean=true):void{
internal_resolver().hide();
}
public function get isBusy():Boolean{
return (internal_resolver().isBusy);
}
public function forward(_arg1:Boolean=true):void{
internal_resolver().forward();
}
public function internal_resolver():mdm_Browser{
return (resolver);
}
public function stop(_arg1:Boolean=true):void{
internal_resolver().stop();
}
public function set y(_arg1:Number):void{
internal_resolver().y = _arg1;
}
public function get width():Number{
return (internal_resolver().width);
}
public function get favorities():Array{
return (internal_resolver().favourites);
}
public function setSourceInTarget(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().setSourceInTarget(_arg1, _arg2);
}
public function printHTMLHeader(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().printHTMLHeader(_arg1);
}
public function set height(_arg1:Number):void{
internal_resolver().height = _arg1;
}
public function printMargins(_arg1:Number=1, _arg2:Number=1, _arg3:Number=1, _arg4:Number=1, _arg5:Boolean=true):void{
internal_resolver().printMargins(_arg1, _arg2, _arg3, _arg4);
}
public function printHeader(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().printHeader(_arg1);
}
public function gotoTarget(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().gotoTarget(_arg1, _arg2);
}
public function addFavorite(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().addFavourite(_arg1, _arg2);
}
public function set url(_arg1:String):void{
internal_resolver().url = _arg1;
}
public function get title():String{
return (internal_resolver().title);
}
public function printCopies(_arg1:Number, _arg2:Boolean=true):void{
internal_resolver().printCopies(_arg1);
}
public function refresh(_arg1:Boolean=true):void{
internal_resolver().refresh();
}
public function printPreview(_arg1:Boolean=true):void{
internal_resolver().printPreview();
}
public function goto(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().goto(_arg1);
}
public function set visible(_arg1:Boolean):void{
internal_resolver().visible = _arg1;
}
public function set onDocumentComplete(_arg1:Function):void{
internal_resolver().onDocumentComplete = _arg1;
}
public function back(_arg1:Boolean=true):void{
internal_resolver().back();
}
public function printFooter(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().printCopies(_arg1);
}
public function printOrientation(_arg1:String="portrait", _arg2:Boolean=true):void{
internal_resolver().printfOrientation(_arg1);
}
public function print(_arg1:Boolean=false, _arg2:Boolean=true):void{
internal_resolver().print(_arg1);
}
public function get height():Number{
return (internal_resolver().height);
}
public function get source():String{
return (internal_resolver().source);
}
public function set x(_arg1:Number):void{
internal_resolver().x = _arg1;
}
public function get visible():Boolean{
return (internal_resolver().visible);
}
public function set userAgent(_arg1:String):void{
internal_resolver().userAgent = _arg1;
}
public function set source(_arg1:String):void{
internal_resolver().source = _arg1;
}
public function close(_arg1:Boolean=true):void{
internal_resolver().close();
}
public function set width(_arg1:Number):void{
internal_resolver().width = _arg1;
}
public function show(_arg1:Boolean=true):void{
internal_resolver().show();
}
public function get url():String{
return (internal_resolver().url);
}
public function get x():Number{
return (internal_resolver().x);
}
}
}//package mdm
dynamic class mdm_Browser extends mdm_resolver {
private var m_parent:Browser;// = null
private function mdm_Browser(_arg1:Browser, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String, _arg7:Boolean):void{
var _local8:Array;
var _local9:int;
m_parent = null;
super();
SetClassName("mdm.Browser");
AddEvents();
_local8 = new Array();
_local8.push(-1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7);
SetDynamic(CallSync("create", _local8));
_local9 = m_dynamicID;
m_dynBrowsers[_local9] = _arg1;
}
private function AddEvents():void{
AddDynamicEvent("onDocumentComplete", true);
}
}
Section 46
//Clipboard (mdm.Clipboard)
package mdm {
public final class Clipboard {
private static var resolver:mdm_Clipboard = null;
public function Clipboard():void{
}
public static function paste(_arg1:Boolean=true):void{
internal_resolver().paste();
}
public static function copy(_arg1:Boolean=true):void{
internal_resolver().copy();
}
private static function internal_resolver():mdm_Clipboard{
if (resolver == null){
resolver = new mdm_Clipboard();
};
return (resolver);
}
public static function cut(_arg1:Boolean=true):void{
internal_resolver().cut();
}
public static function clear(_arg1:Boolean=true):void{
internal_resolver().clear();
}
public static function copyString(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().copyString(_arg1);
}
}
}//package mdm
dynamic class mdm_Clipboard extends mdm_resolver {
private function mdm_Clipboard():void{
SetClassName("mdm.Clipboard");
}
}
Section 47
//COMPort (mdm.COMPort)
package mdm {
public final class COMPort {
private static var resolver:mdm_COMPort = null;
public function COMPort():void{
}
public static function set onCOMPortHEXData(_arg1:Function):void{
internal_resolver().onCOMPortHEXData = _arg1;
}
public static function send(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().send(_arg1);
}
public static function set onCOMPortError(_arg1:Function):void{
internal_resolver().onCOMPortError = _arg1;
}
public static function get initialRTS():String{
return (internal_resolver().initialRTS);
}
public static function unsetRTS(_arg1:Boolean=true):void{
internal_resolver().unsetRTS();
}
public static function set onCOMPortDataSent(_arg1:Function):void{
internal_resolver().onCOMPortDataSent = _arg1;
}
public static function get ports():String{
return (internal_resolver().ports);
}
public static function set rxBuffer(_arg1:Number):void{
internal_resolver().rxBuffer = _arg1;
}
public static function setXON(_arg1:Boolean=true):void{
internal_resolver().setXON();
}
public static function unsetBreak(_arg1:Boolean=true):void{
internal_resolver().unsetBreak();
}
private static function internal_resolver():mdm_COMPort{
if (resolver == null){
resolver = new mdm_COMPort();
};
return (resolver);
}
public static function open(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:String, _arg5:Number, _arg6:String, _arg7:Boolean=true):void{
internal_resolver().open(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6);
}
public static function set onCOMPortData(_arg1:Function):void{
internal_resolver().onCOMPortData = _arg1;
}
public static function userTreshold(_arg1:Boolean, _arg2:Number, _arg3:Boolean=true):void{
internal_resolver().userTreshold(_arg1, _arg2);
}
public static function sendFileContents(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().sendFileContents(_arg1);
}
public static function sendHEXData(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().sendHEXData(_arg1);
}
public static function setDTR(_arg1:Boolean=true):void{
internal_resolver().setDTR();
}
public static function get txBuffer():Number{
return (internal_resolver().txBuffer);
}
public static function useLineMode(_arg1:Boolean, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().useLineMode(_arg1, _arg2);
}
public static function get rxBuffer():Number{
return (internal_resolver().rxBuffer);
}
public static function setEcho(_arg1:Boolean, _arg2:Boolean=true):void{
internal_resolver().setEcho(_arg1);
}
public static function set onCOMPortDSRChanged(_arg1:Function):void{
internal_resolver().onCOMPortDSRChanged = _arg1;
}
public static function set onCOMPortCTSChanged(_arg1:Function):void{
internal_resolver().onCOMPortCTSChanged = _arg1;
}
public static function setRTS(_arg1:Boolean=true):void{
internal_resolver().setRTS();
}
public static function set onCOMPortSendProgress(_arg1:Function):void{
internal_resolver().onCOMPortSendProgress = _arg1;
}
public static function setXOFF(_arg1:Boolean=true):void{
internal_resolver().setXOFF();
}
public static function set txBuffer(_arg1:Number):void{
internal_resolver().txBuffer = _arg1;
}
public static function close(_arg1:Boolean=true):void{
internal_resolver().close();
}
public static function unsetDTR(_arg1:Boolean=true):void{
internal_resolver().unsetDTR();
}
public static function setBreak(_arg1:Boolean=true):void{
internal_resolver().setBreak();
}
public static function get initialDTR():String{
return (internal_resolver().initialDTR);
}
}
}//package mdm
dynamic class mdm_COMPort extends mdm_resolver {
private function mdm_COMPort():void{
SetClassName("mdm.COMPort");
AddEvents();
}
private function AddEvents():void{
AddEvent("onCOMPortCTSChanged", true);
AddEvent("onCOMPortDSRChanged", true);
AddEvent("onCOMPortData", true);
AddEvent("onCOMPortHEXData", true);
AddEvent("onCOMPortDataSent", true);
AddEvent("onCOMPortError", true);
AddEvent("onCOMPortSendProgress", true);
}
}
Section 48
//Database (mdm.Database)
package mdm {
public final class Database {
private static var resolver:mdm_Database = null;
private static function internal_resolver():mdm_Database{
if (resolver == null){
resolver = new mdm_Database();
};
return (resolver);
}
public static function get MySQL():mdm_resolver{
return (internal_resolver().MySQL);
}
public static function get MSAccess():mdm_resolver{
return (internal_resolver().MSAccess);
}
public static function get SQLite():mdm_resolver{
return (internal_resolver().SQLite);
}
public static function get ADO():mdm_resolver{
return (internal_resolver().ADO);
}
}
}//package mdm
dynamic class mdm_Database extends mdm_resolver {
private function mdm_Database():void{
SetClassName("mdm.Database");
AddObject("ADO", null);
AddObject("MSAccess", null);
AddObject("MySQL", null);
AddObject("SQLite", null);
}
}
Section 49
//Dialogs (mdm.Dialogs)
package mdm {
public final class Dialogs {
private static var resolver:mdm_Dialogs = null;
public static function inputBox(_arg1:String, _arg2:String):String{
return (internal_resolver().inputBox(_arg1, _arg2));
}
public static function prompt(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().prompt(_arg1);
}
private static function internal_resolver():mdm_Dialogs{
if (resolver == null){
resolver = new mdm_Dialogs();
};
return (resolver);
}
public static function promptModal(_arg1:String, _arg2:String=null, _arg3:String=null, _arg4:Boolean=true):Boolean{
return (internal_resolver().promptModal(_arg1, _arg2, _arg3, _arg4));
}
public static function get BrowseFile():mdm_resolver{
return (internal_resolver().BrowseFile);
}
public static function promptAdvUnicode(_arg1:String, _arg2:String):Boolean{
return (internal_resolver().promptAdvUnicode(_arg1, _arg2));
}
public static function promptAdv(_arg1:String, _arg2:String=null):Boolean{
return (internal_resolver().promptAdv(_arg1, _arg2));
}
public static function promptModalUnicode(_arg1:String, _arg2:String, _arg3:String):Boolean{
return (internal_resolver().promptModalUnicode(_arg1, _arg2, _arg3));
}
public static function get BrowseFileUnicode():mdm_resolver{
return (internal_resolver().BrowseFileUnicode);
}
public static function get BrowseFolder():mdm_resolver{
return (internal_resolver().BrowseFolder);
}
public static function promptUnicode(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().promptUnicode(_arg1);
}
public static function get BrowseFileToSave():mdm_resolver{
return (internal_resolver().BrowseFileToSave);
}
}
}//package mdm
dynamic class mdm_Dialogs extends mdm_resolver {
private function mdm_Dialogs():void{
SetClassName("mdm.Dialogs");
AddObject("BrowseFile", null);
AddObject("BrowseFileUnicode", null);
AddObject("BrowseFileToSave", null);
AddObject("BrowseFolder", null);
}
}
Section 50
//DLL (mdm.DLL)
package mdm {
public final class DLL {
private var resolver:mdm_DLL;// = null
public function DLL(_arg1:String):void{
resolver = null;
super();
resolver = new mdm_DLL(_arg1);
}
public function close(_arg1:Boolean=true):void{
resolver.close();
}
public function addParameter(_arg1:String, _arg2:String):Number{
return (resolver.addParameter(_arg1, _arg2));
}
public function clear(_arg1:Boolean=true):void{
resolver.clear();
}
public function call(_arg1:String, _arg2:String){
return (resolver.call(_arg1, _arg2));
}
}
}//package mdm
dynamic class mdm_DLL extends mdm_resolver {
private function mdm_DLL(_arg1:String):void{
var _local2:Array;
super();
SetClassName("mdm.DLL");
_local2 = new Array();
_local2.push(-1, _arg1);
SetDynamic(CallSync("create", _local2));
}
}
Section 51
//Encryption (mdm.Encryption)
package mdm {
public final class Encryption {
private static var resolver:mdm_Encryption = null;
public function Encryption():void{
}
public static function encryptFile(_arg1:String, _arg2:String, _arg3:String, _arg4:Boolean=true):void{
internal_resolver().encryptFile(_arg1, _arg2, _arg3);
}
private static function internal_resolver():mdm_Encryption{
if (resolver == null){
resolver = new mdm_Encryption();
};
return (resolver);
}
public static function decryptFile(_arg1:String, _arg2:String, _arg3:String, _arg4:Boolean=true):void{
internal_resolver().decryptFile(_arg1, _arg2, _arg3);
}
public static function encryptString(_arg1:String, _arg2:String):String{
return (internal_resolver().encryptString(_arg1, _arg2));
}
public static function decryptString(_arg1:String, _arg2:String):String{
return (internal_resolver().decryptString(_arg1, _arg2));
}
}
}//package mdm
dynamic class mdm_Encryption extends mdm_resolver {
private function mdm_Encryption():void{
SetClassName("mdm.Encryption");
}
}
Section 52
//Exception (mdm.Exception)
package mdm {
public final class Exception {
private static var resolver:mdm_Exception = null;
public function Exception():void{
}
public static function trapErrors(_arg1:Boolean=true):void{
internal_resolver().trapErrors();
}
public static function disableHandler(_arg1:Boolean=true):void{
internal_resolver().disableHandler();
}
public static function get DebugWindow():mdm_resolver{
return (internal_resolver().DebugWindow);
}
public static function enableHandler(_arg1:Boolean=true):void{
internal_resolver().enableHandler();
}
private static function internal_resolver():mdm_Exception{
if (resolver == null){
resolver = new mdm_Exception();
};
return (resolver);
}
public static function resetHandler(_arg1:Boolean=true):void{
internal_resolver().resetHandler();
}
public static function showErrors(_arg1:Boolean=true):void{
internal_resolver().showErrors();
}
}
}//package mdm
dynamic class mdm_Exception extends mdm_resolver {
private function mdm_Exception():void{
SetClassName("mdm.Exception");
AddObject("DebugWindow", null);
}
}
Section 53
//Extensions (mdm.Extensions)
package mdm {
public final class Extensions {
private static var resolver:mdm_Extensions = null;
public function Extensions():void{
}
private static function internal_resolver():mdm_Extensions{
if (resolver == null){
resolver = new mdm_Extensions();
};
return (resolver);
}
public static function getExtensionByName(_arg1:String):mdm_resolver{
return (internal_resolver().getExtensionByName(_arg1));
}
}
}//package mdm
dynamic class mdm_Extensions extends mdm_resolver {
private function mdm_Extensions():void{
var _local1:int;
super();
SetClassName("mdm.Extensions");
_local1 = 0;
while (_local1 < ExtensionsArray.length) {
AddObject(ExtensionsArray[_local1], null);
_local1++;
};
ExtensionsArray = null;
}
public function getExtensionByName(_arg1:String):mdm_resolver{
return (m_objs[_arg1]);
}
}
Section 54
//ExtensionsArray (mdm.ExtensionsArray)
package mdm {
public var ExtensionsArray:Array = new Array();
}//package mdm
Section 55
//FileExplorer (mdm.FileExplorer)
package mdm {
public final class FileExplorer {
private static var resolver:mdm_FileExplorer = null;
public function mdm_FileExplorer():void{
}
public static function init(_arg1:Boolean=true):void{
internal_resolver().init();
}
public static function get ListView():mdm_resolver{
return (internal_resolver().ListView);
}
public static function set onFileListViewDblClick(_arg1:Function):void{
internal_resolver().onFileListViewDblClick = _arg1;
}
private static function internal_resolver():mdm_FileExplorer{
if (resolver == null){
resolver = new mdm_FileExplorer();
};
return (resolver);
}
public static function get TreeView():mdm_resolver{
return (internal_resolver().TreeView);
}
public static function get ComboBox():mdm_resolver{
return (internal_resolver().ComboBox);
}
}
}//package mdm
dynamic class mdm_FileExplorer extends mdm_resolver {
private function mdm_FileExplorer():void{
SetClassName("mdm.FileExplorer");
AddEvents();
AddObject("ComboBox", null);
AddObject("ListView", null);
AddObject("TreeView", null);
}
private function AddEvents():void{
AddEvent("onFileListViewDblClick", true);
}
}
Section 56
//FileSystem (mdm.FileSystem)
package mdm {
public final class FileSystem {
private static var resolver:mdm_FileSystem = null;
public function mdm_FileSystem():void{
}
public static function getFileDate(_arg1:String):String{
return (internal_resolver().getFileDate(_arg1));
}
public static function makeFolderUnicode(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().makeFolderUnicode(_arg1);
}
public static function loadFile(_arg1:String):String{
return (internal_resolver().loadFile(_arg1));
}
public static function copyFolder(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().copyFolder(_arg1, _arg2);
}
public static function saveFileUnicode(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().saveFileUnicode(_arg1, _arg2);
}
public static function fileExistsUnicode(_arg1:String):Boolean{
return (internal_resolver().fileExistsUnicode(_arg1));
}
public static function appendFileUnicode(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().appendFileUnicode(_arg1, _arg2);
}
private static function internal_resolver():mdm_FileSystem{
if (resolver == null){
resolver = new mdm_FileSystem();
};
return (resolver);
}
public static function saveFileHEX(_arg1:String, _arg2:String, _arg3:Boolean):void{
internal_resolver().saveFileHEX(_arg1, _arg2);
}
public static function getCurrentDir():String{
var _local1:String;
var _local2:RegExp;
_local1 = internal_resolver().getCurrentDir();
_local2 = /\\\\/g;
_local1 = _local1.replace(_local2, "\\");
return (_local1);
}
public static function getAssociation(_arg1:String):String{
return (internal_resolver().getAssociation(_arg1));
}
public static function copyFileUnicode(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().copyFileUnicode(_arg1, _arg2);
}
public static function deleteFile(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().deleteFile(_arg1);
}
public static function copyFile(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().copyFile(_arg1, _arg2);
}
public static function setFileAttribs(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().setFileAttribs(_arg1, _arg2);
}
public static function getFolderSize(_arg1:String):Number{
return (internal_resolver().getFolderSize(_arg1));
}
public static function findFile(_arg1:String):String{
return (internal_resolver().findFile(_arg1));
}
public static function deleteFileUnicode(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().deleteFileUnicode(_arg1);
}
public static function getFileAttribs(_arg1:String):Array{
return (internal_resolver().getFileAttribs(_arg1));
}
public static function saveFile(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().saveFile(_arg1, _arg2);
}
public static function getFileCreator(_arg1:String):String{
return (internal_resolver().getFileCreator(_arg1));
}
public static function getFileType(_arg1:String):String{
return (internal_resolver().getFileType(_arg1));
}
public static function nativePathToUnixPath(_arg1:String):String{
return (internal_resolver().nativePathToUnixPath(_arg1));
}
public static function getFileTime(_arg1:String):String{
return (internal_resolver().getFileTime(_arg1));
}
public static function get BinaryFile():mdm_resolver{
return (internal_resolver().BinaryFile);
}
public static function deleteFolderUnicode(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().deleteFolderUnicode(_arg1, _arg2);
}
public static function setCurrentDir(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().setCurrentDir(_arg1);
}
public static function loadFileHEX(_arg1:String):String{
return (internal_resolver().loadFileHEX(_arg1));
}
public static function setCurrentDirUnicode(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().setCurrentDirUnicode(_arg1);
}
public static function createShortcut(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:Number, _arg6:String, _arg7:Boolean=true):void{
internal_resolver().createShortcut(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6);
}
public static function folderExists(_arg1:String):Boolean{
return (internal_resolver().folderExists(_arg1));
}
public static function folderExistsUnicode(_arg1:String):Boolean{
return (internal_resolver().folderExistsUnicode(_arg1));
}
public static function getFileList(_arg1:String, _arg2:String):Array{
return (internal_resolver().getFileList(_arg1, _arg2));
}
public static function getFolderList(_arg1:String):Array{
return (internal_resolver().getFolderList(_arg1));
}
public static function getCurrentDirUnicode():String{
var _local1:String;
var _local2:RegExp;
_local1 = internal_resolver().getCurrentDirUnicode();
_local2 = /\\\\/g;
_local1 = _local1.replace(_local2, "\\");
return (_local1);
}
public static function getFileSize(_arg1:String):Number{
return (internal_resolver().getFileSize(_arg1));
}
public static function appendFile(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().appendFile(_arg1, _arg2);
}
public static function fileExists(_arg1:String):Boolean{
return (internal_resolver().fileExists(_arg1));
}
public static function deleteFolder(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().deleteFolder(_arg1, _arg2);
}
public static function getLongPathName(_arg1:String):String{
return (internal_resolver().getLongPathName(_arg1));
}
public static function loadFileUnicode(_arg1:String):String{
return (internal_resolver().loadFileUnicode(_arg1));
}
public static function makeFolder(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().makeFolder(_arg1);
}
public static function getShortPathName(_arg1:String):String{
return (internal_resolver().getShortPathName(_arg1));
}
}
}//package mdm
dynamic class mdm_FileSystem extends mdm_resolver {
private function mdm_FileSystem():void{
SetClassName("mdm.FileSystem");
AddObject("BinaryFile", null);
}
}
Section 57
//Flash (mdm.Flash)
package mdm {
public final class Flash {
private static var resolver:mdm_Flash = null;
public function Flash():void{
}
public static function allowScale(_arg1:Boolean, _arg2:Boolean, _arg3:Boolean=true):void{
internal_resolver().allowScale(_arg1, _arg2);
}
public static function setShowAllMode(_arg1:Boolean=true):void{
internal_resolver().setShowAllMode();
}
public static function callFunctionUnicode(_arg1:String, _arg2:String, _arg3:String, _arg4:Boolean=true):void{
internal_resolver().callFunctionUnicode(_arg1, _arg2, _arg3);
}
private static function internal_resolver():mdm_Flash{
if (resolver == null){
resolver = new mdm_Flash();
};
return (resolver);
}
public static function loadMovie(_arg1:Number, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().loadMovie(_arg1, _arg2);
}
public static function getVarUnicode(_arg1:String):String{
return (internal_resolver().getVarUnicode(_arg1));
}
public static function setSWFDir(_arg1:Boolean=true):void{
internal_resolver().setSWFDir();
}
public static function getVar(_arg1:String):String{
return (internal_resolver().getVar(_arg1));
}
public static function setVar(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().setVar(_arg1, _arg2);
}
public static function setSWFDirAdv(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().setSWFDirAdv(_arg1);
}
public static function callFunction(_arg1:String, _arg2:String, _arg3:String, _arg4:Boolean=true):void{
internal_resolver().callFunction(_arg1, _arg2, _arg3);
}
public static function setVarUnicode(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().setVarUnicode(_arg1, _arg2);
}
public static function baseURL(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().baseURL(_arg1);
}
}
}//package mdm
dynamic class mdm_Flash extends mdm_resolver {
private function mdm_Flash():void{
SetClassName("mdm.Flash");
}
}
Section 58
//Forms (mdm.Forms)
package mdm {
public final class Forms {
private static var resolver:mdm_Forms = null;
public function Forms():void{
}
public static function get thisForm():mdm_Form{
internal_resolver().updateForms();
return (internal_resolver().getThisForm());
}
private static function internal_resolver():mdm_Forms{
if (resolver == null){
resolver = new mdm_Forms();
};
return (resolver);
}
public static function getFormByName(_arg1:String):mdm_Form{
internal_resolver().updateForms();
return (internal_resolver().getFormByName(_arg1));
}
}
}//package mdm
import flash.external.*;
dynamic class mdm_FormBase extends mdm_resolver {
private function mdm_FormBase(_arg1:String):void{
SetClassName(("mdm.Forms." + _arg1));
}
}
dynamic class mdm_Forms extends mdm_resolver {
private var m_thisForm:String;
private var m_forms:Object;
private var strForms:String;// = "MainForm<{!z!}>normal<{!z!}>thisForm<{!z!!}>SubForm1<{!z!}>transparent<{!z!}><{!z!!}>"
private function mdm_Forms():void{
var _local1:String;
strForms = "MainForm<{!z!}>normal<{!z!}>thisForm<{!z!!}>SubForm1<{!z!}>transparent<{!z!}><{!z!!}>";
super();
m_forms = null;
SetClassName("mdm.Forms");
if (!m_bSimulate){
_local1 = ExternalInterface.call("mdm.initforms", m_strFormID, "");
} else {
_local1 = strForms;
};
if (_local1 != null){
InitialiseForms(_local1);
};
}
private function InitialiseForms(_arg1:String):void{
var _local2:Array;
var _local3:int;
m_forms = null;
m_forms = new Object();
_local2 = _arg1.split("<{!z!!}>");
_local3 = 0;
while (_local3 < _local2.length) {
InitialiseForm(_local2[_local3]);
_local3++;
};
}
public function getThisForm():mdm_Form{
return (m_forms[m_thisForm]);
}
public function getFormByName(_arg1:String):mdm_Form{
if (m_forms[_arg1] == null){
return (null);
};
return (m_forms[_arg1]);
}
public function updateForms(){
var _local1:String;
_local1 = ExternalInterface.call("mdm.initforms", m_strFormID, "");
if (_local1 != null){
InitialiseForms(_local1);
};
}
private function InitialiseForm(_arg1:String):void{
var _local2:Array;
var _local3:int;
var _local4:Array;
var _local5:String;
_local2 = _arg1.split("<{!!z!!}>");
_local3 = 0;
while (_local3 < _local2.length) {
_local4 = _local2[_local3].split("<{!z!}>");
_local5 = _local4[0];
m_forms[_local5] = new mdm_Form(_local5);
if ((((_local4.length == 3)) && ((_local4[2] == "thisForm")))){
m_thisForm = _local5;
};
_local3++;
};
}
}
final class mdm_Form {
private var resolver:mdm_FormBase;// = null
private function mdm_Form(_arg1:String):void{
resolver = null;
super();
resolver = new mdm_FormBase(_arg1);
}
public function get windowState():String{
return (resolver.windowState);
}
public function showMask(_arg1:String, _arg2:Boolean=true):void{
resolver.showMask(_arg1);
}
public function get visible():Boolean{
return (resolver.getvisible());
}
public function get name():String{
return (resolver.getname());
}
public function shake(_arg1:Number, _arg2:Boolean=true):void{
resolver.shake(_arg1);
}
public function restore(_arg1:Boolean=true):void{
resolver.restore();
}
public function set width(_arg1:Number):void{
resolver.setwidth(_arg1);
}
public function showInScreen(_arg1:Number, _arg2:Boolean=true):void{
resolver.showInScreen(_arg1);
}
public function setFocus(_arg1:Boolean=true):void{
resolver.setFocus();
}
public function set showMinBtn(_arg1:Boolean):void{
resolver.setshowMinBtn(_arg1);
}
public function minimize(_arg1:Boolean=true):void{
resolver.minimize();
}
public function hideStatusBar(_arg1:Boolean=true):void{
resolver.hideStatusBar();
}
public function callFunctionUnicode(_arg1:String, _arg2:String, _arg3:String, _arg4:Boolean=true):void{
resolver.callFunctionUnicode(_arg1, _arg2, _arg3);
}
public function goToFrame(_arg1:Number, _arg2:Boolean=true):void{
resolver.goToFrame(_arg1);
}
public function addMask(_arg1:Number, _arg2:Number, _arg3:String, _arg4:Boolean=true):void{
resolver.addMask(_arg1, _arg2, _arg3);
}
public function get height():Number{
return (resolver.getheight());
}
public function showModal():String{
return (resolver.showModal());
}
public function goToLabel(_arg1:Number, _arg2:Boolean=true):void{
resolver.goToLabel(_arg1);
}
public function startDrag(_arg1:Boolean=true):void{
resolver.startDrag();
}
public function set title(_arg1:String):void{
resolver.settitle(_arg1);
}
public function showFullScreen(_arg1:Boolean, _arg2:Boolean=true):void{
resolver.showFullScreen(_arg1);
}
public function set baseURL(_arg1:String):void{
resolver.setBaseURL(_arg1);
}
public function dndEnable(_arg1:Boolean=true):void{
resolver.dndEnable();
}
public function hide(_arg1:Boolean=true):void{
resolver.hide();
}
public function set bgColor(_arg1:Number):void{
resolver.setBgColor(_arg1);
}
public function hideCaption(_arg1:Boolean, _arg2:Boolean=true):void{
resolver.hideCaption(_arg1);
}
public function constraints(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Boolean=true):void{
resolver.constraints(_arg1, _arg2, _arg3, _arg4);
}
public function get width():Number{
return (resolver.getwidth());
}
public function set titleUnicode(_arg1:String):void{
resolver.settitleUnicode(_arg1);
}
public function showStatusBar(_arg1:Boolean=true):void{
resolver.showStatusBar();
}
public function setStatusBarText(_arg1:String, _arg2:Boolean=true):void{
resolver.setStatusBarText(_arg1);
}
public function hideMask(_arg1:Boolean=true):void{
resolver.hideMask();
}
public function maximize(_arg1:Boolean=true):void{
resolver.maximize();
}
public function set alpha(_arg1:Number):void{
resolver.setAlpha(_arg1);
}
public function set height(_arg1:Number):void{
resolver.setheight(_arg1);
}
public function callFunction(_arg1:String, _arg2:String, _arg3:String, _arg4:Boolean=true):void{
resolver.callFunction(_arg1, _arg2, _arg3);
}
public function get title():String{
return (resolver.gettitle());
}
public function stopDrag(_arg1:Boolean=true):void{
resolver.stopDrag();
}
public function get alpha():Number{
return (resolver.getalpha());
}
public function set showSysBtn(_arg1:Boolean):void{
resolver.setshowSysBtn(_arg1);
}
public function set visible(_arg1:Boolean):void{
resolver.setvisible(_arg1);
}
public function get isCreated():Boolean{
return (resolver.getisCreated());
}
public function set rightMouseBtn(_arg1:String):void{
resolver.setrightMouseBtn(_arg1);
}
public function set middleMouseBtn(_arg1:String):void{
resolver.setmiddleMouseBtn(_arg1);
}
public function set leftMouseBtn(_arg1:String):void{
resolver.setleftMouseBtn(_arg1);
}
public function set showMaxBtn(_arg1:Boolean):void{
resolver.setshowMaxBtn(_arg1);
}
public function dndDisable(_arg1:Boolean=true):void{
resolver.dndDisable();
}
public function set x(_arg1:Number):void{
resolver.setx(_arg1);
}
public function set y(_arg1:Number):void{
resolver.sety(_arg1);
}
public function set type(_arg1:String):void{
resolver.settype(_arg1);
}
public function get x():Number{
return (resolver.getx());
}
public function get y():Number{
return (resolver.gety());
}
public function show(_arg1:Boolean=true):void{
resolver.show();
}
public function close():void{
resolver.close();
}
}
Section 59
//FTP (mdm.FTP)
package mdm {
public final class FTP {
private var resolver:mdm_FTP;// = null
public function FTP(_arg1:String, _arg2:Number):void{
resolver = null;
super();
resolver = new mdm_FTP(this, _arg1, _arg2);
}
public function get success():Boolean{
return (resolver.success);
}
public function get error():String{
return (resolver.error);
}
public function set onListingDone(_arg1:Function):void{
resolver.onListingDone = _arg1;
}
public function set async(_arg1:Boolean):void{
resolver.async = _arg1;
}
public function getDirAttribs(_arg1:String):String{
return (resolver.getDirAttribs(_arg1));
}
public function getFileSize(_arg1:String):Number{
return (resolver.getFileSize(_arg1));
}
public function set onDirDeleted(_arg1:Function):void{
resolver.onDirDeleted = _arg1;
}
public function getFileAttribs(_arg1:String):String{
return (resolver.getFileAttribs(_arg1));
}
public function getDirDateTime(_arg1:String):String{
return (resolver.getDirDateTime(_arg1));
}
public function close(_arg1:Boolean=true):void{
resolver.close();
}
public function set onLoggedIn(_arg1:Function):void{
resolver.onLoggedIn = _arg1;
}
public function set onQuit(_arg1:Function):void{
resolver.onQuit = _arg1;
}
public function set onFileTransferred(_arg1:Function):void{
resolver.onFileTransferred = _arg1;
}
public function set onIndexFileReceived(_arg1:Function):void{
resolver.onIndexFileReceived = _arg1;
}
public function getFolderList():Array{
return (resolver.getFolderList());
}
public function sendCommand(_arg1:String):String{
return (resolver.sendCommand(_arg1));
}
public function sendFile(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
resolver.sendFile(_arg1, _arg2);
}
public function set onFileReceived(_arg1:Function):void{
resolver.onFileReceived = _arg1;
}
public function set currentDir(_arg1:String):void{
resolver.currentDir = _arg1;
}
public function set onReady(_arg1:Function):void{
resolver.onReady = _arg1;
}
public function setProxy(_arg1:String, _arg2:String, _arg3:Number, _arg4:String, _arg5:String, _arg6:Boolean=true):void{
resolver.setProxy(_arg1, _arg2, _arg3, _arg4, _arg5);
}
public function getFileDateTime(_arg1:String):String{
return (resolver.getFileDateTime(_arg1));
}
public function abort(_arg1:Boolean=true):void{
resolver.abort();
}
public function set onDirCreated(_arg1:Function):void{
resolver.onDirCreated = _arg1;
}
public function getFileList():Array{
return (resolver.getFileList());
}
public function set serverType(_arg1:String):void{
resolver.serverType = _arg1;
}
public function set onFileDeleted(_arg1:Function):void{
resolver.onFileDeleted = _arg1;
}
public function makeDir(_arg1:String, _arg2:Boolean=true):void{
resolver.makeDir(_arg1);
}
public function set timeout(_arg1:Number):void{
resolver.timeout = _arg1;
}
public function get isBusy():Boolean{
return (resolver.isBusy);
}
public function set NOOP(_arg1:Boolean):void{
resolver.NOOP = _arg1;
}
public function deleteFile(_arg1:String, _arg2:Boolean=true):void{
resolver.deleteFile(_arg1);
}
public function internal_resolver():mdm_FTP{
return (resolver);
}
public function dirExists(_arg1:String):Boolean{
return (resolver.dirExists(_arg1));
}
public function set onDirChanged(_arg1:Function):void{
resolver.onDirChanged = _arg1;
}
public function set passive(_arg1:Boolean):void{
resolver.passive = _arg1;
}
public function get supportsResume():Boolean{
return (resolver.supportsResume);
}
public function set initialDir(_arg1:String):void{
resolver.initialDir = _arg1;
}
public function get currentDir():String{
return (resolver.currentDir);
}
public function set onFileRenamed(_arg1:Function):void{
resolver.onFileRenamed = _arg1;
}
public function get transferTime():Number{
return (resolver.transferTime);
}
public function set onError(_arg1:Function):void{
resolver.onError = _arg1;
}
public function renameFile(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
resolver.renameFile(_arg1, _arg2);
}
public function refresh(_arg1:Boolean=true):void{
resolver.refresh();
}
public function set transferMode(_arg1:String):void{
resolver.transferMode = _arg1;
}
public function set onResolveLinks(_arg1:Function):void{
resolver.onResolveLinks = _arg1;
}
public function set onAborted(_arg1:Function):void{
resolver.onAborted = _arg1;
}
public function set account(_arg1:String):void{
resolver.account = _arg1;
}
public function deleteDir(_arg1:String, _arg2:Boolean=true):void{
resolver.deleteDir(_arg1);
}
public function set onConnected(_arg1:Function):void{
resolver.onConnected = _arg1;
}
public function set onFileSent(_arg1:Function):void{
resolver.onFileSent = _arg1;
}
public function chDir(_arg1:String, _arg2:Boolean=true):void{
resolver.chDir(_arg1);
}
public function login(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
resolver.login(_arg1, _arg2);
}
public function get bytesTransferred():Number{
return (resolver.bytesTransferred);
}
public function moveFile(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
resolver.moveFile(_arg1, _arg2);
}
public function set onBusy(_arg1:Function):void{
resolver.onBusy = _arg1;
}
public function getFile(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
resolver.getFile(_arg1, _arg2);
}
public function get lastReply():String{
return (resolver.lastReply);
}
public function resumePosition():Number{
return (resolver.resumePosition());
}
public function fileExists(_arg1:String):Boolean{
return (resolver.fileExists(_arg1));
}
public function get loggerData():String{
return (resolver.loggerData);
}
public function get isConnected():Boolean{
return (resolver.isConnected);
}
}
}//package mdm
dynamic class mdm_FTP extends mdm_resolver {
private function mdm_FTP(_arg1:FTP, _arg2:String, _arg3:Number):void{
var _local4:Array;
var _local5:int;
super();
SetClassName("mdm.FTP");
AddEvents();
_local4 = new Array();
_local4.push(-1, _arg2, _arg3);
SetDynamic(CallSync("create", _local4));
_local5 = m_dynamicID;
m_dynFTP[_local5] = _arg1;
}
private function AddEvents():void{
AddDynamicEvent("onAborted", false);
AddDynamicEvent("onBusy", false);
AddDynamicEvent("onConnected", false);
AddDynamicEvent("onDirChanged", false);
AddDynamicEvent("onDirCreated", false);
AddDynamicEvent("onDirDeleted", false);
AddDynamicEvent("onError", false);
AddDynamicEvent("onFileDeleted", false);
AddDynamicEvent("onFileReceived", false);
AddDynamicEvent("onFileRenamed", false);
AddDynamicEvent("onFileSent", false);
AddDynamicEvent("onFileTransferred", false);
AddDynamicEvent("onIndexFileReceived", false);
AddDynamicEvent("onListingDone", false);
AddDynamicEvent("onLoggedIn", false);
AddDynamicEvent("onQuit", false);
AddDynamicEvent("onReady", false);
AddDynamicEvent("onResolveLinks", false);
}
}
Section 60
//HTTP (mdm.HTTP)
package mdm {
public final class HTTP {
private var resolver:mdm_HTTP;// = null
public function HTTP():void{
resolver = null;
super();
resolver = new mdm_HTTP(this);
}
public function internal_resolver():mdm_HTTP{
return (resolver);
}
public function set onTransferComplete(_arg1:Function):void{
resolver.onTransferComplete = _arg1;
}
public function getString(_arg1:String, _arg2:String="", _arg3:String="", _arg4:Boolean=true):void{
resolver.getString(_arg1, _arg2, _arg3);
}
public function abort(_arg1:Boolean=true):void{
resolver.abort();
}
public function getFile(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:Boolean=true):void{
resolver.getFile(_arg1, _arg2, _arg3, _arg4);
}
public function set onBinaryTransferComplete(_arg1:Function):void{
resolver.onBinaryTransferComplete = _arg1;
}
public function close(_arg1:Boolean=true):void{
resolver.close();
}
public function set onError(_arg1:Function):void{
resolver.onError = _arg1;
}
private function AddEvents():void{
resolver.AddDynamicEvent("onBinaryTransferComplete", true);
resolver.AddDynamicEvent("onError", false);
resolver.AddDynamicEvent("onProgress", true);
resolver.AddDynamicEvent("onTransferComplete", true);
}
public function set onProgress(_arg1:Function):void{
resolver.onProgress = _arg1;
}
}
}//package mdm
dynamic class mdm_HTTP extends mdm_resolver {
private function mdm_HTTP(_arg1:HTTP):void{
var _local2:Array;
var _local3:int;
super();
SetClassName("mdm.HTTP");
AddEvents();
_local2 = new Array();
_local2.push(-1);
SetDynamic(CallSync("create", _local2));
_local3 = m_dynamicID;
m_dynHTTP[_local3] = _arg1;
}
private function AddEvents():void{
AddDynamicEvent("onBinaryTransferComplete", true);
AddDynamicEvent("onError", false);
AddDynamicEvent("onProgress", true);
AddDynamicEvent("onTransferComplete", true);
}
}
Section 61
//Image (mdm.Image)
package mdm {
public final class Image {
private static var resolver:mdm_Image = null;
public function mdm_Image():void{
}
public static function setJpgSize(_arg1:String, _arg2:Number, _arg3:Number, _arg4:String, _arg5:Number, _arg6:Boolean=true):void{
internal_resolver().setJpgSize(_arg1, _arg2, _arg3, _arg4, _arg5);
}
public static function bmpToJpg(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().bmpToJpg(_arg1);
}
public static function jpgToSwfSlideShow(_arg1:Number, _arg2:String, _arg3:String, _arg4:String, _arg5:Number, _arg6:Number, _arg7:Boolean=true):void{
internal_resolver().jpgToSwfSlideShow(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6);
}
public static function bmpToPng(_arg1:String, _arg2:String, _arg3:Boolean, _arg4:String, _arg5:Boolean=true):void{
internal_resolver().bmpToPng(_arg1, _arg2, _arg3, _arg4);
}
public static function getJpgSize(_arg1:String):Array{
return (internal_resolver().getJpgSize(_arg1));
}
public static function jpgToSwf(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().jpgToSwf(_arg1, _arg2);
}
private static function internal_resolver():mdm_Image{
if (resolver == null){
resolver = new mdm_Image();
};
return (resolver);
}
public static function jpgToBmp(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().jpgToBmp(_arg1);
}
public static function bmpToJpgAdv(_arg1:String, _arg2:Number, _arg3:Boolean=true):void{
internal_resolver().bmpToJpgAdv(_arg1, _arg2);
}
public static function pngToSwfTransparent(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().pngToSwfTransparent(_arg1);
}
public static function getSwfHeader(_arg1:String):Array{
return (internal_resolver().getSwfHeader(_arg1));
}
public static function get ScreenCapture():mdm_resolver{
return (internal_resolver().ScreenCapture);
}
public static function pngToSwf(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().pngToSwf(_arg1);
}
}
}//package mdm
dynamic class mdm_Image extends mdm_resolver {
private function mdm_Image():void{
SetClassName("mdm.Image");
AddObject("ScreenCapture", null);
}
}
Section 62
//Input (mdm.Input)
package mdm {
public final class Input {
private static var resolver:mdm_Input = null;
public function mdm_Input():void{
}
public static function get Mouse():mdm_resolver{
return (internal_resolver().Mouse);
}
private static function internal_resolver():mdm_Input{
if (resolver == null){
resolver = new mdm_Input();
};
return (resolver);
}
public static function get Twain():mdm_resolver{
return (internal_resolver().Twain);
}
public static function get Joystick():mdm_resolver{
return (internal_resolver().Joystick);
}
public static function get Tablet():mdm_resolver{
return (internal_resolver().Tablet);
}
}
}//package mdm
dynamic class mdm_Tablet extends mdm_resolver {
private function mdm_Tablet():void{
SetClassName("mdm.Input.Tablet");
AddEvents();
}
private function AddEvents():void{
AddEvent("onTabletEvent", true);
}
}
dynamic class mdm_Joystick extends mdm_resolver {
private function mdm_Joystick():void{
SetClassName("mdm.Input.Joystick");
AddEvents();
}
private function AddEvents():void{
AddEvent("onJoystick1ButtonDown", true);
AddEvent("onJoystick1Move", true);
AddEvent("onJoystick2ButtonDown", true);
AddEvent("onJoystick2Move", true);
}
}
dynamic class mdm_Input extends mdm_resolver {
private function mdm_Input():void{
SetClassName("mdm.Input");
AddObject("Joystick", new mdm_Joystick());
AddObject("Mouse", null);
AddObject("Tablet", new mdm_Tablet());
AddObject("Twain", null);
}
}
Section 63
//MacShell (mdm.MacShell)
package mdm {
public final class MacShell {
private static var resolver:mdm_MacShell = null;
public function MacShell():void{
resolver.SetClassName("mdm.MacShell");
}
public static function get output():String{
return (internal_resolver().output);
}
public static function exec(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().exec(_arg1);
}
public static function get isRunning():Boolean{
return (internal_resolver().isRunning);
}
private static function internal_resolver():mdm_MacShell{
if (resolver == null){
resolver = new mdm_MacShell();
};
return (resolver);
}
public static function get exitCode():String{
return (internal_resolver().exitCode);
}
public static function close(_arg1:Boolean=true):void{
internal_resolver().close();
}
}
}//package mdm
dynamic class mdm_MacShell extends mdm_resolver {
private function mdm_MacShell():void{
SetClassName("mdm.MacShell");
}
}
Section 64
//MediaPlayer (mdm.MediaPlayer)
package mdm {
public final class MediaPlayer {
private var resolver:mdm_MediaPlayer9;// = null
public function MediaPlayer(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String, _arg6:Boolean, _arg7:Boolean, _arg8:String):void{
resolver = null;
super();
resolver = new mdm_MediaPlayer9(this, _arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7, _arg8);
}
public function hide(_arg1:Boolean=true):void{
resolver.hide();
}
public function set source(_arg1:String):void{
resolver.source = _arg1;
}
public function internal_resolver():mdm_MediaPlayer9{
return (resolver);
}
public function fastForward(_arg1:Boolean=true):void{
resolver.fastForward();
}
public function set y(_arg1:Number):void{
resolver.y = _arg1;
}
public function get width():Number{
return (resolver.width);
}
public function set height(_arg1:Number):void{
resolver.height = _arg1;
}
public function get x():Number{
return (resolver.x);
}
public function stop(_arg1:Boolean=true):void{
resolver.stop();
}
public function set position(_arg1:Number):void{
resolver.position = _arg1;
}
public function get currentMarker():Number{
return (resolver.currentMarker);
}
public function get duration():Number{
return (resolver.duration);
}
public function set onWMPBuffering(_arg1:Function):void{
resolver.onWMPBuffering = _arg1;
}
public function get mediaName():String{
return (resolver.mediaName);
}
public function mute(_arg1:Boolean, _arg2:Boolean=true):void{
resolver.mute(_arg1);
}
public function get mediaWidth():Number{
return (resolver.mediaWidth);
}
public function get source():String{
return (resolver.source);
}
public function get balance():Number{
return (resolver.balance);
}
public function set onWMPError(_arg1:Function):void{
resolver.onWMPError = _arg1;
}
public function set onWMPChangeState(_arg1:Function):void{
resolver.onWMPChangeState = _arg1;
}
public function get volume():Number{
return (resolver.volume);
}
public function set visible(_arg1:Boolean):void{
resolver.visible = _arg1;
}
public function fastReverse(_arg1:Boolean=true):void{
resolver.fastReverse();
}
public function get height():Number{
return (resolver.height);
}
public function get canSeek():Boolean{
return (resolver.canSeek);
}
public function get position():Number{
return (resolver.position);
}
public function get mediaHeight():Number{
return (resolver.mediaHeight);
}
public function get canScan():Boolean{
return (resolver.canScan);
}
public function set width(_arg1:Number):void{
resolver.width = _arg1;
}
public function set onWMPPositionChanged(_arg1:Function):void{
resolver.onWMPPositionChanged = _arg1;
}
public function get isInstalled():Boolean{
return (resolver.isInstalled);
}
public function get visible():Boolean{
return (resolver.visible);
}
public function play(_arg1:Boolean=true):void{
resolver.play();
}
public function set currentMarker(_arg1:Number):void{
resolver.currentMarker = _arg1;
}
public function pause(_arg1:Boolean=true):void{
resolver.pause();
}
public function set x(_arg1:Number):void{
resolver.x = _arg1;
}
public function close(_arg1:Boolean=true):void{
resolver.close();
}
public function get y():Number{
return (resolver.y);
}
public function featureAvailable(_arg1:String):Boolean{
return (resolver.featureAvailable(_arg1));
}
public function set volume(_arg1:Number):void{
resolver.volume = _arg1;
}
public function get markerCount():Number{
return (resolver.markerCount);
}
public function show(_arg1:Boolean=true):void{
resolver.show();
}
public function set balance(_arg1:Number):void{
resolver.balance = _arg1;
}
}
}//package mdm
dynamic class mdm_MediaPlayer9 extends mdm_resolver {
private function mdm_MediaPlayer9(_arg1:MediaPlayer, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String, _arg7:Boolean, _arg8:Boolean, _arg9:String):void{
var _local10:Array;
var _local11:int;
super();
SetClassName("mdm.MediaPlayer");
AddEvents();
_local10 = new Array();
_local10.push(-1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7, _arg8, _arg9);
SetDynamic(CallSync("create", _local10));
_local11 = m_dynamicID;
m_dynMP9[_local11] = _arg1;
}
private function AddEvents():void{
AddDynamicEvent("onWMPChangeState", true);
AddDynamicEvent("onWMPBuffering", true);
AddDynamicEvent("onWMPError", true);
AddDynamicEvent("onWMPPositionChanged", true);
}
}
Section 65
//MediaPlayer6 (mdm.MediaPlayer6)
package mdm {
public final class MediaPlayer6 {
private var resolver:mdm_MediaPlayer6;// = null
public function MediaPlayer6(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String):void{
resolver = null;
super();
resolver = new mdm_MediaPlayer6(this, _arg1, _arg2, _arg3, _arg4, _arg5);
}
public function noMenu(_arg1:Boolean=true):void{
resolver.noMenu();
}
public function hide(_arg1:Boolean=true):void{
resolver.hide();
}
public function set volume(_arg1:Number):void{
resolver.volume = _arg1;
}
public function internal_resolver():mdm_MediaPlayer6{
return (resolver);
}
public function fastForward(_arg1:Boolean=true):void{
resolver.fastForward();
}
public function set y(_arg1:Number):void{
resolver.y = _arg1;
}
public function get width():Number{
return (resolver.width);
}
public function set height(_arg1:Number):void{
resolver.height = _arg1;
}
public function get x():Number{
return (resolver.x);
}
public function stop(_arg1:Boolean=true):void{
resolver.stop();
}
public function set position(_arg1:Number):void{
resolver.position = _arg1;
}
public function set width(_arg1:Number):void{
resolver.width = _arg1;
}
public function get duration():Number{
return (resolver.duration);
}
public function mute(_arg1:Boolean, _arg2:Boolean=true):void{
resolver.mute(_arg1);
}
public function get volume():Number{
return (resolver.volume);
}
public function get balance():Number{
return (resolver.balance);
}
public function set visible(_arg1:Boolean):void{
resolver.visible = _arg1;
}
public function fastReverse(_arg1:Boolean=true):void{
resolver.fastReverse();
}
public function get height():Number{
return (resolver.height);
}
public function get canSeek():Boolean{
return (resolver.canSeek);
}
public function get position():Number{
return (resolver.position);
}
public function get canScan():Boolean{
return (resolver.canScan);
}
public function get isInstalled():Boolean{
return (resolver.isInstalled);
}
public function get visible():Boolean{
return (resolver.visible);
}
public function play(_arg1:Boolean=true):void{
resolver.play();
}
public function pause(_arg1:Boolean=true):void{
resolver.pause();
}
public function set x(_arg1:Number):void{
resolver.x = _arg1;
}
public function close(_arg1:Boolean=true):void{
resolver.close();
}
public function get y():Number{
return (resolver.y);
}
public function fullscreen(_arg1:Boolean=true):void{
resolver.fullscreen();
}
public function show(_arg1:Boolean=true):void{
resolver.show();
}
public function set onMPChangeState(_arg1:Function):void{
resolver.onMPChangeState = _arg1;
}
public function set balance(_arg1:Number):void{
resolver.balance = _arg1;
}
}
}//package mdm
dynamic class mdm_MediaPlayer6 extends mdm_resolver {
private function mdm_MediaPlayer6(_arg1:MediaPlayer6, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String):void{
var _local7:Array;
var _local8:int;
super();
SetClassName("mdm.MediaPlayer6");
AddEvents();
_local7 = new Array();
_local7.push(-1, _arg2, _arg3, _arg4, _arg5, _arg6);
SetDynamic(CallSync("create", _local7));
_local8 = m_dynamicID;
m_dynMP6[_local8] = _arg1;
}
private function AddEvents():void{
AddDynamicEvent("onMPChangeState", true);
}
}
Section 66
//Menu (mdm.Menu)
package mdm {
public final class Menu {
private static var resolver:mdm_Menu = null;
public function mdm_Menu():void{
}
private static function internal_resolver():mdm_Menu{
if (resolver == null){
resolver = new mdm_Menu();
};
return (resolver);
}
public static function get Main():mdm_resolver{
return (internal_resolver().Main);
}
public static function get Tray():mdm_resolver{
return (internal_resolver().Tray);
}
public static function get Context():mdm_resolver{
return (internal_resolver().Context);
}
}
}//package mdm
dynamic class mdm_MenuContext extends mdm_resolver {
private function mdm_MenuContext():void{
SetClassName("mdm.Menu.Context");
}
}
dynamic class mdm_MenuMain extends mdm_resolver {
private function mdm_MenuMain():void{
SetClassName("mdm.Menu.Main");
}
}
dynamic class mdm_Menu extends mdm_resolver {
private function mdm_Menu():void{
SetClassName("mdm.Menu");
AddObject("Context", new mdm_MenuContext());
AddObject("Main", new mdm_MenuMain());
AddObject("Tray", new mdm_MenuTray());
}
}
dynamic class mdm_MenuTray extends mdm_resolver {
private function mdm_MenuTray():void{
SetClassName("mdm.Menu.Tray");
}
}
Section 67
//Network (mdm.Network)
package mdm {
public final class Network {
private static var resolver:mdm_Network = null;
public function mdm_Network():void{
}
public static function get TCP():mdm_resolver{
return (internal_resolver().TCP);
}
public static function getIPByHost(_arg1:String):String{
return (internal_resolver().getIPByHost(_arg1));
}
public static function checkConnection():Boolean{
return (internal_resolver().checkConnection());
}
private static function internal_resolver():mdm_Network{
if (resolver == null){
resolver = new mdm_Network();
};
return (resolver);
}
public static function get HTTPD():mdm_resolver{
return (internal_resolver().HTTPD);
}
public static function checkConnectionAdv():String{
return (internal_resolver().checkConnectionAdv());
}
public static function get UDP():mdm_resolver{
return (internal_resolver().UDP);
}
public static function get isPresent():Boolean{
return (internal_resolver().isPresent);
}
public static function get IPAddress():String{
return (internal_resolver().IPAddress);
}
public static function get Mail():mdm_resolver{
return (internal_resolver().Mail);
}
public static function checkConnectionPing(_arg1:String, _arg2:Number):Boolean{
return (internal_resolver().checkConnectionPing(_arg1, _arg2));
}
public static function getURL(_arg1:String, _arg2:Boolean=true):String{
return (internal_resolver().getURL(_arg1));
}
public static function getMACAddress(_arg1:Number):String{
return (internal_resolver().getMACAddress(_arg1));
}
public static function getHostByIP(_arg1:String):String{
return (internal_resolver().getHostByIP(_arg1));
}
}
}//package mdm
dynamic class mdm_UDP_Socket extends mdm_resolver {
private function mdm_UDP_Socket():void{
SetClassName("mdm.Network.UDP.Socket");
AddEvents();
}
private function AddEvents():void{
AddEvent("onData", true);
}
}
dynamic class mdm_Network extends mdm_resolver {
private function mdm_Network():void{
SetClassName("mdm.Network");
AddObject("HTTPD", new mdm_HTTPD());
AddObject("Mail", null);
AddObject("TCP", new mdm_TCP());
AddObject("UDP", new mdm_UDP());
}
}
dynamic class mdm_HTTPD extends mdm_resolver {
private function mdm_HTTPD():void{
SetClassName("mdm.Network.HTTPD");
AddEvents();
}
private function AddEvents():void{
AddEvent("onRequest", true);
}
}
dynamic class mdm_UDP extends mdm_resolver {
private function mdm_UDP():void{
SetClassName("mdm.Network.UDP");
AddObject("Socket", new mdm_UDP_Socket());
AddObject("TFTP", null);
}
}
dynamic class mdm_TCP extends mdm_resolver {
private function mdm_TCP():void{
SetClassName("mdm.Network.TCP");
AddObject("FileServer", null);
AddObject("ProxyHTTP", null);
AddObject("Socket", new mdm_TCP_Socket());
}
}
dynamic class mdm_TCP_Socket extends mdm_resolver {
private function mdm_TCP_Socket():void{
SetClassName("mdm.Network.TCP.Socket");
AddEvents();
}
private function AddEvents():void{
AddEvent("onSocketData", true);
AddEvent("onSocketConnect", false);
AddEvent("onSocketClose", false);
}
}
Section 68
//packager (mdm.packager)
package mdm {
import flash.display.*;
public class packager extends MovieClip {
private var dummyInput:Input;
private var dummyAudio:Audio;
private var dummyMenu:Menu;
private var dummyFlash:Flash;
private var dummyDatabase:Database;
private var dummyActiveX:ActiveX;
private var dummyEncryption:Encryption;
private var dummyExt:Extensions;
private var ASYNC;
private var dummyDialogs:Dialogs;
private var dummyNetwork:Network;
private var dummyForms:Forms;
private var dummyRosetta:Rosetta;
private var dummyPDF7:PDF;
private var dummyException:Exception;
private var dummyQuickTime:QuickTime;
private var SYNC;
private var dummyFileExplorer:FileExplorer;
private var dummyProcess:Process;
private var dummyStrings:Strings;
private var dummyShockwave:Shockwave;
private var dummyMacShell:MacShell;
private var dummySystem:System;
private var dummyAppleScript:AppleScript;
private var dummyDll:DLL;
private var dummyRealMedia:RealMedia;
private var dummyHTTP:HTTP;
private var dummyBrowser:Browser;
public var boundingBoxClip:MovieClip;
private var dummyApplication;
private var dummyFileSystem:FileSystem;
private var dummyFTP:FTP;
private var dummyImage:Image;
private var dummyAlert:Alert2;
private var dummyMediaPlayer6:MediaPlayer6;
private var dummyMediaPlayer9:MediaPlayer;
private var dummyClipboard:Clipboard;
private var dummyCOMPort:COMPort;
public function packager(){
dummyApplication = Application;
super();
ASYNC = ASYNC;
SYNC = SYNC;
}
}
}//package mdm
Section 69
//PDF (mdm.PDF)
package mdm {
public final class PDF {
private var resolver:mdm_PDF7;// = null
public function PDF(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:String):void{
resolver = null;
super();
resolver = new mdm_PDF7(_arg1, _arg2, _arg3, _arg4, _arg5);
}
public function hide(_arg1:Boolean=true):void{
resolver.hide();
}
public function lastPage(_arg1:Boolean=true):void{
resolver.lastPage();
}
public function loadFile(_arg1:String, _arg2:Boolean=true):void{
resolver.loadFile(_arg1);
}
public function printWithDialog(_arg1:Boolean=true):void{
resolver.printWithDialog();
}
public function get scrollbars():Boolean{
return (resolver.scrollbars);
}
public function set height(_arg1:Number):void{
resolver.height = _arg1;
}
public function set width(_arg1:Number):void{
resolver.width = _arg1;
}
public function set y(_arg1:Number):void{
resolver.y = _arg1;
}
public function get width():Number{
return (resolver.width);
}
public function printPages(_arg1:Number, _arg2:Number, _arg3:Boolean=true):void{
resolver.printPages(_arg1, _arg2);
}
public function set scrollbars(_arg1:Boolean):void{
resolver.scrollbars = _arg1;
}
public function firstPage(_arg1:Boolean=true):void{
resolver.firstPage();
}
public function nextPage(_arg1:Boolean=true):void{
resolver.nextPage();
}
public function set visible(_arg1:Boolean):void{
resolver.visible = _arg1;
}
public function previousPage(_arg1:Boolean=true):void{
resolver.previousPage();
}
public function get height():Number{
return (resolver.height);
}
public function print(_arg1:Boolean=true):void{
resolver.print();
}
public function set x(_arg1:Number):void{
resolver.x = _arg1;
}
public function get visible():Boolean{
return (resolver.visible);
}
public function printAll(_arg1:Boolean=true):void{
resolver.printAll();
}
public function setCurrentPage(_arg1:Number, _arg2:Boolean=true):void{
resolver.setCurrentPage(_arg1);
}
public function set toolbar(_arg1:Boolean):void{
resolver.toolbar = _arg1;
}
public function close(_arg1:Boolean=true):void{
resolver.close();
}
public function get y():Number{
return (resolver.y);
}
public function get toolbar():Boolean{
return (resolver.toolbar);
}
public function show(_arg1:Boolean=true):void{
resolver.show();
}
public function get x():Number{
return (resolver.x);
}
}
}//package mdm
dynamic class mdm_PDF7 extends mdm_resolver {
private function mdm_PDF7(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:String):void{
var _local6:Array;
super();
SetClassName("mdm.PDF");
_local6 = new Array();
_local6.push(-1, _arg1, _arg2, _arg3, _arg4, _arg5);
SetDynamic(CallSync("create", _local6));
}
}
Section 70
//Process (mdm.Process)
package mdm {
public final class Process {
private static var resolver:mdm_Process = null;
public function mdm_Process():void{
resolver.SetClassName("mdm.Process");
}
public static function isOpen(_arg1:Number, _arg2:Boolean=true):Boolean{
return (internal_resolver().isOpen(_arg1));
}
private static function internal_resolver():mdm_Process{
if (resolver == null){
resolver = new mdm_Process();
};
return (resolver);
}
public static function create(_arg1:String, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String, _arg7:String, _arg8:String, _arg9:Number, _arg10:Number, _arg11:Boolean=true):Number{
return (internal_resolver().create(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7, _arg8, _arg9, _arg10));
}
public static function kill(_arg1:Number, _arg2:Boolean=true):void{
internal_resolver().kill(_arg1);
}
public static function setParams(... _args):void{
internal_resolver().setParams(_args);
}
}
}//package mdm
dynamic class mdm_Process extends mdm_resolver {
private function mdm_Process():void{
SetClassName("mdm.Process");
}
}
Section 71
//QuickTime (mdm.QuickTime)
package mdm {
public final class QuickTime {
private var resolver:mdm_QuickTime;// = null
public function QuickTime(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String):void{
resolver = null;
super();
resolver = new mdm_QuickTime(_arg1, _arg2, _arg3, _arg4, _arg5);
}
public function hide(_arg1:Boolean=true):void{
resolver.hide();
}
public function stop(_arg1:Boolean=true):void{
resolver.stop();
}
public function set y(_arg1:Number):void{
resolver.y = _arg1;
}
public function set width(_arg1:Number):void{
resolver.width = _arg1;
}
public function get width():Number{
return (resolver.width);
}
public function set height(_arg1:Number):void{
resolver.height = _arg1;
}
public function set position(_arg1:Number):void{
resolver.position = _arg1;
}
public function get duration():Number{
return (resolver.duration);
}
public function mute(_arg1:Boolean, _arg2:Boolean=true):void{
resolver.mute(_arg1);
}
public function showControl(_arg1:Boolean=true):void{
resolver.showControl();
}
public function set visible(_arg1:Boolean):void{
resolver.visible = _arg1;
}
public function get height():Number{
return (resolver.height);
}
public function get position():Number{
return (resolver.position);
}
public function get isInstalled():Boolean{
return (resolver.isInstalled);
}
public function get visible():Boolean{
return (resolver.visible);
}
public function play(_arg1:Boolean=true):void{
resolver.play();
}
public function pause(_arg1:Boolean=true):void{
resolver.pause();
}
public function set x(_arg1:Number):void{
resolver.x = _arg1;
}
public function close(_arg1:Boolean=true):void{
resolver.close();
}
public function get y():Number{
return (resolver.y);
}
public function hideControl(_arg1:Boolean=true):void{
resolver.hideControl();
}
public function show(_arg1:Boolean=true):void{
resolver.show();
}
public function get x():Number{
return (resolver.x);
}
}
}//package mdm
dynamic class mdm_QuickTime extends mdm_resolver {
private function mdm_QuickTime(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String):void{
var _local6:Array;
super();
SetClassName("mdm.QuickTime");
_local6 = new Array();
_local6.push(-1, _arg1, _arg2, _arg3, _arg4, _arg5);
SetDynamic(CallSync("create", _local6));
}
}
Section 72
//RealMedia (mdm.RealMedia)
package mdm {
public final class RealMedia {
private var resolver:mdm_RealMedia;// = null
public function RealMedia(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String):void{
resolver = null;
super();
resolver = new mdm_RealMedia(_arg1, _arg2, _arg3, _arg4, _arg5);
}
public function hide(_arg1:Boolean=true):void{
resolver.hide();
}
public function normalSize(_arg1:Boolean=true):void{
resolver.normalSize();
}
public function stop(_arg1:Boolean=true):void{
resolver.stop();
}
public function set y(_arg1:Number):void{
resolver.y = _arg1;
}
public function set width(_arg1:Number):void{
resolver.width = _arg1;
}
public function get width():Number{
return (resolver.width);
}
public function set height(_arg1:Number):void{
resolver.height = _arg1;
}
public function set position(_arg1:Number):void{
resolver.position = _arg1;
}
public function get duration():Number{
return (resolver.duration);
}
public function mute(_arg1:Boolean, _arg2:Boolean=true):void{
resolver.mute(_arg1);
}
public function set visible(_arg1:Boolean):void{
resolver.visible = _arg1;
}
public function get height():Number{
return (resolver.height);
}
public function get position():Number{
return (resolver.position);
}
public function get isInstalled():Boolean{
return (resolver.isInstalled);
}
public function get visible():Boolean{
return (resolver.visible);
}
public function play(_arg1:Boolean=true):void{
resolver.play();
}
public function pause(_arg1:Boolean=true):void{
resolver.pause();
}
public function set x(_arg1:Number):void{
resolver.x = _arg1;
}
public function close(_arg1:Boolean=true):void{
resolver.close();
}
public function get y():Number{
return (resolver.y);
}
public function fullscreen(_arg1:Boolean=true):void{
resolver.fullscreen();
}
public function show(_arg1:Boolean=true):void{
resolver.show();
}
public function get x():Number{
return (resolver.x);
}
}
}//package mdm
dynamic class mdm_RealMedia extends mdm_resolver {
private function mdm_RealMedia(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String):void{
var _local6:Array;
super();
SetClassName("mdm.RealMedia");
_local6 = new Array();
_local6.push(-1, _arg1, _arg2, _arg3, _arg4, _arg5);
SetDynamic(CallSync("create", _local6));
}
}
Section 73
//Rosetta (mdm.Rosetta)
package mdm {
public final class Rosetta {
private static var resolver:mdm_Rosetta = null;
public function Rosetta():void{
}
private static function internal_resolver():mdm_Rosetta{
if (resolver == null){
resolver = new mdm_Rosetta();
};
return (resolver);
}
}
}//package mdm
dynamic class mdm_Rosetta extends mdm_resolver {
private function mdm_Rosetta():void{
SetClassName("mdm.Rosetta");
}
}
Section 74
//Shockwave (mdm.Shockwave)
package mdm {
public final class Shockwave {
private var resolver:mdm_Shockwave;// = null
public function Shockwave(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String):void{
resolver = null;
super();
resolver = new mdm_Shockwave(_arg1, _arg2, _arg3, _arg4, _arg5);
}
public function stop(_arg1:Boolean=true):void{
resolver.stop();
}
public function swForeColor(_arg1:Number, _arg2:Boolean=true):void{
resolver.swForeColor(_arg1);
}
public function evaluateScript(_arg1:String, _arg2:Boolean=true):void{
resolver.evaluateScript(_arg1);
}
public function gotoFrame(_arg1:Number, _arg2:Boolean=true):void{
resolver.gotoFrame(_arg1);
}
public function swSound(_arg1:String, _arg2:Boolean=true):void{
resolver.swSound(_arg1);
}
public function gotoMovie(_arg1:String, _arg2:Boolean=true):void{
resolver.gotoMovie(_arg1);
}
public function set height(_arg1:Number):void{
resolver.height = _arg1;
}
public function get x():Number{
return (resolver.x);
}
public function swAudio(_arg1:String, _arg2:Boolean=true):void{
resolver.swAudio(_arg1);
}
public function set width(_arg1:Number):void{
resolver.width = _arg1;
}
public function set y(_arg1:Number):void{
resolver.y = _arg1;
}
public function get width():Number{
return (resolver.width);
}
public function swName(_arg1:String, _arg2:Boolean=true):void{
resolver.swName(_arg1);
}
public function swPreLoadTime(_arg1:Number, _arg2:Boolean=true):void{
resolver.swPreLoadTime(_arg1);
}
public function swVolume(_arg1:Number, _arg2:Boolean=true):void{
resolver.swVolume(_arg1);
}
public function swColor(_arg1:Number, _arg2:Boolean=true):void{
resolver.swColor(_arg1);
}
public function get currentFrame():Number{
return (resolver.currentFrame);
}
public function swList(_arg1:String, _arg2:Boolean=true):void{
resolver.swList(_arg1);
}
public function set visible(_arg1:Boolean):void{
resolver.visible = _arg1;
}
public function swPassword(_arg1:String, _arg2:Boolean=true):void{
resolver.swPassword(_arg1);
}
public function get height():Number{
return (resolver.height);
}
public function swFrame(_arg1:Number, _arg2:Boolean=true):void{
resolver.swFrame(_arg1);
}
public function swBanner(_arg1:String, _arg2:Boolean=true):void{
resolver.swBanner(_arg1);
}
public function swText(_arg1:String, _arg2:Boolean=true):void{
resolver.swText(_arg1);
}
public function get visible():Boolean{
return (resolver.visible);
}
public function play(_arg1:Boolean=true):void{
resolver.play();
}
public function set x(_arg1:Number):void{
resolver.x = _arg1;
}
public function close(_arg1:Boolean=true):void{
resolver.close();
}
public function get y():Number{
return (resolver.y);
}
public function rewind(_arg1:Boolean=true):void{
resolver.rewind();
}
public function set bgcolor(_arg1:String):void{
resolver.bgColor = _arg1;
}
public function swBackColor(_arg1:Number, _arg2:Boolean=true):void{
resolver.swBackColor(_arg1);
}
}
}//package mdm
dynamic class mdm_Shockwave extends mdm_resolver {
private function mdm_Shockwave(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:String):void{
var _local6:Array;
super();
SetClassName("mdm.Shockwave");
_local6 = new Array();
_local6.push(-1, _arg1, _arg2, _arg3, _arg4, _arg5);
SetDynamic(CallSync("create", _local6));
}
}
Section 75
//Strings (mdm.Strings)
package mdm {
public final class Strings {
private static var resolver:mdm_Strings = null;
public function Strings():void{
}
private static function internal_resolver():mdm_Strings{
if (resolver == null){
resolver = new mdm_Strings();
};
return (resolver);
}
public static function position(_arg1:String, _arg2:String, _arg3:Boolean=true):int{
return (internal_resolver().position(_arg1, _arg2));
}
public static function replace(_arg1:String, _arg2:String, _arg3:String, _arg4:Boolean=true):String{
return (internal_resolver().replace(_arg1, _arg2, _arg3));
}
}
}//package mdm
dynamic class mdm_Strings extends mdm_resolver {
private function mdm_Strings():void{
SetClassName("mdm.Strings");
}
}
Section 76
//SYNC (mdm.SYNC)
package mdm {
public var SYNC = {async:false};
}//package mdm
Section 77
//System (mdm.System)
package mdm {
public final class System {
private static var resolver:mdm_System = null;
public function mdm_System():void{
}
public static function openCDTray(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().openCDTray(_arg1);
}
public static function get linVerString():String{
return (internal_resolver().linVerString);
}
public static function getDisplayModes():Array{
return (internal_resolver().getDisplayModes());
}
public static function get macVerString():String{
return (internal_resolver().macVerString);
}
public static function get winVerStringDetail():String{
return (internal_resolver().winVerStringDetail);
}
public static function logOff(_arg1:String, _arg2:String, _arg3:Boolean):void{
internal_resolver().logOff(_arg1, _arg2);
}
public static function execUnicode(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().execUnicode(_arg1);
}
public static function setWindowFocus(_arg1:Number, _arg2:Boolean=true):void{
internal_resolver().setWindowFocus(_arg1);
}
public static function restart(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().restart(_arg1, _arg2);
}
public static function exec(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().exec(_arg1);
}
public static function getMasterVolume():Number{
return (internal_resolver().getMasterVolume());
}
public static function get VBScript():mdm_resolver{
return (internal_resolver().VBScript);
}
public static function getTotalSpace(_arg1:String):Number{
return (internal_resolver().getTotalSpace(_arg1));
}
public static function execStdOut(_arg1:String):String{
return (internal_resolver().execStdOut(_arg1));
}
public static function setMasterVolume(_arg1:Number, _arg2:Boolean=true):void{
internal_resolver().setMasterVolume(_arg1);
}
public static function get RAMSize():Number{
return (internal_resolver().RAMSize);
}
public static function showTaskBar(_arg1:Boolean=true):void{
internal_resolver().showTaskBar();
}
public static function getWindowList():Array{
return (internal_resolver().getWindowList());
}
public static function get CPUSpeed():Number{
return (internal_resolver().CPUSpeed);
}
public static function get winVerString():String{
return (internal_resolver().winVerString);
}
public static function get CDDrive():String{
return (internal_resolver().CDDrive);
}
public static function powerOff(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().powerOff(_arg1, _arg2);
}
public static function hideTaskBar(_arg1:Boolean=true):void{
internal_resolver().hideTaskBar();
}
public static function setResolution(_arg1:Number, _arg2:Number, _arg3:Number=-1, _arg4=-1, _arg5:Boolean=true):void{
internal_resolver().setResolution(_arg1, _arg2, _arg3, _arg4);
}
public static function closeCDTray(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().closeCDTray(_arg1);
}
public static function getResolution():Array{
return (internal_resolver().getResolution());
}
public static function get screenHeight():Number{
return (internal_resolver().screenHeight);
}
public static function taskBarBlink(_arg1:Boolean=true):void{
internal_resolver().taskBarBlink();
}
public static function get screenWidth():Number{
return (internal_resolver().screenWidth);
}
public static function getVolumeName(_arg1:Number):String{
return (internal_resolver().getVolumeName(_arg1));
}
public static function suspend(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().suspend(_arg1, _arg2);
}
public static function setWallpaper(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().setWallpaper(_arg1);
}
public static function getNumberOfVolumes():Number{
return (internal_resolver().getNumberOfVolumes());
}
public static function getFreeSpace(_arg1:String):Number{
return (internal_resolver().getFreeSpace(_arg1));
}
public static function get isAdmin():Boolean{
return (internal_resolver().isAdmin);
}
public static function get computerName():String{
return (internal_resolver().computerName);
}
public static function postMessage(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Boolean=true):void{
internal_resolver().postMessage(_arg1, _arg2, _arg3, _arg4);
}
private static function internal_resolver():mdm_System{
if (resolver == null){
resolver = new mdm_System();
};
return (resolver);
}
public static function setWallpaperAlt(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().setWallpaperAlt(_arg1);
}
public static function get JScript():mdm_resolver{
return (internal_resolver().JScript);
}
public static function get Paths():mdm_resolver{
return (internal_resolver().Paths);
}
public static function hibernate(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().hibernate(_arg1, _arg2);
}
public static function get language():String{
return (internal_resolver().language);
}
public static function get Registry():mdm_resolver{
return (internal_resolver().Registry);
}
public static function get localTime():String{
return (internal_resolver().localTime);
}
public static function setWaveBalance(_arg1:Number, _arg2:Boolean=true):void{
internal_resolver().setWaveBalance(_arg1);
}
public static function get computerCompany():String{
return (internal_resolver().computerCompany);
}
public static function sendMessage(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Boolean=true):void{
internal_resolver().sendMessage(_arg1, _arg2, _arg3, _arg4);
}
public static function get computerOwner():String{
return (internal_resolver().computerOwner);
}
public static function getWaveVolume():Number{
return (internal_resolver().getWaveVolume());
}
public static function getHDSerial(_arg1:String):String{
return (internal_resolver().getHDSerial(_arg1));
}
public static function get servicePack():String{
return (internal_resolver().servicePack);
}
public static function get DirectX():mdm_resolver{
return (internal_resolver().DirectX);
}
public static function getWaveBalance():Number{
return (internal_resolver().getWaveBalance());
}
public static function setWaveVolume(_arg1:Number, _arg2:Boolean=true):void{
internal_resolver().setWaveVolume(_arg1);
}
public static function shutDown(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().shutDown(_arg1, _arg2);
}
public static function setWaveVolumeAdv(_arg1:Number, _arg2:Number, _arg3:Boolean=true):void{
internal_resolver().setWaveVolumeAdv(_arg1, _arg2);
}
}
}//package mdm
dynamic class mdm_System extends mdm_resolver {
private function mdm_System():void{
SetClassName("mdm.System");
AddObject("DirectX", null);
AddObject("JScript", null);
AddObject("Paths", null);
AddObject("Registry", null);
AddObject("VBScript", null);
}
}
Section 78
//MochiScores (mochi.MochiScores)
package mochi {
import flash.display.*;
import flash.text.*;
public class MochiScores {
private static var boardID:String;
public static var onErrorHandler:Object;
public static var onCloseHandler:Object;
public static function showLeaderboard(_arg1:Object=null):void{
var options = _arg1;
if (options != null){
if (options.clip != null){
if ((options.clip is Sprite)){
MochiServices.setContainer(options.clip);
};
delete options.clip;
} else {
MochiServices.setContainer();
};
MochiServices.stayOnTop();
if (options.name != null){
if ((options.name is TextField)){
if (options.name.text.length > 0){
options.name = options.name.text;
};
};
};
if (options.score != null){
if ((options.score is TextField)){
if (options.score.text.length > 0){
options.score = options.score.text;
};
};
};
if (options.onDisplay != null){
options.onDisplay();
} else {
if (MochiServices.clip != null){
if ((MochiServices.clip is MovieClip)){
MochiServices.clip.stop();
//unresolved jump
};
};
};
} else {
options = {};
if ((MochiServices.clip is MovieClip)){
MochiServices.clip.stop();
//unresolved jump
};
};
if (options.onClose != null){
onCloseHandler = options.onClose;
} else {
onCloseHandler = function ():void{
if ((MochiServices.clip is MovieClip)){
MochiServices.clip.play();
//unresolved jump
};
};
};
if (options.onError != null){
onErrorHandler = options.onError;
} else {
onErrorHandler = null;
};
if (options.boardID == null){
if (MochiScores.boardID != null){
options.boardID = MochiScores.boardID;
};
};
MochiServices.send("scores_showLeaderboard", {options:options}, null, onClose);
}
public static function closeLeaderboard():void{
MochiServices.send("scores_closeLeaderboard");
}
public static function getPlayerInfo(_arg1:Object, _arg2:Object=null):void{
MochiServices.send("scores_getPlayerInfo", null, _arg1, _arg2);
}
public static function requestList(_arg1:Object, _arg2:Object=null):void{
MochiServices.send("scores_requestList", null, _arg1, _arg2);
}
public static function scoresArrayToObjects(_arg1:Object):Object{
var _local2:Object;
var _local3:Number;
var _local4:Number;
var _local5:Object;
var _local6:Object;
var _local7:String;
var _local8:String;
_local2 = {};
for (_local7 in _arg1) {
if (typeof(_arg1[_local7]) == "object"){
if (((!((_arg1[_local7].cols == null))) && (!((_arg1[_local7].rows == null))))){
_local2[_local7] = [];
_local5 = _arg1[_local7];
_local4 = 0;
while (_local4 < _local5.rows.length) {
_local6 = {};
_local3 = 0;
while (_local3 < _local5.cols.length) {
_local6[_local5.cols[_local3]] = _local5.rows[_local4][_local3];
_local3++;
};
_local2[_local7].push(_local6);
_local4++;
};
} else {
_local2[_local7] = {};
for (_local8 in _arg1[_local7]) {
_local2[_local7][_local8] = _arg1[_local7][_local8];
};
};
} else {
_local2[_local7] = _arg1[_local7];
};
};
return (_local2);
}
public static function submit(_arg1:Number, _arg2:String, _arg3:Object=null, _arg4:Object=null):void{
MochiServices.send("scores_submit", {score:_arg1, name:_arg2}, _arg3, _arg4);
}
public static function onClose(_arg1:Object=null):void{
if (_arg1 != null){
if (_arg1.error != null){
if (_arg1.error == true){
if (onErrorHandler != null){
if (_arg1.errorCode == null){
_arg1.errorCode = "IOError";
};
onErrorHandler(_arg1.errorCode);
MochiServices.doClose();
return;
};
};
};
};
onCloseHandler();
MochiServices.doClose();
}
public static function setBoardID(_arg1:String):void{
MochiScores.boardID = _arg1;
MochiServices.send("scores_setBoardID", {boardID:_arg1});
}
}
}//package mochi
Section 79
//MochiServices (mochi.MochiServices)
package mochi {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.net.*;
import flash.system.*;
public class MochiServices {
private static var _container:Object;
private static var _connected:Boolean = false;
private static var _swfVersion:String;
private static var _sendChannel:LocalConnection;
private static var _rcvChannelName:String;
private static var _gatewayURL:String = "http://www.mochiads.com/static/lib/services/services.swf";
private static var _clip:MovieClip;
private static var _loader:Loader;
private static var _id:String;
private static var _listenChannel:LocalConnection;
private static var _timer:Timer;
private static var _sendChannelName:String;
private static var _startTime:Number;
private static var _connecting:Boolean = false;
public static var onError:Object;
private static var _listenChannelName:String = "__mochiservices";
private static var _rcvChannel:LocalConnection;
public static function isNetworkAvailable():Boolean{
return (!((Security.sandboxType == "localWithFile")));
}
public static function send(_arg1:String, _arg2:Object=null, _arg3:Object=null, _arg4:Object=null):void{
if (_connected){
_sendChannel.send(_sendChannelName, "onReceive", {methodName:_arg1, args:_arg2, callbackID:_clip._nextcallbackID});
} else {
if ((((_clip == null)) || (!(_connecting)))){
onError("NotConnected");
handleError(_arg2, _arg3, _arg4);
flush(true);
return;
};
_clip._queue.push({methodName:_arg1, args:_arg2, callbackID:_clip._nextcallbackID});
};
if (_clip != null){
if (((!((_clip._callbacks == null))) && (!((_clip._nextcallbackID == null))))){
_clip._callbacks[_clip._nextcallbackID] = {callbackObject:_arg3, callbackMethod:_arg4};
_clip._nextcallbackID++;
};
};
}
public static function get connected():Boolean{
return (_connected);
}
private static function flush(_arg1:Boolean):void{
var _local2:Object;
var _local3:Object;
if (_clip != null){
if (_clip._queue != null){
while (_clip._queue.length > 0) {
_local2 = _clip._queue.shift();
_local3 = null;
if (_local2 != null){
if (_local2.callbackID != null){
_local3 = _clip._callbacks[_local2.callbackID];
};
delete _clip._callbacks[_local2.callbackID];
if (((_arg1) && (!((_local3 == null))))){
handleError(_local2.args, _local3.callbackObject, _local3.callbackMethod);
};
};
};
};
};
}
private static function clickMovie(_arg1:String, _arg2:Function):MovieClip{
var _local3:Array;
var _local4:int;
var _local5:Array;
var _local6:Array;
var _local7:MovieClip;
var _local8:LocalConnection;
var _local9:String;
var _local10:ByteArray;
var _local11:ByteArray;
var _local12:uint;
var _local13:uint;
var _local14:Loader;
_local3 = [150, 21, 0, 7, 1, 0, 0, 0, 0, 98, 116, 110, 0, 7, 2, 0, 0, 0, 0, 116, 104, 105, 115, 0, 28, 150, 22, 0, 0, 99, 114, 101, 97, 116, 101, 69, 109, 112, 116, 121, 77, 111, 118, 105, 101, 67, 108, 105, 112, 0, 82, 135, 1, 0, 0, 23, 150, 13, 0, 4, 0, 0, 111, 110, 82, 101, 108, 101, 97, 115, 101, 0, 142, 8, 0, 0, 0, 0, 2, 42, 0, 114, 0, 150, 17, 0, 0, 32, 0, 7, 1, 0, 0, 0, 8, 0, 0, 115, 112, 108, 105, 116, 0, 82, 135, 1, 0, 1, 23, 150, 7, 0, 4, 1, 7, 0, 0, 0, 0, 78, 150, 8, 0, 0, 95, 98, 108, 97, 110, 107, 0, 154, 1, 0, 0, 150, 7, 0, 0, 99, 108, 105, 99, 107, 0, 150, 7, 0, 4, 1, 7, 1, 0, 0, 0, 78, 150, 27, 0, 7, 2, 0, 0, 0, 7, 0, 0, 0, 0, 0, 76, 111, 99, 97, 108, 67, 111, 110, 110, 101, 99, 116, 105, 111, 110, 0, 64, 150, 6, 0, 0, 115, 101, 110, 100, 0, 82, 79, 150, 15, 0, 4, 0, 0, 95, 97, 108, 112, 104, 97, 0, 7, 0, 0, 0, 0, 79, 150, 23, 0, 7, 0xFF, 0, 0xFF, 0, 7, 1, 0, 0, 0, 4, 0, 0, 98, 101, 103, 105, 110, 70, 105, 108, 108, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 109, 111, 118, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 100, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 100, 0, 0, 0, 7, 100, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 100, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 16, 0, 7, 0, 0, 0, 0, 4, 0, 0, 101, 110, 100, 70, 105, 108, 108, 0, 82, 23];
_local5 = [104, 0, 31, 64, 0, 7, 208, 0, 0, 12, 1, 0, 67, 2, 0xFF, 0xFF, 0xFF, 63, 3];
_local6 = [0, 64, 0, 0, 0];
_local7 = new MovieClip();
_local8 = new LocalConnection();
_local9 = ((("_click_" + Math.floor((Math.random() * 999999))) + "_") + Math.floor(new Date().getTime()));
_local8 = new LocalConnection();
_local7.lc = _local8;
_local7.click = _arg2;
_local8.client = _local7;
_local8.connect(_local9);
_local10 = new ByteArray();
_local11 = new ByteArray();
_local11.endian = Endian.LITTLE_ENDIAN;
_local11.writeShort(1);
_local11.writeUTFBytes(((_arg1 + " ") + _local9));
_local11.writeByte(0);
_local12 = ((_local3.length + _local11.length) + 4);
_local13 = (_local12 + 35);
_local10.endian = Endian.LITTLE_ENDIAN;
_local10.writeUTFBytes("FWS");
_local10.writeByte(8);
_local10.writeUnsignedInt(_local13);
for each (_local4 in _local5) {
_local10.writeByte(_local4);
};
_local10.writeUnsignedInt(_local12);
_local10.writeByte(136);
_local10.writeShort(_local11.length);
_local10.writeBytes(_local11);
for each (_local4 in _local3) {
_local10.writeByte(_local4);
};
for each (_local4 in _local6) {
_local10.writeByte(_local4);
};
_local14 = new Loader();
_local14.loadBytes(_local10);
_local7.addChild(_local14);
return (_local7);
}
private static function init(_arg1:String, _arg2:Object):void{
_id = _arg1;
if (_arg2 != null){
_container = _arg2;
loadCommunicator(_arg1, _container);
};
}
public static function get childClip():Object{
return (_clip);
}
public static function get id():String{
return (_id);
}
public static function stayOnTop():void{
_container.addEventListener(Event.ENTER_FRAME, MochiServices.bringToTop, false, 0, true);
if (_clip != null){
_clip.visible = true;
};
}
public static function addLinkEvent(_arg1:String, _arg2:String, _arg3:DisplayObjectContainer, _arg4:Function=null):void{
var netup:Boolean;
var vars:Object;
var s:String;
var i:Number;
var x:String;
var req:URLRequest;
var loader:Loader;
var err:Function;
var complete:Function;
var setURL:Function;
var url = _arg1;
var burl = _arg2;
var btn = _arg3;
var onClick = _arg4;
vars = new Object();
vars["mav"] = getVersion();
vars["swfv"] = "9";
vars["swfurl"] = btn.loaderInfo.loaderURL;
vars["fv"] = Capabilities.version;
vars["os"] = Capabilities.os;
vars["lang"] = Capabilities.language;
vars["scres"] = ((Capabilities.screenResolutionX + "x") + Capabilities.screenResolutionY);
s = "?";
i = 0;
for (x in vars) {
if (i != 0){
s = (s + "&");
};
i = (i + 1);
s = (((s + x) + "=") + escape(vars[x]));
};
req = new URLRequest("http://x.mochiads.com/linkping.swf");
loader = new Loader();
err = function (_arg1:Object):void{
netup = false;
_arg1.target.removeEventListener(_arg1.type, arguments.callee);
};
complete = function (_arg1:Object):void{
netup = true;
_arg1.target.removeEventListener(_arg1.type, arguments.callee);
};
loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, err);
loader.contentLoaderInfo.addEventListener(Event.COMPLETE, complete);
loader.load(req);
setURL = function ():void{
var _local1:String;
var _local2:DisplayObject;
if (netup){
_local1 = (url + s);
} else {
_local1 = burl;
};
_local2 = clickMovie(_local1, onClick);
btn.addChild(_local2);
_local2.scaleX = (0.01 * btn.width);
_local2.scaleY = (0.01 * btn.height);
};
setTimeout(setURL, 1500);
}
public static function getVersion():String{
return ("1.35");
}
public static function disconnect():void{
if (((_connected) || (_connecting))){
if (_clip != null){
if (_clip.parent != null){
if ((_clip.parent is Sprite)){
Sprite(_clip.parent).removeChild(_clip);
_clip = null;
};
};
};
_connecting = (_connected = false);
flush(true);
try {
_listenChannel.close();
_rcvChannel.close();
} catch(error:Error) {
};
};
if (_timer != null){
try {
_timer.stop();
} catch(error:Error) {
};
};
}
public static function allowDomains(_arg1:String):String{
var _local2:String;
Security.allowDomain("*");
Security.allowInsecureDomain("*");
if (_arg1.indexOf("http://") != -1){
_local2 = _arg1.split("/")[2].split(":")[0];
Security.allowDomain(_local2);
Security.allowInsecureDomain(_local2);
};
return (_local2);
}
public static function doClose():void{
_container.removeEventListener(Event.ENTER_FRAME, MochiServices.bringToTop);
if (_clip.parent != null){
Sprite(_clip.parent).removeChild(_clip);
};
}
public static function setContainer(_arg1:Object=null, _arg2:Boolean=true):void{
if (_arg1 != null){
if ((_arg1 is Sprite)){
_container = _arg1;
};
};
if (_arg2){
if ((_container is Sprite)){
Sprite(_container).addChild(_clip);
};
};
}
private static function onStatus(_arg1:StatusEvent):void{
switch (_arg1.level){
case "error":
_connected = false;
_listenChannel.connect(_listenChannelName);
break;
};
}
private static function initComChannels():void{
if (!_connected){
_sendChannel.addEventListener(StatusEvent.STATUS, MochiServices.onStatus);
_sendChannel.send(_sendChannelName, "onReceive", {methodName:"handshakeDone"});
_sendChannel.send(_sendChannelName, "onReceive", {methodName:"registerGame", id:_id, clip:_container, version:getVersion(), parentURL:_container.loaderInfo.loaderURL});
_rcvChannel.addEventListener(StatusEvent.STATUS, MochiServices.onStatus);
_clip.onReceive = function (_arg1:Object):void{
var cb:String;
var cblst:Object;
var method:*;
var methodName:String;
var obj:Object;
var pkg = _arg1;
cb = pkg.callbackID;
cblst = this.client._callbacks[cb];
if (!cblst){
return;
};
method = cblst.callbackMethod;
methodName = "";
obj = cblst.callbackObject;
if (((obj) && ((typeof(method) == "string")))){
methodName = method;
if (obj[method] != null){
method = obj[method];
//unresolved jump
};
};
if (method != undefined){
try {
method.apply(obj, pkg.args);
} catch(error:Error) {
};
} else {
if (obj != null){
try {
obj(pkg.args);
} catch(error:Error) {
};
};
};
delete this.client._callbacks[cb];
};
_clip.onError = function ():void{
MochiServices.onError("IOError");
};
_rcvChannel.connect(_rcvChannelName);
_connecting = false;
_connected = true;
_listenChannel.close();
while (_clip._queue.length > 0) {
_sendChannel.send(_sendChannelName, "onReceive", _clip._queue.shift());
};
};
}
private static function listen():void{
_listenChannel = new LocalConnection();
_listenChannel.client = _clip;
_clip.handshake = function (_arg1:Object):void{
MochiServices.comChannelName = _arg1.newChannel;
};
_listenChannel.allowDomain("*", "localhost");
_listenChannel.allowInsecureDomain("*", "localhost");
_listenChannel.connect(_listenChannelName);
}
private static function handleError(_arg1:Object, _arg2:Object, _arg3:Object):void{
var args = _arg1;
var callbackObject = _arg2;
var callbackMethod = _arg3;
if (args != null){
if (args.onError != null){
args.onError.apply(null, ["NotConnected"]);
};
if (((!((args.options == null))) && (!((args.options.onError == null))))){
args.options.onError.apply(null, ["NotConnected"]);
};
};
if (callbackMethod != null){
args = {};
args.error = true;
args.errorCode = "NotConnected";
if (((!((callbackObject == null))) && ((callbackMethod is String)))){
try {
var _local5 = callbackObject;
_local5[callbackMethod](args);
} catch(error:Error) {
};
} else {
if (callbackMethod != null){
try {
callbackMethod.apply(args);
} catch(error:Error) {
};
};
};
};
}
public static function get clip():Object{
return (_container);
}
public static function set comChannelName(_arg1:String):void{
if (_arg1 != null){
if (_arg1.length > 3){
_sendChannelName = (_arg1 + "_fromgame");
_rcvChannelName = _arg1;
initComChannels();
};
};
}
private static function loadCommunicator(_arg1:String, _arg2:Object):MovieClip{
var clipname:String;
var f:Function;
var req:URLRequest;
var id = _arg1;
var clip = _arg2;
clipname = ("_mochiservices_com_" + id);
if (_clip != null){
return (_clip);
};
if (!MochiServices.isNetworkAvailable()){
return (null);
};
MochiServices.allowDomains(_gatewayURL);
_clip = createEmptyMovieClip(clip, clipname, 10336, false);
_loader = new Loader();
_timer = new Timer(1000, 0);
_startTime = getTimer();
_timer.addEventListener(TimerEvent.TIMER, connectWait);
_timer.start();
f = function (_arg1:Object):void{
_clip._mochiad_ctr_failed = true;
MochiServices.disconnect();
MochiServices.onError("IOError");
};
_loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, f);
req = new URLRequest(_gatewayURL);
_loader.load(req);
_clip.addChild(_loader);
_clip._mochiservices_com = _loader;
_sendChannel = new LocalConnection();
_clip._queue = [];
_rcvChannel = new LocalConnection();
_rcvChannel.allowDomain("*", "localhost");
_rcvChannel.allowInsecureDomain("*", "localhost");
_rcvChannel.client = _clip;
_clip._nextcallbackID = 0;
_clip._callbacks = {};
listen();
return (_clip);
}
public static function bringToTop(_arg1:Event):void{
var e = _arg1;
if (MochiServices.clip != null){
if (MochiServices.childClip != null){
try {
if (MochiServices.clip.numChildren > 1){
MochiServices.clip.setChildIndex(MochiServices.childClip, (MochiServices.clip.numChildren - 1));
};
} catch(errorObject:Error) {
_container.removeEventListener(Event.ENTER_FRAME, MochiServices.bringToTop);
};
};
};
}
public static function connect(_arg1:String, _arg2:Object, _arg3:Object=null):void{
var id = _arg1;
var clip = _arg2;
var onError = _arg3;
if ((clip is DisplayObject)){
if (((!(_connected)) && ((_clip == null)))){
_connecting = true;
init(id, clip);
};
//unresolved jump
};
if (onError != null){
MochiServices.onError = onError;
} else {
if (MochiServices.onError == null){
MochiServices.onError = function (_arg1:String):void{
};
};
};
}
public static function createEmptyMovieClip(_arg1:Object, _arg2:String, _arg3:Number, _arg4:Boolean=true):MovieClip{
var mc:MovieClip;
var parent = _arg1;
var name = _arg2;
var depth = _arg3;
var doAdd = _arg4;
mc = new MovieClip();
if (doAdd){
if (((false) && (depth))){
parent.addChildAt(mc, depth);
} else {
parent.addChild(mc);
};
};
try {
parent[name] = mc;
} catch(e:Error) {
throw (new Error("MochiServices requires a clip that is an instance of a dynamic class. If your class extends Sprite or MovieClip, you must make it dynamic."));
};
mc["_name"] = name;
return (mc);
}
public static function connectWait(_arg1:TimerEvent):void{
if ((getTimer() - _startTime) > 10000){
if (!_connected){
_clip._mochiad_ctr_failed = true;
MochiServices.disconnect();
MochiServices.onError("IOError");
};
_timer.stop();
};
}
}
}//package mochi
Section 80
//bg_240 (qbeez_online_release_fla.bg_240)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class bg_240 extends MovieClip {
public function bg_240(){
addFrameScript(0, frame1, 1, frame2);
}
function frame1(){
stop();
}
function frame2(){
stop();
}
}
}//package qbeez_online_release_fla
Section 81
//btn_57 (qbeez_online_release_fla.btn_57)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class btn_57 extends MovieClip {
public function btn_57(){
addFrameScript(115, frame116);
}
function frame116(){
gotoAndPlay("loop");
}
}
}//package qbeez_online_release_fla
Section 82
//btn_59 (qbeez_online_release_fla.btn_59)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class btn_59 extends MovieClip {
public function btn_59(){
addFrameScript(115, frame116);
}
function frame116(){
gotoAndPlay("loop");
}
}
}//package qbeez_online_release_fla
Section 83
//btn_61 (qbeez_online_release_fla.btn_61)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class btn_61 extends MovieClip {
public function btn_61(){
addFrameScript(5, frame6);
}
function frame6(){
stop();
}
}
}//package qbeez_online_release_fla
Section 84
//FADER_54 (qbeez_online_release_fla.FADER_54)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class FADER_54 extends MovieClip {
public function FADER_54(){
addFrameScript(5, frame6, 11, frame12);
}
function frame12(){
stop();
}
function frame6(){
stop();
}
}
}//package qbeez_online_release_fla
Section 85
//gameoverdialog_119 (qbeez_online_release_fla.gameoverdialog_119)
package qbeez_online_release_fla {
import flash.display.*;
import flash.text.*;
public dynamic class gameoverdialog_119 extends MovieClip {
public var hdr_stagecomplete:TextField;
public var hdr_youwin:TextField;
public var hdr_perfect:TextField;
public var hdr_gameover:TextField;
}
}//package qbeez_online_release_fla
Section 86
//gui_92 (qbeez_online_release_fla.gui_92)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class gui_92 extends MovieClip {
public var arrowRight:SimpleButton;
public var arrowLeft:SimpleButton;
}
}//package qbeez_online_release_fla
Section 87
//gui_95 (qbeez_online_release_fla.gui_95)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class gui_95 extends MovieClip {
public var tabFrames:MovieClip;
public function gui_95(){
addFrameScript(0, frame1, 1, frame2, 2, frame3, 3, frame4, 4, frame5);
}
function frame3(){
tabFrames.gotoAndStop(3);
}
function frame1(){
stop();
tabFrames.gotoAndStop(1);
}
function frame4(){
tabFrames.gotoAndStop(4);
}
function frame5(){
tabFrames.gotoAndStop(5);
}
function frame2(){
tabFrames.gotoAndStop(2);
}
}
}//package qbeez_online_release_fla
Section 88
//gui_97 (qbeez_online_release_fla.gui_97)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class gui_97 extends MovieClip {
public function gui_97(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 89
//MainTimeline (qbeez_online_release_fla.MainTimeline)
package qbeez_online_release_fla {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
import QBeezSrc.*;
import com.whirled.game.*;
import flash.geom.*;
import flash.media.*;
import skxSource.*;
import flash.filters.*;
import flash.net.*;
import flash.system.*;
import flash.errors.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class MainTimeline extends MovieClip {
public var sPic2Big:String;
public var sToId:String;
public var overflow:MovieClip;
public var fBtn:SimpleButton;
public var dialogs:MovieClip;
public var soundOnBtn:SimpleButton;
public var levelPos:int;
public var sFacebook:Boolean;
public var sTPos:String;
public var soundOffBtn:SimpleButton;
public var skunkBtn:SimpleButton;
public var lvlCountDown:TextField;
public var sTName:String;
public var hdr_pickapack:TextField;
public var menuBtn:SimpleButton;
public var rBtn:SimpleButton;
public var tSShdr:TextField;
public var sAPI:String;
public var previewload:Array;
public var sMode:String;
public var tPerfects1:TextField;
public var sBtn:SimpleButton;
public var btn_back:SimpleButton;
public var perfectEarned:Boolean;
public var sId:String;
public var gui_levels:MovieClip;
public var tScoreExample:TextField;
public var tPerfectScore:TextField;
public var tPreLevelQbz:TextField;
public var perfectcount:int;
public var IDLESTATE:String;
public var level1:MovieClip;
public var level2:MovieClip;
public var level3:MovieClip;
public var level4:MovieClip;
public var level5:MovieClip;
public var level6:MovieClip;
public var pack1:MovieClip;
public var pack2:MovieClip;
public var pack3:MovieClip;
public var pack4:MovieClip;
public var pack5:MovieClip;
public var btn_changeuser:SimpleButton;
public var HSBtn:SimpleButton;
public var levelPackPos:int;
public var bLocalDataLoaded:Boolean;
public var txt_howtoplay:TextField;
public var fader:MovieClip;
public var gui_packs:MovieClip;
public var txt_packname1:TextField;
public var txt_packname2:TextField;
public var txt_packname4:TextField;
public var txt_packname5:TextField;
public var sSeed:String;
public var txt_packname3:TextField;
public var mcUpsell:MovieClip;
public var QBmap:MovieClip;
public var previews:Array;
public var tStageScore:TextField;
public var sFromScore:String;
public var txt_Version:TextField;
public var pBtn2:SimpleButton;
public var sPostData:String;
public var tMaxGroup1:TextField;
public var tPerfectshdr:TextField;
public var showNameEntry:Boolean;
public var avatarPrize:MovieClip;
public var sGameMode:String;
public var sName1:String;
public var lBtn:SimpleButton;
public var sName2:String;
public var packInfo:TextField;
public var hdr_newplayer:TextField;
public var tScore:TextField;
public var btn_moregames:SimpleButton;
public var bBtn:SimpleButton;
public var tScoreHeader:TextField;
public var packPrice:TextField;
public var lvl_numdisplay:TextField;
public var qbTitle:MovieClip;
public var txt_postscore:TextField;
public var HTPBtn:SimpleButton;
public var cBtn:SimpleButton;
public var sPic1:String;
public var mcPowerMoves:MovieClip;
public var sPic2:String;
public var hdr_welcome:TextField;
public var Timer:MovieClip;
public var txt_gamemode1:TextField;
public var txt_gamemode2:TextField;
public var tMGhdr:TextField;
public var tPreLevel:TextField;
public var clearingPreviews:Boolean;
public var qbLogo:MovieClip;
public var lvlCompleteDlg:MovieClip;
public var packProgress:TextField;
public var btn_done:SimpleButton;
public var lvlScore:TextField;
public var sPic1Big:String;
public var mcNameEntry:MovieClip;
public var sTRound:String;
public var pBtn:SimpleButton;
public function MainTimeline(){
addFrameScript(1, frame2, 11, frame12, 21, frame22, 31, frame32, 42, frame43, 53, frame54, 184, frame185, 186, frame187, 195, frame196, 205, frame206, 215, frame216, 225, frame226, 231, frame232);
}
public function clearJunkHS():void{
if (((QBPackHandler.m_oAvatar) && (contains(QBPackHandler.m_oAvatar)))){
removeChild(QBPackHandler.m_oAvatar);
QBPackHandler.m_oAvatar.removeEventListener(Event.ENTER_FRAME, onAvaFrame);
QBPackHandler.m_oAvatar.gotoAndStop(1);
QBPackHandler.m_oAvatar = null;
};
if (contains(QBGameHandler.WINDOW)){
removeChild(QBGameHandler.WINDOW);
};
if (contains(QBGameHandler.sMainHandler.m_mcSnapShot)){
removeChild(QBGameHandler.sMainHandler.m_mcSnapShot);
};
QBGameHandler.WINDOW.sendState("ALL-DESTROY");
if (QBGameHandler.sMainHandler){
QBGameHandler.sMainHandler.stopAllSound();
QBGameHandler.sMainHandler.shutDown();
QBGameHandler.sMainHandler.clearBoard();
QBGameHandler.sMainHandler.clearData();
QBGameHandler.sMainHandler.cleanUpBoard();
};
dialogs.gotoAndStop(1);
}
public function setLevelPreviews():void{
var _local1:int;
var _local2:int;
var _local3:*;
_local1 = 0;
_local2 = 1;
while (_local2 <= 5) {
_local3 = getChildByName(String(("level" + _local2)));
if (((_local3) && (previews[_local1]))){
previews[_local1].x = (_local3.x - 85);
previews[_local1].y = (_local3.y - 48);
skxScheduler.schedule(addChild, (500 * _local2), null, previews[_local1]);
};
_local2++;
_local1++;
};
}
public function gotoLevelPacksFromGame(_arg1:MouseEvent):void{
sGameMode = "3";
resetSeed();
QBGameHandler.sGameStarted = false;
QBGameHandler.sGameMode = 2;
QBGameHandler.sLastTotalScore = 0;
QBGameHandler.sMainHandler.resetQuest();
fader.gotoAndPlay("fadein");
skxScheduler.schedule(cleanUp, 950);
skxScheduler.schedule(fadeComplete, 1000);
}
public function clearJunk():void{
if (((QBPackHandler.m_oAvatar) && (contains(QBPackHandler.m_oAvatar)))){
QBPackHandler.m_oAvatar.removeEventListener(Event.ENTER_FRAME, onAvaFrame);
removeChild(QBPackHandler.m_oAvatar);
QBPackHandler.m_oAvatar.gotoAndStop(1);
QBPackHandler.m_oAvatar = null;
};
if (contains(QBGameHandler.WINDOW)){
removeChild(QBGameHandler.WINDOW);
};
if (contains(QBGameHandler.sMainHandler.m_mcSnapShot)){
removeChild(QBGameHandler.sMainHandler.m_mcSnapShot);
};
QBGameHandler.WINDOW.sendState("ALL-DESTROY");
if (QBGameHandler.sMainHandler){
QBGameHandler.sMainHandler.stopAllSound();
QBGameHandler.sMainHandler.shutDown();
QBGameHandler.sMainHandler.clearBoard();
QBGameHandler.sMainHandler.clearData();
QBGameHandler.sMainHandler.cleanUpBoard();
};
dialogs.gotoAndStop(1);
gotoAndStop("main", "mainmenu");
}
public function setlevels(_arg1:int):void{
var _local2:Array;
_local2 = QBPackHandler.getGamePacks();
if (_local2[_arg1].levels){
QBGameHandler.m_aLevels = _local2[_arg1].levels;
};
}
function frame12(){
QBGameHandler.sAppState = "menu";
setSoundUI();
gotoAndStop("main");
}
public function resetSeed():void{
var _local1:Date;
_local1 = new Date();
QBGameHandler.sDailySeed = ((_local1.getUTCDate() * _local1.getUTCMonth()) + _local1.getUTCFullYear());
}
function frame2(){
skxWhirled.m_inGame = true;
showNameEntry = true;
sName1 = "";
sName2 = "";
sPic1 = "";
sPic1Big = "";
sPic2 = "";
sPic2Big = "";
sPostData = "";
sMode = "standard";
sFacebook = false;
bLocalDataLoaded = false;
sId = "";
sSeed = "";
sTRound = "";
sTPos = "";
sToId = "";
sGameMode = "1";
sFromScore = "";
sTName = "";
QBGameHandler.sAppState = "menu";
setSoundUI();
sAPI = "whirled";
updateVersion();
skxAPI.init({API:sAPI, stage:this});
if (skxWhirled.getControl().isConnected()){
skxWhirled.getControl().player.addEventListener(GameContentEvent.PLAYER_CONTENT_ADDED, playerContentAdded);
skxWhirled.getControl().local.setFrameRate(20);
skxWhirled.getControl().local.setStageQuality("high");
QBGameHandler.sUserName = skxWhirled.getControl().game.getOccupantName(skxWhirled.getControl().game.getMyId());
QBPackHandler.init(skxWhirled.getControl().game.getLevelPacks(), skxWhirled.getControl().player.getPlayerLevelPacks(skxWhirled.getControl().game.getMyId()));
QBPackHandler.loadLevelsPacks();
};
QBGameHandler.sAppState = "menu";
setSoundUI();
resetSeed();
QBGameHandler.sGameMode = 1;
QBGameHandler.initImageMaps(640, 480);
QBGameHandler.m_nGroundLine = 440;
QBGameHandler.m_nBoardOffsetX = 625;
QBGameHandler.m_nScaleFactor = 0.9;
gotoAndPlay(31);
}
public function flip(_arg1:MouseEvent):void{
if (((((QBGameHandler.sMainHandler) && (!(QBGameHandler.sMainHandler.getGameOver())))) && (!(QBGameHandler.sMainHandler.getPaused())))){
QBGameHandler.sMainHandler.flipBoard();
updatePowerMoves();
};
}
public function stillWater():void{
if (Timer.watertop.currentFrame < 6){
Timer.watertop.gotoAndStop((Timer.watertop.currentFrame + 1));
} else {
Timer.watertop.gotoAndStop(1);
};
}
function frame22(){
gotoAndStop("main");
}
function frame32(){
skxDisplay.Print("main 1 start");
if (QBGameHandler.sMainHandler){
QBGameHandler.sMainHandler.clearData();
};
updateVersion();
stop();
dialogs.gotoAndStop(1);
onAppInit();
if (skxWhirled.getControl().isConnected()){
skxWhirled.getControl().local.setFrameRate(20);
skxWhirled.getControl().local.setStageQuality("high");
};
perfectcount = 0;
}
function frame43(){
QBGameHandler.sAppState = "menu";
btn_done.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
btn_done.addEventListener(MouseEvent.MOUSE_UP, goBack);
}
public function initDialog2():void{
menuBtn.mouseEnabled = false;
menuBtn.alpha = 0.25;
cBtn.addEventListener(MouseEvent.MOUSE_UP, gotoMainMenu);
cBtn.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
}
public function chooseIdleState():void{
var _local1:int;
var _local2:String;
_local1 = 1;
_local2 = "idle";
while (QBPackHandler.getAvatarStates()[String((_local2 + _local1))]) {
_local1++;
};
if (_local1 > 1){
_local1 = skxRandom.getRandomInt(1, _local1);
};
if (_local1 != 1){
_local2 = String((_local2 + _local1));
};
IDLESTATE = _local2;
}
public function gotoPuzzleMode(_arg1:MouseEvent):void{
sGameMode = "4";
resetSeed();
QBGameHandler.sGameMode = 3;
QBGameHandler.sLastTotalScore = 0;
QBGameHandler.sMainHandler.resetQuest();
if (QBGameHandler.sAppState == "menu"){
pBtn.enabled = false;
fader.gotoAndPlay("fadein");
skxScheduler.schedule(fadeComplete, 1000);
};
}
function frame54(){
stop();
}
public function onAvaFrame(_arg1:Object):void{
var _local2:Array;
var _local3:int;
var _local4:String;
if (((QBPackHandler.m_oAvatar) && ((QBPackHandler.m_oAvatar.currentFrame == QBPackHandler.m_oAvatar.currentScene.numFrames)))){
if (QBPackHandler.m_sAvatarState == "idle"){
_local2 = QBPackHandler.getAvatarStates()["idle"];
if (QBPackHandler.getAvatarStates()[IDLESTATE]){
_local2 = QBPackHandler.getAvatarStates()[IDLESTATE];
};
QBPackHandler.m_oAvatar.gotoAndPlay(1, _local2[skxRandom.getRandomInt(0, _local2.length)]);
} else {
if (QBPackHandler.m_sAvatarState == "perfect"){
_local3 = 1;
_local4 = "perfect";
while (QBPackHandler.getAvatarStates()[String((_local4 + _local3))]) {
_local3++;
};
if (_local3 > 1){
_local3 = skxRandom.getRandomInt(1, _local3);
};
if (_local3 != 1){
_local4 = String((_local4 + _local3));
};
_local2 = QBPackHandler.getAvatarStates()[_local4];
if (QBPackHandler.m_iStatePos < _local2.length){
QBPackHandler.m_oAvatar.gotoAndPlay(1, _local2[QBPackHandler.m_iStatePos]);
QBPackHandler.m_iStatePos++;
} else {
QBPackHandler.m_sAvatarState = "idle";
QBPackHandler.m_iStatePos = 0;
_local2 = QBPackHandler.getAvatarStates()["idle"];
QBPackHandler.m_oAvatar.gotoAndPlay(1, _local2[skxRandom.getRandomInt(0, _local2.length)]);
};
} else {
if (QBPackHandler.m_sAvatarState == "win"){
_local3 = 1;
_local4 = "win";
while (QBPackHandler.getAvatarStates()[String((_local4 + _local3))]) {
_local3++;
};
if (_local3 > 1){
_local3 = skxRandom.getRandomInt(1, _local3);
};
if (_local3 != 1){
_local4 = String((_local4 + _local3));
};
_local2 = QBPackHandler.getAvatarStates()[_local4];
if (QBPackHandler.m_iStatePos < _local2.length){
QBPackHandler.m_oAvatar.gotoAndPlay(1, _local2[QBPackHandler.m_iStatePos]);
QBPackHandler.m_iStatePos++;
} else {
if (QBPackHandler.m_iStatePos < 2){
QBPackHandler.m_oAvatar.gotoAndPlay(1);
QBPackHandler.m_iStatePos++;
} else {
QBPackHandler.m_sAvatarState = "idle";
QBPackHandler.m_iStatePos = 0;
_local2 = QBPackHandler.getAvatarStates()["idle"];
QBPackHandler.m_oAvatar.gotoAndPlay(1, _local2[skxRandom.getRandomInt(0, _local2.length)]);
};
};
};
};
};
};
}
public function setUIVisible():void{
pBtn2.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
pBtn2.addEventListener(MouseEvent.MOUSE_UP, gotoMainGame);
pBtn.addEventListener(MouseEvent.MOUSE_UP, gotoLevelPacks);
skunkBtn.addEventListener(MouseEvent.MOUSE_UP, gotoWebsite);
pBtn.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
skunkBtn.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
btn_moregames.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
btn_moregames.addEventListener(MouseEvent.MOUSE_UP, gotoMoreGames);
HTPBtn.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
HTPBtn.addEventListener(MouseEvent.MOUSE_UP, goToHelp);
}
public function setSoundUI():void{
}
function frame206(){
stop();
}
public function selectPack(_arg1:Event=null):void{
pBtn.mouseEnabled = true;
pBtn.alpha = 1;
}
public function buildLevelPreview():void{
var _local1:Array;
var _local2:int;
var _local3:*;
var _local4:Array;
var _local5:int;
_local1 = QBPackHandler.getGamePacks();
_local2 = 0;
while (_local2 < _local1.length) {
if (((((!((_local2 == QBGameHandler.m_iSelectedPack))) && (_local1[_local2].preview))) && (contains(_local1[_local2].preview)))){
removeChild(_local1[_local2].preview);
};
_local2++;
};
if (_local1[QBGameHandler.m_iSelectedPack].preview){
_local3 = getChildByName(String(("level" + 1)));
if (_local3){
_local1[QBGameHandler.m_iSelectedPack].preview.x = (_local3.x - 42);
_local1[QBGameHandler.m_iSelectedPack].preview.y = (_local3.y - 42);
addChildAt(_local1[QBGameHandler.m_iSelectedPack].preview, (getChildIndex(_local3) + 1));
};
} else {
if (QBGameHandler.m_aLevels){
_local4 = QBGameHandler.m_aLevels;
_local5 = 1;
_local2 = 0;
while (_local2 < _local4.length) {
previewload.push({data:QBGameHandler.m_aLevels[_local2], index:_local5});
_local2++;
_local5++;
};
previewload = previewload.reverse();
clearingPreviews = false;
skxScheduler.schedule(createPreview, 500);
};
};
}
public function gotoMainMenu(_arg1:MouseEvent=null):void{
if (((skxWhirled.getControl().isConnected()) && (skxWhirled.getControl().game.isInPlay()))){
skxWhirled.getControl().game.endGameWithScore(0);
};
if (QBGameHandler.sMainHandler.getPaused()){
QBGameHandler.sMainHandler.postPauseTimer();
};
skxMusicChannel.clearAll();
if (getChildByName("rBtn")){
rBtn.removeEventListener(MouseEvent.MOUSE_UP, rotater);
lBtn.removeEventListener(MouseEvent.MOUSE_UP, rotatel);
fBtn.removeEventListener(MouseEvent.MOUSE_UP, flip);
sBtn.removeEventListener(MouseEvent.MOUSE_UP, shuffle);
menuBtn.removeEventListener(MouseEvent.MOUSE_UP, openMenu);
};
if (QBGameHandler.sMainHandler.m_watertimer){
QBGameHandler.sMainHandler.m_watertimer.stop();
QBGameHandler.sMainHandler.m_watertimer.removeEventListener(TimerEvent.TIMER, updateWaterTimer);
};
if (QBGameHandler.sMainHandler.m_timer){
QBGameHandler.sMainHandler.m_timer.removeEventListener(TimerEvent.TIMER, updateTimer);
QBGameHandler.sMainHandler.m_timer.stop();
};
if (!QBGameHandler.sStagedUp){
if (((getChildByName("Timer")) && ((QBGameHandler.sAppState == "game")))){
if (QBGameHandler.sGameMode == 0){
QBGameHandler.sMainHandler.saveQuestMode(true);
};
};
if ((((QBGameHandler.sAppState == "map")) && ((QBGameHandler.sGameMode == 0)))){
QBGameHandler.sMainHandler.saveQuestMode(false);
};
};
removeEventListener(Event.ENTER_FRAME, startGame);
fader.gotoAndPlay("fadein");
skxScheduler.schedule(clearJunk, 1000);
}
public function addSounds():void{
if (!QBGameHandler.sMainHandler){
return;
};
QBGameHandler.sMainHandler.addSound("BOUNCERED", new sndBOUNCERED());
QBGameHandler.sMainHandler.addSound("BOUNCEYELLOW", new sndBOUNCEYELLOW());
QBGameHandler.sMainHandler.addSound("BOUNCEGREEN", new sndBOUNCEGREEN());
QBGameHandler.sMainHandler.addSound("BOUNCEBLUE", new sndBOUNCEBLUE());
QBGameHandler.sMainHandler.addSound("BOUNCEORANGE", new sndBOUNCEORANGE());
QBGameHandler.sMainHandler.addSound("BOUNCEPURPLE", new sndBOUNCEPURPLE());
QBGameHandler.sMainHandler.addSound("BOUNCEGEN", new sndBOUNCEGEN());
QBGameHandler.sMainHandler.addSound("BOUNCEGEN2", new sndBOUNCEGEN());
QBGameHandler.sMainHandler.addSound("SLIDERED", new sndSLIDERED());
QBGameHandler.sMainHandler.addSound("SLIDEGREY", new sndSLIDEORANGE());
QBGameHandler.sMainHandler.addSound("SLIDEYELLOW", new sndSLIDEYELLOW());
QBGameHandler.sMainHandler.addSound("SLIDEGREEN", new sndSLIDEGREEN());
QBGameHandler.sMainHandler.addSound("SLIDEBLUE", new sndSLIDEBLUE());
QBGameHandler.sMainHandler.addSound("SLIDEPURPLE", new sndSLIDEPURPLE());
QBGameHandler.sMainHandler.addSound("SLIDECHOC", new sndSLIDEORANGE());
QBGameHandler.sMainHandler.addSound("SLIDECHAR", new sndSLIDEORANGE());
QBGameHandler.sMainHandler.addSound("SLIDEVAN", new sndSLIDEORANGE());
QBGameHandler.sMainHandler.addSound("SLIDEORANGE", new sndSLIDEORANGE());
QBGameHandler.sMainHandler.addSound("SLIDEGEN", new sndSLIDEORANGE());
QBGameHandler.sMainHandler.addSound("SLIDEGEN2", new sndSLIDEORANGE());
QBGameHandler.sMainHandler.addSound("FALLRED", new sndFALLRED());
QBGameHandler.sMainHandler.addSound("FALLYELLOW", new sndFALLYELLOW());
QBGameHandler.sMainHandler.addSound("FALLPURPLE", new sndFALLPURPLE());
QBGameHandler.sMainHandler.addSound("FALLORANGE", new sndFALLORANGE());
QBGameHandler.sMainHandler.addSound("FALLGREEN", new sndFALLGREEN());
QBGameHandler.sMainHandler.addSound("FALLBLUE", new sndFALLBLUE());
QBGameHandler.sMainHandler.addSound("FALLGEN", new sndFALLRED());
QBGameHandler.sMainHandler.addSound("FALLGEN2", new sndFALLGEN2());
QBGameHandler.sMainHandler.addSound("CRYRED", new sndCRYRED());
QBGameHandler.sMainHandler.addSound("CRYGREY", new sndCRYGREY());
QBGameHandler.sMainHandler.addSound("CRYYELLOW", new sndCRYYELLOW());
QBGameHandler.sMainHandler.addSound("CRYGREEN", new sndCRYGREEN());
QBGameHandler.sMainHandler.addSound("CRYBLUE", new sndCRYBLUE());
QBGameHandler.sMainHandler.addSound("CRYPURPLE", new sndCRYPURPLE());
QBGameHandler.sMainHandler.addSound("CRYCHOC", new sndCRYCHOC());
QBGameHandler.sMainHandler.addSound("CRYCHAR", new sndCRYCHAR());
QBGameHandler.sMainHandler.addSound("CRYVAN", new sndCRYVAN());
QBGameHandler.sMainHandler.addSound("CRYORANGE", new sndCRYORANGE());
QBGameHandler.sMainHandler.addSound("CRYGEN", new sndCRYRED());
QBGameHandler.sMainHandler.addSound("CRYGEN2", new sndCRYGEN2());
QBGameHandler.sMainHandler.addSound("REDTOG1", new sndREDTOG1());
QBGameHandler.sMainHandler.addSound("REDTOG2", new sndREDTOG2());
QBGameHandler.sMainHandler.addSound("REDTOG3", new sndREDTOG3());
QBGameHandler.sMainHandler.addSound("REDTOG4", new sndREDTOG4());
QBGameHandler.sMainHandler.addSound("ORANGETOG1", new sndORANGETOG1());
QBGameHandler.sMainHandler.addSound("ORANGETOG2", new sndORANGETOG2());
QBGameHandler.sMainHandler.addSound("ORANGETOG3", new sndORANGETOG3());
QBGameHandler.sMainHandler.addSound("ORANGETOG4", new sndORANGETOG4());
QBGameHandler.sMainHandler.addSound("BLUETOG1", new sndBLUETOG1());
QBGameHandler.sMainHandler.addSound("BLUETOG2", new sndBLUETOG2());
QBGameHandler.sMainHandler.addSound("BLUETOG3", new sndBLUETOG3());
QBGameHandler.sMainHandler.addSound("BLUETOG4", new sndBLUETOG4());
QBGameHandler.sMainHandler.addSound("GREENTOG1", new sndGREENTOG1());
QBGameHandler.sMainHandler.addSound("GREENTOG2", new sndGREENTOG2());
QBGameHandler.sMainHandler.addSound("GREENTOG3", new sndGREENTOG3());
QBGameHandler.sMainHandler.addSound("GREENTOG4", new sndGREENTOG4());
QBGameHandler.sMainHandler.addSound("YELLOWTOG1", new sndYELLOWTOG1());
QBGameHandler.sMainHandler.addSound("YELLOWTOG2", new sndYELLOWTOG2());
QBGameHandler.sMainHandler.addSound("YELLOWTOG3", new sndYELLOWTOG3());
QBGameHandler.sMainHandler.addSound("YELLOWTOG4", new sndYELLOWTOG4());
QBGameHandler.sMainHandler.addSound("PURPLETOG1", new sndPURPLETOG1());
QBGameHandler.sMainHandler.addSound("PURPLETOG2", new sndPURPLETOG2());
QBGameHandler.sMainHandler.addSound("PURPLETOG3", new sndPURPLETOG3());
QBGameHandler.sMainHandler.addSound("PURPLETOG4", new sndPURPLETOG4());
QBGameHandler.sMainHandler.addSound("CHARTOG1", new sndCHARTOG1());
QBGameHandler.sMainHandler.addSound("CHARTOG2", new sndCHARTOG2());
QBGameHandler.sMainHandler.addSound("CHARTOG3", new sndCHARTOG3());
QBGameHandler.sMainHandler.addSound("CHARTOG4", new sndCHARTOG4());
QBGameHandler.sMainHandler.addSound("CHOCTOG1", new sndCHOCTOG1());
QBGameHandler.sMainHandler.addSound("CHOCTOG2", new sndCHOCTOG2());
QBGameHandler.sMainHandler.addSound("CHOCTOG3", new sndCHOCTOG3());
QBGameHandler.sMainHandler.addSound("CHOCTOG4", new sndCHOCTOG4());
QBGameHandler.sMainHandler.addSound("GREYTOG1", new sndGREYTOG1());
QBGameHandler.sMainHandler.addSound("GREYTOG2", new sndGREYTOG2());
QBGameHandler.sMainHandler.addSound("GREYTOG3", new sndGREYTOG3());
QBGameHandler.sMainHandler.addSound("GREYTOG4", new sndGREYTOG4());
QBGameHandler.sMainHandler.addSound("PINKTOG1", new sndPINKTOG1());
QBGameHandler.sMainHandler.addSound("PINKTOG2", new sndPINKTOG2());
QBGameHandler.sMainHandler.addSound("PINKTOG3", new sndPINKTOG3());
QBGameHandler.sMainHandler.addSound("PINKTOG4", new sndPINKTOG4());
QBGameHandler.sMainHandler.addSound("VANTOG1", new sndVANTOG1());
QBGameHandler.sMainHandler.addSound("VANTOG2", new sndVANTOG2());
QBGameHandler.sMainHandler.addSound("VANTOG3", new sndVANTOG3());
QBGameHandler.sMainHandler.addSound("VANTOG4", new sndVANTOG4());
QBGameHandler.sMainHandler.addSound("BOILTALLY", new sndBOILTALLY());
QBGameHandler.sMainHandler.addSound("LVLDONE", new sndLVLDONE());
QBGameHandler.sMainHandler.addSound("GENTOG1", new sndGENTOG1());
QBGameHandler.sMainHandler.addSound("GENTOG2", new sndGENTOG2());
QBGameHandler.sMainHandler.addSound("GENTOG3", new sndGENTOG3());
QBGameHandler.sMainHandler.addSound("GENTOG4", new sndGENTOG4());
QBGameHandler.sMainHandler.addSound("GEN2TOG1", new sndGEN2TOG1());
QBGameHandler.sMainHandler.addSound("GEN2TOG2", new sndGEN2TOG2());
QBGameHandler.sMainHandler.addSound("GEN2TOG3", new sndGEN2TOG3());
QBGameHandler.sMainHandler.addSound("GEN2TOG4", new sndGEN2TOG4());
QBGameHandler.sMainHandler.addSound("UHH", new sndHUH());
QBGameHandler.sMainHandler.addSound("FOOTSTEP", new sndFOOTSTEP());
QBGameHandler.sMainHandler.addSound("SPIN", new sndSPIN());
QBGameHandler.sMainHandler.addSound("RANDOM1", new sndRANDOM1());
QBGameHandler.sMainHandler.addSound("RANDOM2", new sndRANDOM2());
QBGameHandler.sMainHandler.addSound("RANDOM3", new sndRANDOM3());
QBGameHandler.sMainHandler.addSound("RANDOM4", new sndRANDOM4());
QBGameHandler.sMainHandler.addSound("CLEARBLOCKS", new soundClearBlocks());
QBGameHandler.sMainHandler.addSound("SPLASH", new sndSPLASH());
QBGameHandler.sMainHandler.addSound("WAVE", new sndWAVE());
QBGameHandler.sMainHandler.addSound("SPLAT", new sndSPLAT());
QBGameHandler.sMainHandler.addSound("BOMB", new sndBOMB());
QBGameHandler.sMainHandler.addSound("PAINT", new sndPAINT());
QBGameHandler.sMainHandler.addSound("POINTS", new sndPOINTS());
QBGameHandler.sMainHandler.addSound("TAHDAH", new sndTAHDAH());
QBGameHandler.sMainHandler.addSound("GAMEOVER", new sndGAMEOVER());
QBGameHandler.sMainHandler.addSound("BLINK1", new sndBLINK1());
QBGameHandler.sMainHandler.addSound("BLINK2", new sndBLINK2());
QBGameHandler.sMainHandler.addSound("CLAP1", new sndCLAP1());
QBGameHandler.sMainHandler.addSound("CLAP2", new sndCLAP2());
QBGameHandler.sMainHandler.addSound("MAGICAPPEAR", new sndMAGICAPPEAR());
QBGameHandler.sMainHandler.addSound("MAGICSHOT", new sndMAGICSHOT());
QBGameHandler.sMainHandler.addSound("MAGICCOLOR", new sndMAGICCOLOR());
}
public function openMenuScore(_arg1:MouseEvent):void{
dialogs.gotoAndStop(6);
}
function frame216(){
stop();
finalGame();
}
public function goBackToMenu(_arg1:MouseEvent=null):void{
if (sMode == "standard"){
dialogs.gotoAndStop(2);
} else {
dialogs.gotoAndStop(3);
};
}
public function fadeCompleteToGame():void{
var _local1:Array;
var _local2:int;
var _local3:MovieClip;
clearPreviews();
_local1 = QBPackHandler.getGamePacks();
_local2 = 0;
while (_local2 < _local1.length) {
if (((((_local1[_local2]) && (_local1[_local2].type))) && ((_local1[_local2].type == "level")))){
_local3 = _local1[_local2].icon;
if (((_local3) && (contains(_local3)))){
removeChild(_local3);
_local3.removeEventListener(MouseEvent.CLICK, playPack1);
_local3.removeEventListener(MouseEvent.CLICK, playPack2);
_local3.removeEventListener(MouseEvent.CLICK, playPack3);
_local3.removeEventListener(MouseEvent.CLICK, playPack4);
_local3.removeEventListener(MouseEvent.CLICK, playPack5);
};
};
_local2++;
};
gotoAndStop("game", "game");
}
public function goToMainMenu(_arg1:Event):void{
var f:Function;
var eve = _arg1;
clearingPreviews = true;
skxScheduler.cancelAll();
btn_back.removeEventListener(MouseEvent.MOUSE_UP, goToMainMenu);
btn_back.removeEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
btn_back.enabled = false;
fader.gotoAndPlay("fadein");
f = function ():void{
var _local1:Array;
var _local2:int;
var _local3:MovieClip;
if (QBPackHandler.m_oAvatar){
removeChild(QBPackHandler.m_oAvatar);
QBPackHandler.m_oAvatar.removeEventListener(Event.ENTER_FRAME, onAvaFrame);
QBPackHandler.m_oAvatar.gotoAndStop(1);
QBPackHandler.m_oAvatar = null;
};
clearPreviews();
_local1 = QBPackHandler.getGamePacks();
_local2 = 0;
while (_local2 < _local1.length) {
if (((((_local1[_local2]) && (_local1[_local2].type))) && ((_local1[_local2].type == "level")))){
_local3 = _local1[_local2].icon;
if (((_local3) && (contains(_local3)))){
removeChild(_local3);
_local3.removeEventListener(MouseEvent.CLICK, playPack1);
_local3.removeEventListener(MouseEvent.CLICK, playPack2);
_local3.removeEventListener(MouseEvent.CLICK, playPack3);
_local3.removeEventListener(MouseEvent.CLICK, playPack4);
_local3.removeEventListener(MouseEvent.CLICK, playPack5);
};
};
_local2++;
};
gotoAndStop("main", "mainmenu");
f = null;
};
skxScheduler.schedule(f, 1000);
}
function frame226(){
stop();
initDialog();
}
public function playerContentAdded(_arg1:GameContentEvent):void{
var _local2:Array;
skxDisplay.Print("playerContentAdded");
QBPackHandler.updatePurchased(skxWhirled.getControl().player.getPlayerLevelPacks(skxWhirled.getControl().game.getMyId()));
_local2 = QBPackHandler.getGamePacks();
if (QBPackHandler.hasPurchased(_local2[QBGameHandler.m_iSelectedPack].name)){
pBtn.visible = true;
bBtn.visible = false;
} else {
bBtn.visible = true;
pBtn.visible = false;
};
}
function frame232(){
stop();
initDialog2();
}
public function gotoWebsite(_arg1:MouseEvent):void{
var _local2:URLRequest;
_local2 = new URLRequest("http://www.whirled.com/welcome/355/games-d_393_vec.e.qbeez.playonwhirled");
navigateToURL(_local2);
}
public function gotoHighScoreFromGame(_arg1:MouseEvent, _arg2:int=-1):void{
if (QBGameHandler.sMainHandler.getPaused()){
QBGameHandler.sMainHandler.postPauseTimer();
};
QBGameHandler.sLastTotalScore = Number(QBGameHandler.sMainHandler.getUserData("totalscore"));
QBGameHandler.sMainHandler.m_watertimer.removeEventListener(TimerEvent.TIMER, updateWaterTimer);
QBGameHandler.sMainHandler.m_timer.removeEventListener(TimerEvent.TIMER, updateTimer);
QBGameHandler.sMainHandler.m_timer.stop();
QBGameHandler.sMainHandler.m_watertimer.stop();
if (((QBGameHandler.sQuestStarted) && ((QBGameHandler.sGameMode == 0)))){
QBGameHandler.sMainHandler.resetQuest();
QBGameHandler.sQuestStarted = false;
skxUser.setCurData("questsave", null);
skxUser.storeCurLocally();
};
removeEventListener(Event.ENTER_FRAME, startGame);
skxMusicChannel.clearAll();
fader.gotoAndPlay("fadein");
skxScheduler.schedule(clearJunkHS, 1000);
}
public function updateWater():void{
var _local1:Number;
if (QBGameHandler.sAppState == "game"){
_local1 = Timer.currentFrame;
if (_local1 >= 91){
if (Timer.watertop.currentFrame < 35){
Timer.watertop.gotoAndStop((Timer.watertop.currentFrame + 1));
} else {
Timer.watertop.gotoAndStop(33);
};
} else {
if (_local1 >= 73){
if (Timer.watertop.currentFrame < 32){
Timer.watertop.gotoAndStop((Timer.watertop.currentFrame + 1));
} else {
Timer.watertop.gotoAndStop(29);
};
} else {
if (_local1 >= 46){
if (Timer.watertop.currentFrame < 28){
Timer.watertop.gotoAndStop((Timer.watertop.currentFrame + 1));
} else {
Timer.watertop.gotoAndStop(20);
};
} else {
if (_local1 >= 15){
if (Timer.watertop.currentFrame < 19){
Timer.watertop.gotoAndStop((Timer.watertop.currentFrame + 1));
} else {
Timer.watertop.gotoAndStop(7);
};
} else {
if (Timer.watertop.currentFrame < 6){
Timer.watertop.gotoAndStop((Timer.watertop.currentFrame + 1));
} else {
Timer.watertop.gotoAndStop(1);
};
};
};
};
};
} else {
QBGameHandler.sMainHandler.m_watertimer.stop();
QBGameHandler.sMainHandler.m_watertimer.removeEventListener(TimerEvent.TIMER, updateWaterTimer);
};
}
public function startNew(_arg1:MouseEvent=null):void{
var obj:*;
var f:Function;
var event = _arg1;
QBGameHandler.sMainHandler.m_timer.stop();
QBGameHandler.sMainHandler.m_timer.removeEventListener(TimerEvent.TIMER, updateTimer);
QBGameHandler.sMainHandler.m_watertimer.stop();
QBGameHandler.sMainHandler.m_watertimer.removeEventListener(TimerEvent.TIMER, updateWaterTimer);
QBGameHandler.sMainHandler.m_timer.removeEventListener(TimerEvent.TIMER, updateTimer);
removeEventListener(Event.ENTER_FRAME, startGame);
QBGameHandler.sMainHandler.m_bGameStarted = false;
QBGameHandler.sMainHandler.m_bRestart = false;
QBGameHandler.sJustStagedUp = true;
obj = MovieClip(root);
f = function ():void{
obj.gotoAndStop(1, "map");
f = null;
};
fader.gotoAndPlay("fadein");
skxScheduler.schedule(f, 1000);
}
public function checkPerfect(_arg1:Object):void{
var _local2:*;
if (_arg1.PERFECTCOUNT){
_local2 = (Number(_arg1.PERFECTCOUNT) + 1);
skxWhirled.getControl().player.setCookie({PERFECTCOUNT:_local2});
switch (_local2){
case 3:
skxWhirled.getControl().player.awardTrophy("perfect3");
break;
case 5:
skxWhirled.getControl().player.awardTrophy("perfect5");
break;
case 10:
skxWhirled.getControl().player.awardTrophy("perfect10");
break;
case 15:
skxWhirled.getControl().player.awardTrophy("perfect15");
break;
case 20:
skxWhirled.getControl().player.awardTrophy("perfect20");
break;
case 30:
skxWhirled.getControl().player.awardTrophy("perfect30");
break;
case 40:
skxWhirled.getControl().player.awardTrophy("perfect40");
break;
case 50:
skxWhirled.getControl().player.awardTrophy("perfect50");
break;
case 75:
skxWhirled.getControl().player.awardTrophy("perfect75");
break;
case 100:
skxWhirled.getControl().player.awardTrophy("perfect100");
break;
case 500:
skxWhirled.getControl().player.awardTrophy("perfect500");
break;
case 750:
skxWhirled.getControl().player.awardTrophy("perfect750");
break;
case 1000:
skxWhirled.getControl().player.awardTrophy("perfect1000");
break;
};
} else {
skxWhirled.getControl().player.awardTrophy("perfect1");
skxWhirled.getControl().player.setCookie({PERFECTCOUNT:1});
};
}
public function showHelpScreen(_arg1:Event=null):void{
dialogs.gotoAndStop(8);
}
public function goBack(_arg1:Event=null):void{
if (sMode != "standard"){
QBGameHandler.sAppStarted = false;
};
if (sMode == "make_challenge"){
gotoAndStop("main_ch1");
} else {
if (sMode == "finish_challenge"){
gotoAndStop("main_ch2");
} else {
if (sMode == "tournament"){
gotoAndStop("main_tr");
} else {
gotoAndStop("main");
};
};
};
}
public function setPreviewAvatar():void{
var _local1:Array;
var _local2:int;
var _local3:String;
var _local4:MovieClip;
var _local5:MovieClip;
skxDisplay.Print("setPreviewAvatar");
if (QBPackHandler.m_oAvatar){
removeChild(QBPackHandler.m_oAvatar);
QBPackHandler.m_oAvatar.removeEventListener(Event.ENTER_FRAME, onAvaFrame);
QBPackHandler.m_oAvatar.gotoAndStop(1);
QBPackHandler.m_oAvatar = null;
};
_local1 = QBPackHandler.getGamePacks();
_local2 = 0;
while (_local2 < _local1.length) {
if (((((((!((_local2 == QBGameHandler.m_iSelectedPack))) && (_local1[_local2]))) && (_local1[_local2].type))) && ((_local1[_local2].type == "level")))){
_local4 = _local1[_local2].icon;
if (((_local4) && (contains(_local4)))){
_local4.mouseEnabled = true;
};
};
_local2++;
};
QBPackHandler.buildAvatarStates(_local1[QBGameHandler.m_iSelectedPack].levelinfo.text);
packInfo.text = _local1[QBGameHandler.m_iSelectedPack].description;
_local1[QBGameHandler.m_iSelectedPack].icon.mouseEnabled = false;
if (((QBPackHandler.hasPurchased(_local1[QBGameHandler.m_iSelectedPack].name)) || ((_local1[QBGameHandler.m_iSelectedPack].premium == false)))){
pBtn.visible = true;
bBtn.visible = false;
packInfo.text = _local1[QBGameHandler.m_iSelectedPack].description2;
} else {
bBtn.visible = true;
pBtn.visible = false;
packInfo.text = _local1[QBGameHandler.m_iSelectedPack].description;
};
_local3 = QBPackHandler.getAvatarStates()["avatar"];
if (((QBPackHandler.getAvatarPack(_local3)) && (QBPackHandler.getAvatarPack(_local3).swf))){
_local5 = QBPackHandler.getAvatarPack(_local3).swf;
_local5.gotoAndStop(1);
if (_local3 == "QBtar_Magician"){
_local5.x = (290 + 85);
_local5.y = 275;
} else {
_local5.x = 85;
_local5.y = -20;
};
QBPackHandler.m_oAvatar = _local5;
QBPackHandler.m_sAvatarState = "idle";
QBPackHandler.m_oAvatar.addEventListener(Event.ENTER_FRAME, onAvaFrame);
avatarPrize.visible = false;
addChildAt(QBPackHandler.m_oAvatar, getChildIndex(avatarPrize));
_local1 = QBPackHandler.getAvatarStates()["idle"];
QBPackHandler.m_oAvatar.gotoAndPlay(1, _local1[skxRandom.getRandomInt(0, _local1.length)]);
};
}
public function playClickSnd(_arg1:Event=null):void{
var _local2:Sound;
if (QBGameHandler.sSoundOn){
_local2 = new sndBUTTON();
skxSoundChannel.playSound(_local2);
};
}
public function updateWaterTimer(_arg1:Event):void{
if (QBGameHandler.sAppState == "game"){
if (QBGameHandler.sMainHandler.m_bGameOver){
bubbleWater();
} else {
if (QBGameHandler.sMainHandler.m_bTimeBonus){
stillWater();
} else {
updateWater();
};
};
} else {
QBGameHandler.sMainHandler.m_watertimer.stop();
};
}
public function toggleSound(_arg1:MouseEvent=null):void{
var _local2:SoundTransform;
soundOnBtn.alpha = 1;
soundOffBtn.alpha = 1;
if (QBGameHandler.sSoundOn){
soundOnBtn.visible = false;
soundOffBtn.visible = true;
QBGameHandler.sSoundOn = false;
skxSoundChannel.setVolume(0);
skxMusicChannel.setVolume(0);
} else {
soundOnBtn.visible = true;
soundOffBtn.visible = false;
QBGameHandler.sSoundOn = true;
skxSoundChannel.setVolume(1);
skxMusicChannel.setVolume(1);
_local2 = SoundMixer.soundTransform;
_local2.volume = 1;
SoundMixer.soundTransform = _local2;
};
}
public function gotoLevelPacks(_arg1:MouseEvent):void{
sGameMode = "3";
resetSeed();
QBGameHandler.sGameStarted = false;
QBGameHandler.sGameMode = 2;
QBGameHandler.sLastTotalScore = 0;
QBGameHandler.sMainHandler.resetQuest();
pBtn.enabled = false;
pBtn2.enabled = false;
fader.gotoAndPlay("fadein");
skxScheduler.schedule(fadeComplete, 1000);
}
public function gotoMoreGames(_arg1:MouseEvent):void{
var _local2:URLRequest;
_local2 = new URLRequest("http://www.whirled.com/welcome/355/games");
navigateToURL(_local2);
}
public function winWhirledAvatar():void{
var _local1:String;
var _local2:String;
if (perfectEarned == false){
return;
};
_local1 = QBPackHandler.getAvatarStates()["trophy"];
_local2 = QBPackHandler.getAvatarStates()["award"];
if (!skxWhirled.getControl().player.holdsTrophy(_local1)){
skxDisplay.Print(String((((" Win award " + _local2) + " ") + _local1)));
skxWhirled.getControl().player.awardTrophy(_local1);
skxWhirled.getControl().player.awardPrize(_local2);
};
}
public function playPack2(_arg1:MouseEvent=null):void{
clearingPreviews = true;
skxScheduler.cancelAll();
clearPreviews();
previewload = new Array();
pBtn.mouseEnabled = true;
pBtn.alpha = 1;
gui_levels.gotoAndStop(2);
QBGameHandler.m_iSelectedPack = (levelPackPos + 1);
if (skxWhirled.getControl().isConnected()){
setlevels(QBGameHandler.m_iSelectedPack);
};
setPreviewAvatar();
buildLevelPreview();
}
public function playPack3(_arg1:MouseEvent=null):void{
clearingPreviews = true;
skxScheduler.cancelAll();
clearPreviews();
previewload = new Array();
pBtn.mouseEnabled = true;
pBtn.alpha = 1;
gui_levels.gotoAndStop(3);
QBGameHandler.m_iSelectedPack = (levelPackPos + 2);
if (skxWhirled.getControl().isConnected()){
setlevels(QBGameHandler.m_iSelectedPack);
};
setPreviewAvatar();
buildLevelPreview();
}
public function playPack5(_arg1:MouseEvent=null):void{
clearingPreviews = true;
skxScheduler.cancelAll();
clearPreviews();
previewload = new Array();
pBtn.mouseEnabled = true;
pBtn.alpha = 1;
gui_levels.gotoAndStop(5);
QBGameHandler.m_iSelectedPack = (levelPackPos + 4);
if (skxWhirled.getControl().isConnected()){
setlevels(QBGameHandler.m_iSelectedPack);
};
setPreviewAvatar();
buildLevelPreview();
}
public function updatePowerMoves():void{
if (!getChildByName("rBtn")){
return;
};
if (QBGameHandler.sMainHandler.getGameOver()){
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
rBtn.alpha = 0.25;
lBtn.alpha = 0.25;
fBtn.alpha = 0.25;
sBtn.alpha = 0.25;
return;
};
if (QBGameHandler.sMainHandler.getInfPowerMoves()){
mcPowerMoves.gotoAndStop(5);
rBtn.enabled = true;
lBtn.enabled = true;
fBtn.enabled = true;
sBtn.enabled = true;
rBtn.alpha = 1;
lBtn.alpha = 1;
fBtn.alpha = 1;
sBtn.alpha = 1;
} else {
mcPowerMoves.gotoAndStop((4 - QBGameHandler.sMainHandler.getPowerMoves()));
if (QBGameHandler.sMainHandler.getPowerMoves() <= 0){
rBtn.alpha = 0.25;
lBtn.alpha = 0.25;
fBtn.alpha = 0.25;
sBtn.alpha = 0.25;
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
} else {
rBtn.alpha = 1;
lBtn.alpha = 1;
fBtn.alpha = 1;
sBtn.alpha = 1;
rBtn.enabled = true;
lBtn.enabled = true;
fBtn.enabled = true;
sBtn.enabled = true;
};
};
}
public function playPack4(_arg1:MouseEvent=null):void{
clearingPreviews = true;
skxScheduler.cancelAll();
clearPreviews();
previewload = new Array();
pBtn.mouseEnabled = true;
pBtn.alpha = 1;
gui_levels.gotoAndStop(4);
QBGameHandler.m_iSelectedPack = (levelPackPos + 3);
if (skxWhirled.getControl().isConnected()){
setlevels(QBGameHandler.m_iSelectedPack);
};
setPreviewAvatar();
buildLevelPreview();
}
public function rotatel(_arg1:MouseEvent):void{
if (((((QBGameHandler.sMainHandler) && (!(QBGameHandler.sMainHandler.getGameOver())))) && (!(QBGameHandler.sMainHandler.getPaused())))){
QBGameHandler.sMainHandler.rotateBoard(-1);
updatePowerMoves();
};
}
public function playPack1(_arg1:MouseEvent=null):void{
clearingPreviews = true;
skxScheduler.cancelAll();
clearPreviews();
previewload = new Array();
pBtn.mouseEnabled = true;
pBtn.alpha = 1;
gui_levels.gotoAndStop(1);
QBGameHandler.m_iSelectedPack = levelPackPos;
if (skxWhirled.getControl().isConnected()){
setlevels(QBGameHandler.m_iSelectedPack);
};
setPreviewAvatar();
buildLevelPreview();
}
public function rotater(_arg1:MouseEvent):void{
if (((((QBGameHandler.sMainHandler) && (!(QBGameHandler.sMainHandler.getGameOver())))) && (!(QBGameHandler.sMainHandler.getPaused())))){
QBGameHandler.sMainHandler.rotateBoard(1);
updatePowerMoves();
};
}
public function openGameShop(_arg1:Event):void{
var _local2:Array;
var _local3:*;
if (skxWhirled.getControl().isConnected()){
skxDisplay.Print("openGameShop ");
_local2 = QBPackHandler.getGamePacks();
_local3 = _local2[QBGameHandler.m_iSelectedPack].buyurl;
if (String(_local3) == "none"){
skxWhirled.getControl().local.showGameShop(GameControl.LEVEL_PACK_SHOP);
} else {
skxWhirled.getControl().local.showGameShop(GameControl.LEVEL_PACK_SHOP, Number(_local3));
};
};
}
function frame187(){
QBGameHandler.sAppState = "game";
dialogs.addEventListener(Event.ADDED, onDialogAdd);
stop();
setSoundUI();
IDLESTATE = "idle";
lvlScore.visible = false;
tPerfectScore.visible = false;
lvl_numdisplay.visible = false;
tPreLevel.visible = false;
tPreLevelQbz.visible = false;
lvlCompleteDlg.visible = false;
overflow.visible = false;
overflow.gotoAndStop(1);
perfectEarned = false;
startGame();
}
function frame185(){
levelPackPos = 0;
levelPos = 0;
if (QBGameHandler.sMainHandler){
QBGameHandler.sMainHandler.clearData();
};
previews = new Array();
previewload = new Array();
clearingPreviews = false;
level1.visible = false;
level2.visible = false;
level3.visible = false;
level4.visible = false;
level5.visible = false;
level6.visible = false;
bBtn.visible = false;
pBtn.mouseEnabled = false;
pBtn.alpha = 0.25;
pBtn.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
pBtn.addEventListener(MouseEvent.CLICK, playPack);
bBtn.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
bBtn.addEventListener(MouseEvent.CLICK, openGameShop);
btn_back.addEventListener(MouseEvent.MOUSE_UP, goToMainMenu);
btn_back.addEventListener(MouseEvent.CLICK, playClickSnd);
addEventListener(GameContentEvent.PLAYER_CONTENT_ADDED, playerContentAdded);
skxWhirled.getControl().player.addEventListener(GameContentEvent.PLAYER_CONTENT_ADDED, playerContentAdded);
QBPackHandler.sortLevelPacks();
skxScheduler.schedule(playPack1, 250);
gui_packs.arrowRight.addEventListener(MouseEvent.MOUSE_UP, scrollPackRight);
gui_packs.arrowRight.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
gui_packs.arrowLeft.addEventListener(MouseEvent.MOUSE_UP, scrollPackLeft);
gui_packs.arrowLeft.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
buildPacks();
stop();
}
public function setUI():void{
tPerfectScore.visible = false;
lvlCompleteDlg.visible = false;
lvlCountDown.text = "";
lvlCountDown.visible = false;
menuBtn.enabled = false;
menuBtn.mouseEnabled = false;
Timer.gotoAndStop(1);
lvlCompleteDlg.gotoAndStop(1);
qbLogo.gotoAndStop(1);
if (QBGameHandler.sGameMode == 3){
} else {
Timer.visible = true;
Timer.gotoAndStop(1);
};
dialogs.gotoAndStop(1);
if (QBGameHandler.sSoundOn){
soundOnBtn.visible = true;
soundOffBtn.visible = false;
} else {
soundOnBtn.visible = false;
soundOffBtn.visible = true;
};
mcPowerMoves.gotoAndStop((4 - QBGameHandler.sMainHandler.getPowerMoves()));
rBtn.alpha = 0.25;
lBtn.alpha = 0.25;
fBtn.alpha = 0.25;
sBtn.alpha = 0.25;
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
addChildAt(QBGameHandler.WINDOW, 0);
addChildAt(QBGameHandler.sMainHandler.m_mcSnapShot, (getChildIndex(dialogs) - 1));
rBtn.addEventListener(MouseEvent.MOUSE_UP, rotater);
lBtn.addEventListener(MouseEvent.MOUSE_UP, rotatel);
fBtn.addEventListener(MouseEvent.MOUSE_UP, flip);
sBtn.addEventListener(MouseEvent.MOUSE_UP, shuffle);
menuBtn.addEventListener(MouseEvent.MOUSE_UP, openMenu);
menuBtn.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
updatePowerMoves();
tScore.text = QBGameHandler.sMainHandler.getPrettyTotalScore();
if (!QBGameHandler.sGameMode){
tScoreHeader.text = String(((("LVL: " + QBGameHandler.sMainHandler.getCurrentLevel()) + "-") + QBGameHandler.sMainHandler.getSubLevel()));
} else {
tScoreHeader.text = String(("LVL: " + QBGameHandler.sMainHandler.getSubLevel()));
};
}
public function initDialog():void{
var f:Function;
menuBtn.mouseEnabled = false;
menuBtn.alpha = 0.25;
f = function (_arg1:Object):void{
cBtn.removeEventListener(MouseEvent.MOUSE_UP, f);
f = null;
gotoAndStop("game");
QBGameHandler.sMainHandler.goToState("STARTNEWGAME", 1000);
};
cBtn.addEventListener(MouseEvent.MOUSE_UP, f);
cBtn.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
}
public function finalGame():void{
menuBtn.mouseEnabled = false;
menuBtn.alpha = 0.25;
txt_postscore.mouseEnabled = false;
cBtn.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
tStageScore.text = QBGameHandler.prettyScore(QBGameHandler.sMainHandler.getUserData("totalscore"));
tPerfects1.text = String(QBGameHandler.sMainHandler.getUserData("perfect"));
tMaxGroup1.text = String(QBGameHandler.sMainHandler.getUserData("maxgroup"));
if (QBGameHandler.sMainHandler.m_watertimer){
QBGameHandler.sMainHandler.m_watertimer.stop();
QBGameHandler.sMainHandler.m_watertimer.removeEventListener(TimerEvent.TIMER, updateWaterTimer);
};
if (QBGameHandler.sMainHandler.m_timer){
QBGameHandler.sMainHandler.m_timer.removeEventListener(TimerEvent.TIMER, updateTimer);
QBGameHandler.sMainHandler.m_timer.stop();
};
if (QBGameHandler.m_aLevels){
winWhirledAvatar();
cBtn.addEventListener(MouseEvent.MOUSE_UP, gotoMainMenu);
} else {
cBtn.addEventListener(MouseEvent.MOUSE_UP, gotoMainMenu);
};
skxWhirled.getControl().game.endGameWithScore(QBGameHandler.sMainHandler.getUserData("totalscore"));
skxWhirled.getControl().game.systemMessage((String(("Your final score is " + QBGameHandler.prettyScore(QBGameHandler.sMainHandler.getUserData("totalscore")))) + " points."));
}
function frame196(){
endStage();
stop();
}
public function restartLevel(_arg1:MouseEvent):void{
QBGameHandler.sMainHandler.m_bGameStarted = false;
QBGameHandler.sMainHandler.m_bRestart = true;
closeMenu();
QBGameHandler.sMainHandler.postPauseTimer();
QBGameHandler.sMainHandler.restartLevel();
QBGameHandler.sMainHandler.startGame();
}
public function cleanUp(_arg1:Object=null):void{
if (((QBPackHandler.m_oAvatar) && (contains(QBPackHandler.m_oAvatar)))){
removeChild(QBPackHandler.m_oAvatar);
QBPackHandler.m_oAvatar.removeEventListener(Event.ENTER_FRAME, onAvaFrame);
QBPackHandler.m_oAvatar.gotoAndStop(1);
QBPackHandler.m_oAvatar = null;
};
if (((QBGameHandler.WINDOW) && (contains(QBGameHandler.WINDOW)))){
QBGameHandler.WINDOW.sendState("ALL-DESTROY");
removeChild(QBGameHandler.WINDOW);
};
if (QBGameHandler.sMainHandler){
QBGameHandler.sMainHandler.stopAllSound();
QBGameHandler.sMainHandler.shutDown();
QBGameHandler.sMainHandler.clearBoard();
QBGameHandler.sMainHandler.clearData();
QBGameHandler.sMainHandler.cleanUpBoard();
if (((QBGameHandler.sMainHandler.m_mcSnapShot) && (contains(QBGameHandler.sMainHandler.m_mcSnapShot)))){
removeChild(QBGameHandler.sMainHandler.m_mcSnapShot);
};
if (QBGameHandler.sMainHandler.m_watertimer){
QBGameHandler.sMainHandler.m_watertimer.removeEventListener(TimerEvent.TIMER, updateWaterTimer);
};
if (QBGameHandler.sMainHandler.m_timer){
QBGameHandler.sMainHandler.m_timer.removeEventListener(TimerEvent.TIMER, updateTimer);
};
};
QBGameHandler.sNewGameDispatcher.removeEventListener(QBGameEvent.GAME, onNewGame);
skxMusicChannel.clearAll();
skxSoundChannel.clearAll();
skxScheduler.cancelAll();
}
public function openMenu(_arg1:MouseEvent):void{
if (getChildByName("Timer")){
Timer.stop();
};
if (QBGameHandler.sMainHandler){
QBGameHandler.sMainHandler.pauseGame();
};
dialogs.alpha = 0;
dialogs.visible = true;
if (sMode == "standard"){
dialogs.gotoAndStop(2);
} else {
dialogs.gotoAndStop(3);
};
skxUtil.fadeTo(dialogs, 200, 5, 1);
if (((getChildByName("rBtn")) && ((rBtn.enabled == true)))){
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
};
}
public function onNewGame(_arg1:QBGameEvent):void{
var _local2:String;
var _local3:String;
if (!QBGameHandler.sMainHandler){
return;
};
_local2 = _arg1.getevent().EVENT;
switch (_local2){
case "LASTLEVELPACK":
_local3 = QBPackHandler.getAvatarStates()["trophy"];
if (skxWhirled.getControl().player.holdsTrophy(_local3)){
gotoAndStop("packgui2");
} else {
gotoAndStop("packgui");
};
break;
case "NEWGAME":
QBGameHandler.sMainHandler.addSound("BOILTALLY", new sndBOILTALLY());
QBGameHandler.sMainHandler.m_timer.addEventListener(TimerEvent.TIMER, updateTimer);
break;
case "FRAMERATE":
if (skxWhirled.getControl().isConnected()){
skxWhirled.getControl().local.setFrameRate(Number(_arg1.getevent().SPEED));
skxWhirled.getControl().local.setStageQuality("high");
};
break;
case "NOSHUFFLE":
skxWhirled.getControl().player.awardTrophy("NOSHUFFLE");
break;
case "NOROTATE":
skxWhirled.getControl().player.awardTrophy("NOROTATE");
break;
case "NOFLIP":
skxWhirled.getControl().player.awardTrophy("NOFLIP");
break;
case "NOPOWERMOVES":
skxWhirled.getControl().player.awardTrophy("NOPOWERMOVES");
break;
case "TIMEMASTER":
skxWhirled.getControl().player.awardTrophy("TIMEMASTER");
break;
case "NARROWESCAPE":
skxWhirled.getControl().player.awardTrophy("NARROWESCAPE");
break;
case "WATERLOGGED":
skxWhirled.getControl().player.awardTrophy("WATERLOGGED");
break;
case "GROUP":
if (skxWhirled.getControl().isConnected()){
if ((((_arg1.getevent().COUNT >= 10)) && ((_arg1.getevent().COUNT < 20)))){
skxWhirled.getControl().player.awardTrophy("clear10");
};
if ((((_arg1.getevent().COUNT >= 20)) && ((_arg1.getevent().COUNT < 30)))){
skxWhirled.getControl().player.awardTrophy("clear20");
};
if ((((_arg1.getevent().COUNT >= 30)) && ((_arg1.getevent().COUNT < 40)))){
skxWhirled.getControl().player.awardTrophy("clear30");
};
if ((((_arg1.getevent().COUNT >= 40)) && ((_arg1.getevent().COUNT < 50)))){
skxWhirled.getControl().player.awardTrophy("clear40");
};
if ((((_arg1.getevent().COUNT >= 50)) && ((_arg1.getevent().COUNT < 60)))){
skxWhirled.getControl().player.awardTrophy("clear50");
};
};
break;
case "MAGICGROUP":
if (skxWhirled.getControl().isConnected()){
if (_arg1.getevent().COUNT == 1){
skxWhirled.getControl().player.awardTrophy("magicclear1");
};
if (_arg1.getevent().COUNT == 2){
skxWhirled.getControl().player.awardTrophy("magicclear2");
};
if (_arg1.getevent().COUNT == 3){
skxWhirled.getControl().player.awardTrophy("magicclear3");
};
if (_arg1.getevent().COUNT == 4){
skxWhirled.getControl().player.awardTrophy("magicclear4");
};
if (_arg1.getevent().COUNT == 5){
skxWhirled.getControl().player.awardTrophy("magicclear5");
};
if (_arg1.getevent().COUNT == 6){
skxWhirled.getControl().player.awardTrophy("magicclear6");
};
};
break;
case "PAINTGROUP":
if (skxWhirled.getControl().isConnected()){
if ((((_arg1.getevent().COUNT >= 5)) && ((_arg1.getevent().COUNT < 10)))){
skxWhirled.getControl().player.awardTrophy("paintclear5");
};
if ((((_arg1.getevent().COUNT >= 10)) && ((_arg1.getevent().COUNT < 20)))){
skxWhirled.getControl().player.awardTrophy("paintclear10");
};
if ((((_arg1.getevent().COUNT >= 20)) && ((_arg1.getevent().COUNT < 30)))){
skxWhirled.getControl().player.awardTrophy("paintclear20");
};
if ((((_arg1.getevent().COUNT >= 30)) && ((_arg1.getevent().COUNT < 40)))){
skxWhirled.getControl().player.awardTrophy("paintclear30");
};
if ((((_arg1.getevent().COUNT >= 40)) && ((_arg1.getevent().COUNT < 50)))){
skxWhirled.getControl().player.awardTrophy("paintclear40");
};
if ((((_arg1.getevent().COUNT >= 50)) && ((_arg1.getevent().COUNT < 60)))){
skxWhirled.getControl().player.awardTrophy("paintclear50");
};
if ((((_arg1.getevent().COUNT >= 60)) && ((_arg1.getevent().COUNT < 70)))){
skxWhirled.getControl().player.awardTrophy("paintclear60");
};
if (_arg1.getevent().COUNT >= 75){
skxWhirled.getControl().player.awardTrophy("paintclear75");
};
};
break;
case "BOMBGROUP":
if (skxWhirled.getControl().isConnected()){
if ((((_arg1.getevent().COUNT >= 10)) && ((_arg1.getevent().COUNT < 20)))){
skxWhirled.getControl().player.awardTrophy("bombclear10");
};
if ((((_arg1.getevent().COUNT >= 20)) && ((_arg1.getevent().COUNT < 30)))){
skxWhirled.getControl().player.awardTrophy("bombclear20");
};
if ((((_arg1.getevent().COUNT >= 30)) && ((_arg1.getevent().COUNT < 40)))){
skxWhirled.getControl().player.awardTrophy("bombclear30");
};
if ((((_arg1.getevent().COUNT >= 40)) && ((_arg1.getevent().COUNT < 50)))){
skxWhirled.getControl().player.awardTrophy("bombclear40");
};
if ((((_arg1.getevent().COUNT >= 50)) && ((_arg1.getevent().COUNT < 60)))){
skxWhirled.getControl().player.awardTrophy("bombclear50");
};
if ((((_arg1.getevent().COUNT >= 60)) && ((_arg1.getevent().COUNT < 70)))){
skxWhirled.getControl().player.awardTrophy("bombclear60");
};
if ((((_arg1.getevent().COUNT >= 70)) && ((_arg1.getevent().COUNT < 80)))){
skxWhirled.getControl().player.awardTrophy("bombclear70");
};
};
break;
case "PERFECT":
if (QBPackHandler.m_oAvatar){
QBPackHandler.m_sAvatarState = "perfect";
QBPackHandler.m_iStatePos = 0;
};
perfectcount++;
perfectEarned = true;
if (skxWhirled.getControl().isConnected()){
switch (perfectcount){
case 1:
skxWhirled.getControl().player.awardTrophy("perfect1");
break;
case 3:
skxWhirled.getControl().player.awardTrophy("perfect3");
break;
case 5:
skxWhirled.getControl().player.awardTrophy("perfect5");
break;
case 10:
skxWhirled.getControl().player.awardTrophy("perfect10");
break;
};
};
menuBtn.enabled = false;
menuBtn.mouseEnabled = false;
menuBtn.alpha = 0.25;
rBtn.alpha = 0.25;
lBtn.alpha = 0.25;
fBtn.alpha = 0.25;
sBtn.alpha = 0.25;
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
tPerfectScore.visible = true;
tPerfectScore.text = "100,000";
lvlCompleteDlg.visible = true;
lvlCompleteDlg.gotoAndStop(5);
break;
case "PERFECTCOUNT":
tPerfectScore.visible = true;
tPerfectScore.text = QBGameHandler.sMainHandler.getCurPerfect();
break;
case "PERBLUR":
skxUtil.blurTo(lvlCompleteDlg, 100, 5, 5, 40);
break;
case "BONUSBLUR":
skxUtil.blurTo(lvlScore, 100, 5, 5, 40);
skxUtil.blurTo(tPerfectScore, 100, 5, 5, 40);
break;
case "GAMEOVERWIN":
menuBtn.enabled = true;
menuBtn.mouseEnabled = true;
menuBtn.alpha = 1;
rBtn.alpha = 0.25;
lBtn.alpha = 0.25;
fBtn.alpha = 0.25;
sBtn.alpha = 0.25;
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
lvlCompleteDlg.visible = true;
lvlCompleteDlg.gotoAndStop(3);
if ((((sMode == "make_challenge")) || ((sMode == "finish_challenge")))){
gotoAndStop("final_ch1");
} else {
if (sMode == "tournament"){
gotoAndStop("final_ch2");
} else {
gotoAndStop("final");
};
};
break;
case "PRELEVEL":
perfectEarned = false;
if (skxWhirled.getControl().isConnected()){
skxWhirled.getControl().game.playerReady();
};
overflow.visible = false;
overflow.gotoAndStop(1);
Timer.gotoAndStop(1);
Timer.watertop.gotoAndStop(1);
if (QBGameHandler.sSoundOn){
soundOnBtn.visible = true;
soundOffBtn.visible = false;
} else {
soundOnBtn.visible = false;
soundOffBtn.visible = true;
};
menuBtn.enabled = false;
menuBtn.alpha = 0.25;
Timer.filters = [];
if (QBPackHandler.m_oAvatar){
QBPackHandler.m_oAvatar.filters = [];
};
lvlScore.visible = false;
lvlCountDown.visible = false;
lvlCompleteDlg.gotoAndStop(1);
rBtn.alpha = 0.25;
lBtn.alpha = 0.25;
fBtn.alpha = 0.25;
sBtn.alpha = 0.25;
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
lvl_numdisplay.visible = true;
tPreLevel.visible = true;
tPreLevelQbz.visible = true;
tPreLevel.text = "";
lvlScore.visible = false;
if (QBGameHandler.sGameMode == 3){
} else {
QBGameHandler.sMainHandler.m_timer.addEventListener(TimerEvent.TIMER, updateTimer);
QBGameHandler.sMainHandler.m_watertimer.addEventListener(TimerEvent.TIMER, updateWaterTimer);
};
if (!QBGameHandler.sGameMode){
tScoreHeader.text = String(((("LVL: " + QBGameHandler.sMainHandler.getCurrentLevel()) + "-") + QBGameHandler.sMainHandler.getSubLevel()));
lvl_numdisplay.text = String(((("Level " + QBGameHandler.sMainHandler.getCurrentLevel()) + "-") + QBGameHandler.sMainHandler.getSubLevel()));
} else {
tScoreHeader.text = String(("LVL: " + QBGameHandler.sMainHandler.getSubLevel()));
lvl_numdisplay.text = String(("Level " + QBGameHandler.sMainHandler.getSubLevel()));
};
tPreLevelQbz.text = String((QBGameHandler.sMainHandler.getQBCount() + " QBz"));
tPreLevel.text = QBGameHandler.sMainHandler.getPrelevelInfo();
break;
case "ENDGAME":
if ((((QBPackHandler.m_sAvatarState == "idle")) && ((QBGameHandler.sMainHandler.getLiveQBCount() > 0)))){
QBPackHandler.m_sAvatarState = "win";
QBPackHandler.m_iStatePos = 0;
};
rBtn.alpha = 0.25;
lBtn.alpha = 0.25;
fBtn.alpha = 0.25;
sBtn.alpha = 0.25;
menuBtn.alpha = 0.25;
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
menuBtn.enabled = false;
menuBtn.mouseEnabled = false;
QBGameHandler.sMainHandler.levelUp();
break;
case "STARTLEVEL":
menuBtn.enabled = true;
menuBtn.mouseEnabled = true;
menuBtn.alpha = 1;
rBtn.alpha = 1;
lBtn.alpha = 1;
fBtn.alpha = 1;
sBtn.alpha = 1;
rBtn.enabled = true;
lBtn.enabled = true;
fBtn.enabled = true;
sBtn.enabled = true;
updatePowerMoves();
skxUtil.blurTo(lvl_numdisplay, 100, 3, 5, 40);
skxUtil.blurTo(tPreLevel, 100, 3, 5, 40);
skxUtil.blurTo(tPreLevelQbz, 100, 3, 5, 40);
break;
case "GAMEOVERLOST":
if (QBGameHandler.sMainHandler.m_bGameOverCountdown == false){
menuBtn.enabled = false;
menuBtn.mouseEnabled = false;
menuBtn.alpha = 0.25;
rBtn.alpha = 0.25;
lBtn.alpha = 0.25;
fBtn.alpha = 0.25;
sBtn.alpha = 0.25;
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
lvlScore.visible = true;
lvlCountDown.visible = true;
if (QBGameHandler.sGameMode == 3){
lvlCountDown.text = "Clear 95% to continue...retry in 5...";
lvlScore.text = String((QBGameHandler.sMainHandler.getPercCleared() + "% Cleared"));
} else {
lvlScore.text = "Times Up!!";
lvlCountDown.text = "Get Ready!! 5...";
};
lvlCompleteDlg.visible = true;
lvlCompleteDlg.gotoAndStop(4);
QBGameHandler.sMainHandler.m_bRestart = true;
QBGameHandler.sMainHandler.goToState("STARTCOUNTDOWN", 25);
};
break;
case "COUNTDOWN":
if (QBGameHandler.sGameMode == 3){
if (QBGameHandler.sMainHandler.m_iCurPerfect > 0){
lvlCountDown.text = String((("Clear 95% to continue...retry in " + QBGameHandler.sMainHandler.m_iCurPerfect) + "..."));
};
} else {
if (QBGameHandler.sMainHandler.m_iCurPerfect > 0){
lvlCountDown.text = String((("Get Ready!! " + QBGameHandler.sMainHandler.m_iCurPerfect) + "..."));
};
};
break;
case "LOWERWATER":
if (QBGameHandler.sGameMode != 3){
Timer.watertop.gotoAndStop("turb0");
if (QBGameHandler.sMainHandler.getGameTime() > 0){
Timer.gotoAndStop(QBGameHandler.sMainHandler.getGameTime());
} else {
Timer.gotoAndStop(1);
};
};
break;
case "STONETIP":
dialogs.gotoAndStop(10);
dialogs.alpha = 0;
skxUtil.fadeTo(dialogs, 200, 5, 1);
break;
case "BOMBTIP":
dialogs.gotoAndStop(7);
dialogs.alpha = 0;
skxUtil.fadeTo(dialogs, 200, 5, 1);
break;
case "LVLCOMPLETE":
menuBtn.enabled = true;
menuBtn.mouseEnabled = true;
menuBtn.alpha = 1;
tPerfectScore.visible = false;
lvlScore.visible = false;
lvlScore.text = "";
QBGameHandler.sMainHandler.goToState("STARTNEWGAME", 1000);
break;
case "STAGECOMPLETE":
menuBtn.mouseEnabled = false;
menuBtn.alpha = 0.25;
gotoAndStop("final");
break;
case "MAGICREADY":
rBtn.alpha = 0.25;
lBtn.alpha = 0.25;
fBtn.alpha = 0.25;
sBtn.alpha = 0.25;
rBtn.mouseEnabled = false;
lBtn.mouseEnabled = false;
fBtn.mouseEnabled = false;
sBtn.mouseEnabled = false;
menuBtn.mouseEnabled = false;
menuBtn.alpha = 0.25;
break;
case "MAGICDONE":
rBtn.alpha = 1;
lBtn.alpha = 1;
fBtn.alpha = 1;
sBtn.alpha = 1;
rBtn.mouseEnabled = true;
lBtn.mouseEnabled = true;
fBtn.mouseEnabled = true;
sBtn.mouseEnabled = true;
menuBtn.mouseEnabled = true;
sBtn.addEventListener(MouseEvent.MOUSE_UP, shuffle);
menuBtn.alpha = 1;
break;
case "TIMEBONUS":
rBtn.alpha = 0.25;
lBtn.alpha = 0.25;
fBtn.alpha = 0.25;
sBtn.alpha = 0.25;
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
lvlCompleteDlg.gotoAndStop(0);
lvlScore.visible = true;
tPerfectScore.visible = true;
tPerfectScore.text = "0";
lvlScore.text = "TIME BONUS";
break;
case "BONUSCOUNT":
tPerfectScore.text = QBGameHandler.sMainHandler.getCurPerfect();
if (Timer.currentFrame < 100){
Timer.gotoAndStop((Timer.currentFrame + 1));
} else {
QBGameHandler.sMainHandler.m_bTimeBonus = false;
skxSoundChannel.clearAll();
skxScheduler.schedule(QBGameHandler.sMainHandler.stopBonusCount, 500);
if (((!(QBGameHandler.m_aLevels)) && ((QBGameHandler.sMainHandler.getSubLevel() <= 10)))){
if (((skxWhirled.getControl().isConnected()) && (skxWhirled.getControl().game.isInPlay()))){
skxWhirled.getControl().game.endGameWithScore(QBGameHandler.sMainHandler.getUserData("score"));
skxWhirled.getControl().game.systemMessage((String(("You scored " + QBGameHandler.prettyScore(QBGameHandler.sMainHandler.getUserData("score")))) + " points in this level."));
};
} else {
if ((((QBGameHandler.sMainHandler.getSubLevel() < QBGameHandler.m_aLevels.length)) && (skxWhirled.getControl().game.isInPlay()))){
skxWhirled.getControl().game.endGameWithScore(QBGameHandler.sMainHandler.getUserData("score"));
skxWhirled.getControl().game.systemMessage((String(("You scored " + QBGameHandler.prettyScore(QBGameHandler.sMainHandler.getUserData("score")))) + " points in this level."));
};
};
};
break;
case "PAUSE":
if (QBPackHandler.m_oAvatar){
QBPackHandler.m_oAvatar.visible = false;
};
if (getChildByName("Timer")){
qbLogo.visible = false;
menuBtn.visible = false;
soundOnBtn.visible = false;
soundOffBtn.visible = false;
};
if (getChildByName("mcUpsell")){
mcUpsell.visible = false;
};
if (getChildByName("tScoreHeader")){
mcPowerMoves.visible = false;
menuBtn.visible = false;
rBtn.visible = false;
lBtn.visible = false;
fBtn.visible = false;
sBtn.visible = false;
rBtn.enabled = false;
lBtn.enabled = false;
fBtn.enabled = false;
sBtn.enabled = false;
tScore.visible = false;
tScoreHeader.visible = false;
};
break;
case "UNPAUSE":
if (QBPackHandler.m_oAvatar){
QBPackHandler.m_oAvatar.visible = true;
};
menuBtn.visible = true;
if (getChildByName("mcUpsell")){
mcUpsell.visible = true;
};
if (getChildByName("tScoreHeader")){
updatePowerMoves();
rBtn.visible = true;
lBtn.visible = true;
fBtn.visible = true;
sBtn.visible = true;
tScore.visible = true;
tScoreHeader.visible = true;
mcPowerMoves.visible = true;
tScoreHeader.visible = true;
};
if (getChildByName("Timer")){
if (QBGameHandler.sGameMode == 3){
} else {
Timer.visible = true;
if (((QBGameHandler.sMainHandler.getGameOver()) && (QBGameHandler.sMainHandler.getTimerPassed()))){
overflow.visible = true;
};
};
qbLogo.visible = true;
menuBtn.visible = true;
if (QBGameHandler.sSoundOn){
soundOnBtn.visible = true;
soundOffBtn.visible = false;
} else {
soundOnBtn.visible = false;
soundOffBtn.visible = true;
};
};
};
}
public function endStage():void{
cBtn.addEventListener(MouseEvent.MOUSE_UP, startNew);
mcUpsell.addEventListener(MouseEvent.MOUSE_UP, gotoUpsell);
cBtn.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
mcUpsell.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
tStageScore.text = QBGameHandler.prettyScore(QBGameHandler.sMainHandler.getUserData("stagescore"), false);
tPerfects1.text = String(QBGameHandler.sMainHandler.getUserData("curperfect"));
tMaxGroup1.text = String(QBGameHandler.sMainHandler.getUserData("curmaxgroup"));
if (QBGameHandler.sMainHandler.getCurrentLevel() <= 10){
mcUpsell.gotoAndStop((QBGameHandler.sMainHandler.getCurrentLevel() + 1));
} else {
mcUpsell.gotoAndStop(skxRandom.getRandomInt(2, 10));
};
QBGameHandler.sMainHandler.stageUp();
}
public function onDialogAdd(_arg1:Event=null):void{
if (dialogs.getChildByName("btn_done")){
dialogs.getChildByName("btn_done").addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
dialogs.getChildByName("btn_done").addEventListener(MouseEvent.MOUSE_UP, closeHelpScreen);
};
if (dialogs.getChildByName("mainHowToPlay")){
dialogs.getChildByName("mainHowToPlay").addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
dialogs.getChildByName("mainHowToPlay").addEventListener(MouseEvent.MOUSE_UP, showHelpScreen);
};
if (dialogs.getChildByName("mainMenuBtn")){
dialogs.getChildByName("mainMenuBtn").addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
dialogs.getChildByName("mainMenuBtn").addEventListener(MouseEvent.MOUSE_UP, gotoMainMenu);
};
if (dialogs.getChildByName("resumeBtn")){
dialogs.getChildByName("resumeBtn").addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
dialogs.getChildByName("resumeBtn").addEventListener(MouseEvent.MOUSE_UP, closeMenu);
};
if (dialogs.getChildByName("justquitBtn")){
dialogs.getChildByName("justquitBtn").addEventListener(MouseEvent.MOUSE_UP, gotoMainMenu);
dialogs.getChildByName("justquitBtn").addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
};
if (dialogs.getChildByName("submitscoreBtn")){
dialogs.getChildByName("submitscoreBtn").addEventListener(MouseEvent.MOUSE_UP, gotoHighScoreFromGame);
dialogs.getChildByName("submitscoreBtn").addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
};
if (dialogs.getChildByName("cancelBtn")){
dialogs.getChildByName("cancelBtn").addEventListener(MouseEvent.MOUSE_UP, goBackToMenu);
dialogs.getChildByName("cancelBtn").addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
};
if (dialogs.getChildByName("cancelTipBtn")){
dialogs.getChildByName("cancelTipBtn").addEventListener(MouseEvent.MOUSE_UP, closeTip);
dialogs.getChildByName("cancelTipBtn").addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
};
}
public function shuffle(_arg1:MouseEvent):void{
if (((((QBGameHandler.sMainHandler) && (!(QBGameHandler.sMainHandler.getGameOver())))) && (!(QBGameHandler.sMainHandler.getPaused())))){
QBGameHandler.sMainHandler.shuffleBoard();
updatePowerMoves();
};
}
public function clearPreviews():void{
var _local1:Array;
var _local2:int;
while (previews.length) {
if (contains(previews[(previews.length - 1)])){
removeChild(previews[(previews.length - 1)]);
};
previews.pop();
};
previews = new Array();
_local1 = QBPackHandler.getGamePacks();
_local2 = 0;
while (_local2 < _local1.length) {
if (((_local1[_local2].preview) && (contains(_local1[_local2].preview)))){
removeChild(_local1[_local2].preview);
};
_local2++;
};
}
public function createPreview():void{
var _local1:*;
var _local2:String;
var _local3:int;
var _local4:BitmapData;
var _local5:Bitmap;
var _local6:*;
if (((previewload.length) && ((clearingPreviews == false)))){
_local1 = previewload.pop();
_local2 = _local1.data;
_local3 = _local1.index;
_local4 = QBGameHandler.sMainHandler.getLevelPreview(_local2);
_local5 = new Bitmap(_local4);
_local5.scaleX = 0.2;
_local5.scaleY = 0.2;
previews.push(_local5);
_local6 = getChildByName(String(("level" + _local3)));
if (((_local6) && (_local5))){
_local5.x = (_local6.x - 84.5);
_local5.y = (_local6.y - 48);
addChildAt(_local5, (getChildIndex(_local6) + 1));
};
skxScheduler.schedule(createPreview, 300);
};
}
public function scrollPackRight(_arg1:Event):void{
if (levelPackPos < (QBPackHandler.getLevelPackCount() - 5)){
levelPackPos++;
QBGameHandler.m_iSelectedPack++;
buildPacks();
setPreviewAvatar();
buildLevelPreview();
};
}
public function closeHelpScreen(_arg1:Event=null):void{
goBackToMenu();
}
public function updatePerc(_arg1:Event):void{
}
public function checkWaterLogged(_arg1:Object):void{
var _local2:*;
if (_arg1.WATERCOUNT){
_local2 = (Number(_arg1.WATERCOUNT) + 1);
skxWhirled.getControl().player.setCookie({WATERCOUNT:_local2});
if (_local2 >= 5){
skxWhirled.getControl().player.awardTrophy("WATERLOGGED");
};
} else {
skxWhirled.getControl().player.setCookie({WATERCOUNT:1});
};
}
public function quickRestart(_arg1:MouseEvent=null):void{
QBGameHandler.sMainHandler.m_bGameStarted = false;
QBGameHandler.sMainHandler.m_bRestart = true;
if (QBGameHandler.sMainHandler.getPaused()){
QBGameHandler.sMainHandler.postPauseTimer();
};
QBGameHandler.sMainHandler.restartLevel();
}
public function goToHelp(_arg1:Event=null):void{
gotoAndStop("howtoplay");
}
public function playPack(_arg1:Event=null):void{
var _local2:Array;
var _local3:int;
clearingPreviews = true;
skxScheduler.cancelAll();
pBtn.mouseEnabled = false;
_local2 = QBPackHandler.getGamePacks();
_local3 = 0;
while (_local3 < _local2.length) {
if (((_local2[_local3]) && (_local2[_local3].icon))){
_local2[_local3].icon.mouseEnabled = false;
};
_local3++;
};
fader.gotoAndPlay("fadein");
skxScheduler.schedule(fadeCompleteToGame, 1000);
}
public function closeMenu(_arg1:MouseEvent=null):void{
if (QBGameHandler.sMainHandler){
QBGameHandler.sMainHandler.unPause();
};
dialogs.alpha = 1;
skxUtil.fadeTo(dialogs, 200, 5, 0);
skxUtil.goToFrameIn(dialogs, 1, 250);
updatePowerMoves();
menuBtn.enabled = true;
}
public function startGame(_arg1:Event=null):void{
if ((((QBGameHandler.sGameStarted == false)) && ((QBGameHandler.sAppStarted == true)))){
QBGameHandler.sGameStarted = true;
skxWhirled.getControl().addEventListener(Event.UNLOAD, cleanUp);
addEventListener(Event.UNLOAD, cleanUp);
lvlScore.visible = false;
tPerfectScore.visible = false;
lvl_numdisplay.visible = false;
tPreLevel.visible = false;
tPreLevelQbz.visible = false;
lvlCompleteDlg.visible = false;
overflow.visible = false;
overflow.gotoAndStop(1);
Timer.visible = false;
perfectcount = 0;
QBGameHandler.sMainHandler.m_oScoreText = tScore;
QBGameHandler.sMainHandler.m_TextExample = tScoreExample;
skxScheduler.unpause();
if (!QBGameHandler.sNewGameDispatcher){
QBGameHandler.sNewGameDispatcher = new EventDispatcher();
};
QBGameHandler.sNewGameDispatcher.addEventListener(QBGameEvent.GAME, onNewGame);
lvl_numdisplay.visible = true;
tPreLevel.visible = true;
tPreLevelQbz.visible = true;
if (QBGameHandler.m_aLevels){
QBGameHandler.m_iCurrentPackLevel = 0;
QBGameHandler.sMainHandler.loadLevel(QBGameHandler.m_aLevels[QBGameHandler.m_iCurrentPackLevel]);
setWhirledAvatar();
} else {
QBGameHandler.sMainHandler.startGame();
};
setUI();
QBGameHandler.WINDOW.renderWindow();
addSounds();
fader.gotoAndPlay("fadeout");
} else {
setUI();
};
}
public function closeTip(_arg1:Event=null):void{
if (QBGameHandler.sMainHandler){
QBGameHandler.sMainHandler.unPause();
};
skxUtil.fadeTo(dialogs, 200, 5, 0);
skxUtil.goToFrameIn(dialogs, 1, 250);
}
public function mouseBtn(_arg1:MouseEvent):void{
var _local2:int;
if (((((QBGameHandler.sMainHandler) && (!(QBGameHandler.sMainHandler.getIsOverSelected())))) && (!(QBGameHandler.sMainHandler.getPaused())))){
_local2 = 0;
_local2 = 0;
while (_local2 < QBGameHandler.sMainHandler.SELECTED.length) {
QBGameHandler.sMainHandler.SELECTED[_local2].bSelected = false;
QBGameHandler.sMainHandler.SELECTED[_local2].setAnimationState("IDLE");
_local2++;
};
};
}
public function setWhirledAvatar():void{
var _local1:Array;
if (QBPackHandler.m_oAvatar){
if (QBPackHandler.getAvatarPack("QBtar_Magician").swf == QBPackHandler.m_oAvatar){
QBPackHandler.m_oAvatar.x = 290;
QBPackHandler.m_oAvatar.y = 275;
} else {
QBPackHandler.m_oAvatar.x = 0;
QBPackHandler.m_oAvatar.y = 0;
};
QBPackHandler.m_sAvatarState = "idle";
QBPackHandler.m_oAvatar.addEventListener(Event.ENTER_FRAME, onAvaFrame);
addChildAt(QBPackHandler.m_oAvatar, (getChildIndex(overflow) - 1));
_local1 = QBPackHandler.getAvatarStates()["idle"];
QBPackHandler.m_oAvatar.gotoAndPlay(1, _local1[skxRandom.getRandomInt(0, _local1.length)]);
};
}
public function changeUser(_arg1:Event=null):void{
}
public function buildPacks():void{
var _local1:Array;
var _local2:int;
var _local3:int;
var _local4:int;
var _local5:*;
var _local6:*;
var _local7:MovieClip;
var _local8:Array;
_local1 = QBPackHandler.getGamePacks();
_local2 = 1;
while (_local2 < 6) {
_local5 = getChildByName(String(("pack" + _local2)));
_local6 = getChildByName(String(("txt_packname" + _local2)));
_local5.visible = false;
_local6.visible = false;
_local2++;
};
_local2 = 0;
while (_local2 < _local1.length) {
if (((((_local1[_local2]) && (_local1[_local2].type))) && ((_local1[_local2].type == "level")))){
_local7 = _local1[_local2].icon;
if (((_local7) && (contains(_local7)))){
removeChild(_local7);
_local7.removeEventListener(MouseEvent.CLICK, playPack1);
_local7.removeEventListener(MouseEvent.CLICK, playPack2);
_local7.removeEventListener(MouseEvent.CLICK, playPack3);
_local7.removeEventListener(MouseEvent.CLICK, playPack4);
_local7.removeEventListener(MouseEvent.CLICK, playPack5);
};
};
_local2++;
};
QBGameHandler.m_aLevels = null;
_local3 = 1;
_local4 = levelPackPos;
while (_local4 < _local1.length) {
if (((((((_local1[_local4]) && (_local1[_local4].type))) && ((_local1[_local4].type == "level")))) && (_local1[_local4].icon))){
_local7 = _local1[_local4].icon;
_local5 = getChildByName(String(("pack" + _local3)));
_local6 = getChildByName(String(("txt_packname" + _local3)));
if (((((_local5) && (_local6))) && (_local7))){
_local8 = _local1[_local4].levels;
_local7.x = _local5.x;
_local7.y = _local5.y;
_local6.visible = true;
_local6.text = String(_local1[_local4].packname);
addChildAt(_local7, (getChildIndex(_local5) + 1));
_local7.buttonMode = true;
_local7.mouseEnabled = true;
_local7.mouseChildren = false;
switch (_local3){
case 1:
_local7.addEventListener(MouseEvent.CLICK, playPack1);
break;
case 2:
_local7.addEventListener(MouseEvent.CLICK, playPack2);
break;
case 3:
_local7.addEventListener(MouseEvent.CLICK, playPack3);
break;
case 4:
_local7.addEventListener(MouseEvent.CLICK, playPack4);
break;
case 5:
_local7.addEventListener(MouseEvent.CLICK, playPack5);
break;
};
_local7.addEventListener(MouseEvent.MOUSE_DOWN, playClickSnd);
_local3++;
};
};
_local4++;
};
}
public function scrollPackLeft(_arg1:Event):void{
if (levelPackPos > 0){
levelPackPos--;
QBGameHandler.m_iSelectedPack--;
buildPacks();
setPreviewAvatar();
buildLevelPreview();
};
}
public function gotoUpsell(_arg1:MouseEvent):void{
var _local2:URLRequest;
_local2 = new URLRequest("http://games.skunkstudios.com/games/qbeez2/");
navigateToURL(_local2);
}
public function gotoMainGame(_arg1:MouseEvent):void{
sGameMode = "3";
resetSeed();
QBGameHandler.sGameStarted = false;
QBGameHandler.sGameMode = 2;
QBGameHandler.sLastTotalScore = 0;
QBGameHandler.sMainHandler.resetQuest();
pBtn.enabled = false;
pBtn2.enabled = false;
fader.gotoAndPlay("fadein");
skxScheduler.schedule(gotoAndStop, 1000, null, "game", "game");
}
public function updateVersion():void{
if (txt_Version){
txt_Version.text = "Ver. 1.211";
txt_Version.selectable = false;
txt_Version.mouseEnabled = false;
};
}
public function fadeComplete():void{
if (skxWhirled.getControl().isConnected()){
gotoAndStop("1", "packs");
} else {
gotoAndStop("game", "game");
};
}
public function bubbleWater():void{
if (Timer.watertop.currentFrame < 19){
Timer.watertop.gotoAndStop((Timer.watertop.currentFrame + 1));
} else {
Timer.watertop.gotoAndStop(7);
};
}
public function onAppInit(_arg1:Event=null):void{
QBGameHandler.sXMLFile = "";
QBGameHandler.sLastTotalScore = 0;
setUIVisible();
if (QBGameHandler.sAppStarted == false){
QBGameHandler.sMainHandler = new QBGameHandler(MovieClip(root));
dialogs.addEventListener(Event.ADDED, onDialogAdd);
QBGameHandler.sGameStarted = false;
QBGameHandler.sAppStarted = true;
} else {
pBtn.enabled = true;
setUIVisible();
if (QBGameHandler.sAppState != "menu"){
fader.gotoAndPlay("fadeout");
};
QBGameHandler.sAppState = "menu";
};
}
public function updateTimer(_arg1:Event):void{
var _local2:Number;
var _local3:int;
var _local4:Number;
if (!QBGameHandler.sMainHandler){
return;
};
if (QBGameHandler.sGameMode != 3){
if (((((!(QBGameHandler.sMainHandler.getTimerPassed())) && (!(QBGameHandler.sMainHandler.getGameOver())))) && (!(QBGameHandler.sMainHandler.m_bTimeBonus)))){
_local2 = QBGameHandler.sMainHandler.getGameTime();
Timer.gotoAndStop(_local2);
};
if (QBGameHandler.sMainHandler.getGameOver()){
_local3 = 0;
_local4 = QBGameHandler.sMainHandler.getGameTime();
if (QBGameHandler.sMainHandler.getTimerPassed()){
if ((((overflow.visible == false)) && (skxWhirled.getControl().isConnected()))){
skxWhirled.getControl().player.awardTrophy("OVERFLOW");
};
_local3 = (((100 - _local4) / 100) * 22);
overflow.visible = true;
overflow.gotoAndStop(_local3);
if (_local3 >= 22){
Timer.filters = [new BlurFilter(6, 6, 1)];
};
};
};
};
}
}
}//package qbeez_online_release_fla
Section 90
//MC_4 (qbeez_online_release_fla.MC_4)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class MC_4 extends MovieClip {
public function MC_4(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 91
//overflow_111 (qbeez_online_release_fla.overflow_111)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class overflow_111 extends MovieClip {
public function overflow_111(){
addFrameScript(0, frame1, 21, frame22);
}
function frame1(){
stop();
}
function frame22(){
stop();
}
}
}//package qbeez_online_release_fla
Section 92
//pop_16 (qbeez_online_release_fla.pop_16)
package qbeez_online_release_fla {
import flash.display.*;
import flash.text.*;
public dynamic class pop_16 extends MovieClip {
public var continuesavedBtn:SimpleButton;
public var hdr_PlayerName:TextField;
public var mailsendBtn:SimpleButton;
public var tName:TextField;
public var hdr_welcome:TextField;
public var mcQBz:MovieClip;
public var txt_qbeezpaused:TextField;
public var startnewgameBtn:SimpleButton;
public var tlink:TextField;
public var hdr_newplayer:TextField;
public var cancelBtn:SimpleButton;
public var mailFriend2:TextField;
public var copyBtn:SimpleButton;
public var mailFriend3:TextField;
public var mailPlayer1:TextField;
public var hdr_oops:TextField;
public var mailFriend1:TextField;
public var txt_typeaplayername:TextField;
public var bNameOk:SimpleButton;
public var mailBody:TextField;
public function pop_16(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
stop();
}
}
}//package qbeez_online_release_fla
Section 93
//pop_24 (qbeez_online_release_fla.pop_24)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class pop_24 extends MovieClip {
public var qbBtn12:SimpleButton;
public var qbBtn1:SimpleButton;
public var qbBtn3:SimpleButton;
public var qbBtn4:SimpleButton;
public var qbBtn6:SimpleButton;
public var qbBtn11:SimpleButton;
public var qbBtn2:SimpleButton;
public var qbBtn8:SimpleButton;
public var qbBtn5:SimpleButton;
public var qbBtn7:SimpleButton;
public var qbBtn9:SimpleButton;
public var qbBtn13:SimpleButton;
public var qbBtn14:SimpleButton;
public var qbBtn15:SimpleButton;
public var qbBtn10:SimpleButton;
public function pop_24(){
addFrameScript(1, frame2);
}
function frame2(){
stop();
}
}
}//package qbeez_online_release_fla
Section 94
//pop_41 (qbeez_online_release_fla.pop_41)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class pop_41 extends MovieClip {
public var qbBtn12:SimpleButton;
public var qbBtn1:SimpleButton;
public var qbBtn3:SimpleButton;
public var qbBtn4:SimpleButton;
public var qbBtn6:SimpleButton;
public var qbBtn11:SimpleButton;
public var qbBtn2:SimpleButton;
public var qbBtn8:SimpleButton;
public var qbBtn5:SimpleButton;
public var qbBtn7:SimpleButton;
public var qbBtn9:SimpleButton;
public var qbBtn13:SimpleButton;
public var qbBtn14:SimpleButton;
public var qbBtn15:SimpleButton;
public var qbBtn10:SimpleButton;
public function pop_41(){
addFrameScript(1, frame2);
}
function frame2(){
stop();
}
}
}//package qbeez_online_release_fla
Section 95
//QB_66 (qbeez_online_release_fla.QB_66)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB_66 extends MovieClip {
public var qbroot:MovieClip;
public function QB_66(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 96
//QB2_67 (qbeez_online_release_fla.QB2_67)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_67 extends MovieClip {
public function QB2_67(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 97
//QB2_68 (qbeez_online_release_fla.QB2_68)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_68 extends MovieClip {
public function QB2_68(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 98
//QB2_72 (qbeez_online_release_fla.QB2_72)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_72 extends MovieClip {
public function QB2_72(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
stop();
}
}
}//package qbeez_online_release_fla
Section 99
//QB2_75 (qbeez_online_release_fla.QB2_75)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_75 extends MovieClip {
public function QB2_75(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 100
//QB2_76 (qbeez_online_release_fla.QB2_76)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_76 extends MovieClip {
public function QB2_76(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 101
//QB2_77 (qbeez_online_release_fla.QB2_77)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_77 extends MovieClip {
public function QB2_77(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 102
//QB2_78 (qbeez_online_release_fla.QB2_78)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_78 extends MovieClip {
public function QB2_78(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 103
//QB2_79 (qbeez_online_release_fla.QB2_79)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_79 extends MovieClip {
public function QB2_79(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 104
//QB2_80 (qbeez_online_release_fla.QB2_80)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_80 extends MovieClip {
public function QB2_80(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 105
//QB2_81 (qbeez_online_release_fla.QB2_81)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_81 extends MovieClip {
public function QB2_81(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 106
//QB2_82 (qbeez_online_release_fla.QB2_82)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_82 extends MovieClip {
public function QB2_82(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 107
//QB2_83 (qbeez_online_release_fla.QB2_83)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_83 extends MovieClip {
public function QB2_83(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 108
//QB2_84 (qbeez_online_release_fla.QB2_84)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_84 extends MovieClip {
public function QB2_84(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 109
//QB2_86 (qbeez_online_release_fla.QB2_86)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_86 extends MovieClip {
public function QB2_86(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 110
//QB2_87 (qbeez_online_release_fla.QB2_87)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class QB2_87 extends MovieClip {
public function QB2_87(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 111
//QBz2_dialogs_web_42 (qbeez_online_release_fla.QBz2_dialogs_web_42)
package qbeez_online_release_fla {
import flash.display.*;
import flash.text.*;
public dynamic class QBz2_dialogs_web_42 extends MovieClip {
public var mainHowToPlay:SimpleButton;
public var justquitBtn:SimpleButton;
public var txt_qbeezpaused:TextField;
public var mainMenuBtn:SimpleButton;
public var cancelBtn:SimpleButton;
public var submitscoreBtn:SimpleButton;
public var btn_done:SimpleButton;
public var cancelTipBtn:SimpleButton;
public var resumeBtn:SimpleButton;
public function QBz2_dialogs_web_42(){
addFrameScript(0, frame1, 1, frame2, 2, frame3, 3, frame4, 4, frame5, 5, frame6);
}
function frame3(){
stop();
}
function frame6(){
stop();
}
function frame1(){
stop();
}
function frame4(){
stop();
}
function frame5(){
stop();
}
function frame2(){
stop();
}
}
}//package qbeez_online_release_fla
Section 112
//QBz2_dialogs_whirled_122 (qbeez_online_release_fla.QBz2_dialogs_whirled_122)
package qbeez_online_release_fla {
import flash.display.*;
import flash.text.*;
public dynamic class QBz2_dialogs_whirled_122 extends MovieClip {
public var mainHowToPlay:SimpleButton;
public var justquitBtn:SimpleButton;
public var txt_qbeezpaused:TextField;
public var mainMenuBtn:SimpleButton;
public var txt_tip1:TextField;
public var cancelBtn:SimpleButton;
public var submitscoreBtn:SimpleButton;
public var btn_done:SimpleButton;
public var hdr_tip1:TextField;
public var hdr_tip2:TextField;
public var cancelTipBtn:SimpleButton;
public var resumeBtn:SimpleButton;
public function QBz2_dialogs_whirled_122(){
addFrameScript(0, frame1, 1, frame2, 2, frame3, 3, frame4, 4, frame5, 5, frame6, 8, frame9, 9, frame10);
}
function frame10(){
stop();
}
function frame3(){
stop();
}
function frame6(){
stop();
}
function frame1(){
stop();
}
function frame4(){
stop();
}
function frame5(){
stop();
}
function frame9(){
stop();
}
function frame2(){
stop();
}
}
}//package qbeez_online_release_fla
Section 113
//stars_261 (qbeez_online_release_fla.stars_261)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class stars_261 extends MovieClip {
public function stars_261(){
addFrameScript(9, frame10);
}
function frame10(){
stop();
}
}
}//package qbeez_online_release_fla
Section 114
//Timer_105 (qbeez_online_release_fla.Timer_105)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class Timer_105 extends MovieClip {
public var watertop:MovieClip;
public function Timer_105(){
addFrameScript(0, frame1);
}
function frame1(){
}
}
}//package qbeez_online_release_fla
Section 115
//timer_107 (qbeez_online_release_fla.timer_107)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class timer_107 extends MovieClip {
public var watertop:MovieClip;
public function timer_107(){
addFrameScript(0, frame1, 18, frame19, 27, frame28, 31, frame32, 35, frame36);
}
function frame1(){
stop();
}
function frame19(){
gotoAndPlay("turb1");
}
function frame36(){
gotoAndPlay("turb4");
}
function frame28(){
gotoAndPlay("turb2");
}
function frame32(){
gotoAndPlay("turb3");
}
}
}//package qbeez_online_release_fla
Section 116
//upsell1_129 (qbeez_online_release_fla.upsell1_129)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class upsell1_129 extends MovieClip {
public var lmBtn:SimpleButton;
public function upsell1_129(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 117
//whirledmenucloud2_1 (qbeez_online_release_fla.whirledmenucloud2_1)
package qbeez_online_release_fla {
import flash.display.*;
public dynamic class whirledmenucloud2_1 extends MovieClip {
public function whirledmenucloud2_1(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package qbeez_online_release_fla
Section 118
//QBeez (QBeezSrc.QBeez)
package QBeezSrc {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.geom.*;
import skxSource.*;
import flash.filters.*;
public class QBeez extends skxSprite {
public var bFlipping:Boolean;// = false
public var xVel:Number;// = 0
public var m_bHopping:Boolean;// = false
public var waterRef:Bitmap;// = null
private var m_oQBGameHandler;
public var bGameOver:Boolean;// = false
public var yVel:Number;// = 0
public var m_bRising:Boolean;// = false
public var bSquished:Boolean;// = false
public var sColor:String;// = "GEN"
public var bCrying:Boolean;// = false
public var bPainted:Boolean;// = false
private var m_sGoToState:String;// = ""
private var m_oCurBlur:BlurFilter;// = null
public var bFlipped:Boolean;// = false
public var bKill:Boolean;// = false
public var xPos:int;// = 0
public var bDrown:Boolean;// = false
public var xAcc:Number;// = 0
public var bMouseOver:Boolean;// = false
public var m_oEffect:skxSprite;
public var yPos:int;// = 0
public var bSelected:Boolean;// = false
public var qbType:int;// = 0
public var nForceX:Number;// = 0
public var nForceY:Number;// = 0
public var yAcc:Number;// = 0
public var bPainting:Boolean;// = false
public var bDropping:Boolean;// = false
public var nSlidePos:Number;// = 0
public var nDropLocV:Number;// = 0
public var bSliding:Boolean;// = false
public var nSlideLocX:Number;// = 0
public var bPowerUp:Boolean;// = false
public var mData;// = 0
public var bBlownUp:Boolean;// = false
public var nQbLocV2:Number;// = 0
public static var sFlipDispatcher:EventDispatcher = new EventDispatcher();
public static var sRotDispatcher:EventDispatcher = new EventDispatcher();
public static var sShuffleDispatcher:EventDispatcher = new EventDispatcher();
public function QBeez(_arg1:Boolean=false, _arg2:Number=0, _arg3:Number=0, _arg4:String=""){
m_oQBGameHandler = undefined;
m_oEffect = new skxSprite();
m_sGoToState = "";
m_oCurBlur = null;
xPos = 0;
yPos = 0;
qbType = 0;
bSelected = false;
bDropping = false;
bSliding = false;
bKill = false;
bSquished = false;
bBlownUp = false;
bGameOver = false;
bFlipping = false;
bMouseOver = false;
yVel = 0;
yAcc = 0;
bFlipped = false;
bDrown = false;
bCrying = false;
sColor = "GEN";
bPainting = false;
bPainted = false;
xVel = 0;
xAcc = 0;
m_bHopping = false;
nForceX = 0;
nForceY = 0;
m_bRising = false;
nQbLocV2 = 0;
nDropLocV = 0;
nSlideLocX = 0;
nSlidePos = 0;
bPowerUp = false;
waterRef = null;
mData = 0;
bPowerUp = _arg1;
super();
m_bUpdatable = true;
m_oEffect.m_bUpdatable = true;
sRotDispatcher.addEventListener(QBRotateEvent.ROTATE, onRotate);
sFlipDispatcher.addEventListener(QBFlipEvent.FLIP, onFlip);
sShuffleDispatcher.addEventListener(QBShuffleEvent.SHUFFLE, onShuffle);
}
override public function onMouseOver():void{
if ((((((((((bKill == true)) || (m_oQBGameHandler.getGameOver()))) || (bGameOver))) || (m_oQBGameHandler.getPaused()))) || (bBlownUp))){
return;
};
bMouseOver = true;
if (((m_oQBGameHandler.getIsSelected()) && ((bSelected == true)))){
m_oQBGameHandler.setIsOverSelected(true);
} else {
if (((!(m_oQBGameHandler.getIsSelected())) && ((bSelected == false)))){
if (((((((isOnTop()) && (!((yPos == 0))))) && (!(bFlipped)))) && (!(bPowerUp)))){
goToState("FLIP", 2000);
} else {
if (!bPowerUp){
goToState("ROLLOVER", 500);
};
};
} else {
if (((((((isOnTop()) && (!((yPos == 0))))) && (!(bFlipped)))) && (!(bPowerUp)))){
goToState("FLIP", 2000);
} else {
if (!bPowerUp){
goToState("ROLLOVER", 500);
};
};
};
};
}
public function isOnTop():Boolean{
var _local1:QBeez;
_local1 = null;
_local1 = m_oQBGameHandler.getQBee(xPos, (yPos - 1));
if (_local1){
return (false);
};
return (true);
}
protected function removeListeners():void{
sRotDispatcher.removeEventListener(QBRotateEvent.ROTATE, onRotate);
sFlipDispatcher.removeEventListener(QBFlipEvent.FLIP, onFlip);
sShuffleDispatcher.removeEventListener(QBShuffleEvent.SHUFFLE, onShuffle);
}
public function onRotate(_arg1:QBRotateEvent){
var _local2:int;
var _local3:Number;
var _local4:Number;
var _local5:int;
var _local6:int;
if ((((((bKill == true)) || (m_oQBGameHandler.getGameOver()))) || (m_oQBGameHandler.getPaused()))){
return;
};
_local2 = _arg1.dir();
_local3 = 0;
_local4 = 0;
_local5 = yPos;
_local6 = ((m_oQBGameHandler.getBoardSize() - xPos) - 1);
if (_local2 == 1){
_local5 = ((m_oQBGameHandler.getBoardSize() - yPos) - 1);
_local6 = xPos;
};
m_oQBGameHandler.TEMPGRID[String(((_local5 + "_") + _local6))] = this;
setGridPos(_local5, _local6);
_local3 = skxUtil.getDistance(x, y, (m_oQBGameHandler.getStartLocX() + (xPos * m_oQBGameHandler.getQBScale())), (m_oQBGameHandler.getStartLocY() + (yPos * m_oQBGameHandler.getQBScale())));
_local4 = (_local3 / (0.25 + (m_oQBGameHandler.getBoardSize() / 100)));
resetForces();
resetSliding();
moveTo((m_oQBGameHandler.m_nStartLocX + (xPos * m_oQBGameHandler.getQBScale())), (m_oQBGameHandler.m_nStartLocY + (yPos * m_oQBGameHandler.getQBScale())), _local4, true);
m_oQBGameHandler.m_iNumberUpdated++;
m_oQBGameHandler.updateGrid();
}
override public function onAnimationEnd(_arg1:String):void{
var _local2:Number;
if (((!(m_CurAnimation)) || (bPowerUp))){
return;
};
_local2 = Math.random();
switch (_arg1){
case "FLIPFAST":
setState("IDLE");
break;
case "QBLINK":
if (_local2 < 0.003){
setAnimationState("QBLINK");
} else {
setAnimationState("IDLE");
};
break;
case "QHBLINK":
if (_local2 < 0.03){
setAnimationState("QHBLINK");
} else {
setAnimationState("HOLDBREATH");
};
break;
case "BLINK":
if (_local2 < 0.3){
setAnimationState("QBLINK");
} else {
if (_local2 < 0.4){
setAnimationState("BLINK");
if (_local2 < 0.05){
m_oQBGameHandler.playSound("BLINK1", 0, 1, true);
};
if (_local2 < 0.1){
m_oQBGameHandler.playSound("BLINK2", 0, 1, true);
};
} else {
if ((((_local2 < 0.45)) && (!(bGameOver)))){
setAnimationState("SMILE");
} else {
setAnimationState("IDLE");
};
};
};
break;
case "INHALE":
if (QBGameHandler.sGameMode != 3){
setAnimationState("HOLDBREATH");
};
break;
case "HOLDBLINK":
if (_local2 < 0.1){
setAnimationState("HOLDBREATH");
} else {
if (_local2 < 0.15){
setAnimationState("QHBLINK");
};
};
break;
case "HOLDBREATH":
if (_local2 < 0.001){
setAnimationState("HOLDBLINK");
};
break;
case "SCAREDLOOK":
if (_local2 < 0.05){
setAnimationState("SCARED");
} else {
if (_local2 < 0.1){
setAnimationState("IDLE");
};
};
break;
case "SCARED":
if (_local2 < 0.05){
setAnimationState("SCAREDLOOK");
};
break;
case "SCAREDINHALE":
setAnimationState("SCARED");
break;
case "IDLE":
if ((((((((((_local2 < 0.005)) && ((m_oQBGameHandler.getGameTime() > 50)))) && ((skxRandom.getRandomInt(0, 100) < m_oQBGameHandler.getGameTime())))) && (!(bGameOver)))) && (!((QBGameHandler.sGameMode == 3))))){
setAnimationState("SCAREDINHALE");
} else {
if (_local2 < 0.0006){
setAnimationState("BLINK");
} else {
if ((((_local2 < 0.0009)) && (!(bGameOver)))){
setAnimationState("SMILE");
};
};
};
break;
case "EMOTE":
case "SMILE":
if (_local2 < 0.05){
setAnimationState("IDLE");
} else {
if (_local2 < 0.06){
setAnimationState("BLINK");
};
};
break;
case "SQUISH":
setAnimationState("IDLE");
break;
case "ROLLOVER":
if (_local2 < 0.4){
setAnimationState("IDLE");
};
break;
};
}
public function onPositionChange():void{
var _local1:QBeez;
m_oEffect.visible = false;
if (bPowerUp){
if ((((qbType >= 17)) && ((qbType <= 31)))){
_local1 = m_oQBGameHandler.getQBee((xPos + 1), yPos);
if (((_local1) && ((_local1.qbType == qbType)))){
m_oEffect.visible = true;
_local1.m_oEffect.visible = true;
};
_local1 = m_oQBGameHandler.getQBee((xPos - 1), yPos);
if (((_local1) && ((_local1.qbType == qbType)))){
m_oEffect.visible = true;
_local1.m_oEffect.visible = true;
};
_local1 = m_oQBGameHandler.getQBee(xPos, (yPos + 1));
if (((_local1) && ((_local1.qbType == qbType)))){
m_oEffect.visible = true;
_local1.m_oEffect.visible = true;
};
_local1 = m_oQBGameHandler.getQBee(xPos, (yPos - 1));
if (((_local1) && ((_local1.qbType == qbType)))){
m_oEffect.visible = true;
_local1.m_oEffect.visible = true;
};
} else {
if ((((qbType >= 41)) && ((qbType <= 55)))){
_local1 = m_oQBGameHandler.getQBee((xPos + 1), yPos);
if (((_local1) && ((_local1.qbType == qbType)))){
m_oEffect.visible = true;
_local1.m_oEffect.visible = true;
};
_local1 = m_oQBGameHandler.getQBee((xPos - 1), yPos);
if (((_local1) && ((_local1.qbType == qbType)))){
m_oEffect.visible = true;
_local1.m_oEffect.visible = true;
};
_local1 = m_oQBGameHandler.getQBee(xPos, (yPos + 1));
if (((_local1) && ((_local1.qbType == qbType)))){
m_oEffect.visible = true;
_local1.m_oEffect.visible = true;
};
_local1 = m_oQBGameHandler.getQBee(xPos, (yPos - 1));
if (((_local1) && ((_local1.qbType == qbType)))){
m_oEffect.visible = true;
_local1.m_oEffect.visible = true;
};
} else {
if (qbType == 16){
m_oEffect.visible = true;
};
};
};
};
}
override public function onRender(_arg1:BitmapData, _arg2:Object=null):void{
super.onRender(_arg1, _arg2);
if (m_oEffect.visible){
m_oEffect.onRender(_arg1);
};
}
override protected function onMoveToTarget():void{
if (((bPainting) && ((qbType == 16)))){
setTimerOff();
m_oQBGameHandler.m_TypeList[qbType] = (m_oQBGameHandler.m_TypeList[qbType] - 1);
m_oQBGameHandler.m_LiveQB--;
bKill = true;
removeListeners();
super.onDestroy();
if (m_oQBGameHandler.m_iRunningBrushes > 0){
m_oQBGameHandler.m_iRunningBrushes = 0;
m_oQBGameHandler.setIsMoving(false);
m_oQBGameHandler.setIsShifting(false);
m_oQBGameHandler.removeBlanks();
m_oQBGameHandler.removeColumns();
m_oQBGameHandler.sortGrid();
m_oQBGameHandler.updateGameState();
m_oQBGameHandler.setIsPainting(false);
};
return;
};
if ((((bKill == true)) || (bDrown))){
return;
};
if (!bPowerUp){
if (bSelected){
setAnimationState("HOT");
} else {
if (bCrying){
setAnimationState("EMOTE");
} else {
if (bDrown){
setAnimationState("INHALE");
} else {
if (!bDrown){
setAnimationState("IDLE");
};
};
};
};
};
if (((m_oQBGameHandler.getIsMoving()) && (!(m_oQBGameHandler.getIsShifting())))){
m_oQBGameHandler.setIsMoving(false);
m_oQBGameHandler.removeBlanks();
m_oQBGameHandler.removeColumns();
m_oQBGameHandler.sortGrid();
m_oQBGameHandler.updateGameState();
};
}
public function setGridPos(_arg1:int, _arg2:int){
xPos = _arg1;
yPos = _arg2;
}
public function onExitScreen(_arg1:MouseEvent):void{
var _local2:int;
_local2 = 0;
_local2 = 0;
while (_local2 < m_oQBGameHandler.SELECTED.length) {
m_oQBGameHandler.SELECTED[_local2].bSelected = false;
if (!m_oQBGameHandler.SELECTED[_local2].bPowerUp){
m_oQBGameHandler.SELECTED[_local2].setAnimationState("IDLE");
};
_local2++;
};
}
public function onBlowUp():void{
var _local1:QBExplosion;
var _local2:Number;
var _local3:String;
rotation = skxRandom.getRandomFlt(0, 360);
bBlownUp = true;
getWindow().removeObject(m_oEffect);
if (bPowerUp == true){
destroyStones((xPos + 1), (yPos + 1));
destroyStones((xPos - 1), (yPos - 1));
destroyStones((xPos - 1), (yPos + 1));
destroyStones((xPos + 1), (yPos - 1));
destroyStones((xPos + 1), yPos);
destroyStones((xPos - 1), yPos);
destroyStones(xPos, (yPos + 1));
destroyStones(xPos, (yPos - 1));
};
yAcc = (skxRandom.getRandomFlt(5, 10) * -1);
xAcc = 0;
yVel = (skxRandom.getRandomFlt(1000, 2000) * -1);
xVel = skxRandom.getRandomFlt(-300, 300);
setDepth((m_oQBGameHandler.getQBCount() + 100));
m_oQBGameHandler.setQBee(xPos, yPos);
m_oQBGameHandler.m_LiveQB--;
m_oQBGameHandler.m_TypeList[qbType] = (m_oQBGameHandler.m_TypeList[qbType] - 1);
if (bPowerUp == false){
setState("BLOWNUP");
} else {
if ((((qbType >= 17)) && ((qbType <= 31)))){
if (getWindow()){
_local1 = new QBExplosion(x, y, m_oQBGameHandler.IMAGEDATA[39]);
_local1.setDepth(10000);
getWindow().addObject(_local1);
};
Delete();
} else {
if (qbType == 40){
setAnimationState("STONEBLOWNUP");
};
};
};
m_oQBGameHandler.m_iBlownUpPieces++;
m_oQBGameHandler.m_iBlownAway--;
if (m_oQBGameHandler.m_iBlownAway <= 0){
m_oQBGameHandler.dispatchGameEvent({EVENT:"BOMBGROUP", COUNT:m_oQBGameHandler.m_iBlownUpPieces});
_local2 = ((m_oQBGameHandler.m_iBlownUpPieces * m_oQBGameHandler.m_iBlownUpPieces) * 100);
_local3 = m_oQBGameHandler.addScore(_local2);
m_oQBGameHandler.createScoreText(_local3, 400, 240, _local2);
m_oQBGameHandler.setIsShifting(false);
m_oQBGameHandler.removeBlanks();
m_oQBGameHandler.removeColumns();
m_oQBGameHandler.sortGrid();
m_oQBGameHandler.updateGameState();
m_oQBGameHandler.m_iBlownAway = 0;
m_oQBGameHandler.m_iBlownUpPieces = 0;
};
}
override protected function onTimer(_arg1:Event=null):void{
if (m_oQBGameHandler.getPaused()){
return;
};
setTimerOff();
if ((((m_sGoToState == "SMILE")) || ((((((m_sGoToState == "ROLLOVER")) && (!(bGameOver)))) && (!(bPowerUp)))))){
if (((((!(bSelected)) && (!(bDropping)))) && (!(bSliding)))){
setAnimationState("SMILE");
};
m_sGoToState = "";
} else {
if (m_sGoToState == "MAGIC"){
sColor = m_oQBGameHandler.getColor(qbType);
bPowerUp = false;
setImage(m_oQBGameHandler.IMAGEDATA[qbType]);
setAnimationState("IDLE");
switch (qbType){
case 1:
setColorOffset(253, 171, 252);
break;
case 2:
setColorOffset(-150, -150, -150);
break;
case 3:
setColorOffset(-75, -75, -75);
break;
case 4:
setColorOffset(112, 183, 254);
break;
case 5:
setColorOffset(0xFF, 0, 0);
break;
case 6:
setColorOffset(0xFF, 0xFF, 0);
break;
case 7:
setColorOffset(116, 1, 1);
break;
case 8:
setColorOffset(2, 141, 1);
break;
case 9:
setColorOffset(1, 98, 216);
break;
case 10:
setColorOffset(243, 134, 1);
break;
case 11:
setColorOffset(120, 0, 167);
break;
case 12:
setColorOffset(153, 102, 0);
break;
case 13:
setColorOffset(250, 250, 250);
break;
case 14:
setColorOffset(0xFF, 0, 212);
break;
case 15:
setColorOffset(5, 254, 5);
break;
};
skxScheduler.schedule(setColorOffset, 200, null, 150, 150, 150);
skxScheduler.schedule(setColorOffset, 300, null, 0, 0, 0);
m_sGoToState = "";
} else {
if (m_sGoToState == "FLIPFAST"){
m_oQBGameHandler.playSound("SPLAT");
if (qbType < 16){
sColor = m_oQBGameHandler.getColor(qbType);
bPowerUp = false;
setImage(m_oQBGameHandler.IMAGEDATA[qbType]);
setAnimationState(m_sGoToState);
} else {
if (qbType == 16){
bPowerUp = true;
setImage(m_oQBGameHandler.IMAGEDATA[qbType]);
setAnimationState("BRUSHIDLE");
} else {
if ((((qbType >= 17)) && ((qbType <= 32)))){
bPowerUp = true;
setImage(m_oQBGameHandler.IMAGEDATA[17]);
setAnimationState(m_oQBGameHandler.getType(qbType));
} else {
if ((((qbType >= 41)) && ((qbType <= 55)))){
bPowerUp = true;
setImage(m_oQBGameHandler.IMAGEDATA[41]);
setAnimationState(m_oQBGameHandler.getType(qbType));
} else {
if (qbType == 40){
bPowerUp = true;
setImage(m_oQBGameHandler.IMAGEDATA[40]);
setAnimationState("IDLE");
};
};
};
};
};
m_sGoToState = "";
} else {
if ((((((((m_sGoToState == "FLIP")) && (bMouseOver))) && (!(bGameOver)))) && (!(bPowerUp)))){
bFlipped = true;
if (((((!(bSelected)) && (!(bDropping)))) && (!(bSliding)))){
setAnimationState(m_sGoToState);
};
nDropLocV = y;
bFlipping = true;
nForceY = m_oQBGameHandler.getGravity();
yVel = ((-(nForceY) * m_oQBGameHandler.getFallScale()) * 6);
m_sGoToState = "";
} else {
if ((((((m_sGoToState == "EMOTE")) && (bGameOver))) && (!(bPowerUp)))){
setAnimationState(m_sGoToState);
bCrying = true;
goToState("IDLE", 2100);
} else {
if ((((((m_sGoToState == "IDLE")) && (bGameOver))) && (!(bPowerUp)))){
bCrying = false;
setAnimationState(m_sGoToState);
};
};
};
};
};
};
}
public function goToState(_arg1:String, _arg2:int):void{
if ((((m_sGoToState == "MAGIC")) || ((getState() == "WIGGLEHOT")))){
return;
};
m_sGoToState = _arg1;
setTimerOn(_arg2);
}
public function onShuffle(_arg1:QBShuffleEvent){
var _local2:Boolean;
var _local3:*;
if ((((((((bKill == true)) || (!(m_oQBGameHandler)))) || (m_oQBGameHandler.getGameOver()))) || (m_oQBGameHandler.getPaused()))){
return;
};
_local2 = _arg1.started();
if ((((_local2 == true)) && ((m_oQBGameHandler.POSITIONS.length > 0)))){
_local3 = m_oQBGameHandler.POSITIONS.pop();
qbType = _local3.type;
bPowerUp = _local3.isPower;
sColor = m_oQBGameHandler.getColor(qbType);
if (qbType == 16){
bPowerUp = true;
setImage(m_oQBGameHandler.IMAGEDATA[qbType]);
setAnimationState("BRUSHIDLE");
} else {
if (qbType == 40){
bPowerUp = true;
setImage(m_oQBGameHandler.IMAGEDATA[qbType]);
setAnimationState("IDLE");
} else {
if ((((qbType >= 17)) && ((qbType <= 31)))){
bPowerUp = true;
setImage(m_oQBGameHandler.IMAGEDATA[17]);
setAnimationState(m_oQBGameHandler.getType(qbType));
} else {
if ((((qbType >= 41)) && ((qbType <= 55)))){
bPowerUp = true;
setImage(m_oQBGameHandler.IMAGEDATA[41]);
setAnimationState(m_oQBGameHandler.getType(qbType));
} else {
sColor = m_oQBGameHandler.getColor(qbType);
setImage(m_oQBGameHandler.IMAGEDATA[qbType]);
if (bSliding){
setState("SLIDE");
} else {
if (bDropping){
setState("DROP");
} else {
setState("IDLE");
};
};
};
};
};
};
updateAnimation(1);
} else {
if (_local2 == false){
m_oQBGameHandler.POSITIONS.push({type:qbType, curstate:m_sState, isPower:bPowerUp});
m_oQBGameHandler.m_iNumberUpdated++;
m_oQBGameHandler.finishShuffle();
};
};
}
override public function onDestroy():void{
if (bKill == false){
setTimerOff();
if (!bBlownUp){
m_oQBGameHandler.m_TypeList[qbType] = (m_oQBGameHandler.m_TypeList[qbType] - 1);
m_oQBGameHandler.setQBee(xPos, yPos);
m_oQBGameHandler.m_LiveQB--;
};
bKill = true;
removeListeners();
super.onDestroy();
};
}
public function resetForces():void{
nDropLocV = 0;
yVel = 0;
yAcc = 0;
bDropping = false;
}
public function onFlip(_arg1:QBFlipEvent){
var _local2:Number;
var _local3:Number;
var _local4:int;
if ((((((bKill == true)) || (m_oQBGameHandler.getGameOver()))) || (m_oQBGameHandler.getPaused()))){
return;
};
_local2 = 0;
_local3 = 0;
_local4 = ((m_oQBGameHandler.getBoardSize() - yPos) - 2);
m_oQBGameHandler.TEMPGRID[String(((xPos + "_") + _local4))] = this;
setGridPos(xPos, _local4);
_local2 = skxUtil.getDistance(x, y, (m_oQBGameHandler.getStartLocX() + (xPos * m_oQBGameHandler.getQBScale())), (m_oQBGameHandler.getStartLocY() + (yPos * m_oQBGameHandler.getQBScale())));
_local3 = (_local2 / (0.25 + (m_oQBGameHandler.getBoardSize() / 100)));
resetForces();
moveTo((m_oQBGameHandler.m_nStartLocX + (xPos * m_oQBGameHandler.getQBScale())), (m_oQBGameHandler.m_nStartLocY + (yPos * m_oQBGameHandler.getQBScale())), _local3, true);
m_oQBGameHandler.m_iNumberUpdated++;
m_oQBGameHandler.updateGrid();
}
public function dropBlock(_arg1:int, _arg2:int):void{
var _local3:Number;
if ((((bKill == true)) || (bDrown))){
return;
};
bDropping = true;
if (!bPowerUp){
setAnimationState("JUMP");
};
_local3 = (yPos + _arg1);
nDropLocV = (m_oQBGameHandler.getStartLocY() + (m_oQBGameHandler.getQBScale() * _local3));
nForceY = m_oQBGameHandler.getGravity();
yAcc = 0;
yVel = ((-(nForceY) * _arg2) * m_oQBGameHandler.getFallScale());
}
public function setGameHandler(_arg1:QBGameHandler):void{
m_oQBGameHandler = _arg1;
}
public function destroyStones(_arg1:int, _arg2:int):void{
var _local3:QBeez;
_local3 = m_oQBGameHandler.getQBee(_arg1, _arg2);
if (((_local3) && ((_local3.qbType == 40)))){
_local3.setAnimationState("STONEBLOWNUP");
_local3.bBlownUp = true;
m_oQBGameHandler.setQBee(_local3.xPos, _local3.yPos);
m_oQBGameHandler.m_LiveQB--;
m_oQBGameHandler.m_TypeList[_local3.qbType] = (m_oQBGameHandler.m_TypeList[_local3.qbType] - 1);
m_oQBGameHandler.m_iBlownUpPieces++;
_local3.rotation = skxRandom.getRandomFlt(0, 360);
_local3.yAcc = (skxRandom.getRandomFlt(5, 10) * -1);
_local3.xAcc = 0;
_local3.yVel = (skxRandom.getRandomFlt(1000, 2000) * -1);
_local3.xVel = skxRandom.getRandomFlt(-300, 300);
setDepth((m_oQBGameHandler.getQBCount() + 100));
};
}
public function onPowerMove(_arg1:Array, _arg2:int, _arg3:QBeez):void{
var _local4:int;
var _local5:int;
var _local6:Number;
var _local7:Number;
var _local8:QBeez;
var _local9:int;
var _local10:int;
var _local11:Number;
var _local12:int;
var _local13:int;
var _local14:String;
_local4 = 0;
if (_arg2 == 16){
m_oQBGameHandler.m_iRunningBrushes = _arg1.length;
_local5 = 0;
m_oQBGameHandler.playSound("PAINT", 0, 1, true);
getWindow().removeObject(_arg3.m_oEffect);
_local4 = 0;
while (_local4 < m_oQBGameHandler.m_iRunningBrushes) {
_arg1[_local4].bSelected = false;
_arg1[_local4].setState("BRUSHPAINT");
getWindow().removeObject(_arg1[_local4].m_oEffect);
m_oQBGameHandler.setIsPainting(true);
_arg1[_local4].setDepth(((m_oQBGameHandler.getQBCount() + 20) + _local4));
_arg1[_local4].bPainting = true;
_local6 = skxUtil.getDistance(_arg1[_local4].x, _arg1[_local4].y, _arg1[_local4].x, (_arg1[_local4].y - 600));
_local7 = (_local6 / 1);
_arg1[_local4].moveTo(_arg1[_local4].x, -50, _local7, true);
_local8 = m_oQBGameHandler.getQBee(_arg1[_local4].xPos, (_arg1[_local4].yPos - 1));
m_oQBGameHandler.setQBee(_arg1[_local4].xPos, _arg1[_local4].yPos);
if (((_local8) && (!((_local8.qbType == 16))))){
_local9 = _local8.qbType;
_local10 = _local8.yPos;
_local11 = 0;
while (_local8 != null) {
_local8 = m_oQBGameHandler.getQBee(_arg1[_local4].xPos, _local10);
if (_local8){
_local5++;
_local6 = skxUtil.getDistance(_arg1[_local4].x, _arg1[_local4].y, _local8.x, _local8.y);
_local11 = (_local6 / _local7);
m_oQBGameHandler.m_TypeList[_local8.qbType] = (m_oQBGameHandler.m_TypeList[_local8.qbType] - 1);
if ((((((_local8.qbType >= 17)) && ((_local8.qbType <= 31)))) && ((_local9 <= 15)))){
_local8.qbType = m_oQBGameHandler.getBombType(_local9);
} else {
_local8.qbType = _local9;
};
_local8.bPainted = true;
m_oQBGameHandler.m_TypeList[_local9] = (m_oQBGameHandler.m_TypeList[_local9] + 1);
_local8.goToState("FLIPFAST", (_local11 * 1000));
};
_local10--;
};
};
_local4++;
};
m_oQBGameHandler.dispatchGameEvent({EVENT:"PAINTGROUP", COUNT:_local5});
m_oQBGameHandler.sortGrid();
m_oQBGameHandler.setIsShifting(true);
} else {
if ((((_arg1[0].qbType >= 41)) && ((_arg1[0].qbType <= 55)))){
if (_arg1.length > 1){
_local12 = _arg1.length;
_local13 = _arg1[0].qbType;
_local10 = 0;
while (_local10 < _arg1.length) {
_arg1[_local10].onDestroy();
_local10++;
};
m_oQBGameHandler.startMagicSequence(_local12, _local13);
};
} else {
if ((((_arg1[0].qbType >= 17)) && ((_arg1[0].qbType <= 31)))){
if (_arg1.length > 1){
m_oQBGameHandler.m_iBlownAway = 0;
m_oQBGameHandler.m_iBlownUpPieces = 0;
m_oQBGameHandler.setIsShifting(true);
m_oQBGameHandler.playSound("BOMB", 0, 1, true);
_local12 = 0;
switch (m_oQBGameHandler.getType(_arg1[0].qbType)){
case "6BOMB":
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[6] + m_oQBGameHandler.m_TypeList[22]);
break;
case "1BOMB":
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[1] + m_oQBGameHandler.m_TypeList[17]);
break;
case "2BOMB":
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[2] + m_oQBGameHandler.m_TypeList[18]);
break;
case "3BOMB":
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[3] + m_oQBGameHandler.m_TypeList[19]);
break;
case "4BOMB":
_local12 = m_oQBGameHandler.m_TypeList[4];
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[4] + m_oQBGameHandler.m_TypeList[20]);
break;
case "5BOMB":
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[5] + m_oQBGameHandler.m_TypeList[21]);
break;
case "7BOMB":
_local12 = m_oQBGameHandler.m_TypeList[7];
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[7] + m_oQBGameHandler.m_TypeList[23]);
break;
case "8BOMB":
_local12 = m_oQBGameHandler.m_TypeList[8];
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[8] + m_oQBGameHandler.m_TypeList[24]);
break;
case "9BOMB":
_local12 = m_oQBGameHandler.m_TypeList[9];
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[9] + m_oQBGameHandler.m_TypeList[25]);
break;
case "10BOMB":
_local12 = m_oQBGameHandler.m_TypeList[10];
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[10] + m_oQBGameHandler.m_TypeList[26]);
break;
case "11BOMB":
_local12 = m_oQBGameHandler.m_TypeList[11];
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[11] + m_oQBGameHandler.m_TypeList[27]);
break;
case "12BOMB":
_local12 = m_oQBGameHandler.m_TypeList[12];
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[12] + m_oQBGameHandler.m_TypeList[28]);
break;
case "13BOMB":
_local12 = m_oQBGameHandler.m_TypeList[13];
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[13] + m_oQBGameHandler.m_TypeList[29]);
break;
case "14BOMB":
_local12 = m_oQBGameHandler.m_TypeList[14];
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[14] + m_oQBGameHandler.m_TypeList[30]);
break;
case "15BOMB":
_local12 = m_oQBGameHandler.m_TypeList[15];
m_oQBGameHandler.m_iBlownAway = (m_oQBGameHandler.m_TypeList[15] + m_oQBGameHandler.m_TypeList[31]);
break;
};
getWindow().sendState(String(("ALL-" + m_oQBGameHandler.getType(_arg1[0].qbType))));
} else {
_local14 = m_oQBGameHandler.addScore(-100);
m_oQBGameHandler.createScoreText(_local14, x, y, -100);
m_oQBGameHandler.pauseGame();
m_oQBGameHandler.dispatchGameEvent({EVENT:"BOMBTIP"});
};
} else {
if (_arg1[0].qbType == 40){
_local14 = m_oQBGameHandler.addScore(-100);
m_oQBGameHandler.createScoreText(_local14, x, y, -100);
m_oQBGameHandler.pauseGame();
m_oQBGameHandler.dispatchGameEvent({EVENT:"STONETIP"});
};
};
};
};
}
public function slideBlock(_arg1:int):void{
if ((((bKill == true)) || (bDrown))){
return;
};
resetSliding();
bSliding = true;
if (((!((bDropping == true))) && (!(bPowerUp)))){
setAnimationState("SLIDE");
};
nSlideLocX = (m_oQBGameHandler.getStartLocX() + ((xPos + _arg1) * m_oQBGameHandler.getQBScale()));
xAcc = 0;
}
public function onGetOut():void{
bBlownUp = true;
yAcc = (skxRandom.getRandomFlt(5, 10) * -1);
yVel = (skxRandom.getRandomFlt(1000, 2000) * -1);
xVel = -50;
}
public function Init(){
var _local1:Dictionary;
var _local2:Number;
var _local3:Number;
var _local4:int;
var _local5:int;
var _local6:Dictionary;
var _local7:String;
var _local8:String;
m_oEffect.setMount(this);
m_oEffect.setImage(m_oQBGameHandler.IMAGEDATA[38]);
m_oEffect.setFrame(1);
_local1 = new Dictionary();
_local1["IDLE"] = new skxAnimation("IDLE");
_local1["BLINK"] = new skxAnimation("BLINK");
_local1["ROLLOVER"] = new skxAnimation("ROLLOVER", true);
_local1["JUMP"] = new skxAnimation("JUMP", true);
_local1["FLIP"] = new skxAnimation("FLIP", true);
_local1["FLIPFAST"] = new skxAnimation("FLIPFAST", true);
_local1["DROP"] = new skxAnimation("DROP", true);
_local1["STOMP"] = new skxAnimation("STOMP", true);
_local1["HOT"] = new skxAnimation("HOT", true);
_local1["SQUISH"] = new skxAnimation("SQUISH", true);
_local1["EMOTE"] = new skxAnimation("EMOTE", true);
_local1["EMOTE2"] = new skxAnimation("EMOTE2", true);
_local1["SMILE"] = new skxAnimation("SMILE", true);
_local1["FROWN"] = new skxAnimation("FROWN", true);
_local1["HOPAWAY"] = new skxAnimation("HOPAWAY", true);
_local1["INHALE"] = new skxAnimation("INHALE", true);
_local1["HOLDBREATH"] = new skxAnimation("HOLDBREATH", true);
_local1["SLIDE"] = new skxAnimation("SLIDE", true);
_local1["QBLINK"] = new skxAnimation("QBLINK", true);
_local1["QHBLINK"] = new skxAnimation("QHBLINK", true);
_local1["SCARED"] = new skxAnimation("SCARED", true);
_local1["SCAREDINHALE"] = new skxAnimation("SCAREDINHALE", true);
_local1["SCAREDLOOK"] = new skxAnimation("SCAREDLOOK", true);
_local1["HOLDBLINK"] = new skxAnimation("HOLDBLINK", true);
_local1["WIGGLEHOT"] = new skxAnimation("WIGGLEHOT", true);
_local1["IDLE"].addFrame(1, 0.1);
_local1["BLINK"].addFrame(3, 0.3);
_local1["ROLLOVER"].addFrame(10, 0.25);
_local1["JUMP"].addFrame(15, 0.05);
_local1["FLIP"].addFrame(14, 0.15);
_local1["FLIP"].addFrame(15, 0.15);
_local1["FLIP"].addFrame(16, 0.15);
_local1["FLIP"].addFrame(17, 0.15);
_local1["FLIP"].addFrame(18, 0.2);
_local1["FLIPFAST"].addFrame(14, 0.1);
_local1["FLIPFAST"].addFrame(15, 0.1);
_local1["FLIPFAST"].addFrame(16, 0.1);
_local1["FLIPFAST"].addFrame(17, 0.1);
_local1["FLIPFAST"].addFrame(18, 0.1);
m_animSeq["BLOWNUP"] = new skxAnimation("BLOWNUP", true);
m_animSeq["BLOWNUP"].addFrame(14, 0.1);
m_animSeq["BLOWNUP"].addFrame(15, 0.1);
m_animSeq["BLOWNUP"].addFrame(16, 0.1);
m_animSeq["BLOWNUP"].addFrame(17, 0.1);
m_animSeq["BLOWNUP"].addFrame(18, 0.1);
m_animSeq["STONEBLOWNUP"] = new skxAnimation("STONEBLOWNUP");
m_animSeq["STONEBLOWNUP"].addFrame(2, 0.05);
m_animSeq["STONEBLOWNUP"].addFrame(3, 0.05);
m_animSeq["STONEBLOWNUP"].addFrame(4, 0.05);
m_animSeq["STONEBLOWNUP"].addFrame(5, 0.05);
m_animSeq["STONEBLOWNUP"].addFrame(6, 0.05);
m_animSeq["STONEBLOWNUP"].addFrame(7, 0.05);
m_animSeq["STONEBLOWNUP"].addFrame(8, 0.05);
m_animSeq["STONEBLOWNUP"].addFrame(9, 0.05);
m_animSeq["STONEBLOWNUP"].addFrame(10, 0.05);
m_animSeq["STONEBLOWNUP"].addFrame(11, 0.05);
m_animSeq["STONEBLOWNUP"].addFrame(12, 0.05);
_local1["DROP"].addFrame(12, 0.1);
_local1["DROP"].addFrame(13, 0.1);
_local1["STOMP"].addFrame(4, 0.05);
_local1["HOT"].addFrame(2, 0.05);
_local1["WIGGLEHOT"].addFrame(21, 0.1);
_local1["WIGGLEHOT"].addFrame(22, 0.1);
_local1["WIGGLEHOT"].addFrame(23, 0.1);
_local1["WIGGLEHOT"].addFrame(22, 0.1);
_local1["SQUISH"].addFrame(4, 0.25);
_local1["EMOTE"].addFrame(5, 0.15);
_local1["EMOTE"].addFrame(6, 0.1);
_local1["EMOTE"].addFrame(7, 0.15);
_local1["EMOTE"].addFrame(8, 0.1);
_local1["EMOTE2"].addFrame(10, 0.05);
_local1["SMILE"].addFrame(10, 0.05);
_local1["HOPAWAY"].addFrame(11, 0.05);
_local1["INHALE"].addFrame(19, 0.3);
_local1["HOLDBREATH"].addFrame(20, 0.05);
_local1["HOLDBLINK"].addFrame(9, 0.25);
_local1["SLIDE"].addFrame(11, 0.05);
_local1["QBLINK"].addFrame(1, 0.1);
_local1["QBLINK"].addFrame(3, 0.05);
_local1["QHBLINK"].addFrame(20, 0.1);
_local1["QHBLINK"].addFrame(9, 0.05);
_local1["SCARED"].addFrame(9, 0.25);
_local1["SCAREDINHALE"].addFrame(19, 0.3);
_local1["SCAREDLOOK"].addFrame(25, 0.2);
m_animSeq[_local1["IDLE"].Name] = _local1["IDLE"];
m_animSeq[_local1["HOT"].Name] = _local1["HOT"];
m_animSeq[_local1["SQUISH"].Name] = _local1["SQUISH"];
m_animSeq[_local1["BLINK"].Name] = _local1["BLINK"];
m_animSeq[_local1["QBLINK"].Name] = _local1["QBLINK"];
m_animSeq[_local1["QHBLINK"].Name] = _local1["QHBLINK"];
m_animSeq[_local1["FLIP"].Name] = _local1["FLIP"];
m_animSeq[_local1["FLIPFAST"].Name] = _local1["FLIPFAST"];
m_animSeq[_local1["DROP"].Name] = _local1["DROP"];
m_animSeq[_local1["HOPAWAY"].Name] = _local1["HOPAWAY"];
m_animSeq[_local1["WIGGLEHOT"].Name] = _local1["WIGGLEHOT"];
m_animSeq[_local1["EMOTE"].Name] = _local1["EMOTE"];
m_animSeq[_local1["EMOTE2"].Name] = _local1["EMOTE2"];
m_animSeq[_local1["SMILE"].Name] = _local1["SMILE"];
m_animSeq[_local1["INHALE"].Name] = _local1["INHALE"];
m_animSeq[_local1["HOLDBREATH"].Name] = _local1["HOLDBREATH"];
m_animSeq[_local1["HOLDBLINK"].Name] = _local1["HOLDBLINK"];
m_animSeq[_local1["SLIDE"].Name] = _local1["SLIDE"];
m_animSeq[_local1["STOMP"].Name] = _local1["STOMP"];
m_animSeq[_local1["JUMP"].Name] = _local1["JUMP"];
m_animSeq[_local1["ROLLOVER"].Name] = _local1["ROLLOVER"];
m_animSeq["SCARED"] = _local1["SCARED"];
m_animSeq["SCAREDINHALE"] = _local1["SCAREDINHALE"];
m_animSeq["SCAREDLOOK"] = _local1["SCAREDLOOK"];
m_animSeq["BRUSHIDLE"] = new skxAnimation("BRUSHIDLE", true);
m_animSeq["BRUSHPAINT"] = new skxAnimation("BRUSHPAINT", true);
m_animSeq["BRUSHIDLE"].addFrame(1, 0.2);
m_animSeq["BRUSHIDLE"].addFrame(2, 0.2);
m_animSeq["BRUSHIDLE"].addFrame(3, 0.2);
m_animSeq["BRUSHIDLE"].addFrame(2, 0.2);
m_animSeq["BRUSHPAINT"].addFrame(4, 5);
_local2 = 0.15;
_local3 = 0.2;
_local4 = 1;
_local5 = 1;
while (_local4 < 16) {
_local7 = String((_local4 + "BOMB"));
_local8 = String(((_local4 + 1) + "BOMB"));
m_animSeq[_local7] = new skxAnimation(_local7, true);
m_animSeq[_local7].addFrame(_local5, _local3);
m_animSeq[_local7].addFrame((_local5 + 1), _local2);
m_animSeq[_local7].addFrame((_local5 + 2), _local3);
m_animSeq[_local7].addFrame((_local5 + 1), _local2);
m_animSeq[_local8] = new skxAnimation(_local8, true);
m_animSeq[_local8].addFrame((_local5 + 3), _local3);
m_animSeq[_local8].addFrame((_local5 + 4), _local2);
m_animSeq[_local8].addFrame((_local5 + 5), _local3);
m_animSeq[_local8].addFrame((_local5 + 4), _local2);
_local5 = (_local5 + 6);
_local4 = (_local4 + 2);
};
_local4 = 1;
_local5 = 1;
while (_local4 < 16) {
_local7 = String((_local4 + "MAGIC"));
_local8 = String(((_local4 + 1) + "MAGIC"));
m_animSeq[_local7] = new skxAnimation(_local7, true);
m_animSeq[_local7].addFrame(_local5, _local3);
m_animSeq[_local7].addFrame((_local5 + 1), _local2);
m_animSeq[_local7].addFrame((_local5 + 2), _local3);
m_animSeq[_local7].addFrame((_local5 + 1), _local2);
m_animSeq[_local8] = new skxAnimation(_local8, true);
m_animSeq[_local8].addFrame((_local5 + 3), _local3);
m_animSeq[_local8].addFrame((_local5 + 4), _local2);
m_animSeq[_local8].addFrame((_local5 + 5), _local3);
m_animSeq[_local8].addFrame((_local5 + 4), _local2);
_local5 = (_local5 + 6);
_local4 = (_local4 + 2);
};
_local6 = new Dictionary();
_local6["IDLE"] = new skxAnimation("IDLE");
_local6["IDLE"].addFrame(1, 0.1);
_local6["IDLE"].addFrame(2, 0.1);
_local6["IDLE"].addFrame(3, 0.1);
_local6["IDLE"].addFrame(4, 0.1);
_local6["IDLE"].addFrame(5, 0.1);
_local6["IDLE"].addFrame(6, 0.1);
_local6["IDLE"].addFrame(7, 0.1);
_local6["IDLE"].addFrame(8, 0.1);
_local6["IDLE"].addFrame(9, 0.1);
_local6["IDLE"].addFrame(10, 0.1);
_local6["IDLE"].addFrame(11, 0.1);
_local6["IDLE"].addFrame(12, 0.1);
m_oEffect.setAnimStates(_local6);
m_oEffect.visible = false;
m_oEffect.setActive(true);
m_oEffect.setState("IDLE");
if (qbType == 16){
m_oEffect.visible = true;
setAnimationState("BRUSHIDLE");
} else {
if ((((qbType >= 17)) && ((qbType <= 31)))){
setAnimationState(String(((qbType - 16) + "BOMB")));
} else {
if ((((qbType >= 41)) && ((qbType <= 55)))){
setAnimationState(String(((qbType - 40) + "MAGIC")));
} else {
if (qbType == 40){
setAnimationState("IDLE");
} else {
setAnimationState("IDLE");
};
};
};
};
setActive(true);
setMouseEnabled(true);
}
override public function onMouseOff():void{
if ((((((((((bKill == true)) || (m_oQBGameHandler.getGameOver()))) || (bGameOver))) || (m_oQBGameHandler.getPaused()))) || (bBlownUp))){
return;
};
bMouseOver = false;
if ((((bFlipping == false)) && (!(bPowerUp)))){
bFlipped = false;
};
if (((m_oQBGameHandler.getIsSelected()) && ((bSelected == true)))){
m_oQBGameHandler.setIsOverSelected(false);
};
}
override public function onUpdate(_arg1:Number=0):void{
if (m_oQBGameHandler.getPaused()){
return;
};
onPositionChange();
if (m_oEffect.visible){
m_oEffect.onUpdate(_arg1);
};
if (((((((bPowerUp) && ((qbType >= 17)))) && ((qbType <= 31)))) && (!(m_oQBGameHandler.getIsPainting())))){
if (getState() != m_oQBGameHandler.getType(qbType)){
setAnimationState(m_oQBGameHandler.getType(qbType));
};
};
if (((((((bPowerUp) && ((qbType >= 41)))) && ((qbType <= 55)))) && (!(m_oQBGameHandler.getIsPainting())))){
if (getState() != m_oQBGameHandler.getType(qbType)){
setAnimationState(m_oQBGameHandler.getType(qbType));
};
};
super.onUpdate(_arg1);
if (((((!((bSelected == true))) && ((getState() == "HOT")))) || ((((((getState() == "WIGGLEHOT")) && (!(bPowerUp)))) && (!(m_oQBGameHandler.m_bMagicMode)))))){
setState("IDLE");
};
if (bBlownUp == true){
yAcc = (yAcc + (m_oQBGameHandler.getGravity() * _arg1));
yVel = yAcc;
x = (x + (xVel * _arg1));
y = (y + yVel);
if (((!((getState() == "BLOWNUP"))) && (!(bPowerUp)))){
setState("BLOWNUP");
};
alpha = Math.max(0, (alpha - (4 * _arg1)));
if (alpha <= 0.05){
visible = false;
Delete();
};
return;
};
if (((((((((((((!(bDrown)) && (!(bDropping)))) && (!(bFlipping)))) && (!(bSliding)))) && (m_oQBGameHandler.getTimerPassed()))) && (!(bPowerUp)))) && (!((QBGameHandler.sGameMode == 3))))){
if (((((((!((getState() == "HOLDBLINK"))) && (!((getState() == "INHALE"))))) && (!((getState() == "HOLDBREATH"))))) && (!((getState() == "QHBLINK"))))){
setAnimationState("INHALE");
};
return;
};
if ((((((qbType == 16)) && ((bPainting == true)))) && (bPowerUp))){
setState("BRUSHPAINT");
return;
};
if (((bPainted) && (m_oQBGameHandler.getIsPainting()))){
return;
};
if (((bPainted) && (!(m_oQBGameHandler.getIsPainting())))){
bPainted = false;
};
if (((bDrown) && (!((QBGameHandler.sGameMode == 3))))){
xVel = (xVel + (xAcc * _arg1));
x = (x + xVel);
yAcc = (yAcc + (_arg1 * (skxRandom.getRandomFlt(0.5, 2) * -2)));
yVel = yAcc;
y = (y + yVel);
if (((((((((!(bPowerUp)) && (!((getState() == "HOLDBLINK"))))) && (!((getState() == "INHALE"))))) && (!((getState() == "HOLDBREATH"))))) && (!((getState() == "QHBLINK"))))){
setAnimationState("HOLDBLINK");
};
return;
};
if (bSliding){
xAcc = (xAcc + ((m_oQBGameHandler.getGravity() / 6) * _arg1));
if (((x + xVel) + xAcc) < nSlideLocX){
xVel = (xVel + xAcc);
x = (x + xVel);
if (!bPowerUp){
if (bSelected){
setAnimationState("HOT");
} else {
setAnimationState("IDLE");
};
if (bDropping != true){
setAnimationState("SLIDE");
};
};
} else {
if (!bCrying){
m_oQBGameHandler.playSound(String(("SLIDE" + sColor)));
};
x = nSlideLocX;
resetSliding();
m_oQBGameHandler.m_iSlidingCount--;
if (!bPowerUp){
if (bSelected){
setAnimationState("HOT");
} else {
if (bCrying){
setAnimationState("EMOTE");
} else {
if (bDrown){
setAnimationState("INHALE");
} else {
setAnimationState("IDLE");
};
};
};
};
if (m_oQBGameHandler.m_iSlidingCount <= 0){
m_oQBGameHandler.sortGrid(true);
};
};
};
if (((bDropping) || (bFlipping))){
if (!m_bRising){
yAcc = (yAcc + (m_oQBGameHandler.getGravity() * _arg1));
if (((y + yVel) + yAcc) < nDropLocV){
yVel = (yVel + yAcc);
y = (y + yVel);
if (!bPowerUp){
if ((((yVel > 0)) && (bDropping))){
setAnimationState("DROP");
};
if ((((yVel > 0)) && (bFlipping))){
setAnimationState("FLIP");
};
};
} else {
m_oQBGameHandler.playSound("FOOTSTEP");
y = nDropLocV;
resetForces();
bFlipping = false;
if (!bPowerUp){
if (bCrying){
setAnimationState("EMOTE");
} else {
if (((bDrown) && (!((QBGameHandler.sGameMode == 3))))){
setAnimationState("INHALE");
} else {
if (bSelected){
setAnimationState("HOT");
} else {
setAnimationState("IDLE");
};
if (m_bHopping){
m_bHopping = false;
setAnimationState("BLINK");
} else {
if (isOnTop()){
setAnimationState("SQUISH");
} else {
setAnimationState("BLINK");
};
};
};
};
};
};
} else {
yVel = (yVel + (yAcc * _arg1));
y = (y + yVel);
if (y < nDropLocV){
m_bRising = false;
};
};
};
if (!bPowerUp){
if (((bSelected) && (!(bDropping)))){
setAnimationState("HOT");
} else {
if (bSelected){
setAnimationState("WIGGLEHOT");
};
};
};
}
public function copyQbee(_arg1:QBeez):void{
qbType = _arg1.qbType;
sColor = _arg1.sColor;
setImage(m_oQBGameHandler.IMAGEDATA[qbType]);
}
override public function onStart(_arg1:Event=null):void{
super.onStart(_arg1);
}
public function hopBlock(_arg1:int):void{
var _local2:Number;
if ((((bKill == true)) || (bDrown))){
return;
};
m_bRising = true;
bDropping = true;
m_bHopping = true;
_local2 = yPos;
nDropLocV = (m_oQBGameHandler.getStartLocY() + (m_oQBGameHandler.getQBScale() * _local2));
nForceY = m_oQBGameHandler.getGravity();
yAcc = 0;
yVel = ((-(nForceY) * _arg1) * m_oQBGameHandler.getFallScale());
}
public function Delete():void{
onDestroy();
}
public function resetSliding():void{
nSlideLocX = 0;
xVel = 0;
xAcc = 0;
bSliding = false;
}
override protected function onState(_arg1:skxStateEvent=null):void{
var _local2:Array;
var _local3:String;
var _local4:String;
var _local5:Number;
_local2 = _arg1.state().split("-");
if (_local2.length < 2){
skxDisplay.Error("Invalid state string sent.");
return;
};
_local3 = _local2[0];
_local4 = _local2[1];
if ((((_local3 == "ALL")) || ((_local3 == name)))){
switch (_local4){
case "DROP":
dropBlock(0, (m_oQBGameHandler.getBoardSize() - yPos));
break;
case "EMOTE":
if (bGameOver == false){
setTimerOff();
removeListeners();
bGameOver = true;
if (!bPowerUp){
goToState("EMOTE", 50);
};
};
break;
case "INHALE":
if (bGameOver == false){
setTimerOff();
removeListeners();
if (!bPowerUp){
if (m_CurAnimation.Name == "SCARED"){
setAnimationState("HOLDBLINK");
} else {
if (m_CurAnimation.Name == "SCAREDLOOK"){
setAnimationState("HOLDBREATH");
} else {
setAnimationState(_local4);
};
};
};
bGameOver = true;
};
break;
case "DROWN":
if (bDrown == false){
bDrown = true;
if (((((((((!(bPowerUp)) && (!((m_CurAnimation.Name == "HOLDBLINK"))))) && (!((m_CurAnimation.Name == "INHALE"))))) && (!((m_CurAnimation.Name == "HOLDBREATH"))))) && (!((m_CurAnimation.Name == "QHBLINK"))))){
setAnimationState("HOLDBLINK");
};
_local5 = ((m_oQBGameHandler.getBoardSize() - yPos) / m_oQBGameHandler.getBoardSize());
xAcc = (((skxRandom.getRandomFlt(-1, 1) * m_oQBGameHandler.getQBScale()) / 100) * _local5);
yAcc = (((skxRandom.getRandomFlt(-1.5, -0.0001) * _local5) * m_oQBGameHandler.getQBScale()) / 100);
setAutoRotation(skxRandom.getRandomInt(-15, 15));
};
break;
case "PAUSE":
visible = false;
break;
case "UNPAUSE":
visible = true;
break;
case "BLOWUP":
onBlowUp();
break;
case "6BOMB":
if ((((qbType == 6)) || ((qbType == 22)))){
onBlowUp();
};
break;
case "1BOMB":
if ((((qbType == 1)) || ((qbType == 17)))){
onBlowUp();
};
break;
case "2BOMB":
if ((((qbType == 2)) || ((qbType == 18)))){
onBlowUp();
};
break;
case "3BOMB":
if ((((qbType == 3)) || ((qbType == 19)))){
onBlowUp();
};
break;
case "4BOMB":
if ((((qbType == 4)) || ((qbType == 20)))){
onBlowUp();
};
break;
case "5BOMB":
if ((((qbType == 5)) || ((qbType == 21)))){
onBlowUp();
};
break;
case "7BOMB":
if ((((qbType == 7)) || ((qbType == 23)))){
onBlowUp();
};
break;
case "8BOMB":
if ((((qbType == 8)) || ((qbType == 24)))){
onBlowUp();
};
break;
case "9BOMB":
if ((((qbType == 9)) || ((qbType == 25)))){
onBlowUp();
};
break;
case "10BOMB":
if ((((qbType == 10)) || ((qbType == 26)))){
onBlowUp();
};
break;
case "11BOMB":
if ((((qbType == 11)) || ((qbType == 27)))){
onBlowUp();
};
break;
case "12BOMB":
if ((((qbType == 12)) || ((qbType == 28)))){
onBlowUp();
};
break;
case "13BOMB":
if ((((qbType == 13)) || ((qbType == 29)))){
onBlowUp();
};
break;
case "14BOMB":
if ((((qbType == 14)) || ((qbType == 30)))){
onBlowUp();
};
break;
case "15BOMB":
if ((((qbType == 15)) || ((qbType == 31)))){
onBlowUp();
};
break;
case "GETOUT":
onGetOut();
break;
};
super.onState(_arg1);
};
}
}
}//package QBeezSrc
Section 119
//QBExplosion (QBeezSrc.QBExplosion)
package QBeezSrc {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
import skxSource.*;
public class QBExplosion extends skxSprite {
private var i:int;// = 0
public function QBExplosion(_arg1:Number, _arg2:Number, _arg3:skxImage):void{
i = 0;
super();
m_bUpdatable = true;
x = _arg1;
y = _arg2;
setImage(_arg3);
m_animSeq["IDLE"] = new skxAnimation("IDLE", true);
m_animSeq["IDLE"].addFrame(1, 0.05);
m_animSeq["IDLE"].addFrame(2, 0.05);
m_animSeq["IDLE"].addFrame(3, 0.05);
m_animSeq["IDLE"].addFrame(4, 0.05);
m_animSeq["IDLE"].addFrame(5, 0.05);
m_animSeq["IDLE"].addFrame(6, 0.05);
m_animSeq["IDLE"].addFrame(7, 0.05);
m_animSeq["IDLE"].addFrame(8, 0.05);
setActive(true);
setState("IDLE");
setTimerOn(50);
}
override public function onAnimationEnd(_arg1:String):void{
destroy();
}
override protected function onTimer(_arg1:Event=null):void{
i++;
if (i == 4){
} else {
if (i == 5){
} else {
if (i == 6){
alpha = 0.8;
} else {
if (i == 7){
alpha = 0.7;
};
};
};
};
if (i == 8){
alpha = 0.5;
};
if (i == 9){
};
if (i == 10){
};
if (i > 10){
alpha = 0.4;
setTimerOff();
destroy();
};
}
}
}//package QBeezSrc
Section 120
//QBFlipEvent (QBeezSrc.QBFlipEvent)
package QBeezSrc {
import flash.events.*;
public class QBFlipEvent extends Event {
private var _dir:int;// = 0
public static const FLIP:String = "Flip";
public function QBFlipEvent(_arg1:String, _arg2:Boolean=true, _arg3:Boolean=false):void{
_dir = 0;
super(_arg1, _arg2, _arg3);
}
override public function clone():Event{
return (new QBFlipEvent(type));
}
}
}//package QBeezSrc
Section 121
//QBGameEvent (QBeezSrc.QBGameEvent)
package QBeezSrc {
import flash.events.*;
public class QBGameEvent extends Event {
var _event:Object;
public static const GAME:String = "Game";
public function QBGameEvent(_arg1:String, _arg2:Object, _arg3:Boolean=true, _arg4:Boolean=false):void{
_event = _arg2;
super(_arg1, _arg3, _arg4);
}
public function getevent():Object{
return (_event);
}
override public function clone():Event{
return (new QBGameEvent(type, _event));
}
}
}//package QBeezSrc
Section 122
//QBGameHandler (QBeezSrc.QBGameHandler)
package QBeezSrc {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
import flash.geom.*;
import flash.media.*;
import skxSource.*;
import flash.filters.*;
import flash.net.*;
public class QBGameHandler {
public var m_pauseTimer:Timer;
private var m_iMusicSegment:int;// = 0
public var m_sLevelName:String;// = ""
private var m_iBoardHeight:int;// = 0
public var m_bMagicChanging:Boolean;// = false
private var m_iGameTime:int;// = 0
private var m_nShuffleCountPos:int;// = 0
public var m_iCurPerfect:int;// = 100000
public var m_iTotalScore:int;// = 0
private var m_iPauseBlur:int;// = 0
public var m_bTimeBonus:Boolean;// = false
public var m_LiveQB;// = 0
public var PLAYERSCORE:Dictionary;
private var m_bPerfectCount:Boolean;// = false
private var m_iPerfects:int;// = 0
public var m_iSlidingCount:int;// = 0
public var m_QBColorSet:Array;
private var m_stateTimer:Timer;// = null
public var m_oScoreText:TextField;// = null
public var POSITIONS:Array;
private var m_iCurMaxGroup:int;// = 0
public var m_iShuffleCount:int;// = 0
public var m_sLevelAuthor:String;// = ""
private var m_bInfPowerMoves:Boolean;// = false
private var m_bSelection:Boolean;// = false
private var m_bPaused:Boolean;// = false
public var LVLCOUNTPARAM:Dictionary;
private var m_shuffleTimer:Timer;
public var m_mcBGRef:MovieClip;// = null
private var m_iCurrentLvl:int;// = 0
private var m_bShuffling:Boolean;// = false
public var m_SnapShotData:Bitmap;// = null
public var bSortAfterSlide:Boolean;// = false
public var m_TypeCount:int;// = 0
private var m_iQBCount:int;// = 0
public var m_TextExample;
public var SELECTED:Array;
private var m_sLoadedLevel:String;// = ""
public var m_aTypes:Array;
public var m_mcSnapShot;// = null
private var m_sGoToState:String;// = ""
public var m_Stage;// = null
private var m_iBoardSize:int;// = 0
public var m_TypeList:Dictionary;
public var m_iBlownAway:int;// = 0
private var m_iCurrentSubLvl:int;// = 0
public var m_sDiff:String;// = ""
public var m_bLoadedGame:Boolean;// = false
public var QBEEZGRID:Dictionary;
private var m_nShuffleCount:int;// = 30
private var m_nFallScale:Number;// = 0
private var m_iCurPerfects:int;// = 0
public var m_iRotateCount:int;// = 0
public var m_nStartLocX:Number;// = 0
public var m_nStartLocY:Number;// = 0
private var m_bTimerPassed:Boolean;// = false
public var m_bRestart:Boolean;// = false
private var m_nImageScale:Number;// = 0
private var m_tForceCheckTimer:Timer;
public var m_timer:Timer;
public var TEMPPOSITIONS:Array;
private var m_iBoardWidth:int;// = 0
private var m_nPowerMoves:Number;// = 3
public var m_bGameStarted:Boolean;// = false
public var m_sMusicType:String;// = "A"
private var m_shuffleStopTimer:Timer;
public var m_iBlownUpPieces:int;// = 0
private var m_bDrown:Boolean;// = false
public var COLORPARAM:Dictionary;
public var LEVELDATA:Array;
public var SOUNDDATA:Dictionary;
public var TEMPGRID:Dictionary;
public var m_dAnimSeq:Dictionary;
private var m_nQBScale:Number;// = 0
public var m_iScreenWidth:int;// = 0
public var m_bGameOver:Boolean;// = false
public var m_iBGFrame:int;// = 1
private var m_iMagicType:int;// = 0
public var ITEMPARAM:Dictionary;
private var m_newGameTimer:Timer;
private var m_nShuffleDelay:int;// = 15
public var m_iFlipCount:int;// = 0
private var m_bShifting:Boolean;// = false
private var m_bStartUnPause:Boolean;// = false
public var m_iNumberUpdated;// = 0
public var m_bRestartStage:Boolean;// = false
public var IMAGEDATA:Dictionary;
public var BLUROUT:Array;
public var m_TextContainer:MovieClip;
private var m_bMoving:Boolean;// = false
public var m_bStopBar:Boolean;// = false
public var m_nScreenScale:Number;// = 0
private var m_nGravity:Number;// = 40
public var SOUNDNAMES:Array;
public var m_watertimer:Timer;
private var m_bFirstGame:Boolean;// = true
public var m_iBackground:int;// = 0
public var m_sMessage:String;// = ""
public var m_iRunningBrushes:int;// = 0
private var m_oMover:MovieClip;// = null
public var m_QBCount;// = 0
public var m_ColorSet:Array;
private var m_iMaxGroup:int;// = 0
private var m_iColCount:int;// = 0
private var m_iScore:int;// = 0
public var m_sqTimer:Timer;
public var TIMEPARAM:Dictionary;
public var m_bGameOverCountdown:Boolean;// = false
public var m_bLowerWater:Boolean;// = false
public var m_bMagicMode:Boolean;// = false
private var m_blurTimer:Timer;
private var m_pLastMagicPoint:Point;
private var m_bOverSelection:Boolean;// = false
private var m_bMouseOver:Boolean;// = false
private var m_iMoves:int;// = 0
private var m_bPainting:Boolean;// = false
public var USERDATA:Dictionary;
public var m_bLevelDone:Boolean;// = false
private var m_iMagicSize:int;// = 0
private var m_bForceSort:Boolean;// = false
public var m_sHS:String;// = ""
public static var sJustStagedUp:Boolean = false;
public static var m_mcHatsRef = null;
public static var sAppState:String = "";
public static var sFromHS:Boolean = false;
public static var sUserName:String = "";
public static var m_mcReference = null;
public static var m_iSelectedPack:int = 0;
public static var m_nBoardOffsetX:Number = 490;
public static var sUserColor:int = -1;
public static var sBombTip:Boolean = false;
public static var m_iCurrentPackLevel:int = 0;
public static var sBGScale:Number = 0.8;
public static var sLastTotalScore:Number = 0;
public static var sXMLFile:String = "";
public static var m_mcBrushRef = null;
public static var sNewGameDispatcher:EventDispatcher = new EventDispatcher();
public static var sGameMode:int = 0;
public static var m_mcBombRef = null;
public static var sGameStarted:Boolean = false;
public static var m_mcExplosion = null;
public static var sQuestStarted:Boolean = false;
public static var m_nGroundLine:Number = 455;
public static var sSoundOn:Boolean = true;
public static var m_aLevels:Array;
public static var sMainHandler:QBGameHandler = null;
public static var WINDOW:QBWindow = null;
public static var SIMAGEDATA:Array = new Array(55);
public static var sAppStarted:Boolean = false;
public static var sStagedUp:Boolean = false;
public static var sDailySeed:int = 0;
public static var m_nScaleFactor:Number = 1;
public static var sQuestFrame:int = 1;
public function QBGameHandler(_arg1):void{
m_iShuffleCount = 0;
m_iRotateCount = 0;
m_iFlipCount = 0;
SELECTED = new Array();
QBEEZGRID = new Dictionary(false);
TEMPGRID = new Dictionary(false);
POSITIONS = new Array();
TEMPPOSITIONS = new Array();
BLUROUT = new Array();
m_iNumberUpdated = 0;
m_LiveQB = 0;
m_QBCount = 0;
m_bRestart = false;
m_bRestartStage = false;
LEVELDATA = new Array();
IMAGEDATA = new Dictionary();
SOUNDDATA = new Dictionary(false);
SOUNDNAMES = new Array();
TIMEPARAM = new Dictionary();
ITEMPARAM = new Dictionary();
LVLCOUNTPARAM = new Dictionary();
COLORPARAM = new Dictionary();
PLAYERSCORE = new Dictionary();
USERDATA = new Dictionary();
m_sLevelName = "";
m_sLevelAuthor = "";
m_iBackground = 0;
m_sMessage = "";
m_sDiff = "";
m_sHS = "";
m_aTypes = new Array();
m_tForceCheckTimer = new Timer(2000);
m_bPaused = false;
bSortAfterSlide = false;
m_nFallScale = 0;
m_nGravity = 40;
m_iBoardWidth = 0;
m_iBoardHeight = 0;
m_iBoardSize = 0;
m_nQBScale = 0;
m_timer = new Timer(1000);
m_watertimer = new Timer(25);
m_shuffleStopTimer = new Timer(1000);
m_newGameTimer = new Timer(1000);
m_blurTimer = new Timer(25);
m_nShuffleDelay = 15;
m_nShuffleCount = 30;
m_nShuffleCountPos = 0;
m_iColCount = 0;
m_bGameStarted = false;
m_TypeCount = 0;
m_TypeList = new Dictionary();
m_nStartLocY = 0;
m_nStartLocX = 0;
m_bLoadedGame = false;
m_pauseTimer = new Timer(10);
m_sqTimer = new Timer(500);
m_stateTimer = null;
m_iCurrentLvl = 0;
m_iCurrentSubLvl = 0;
m_sGoToState = "";
m_iScore = 0;
m_iTotalScore = 0;
m_iMaxGroup = 0;
m_iPerfects = 0;
m_iMoves = 0;
m_iCurMaxGroup = 0;
m_iCurPerfects = 0;
m_bInfPowerMoves = false;
m_nPowerMoves = 3;
m_bShifting = false;
m_bMoving = false;
m_bSelection = false;
m_bOverSelection = false;
m_bGameOver = false;
m_bTimerPassed = false;
m_bMouseOver = false;
m_nImageScale = 0;
m_bPainting = false;
m_bShuffling = false;
m_bLevelDone = false;
m_iMusicSegment = 0;
m_iPauseBlur = 0;
m_bStartUnPause = false;
m_bLowerWater = false;
m_bStopBar = false;
m_iGameTime = 0;
m_bPerfectCount = false;
m_iCurPerfect = 100000;
m_bTimeBonus = false;
m_bGameOverCountdown = false;
m_iRunningBrushes = 0;
m_iQBCount = 0;
m_bDrown = false;
m_bForceSort = false;
m_dAnimSeq = new Dictionary();
m_mcBGRef = null;
m_sLoadedLevel = "";
m_mcSnapShot = null;
m_SnapShotData = null;
m_Stage = null;
m_TextContainer = new MovieClip();
m_iBGFrame = 1;
m_oScoreText = null;
m_iScreenWidth = 0;
m_nScreenScale = 0;
m_sMusicType = "A";
m_iSlidingCount = 0;
m_iBlownAway = 0;
m_iBlownUpPieces = 0;
m_bFirstGame = true;
m_bMagicMode = false;
m_bMagicChanging = false;
m_iMagicSize = 0;
m_iMagicType = 0;
m_oMover = null;
m_pLastMagicPoint = new Point();
super();
m_Stage = _arg1;
WINDOW.m_oQBGameHandler = this;
m_iScreenWidth = WINDOW.m_iScrHeight;
m_nScreenScale = (m_iScreenWidth / WINDOW.m_iScrHeight);
IMAGEDATA = new Dictionary();
SOUNDDATA = new Dictionary();
SOUNDNAMES = new Array();
setTimeParam();
setGameParam();
m_mcSnapShot = new MovieClip();
setUserData("totalscore", 0);
setUserData("stagescore", 0);
setUserData("score", 0);
setUserData("lastscore", 0);
setUserData("lastperfect", 0);
setUserData("lasmaxgroup", 0);
setUserData("perfect", 0);
setUserData("maxgroup", 0);
setUserData("curperfect", 0);
setUserData("curmaxgroup", 0);
m_pauseTimer.addEventListener(TimerEvent.TIMER, onPauseTimer, false, 0, true);
}
public function getIsFirstLevel():Boolean{
return (m_bFirstGame);
}
public function getIsPainting():Boolean{
return (m_bPainting);
}
public function getCurrentLevel():int{
return (m_iCurrentLvl);
}
public function sortGrid(_arg1:Boolean=false):void{
var _local2:QBeez;
var _local3:int;
var _local4:int;
var _local5:int;
var _local6:int;
if (((m_bShuffling) && (m_bShifting))){
m_bForceSort = true;
return;
};
if (m_bShifting){
return;
};
_local2 = null;
_local3 = 0;
_local4 = 0;
_local5 = 10;
_local6 = -1;
if (!_arg1){
_local3 = (m_iBoardSize - 1);
while (_local3 >= 0) {
_local2 = getQBee(_local3, (m_iBoardSize - 1));
if (((((((((_local2) && (_local2.bSliding))) && (!(_local2.bBlownUp)))) && (!(_local2.bKill)))) && (!(_local2.bPainting)))){
_local6 = _local3;
break;
};
_local3--;
};
if (_local6 > 0){
_local3 = _local6;
while (_local3 >= 0) {
_local4 = (m_iBoardSize - 1);
while (_local4 >= -1) {
_local2 = null;
_local2 = getQBee(_local3, _local4);
if (((((((_local2) && (!(_local2.bBlownUp)))) && (!(_local2.bKill)))) && (!(_local2.bPainting)))){
_local2.setDepth(_local5);
_local5++;
};
_local4--;
};
_local3--;
};
};
};
_local3 = (_local6 + 1);
while (_local3 < m_iBoardSize) {
_local4 = (m_iBoardSize - 1);
while (_local4 >= -1) {
_local2 = null;
_local2 = getQBee(_local3, _local4);
if (((((((_local2) && (!(_local2.bBlownUp)))) && (!(_local2.bKill)))) && (!(_local2.bPainting)))){
_local2.setDepth(_local5);
_local5++;
};
_local4--;
};
_local3++;
};
}
public function scareCircle(_arg1:Event=null):void{
var _local2:Number;
var _local3:int;
var _local4:int;
var _local5:QBeez;
var _local6:QBeez;
var _local7:int;
var _local8:int;
var _local9:int;
var _local10:int;
var _local11:int;
var _local12:int;
_local2 = (getQBScale() / 2);
_local3 = (((m_oMover.x - m_nStartLocX) + _local2) / getQBScale());
_local4 = (((m_oMover.y - m_nStartLocY) + _local2) / getQBScale());
_local5 = getQBee(_local3, _local4);
_local6 = null;
if ((((m_pLastMagicPoint.x == _local3)) && ((m_pLastMagicPoint.y == _local4)))){
return;
};
_local7 = 0;
_local8 = 0;
_local7 = 0;
while (_local7 < m_iBoardSize) {
_local8 = (m_iBoardSize - 1);
while (_local8 >= -1) {
_local6 = getQBee(_local7, _local8);
if (_local6){
_local6.setState("IDLE");
_local6.setColorOffset(0, 0, 0);
};
_local8--;
};
_local7++;
};
if (!_local5){
return;
};
m_pLastMagicPoint.x = _local3;
m_pLastMagicPoint.y = _local4;
_local8 = 0;
_local9 = 0;
_local10 = 0;
switch (m_iMagicType){
case 1:
_local8 = 253;
_local9 = 171;
_local10 = 252;
break;
case 2:
_local8 = -150;
_local9 = -150;
_local10 = -150;
break;
case 3:
_local8 = -75;
_local9 = -75;
_local10 = -75;
break;
case 4:
_local8 = 112;
_local9 = 183;
_local10 = 254;
break;
case 5:
_local8 = 0xFF;
_local9 = 0;
_local10 = 0;
break;
case 6:
_local8 = 0xFF;
_local9 = 0xFF;
_local10 = 0;
break;
case 7:
_local8 = 116;
_local9 = 1;
_local10 = 1;
break;
case 8:
_local8 = 2;
_local9 = 141;
_local10 = 1;
break;
case 9:
_local8 = 1;
_local9 = 98;
_local10 = 216;
break;
case 10:
_local8 = 243;
_local9 = 134;
_local10 = 1;
break;
case 11:
_local8 = 120;
_local9 = 0;
_local10 = 167;
break;
case 12:
_local8 = 153;
_local9 = 102;
_local10 = 0;
break;
case 13:
_local8 = 250;
_local9 = 250;
_local10 = 250;
break;
case 14:
_local8 = 0xFF;
_local9 = 0;
_local10 = 212;
break;
case 15:
_local8 = 5;
_local9 = 254;
_local10 = 5;
break;
};
_local8 = (_local8 * 0.5);
_local9 = (_local9 * 0.5);
_local10 = (_local10 * 0.5);
_local11 = _local5.xPos;
_local12 = _local5.yPos;
if (m_iMagicSize > 1){
_local5.setColorOffset(_local8, _local9, _local10);
_local6 = getQBee(_local11, (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee(_local11, (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 1), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 1), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 1), (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 1), (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 1), (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 1), (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee(_local11, (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee(_local11, (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
};
if (m_iMagicSize > 2){
_local6 = getQBee((_local11 + 1), (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 1), (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 1), (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 1), (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
};
if (m_iMagicSize > 3){
_local6 = getQBee((_local11 - 1), (_local12 + 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee(_local11, (_local12 + 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 1), (_local12 + 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 1), (_local12 - 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee(_local11, (_local12 - 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 1), (_local12 - 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 3), (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 3), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 3), (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 3), (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 3), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 3), (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
};
if (m_iMagicSize > 4){
_local6 = getQBee((_local11 - 1), (_local12 + 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee(_local11, (_local12 + 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 1), (_local12 + 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 1), (_local12 - 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee(_local11, (_local12 - 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 1), (_local12 - 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 4), (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 4), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 4), (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 4), (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 4), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 4), (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), (_local12 + 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 3), (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), (_local12 - 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 3), (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), (_local12 - 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 3), (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), (_local12 + 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 3), (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
};
if (m_iMagicSize > 6){
_local6 = getQBee((_local11 + 2), (_local12 + 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 4), (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 3), (_local12 + 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 3), (_local12 + 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 4), (_local12 + 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), (_local12 - 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 4), (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 3), (_local12 - 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 3), (_local12 - 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 4), (_local12 - 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), (_local12 + 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 4), (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 3), (_local12 + 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 3), (_local12 + 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 4), (_local12 + 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), (_local12 - 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 4), (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 3), (_local12 - 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 3), (_local12 - 4));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 4), (_local12 - 3));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
};
if (m_iMagicSize > 9){
_local6 = getQBee((_local11 + 5), (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 5), (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 5), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 5), (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 5), (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 5), (_local12 - 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 5), (_local12 - 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 5), _local12);
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 5), (_local12 + 1));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 5), (_local12 + 2));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), (_local12 + 5));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 1), (_local12 + 5));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee(_local11, (_local12 + 5));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 1), (_local12 + 5));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), (_local12 + 5));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 2), (_local12 - 5));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 - 1), (_local12 - 5));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee(_local11, (_local12 - 5));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 1), (_local12 - 5));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
_local6 = getQBee((_local11 + 2), (_local12 - 5));
if (_local6){
_local6.setColorOffset(_local8, _local9, _local10);
};
};
}
public function startCountDown():void{
if (!m_bLevelDone){
return;
};
m_bGameOverCountdown = true;
m_iCurPerfect = 5;
playSound("GAMEOVER");
m_newGameTimer.start();
}
public function checkNewStageScore():Boolean{
if (m_bRestartStage){
m_bRestartStage = false;
return (true);
};
return (false);
}
public function setIsPainting(_arg1:Boolean=true):void{
m_bPainting = _arg1;
}
public function getGravity():Number{
return (m_nGravity);
}
public function getLevelPreview(_arg1:String):BitmapData{
var _local2:skxWindow;
var _local3:int;
var _local4:String;
var _local5:RegExp;
var _local6:RegExp;
var _local7:RegExp;
var _local8:RegExp;
var _local9:Array;
var _local10:Array;
var _local11:int;
var _local12:Array;
var _local13:String;
var _local14:Array;
var _local15:Number;
var _local16:int;
var _local17:int;
var _local18:int;
var _local19:QBeez;
var _local20:BitmapData;
_local2 = new skxWindow(WINDOW.m_iScrWidth, WINDOW.m_iScrHeight);
setGameParam();
clearBoard();
_local3 = 0;
m_iNumberUpdated = 0;
m_LiveQB = 0;
m_TypeCount = 0;
m_TypeList = new Dictionary();
_local3 = 0;
_local4 = _arg1;
_local5 = /\r/g;
_local6 = /\n\n/g;
_local7 = /"/g;
_local8 = /\s/g;
_local4 = _local4.replace(_local5, "\n");
_local4 = _local4.replace(_local6, "\n");
_local4 = _local4.replace("END", "\n");
_local4 = _local4.replace("|", "\n");
_local9 = _local4.split("\n");
_local10 = _local9[0].split(",");
_local11 = 0;
_local13 = _local4.substring((_local4.indexOf("[") + 1), _local4.indexOf("]")).replace(_local7, "");
_local13 = _local13.replace(_local8, "");
_local14 = _local13.split(",");
m_ColorSet = new Array();
m_QBColorSet = new Array();
_local3 = 0;
while (_local3 < _local14.length) {
m_ColorSet.push(_local14[_local3]);
if (getLevelInt(_local14[_local3]) < 16){
m_QBColorSet.push(_local14[_local3]);
};
_local3++;
};
m_TypeCount = m_ColorSet.length;
_local3 = 0;
while (_local3 < _local10.length) {
_local12 = _local10[_local3].split(":");
switch (_local12[0]){
case "#col":
_local11 = Number(_local12[1]);
break;
case "#bkg":
m_iBackground = int(_local12[1]);
break;
case "#name":
m_sLevelName = _local12[1];
break;
case "#by":
m_sLevelAuthor = _local12[1];
break;
case "#msg":
m_sMessage = _local12[1];
break;
case "#diff":
m_sDiff = _local12[1];
break;
case "#hs":
m_sHS = _local12[1];
break;
default:
break;
};
_local3++;
};
_local15 = ((750 / _local11) * m_nScaleFactor);
m_nQBScale = (_local15 * 0.6);
m_iBoardSize = _local11;
m_iQBCount = (_local11 * _local11);
_local16 = 0;
_local17 = 0;
_local18 = 0;
_local19 = null;
m_nFallScale = (m_nQBScale / WINDOW.m_iScrHeight);
m_nImageScale = (_local15 / 100);
m_mcBrushRef.scaleX = m_nImageScale;
m_mcBrushRef.scaleY = m_nImageScale;
m_mcBombRef.scaleX = m_nImageScale;
m_mcBombRef.scaleY = m_nImageScale;
m_mcReference.scaleX = m_nImageScale;
m_mcReference.scaleY = m_nImageScale;
m_nStartLocX = ((m_nBoardOffsetX - (m_nQBScale * (_local11 - 1))) - (m_nQBScale / 2));
m_nStartLocY = ((m_nGroundLine - (m_nQBScale * (_local11 - 1))) - (m_nQBScale / 2));
initQBeez();
_local17 = 0;
while (_local17 <= _local11) {
if (_local9[(_local17 + 1)]){
_local12 = _local9[(_local17 + 1)].split("-");
_local16 = 0;
while (_local16 < _local11) {
_local18 = getLevelInt(String(_local12[_local16]));
_local19 = new QBeez();
_local19.x = (m_nStartLocX + (_local16 * m_nQBScale));
_local19.y = (m_nStartLocY + (_local17 * m_nQBScale));
_local19.qbType = _local18;
_local19.sColor = getColor(_local19.qbType);
_local19.name = String(_local3);
_local19.setGameHandler(this);
_local19 = setPiece(_local19);
_local2.addObject(_local19);
setQBee(_local16, (_local17 - 1), _local19);
_local19.Init();
_local16++;
_local3++;
};
};
_local17++;
};
sortGrid(true);
_local2.Unpause();
_local2.update();
_local2.Pause();
_local2.renderWindow();
_local20 = _local2.getCurBuffer();
_local2.clearObjects();
_local2 = null;
return (_local20);
}
private function startLevelOverSequence():void{
var _local1:int;
m_bLevelDone = true;
m_tForceCheckTimer.stop();
dispatchGameEvent({EVENT:"ENDGAME"});
stopAllSound();
skxSoundChannel.clearAll();
if (m_LiveQB <= 0){
goToState("PERFECT", 750);
addPerfect();
} else {
if (sGameMode != 3){
goToState("TIMEBONUS", 750);
} else {
if (getPercCleared() >= 95){
goToState("TIMEBONUS", 750);
} else {
dispatchGameEvent({EVENT:"COUNTDOWN"});
dispatchGameEvent({EVENT:"GAMEOVERLOST"});
};
};
};
m_bGameStarted = false;
m_bGameOver = true;
m_bTimerPassed = false;
WINDOW.sendState("ALL-EMOTE");
_local1 = 0;
playSound("LVLDONE", 0, 1, true);
_local1 = 1;
while (_local1 < 16) {
if (m_TypeList[_local1] > 0){
playSound(String(("CRY" + getColor(_local1))));
};
_local1++;
};
}
public function getGroundLine():Number{
return (m_nGroundLine);
}
public function stopAllSound():void{
skxSoundChannel.clearAll();
skxMusicChannel.clearAll();
}
public function getCircleQBeez(_arg1:QBeez):void{
var _local2:int;
var _local3:int;
var _local4:int;
var _local5:int;
var _local6:QBeez;
var _local7:int;
_local2 = _arg1.xPos;
_local3 = _arg1.yPos;
_local4 = 75;
_local5 = 10;
_local6 = null;
_local7 = 0;
if (m_iMagicSize > 1){
m_TypeList[_arg1.qbType] = (m_TypeList[_arg1.qbType] - 1);
_arg1.qbType = m_iMagicType;
_local7++;
_arg1.goToState("MAGIC", _local5);
_local6 = getQBee(_local2, (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 1)));
};
_local6 = getQBee(_local2, (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 1)));
};
_local6 = getQBee((_local2 + 1), _local3);
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 1)));
};
_local6 = getQBee((_local2 - 1), _local3);
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 1)));
};
_local6 = getQBee((_local2 - 1), (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 1)));
};
_local6 = getQBee((_local2 - 1), (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 1)));
};
_local6 = getQBee((_local2 + 1), (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 1)));
};
_local6 = getQBee((_local2 + 1), (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 1)));
};
_local6 = getQBee(_local2, (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee(_local2, (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 + 2), _local3);
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 - 2), _local3);
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
};
if (m_iMagicSize > 2){
_local6 = getQBee((_local2 + 1), (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 - 1), (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 + 1), (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 - 1), (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 + 2), (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 - 2), (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 + 2), (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 - 2), (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
};
if (m_iMagicSize > 3){
_local6 = getQBee((_local2 - 1), (_local3 + 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee(_local2, (_local3 + 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 1), (_local3 + 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 - 1), (_local3 - 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee(_local2, (_local3 - 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 1), (_local3 - 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 - 3), (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 - 3), _local3);
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 - 3), (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 3), (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 3), _local3);
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 3), (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 2), (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 - 2), (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 - 2), (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
_local6 = getQBee((_local2 + 2), (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 2)));
};
};
if (m_iMagicSize > 4){
_local6 = getQBee((_local2 - 1), (_local3 + 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee(_local2, (_local3 + 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 + 1), (_local3 + 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 - 1), (_local3 - 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee(_local2, (_local3 - 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 + 1), (_local3 - 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 - 4), (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 - 4), _local3);
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 - 4), (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 + 4), (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 + 4), _local3);
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 + 4), (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 + 2), (_local3 + 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 3), (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 - 2), (_local3 - 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 - 3), (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 2), (_local3 - 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 3), (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 - 2), (_local3 + 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 - 3), (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
};
if (m_iMagicSize > 6){
_local6 = getQBee((_local2 + 2), (_local3 + 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 + 4), (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 + 3), (_local3 + 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 3), (_local3 + 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 4), (_local3 + 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 2), (_local3 - 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 - 4), (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 - 3), (_local3 - 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 - 3), (_local3 - 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 4), (_local3 - 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 2), (_local3 + 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 - 4), (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 - 3), (_local3 + 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 - 3), (_local3 + 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 4), (_local3 + 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 2), (_local3 - 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 + 4), (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 4)));
};
_local6 = getQBee((_local2 + 3), (_local3 - 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 3)));
};
_local6 = getQBee((_local2 + 3), (_local3 - 4));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 4), (_local3 - 3));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
};
if (m_iMagicSize > 9){
_local6 = getQBee((_local2 + 5), (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 5), (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 5), _local3);
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 5), (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 5), (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 5), (_local3 - 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 5), (_local3 - 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 5), _local3);
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 5), (_local3 + 1));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 5), (_local3 + 2));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 2), (_local3 + 5));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 1), (_local3 + 5));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee(_local2, (_local3 + 5));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 1), (_local3 + 5));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 2), (_local3 + 5));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 2), (_local3 - 5));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 - 1), (_local3 - 5));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee(_local2, (_local3 - 5));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 1), (_local3 - 5));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
_local6 = getQBee((_local2 + 2), (_local3 - 5));
if (_local6){
m_TypeList[_local6.qbType] = (m_TypeList[_local6.qbType] - 1);
_local6.qbType = m_iMagicType;
_local7++;
_local6.goToState("MAGIC", (_local5 + (_local4 * 5)));
};
};
if (_local7 == 13){
dispatchGameEvent({EVENT:"MAGICGROUP", COUNT:1});
} else {
if (_local7 == 21){
dispatchGameEvent({EVENT:"MAGICGROUP", COUNT:2});
} else {
if (_local7 == 37){
dispatchGameEvent({EVENT:"MAGICGROUP", COUNT:3});
} else {
if (_local7 == 57){
dispatchGameEvent({EVENT:"MAGICGROUP", COUNT:4});
} else {
if (_local7 == 77){
dispatchGameEvent({EVENT:"MAGICGROUP", COUNT:5});
} else {
if (_local7 == 97){
dispatchGameEvent({EVENT:"MAGICGROUP", COUNT:6});
};
};
};
};
};
};
m_TypeList[m_iMagicType] = (m_TypeList[m_iMagicType] + _local7);
}
public function getPaused():Boolean{
return (m_bPaused);
}
public function onPauseTimer(_arg1:Event=null):void{
var _local2:int;
_local2 = 15;
if (((((getPaused()) && ((m_iPauseBlur < _local2)))) && (!(m_bStartUnPause)))){
m_mcSnapShot.visible = true;
m_SnapShotData.visible = true;
m_iPauseBlur = Math.min((m_iPauseBlur + 4), _local2);
if (sSoundOn == true){
setMusicVolume((1 - (m_iPauseBlur / _local2)));
};
m_mcSnapShot.filters = [new BlurFilter(m_iPauseBlur, m_iPauseBlur, 1)];
WINDOW.filters = [new BlurFilter(m_iPauseBlur, m_iPauseBlur, 1)];
WINDOW.Pause();
WINDOW.sendState("ALL-PAUSE");
dispatchGameEvent({EVENT:"PAUSE"});
} else {
if (((m_bStartUnPause) && ((m_iPauseBlur > 0)))){
if (sSoundOn == true){
setMusicVolume((1 - (m_iPauseBlur / _local2)));
};
m_mcSnapShot.visible = true;
m_SnapShotData.visible = true;
m_iPauseBlur = Math.max((m_iPauseBlur - 4), 0);
m_mcSnapShot.filters = [new BlurFilter(m_iPauseBlur, m_iPauseBlur, 1)];
WINDOW.filters = [new BlurFilter(m_iPauseBlur, m_iPauseBlur, 1)];
} else {
if (((((m_bStartUnPause) && (getPaused()))) && ((m_iPauseBlur <= 0)))){
postPauseTimer();
if (m_bGameOverCountdown){
m_newGameTimer.start();
};
};
};
};
}
public function restartStage():void{
}
public function setInfPowerMoves(_arg1:Boolean):void{
m_bInfPowerMoves = _arg1;
}
public function loadLevel(_arg1:String):void{
var _local2:int;
var _local3:String;
var _local4:RegExp;
var _local5:RegExp;
var _local6:RegExp;
var _local7:RegExp;
var _local8:Array;
var _local9:Array;
var _local10:int;
var _local11:Array;
var _local12:String;
var _local13:Array;
var _local14:Number;
var _local15:int;
var _local16:int;
var _local17:int;
var _local18:QBeez;
var _local19:skxImage;
WINDOW.filters = [];
skxSoundChannel.clearAll();
setGameParam();
clearBoard();
stopAllSound();
setTimerOff();
_local2 = 0;
m_bStopBar = false;
m_bTimerPassed = false;
m_bTimeBonus = false;
m_bPaused = true;
m_bDrown = false;
m_bTimeBonus = false;
m_bPerfectCount = false;
m_bLevelDone = false;
m_iGameTime = 0;
m_nPowerMoves = 3;
m_bLowerWater = false;
m_bGameOver = false;
m_bGameOverCountdown = false;
bSortAfterSlide = false;
SELECTED = new Array();
QBEEZGRID = new Dictionary();
TEMPGRID = new Dictionary();
POSITIONS = new Array();
TEMPPOSITIONS = new Array();
m_iNumberUpdated = 0;
m_LiveQB = 0;
m_TypeCount = 0;
m_TypeList = new Dictionary();
_local2 = 0;
_local3 = _arg1;
_local4 = /\r/g;
_local5 = /\n\n/g;
_local6 = /"/g;
_local7 = /\s/g;
_local3 = _local3.replace(_local4, "\n");
_local3 = _local3.replace(_local5, "\n");
_local3 = _local3.replace("END", "\n");
_local3 = _local3.replace("|", "\n");
_local8 = _local3.split("\n");
_local9 = _local8[0].split(",");
_local10 = 0;
_local12 = _local3.substring((_local3.indexOf("[") + 1), _local3.indexOf("]")).replace(_local6, "");
_local12 = _local12.replace(_local7, "");
_local13 = _local12.split(",");
m_ColorSet = new Array();
m_QBColorSet = new Array();
_local2 = 0;
while (_local2 < _local13.length) {
m_ColorSet.push(_local13[_local2]);
if (getLevelInt(_local13[_local2]) < 16){
m_QBColorSet.push(_local13[_local2]);
};
_local2++;
};
m_TypeCount = m_ColorSet.length;
_local2 = 0;
while (_local2 < _local9.length) {
_local11 = _local9[_local2].split(":");
switch (_local11[0]){
case "#col":
_local10 = Number(_local11[1]);
break;
case "#bkg":
m_iBackground = int(_local11[1]);
break;
case "#name":
m_sLevelName = _local11[1];
break;
case "#by":
m_sLevelAuthor = _local11[1];
break;
case "#msg":
m_sMessage = _local11[1];
break;
case "#diff":
m_sDiff = _local11[1];
break;
case "#hs":
m_sHS = _local11[1];
break;
default:
break;
};
_local2++;
};
_local14 = ((750 / _local10) * m_nScaleFactor);
m_nQBScale = (_local14 * 0.6);
m_iBoardSize = _local10;
m_iQBCount = (_local10 * _local10);
_local15 = 0;
_local16 = 0;
_local17 = 0;
_local18 = null;
m_nFallScale = (m_nQBScale / WINDOW.m_iScrHeight);
m_nImageScale = (_local14 / 100);
m_mcBrushRef.scaleX = m_nImageScale;
m_mcBrushRef.scaleY = m_nImageScale;
m_mcBombRef.scaleX = m_nImageScale;
m_mcBombRef.scaleY = m_nImageScale;
m_mcReference.scaleX = m_nImageScale;
m_mcReference.scaleY = m_nImageScale;
m_nStartLocX = ((m_nBoardOffsetX - (m_nQBScale * (_local10 - 1))) - (m_nQBScale / 2));
m_nStartLocY = ((m_nGroundLine - (m_nQBScale * (_local10 - 1))) - (m_nQBScale / 2));
dispatchGameEvent({EVENT:"PRELEVEL"});
m_iBGFrame = m_iBackground;
initQBeez();
setMusicType();
_local19 = new skxImage(new Background(), {type:"movie", scalex:sBGScale, scaley:sBGScale, width:800, height:600, copyframes:[m_iBGFrame], r:1, g:1, b:1});
WINDOW.setBackground(_local19);
_local16 = 0;
while (_local16 <= _local10) {
if (_local8[(_local16 + 1)]){
_local11 = _local8[(_local16 + 1)].split("-");
_local15 = 0;
while (_local15 < _local10) {
_local17 = getLevelInt(String(_local11[_local15]));
LEVELDATA.push(_local17);
_local18 = new QBeez();
_local18.x = (m_nStartLocX + (_local15 * m_nQBScale));
_local18.y = ((m_nStartLocY + (_local16 * m_nQBScale)) - 600);
_local18.qbType = _local17;
_local18.sColor = getColor(_local18.qbType);
_local18.name = String(_local2);
_local18.setGameHandler(this);
_local18 = setPiece(_local18);
m_TypeList[_local18.qbType] = (m_TypeList[_local18.qbType] + 1);
WINDOW.addObject(_local18);
setQBee(_local15, (_local16 - 1), _local18);
_local18.Init();
m_LiveQB++;
_local15++;
_local2++;
};
};
_local16++;
};
m_bLoadedGame = false;
preLevel();
}
public function stageUp():void{
sStagedUp = true;
m_iCurrentPackLevel++;
m_iCurrentSubLvl++;
if (m_iCurrentSubLvl >= 7){
m_iCurrentSubLvl = 1;
m_iCurrentLvl++;
updateSaveQuestMode();
setUserData("stagescore", 0);
setUserData("maxgroup", 0);
setUserData("perfect", 0);
setUserData("score", 0);
setUserData("curmaxgroup", 0);
setUserData("curperfect", 0);
};
}
public function Pick(_arg1:int, _arg2:int, _arg3:int):void{
var _local4:QBeez;
_local4 = QBEEZGRID[String(((_arg1 + "_") + _arg2))];
if (((((_local4) && ((SELECTED.indexOf(_local4) == -1)))) && ((_local4.qbType == _arg3)))){
SELECTED.push(_local4);
Pick((_arg1 + 1), _arg2, _arg3);
Pick((_arg1 - 1), _arg2, _arg3);
Pick(_arg1, (_arg2 - 1), _arg3);
Pick(_arg1, (_arg2 + 1), _arg3);
};
}
private function onXMLLoaded(_arg1:Event):void{
var _local2:XML;
var _local3:XMLList;
var _local4:XML;
_local2 = new XML(_arg1.target.data);
_local3 = _local2.children();
for each (_local4 in _local3) {
if ((((_local4.name() == (_local2.namespaceDeclarations()[0] + "::level_data"))) || ((_local4.name() == "level_data")))){
loadLevel(String(_local4));
return;
};
};
}
public function getPrettyTotalScore():String{
return (prettyScore(getUserData("totalscore"), false));
}
public function retriveQBList():String{
var _local1:String;
var _local2:QBeez;
var _local3:int;
var _local4:int;
if (m_bGameOver){
return ("CLEAR");
};
_local1 = "";
_local2 = null;
_local3 = (m_iBoardSize - 1);
while (_local3 >= -1) {
_local4 = (m_iBoardSize - 1);
while (_local4 >= -1) {
_local2 = null;
_local2 = getQBee(_local3, _local4);
if (((((_local2) && (!(_local2.bBlownUp)))) && (!(_local2.bKill)))){
_local1 = (_local1 + String((((((_local3 + "+") + _local4) + "+") + _local2.qbType) + "?")));
};
_local4--;
};
_local3--;
};
if (_local1 == ""){
return ("CLEAR");
};
return (_local1);
}
public function outputLevelInfo():void{
}
public function addPerfect():void{
setUserData("curperfect", (getUserData("curperfect") + 1));
setUserData("perfect", (getUserData("perfect") + 1));
}
public function setLevel(_arg1:int){
m_iCurrentLvl = _arg1;
}
public function forceCheckBoardMoves(_arg1:Event):void{
if (((((((!(checkBoardMoves())) && ((getPowerMoves() == 0)))) && ((m_bMagicChanging == false)))) && ((m_bMagicMode == false)))){
startLevelOverSequence();
};
}
public function playSound(_arg1:String, _arg2:Number=0, _arg3:uint=1, _arg4:Boolean=false):void{
var _local5:Sound;
_local5 = (SOUNDDATA[_arg1] as Sound);
if (_local5){
skxSoundChannel.playSound(_local5, _arg2, _arg3, _arg4);
};
}
public function updateSaveQuestMode():void{
var _local1:Number;
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:String;
var _local8:int;
_local1 = 0;
_local2 = 0;
_local3 = 0;
_local4 = Number(getUserData("perfect"));
_local5 = Number(getUserData("maxgroup"));
_local6 = Number(getUserData("totalscore"));
_local8 = getCurrentLevel();
_local7 = String(((((((((((((((((((((((((((("0-" + sDailySeed) + "-") + _local8) + "-") + 1) + "-") + _local1) + "-") + _local2) + "-") + _local3) + "-") + _local4) + "-") + _local5) + "-") + _local6) + "-") + getStageNode(_local8)) + "-") + 0) + "-") + m_iBGFrame) + "-") + 3) + "-") + "CLEAR"));
skxUser.setCurData("questsave", _local7);
skxUser.storeCurLocally();
}
public function onShuffleEnd():void{
m_bShifting = false;
}
public function rotateBoard(_arg1:int):void{
if ((((((((((((((getInfPowerMoves() == false)) && ((getPowerMoves() < 1)))) || (m_bShifting))) || (m_bMoving))) || (m_bGameOver))) || (m_bMagicChanging))) || (m_bMagicMode))){
return;
};
m_iRotateCount++;
m_bShifting = true;
m_bMoving = true;
playSound("SPIN", 0, 1, true);
TEMPGRID = new Dictionary();
m_iNumberUpdated = 0;
QBeez.sRotDispatcher.dispatchEvent(new QBRotateEvent(QBRotateEvent.ROTATE, _arg1));
if (!getInfPowerMoves()){
m_nPowerMoves--;
};
}
public function dispatchGameEvent(_arg1:Object):void{
sNewGameDispatcher.dispatchEvent(new QBGameEvent(QBGameEvent.GAME, _arg1));
}
public function addScore(_arg1:int):String{
setUserData("totalscore", (getUserData("totalscore") + _arg1));
setUserData("score", (getUserData("score") + _arg1));
setUserData("stagescore", (getUserData("stagescore") + _arg1));
if (getUserData("stagescore") < 0){
setUserData("stagescore", 0);
};
if (getUserData("score") < 0){
setUserData("score", 0);
};
if (getUserData("totalscore") < 0){
setUserData("totalscore", 0);
};
m_oScoreText.text = prettyScore(getUserData("totalscore"), false);
return (prettyScore(_arg1));
}
public function getBombType(_arg1:int):int{
switch (_arg1){
case 1:
return (17);
case 2:
return (18);
case 3:
return (19);
case 4:
return (20);
case 5:
return (21);
case 6:
return (22);
case 7:
return (23);
case 8:
return (24);
case 9:
return (25);
case 10:
return (26);
case 11:
return (27);
case 12:
return (28);
case 13:
return (29);
case 14:
return (30);
case 15:
return (31);
};
return (-1);
}
public function getBoardWidth():int{
return (m_iBoardWidth);
}
public function getBoardHeight():int{
return (m_iBoardHeight);
}
public function startDrop():void{
WINDOW.sendState("ALL-DROP");
}
public function flipBoard():void{
if ((((((((((((((getInfPowerMoves() == false)) && ((getPowerMoves() < 1)))) || (m_bShifting))) || (m_bMoving))) || (m_bGameOver))) || (m_bMagicChanging))) || (m_bMagicMode))){
return;
};
m_iFlipCount++;
m_bShifting = true;
m_bMoving = true;
incMoves();
playSound("SPIN", 0, 1, true);
TEMPGRID = new Dictionary();
m_iNumberUpdated = 0;
QBeez.sFlipDispatcher.dispatchEvent(new QBFlipEvent(QBFlipEvent.FLIP));
if (!getInfPowerMoves()){
m_nPowerMoves--;
};
}
public function setStateTimerOff():Boolean{
if (m_stateTimer){
m_stateTimer.stop();
return (true);
};
return (false);
}
public function shutDown():void{
setTimerOff();
SELECTED = new Array();
QBEEZGRID = new Dictionary();
TEMPGRID = new Dictionary();
POSITIONS = new Array();
TEMPPOSITIONS = new Array();
m_iNumberUpdated = 0;
m_LiveQB = 0;
bSortAfterSlide = false;
IMAGEDATA = new Dictionary();
m_newGameTimer.stop();
m_bGameStarted = false;
m_bGameOver = true;
m_bTimerPassed = false;
m_bTimeBonus = false;
m_bPaused = true;
m_bDrown = false;
m_bTimeBonus = false;
m_bPerfectCount = false;
m_bLowerWater = false;
}
public function setVolume(_arg1:Number):void{
skxSoundChannel.setVolume(_arg1);
skxMusicChannel.setVolume(_arg1);
}
private function onStartNewTimer(_arg1:Event):void{
if (m_bGameOverCountdown){
if (m_iCurPerfect <= 0){
m_bGameOverCountdown = false;
goToState("STARTNEWGAME", 2000);
} else {
m_iCurPerfect = (m_iCurPerfect - 1);
dispatchGameEvent({EVENT:"COUNTDOWN"});
};
};
}
public function cleanUpBoard():void{
WINDOW.clearObjects();
}
public function getPrettyScore():String{
return (prettyScore(getUserData("score"), false));
}
public function generareLevel(_arg1:int):Array{
var _local2:int;
var _local3:Array;
var _local4:Array;
var _local5:*;
var _local6:int;
var _local7:int;
var _local8:Array;
var _local9:String;
var _local10:int;
var _local11:int;
if (sGameMode == 0){
skxRandom.setSeed(((sDailySeed * getCurrentLevel()) * (getSubLevel() * 100)));
} else {
skxRandom.setSeed((sDailySeed * ((getSubLevel() * 100) + (sGameMode * 100))));
};
_local2 = COLORPARAM[m_iCurrentLvl][(m_iCurrentSubLvl - 1)];
m_ColorSet = getColorSet(_local2);
m_TypeCount = m_ColorSet.length;
_local3 = new Array();
_local4 = new Array();
_local5 = m_ColorSet.length;
_local6 = 0;
_local7 = 0;
_local8 = new Array();
_local7 = 0;
_local9 = "";
_local10 = getCurrentLevel();
if ((((sGameMode == 1)) || ((sGameMode == 2)))){
_local10 = getSubLevel();
};
while (_local7 < ITEMPARAM[_local10].length) {
_local9 = ITEMPARAM[_local10][_local7];
if (_local9 == "randomvalid"){
switch (skxRandom.getRandomInt(0, 2)){
case 0:
_local9 = "brush";
break;
case 1:
_local9 = "2bomb";
break;
};
};
if (_local9 == "brush"){
_local3.push(16);
} else {
if (_local9 == "stone"){
_local3.push(40);
} else {
if (_local9 == "bomb"){
_local6 = m_ColorSet[skxRandom.getRandomInt(0, _local5)];
while (_local8.indexOf(_local6) != -1) {
_local6 = m_ColorSet[skxRandom.getRandomInt(0, _local5)];
};
_local3.push(getBombType(_local6));
_local8.push(_local6);
if (_local8.length >= _local5){
_local8 = new Array();
};
} else {
if (_local9 == "magic"){
_local6 = m_ColorSet[skxRandom.getRandomInt(0, _local5)];
while (_local8.indexOf(_local6) != -1) {
_local6 = m_ColorSet[skxRandom.getRandomInt(0, _local5)];
};
_local3.push(getMagicType(_local6));
_local8.push(_local6);
if (_local8.length >= _local5){
_local8 = new Array();
};
} else {
if (_local9 == "2magic"){
_local6 = m_ColorSet[skxRandom.getRandomInt(0, _local5)];
while (_local8.indexOf(_local6) != -1) {
_local6 = m_ColorSet[skxRandom.getRandomInt(0, _local5)];
};
_local3.push(getMagicType(_local6));
_local8.push(_local6);
_local3.push(getMagicType(_local6));
if (_local8.length >= _local5){
_local8 = new Array();
};
} else {
if (_local9 == "2bomb"){
_local6 = m_ColorSet[skxRandom.getRandomInt(0, _local5)];
while (_local8.indexOf(_local6) != -1) {
_local6 = m_ColorSet[skxRandom.getRandomInt(0, _local5)];
};
_local3.push(getBombType(_local6));
_local8.push(_local6);
_local3.push(getBombType(_local6));
if (_local8.length >= _local5){
_local8 = new Array();
};
} else {
if (_local9 == "randombomb"){
_local6 = skxRandom.getRandomInt(17, 32);
_local3.push(getBombType(_local6));
} else {
if (_local9 == "none"){
break;
};
};
};
};
};
};
};
};
_local7++;
};
_local7 = 0;
_local11 = ((_arg1 - _local3.length) / _local5);
while (_local7 < _local11) {
_local6 = 0;
while (_local6 < _local5) {
_local3.push(m_ColorSet[_local6]);
_local6++;
};
_local7++;
};
while (_local3.length < _arg1) {
_local3.push(m_ColorSet[skxRandom.getRandomInt(0, m_ColorSet.length)]);
};
_local3 = skxUtil.shuffleArray(_local3);
LEVELDATA = _local3;
return (_local3);
}
public function setTimerOff():Boolean{
if (m_timer){
m_timer.stop();
return (true);
};
return (false);
}
protected function onStateTimer(_arg1:Event=null):void{
if (m_sGoToState == "STARTNEWGAME"){
skxDisplay.Print("start new game ");
m_bGameStarted = false;
m_sGoToState = "";
if (QBGameHandler.m_aLevels){
skxDisplay.Print("Play custom level");
QBGameHandler.sMainHandler.loadLevel(QBGameHandler.m_aLevels[QBGameHandler.m_iCurrentPackLevel]);
} else {
startGame();
};
return;
} else {
if (m_sGoToState == "PLAYAD"){
dispatchGameEvent({EVENT:"PLAYAD"});
} else {
if (m_sGoToState == "STATS"){
showStats();
} else {
if (m_sGoToState == "PERFECT"){
m_iCurPerfect = 100000;
skxScheduler.schedule(startPerfectCountDown, 50);
} else {
if (m_sGoToState == "PERFECTCOUNT"){
m_bPerfectCount = true;
setTimerOn(10);
dispatchGameEvent({EVENT:"PERFECTCOUNT"});
} else {
if (m_sGoToState == "TIMEBONUS"){
if (sGameMode != 3){
dispatchGameEvent({EVENT:"TIMEBONUS"});
skxScheduler.schedule(startTimeBonus, 500);
} else {
updateStats();
if (m_aLevels){
if (m_iCurrentPackLevel < m_aLevels.length){
goToState("PREWATER", 500);
} else {
goToState("STAGECOMPLETE", 700);
};
} else {
if (m_iCurrentSubLvl < 6){
goToState("PREWATER", 500);
} else {
goToState("STAGECOMPLETE", 700);
};
};
return;
};
} else {
if (m_sGoToState == "STARTCOUNTDOWN"){
restartLevel();
startCountDown();
} else {
if ((((m_sGoToState == "GAMEOVERWIN")) || ((m_sGoToState == "GAMEOVERLOST")))){
dispatchGameEvent({EVENT:m_sGoToState});
} else {
if (m_sGoToState == "STAGECOMPLETE"){
dispatchGameEvent({EVENT:"STAGECOMPLETE"});
} else {
if (m_sGoToState == "PREWATER"){
startLowerWater();
};
};
};
};
};
};
};
};
};
};
m_sGoToState = "";
setStateTimerOff();
}
public function setUserData(_arg1:String, _arg2){
USERDATA[_arg1] = _arg2;
}
public function startLowerWater():void{
if (!m_bLevelDone){
return;
};
m_watertimer.stop();
WINDOW.sendState("ALL-GETOUT");
m_iGameTime = 100;
m_bLowerWater = true;
setTimerOn(5);
}
public function clearBoard():void{
var _local1:QBeez;
var _local2:int;
var _local3:int;
_local1 = null;
_local2 = 0;
_local3 = 0;
_local2 = 0;
while (_local2 < m_iBoardSize) {
_local3 = (m_iBoardSize - 1);
while (_local3 >= -1) {
_local1 = getQBee(_local2, _local3);
if (_local1){
_local1.Delete();
};
_local3--;
};
_local2++;
};
}
public function setIsMoving(_arg1:Boolean=true):void{
m_bMoving = _arg1;
}
public function getImageScale():Number{
return (m_nImageScale);
}
public function saveQuestMode(_arg1:Boolean):void{
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:String;
_local2 = Number(getUserData("curperfect"));
_local3 = Number(getUserData("curmaxgroup"));
_local4 = Number(getUserData("stagescore"));
_local5 = Number(getUserData("perfect"));
_local6 = Number(getUserData("maxgroup"));
_local7 = Number(getUserData("totalscore"));
_local8 = "";
if (_arg1){
_local8 = (_local8 + "1-");
_local8 = (_local8 + String(((((((((((((((((((((((((((sDailySeed + "-") + Math.max(1, getCurrentLevel())) + "-") + getSubLevel()) + "-") + _local2) + "-") + _local3) + "-") + _local4) + "-") + _local5) + "-") + _local6) + "-") + _local7) + "-") + getStageNode(getCurrentLevel())) + "-") + m_iGameTime) + "-") + m_iBGFrame) + "-") + m_nPowerMoves) + "-") + retriveQBList())));
} else {
_local8 = (_local8 + "0-");
_local8 = (_local8 + String(((((((((((((((((((((((((((sDailySeed + "-") + Math.max(1, getCurrentLevel())) + "-") + getSubLevel()) + "-") + _local2) + "-") + _local3) + "-") + _local4) + "-") + _local5) + "-") + _local6) + "-") + _local7) + "-") + getStageNode(getCurrentLevel())) + "-") + m_iGameTime) + "-") + m_iBGFrame) + "-") + m_nPowerMoves) + "-") + retriveQBList())));
};
skxUser.setCurData("questsave", _local8);
skxUser.storeCurLocally();
}
public function getSubLevel():int{
return (m_iCurrentSubLvl);
}
public function checkBoardMoves():Boolean{
var _local1:QBeez;
var _local2:*;
var _local3:*;
var _local4:*;
var _local5:*;
var _local6:int;
var _local7:int;
_local5 = null;
_local6 = 0;
_local7 = 0;
_local6 = -1;
while (_local6 <= m_iBoardSize) {
_local7 = (m_iBoardSize - 1);
while (_local7 >= -1) {
_local1 = getQBee(_local6, _local7);
if (((_local1) && ((_local1.qbType == 16)))){
return (true);
};
if (((_local1) && (!((_local1.qbType == 40))))){
_local2 = getQBee(_local6, (_local7 - 1));
_local3 = getQBee(_local6, (_local7 + 1));
_local4 = getQBee((_local6 - 1), _local7);
_local5 = getQBee((_local6 + 1), _local7);
if (((_local2) && ((_local1.qbType == _local2.qbType)))){
return (true);
};
if (((_local3) && ((_local1.qbType == _local3.qbType)))){
return (true);
};
if (((_local4) && ((_local1.qbType == _local4.qbType)))){
return (true);
};
if (((_local5) && ((_local1.qbType == _local5.qbType)))){
return (true);
};
};
_local7--;
};
_local6++;
};
return (false);
}
public function setMusicVolume(_arg1:Number):void{
skxMusicChannel.setVolume(_arg1);
}
private function onTimer(_arg1:Event):void{
if (m_bLowerWater){
m_iGameTime = Math.max((m_iGameTime - 3), 0);
dispatchGameEvent({EVENT:"LOWERWATER"});
if (m_iGameTime <= 0){
m_iGameTime = 0;
m_bLowerWater = false;
m_bGameStarted = false;
if (((m_aLevels) && ((m_iCurrentPackLevel == (m_aLevels.length - 1))))){
dispatchGameEvent({EVENT:"LASTLEVELPACK"});
} else {
goToState("STARTNEWGAME", 2000);
};
};
return;
};
if (((!(m_bGameOver)) && (!(m_bLowerWater)))){
m_iGameTime = (m_iGameTime + 1);
if (m_iGameTime >= 100){
m_bTimerPassed = true;
m_bLevelDone = true;
m_bGameStarted = false;
m_bGameOver = true;
WINDOW.sendState("ALL-INHALE");
stopAllSound();
playSound("SPLASH");
playSound("WAVE");
setTimerOn(20);
};
} else {
if ((((m_bDrown == false)) && (m_bGameOver))){
if (m_bTimerPassed){
m_bDrown = true;
};
};
};
if (m_bDrown){
if (m_iGameTime >= 1){
m_iGameTime = (m_iGameTime - 1);
} else {
if (m_bTimerPassed){
WINDOW.sendState("ALL-DROWN");
dispatchGameEvent({EVENT:"GAMEOVERLOST"});
WINDOW.filters = [new BlurFilter(6, 6, 1)];
if (QBPackHandler.m_oAvatar){
QBPackHandler.m_oAvatar.filters = [new BlurFilter(6, 6, 1)];
};
};
m_bTimeBonus = false;
m_bPerfectCount = false;
setTimerOff();
};
};
if (m_bTimeBonus){
addScore(100);
m_iCurPerfect = (m_iCurPerfect + 100);
dispatchGameEvent({EVENT:"BONUSCOUNT"});
};
if (m_bPerfectCount){
m_iCurPerfect = (m_iCurPerfect - 1000);
addScore(1000);
if (m_iCurPerfect <= 0){
m_iCurPerfect = 0;
m_bPerfectCount = false;
skxScheduler.schedule(dispatchGameEvent, 250, null, {EVENT:"PERBLUR"});
goToState("TIMEBONUS", 500);
};
dispatchGameEvent({EVENT:"PERFECTCOUNT"});
};
}
public function getPercCleared():int{
var _local1:Number;
_local1 = ((getQBCount() - getLiveQBCount()) / getQBCount());
_local1 = (_local1 * 100);
return (int(_local1));
}
private function preLevel():void{
m_QBCount = m_LiveQB;
m_bGameStarted = true;
WINDOW.setSpeed(25);
dispatchGameEvent({EVENT:"FRAMERATE", SPEED:30});
skxScheduler.schedule(startLevel, 2000);
m_tForceCheckTimer.addEventListener(TimerEvent.TIMER, forceCheckBoardMoves);
m_tForceCheckTimer.start();
}
public function getPowerMoves():Number{
return (m_nPowerMoves);
}
public function setMusicType():void{
var _local1:int;
var _local2:int;
_local1 = skxRandom.getRandomInt(0, 4);
_local2 = 0;
switch (m_sMusicType){
case "B":
_local2 = 1;
break;
case "C":
_local2 = 2;
break;
case "D":
_local2 = 3;
break;
};
while (_local1 == _local2) {
_local1 = skxRandom.getRandomInt(0, 4);
};
switch (_local1){
case 0:
m_sMusicType = "A";
break;
case 1:
m_sMusicType = "B";
break;
case 2:
m_sMusicType = "C";
break;
case 3:
m_sMusicType = "D";
break;
};
}
public function getStageHSData():Array{
var _local1:Array;
_local1 = new Array();
return (_local1);
}
public function removeColumns():void{
var _local1:Array;
var _local2:int;
var _local3:int;
var _local4:QBeez;
var _local5:int;
var _local6:Boolean;
if (m_bShifting){
return;
};
_local1 = new Array();
m_iSlidingCount = 0;
_local2 = 0;
_local3 = 0;
_local4 = null;
m_bShifting = true;
_local2 = 0;
while (_local2 < m_iBoardSize) {
_local6 = true;
_local3 = (m_iBoardSize - 1);
while (_local3 >= -1) {
_local4 = null;
_local4 = getQBee(_local2, _local3);
if (_local4){
_local6 = false;
break;
};
_local3--;
};
if (_local6 == true){
_local1[_local2] = _local2;
};
_local2++;
};
_local5 = 0;
_local2 = (m_iBoardSize - 1);
while (_local2 >= 0) {
if (_local1[_local2] > 0){
_local5++;
} else {
if (_local5 > 0){
_local3 = -1;
while (_local3 < m_iBoardSize) {
_local4 = null;
_local4 = getQBee(_local2, _local3);
if (_local4){
_local4.slideBlock(_local5);
setQBee(_local2, _local3);
setQBee((_local2 + _local5), _local3, _local4);
m_iSlidingCount++;
};
_local3++;
};
};
};
_local2--;
};
m_bShifting = false;
}
public function restartLevel():void{
var _local1:Number;
_local1 = Number(getUserData("score"));
if (_local1 != 0){
createScoreText(String(("-" + prettyScore(_local1, false))), (m_oScoreText.x + 25), m_oScoreText.y, _local1, m_oScoreText, true, false);
_local1 = (_local1 * -1);
};
setUserData("totalscore", (getUserData("totalscore") + _local1));
setUserData("stagescore", (getUserData("stagescore") + _local1));
if (getUserData("totalscore") < 0){
setUserData("totalscore", 0);
};
if (getUserData("stagescore") < 0){
setUserData("stagescore", 0);
};
setUserData("score", 0);
m_oScoreText.text = prettyScore(getUserData("totalscore"), false);
}
public function squishCol(_arg1:int):void{
var _local2:int;
var _local3:QBeez;
var _local4:Array;
var _local5:int;
_local2 = 1;
_local3 = null;
_local4 = new Array();
_local5 = 0;
_local5 = (m_iBoardSize - 1);
while (_local5 >= 0) {
_local3 = null;
_local3 = getQBee(_arg1, _local5);
if (_local3){
_local3.hopBlock(_local2);
_local2++;
} else {
break;
};
_local5--;
};
}
private function onMode2Timer(_arg1:Event):void{
if (m_bLowerWater){
m_iGameTime = Math.max((m_iGameTime - 3), 0);
dispatchGameEvent({EVENT:"LOWERWATER"});
if (m_iGameTime <= 0){
m_iGameTime = 0;
m_bLowerWater = false;
m_bGameStarted = false;
m_bStopBar = true;
goToState("STARTNEWGAME", 2000);
};
return;
};
if (m_bPerfectCount){
if (m_iCurPerfect <= 3000){
addScore(m_iCurPerfect);
m_iCurPerfect = 0;
m_bPerfectCount = false;
m_iGameTime = getPercCleared();
dispatchGameEvent({EVENT:"PERBLUR"});
goToState("TIMEBONUS", 50);
} else {
m_iCurPerfect = (m_iCurPerfect - 3000);
addScore(3000);
};
dispatchGameEvent({EVENT:"PERFECTCOUNT"});
};
}
public function onSQTimer(_arg1:Event=null):void{
var _local2:Number;
if (((m_bGameOver) || (m_bLowerWater))){
return;
};
if (skxMusicChannel.getCount() < 4){
_local2 = 0;
if (sGameMode != 3){
if (getGameTime() > 70){
_local2 = 3;
} else {
if (getGameTime() > 45){
_local2 = 2;
} else {
if (getGameTime() > 25){
_local2 = 1;
};
};
};
} else {
switch (m_iMusicSegment){
case 3:
_local2 = 1;
break;
case 6:
_local2 = 2;
break;
case 9:
_local2 = 3;
break;
case 12:
_local2 = 0;
m_iMusicSegment = 0;
break;
};
m_iMusicSegment++;
};
if (m_sMusicType == "A"){
switch (_local2){
case 0:
skxMusicChannel.addSound(new MUSA1());
break;
case 1:
skxMusicChannel.addSound(new MUSA2());
break;
case 2:
skxMusicChannel.addSound(new MUSA3());
break;
case 3:
skxMusicChannel.addSound(new MUSA4());
break;
};
} else {
if (m_sMusicType == "B"){
switch (_local2){
case 0:
skxMusicChannel.addSound(new MUSB1());
break;
case 1:
skxMusicChannel.addSound(new MUSB2());
break;
case 2:
skxMusicChannel.addSound(new MUSB3());
break;
case 3:
skxMusicChannel.addSound(new MUSB4());
break;
};
} else {
if (m_sMusicType == "C"){
switch (_local2){
case 0:
skxMusicChannel.addSound(new MUSC1());
break;
case 1:
skxMusicChannel.addSound(new MUSC2());
break;
case 2:
skxMusicChannel.addSound(new MUSC3());
break;
case 3:
skxMusicChannel.addSound(new MUSC4());
break;
};
} else {
if (m_sMusicType == "D"){
switch (_local2){
case 0:
skxMusicChannel.addSound(new MUSD1());
break;
case 1:
skxMusicChannel.addSound(new MUSD2());
break;
case 2:
skxMusicChannel.addSound(new MUSD3());
break;
case 3:
skxMusicChannel.addSound(new MUSD4());
break;
};
};
};
};
};
};
}
public function resetQuest():void{
USERDATA = new Dictionary();
m_iCurrentPackLevel = 0;
m_iCurrentSubLvl = 1;
m_iCurrentLvl = 1;
sQuestFrame = 1;
setUserData("totalscore", 0);
setUserData("score", 0);
setUserData("maxgroup", 0);
setUserData("perfect", 0);
setUserData("stagescore", 0);
setUserData("score", 0);
setUserData("curmaxgroup", 0);
setUserData("curperfect", 0);
}
public function setIsOverSelected(_arg1:Boolean=true):void{
m_bOverSelection = _arg1;
}
public function unPause():void{
m_bStartUnPause = true;
}
public function getIsOverSelected():Boolean{
return (m_bOverSelection);
}
public function getStats():String{
var _local1:String;
_local1 = "";
return (_local1);
}
public function getTimerPassed():Boolean{
return (m_bTimerPassed);
}
public function goToState(_arg1:String, _arg2:int):void{
m_sGoToState = _arg1;
setStateTimerOn(_arg2);
m_stateTimer.start();
}
public function getQBee(_arg1:int, _arg2:int):QBeez{
return (QBEEZGRID[String(((_arg1 + "_") + _arg2))]);
}
public function finishShuffle():void{
if (m_iNumberUpdated == m_LiveQB){
POSITIONS = skxUtil.shuffleArray(POSITIONS);
TEMPPOSITIONS = POSITIONS.slice();
QBeez.sShuffleDispatcher.dispatchEvent(new QBShuffleEvent(QBShuffleEvent.SHUFFLE, true));
};
}
public function addSound(_arg1:String, _arg2):Boolean{
var _local3:Sound;
_local3 = (_arg2 as Sound);
if (_local3){
SOUNDNAMES.push(_arg1);
SOUNDDATA[_arg1] = _local3;
return (true);
};
return (false);
}
public function startTimeBonus():void{
if (!m_bLevelDone){
return;
};
if (m_iShuffleCount == 0){
dispatchGameEvent({EVENT:"NOSHUFFLE"});
};
if (m_iRotateCount == 0){
dispatchGameEvent({EVENT:"NOROTATE"});
};
if (m_iFlipCount == 0){
dispatchGameEvent({EVENT:"NOFLIP"});
};
if (m_iGameTime <= 9){
dispatchGameEvent({EVENT:"TIMEMASTER"});
};
if (m_iGameTime >= 98){
dispatchGameEvent({EVENT:"NARROWESCAPE"});
};
playSound("BOILTALLY", 0, 100);
m_iCurPerfect = 0;
m_bPerfectCount = false;
m_bTimeBonus = true;
setTimerOn(10);
}
public function startLevel():void{
setUserData("score", 0);
if (m_bLoadedGame == false){
dispatchGameEvent({EVENT:"STARTLEVEL"});
startDrop();
};
dispatchGameEvent({EVENT:"NEWGAME"});
onSQTimer();
onSQTimer();
skxMusicChannel.nextSound();
m_sqTimer.start();
m_bPaused = false;
if (sGameMode != 3){
setTimerOn(((TIMEPARAM[getBoardSize()] / 100) * 1000));
} else {
setTimerOn(20);
};
WINDOW.sendState("ALL-UNPAUSE");
WINDOW.Unpause();
sortGrid();
m_bLoadedGame = false;
m_timer.start();
m_watertimer.start();
}
public function pauseGame():void{
m_bPaused = true;
m_timer.stop();
if (m_watertimer){
m_watertimer.stop();
};
WINDOW.Pause();
m_newGameTimer.stop();
m_iPauseBlur = 0;
m_bStartUnPause = false;
m_pauseTimer.start();
m_mcSnapShot.visible = false;
m_mcSnapShot.filters = [];
if (m_SnapShotData){
m_SnapShotData = null;
};
m_SnapShotData = new Bitmap(skxUtil.takeSnapshot(m_Stage, 500, 520));
m_SnapShotData.visible = false;
m_mcSnapShot.addChild(m_SnapShotData);
}
public function initQBeez():void{
var _local1:int;
_local1 = 0;
m_shuffleTimer = new Timer(m_nShuffleDelay);
m_shuffleTimer.addEventListener(TimerEvent.TIMER, onShuffleTimer, false, 0, true);
m_shuffleStopTimer.addEventListener(TimerEvent.TIMER, onShuffleStopTimer, false, 0, true);
m_newGameTimer.addEventListener(TimerEvent.TIMER, onStartNewTimer, false, 0, true);
m_sqTimer.addEventListener(TimerEvent.TIMER, onSQTimer);
m_blurTimer.stop();
m_mcSnapShot.visible = false;
IMAGEDATA = new Dictionary();
_local1 = 1;
while (_local1 < 16) {
IMAGEDATA[_local1] = SIMAGEDATA[_local1].clone(m_nImageScale, m_nImageScale);
_local1++;
};
IMAGEDATA[16] = SIMAGEDATA[16].clone(m_nImageScale, m_nImageScale);
IMAGEDATA[17] = SIMAGEDATA[17].clone(m_nImageScale, m_nImageScale);
IMAGEDATA[38] = SIMAGEDATA[38].clone(m_nImageScale, m_nImageScale);
IMAGEDATA[39] = SIMAGEDATA[39].clone(m_nImageScale, m_nImageScale);
IMAGEDATA[40] = SIMAGEDATA[40].clone(m_nImageScale, m_nImageScale);
IMAGEDATA[41] = SIMAGEDATA[41].clone(m_nImageScale, m_nImageScale);
_local1 = 0;
while (_local1 <= 55) {
m_TypeList[_local1] = 0;
_local1++;
};
if (sSoundOn){
setVolume(1);
} else {
setVolume(0);
};
}
public function checkGameOver():Boolean{
var _local1:int;
if (((m_bMagicChanging) || (m_bMagicMode))){
return (false);
};
_local1 = 0;
if (m_TypeList[16] <= 0){
if (m_LiveQB <= 1){
return (true);
};
} else {
if (m_LiveQB <= 0){
return (true);
};
};
_local1 = 1;
while (_local1 <= 55) {
if ((((m_TypeList[_local1] > 1)) && (((getInfPowerMoves()) || ((getPowerMoves() > 0)))))){
return (false);
};
if ((((m_TypeList[_local1] > 0)) && ((_local1 == 16)))){
return (false);
};
_local1++;
};
if (checkBoardMoves()){
return (false);
};
return (true);
}
public function updateGameState():void{
if (((((checkGameOver()) && (!((m_bGameOver == true))))) && (m_bGameStarted))){
startLevelOverSequence();
};
}
public function setBackground():void{
var _local1:skxImage;
if ((((sGameMode == 0)) && ((getSubLevel() == 1)))){
m_iBGFrame = skxRandom.getRandomInt(1, 15);
_local1 = new skxImage(new Background(), {type:"movie", scalex:sBGScale, scaley:sBGScale, width:800, height:600, copyframes:[m_iBGFrame], r:1, g:1, b:1});
WINDOW.setBackground(_local1);
} else {
if (((!((sGameMode == 0))) && ((getSubLevel() == 1)))){
if (sGameMode == 2){
m_iBGFrame = skxRandom.getRandomInt(1, 15);
} else {
m_iBGFrame = 0;
};
_local1 = new skxImage(new Background(), {type:"movie", scalex:sBGScale, scaley:sBGScale, width:800, height:600, copyframes:[m_iBGFrame], r:1, g:1, b:1});
WINDOW.setBackground(_local1);
};
};
}
public function getSel():Array{
return (SELECTED);
}
public function levelUp():void{
m_iCurrentPackLevel++;
m_iCurrentSubLvl++;
}
public function getLevelInt(_arg1:String):int{
switch (_arg1){
case "=":
return (40);
case "h":
return (getBombType(6));
case "i":
return (getBombType(8));
case "j":
return (getBombType(15));
case "k":
return (getBombType(9));
case "l":
return (getBombType(4));
case "m":
return (getBombType(13));
case "n":
return (getBombType(12));
case "q":
return (getBombType(10));
case "s":
return (getBombType(5));
case "t":
return (getBombType(7));
case "u":
return (getBombType(11));
case "v":
return (getBombType(1));
case "@":
return (getBombType(2));
case "&":
return (getBombType(3));
case "%":
return (getBombType(14));
case "O":
return (41);
case "M":
return (42);
case "N":
return (43);
case "E":
return (44);
case "*":
return (45);
case "A":
return (46);
case "J":
return (47);
case "C":
return (48);
case "D":
return (49);
case "H":
return (50);
case "K":
return (51);
case "G":
return (52);
case "F":
return (53);
case "L":
return (54);
case "B":
return (55);
case "<":
return (16);
case "o":
return (10);
case "g":
return (15);
case "r":
return (5);
case "b":
return (9);
case "c":
return (4);
case "z":
return (2);
case "e":
return (7);
case "d":
return (12);
case "y":
return (6);
case "p":
return (11);
case "a":
return (8);
case "w":
return (13);
case "f":
return (1);
case "x":
return (3);
case "$":
return (14);
case "?":
return (getLevelInt(m_QBColorSet[skxRandom.getRandomInt(0, m_QBColorSet.length)]));
default:
return (getLevelInt(m_QBColorSet[skxRandom.getRandomInt(0, m_QBColorSet.length)]));
};
}
public function setTimerOn(_arg1:Number):void{
if (_arg1 <= 0){
return;
};
if (!m_timer){
m_timer = new Timer(_arg1);
m_timer.start();
} else {
m_timer.delay = _arg1;
};
if (sGameMode != 3){
m_timer.addEventListener(TimerEvent.TIMER, onTimer);
} else {
m_timer.addEventListener(TimerEvent.TIMER, onMode2Timer);
};
}
public function removeBlanks():void{
var _local1:int;
var _local2:Array;
var _local3:QBeez;
var _local4:int;
var _local5:int;
var _local6:int;
var _local7:int;
var _local8:int;
if (((m_bMoving) || (m_bShifting))){
return;
};
_local1 = 0;
_local2 = new Array();
_local3 = null;
_local4 = 0;
m_bShifting = true;
_local5 = 0;
while (_local5 < m_iBoardSize) {
_local6 = 0;
_local7 = 0;
_local8 = (m_iBoardSize - 1);
while (_local8 >= -1) {
_local3 = getQBee(_local5, _local8);
if (_local3 == null){
_local6++;
} else {
if (_local6 > 0){
_local7++;
_local3.dropBlock(_local6, _local7);
_local1++;
_local2.push(_local3);
setQBee(_local5, (_local8 + _local6), _local3);
};
};
_local8--;
};
_local4 = -1;
while (_local4 < (_local6 - 1)) {
setQBee(_local5, _local4);
_local4++;
};
_local5++;
};
m_bShifting = false;
}
public function startPerfectCountDown():void{
if (!m_bLevelDone){
return;
};
playSound("TAHDAH");
dispatchGameEvent({EVENT:"PERFECT"});
skxScheduler.schedule(playSound, 1500, null, "POINTS");
goToState("PERFECTCOUNT", 1500);
}
public function getBoardSize():int{
return (m_iBoardSize);
}
public function getGameTime():int{
return (m_iGameTime);
}
public function updateStats():void{
}
public function getGameOver():Boolean{
return (m_bGameOver);
}
public function magicZap(_arg1:QBeez):void{
var c:int;
var r:int;
var q:QBeez;
var shot:MovieClip;
var g:int;
var b:int;
var bc:ColorTransform;
var f:Function;
var d:Number;
var t:Number;
var angle:Number;
var qb = _arg1;
c = 0;
r = 0;
q = null;
c = 0;
while (c < m_iBoardSize) {
r = (m_iBoardSize - 1);
while (r >= -1) {
q = getQBee(c, r);
if (q){
q.setColorOffset(0, 0, 0);
};
r = (r - 1);
};
c = (c + 1);
};
m_bMagicChanging = true;
m_bMagicMode = false;
playSound("MAGICSHOT");
shot = new NEWHATZMAGIC();
r = 0;
g = 0;
b = 0;
switch (m_iMagicType){
case 1:
r = 253;
g = 171;
b = 252;
break;
case 2:
r = 5;
g = 5;
b = 5;
break;
case 3:
r = 150;
g = 150;
b = 150;
break;
case 4:
r = 112;
g = 183;
b = 254;
break;
case 5:
r = 0xFF;
g = 0;
b = 0;
break;
case 6:
r = 0xFF;
g = 0xFF;
b = 0;
break;
case 7:
r = 116;
g = 1;
b = 1;
break;
case 8:
r = 2;
g = 141;
b = 1;
break;
case 9:
r = 1;
g = 98;
b = 216;
break;
case 10:
r = 243;
g = 134;
b = 1;
break;
case 11:
r = 120;
g = 0;
b = 167;
break;
case 12:
r = 153;
g = 102;
b = 0;
break;
case 13:
r = 250;
g = 250;
b = 250;
break;
case 14:
r = 0xFF;
g = 0;
b = 212;
break;
case 15:
r = 5;
g = 254;
b = 5;
break;
};
bc = shot.transform.colorTransform;
bc.redMultiplier = (r / 0xFF);
bc.greenMultiplier = (g / 0xFF);
bc.blueMultiplier = (b / 0xFF);
shot.transform.colorTransform = bc;
shot.x = 150;
shot.y = 390;
shot.rotation = 330;
f = function ():void{
playSound("MAGICCOLOR");
WINDOW.parent.removeChild(shot);
getCircleQBeez(qb);
m_bMagicChanging = false;
m_bMagicMode = false;
m_iMagicSize = 0;
m_iMagicType = 0;
dispatchGameEvent({EVENT:"MAGICDONE"});
f = null;
};
d = skxUtil.getDistance(shot.x, shot.y, qb.x, qb.y);
t = (d / 10);
shot.scaleX = Math.max(2, (1 + (m_iMagicSize / 10)));
shot.scaleY = Math.max(2, (1 + (m_iMagicSize / 10)));
angle = Math.atan2((shot.y - qb.y), (shot.x - qb.x));
shot.rotation = (((angle * 180) / Math.PI) - 180);
shot.gotoAndPlay(1);
WINDOW.parent.addChild(shot);
skxUtil.moveTo(shot, t, 12, qb.x, qb.y, f);
WINDOW.parent.removeEventListener(MouseEvent.MOUSE_MOVE, scareCircle);
m_oMover.stopDrag();
WINDOW.parent.removeChild(m_oMover);
m_oMover = null;
}
public function getQBCount():int{
return (m_iQBCount);
}
public function setIsShifting(_arg1:Boolean=true):void{
m_bShifting = _arg1;
}
public function shuffleBoard():void{
var _local1:int;
var _local2:int;
if ((((((((((((((getInfPowerMoves() == false)) && ((getPowerMoves() < 1)))) || (m_bShifting))) || (m_bGameOver))) || (m_bMoving))) || (m_bMagicChanging))) || (m_bMagicMode))){
return;
};
m_iShuffleCount++;
_local1 = 0;
_local2 = 0;
_local1 = 1;
while (_local1 <= 55) {
if (m_TypeList[_local1] > 0){
_local2++;
};
_local1++;
};
if (_local2 <= 1){
return;
};
playSound(String(("RANDOM" + skxRandom.getRandomInt(1, 5))), 0, 1, true);
m_bShifting = true;
m_bShuffling = true;
POSITIONS = new Array();
TEMPPOSITIONS = new Array();
m_iNumberUpdated = 0;
QBeez.sShuffleDispatcher.dispatchEvent(new QBShuffleEvent(QBShuffleEvent.SHUFFLE, false));
m_shuffleTimer.start();
m_shuffleStopTimer.start();
if (!getInfPowerMoves()){
m_nPowerMoves--;
};
}
public function loadQuestMode():void{
var _local1:String;
var _local2:Array;
if (!questSaveExists()){
return;
};
_local1 = String(skxUser.getCurData("questsave"));
_local2 = _local1.split("-");
if (_local2[1]){
sDailySeed = Number(_local2[1]);
};
if (_local2[2]){
m_iCurrentLvl = Number(_local2[2]);
};
if (_local2[3]){
m_iCurrentSubLvl = Number(_local2[3]);
};
if (_local2[4]){
setUserData("curperfect", Number(_local2[4]));
};
if (_local2[5]){
setUserData("curmaxgroup", Number(_local2[5]));
};
if (_local2[6]){
setUserData("stagescore", Number(_local2[6]));
};
if (_local2[7]){
setUserData("perfect", Number(_local2[7]));
};
if (_local2[8]){
setUserData("maxgroup", Number(_local2[8]));
};
if (_local2[9]){
setUserData("totalscore", Number(_local2[9]));
};
if (_local2[10]){
sQuestFrame = Number(_local2[10]);
};
if (_local2[11]){
m_iGameTime = Number(_local2[11]);
};
if (_local2[12]){
m_iBGFrame = Number(_local2[12]);
};
if (_local2[13]){
m_nPowerMoves = Number(_local2[13]);
};
if (_local2[14]){
m_sLoadedLevel = String(_local2[14]);
};
}
public function getIsShifting():Boolean{
return (m_bShifting);
}
public function sendStageHSData(_arg1:Array):void{
}
public function loadXML(_arg1:String):void{
var _local2:URLLoader;
_local2 = new URLLoader();
_local2.load(new URLRequest(_arg1));
_local2.addEventListener(Event.COMPLETE, onXMLLoaded);
}
public function startGame():void{
var _local1:int;
var _local2:int;
var _local3:Number;
var _local4:int;
var _local5:int;
var _local6:int;
var _local7:QBeez;
var _local8:Array;
skxDisplay.Print("Play 1");
WINDOW.filters = [];
skxSoundChannel.clearAll();
setGameParam();
clearBoard();
stopAllSound();
setTimerOff();
_local1 = 0;
m_bStopBar = false;
m_bTimerPassed = false;
m_bTimeBonus = false;
m_bPaused = true;
m_bDrown = false;
m_bTimeBonus = false;
m_bPerfectCount = false;
m_bLevelDone = false;
m_iGameTime = 0;
m_nPowerMoves = 3;
m_bLowerWater = false;
m_bGameOver = false;
m_bGameOverCountdown = false;
bSortAfterSlide = false;
m_bMagicChanging = false;
m_bMagicMode = false;
SELECTED = new Array();
QBEEZGRID = new Dictionary();
TEMPGRID = new Dictionary();
POSITIONS = new Array();
TEMPPOSITIONS = new Array();
m_iNumberUpdated = 0;
m_LiveQB = 0;
m_TypeCount = 0;
m_TypeList = new Dictionary();
QBeez.sRotDispatcher = new EventDispatcher();
QBeez.sFlipDispatcher = new EventDispatcher();
QBeez.sShuffleDispatcher = new EventDispatcher();
if (m_iCurrentLvl == 0){
m_iCurrentLvl = 1;
};
if (m_iCurrentSubLvl == 0){
m_iCurrentSubLvl = 1;
};
_local2 = LVLCOUNTPARAM[m_iCurrentLvl][(m_iCurrentSubLvl - 1)];
m_sDiff = "MED";
_local3 = ((750 / _local2) * m_nScaleFactor);
m_nQBScale = (_local3 * 0.6);
m_iBoardSize = _local2;
m_iQBCount = (_local2 * _local2);
_local4 = 0;
_local5 = 0;
_local6 = 0;
_local7 = null;
m_nFallScale = (m_nQBScale / WINDOW.m_iScrHeight);
m_nImageScale = (_local3 / 100);
m_nStartLocX = ((m_nBoardOffsetX - (m_nQBScale * (_local2 - 1))) - (m_nQBScale / 2));
m_nStartLocY = ((m_nGroundLine - (m_nQBScale * (_local2 - 1))) - (m_nQBScale / 2));
dispatchGameEvent({EVENT:"PRELEVEL"});
skxDisplay.Print("Play 4");
_local8 = generareLevel((_local2 * _local2));
setBackground();
initQBeez();
setMusicType();
_local4 = 0;
_local1 = 0;
while (_local4 < _local2) {
_local5 = (_local2 - 1);
while (_local5 >= 0) {
_local6 = _local8[_local1];
_local7 = new QBeez();
_local7.x = (m_nStartLocX + (_local4 * m_nQBScale));
_local7.y = ((m_nStartLocY + (_local5 * m_nQBScale)) - 600);
_local7.qbType = _local6;
_local7.sColor = getColor(_local7.qbType);
_local7.name = String(_local1);
_local7.setGameHandler(this);
_local7 = setPiece(_local7);
m_TypeList[_local7.qbType] = (m_TypeList[_local7.qbType] + 1);
WINDOW.addObject(_local7);
setQBee(_local4, _local5, _local7);
_local7.Init();
m_LiveQB++;
_local5--;
_local1++;
};
_local4++;
};
m_bLoadedGame = false;
preLevel();
}
public function getColorSet(_arg1):Array{
var _local2:Array;
var _local3:int;
_local2 = new Array();
_local3 = 0;
while (_local2.length < _arg1) {
_local3 = skxRandom.getRandomInt(1, 15);
if (_local2.indexOf(_local3) == -1){
_local2.push(_local3);
};
};
return (_local2);
}
private function onShuffleStopTimer(_arg1:Event=null):void{
m_nShuffleCountPos = 0;
m_bShifting = false;
m_bShuffling = false;
m_shuffleTimer.stop();
m_shuffleStopTimer.stop();
updateGameState();
}
private function setGameParam():void{
ITEMPARAM = new Dictionary();
LVLCOUNTPARAM = new Dictionary();
if ((((sGameMode == 0)) || ((sGameMode == 3)))){
COLORPARAM[1] = [3, 3, 3, 3, 3, 3];
COLORPARAM[2] = [3, 3, 3, 3, 4, 4];
COLORPARAM[3] = [3, 3, 3, 4, 4, 4];
COLORPARAM[4] = [3, 4, 4, 4, 4, 4];
COLORPARAM[5] = [4, 4, 4, 4, 4, 4];
COLORPARAM[6] = [4, 4, 4, 4, 4, 4];
COLORPARAM[7] = [4, 4, 4, 5, 5, 5];
COLORPARAM[8] = [4, 4, 5, 5, 5, 5];
COLORPARAM[9] = [4, 5, 5, 5, 5, 5];
COLORPARAM[10] = [5, 5, 5, 5, 5, 5];
LVLCOUNTPARAM[1] = [5, 6, 7, 8, 9, 10];
LVLCOUNTPARAM[2] = [6, 7, 8, 9, 10, 11];
LVLCOUNTPARAM[3] = [7, 8, 9, 10, 11, 12];
LVLCOUNTPARAM[4] = [8, 9, 10, 11, 12, 13];
LVLCOUNTPARAM[5] = [8, 10, 11, 12, 13, 14];
LVLCOUNTPARAM[6] = [8, 11, 12, 13, 14, 15];
LVLCOUNTPARAM[7] = [9, 11, 13, 14, 15, 16];
LVLCOUNTPARAM[8] = [9, 12, 14, 15, 16, 17];
LVLCOUNTPARAM[9] = [9, 12, 15, 16, 17, 18];
LVLCOUNTPARAM[10] = [10, 12, 13, 14, 17, 18];
ITEMPARAM[1] = ["none"];
ITEMPARAM[2] = ["2bomb"];
ITEMPARAM[3] = ["brush"];
ITEMPARAM[4] = ["2bomb", "brush"];
ITEMPARAM[5] = ["2bomb", "brush", "brush"];
ITEMPARAM[6] = ["2bomb", "brush", "2bomb"];
ITEMPARAM[7] = ["2bomb", "brush", "2bomb", "2bomb"];
ITEMPARAM[8] = ["2bomb", "brush", "2bomb", "2bomb"];
ITEMPARAM[9] = ["2bomb", "brush", "2bomb", "2bomb"];
ITEMPARAM[10] = ["2bomb", "brush", "2bomb", "2bomb"];
} else {
if (sGameMode == 1){
LVLCOUNTPARAM[1] = [6, 12, 18];
COLORPARAM[1] = [3, 4, 5];
ITEMPARAM[1] = ["none"];
ITEMPARAM[2] = ["2bomb"];
ITEMPARAM[3] = ["brush", "brush", "2bomb"];
} else {
if (sGameMode == 2){
LVLCOUNTPARAM[1] = [6, 8, 10, 12, 13, 14, 15, 16, 17, 18];
COLORPARAM[1] = [3, 3, 3, 4, 4, 4, 4, 5, 5, 5];
ITEMPARAM[1] = ["none"];
ITEMPARAM[2] = ["2bomb"];
ITEMPARAM[3] = ["brush"];
ITEMPARAM[4] = ["2magic"];
ITEMPARAM[5] = ["2bomb", "brush"];
ITEMPARAM[6] = ["2bomb", "brush"];
ITEMPARAM[7] = ["2bomb", "brush", "2bomb"];
ITEMPARAM[8] = ["2bomb", "brush", "2magic"];
ITEMPARAM[9] = ["2bomb", "brush", "2bomb", "2magic"];
ITEMPARAM[10] = ["2bomb", "brush", "2magic", "brush"];
};
};
};
}
public function createScoreText(_arg1:String, _arg2:Number, _arg3:Number, _arg4:Number, _arg5=null, _arg6:Boolean=false, _arg7:Boolean=true):void{
var _local8:QBScoreText;
if (_arg5 == null){
_local8 = new QBScoreText(_arg1, _arg2, _arg3, _arg4, m_TextExample);
} else {
_local8 = new QBScoreText(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7);
};
m_Stage.addChild(_local8);
}
public function incMoves():void{
}
private function setTimeParam():void{
TIMEPARAM[4] = int((16 * 1.5));
TIMEPARAM[5] = int((32 * 1.5));
TIMEPARAM[6] = int((38 * 1.5));
TIMEPARAM[7] = int((45 * 1.5));
TIMEPARAM[8] = int((52 * 1.5));
TIMEPARAM[9] = int((59 * 1.5));
TIMEPARAM[10] = int((65 * 1.5));
TIMEPARAM[11] = int((72 * 1.5));
TIMEPARAM[12] = int((79 * 1.5));
TIMEPARAM[13] = int((86 * 1.5));
TIMEPARAM[14] = int((92 * 1.5));
TIMEPARAM[15] = int((99 * 1.5));
TIMEPARAM[16] = int((106 * 1.5));
TIMEPARAM[17] = int((112 * 1.5));
TIMEPARAM[18] = int((119 * 1.5));
TIMEPARAM[19] = int((126 * 1.5));
TIMEPARAM[20] = int((133 * 1.5));
TIMEPARAM[21] = int((139 * 1.5));
TIMEPARAM[22] = int((146 * 1.5));
TIMEPARAM[23] = int((153 * 1.5));
TIMEPARAM[24] = int((160 * 1.5));
TIMEPARAM[25] = int((166 * 1.5));
TIMEPARAM[26] = int((173 * 1.5));
TIMEPARAM[27] = int((180 * 1.5));
TIMEPARAM[28] = int((187 * 1.5));
TIMEPARAM[29] = int((193 * 1.5));
TIMEPARAM[30] = int((200 * 1.5));
TIMEPARAM[31] = int((139 * 1.5));
TIMEPARAM[32] = int((146 * 1.5));
TIMEPARAM[33] = int((153 * 1.5));
TIMEPARAM[34] = int((160 * 1.5));
TIMEPARAM[35] = int((166 * 1.5));
TIMEPARAM[36] = int((173 * 1.5));
TIMEPARAM[37] = int((180 * 1.5));
TIMEPARAM[38] = int((187 * 1.5));
TIMEPARAM[39] = int((193 * 1.5));
TIMEPARAM[40] = int((200 * 1.5));
}
public function getUserData(_arg1:String){
if (USERDATA[_arg1]){
return (USERDATA[_arg1]);
};
return (0);
}
private function onShuffleTimer(_arg1:Event):void{
if (!m_bGameOver){
m_nShuffleCountPos++;
TEMPPOSITIONS = skxUtil.shuffleArray(TEMPPOSITIONS);
POSITIONS = TEMPPOSITIONS.slice();
if (m_bForceSort){
m_bShifting = false;
sortGrid();
m_bForceSort = false;
m_bShifting = true;
};
QBeez.sShuffleDispatcher.dispatchEvent(new QBShuffleEvent(QBShuffleEvent.SHUFFLE, true));
} else {
onShuffleStopTimer();
};
}
public function getPrelevelInfo():String{
if (sGameMode != 3){
return (String((getTimeCount() + " Seconds\n to finish this level.")));
};
return (String("Remove 95% of the QBeez."));
}
public function getIsMoving():Boolean{
return (m_bMoving);
}
public function clearData():void{
var _local1:int;
_local1 = 0;
_local1 = 1;
while (_local1 < 40) {
if (IMAGEDATA[_local1]){
IMAGEDATA[_local1].dispose();
IMAGEDATA[_local1] = null;
};
_local1++;
};
m_iShuffleCount = 0;
m_iRotateCount = 0;
m_iFlipCount = 0;
m_bMagicChanging = false;
m_bMagicMode = false;
m_aLevels = null;
WINDOW.clearObjects();
if (WINDOW.parent){
WINDOW.parent.removeEventListener(MouseEvent.MOUSE_MOVE, scareCircle);
};
if (m_oMover){
m_oMover.stopDrag();
if (((WINDOW.parent) && (WINDOW.parent.contains(m_oMover)))){
WINDOW.parent.removeChild(m_oMover);
};
m_oMover = null;
};
SELECTED = new Array();
QBEEZGRID = new Dictionary(false);
TEMPGRID = new Dictionary(false);
POSITIONS = new Array();
TEMPPOSITIONS = new Array();
m_TypeList = new Dictionary();
m_nStartLocY = 0;
m_nStartLocX = 0;
m_bLoadedGame = false;
m_timer = new Timer(1000);
m_watertimer = new Timer(25);
m_shuffleStopTimer = new Timer(1000);
m_newGameTimer = new Timer(1000);
m_iCurrentPackLevel = -1;
m_iSelectedPack = -1;
QBPackHandler.m_oAvatar = null;
m_aLevels = null;
skxSoundChannel.clearAll();
stopAllSound();
setTimerOff();
m_bStopBar = false;
m_bTimerPassed = false;
m_bTimeBonus = false;
m_bPaused = true;
m_bGameStarted = true;
m_bDrown = false;
m_bTimeBonus = false;
m_bPerfectCount = false;
m_bLevelDone = false;
m_iGameTime = 0;
m_nPowerMoves = 3;
m_bLowerWater = false;
m_bGameOver = false;
m_bGameOverCountdown = false;
bSortAfterSlide = false;
SELECTED = new Array();
QBEEZGRID = new Dictionary();
TEMPGRID = new Dictionary();
POSITIONS = new Array();
TEMPPOSITIONS = new Array();
m_iNumberUpdated = 0;
m_LiveQB = 0;
m_TypeCount = 0;
m_TypeList = new Dictionary();
QBeez.sRotDispatcher = new EventDispatcher();
QBeez.sFlipDispatcher = new EventDispatcher();
QBeez.sShuffleDispatcher = new EventDispatcher();
LEVELDATA = new Array();
}
public function getTimeCount():int{
return (TIMEPARAM[m_iBoardSize]);
}
public function onOffScreen():void{
}
public function showStats():void{
}
public function getQBScale():Number{
return (m_nQBScale);
}
public function getCurPerfect():String{
return (prettyScore(m_iCurPerfect, false));
}
public function updateGrid():void{
if (m_iNumberUpdated >= m_LiveQB){
QBEEZGRID = TEMPGRID;
m_iNumberUpdated = 0;
sortGrid();
m_bShifting = false;
updateGameState();
};
}
public function getType(_arg1:int):String{
switch (_arg1){
case 40:
return ("STONE");
case 16:
return ("BRUSH");
case 17:
return ("1BOMB");
case 18:
return ("2BOMB");
case 19:
return ("3BOMB");
case 20:
return ("4BOMB");
case 21:
return ("5BOMB");
case 22:
return ("6BOMB");
case 23:
return ("7BOMB");
case 24:
return ("8BOMB");
case 25:
return ("9BOMB");
case 26:
return ("10BOMB");
case 27:
return ("11BOMB");
case 28:
return ("12BOMB");
case 29:
return ("13BOMB");
case 30:
return ("14BOMB");
case 31:
return ("15BOMB");
case 41:
return ("1MAGIC");
case 42:
return ("2MAGIC");
case 43:
return ("3MAGIC");
case 44:
return ("4MAGIC");
case 45:
return ("5MAGIC");
case 46:
return ("6MAGIC");
case 47:
return ("7MAGIC");
case 48:
return ("8MAGIC");
case 49:
return ("9MAGIC");
case 50:
return ("10MAGIC");
case 51:
return ("11MAGIC");
case 52:
return ("12MAGIC");
case 53:
return ("13MAGIC");
case 54:
return ("14MAGIC");
case 55:
return ("15MAGIC");
};
return ("QB");
}
public function setPiece(_arg1:QBeez):QBeez{
if (getType(_arg1.qbType) == "QB"){
_arg1.bPowerUp = false;
_arg1.setImage(IMAGEDATA[_arg1.qbType]);
} else {
if (getType(_arg1.qbType) == "BRUSH"){
_arg1.bPowerUp = true;
_arg1.setImage(IMAGEDATA[16]);
} else {
if ((((_arg1.qbType >= 17)) && ((_arg1.qbType <= 31)))){
_arg1.bPowerUp = true;
_arg1.setImage(IMAGEDATA[17]);
} else {
if ((((_arg1.qbType >= 41)) && ((_arg1.qbType <= 55)))){
_arg1.bPowerUp = true;
_arg1.setImage(IMAGEDATA[41]);
} else {
if (getType(_arg1.qbType) == "STONE"){
_arg1.bPowerUp = true;
_arg1.setImage(IMAGEDATA[40]);
};
};
};
};
};
return (_arg1);
}
public function getColor(_arg1:int):String{
switch (_arg1){
case 1:
return ("GEN2");
case 2:
return ("CHAR");
case 3:
return ("GREY");
case 4:
return ("GEN");
case 5:
return ("RED");
case 6:
return ("YELLOW");
case 7:
return ("GEN");
case 8:
return ("GREEN");
case 9:
return ("BLUE");
case 10:
return ("ORANGE");
case 11:
return ("PURPLE");
case 12:
return ("CHOC");
case 13:
return ("VAN");
case 14:
return ("PINK");
case 15:
return ("GEN");
};
return ("NONE");
}
public function startMagicSequence(_arg1:int, _arg2:int):void{
var rect:Rectangle;
var mc:MovieClip;
var poof:MovieClip;
var rem:Function;
var siz = _arg1;
var typ = _arg2;
if (m_LiveQB <= 0){
checkGameOver();
return;
};
dispatchGameEvent({EVENT:"MAGICREADY"});
if (QBPackHandler.m_oAvatar){
QBPackHandler.m_oAvatar.gotoAndPlay(1, "state_Magical_01:90");
} else {
playSound("MAGICAPPEAR");
if (QBPackHandler.getAvatarPack("QBtar_Magician")){
mc = QBPackHandler.getAvatarPack("QBtar_Magician").swf;
mc.x = 290;
mc.y = 275;
mc.gotoAndPlay(1, "state_Magical_01:90");
poof = new NEWPOOFMAGIC();
skxUtil.playMovieClip(poof, 1, 5, 150);
poof.scaleX = 2;
poof.scaleY = 2;
poof.x = (mc.x - 160);
poof.y = (mc.y + 125);
rem = function ():void{
WINDOW.parent.removeChild(poof);
};
skxScheduler.schedule(rem, 600);
WINDOW.parent.addChild(mc);
WINDOW.parent.addChild(poof);
};
};
m_bMagicMode = true;
m_bMagicChanging = false;
m_iMagicSize = siz;
m_iMagicType = (typ - 40);
m_oMover = new NEWAIMER();
m_oMover.x = -100;
m_oMover.scaleX = 0.35;
m_oMover.scaleY = 0.35;
WINDOW.parent.addEventListener(MouseEvent.MOUSE_MOVE, scareCircle);
rect = new Rectangle(getStartLocX(), getStartLocY(), 490, 490);
m_oMover.startDrag(true, rect);
WINDOW.parent.addChild(m_oMover);
scareCircle();
}
public function setStateTimerOn(_arg1:Number):void{
if (!m_stateTimer){
m_stateTimer = new Timer(_arg1);
m_stateTimer.addEventListener(TimerEvent.TIMER, onStateTimer);
m_stateTimer.start();
} else {
m_stateTimer.addEventListener(TimerEvent.TIMER, onStateTimer);
m_stateTimer.delay = _arg1;
};
}
public function postPauseTimer():void{
if (getPaused()){
if (sSoundOn == true){
setMusicVolume(1);
};
m_bStartUnPause = false;
m_bPaused = false;
m_timer.start();
if (m_watertimer){
m_watertimer.start();
};
WINDOW.Unpause();
WINDOW.sendState("ALL-UNPAUSE");
dispatchGameEvent({EVENT:"UNPAUSE"});
m_mcSnapShot.visible = false;
m_SnapShotData.visible = false;
if (((((m_SnapShotData) && (m_mcSnapShot))) && (m_mcSnapShot.contains(m_SnapShotData)))){
m_mcSnapShot.removeChild(m_SnapShotData);
m_SnapShotData = null;
};
m_iPauseBlur = 0;
m_mcSnapShot.filters = [];
WINDOW.filters = [];
m_pauseTimer.stop();
};
}
public function getInfPowerMoves():Boolean{
return (m_bInfPowerMoves);
}
public function getMagicType(_arg1:int):int{
switch (_arg1){
case 1:
return (41);
case 2:
return (42);
case 3:
return (43);
case 4:
return (44);
case 5:
return (45);
case 6:
return (46);
case 7:
return (47);
case 8:
return (48);
case 9:
return (49);
case 10:
return (50);
case 11:
return (51);
case 12:
return (52);
case 13:
return (53);
case 14:
return (54);
case 15:
return (55);
};
return (-1);
}
public function getGrid():Dictionary{
return (QBEEZGRID);
}
public function getFallScale():Number{
return (m_nFallScale);
}
public function setQBee(_arg1:int, _arg2:int, _arg3:QBeez=null):void{
if (_arg3){
_arg3.xPos = _arg1;
_arg3.yPos = _arg2;
QBEEZGRID[String(((_arg1 + "_") + _arg2))] = _arg3;
} else {
QBEEZGRID[String(((_arg1 + "_") + _arg2))] = null;
};
}
public function getIsSelected():Boolean{
return (m_bSelection);
}
public function getLiveQBCount():int{
return (m_LiveQB);
}
public function setSubLevel(_arg1:int){
m_iCurrentSubLvl = _arg1;
}
public function stopBonusCount():void{
var _local1:Sound;
var _local2:int;
if (!m_bLevelDone){
return;
};
_local1 = (SOUNDDATA["BOILTALLY"] as Sound);
if (_local1){
skxSoundChannel.stopSound(_local1);
};
QBGameHandler.sLastTotalScore = QBGameHandler.sMainHandler.getUserData("totalscore");
dispatchGameEvent({EVENT:"BONUSBLUR"});
m_bTimeBonus = false;
updateStats();
if (m_aLevels){
if (m_iCurrentPackLevel < m_aLevels.length){
goToState("PREWATER", 500);
} else {
goToState("STAGECOMPLETE", 700);
};
} else {
_local2 = 7;
if (sGameMode == 1){
_local2 = 4;
} else {
if (sGameMode == 2){
_local2 = 11;
};
};
if (m_iCurrentSubLvl < _local2){
goToState("PREWATER", 500);
} else {
if ((((_local2 == 4)) || ((_local2 == 11)))){
goToState("GAMEOVERWIN", 700);
} else {
goToState("STAGECOMPLETE", 700);
};
};
};
}
public function getStartLocX():Number{
return (m_nStartLocX);
}
public function getStartLocY():Number{
return (m_nStartLocY);
}
public function setIsSelected(_arg1:Boolean=true):void{
m_bSelection = _arg1;
}
public function setMaxGroup(_arg1:Number):void{
if (_arg1 > getUserData("curmaxgroup")){
setUserData("curmaxgroup", _arg1);
};
if (_arg1 > getUserData("maxgroup")){
setUserData("maxgroup", _arg1);
};
}
public function loadGame():void{
var _local1:int;
var _local2:int;
var _local3:Number;
var _local4:int;
var _local5:int;
var _local6:int;
var _local7:QBeez;
var _local8:int;
var _local9:Array;
var _local10:skxImage;
var _local11:Array;
WINDOW.filters = [];
skxSoundChannel.clearAll();
setGameParam();
clearBoard();
stopAllSound();
setTimerOff();
_local1 = 0;
m_bMagicChanging = false;
m_bMagicMode = false;
m_bStopBar = false;
m_bTimerPassed = false;
m_bTimeBonus = false;
m_bPaused = true;
m_bGameStarted = true;
m_bDrown = false;
m_bTimeBonus = false;
m_bPerfectCount = false;
m_bLevelDone = false;
m_iGameTime = 0;
m_nPowerMoves = 3;
m_bLowerWater = false;
m_bGameOver = false;
m_bGameOverCountdown = false;
bSortAfterSlide = false;
SELECTED = new Array();
QBEEZGRID = new Dictionary();
TEMPGRID = new Dictionary();
POSITIONS = new Array();
TEMPPOSITIONS = new Array();
m_iNumberUpdated = 0;
m_LiveQB = 0;
m_TypeCount = 0;
m_TypeList = new Dictionary();
QBeez.sRotDispatcher = new EventDispatcher();
QBeez.sFlipDispatcher = new EventDispatcher();
QBeez.sShuffleDispatcher = new EventDispatcher();
loadQuestMode();
_local2 = LVLCOUNTPARAM[m_iCurrentLvl][(m_iCurrentSubLvl - 1)];
m_sDiff = "MED";
_local3 = ((750 / _local2) * m_nScaleFactor);
m_nQBScale = (_local3 * 0.6);
m_iBoardSize = _local2;
m_iQBCount = (_local2 * _local2);
_local4 = 0;
_local5 = 0;
_local6 = 0;
_local7 = null;
m_nFallScale = (m_nQBScale / WINDOW.m_iScrHeight);
m_nImageScale = (_local3 / 100);
m_nStartLocX = ((m_nBoardOffsetX - (m_nQBScale * (_local2 - 1))) - (m_nQBScale / 2));
m_nStartLocY = ((m_nGroundLine - (m_nQBScale * (_local2 - 1))) - (m_nQBScale / 2));
dispatchGameEvent({EVENT:"PRELEVEL"});
_local1 = 0;
if (sGameMode == 0){
skxRandom.setSeed((((sDailySeed + getCurrentLevel()) + getSubLevel()) + sGameMode));
} else {
skxRandom.setSeed(((sDailySeed + getCurrentLevel()) + sGameMode));
};
_local8 = COLORPARAM[m_iCurrentLvl][(m_iCurrentSubLvl - 1)];
m_ColorSet = getColorSet(_local8);
m_TypeCount = m_ColorSet.length;
LEVELDATA = new Array();
_local9 = m_sLoadedLevel.split("?");
initQBeez();
setMusicType();
while (_local1 < (_local9.length - 1)) {
_local7 = null;
_local11 = _local9[_local1].split("+");
_local4 = Number(_local11[0]);
_local5 = Number(_local11[1]);
_local6 = Number(_local11[2]);
LEVELDATA.push(_local6);
_local7 = new QBeez();
_local7.x = (m_nStartLocX + (_local4 * m_nQBScale));
_local7.y = (m_nStartLocY + (_local5 * m_nQBScale));
_local7.qbType = _local6;
_local7.sColor = getColor(_local7.qbType);
_local7.visible = true;
_local7.alpha = 1;
_local7.name = String(_local1);
_local7.setGameHandler(this);
_local7 = setPiece(_local7);
m_TypeList[_local7.qbType] = (m_TypeList[_local7.qbType] + 1);
WINDOW.addObject(_local7);
setQBee(_local4, _local5, _local7);
_local7.Init();
m_LiveQB++;
_local1++;
};
_local10 = new skxImage(new Background(), {type:"movie", scalex:sBGScale, scaley:sBGScale, width:800, height:600, copyframes:[m_iBGFrame], r:1, g:1, b:1});
WINDOW.setBackground(_local10);
m_oScoreText.text = prettyScore(getUserData("totalscore"), false);
m_QBCount = m_LiveQB;
m_bGameStarted = true;
WINDOW.setSpeed(25);
dispatchGameEvent({EVENT:"FRAMERATE", SPEED:30});
m_bLoadedGame = true;
QBGameHandler.sQuestFrame = getStageNode(m_iCurrentLvl);
startLevel();
}
public static function savedInMap():Boolean{
var _local1:String;
var _local2:Array;
_local1 = String(skxUser.getCurData("questsave"));
_local2 = _local1.split("-");
if (((_local2[0]) && ((_local2[0] == "0")))){
return (true);
};
return (false);
}
public static function questSaveExists():Boolean{
if (skxUser.getCurData("questsave") == null){
return (false);
};
if (skxUser.getCurData("questsave") == "null"){
return (false);
};
if (skxUser.getCurData("questsave") == "none"){
return (false);
};
return (true);
}
public static function questStarted():Boolean{
var _local1:String;
var _local2:Array;
_local1 = String(skxUser.getCurData("questsave"));
_local2 = _local1.split("-");
if (((((((_local2[2]) && (!((String(_local2[2]) == "0"))))) && (_local2[3]))) && (!((String(_local2[3]) == "0"))))){
return (true);
};
return (false);
}
public static function gameEvent(_arg1:Object):void{
sNewGameDispatcher.dispatchEvent(new QBGameEvent(QBGameEvent.GAME, _arg1));
}
public static function prettyScore(_arg1:int, _arg2:Boolean=true):String{
var _local3:String;
var _local4:String;
var _local5:int;
var _local6:int;
var _local7:String;
if ((((_arg1 <= 0)) && (_arg2))){
return ("-100");
};
_local3 = String(_arg1);
_local4 = "";
_local5 = (_local3.length - 3);
_local6 = 0;
_local7 = _local3.substr(_local5, 3);
_local5 = (_local3.length - 1);
while (_local5 >= 0) {
_local7 = _local3.substr(_local5, 1);
if (_local6 == 3){
_local6 = 0;
_local4 = ("," + _local4);
};
_local4 = (_local7 + _local4);
_local5--;
_local6++;
};
return (_local4);
}
public static function initImageMaps(_arg1:Number=500, _arg2:Number=500):void{
var _local3:int;
WINDOW = new QBWindow(_arg1, _arg2);
m_mcReference = new NEWQB();
m_mcBrushRef = new NEWBRUSH();
m_mcBombRef = new NEWBOMB();
m_mcHatsRef = new NEWHATZ();
m_mcExplosion = new Explosion();
m_mcReference.gotoAndStop(1);
_local3 = 1;
_local3 = 1;
while (_local3 < 16) {
SIMAGEDATA[_local3] = new skxImage(m_mcReference, {type:"bitmap", width:400, height:400, col:5, row:5, frames:23, scalex:1, scaley:1, mcframe:_local3, r:1, g:1, b:1});
_local3++;
};
SIMAGEDATA[16] = new skxImage(m_mcBrushRef, {type:"bitmap", width:320, height:80, col:4, row:1, frames:4, scalex:1, scaley:1, r:1, g:1, b:1});
SIMAGEDATA[17] = new skxImage(m_mcBombRef, {type:"bitmap", width:480, height:640, col:6, row:8, frames:48, scalex:1, scaley:1, r:1, g:1, b:1});
SIMAGEDATA[39] = new skxImage(m_mcExplosion, {type:"bitmap", width:320, height:160, col:4, row:2, frames:8, scalex:1, scaley:1, r:1, g:1, b:1});
SIMAGEDATA[40] = new skxImage(new NEWSTONE(), {type:"movie", width:80, height:80, frames:11, scalex:1, scaley:1, r:1, g:1, b:1});
SIMAGEDATA[38] = new skxImage(new NEWBOMBglow(), {type:"bitmap", width:480, height:160, col:6, row:2, frames:12, scalex:1, scaley:1, r:1, g:1, b:1});
SIMAGEDATA[41] = new skxImage(m_mcHatsRef, {type:"bitmap", width:480, height:640, col:6, row:8, frames:48, scalex:1, scaley:1, r:1, g:1, b:1});
}
public static function getStageNode(_arg1):int{
switch (_arg1){
case 1:
return (1);
case 2:
return (17);
case 3:
return (45);
case 4:
return (69);
case 5:
return (92);
case 6:
return (123);
case 7:
return (153);
case 8:
return (180);
case 9:
return (214);
case 10:
return (242);
};
return (1);
}
}
}//package QBeezSrc
Section 123
//QBPackHandler (QBeezSrc.QBPackHandler)
package QBeezSrc {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
import flash.media.*;
import skxSource.*;
import com.whirled.*;
import flash.net.*;
public class QBPackHandler {
private static var s_iPacksLoaded:int = 0;
private static var s_oGamePacks:Array = new Array();
private static var s_iAvatarsLoaded:int = 0;
private static var s_iLevelsLoaded:int = 0;
public static var m_oAvatar:MovieClip = null;
public static var m_sAvatarState:String = "";
private static var s_iPackCount:int = 0;
public static var s_oLevelPacks:Dictionary = new Dictionary();
public static var s_aPurchasedPacks:Array = null;
private static var m_dStates:Dictionary;
public static var m_iStatePos:int = 0;
private static var s_oAvatarPacks:Array = new Array();
public static function getPackCount():int{
return (s_iPackCount);
}
public static function getGamePacks():Array{
return (s_oGamePacks);
}
public static function doneLoadingPacks():Boolean{
if (s_iPacksLoaded >= s_iPackCount){
return (true);
};
return (false);
}
public static function getLevelPackCount():int{
return (s_iLevelsLoaded);
}
public static function loadLevelsPacks():void{
var _local1:Object;
s_iPacksLoaded = 0;
s_iLevelsLoaded = 0;
s_iAvatarsLoaded = 0;
for each (_local1 in s_oLevelPacks) {
if (_local1){
buildLevelPack(getMediaURL(_local1.ident), String(_local1.ident), _local1.premium);
};
};
}
public static function getLevelPack(_arg1:String){
var _local2:int;
_local2 = 0;
while (_local2 < s_oGamePacks.length) {
if (((s_oGamePacks[_local2]) && ((s_oGamePacks[_local2].name == _arg1)))){
return (s_oGamePacks[_local2]);
};
_local2++;
};
_local2 = 0;
while (_local2 < s_oAvatarPacks.length) {
if (((s_oAvatarPacks) && ((s_oAvatarPacks[_local2].name == _arg1)))){
return (s_oAvatarPacks[_local2]);
};
_local2++;
};
return (null);
}
public static function buildAvatarStates(_arg1:String):void{
var _local2:String;
var _local3:Array;
var _local4:int;
var _local5:Array;
_local2 = _arg1.replace(/\s/g, "");
_local3 = _local2.split(",");
m_dStates = new Dictionary();
_local4 = 0;
while (_local4 < _local3.length) {
if (_local3[_local4]){
_local5 = _local3[_local4].split("=");
if (_local5.length == 2){
if (String(_local5[1]).split("-").length > 1){
m_dStates[String(_local5[0])] = String(_local5[1]).split("-");
} else {
m_dStates[String(_local5[0])] = String(_local5[1]);
};
} else {
skxDisplay.Print("ERROR: Wrong number of = delimeters. Should be 1. ");
};
};
_local4++;
};
}
public static function init(_arg1:Array, _arg2:Array):void{
var _local3:Object;
updatePurchased(_arg2);
s_iPackCount = 0;
for each (_local3 in _arg1) {
s_iPackCount++;
if (_local3.ident){
s_oLevelPacks[_local3.ident] = _local3;
};
};
}
public static function updatePurchased(_arg1:Array):void{
s_aPurchasedPacks = _arg1;
}
public static function sortLevelPacks():void{
s_oGamePacks.sortOn("order", Array.NUMERIC);
}
public static function getMediaURL(_arg1:String):String{
if (s_oLevelPacks[_arg1]){
return (s_oLevelPacks[_arg1].mediaURL);
};
return (null);
}
public static function getAvatarPackCount():int{
return (s_iAvatarsLoaded);
}
public static function getAvatarPack(_arg1:String){
var _local2:int;
_local2 = 0;
while (_local2 < s_oAvatarPacks.length) {
if (((s_oAvatarPacks[_local2]) && ((s_oAvatarPacks[_local2].name == _arg1)))){
skxDisplay.Print(String("avatar found"));
return (s_oAvatarPacks[_local2]);
};
_local2++;
};
return (null);
}
public static function getAvatarPacks():Array{
return (s_oAvatarPacks);
}
private static function buildLevelPack(_arg1:String, _arg2:String, _arg3:int):void{
var pckLoader:Loader;
var onPckLoaded:Function;
var url = _arg1;
var id = _arg2;
var bprem = _arg3;
pckLoader = new Loader();
pckLoader.load(new URLRequest(url));
onPckLoaded = function (_arg1:Event):void{
var _local2:Array;
var _local3:MovieClip;
var _local4:int;
var _local5:String;
var _local6:Array;
var _local7:int;
var _local8:String;
var _local9:String;
var _local10:String;
var _local11:String;
var _local12:Boolean;
var _local13:String;
var _local14:String;
var _local15:MovieClip;
var _local16:*;
var _local17:Array;
if (((_arg1.target) && (_arg1.target.content))){
_local2 = new Array();
_local3 = MovieClip(_arg1.target.content);
_local4 = 1;
_local3.gotoAndStop(1);
if (_local3.getChildByName(String("level_1"))){
while (_local3.getChildByName(String(("level_" + _local4)))) {
_local16 = (_local3.getChildByName(String(("level_" + _local4))) as TextField);
if (_local16){
_local2.push(String(_local16.text));
};
_local4++;
};
_local5 = _local3.LevelInfo.text;
_local6 = _local5.split(",");
_local7 = 1;
_local8 = "";
_local9 = "";
_local10 = "";
_local11 = "";
_local4 = 0;
while (_local4 < _local6.length) {
if (_local6[_local4]){
_local17 = _local6[_local4].split("=");
if (_local17.length > 1){
if (_local17[0] == "order"){
_local7 = Number(_local17[1]);
} else {
if (_local17[0] == "packname"){
_local8 = String(_local17[1]);
} else {
if (_local17[0] == "trophy"){
_local9 = String(_local17[1]);
} else {
if (_local17[0] == "award"){
_local10 = String(_local17[1]);
} else {
if (_local17[0] == "buyurl"){
_local11 = String(_local17[1]);
};
};
};
};
};
};
};
_local4++;
};
_local12 = bprem;
_local13 = "";
_local14 = "";
_local15 = null;
if (_local3.packInfo){
_local13 = _local3.packInfo.text;
};
if (_local3.packInfo2){
_local14 = _local3.packInfo2.text;
};
if (_local3.packInfo2){
_local14 = _local3.packInfo2.text;
};
if (_local3.packInfo2){
_local15 = _local3.previews;
};
s_oGamePacks.push({type:"level", name:id, icon:_local3.icon, award:_local10, packname:_local8, levels:_local2, swf:_local3, levelinfo:_local3.LevelInfo, order:_local7, description:_local13, description2:_local14, premium:_local12, trophy:_local9, preview:_local15, buyurl:_local11});
s_iLevelsLoaded++;
} else {
_local3.mouseEnabled = false;
s_oAvatarPacks.push({type:"avatar", name:id, swf:_local3});
s_iAvatarsLoaded++;
};
s_iPacksLoaded++;
};
pckLoader.contentLoaderInfo.removeEventListener(Event.COMPLETE, onPckLoaded);
};
pckLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, onPckLoaded);
}
public static function getAvatarStates():Dictionary{
return (m_dStates);
}
public static function hasPurchased(_arg1:String):Boolean{
var _local2:int;
_local2 = 0;
while (_local2 < s_aPurchasedPacks.length) {
if (((s_aPurchasedPacks[_local2]) && ((s_aPurchasedPacks[_local2].ident == _arg1)))){
return (true);
};
_local2++;
};
return (false);
}
}
}//package QBeezSrc
Section 124
//QBRotateEvent (QBeezSrc.QBRotateEvent)
package QBeezSrc {
import flash.events.*;
public class QBRotateEvent extends Event {
private var _dir:int;// = 0
public static const ROTATE:String = "Rotate";
public function QBRotateEvent(_arg1:String, _arg2:int, _arg3:Boolean=true, _arg4:Boolean=false):void{
_dir = 0;
_dir = _arg2;
super(_arg1, _arg3, _arg4);
}
public function dir():Number{
return (_dir);
}
override public function clone():Event{
return (new QBRotateEvent(type, _dir));
}
}
}//package QBeezSrc
Section 125
//QBScoreText (QBeezSrc.QBScoreText)
package QBeezSrc {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
import skxSource.*;
import flash.filters.*;
public class QBScoreText extends Sprite {
private var m_delay:int;// = 50
private var m_killtimer:Timer;
private var m_bKill:Boolean;// = false
private var m_timer:Timer;
private static var m_oLastText:QBScoreText = null;
public function QBScoreText(_arg1:String, _arg2:Number, _arg3:Number, _arg4:Number, _arg5=null, _arg6:Boolean=false, _arg7:Boolean=true):void{
var _local8:Number;
var _local9:int;
var _local10:Number;
var _local11:Number;
var _local12:TextField;
var _local13:TextFormat;
var _local14:Boolean;
var _local15:Number;
var _local16:Number;
m_delay = 50;
m_timer = new Timer(m_delay);
m_killtimer = new Timer(700);
m_bKill = false;
super();
if (m_oLastText){
m_oLastText.onKillTimer();
};
mouseEnabled = false;
_local8 = (1 + (_arg4 / 5000));
_local9 = _arg1.length;
_local10 = 0;
if (_arg4 != -100){
_local10 = (Math.min((14 * _local8), 35) * 0.8);
} else {
_local10 = 10;
};
_local11 = 0;
_local12 = new TextField();
_local12.text = _arg1;
m_timer.addEventListener(TimerEvent.TIMER, onTimer);
m_killtimer.addEventListener(TimerEvent.TIMER, onKillTimer);
_local14 = true;
if (((_arg5) && (_arg6))){
_local13 = _arg5.getTextFormat();
_local14 = false;
} else {
_local13 = new TextFormat();
_local13.font = "Excalibur LogoType";
_local13.color = 0xFFFFFF;
_local13.size = _local10;
_local13.letterSpacing = 0;
};
_local12.setTextFormat(_local13);
_local12.embedFonts = true;
if (_local14){
_local12.width = (_local10 * _local9);
_local12.height = (_local10 * 2);
};
_local12.selectable = false;
_local12.mouseEnabled = false;
if (_arg5){
filters = _arg5.filters;
};
addChild(_local12);
y = _arg3;
x = _arg2;
m_timer.start();
m_killtimer.start();
if (_arg7){
_local15 = (x + _local12.width);
if (_local15 > 500){
x = (x - (_local15 - 500));
};
_local16 = (y + _local12.height);
if (_local16 > 500){
y = (y - (_local16 - 500));
};
x = Math.max(0, x);
y = Math.max(0, y);
};
m_oLastText = this;
}
protected function onKillTimer(_arg1:Event=null):void{
m_bKill = true;
m_killtimer.stop();
m_killtimer.removeEventListener(TimerEvent.TIMER, onKillTimer);
}
protected function onTimer(_arg1:Event=null):void{
var _local2:Number;
var _local3:Number;
y = (y - 5);
if (m_bKill){
alpha = (alpha - 0.3);
_local2 = ((1 - alpha) * 3);
_local3 = ((1 - alpha) * 50);
filters = [new BlurFilter(_local2, _local3, 1)];
};
if (alpha <= 0){
visible = false;
m_timer.stop();
m_timer.removeEventListener(TimerEvent.TIMER, onTimer);
parent.removeChild(this);
delete ??getglobalscope
[this];
};
}
}
}//package QBeezSrc
Section 126
//QBShuffleEvent (QBeezSrc.QBShuffleEvent)
package QBeezSrc {
import flash.events.*;
public class QBShuffleEvent extends Event {
private var _started:Boolean;// = false
public static const SHUFFLE:String = "Shuffle";
public function QBShuffleEvent(_arg1:String, _arg2:Boolean=false, _arg3:Boolean=true, _arg4:Boolean=false):void{
_started = false;
_started = _arg2;
super(_arg1, _arg3, _arg4);
}
public function started():Boolean{
return (_started);
}
override public function clone():Event{
return (new QBShuffleEvent(type, _started));
}
}
}//package QBeezSrc
Section 127
//QBWindow (QBeezSrc.QBWindow)
package QBeezSrc {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
import flash.geom.*;
import flash.media.*;
import skxSource.*;
import flash.filters.*;
import flash.xml.*;
public class QBWindow extends skxWindow {
public var m_oQBGameHandler:QBGameHandler;// = null
public function QBWindow(_arg1:int=800, _arg2:int=600):void{
m_oQBGameHandler = null;
super(_arg1, _arg2);
setSingleMouseFocus(false);
}
override public function onMouseUp(_arg1:Number, _arg2:Number):void{
var _local3:Number;
var _local4:int;
var _local5:int;
var _local6:QBeez;
var _local7:int;
var _local8:Number;
var _local9:String;
if (m_oQBGameHandler.m_bMagicChanging){
return;
};
_local3 = (m_oQBGameHandler.getQBScale() / 2);
_local4 = (((_arg1 - m_oQBGameHandler.m_nStartLocX) + _local3) / m_oQBGameHandler.getQBScale());
_local5 = (((_arg2 - m_oQBGameHandler.m_nStartLocY) + _local3) / m_oQBGameHandler.getQBScale());
_local6 = m_oQBGameHandler.getQBee(_local4, _local5);
if (((((((((((((((!(_local6)) || ((_local6.bKill == true)))) || (m_oQBGameHandler.getGameOver()))) || (m_oQBGameHandler.getIsShifting()))) || (_local6.bGameOver))) || (m_oQBGameHandler.getPaused()))) || (m_oQBGameHandler.getIsShifting()))) || (_local6.bBlownUp))){
deselectAll();
return;
};
_local7 = 0;
if (_local6.bSelected){
if (!_local6.bPowerUp){
m_oQBGameHandler.playSound("CLEARBLOCKS", 0, 1, true);
_local8 = ((m_oQBGameHandler.SELECTED.length * m_oQBGameHandler.SELECTED.length) * 100);
if (m_oQBGameHandler.SELECTED.length >= 20){
m_oQBGameHandler.playSound("CLAP1", 0, 1, true);
} else {
if (m_oQBGameHandler.SELECTED.length >= 30){
m_oQBGameHandler.playSound("CLAP1", 0, 1, true);
};
};
_local9 = m_oQBGameHandler.addScore(_local8);
m_oQBGameHandler.createScoreText(_local9, _arg1, _arg2, _local8);
m_oQBGameHandler.setMaxGroup(m_oQBGameHandler.SELECTED.length);
m_oQBGameHandler.dispatchGameEvent({EVENT:"GROUP", COUNT:m_oQBGameHandler.SELECTED.length});
_local7 = 0;
while (_local7 < m_oQBGameHandler.SELECTED.length) {
m_oQBGameHandler.SELECTED[_local7].bSelected = false;
m_oQBGameHandler.SELECTED[_local7].setAnimationState("BLINK");
m_oQBGameHandler.SELECTED[_local7].onDestroy();
_local7++;
};
} else {
m_oQBGameHandler.SELECTED[0].onPowerMove(m_oQBGameHandler.SELECTED, _local6.qbType, _local6);
};
};
deselectAll();
if (!m_oQBGameHandler.getIsShifting()){
m_oQBGameHandler.removeBlanks();
m_oQBGameHandler.removeColumns();
m_oQBGameHandler.sortGrid();
m_oQBGameHandler.updateGameState();
};
}
private function deselectAll():void{
var _local1:int;
_local1 = 0;
while (_local1 < m_oQBGameHandler.SELECTED.length) {
m_oQBGameHandler.SELECTED[_local1].bSelected = false;
if (!m_oQBGameHandler.SELECTED[_local1].bPowerUp){
m_oQBGameHandler.SELECTED[_local1].setAnimationState("IDLE");
};
_local1++;
};
m_oQBGameHandler.setIsOverSelected(false);
m_oQBGameHandler.setIsSelected(false);
}
override public function onMouseDown(_arg1:Number, _arg2:Number):void{
var sca:Number;
var xpos:int;
var ypos:int;
var qb:QBeez;
var i:int;
var mc:MovieClip;
var par:*;
var f:Function;
var t:String;
var mouseX = _arg1;
var mouseY = _arg2;
if (m_oQBGameHandler.m_bMagicChanging){
return;
};
sca = (m_oQBGameHandler.getQBScale() / 2);
xpos = (((mouseX - m_oQBGameHandler.m_nStartLocX) + sca) / m_oQBGameHandler.getQBScale());
ypos = (((mouseY - m_oQBGameHandler.m_nStartLocY) + sca) / m_oQBGameHandler.getQBScale());
if ((((mouseX < (m_oQBGameHandler.m_nStartLocX - sca))) || ((mouseY < (m_oQBGameHandler.m_nStartLocY - sca))))){
return;
};
qb = m_oQBGameHandler.getQBee(xpos, ypos);
if (((((((((((((((!(qb)) || ((qb.bKill == true)))) || (m_oQBGameHandler.getIsShifting()))) || (m_oQBGameHandler.getIsPainting()))) || (m_oQBGameHandler.getGameOver()))) || (qb.bGameOver))) || (m_oQBGameHandler.getPaused()))) || (qb.bBlownUp))){
return;
};
if (m_oQBGameHandler.m_bMagicMode){
if (QBPackHandler.m_oAvatar){
QBPackHandler.m_oAvatar.gotoAndPlay(1, "action_WandWave");
skxScheduler.schedule(m_oQBGameHandler.magicZap, 50, null, qb);
} else {
if (QBPackHandler.getAvatarPack("QBtar_Magician")){
mc = QBPackHandler.getAvatarPack("QBtar_Magician").swf;
mc.gotoAndPlay(1, "action_WandWave");
par = this.parent;
f = function ():void{
var poof:MovieClip;
var rem:Function;
par.removeChild(mc);
f = null;
poof = new NEWPOOFMAGIC();
skxUtil.playMovieClip(poof, 1, 5, 100);
poof.scaleX = 2;
poof.scaleY = 2;
poof.x = (mc.x - 165);
poof.y = (mc.y + 120);
rem = function ():void{
par.removeChild(poof);
};
par.addChild(poof);
skxScheduler.schedule(rem, 600);
};
m_oQBGameHandler.magicZap(qb);
skxScheduler.schedule(f, 1250);
} else {
m_oQBGameHandler.magicZap(qb);
};
};
return;
};
i = 0;
m_oQBGameHandler.SELECTED = new Array();
m_oQBGameHandler.Pick(qb.xPos, qb.yPos, qb.qbType);
if (qb.bPowerUp){
m_oQBGameHandler.setIsSelected(true);
m_oQBGameHandler.setIsOverSelected(true);
i = 0;
while (i < m_oQBGameHandler.SELECTED.length) {
m_oQBGameHandler.SELECTED[i].bSelected = true;
m_oQBGameHandler.SELECTED[i].setTimerOff();
i = (i + 1);
};
} else {
if (m_oQBGameHandler.SELECTED.length > 1){
m_oQBGameHandler.setIsSelected(true);
m_oQBGameHandler.setIsOverSelected(true);
i = 0;
while (i < m_oQBGameHandler.SELECTED.length) {
m_oQBGameHandler.SELECTED[i].bSelected = true;
m_oQBGameHandler.SELECTED[i].setTimerOff();
if (!m_oQBGameHandler.SELECTED[i].bPowerUp){
if (((m_oQBGameHandler.SELECTED[i].bDropping) || (m_oQBGameHandler.SELECTED[i].bFlipping))){
m_oQBGameHandler.SELECTED[i].setAnimationState("WIGGLEHOT");
} else {
m_oQBGameHandler.SELECTED[i].setAnimationState("HOT");
};
};
i = (i + 1);
};
if (m_oQBGameHandler.SELECTED.length >= 30){
m_oQBGameHandler.playSound(String((qb.sColor + "TOG4")), 0, 1, true);
} else {
if (m_oQBGameHandler.SELECTED.length >= 20){
m_oQBGameHandler.playSound(String((qb.sColor + "TOG3")), 0, 1, true);
} else {
if (m_oQBGameHandler.SELECTED.length >= 5){
m_oQBGameHandler.playSound(String((qb.sColor + "TOG2")), 0, 1, true);
} else {
m_oQBGameHandler.playSound(String((qb.sColor + "TOG1")), 0, 1, true);
};
};
};
} else {
t = m_oQBGameHandler.addScore(-100);
m_oQBGameHandler.createScoreText(t, mouseX, mouseY, -100);
if (!m_oQBGameHandler.SELECTED[0].bPowerUp){
m_oQBGameHandler.SELECTED[0].setAnimationState("ROLLOVER");
};
m_oQBGameHandler.playSound("UHH");
m_oQBGameHandler.SELECTED = new Array();
};
};
}
}
}//package QBeezSrc
Section 128
//skxAnimation (skxSource.skxAnimation)
package skxSource {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.geom.*;
public class skxAnimation {
public var Frames:Array;
public var AnimationTime:Number;// = 0
private var CurrentFrame:int;// = 0
private var FramePos:Number;// = 0
private var LastFrame:int;// = 0
public var Owner:skxSprite;// = null
public var bLoop:Boolean;// = true
public var Name:String;// = ""
public function skxAnimation(_arg1:String="", _arg2:Boolean=true){
Name = "";
Frames = new Array();
CurrentFrame = 0;
LastFrame = 0;
FramePos = 0;
AnimationTime = 0;
bLoop = true;
Owner = null;
super();
Name = _arg1;
bLoop = _arg2;
}
public function hasFrameChanged():Boolean{
if (LastFrame == CurrentFrame){
return (false);
};
return (true);
}
public function prevFrame():void{
if (CurrentFrame > 0){
setFrame((CurrentFrame - 1));
} else {
setFrame((Frames.length() - 1));
};
}
public function displayFrame():void{
var _local1:int;
_local1 = 0;
_local1 = 0;
while (_local1 < Frames.length) {
_local1++;
};
}
public function getCurFrameLength():Number{
return (Frames[CurrentFrame].Length);
}
public function addFrame(_arg1:int, _arg2:Number){
if (_arg2 > 0){
AnimationTime = (AnimationTime + _arg2);
Frames.push(new skxFrame(_arg1, AnimationTime));
} else {
Frames.push(new skxFrame(_arg1, AnimationTime));
};
}
public function reset(){
CurrentFrame = 0;
FramePos = 0;
}
public function updateFrame(_arg1:Number):void{
var _local2:int;
if (getCurFrameLength() != -1){
FramePos = (FramePos + _arg1);
if ((((FramePos >= AnimationTime)) && (bLoop))){
setFrame(0);
FramePos = 0;
if (Owner){
Owner.onAnimationEnd(Name);
};
} else {
if (FramePos >= AnimationTime){
if (Owner){
Owner.onAnimationEnd(Name);
};
};
};
_local2 = (Frames.length - 1);
while (_local2 > CurrentFrame) {
if (FramePos >= Frames[(_local2 - 1)].Length){
setFrame(_local2);
return;
};
_local2--;
};
};
}
public function setFrame(_arg1:int):void{
if ((((_arg1 >= 0)) && ((_arg1 < Frames.length)))){
LastFrame = CurrentFrame;
CurrentFrame = _arg1;
};
}
public function getFrame():int{
return (Frames[CurrentFrame].Frame);
}
public function nextFrame():void{
if (CurrentFrame < (Frames.length - 1)){
CurrentFrame = (CurrentFrame + 1);
} else {
reset();
};
}
}
}//package skxSource
Section 129
//skxAPI (skxSource.skxAPI)
package skxSource {
import flash.utils.*;
public class skxAPI {
public static var receive:Function = function ():void{
};
public static var send:Function = function ():void{
};
private static var m_sAPI:String = "";
public static function getAPI():String{
return (m_sAPI);
}
public static function init(_arg1:Object):void{
m_sAPI = _arg1.API;
if (_arg1.API == "mochi"){
skxMochi.init(_arg1);
} else {
if (_arg1.API == "whirled"){
skxWhirled.init(_arg1);
};
};
}
}
}//package skxSource
Section 130
//skxDisplay (skxSource.skxDisplay)
package skxSource {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
public class skxDisplay extends Sprite {
private static var m_bInit:Boolean = false;
private static var par = null;
private static var m_DebugLevel:int = 0;
private static var m_instance:skxDisplay = null;
private static var m_sText:String = "";
public static var m_nTimerRefreshRate = 2500;
private static var m_Timer:Timer = new skxTimer(m_nTimerRefreshRate);
private static var m_displayText:TextField = null;
public static function Error(_arg1:String):void{
if (((m_bInit) && (m_instance))){
par.addChild(m_instance);
m_sText = ((m_sText + "\n") + _arg1);
m_displayText.text = m_sText;
};
}
private static function onDrag(_arg1:Event):void{
switch (_arg1.type){
case MouseEvent.MOUSE_DOWN:
m_instance.startDrag();
break;
case MouseEvent.MOUSE_UP:
m_instance.stopDrag();
break;
case Event.MOUSE_LEAVE:
m_instance.stopDrag();
break;
};
}
public static function Print(_arg1:String):void{
if (((m_bInit) && (m_instance))){
par.addChild(m_instance);
m_sText = ((m_sText + "\n") + _arg1);
m_displayText.text = m_sText;
};
}
public static function init(_arg1):void{
m_bInit = true;
m_displayText = new TextField();
m_displayText.alpha = 0.5;
m_displayText.autoSize = "left";
m_displayText.background = true;
m_displayText.backgroundColor = 0xFFFFFF;
m_displayText.border = true;
m_displayText.borderColor = 0;
m_displayText.selectable = false;
m_displayText.wordWrap = true;
m_displayText.width = 400;
par = _arg1;
m_instance = new (skxDisplay);
m_instance.addChild(m_displayText);
m_instance.alpha = 0.5;
par.addChild(m_instance);
m_sText = "Init display text. ";
m_Timer.addEventListener(TimerEvent.TIMER, update, false, 0, true);
m_Timer.start();
m_instance.visible = true;
}
private static function update(_arg1:TimerEvent):void{
var _local2:int;
if (m_sText.length > 0){
_local2 = m_sText.indexOf("\n");
m_sText = m_sText.substr((_local2 + 1), m_sText.length);
m_displayText.text = m_sText;
};
}
public static function toggleDisplay():void{
if (m_instance.visible == true){
m_instance.visible = false;
} else {
m_instance.visible = true;
};
}
public static function Warn(_arg1:String):void{
if (((m_bInit) && (m_instance))){
par.addChild(m_instance);
m_sText = ((m_sText + "\n") + _arg1);
m_displayText.text = m_sText;
};
}
}
}//package skxSource
Section 131
//skxFrame (skxSource.skxFrame)
package skxSource {
public class skxFrame {
public var Length:Number;// = 0
public var Frame:uint;// = 0
public function skxFrame(_arg1, _arg2:Number){
Length = 0;
Frame = 0;
super();
Length = _arg2;
Frame = _arg1;
}
}
}//package skxSource
Section 132
//skxImage (skxSource.skxImage)
package skxSource {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.geom.*;
public class skxImage {
public var m_nScaleX:Number;// = 1
public var m_nScaleY:Number;// = 1
public var m_sName:String;// = ""
private var m_pOffset:Point;
public var m_nPitchX:Number;// = 0
public var m_nPitchY:Number;// = 0
public var m_iRows:int;// = 1
public var m_oObjRef;
private var m_iFrame:int;// = 1
private var m_oDefTransform:Transform;// = null
public var m_iHeight:Number;// = 0
private var m_aBitmapData:Array;
public var m_iCol:int;// = 1
private var m_iTotalFrames:int;// = 0
public var m_iWidth:Number;// = 0
private var m_sType:String;// = ""
public function skxImage(_arg1, _arg2=null){
m_sName = "";
m_aBitmapData = new Array();
m_iTotalFrames = 0;
m_iRows = 1;
m_iCol = 1;
m_iHeight = 0;
m_iWidth = 0;
m_nPitchX = 0;
m_nPitchY = 0;
m_nScaleX = 1;
m_nScaleY = 1;
m_sType = "";
m_oDefTransform = null;
m_iFrame = 1;
m_pOffset = new Point();
super();
if ((_arg1 as BitmapData)){
m_iHeight = _arg1.height;
m_iWidth = _arg1.width;
m_nPitchX = m_iWidth;
m_nPitchY = m_iHeight;
m_iRows = 1;
m_iCol = 1;
addFrame(_arg1);
} else {
if ((_arg1 as MovieClip)){
m_oObjRef = (_arg1 as MovieClip);
m_oObjRef.visible = true;
m_oDefTransform = m_oObjRef.transform;
m_sType = _arg2.type;
m_iFrame = 1;
if (_arg2.mcframe){
m_iFrame = _arg2.mcframe;
};
m_iTotalFrames = 0;
if (_arg2.type == "bitmap"){
buildFromBitmap(m_oObjRef, _arg2);
} else {
buildFromMovie(m_oObjRef, _arg2);
};
resetRef();
};
};
}
private function resetRef():void{
m_oObjRef.transform = m_oDefTransform;
m_oObjRef.visible = false;
}
private function buildFromBitmap(_arg1, _arg2):void{
var _local3:Number;
var _local4:Number;
var _local5:ColorTransform;
var _local6:int;
var _local7:int;
var _local8:int;
var _local9:Point;
var _local10:Number;
var _local11:Number;
var _local12:BitmapData;
m_nScaleX = 1;
m_nScaleY = 1;
m_iRows = 1;
m_iCol = 1;
m_nScaleX = Number(_arg2.scalex);
m_nScaleY = Number(_arg2.scaley);
if (_arg2.row){
m_iRows = _arg2.row;
};
if (_arg2.col){
m_iCol = _arg2.col;
};
_arg1.scaleX = m_nScaleX;
_arg1.scaleY = m_nScaleY;
if (m_iFrame != -1){
_arg1.gotoAndStop(m_iFrame);
};
_local3 = ((_arg2.width * m_nScaleX) / m_iCol);
_local4 = ((_arg2.height * m_nScaleY) / m_iRows);
m_iHeight = _arg2.height;
m_iWidth = _arg2.width;
m_nPitchX = _local3;
m_nPitchY = _local4;
_local5 = new ColorTransform();
_local5.redMultiplier = 1;
_local5.greenMultiplier = 1;
_local5.blueMultiplier = 1;
_local5.redMultiplier = Number(_arg2.r);
_local5.greenMultiplier = Number(_arg2.g);
_local5.blueMultiplier = Number(_arg2.b);
_local6 = 0;
_local7 = 0;
_local8 = 0;
if (_arg2.copyframes){
while (_local8 < _arg2.copyframes.length) {
_local9 = skxUtil.returnGridPos(_arg2.copyframes[_local8], m_iCol);
_local10 = ((_local3 * (_local9.x - 1)) * -1);
_local11 = ((_local4 * (_local9.y - 1)) * -1);
_local12 = skxUtil.takeSnapshot(_arg1, m_nPitchX, m_nPitchY, -1, _local10, _local11);
if (_local12){
_local12.colorTransform(_local12.rect, _local5);
addFrame(_local12);
};
_local8++;
};
} else {
while (_local8 < _arg2.frames) {
_local10 = ((_local3 * _local6) * -1);
_local11 = ((_local4 * _local7) * -1);
_local12 = skxUtil.takeSnapshot(_arg1, _local3, _local4, -1, _local10, _local11);
if (_local12){
_local12.colorTransform(_local12.rect, _local5);
addFrame(_local12);
_local6++;
if (_local6 == m_iCol){
_local7++;
_local6 = 0;
};
};
_local8++;
};
};
}
private function addFrame(_arg1:BitmapData):void{
m_iTotalFrames++;
m_aBitmapData.push(_arg1);
}
private function buildFromMovie(_arg1, _arg2):void{
var _local3:int;
var _local4:ColorTransform;
var _local5:BitmapData;
_local3 = 0;
m_nScaleX = 1;
m_nScaleY = 1;
m_nScaleX = Number(_arg2.scalex);
m_nScaleY = Number(_arg2.scaley);
if (_arg2.offsetx){
m_pOffset.x = Number(_arg2.offsetx);
};
if (_arg2.offsety){
m_pOffset.y = Number(_arg2.offsety);
};
_local4 = new ColorTransform();
_local4.redMultiplier = Number(_arg2.r);
_local4.greenMultiplier = Number(_arg2.g);
_local4.blueMultiplier = Number(_arg2.b);
_arg1.scaleX = m_nScaleX;
_arg1.scaleY = m_nScaleY;
m_iHeight = _arg2.height;
m_iWidth = _arg2.width;
m_nPitchX = (m_iWidth * m_nScaleX);
m_nPitchY = (m_iHeight * m_nScaleY);
m_iRows = 1;
m_iCol = 1;
if (_arg2.copyframes){
while (_local3 < _arg2.copyframes.length) {
_local5 = skxUtil.takeSnapshot(_arg1, (m_iWidth * m_nScaleX), (m_iHeight * m_nScaleY), ((_arg2.copyframes[_local3] + m_iFrame) - 1), m_pOffset.x, m_pOffset.y);
if (_local5){
_local5.colorTransform(_local5.rect, _local4);
addFrame(_local5);
};
_local3++;
};
} else {
while (_local3 < _arg2.frames) {
_local5 = skxUtil.takeSnapshot(_arg1, (m_iWidth * m_nScaleX), (m_iHeight * m_nScaleY), (_local3 + m_iFrame), m_pOffset.x, m_pOffset.y);
if (_local5){
_local5.colorTransform(_local5.rect, _local4);
addFrame(_local5);
};
_local3++;
};
};
_arg1.scaleX = 1;
_arg1.scaleY = 1;
}
public function getTotalFrames():int{
return (m_iTotalFrames);
}
public function getData(_arg1:int=0):BitmapData{
if ((((_arg1 >= 0)) && ((_arg1 < m_iTotalFrames)))){
return (m_aBitmapData[_arg1]);
};
return (null);
}
public function dispose():void{
var _local1:int;
if (m_aBitmapData){
_local1 = 0;
while (_local1 < m_aBitmapData.length) {
if (m_aBitmapData[_local1]){
m_aBitmapData[_local1].dispose();
m_aBitmapData[_local1] = null;
};
_local1++;
};
};
m_iTotalFrames = 0;
m_iRows = 1;
m_iCol = 1;
m_iHeight = 0;
m_iWidth = 0;
m_nPitchX = 0;
m_nPitchY = 0;
m_nScaleX = 1;
m_nScaleY = 1;
m_aBitmapData = new Array();
m_oObjRef = null;
m_oDefTransform = null;
}
public function clone(_arg1:Number=1, _arg2:Number=1, _arg3:Number=1, _arg4:Number=1, _arg5:Number=1, _arg6:Array=null):skxImage{
return (new skxImage(m_oObjRef, {type:m_sType, mcframe:m_iFrame, scalex:_arg1, scaley:_arg2, r:_arg3, g:_arg4, b:_arg5, copyframes:_arg6, col:m_iCol, row:m_iRows, height:m_iHeight, width:m_iWidth, frames:m_iTotalFrames}));
}
}
}//package skxSource
Section 133
//skxLevelLoader (skxSource.skxLevelLoader)
package skxSource {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
public class skxLevelLoader {
public static function onSecurityError(_arg1:SecurityErrorEvent):void{
}
public static function onIOError(_arg1:IOErrorEvent):void{
}
public static function parseXML(_arg1:XML):Array{
var _local2:Array;
var _local3:XMLList;
var _local4:XML;
var _local5:Dictionary;
var _local6:XMLList;
var _local7:String;
var _local8:XML;
_local2 = new Array();
_local3 = _arg1.children();
for each (_local4 in _local3) {
_local5 = new Dictionary(true);
_local6 = _local4.children();
_local7 = "";
for each (_local8 in _local6) {
if (_local8.name() == "class"){
_local7 = _local8;
} else {
_local5[_local8.name()] = _local8;
};
};
_local2.push({CLASS:_local7, DATA:_local5});
};
return (_local2);
}
public static function loadLevel(_arg1, _arg2:String="XML"):Array{
switch (_arg2){
case "XML":
return (parseXML(XML(_arg1)));
};
return (null);
}
public static function onHTTPStatus(_arg1:HTTPStatusEvent):void{
}
public static function parseForImages(_arg1:XML):Array{
var _local2:Array;
var _local3:XMLList;
var _local4:XML;
var _local5:Dictionary;
var _local6:XMLList;
var _local7:String;
var _local8:XML;
_local2 = new Array();
_local3 = _arg1.children();
for each (_local4 in _local3) {
_local5 = new Dictionary(true);
_local6 = _local4.children();
_local7 = "";
for each (_local8 in _local6) {
if (_local8.name() == "image"){
_local2.push(_local8);
};
};
};
return (_local2);
}
}
}//package skxSource
Section 134
//skxMochi (skxSource.skxMochi)
package skxSource {
import flash.utils.*;
import mochi.*;
public class skxMochi {
public static function init(_arg1:Object):void{
skxAPI.send = send;
skxAPI.receive = receive;
skxScene.m_Stage = _arg1.stage;
MochiServices.connect(_arg1.key, _arg1.stage);
}
public static function receive(_arg1:Object):void{
}
public static function send(_arg1:Object):void{
if (_arg1.skxfunc == "preloader"){
MochiAd.showPreloaderAd(_arg1);
} else {
if (_arg1.skxfunc == "timedad"){
MochiAd.showTimedAd(_arg1);
} else {
if (_arg1.skxfunc == "showleaderboard"){
MochiScores.showLeaderboard(_arg1);
} else {
if (_arg1.skxfunc == "closeleaderboard"){
MochiScores.closeLeaderboard();
};
};
};
};
}
}
}//package skxSource
Section 135
//skxMusicChannel (skxSource.skxMusicChannel)
package skxSource {
import flash.events.*;
import flash.utils.*;
import flash.media.*;
public class skxMusicChannel {
private static var m_oSounds:Array = new Array();
private static var m_oSoundChannel = null;
private static var m_oSoundTransform:SoundTransform = new SoundTransform(1, 0);
private static var m_nVolume:Number = 1;
private static var m_tFadingTimer:Timer = new skxTimer(100);
private static var m_oPlayingSound:Sound = null;
public function playSound(_arg1:Sound, _arg2:Number=0, _arg3:uint=1, _arg4:Boolean=false):void{
if (((((!(isSoundPlaying())) || (_arg4))) && (skxSystem.checkSoundDevice()))){
m_oSoundChannel = _arg1.play(_arg2, _arg3, m_oSoundTransform);
m_oSoundChannel.addEventListener(Event.SOUND_COMPLETE, nextSound, false, 50000000, true);
};
}
public static function clearAll():Boolean{
if (!skxSystem.checkSoundDevice()){
return (false);
};
if (m_oPlayingSound){
m_oPlayingSound = null;
};
if (m_oSounds.length > 0){
if (m_oSoundChannel){
m_oSoundChannel.removeEventListener(Event.SOUND_COMPLETE, nextSound);
m_oSoundChannel.stop();
m_oSoundChannel = null;
};
m_oSounds = new Array();
return (true);
};
return (false);
}
public static function getSoundChannel():SoundChannel{
return (m_oSoundChannel);
}
public static function setVolume(_arg1:Number):Boolean{
if (!skxSystem.checkSoundDevice()){
return (false);
};
m_nVolume = _arg1;
m_oSoundTransform.volume = m_nVolume;
if (m_oSoundChannel){
m_oSoundChannel.soundTransform = m_oSoundTransform;
};
return (true);
}
public static function addSound(_arg1):Boolean{
var _local2:Sound;
if (skxSystem.checkSoundDevice() == false){
return (false);
};
_local2 = (_arg1 as Sound);
if (_local2){
m_oSounds.push(_local2);
return (true);
};
return (false);
}
public static function getVolume():Number{
return (m_nVolume);
}
public static function nextSound(_arg1:Event=null):void{
if (!m_oSounds){
return;
};
if (m_oSoundChannel){
m_oSoundChannel.removeEventListener(Event.SOUND_COMPLETE, nextSound);
m_oSoundChannel.stop();
m_oSoundChannel = null;
m_oPlayingSound = null;
};
if ((((_arg1 == null)) && ((m_oSounds.length > 0)))){
m_oSoundChannel = m_oSounds[0].play(0, 0, m_oSoundTransform);
if (m_oSoundChannel){
m_oSoundChannel.addEventListener(Event.SOUND_COMPLETE, nextSound, false, 50000000, true);
};
m_oPlayingSound = (skxUtil.popFromArray(0, m_oSounds) as Sound);
} else {
if (_arg1){
if (m_oSounds.length > 1){
m_oSoundChannel = m_oSounds[1].play(0, 0, m_oSoundTransform);
if (m_oSoundChannel){
m_oSoundChannel.addEventListener(Event.SOUND_COMPLETE, nextSound, false, 50000000, true);
};
m_oPlayingSound = (skxUtil.popFromArray(0, m_oSounds) as Sound);
} else {
if (m_oSounds.length > 0){
m_oSoundChannel = m_oSounds[0].play(0, 0, m_oSoundTransform);
if (m_oSoundChannel){
m_oSoundChannel.addEventListener(Event.SOUND_COMPLETE, nextSound, false, 50000000, true);
};
m_oPlayingSound = (skxUtil.popFromArray(0, m_oSounds) as Sound);
};
};
};
};
}
public static function isSoundPlaying():Boolean{
var _local1:SoundChannel;
if (skxSystem.checkSoundDevice() == false){
return (false);
};
_local1 = m_oSoundChannel;
if (((_local1) && ((_local1.position <= 1)))){
return (true);
};
return (false);
}
public static function getCount():int{
return (m_oSounds.length);
}
public static function fadeVolume(_arg1:Number, _arg2:Number, _arg3:int):void{
var i:int;
var factor:Number;
var f:Function;
var nVol = _arg1;
var ms = _arg2;
var steps = _arg3;
if (!skxSystem.checkSoundDevice()){
return;
};
if (m_tFadingTimer.running){
m_tFadingTimer.stop();
m_tFadingTimer = new skxTimer((ms / steps));
};
i = 0;
factor = ((nVol - getVolume()) / steps);
m_tFadingTimer.delay = (ms / steps);
f = function (_arg1:Object):void{
setVolume((getVolume() + factor));
if ((((getVolume() == nVol)) || ((i >= steps)))){
m_tFadingTimer.stop();
m_tFadingTimer.removeEventListener(TimerEvent.TIMER, f);
setVolume(nVol);
f = null;
return;
};
i++;
};
m_tFadingTimer.addEventListener(TimerEvent.TIMER, f);
m_tFadingTimer.start();
}
}
}//package skxSource
Section 136
//skxPaths (skxSource.skxPaths)
package skxSource {
import flash.utils.*;
public final class skxPaths {
private static var m_oPaths:Dictionary = new Dictionary(true);
private static var m_iPathCount:int = 0;
public static function setPath(_arg1:String, _arg2:Array):void{
m_iPathCount++;
m_oPaths[_arg1] = _arg2;
}
public static function clearPaths():void{
m_iPathCount = 0;
m_oPaths = new Dictionary(true);
}
public static function getPath(_arg1:String):Array{
if (m_oPaths[_arg1]){
return (m_oPaths[_arg1]);
};
return (null);
}
}
}//package skxSource
Section 137
//skxRandom (skxSource.skxRandom)
package skxSource {
public class skxRandom {
private static var m_nSeed:Number = 0;
public static function setSeed(_arg1:Number):void{
if (_arg1 < 0){
m_nSeed = (_arg1 * -1);
} else {
m_nSeed = _arg1;
};
}
public static function getRandomFlt(_arg1:Number, _arg2:Number):Number{
if (_arg2 <= _arg1){
return (_arg2);
};
return (((getRandom() * (_arg2 - _arg1)) + _arg1));
}
public static function getRandomInt(_arg1:Number, _arg2:Number):Number{
if (_arg2 <= _arg1){
return (_arg2);
};
return (Math.floor(((getRandom() * (_arg2 - _arg1)) + _arg1)));
}
public static function getSeed():Number{
return (m_nSeed);
}
public static function getRandom():Number{
var _local1:Number;
m_nSeed = (((getSeed() * 9301) + 49297) % 233280);
_local1 = (getSeed() / 233280);
if (_local1 < 0){
_local1 = (_local1 * -1);
};
return (_local1);
}
public static function getRandomBool():Boolean{
return ((getRandom() < 0.5));
}
}
}//package skxSource
Section 138
//skxResourceMgr (skxSource.skxResourceMgr)
package skxSource {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.geom.*;
import flash.media.*;
import flash.net.*;
public class skxResourceMgr {
private static var refLoader:URLLoader = null;
private static var m_oResourcePool:Dictionary = new Dictionary(true);
private static var xmlLoader:URLLoader = null;
private static var m_iBytesTotal:int = 0;
private static var m_oLoader = null;
private static var initLoadCount:int = 0;
private static var m_aResourceURL = null;
private static var m_bResourceListLoaded:Boolean = false;
private static var m_bLoadAll:Boolean = false;
private static var m_oLoadedSWFS:Dictionary = new Dictionary(true);
private static var m_oRef;
private static var m_bCallBackCalled:Boolean = false;
private static var m_iBytesLoaded:int = 0;
private static var m_oResourceNames:Array = new Array();
public static var m_OverrideSettings:Object;
private static var breakLoading:Boolean = false;
private static var imgLoader:Loader = null;
private static var m_sPreloader = "";
private static var m_sNextName:String = "";
private static var m_oStage = null;
private static var m_oData;
private static var m_iInProgress:int = 0;
private static var m_fCallback:Function = null;
public static function getResource(_arg1:String):Object{
if (m_oResourcePool[_arg1]){
return (m_oResourcePool[_arg1]);
};
return (null);
}
public static function globalLoaded(_arg1:Event=null):void{
m_bResourceListLoaded = true;
}
public static function refXML(_arg1:Array, _arg2:Object=null):void{
var _local3:XML;
var _local4:XMLList;
var _local5:XML;
var _local6:Dictionary;
var _local7:String;
var _local8:String;
var _local9:String;
var _local10:String;
var _local11:Number;
var _local12:Number;
var _local13:int;
var _local14:int;
var _local15:Number;
var _local16:Number;
var _local17:Number;
var _local18:Number;
var _local19:int;
var _local20:Number;
var _local21:String;
var _local22:Boolean;
_local3 = XML(_arg1.pop());
_local4 = _local3.children();
for each (_local5 in _local4) {
_local6 = skxUtil.parseXML(XML(_local5));
_local7 = _local5.attribute("name");
_local8 = "global";
_local9 = "noscene";
if (_local6["scene"]){
_local8 = String(_local6["scene"]);
};
if (_local6["filescene"]){
_local9 = String(_local6["filescene"]);
};
_local10 = null;
if (_local6["filename"]){
_local10 = _local6["filename"];
};
switch (String(_local6["type"])){
case "MC":
case "mc":
case "movieclip":
loadResourcePara({LOADER:null, RES:_local6["resourcename"], URL:_local10, FILESCENE:_local9, NAME:_local7, TYPE:"MC", DATA:null, SCENE:_local8});
break;
case "IMG":
case "img":
case "bitmap":
_local11 = 0;
_local12 = 0;
_local13 = 1;
_local14 = 1;
_local15 = 1;
_local16 = 1;
_local17 = 0;
_local18 = 0;
_local19 = -1;
_local20 = 1;
_local21 = "bitmap";
_local22 = false;
if (_local6["rows"]){
_local14 = _local6["rows"];
};
if (_local6["cols"]){
_local13 = _local6["cols"];
};
if (_local6["scalex"]){
_local15 = _local6["scalex"];
};
if (_local6["scaley"]){
_local16 = _local6["scaley"];
};
if (_local6["offsetx"]){
_local17 = _local6["offsetx"];
};
if (_local6["offsety"]){
_local18 = _local6["offsety"];
};
if (_local6["width"]){
_local11 = _local6["width"];
};
if (_local6["height"]){
_local12 = _local6["height"];
};
if (_local6["frames"]){
_local19 = _local6["frames"];
};
if (_local6["srctype"]){
_local21 = _local6["srctype"];
};
if (_local6["startframe"]){
_local20 = _local6["startframe"];
};
if (_local6["sf"]){
_local20 = _local6["sf"];
};
if (((((_local6["allowoverride"]) && ((_local6["allowoverride"] == "1")))) || ((_local6["allowoverride"] == "true")))){
_local22 = true;
};
if (_local19 == -1){
_local19 = (_local14 * _local13);
};
loadResourcePara({LOADER:null, RES:_local6["resourcename"], URL:_local10, FILESCENE:_local9, NAME:_local7, SCENE:_local8, TYPE:"IMG", WIDTH:_local11, HEIGHT:_local12, COL:_local13, ROWS:_local14, FRAMES:_local19, SRC:_local21, SCALEX:_local15, SCALEY:_local16, OFFSETX:_local17, OFFSETY:_local18, STARTFRAME:_local20, DATA:null, ALLOWOVERRIDE:_local22});
break;
case "TEXT":
case "TXT":
case "text":
case "txt":
loadResourcePara({LOADER:null, RES:_local6["resourcename"], URL:_local10, NAME:_local7, TYPE:"TEXT", DATA:null, SCENE:_local8});
break;
case "SOUND":
case "MP3":
case "sound":
case "mp3":
loadResourcePara({LOADER:null, RES:_local6["resourcename"], URL:_local10, NAME:_local7, TYPE:"SOUND", DATA:null, SCENE:_local8});
break;
};
};
if (_arg1.length > 0){
refXML(_arg1);
} else {
_local8 = "global";
if (((_arg2) && (_arg2.SCENE))){
_local8 = _arg2.SCENE;
};
loadScene(_local8, globalLoaded, m_sPreloader);
};
}
private static function onSoundLoaded(_arg1:Event, _arg2=null):void{
if (_arg2){
m_oResourceNames.push(m_oData.NAME);
setResource(m_oData.NAME, _arg2);
} else {
if (m_oData.TYPE == "SOUND"){
m_oResourceNames.push(m_oData.NAME);
setResource(m_oData.NAME, _arg1.target);
};
};
breakLoading = true;
startLoad();
}
private static function onImgLoaded(_arg1:Event=null, _arg2=null):void{
var cnt:*;
var checkMC:MovieClip;
var f:Function;
var col:int;
var row:int;
var frames:int;
var sx:Number;
var sy:Number;
var mdata:skxImage;
var ev = _arg1;
var content = _arg2;
cnt = null;
if (m_oResourcePool[m_oData.NAME].DATA){
startLoad();
return;
};
if (((m_oResourcePool[m_oData.NAME].DATA) && (m_oData.ALLOWOVERRIDE))){
if (((((m_OverrideSettings) && ((m_OverrideSettings.scalex == m_oResourcePool[m_oData.NAME].DATA.m_nScaleX)))) && ((m_OverrideSettings.scaley == m_oResourcePool[m_oData.NAME].DATA.m_nScaleY)))){
startLoad();
};
};
if (content){
cnt = content;
} else {
cnt = imgLoader.content;
m_oLoadedSWFS[String(m_oData.URL)] = cnt;
};
cnt.gotoAndStop(1);
checkMC = (cnt as MovieClip);
if (m_oData.TYPE == "MC"){
if (((checkMC) && (!((m_oData.FILESCENE == "noscene"))))){
f = function (_arg1:Object):void{
var _local2:MovieClip;
if (((checkMC.numChildren) && (checkMC.getChildAt(0)))){
_local2 = (checkMC.getChildAt(0) as MovieClip);
checkMC.removeChild(_local2);
_local2.gotoAndStop(1);
m_oResourceNames.push(m_oData.NAME);
if (((m_oData.cache) && ((m_oData.cache == "1")))){
_local2.cacheAsBitmap = true;
};
setResource(m_oData.NAME, _local2);
checkMC.removeEventListener(Event.ENTER_FRAME, f);
checkMC = null;
startLoad();
f = null;
} else {
checkMC.gotoAndStop(1, String(m_oData.FILESCENE));
};
};
checkMC.gotoAndStop(1, String(m_oData.FILESCENE));
checkMC.addEventListener(Event.ENTER_FRAME, f);
return;
};
m_oResourceNames.push(m_oData.NAME);
if (((m_oData.cache) && ((m_oData.cache == "1")))){
cnt.cacheAsBitmap = true;
};
setResource(m_oData.NAME, cnt);
startLoad();
return;
} else {
if (m_oData.TYPE == "IMG"){
if (checkMC){
m_oResourceNames.push(m_oData.NAME);
col = 1;
row = 1;
frames = 1;
sx = 1;
sy = 1;
if (m_oData.ROWS){
row = m_oData.ROWS;
};
if (m_oData.COL){
col = m_oData.COL;
};
if (m_oData.FRAMES){
frames = m_oData.FRAMES;
};
if (m_oData.ALLOWOVERRIDE){
if (((m_OverrideSettings) && (m_OverrideSettings.scalex))){
sx = m_OverrideSettings.scalex;
};
if (((m_OverrideSettings) && (m_OverrideSettings.scaley))){
sy = m_OverrideSettings.scaley;
};
};
if (m_oData.FILESCENE != "noscene"){
checkMC.gotoAndStop(1, String(m_oData.FILESCENE));
};
mdata = new skxImage(checkMC, {type:m_oData.SRC, width:int(m_oData.WIDTH), height:int(m_oData.HEIGHT), col:col, row:row, frames:frames, scalex:sx, scaley:sy, mcframe:m_oData.STARTFRAME, offsetx:m_oData.OFFSETX, offsety:m_oData.OFFSETY, r:1, g:1, b:1});
mdata.m_sName = m_oData.NAME;
setResource(m_oData.NAME, mdata);
startLoad();
return;
};
};
};
startLoad();
}
public static function loadResource(_arg1:String):void{
var _local2:Sound;
if (!m_oResourcePool[_arg1]){
startLoad();
return;
};
m_oData = m_oResourcePool[_arg1];
if (m_oData){
if ((((m_oData.TYPE == "MC")) || ((m_oData.TYPE == "IMG")))){
if (((m_oData.RES) && (getData(String(m_oData.RES))))){
onImgLoaded(null, getResource(String(m_oData.RES)).DATA);
} else {
if (((m_oLoadedSWFS[String(m_oData.URL)]) || ((String(m_oLoadedSWFS[String(m_oData.URL)]) == "loading")))){
onImgLoaded(null, m_oLoadedSWFS[String(m_oData.URL)]);
} else {
if (((m_oData.URL) && (!((String(m_oData.URL) == "null"))))){
m_oLoadedSWFS[String(m_oData.URL)] = "loading";
imgLoader = new Loader();
imgLoader.load(new URLRequest(m_oData.URL));
imgLoader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, onIOError, false, 0, true);
imgLoader.contentLoaderInfo.addEventListener(SecurityErrorEvent.SECURITY_ERROR, onSecurityError, false, 0, true);
imgLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, onImgLoaded, false, 0, true);
} else {
startLoad();
};
};
};
} else {
if (m_oData.TYPE == "TEXT"){
if (((m_oData.URL) && (!((String(m_oData.URL) == "null"))))){
xmlLoader = new URLLoader();
xmlLoader.dataFormat = URLLoaderDataFormat.TEXT;
xmlLoader.load(new URLRequest(m_oData.URL));
xmlLoader.addEventListener(IOErrorEvent.IO_ERROR, onIOError, false, 0, true);
xmlLoader.addEventListener(SecurityErrorEvent.SECURITY_ERROR, onSecurityError, false, 0, true);
xmlLoader.addEventListener(Event.COMPLETE, onXmlLoaded, false, 0, true);
} else {
startLoad();
};
} else {
if (m_oData.TYPE == "SOUND"){
if (m_oData.RES){
onSoundLoaded(null, getResource(String(m_oData.RES)).DATA);
} else {
if (((m_oData.URL) && (!((String(m_oData.URL) == "null"))))){
_local2 = new Sound();
_local2.load(new URLRequest(m_oData.URL));
_local2.addEventListener(Event.COMPLETE, onSoundLoaded, false, 0, true);
} else {
startLoad();
};
};
};
};
};
};
}
public static function getData(_arg1:String){
if (m_oResourcePool[_arg1]){
return (m_oResourcePool[_arg1].DATA);
};
return (null);
}
private static function loadResourcePara(_arg1):Boolean{
m_oResourcePool[_arg1.NAME] = _arg1;
return (true);
}
public static function setResource(_arg1:String, _arg2, _arg3:String="TEMP"):void{
var _local4:MovieClip;
if (!m_oResourcePool[_arg1]){
m_oResourcePool[_arg1] = {LOADER:null, NAME:_arg1, SCENE:_arg3, DATA:null};
} else {
if (m_oResourcePool[_arg1].DATA){
return;
};
};
m_oResourcePool[_arg1].DATA = _arg2;
if (((((m_oStage) && (!((m_sPreloader == ""))))) && ((_arg1 == m_sPreloader)))){
_local4 = new MovieClip();
_local4.name = "skxtransition";
_local4.addChild(m_oResourcePool[_arg1].DATA);
m_oStage.addChildAt(_local4, 0);
};
}
public static function unloadAll():void{
var _local1:Object;
for each (_local1 in m_oResourcePool) {
if (((_local1) && (!((_local1.SCENE == "global"))))){
if (_local1.DATA){
if ((((((_local1.DATA as MovieClip)) && (_local1.DATA.parent))) && ((_local1.DATA.parent as MovieClip)))){
_local1.DATA.parent.removeChild(_local1.DATA);
};
if ((((_local1.DATA as MovieClip)) && ((_local1.DATA.parent as Loader)))){
_local1.DATA.parent.unload();
};
delete _local1.DATA;
};
_local1.LOADER = null;
_local1.DATA = null;
if (_local1.SCENE == "TEMP"){
m_oResourcePool[_local1.NAME] = null;
};
};
};
}
public static function getAmountLoaded():int{
return (Math.round(((m_iBytesLoaded / m_iBytesTotal) * 100)));
}
public static function unloadResource(_arg1:String):void{
}
public static function Init(_arg1:Array, _arg2:Boolean=false, _arg3:Object=null):void{
m_aResourceURL = _arg1;
m_bLoadAll = _arg2;
if (_arg3){
if (_arg3.STAGE){
m_oStage = _arg3.STAGE;
} else {
m_oStage = skxScene.getScene();
};
if (_arg3.PRELOADER){
m_sPreloader = _arg3.PRELOADER;
};
};
refXML(m_aResourceURL, _arg3);
}
private static function unloadSWFS():void{
var _local1:Object;
for each (_local1 in m_oLoadedSWFS) {
if (((_local1) && ((_local1 as Loader)))){
_local1.unload();
};
_local1 = null;
};
m_oLoadedSWFS = new Dictionary(true);
}
public static function onHTTPStatus(_arg1:HTTPStatusEvent){
startLoad();
}
public static function onIOError(_arg1:IOErrorEvent){
startLoad();
}
public static function loadScene(_arg1:String, _arg2:Function=null, _arg3:String="", _arg4:Array=null):void{
var _local5:Array;
var _local6:Object;
var _local7:int;
m_fCallback = _arg2;
m_bCallBackCalled = false;
_local5 = new Array();
for each (_local6 in m_oResourcePool) {
if (((((((_local6) && ((((_local6.SCENE == _arg1)) || (m_bLoadAll))))) && ((_local6.DATA == null)))) && (!((_local6.NAME == _arg3))))){
_local5.push(_local6.NAME);
};
};
if (_arg4){
_local7 = 0;
while (_local7 < _arg4.length) {
if (((!((_arg4[_local7] == ""))) && (!((_arg4[_local7] == " "))))){
skxUtil.safeInsert(_arg4[_local7], _local5);
};
_local7++;
};
};
if (((m_oStage) && (!((_arg3 == ""))))){
_local5.push(_arg3);
};
loadResourceList(_local5, _arg2);
}
public static function isLoading():Boolean{
return (m_bResourceListLoaded);
}
public static function onSecurityError(_arg1:SecurityErrorEvent){
}
public static function getResourceList():Array{
return (m_oResourceNames);
}
public static function loadResourceList(_arg1:Array, _arg2:Function=null):void{
m_oLoader = _arg1;
m_fCallback = _arg2;
m_bCallBackCalled = false;
initLoadCount = m_oLoader.length;
startLoad();
}
public static function returnImageData(_arg1:XML):Array{
var _local2:XML;
var _local3:XMLList;
var _local4:Array;
var _local5:XML;
var _local6:Dictionary;
var _local7:String;
var _local8:String;
_local2 = _arg1;
_local3 = _local2.children();
_local4 = new Array();
for each (_local5 in _local3) {
_local6 = skxUtil.parseXML(XML(_local5));
_local7 = _local5.attribute("name");
_local8 = _local6["filename"];
if (((_local6["resourcename"]) && (getData(_local6["resourcename"])))){
_local8 = _local6["resourcename"];
};
if (_local8){
switch (String(_local6["type"])){
case "IMG":
case "img":
case "bitmap":
_local4.push({file:_local8, id:_local7});
break;
};
};
};
return (_local4);
}
private static function onXmlLoaded(_arg1:Event):void{
m_oResourceNames.push(m_oData.NAME);
setResource(m_oData.NAME, xmlLoader.data);
startLoad();
}
public static function currentLoaded():int{
if (!m_oLoader){
return (0);
};
return (m_oLoader.length);
}
public static function totalToLoad():int{
return (initLoadCount);
}
private static function startLoad():void{
var _local1:String;
if (((m_oLoader) && ((m_oLoader.length > 0)))){
_local1 = m_oLoader.pop();
loadResource(_local1);
} else {
if (((m_fCallback) && ((m_bCallBackCalled == false)))){
m_bCallBackCalled = true;
unloadSWFS();
skxScheduler.schedule(m_fCallback, 20);
};
};
}
public static function onProgressEvent(_arg1:ProgressEvent){
}
}
}//package skxSource
Section 139
//skxScene (skxSource.skxScene)
package skxSource {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.geom.*;
import flash.media.*;
import flash.net.*;
public class skxScene {
private static var m_sScene:String = "";
public static var m_Stage = null;
private static var m_oScene:Dictionary = new Dictionary(true);
public static function removeObject(_arg1):void{
if (((m_Stage) && (m_Stage.contains(_arg1)))){
m_Stage.removeChild(_arg1);
};
}
public static function clearScene():void{
var _local1:int;
if (m_Stage){
_local1 = m_Stage.numChildren;
while (_local1) {
m_Stage.removeChildAt((_local1 - 1));
_local1--;
};
};
}
public static function goToScene(_arg1, _arg2:Function=null, _arg3:Array=null):void{
var _local4:int;
m_sScene = _arg1;
if (m_Stage){
_local4 = m_Stage.numChildren;
while (_local4) {
if (m_Stage.getChildAt((_local4 - 1)).name != "skxtransition"){
m_Stage.removeChildAt((_local4 - 1));
};
_local4--;
};
};
skxPaths.clearPaths();
skxSoundChannel.clearAll();
skxMusicChannel.clearAll();
skxScheduler.cancelAll();
skxResourceMgr.unloadAll();
skxResourceMgr.loadScene(_arg1, _arg2, "", _arg3);
}
public static function getScene(){
if (m_Stage){
return (m_Stage);
};
return (null);
}
}
}//package skxSource
Section 140
//skxScheduler (skxSource.skxScheduler)
package skxSource {
import flash.events.*;
import flash.utils.*;
public class skxScheduler {
private static var m_aSchedules:Array = new Array();
public static function execAll():void{
var _local1:int;
_local1 = 0;
while (_local1 < m_aSchedules.length) {
if (((((m_aSchedules[_local1]) && ((m_aSchedules[_local1].currentCount == 0)))) && (m_aSchedules[_local1].running))){
m_aSchedules[_local1].delay = (10 + _local1);
m_aSchedules[_local1].start();
};
_local1++;
};
}
public static function cancel(_arg1:int):Boolean{
if (m_aSchedules[_arg1]){
m_aSchedules[_arg1].stop();
m_aSchedules[_arg1].removeEventListener(TimerEvent.TIMER, m_aSchedules[_arg1].func);
skxUtil.popFromArray(_arg1, m_aSchedules);
return (true);
};
return (false);
}
public static function unpause():void{
var _local1:int;
_local1 = 0;
while (_local1 < m_aSchedules.length) {
m_aSchedules[_local1].start();
_local1++;
};
clearTimers();
}
public static function pause():void{
var _local1:int;
_local1 = 0;
while (_local1 < m_aSchedules.length) {
m_aSchedules[_local1].stop();
_local1++;
};
clearTimers();
}
public static function schedule(_arg1:Function, _arg2:int, _arg3:Object=null, _arg4:Object=null, _arg5:Object=null, _arg6:Object=null, _arg7:Object=null, _arg8:Object=null, _arg9:Object=null, _arg10:Object=null, _arg11:Object=null, _arg12:Object=null):int{
var id:int;
var timer:skxTimer;
var f:Function;
var func = _arg1;
var ms = _arg2;
var obj = _arg3;
var arg1 = _arg4;
var arg2 = _arg5;
var arg3 = _arg6;
var arg4 = _arg7;
var arg5 = _arg8;
var arg6 = _arg9;
var arg7 = _arg10;
var arg8 = _arg11;
var arg9 = _arg12;
id = m_aSchedules.length;
timer = new skxTimer(ms, 0, true);
m_aSchedules.push(timer);
f = function (_arg1:Object):void{
timer.stop();
timer.removeEventListener(TimerEvent.TIMER, f);
skxUtil.removeObjectFromArray(timer, skxScheduler.m_aSchedules);
if (func){
if (arg9 != null){
func.call(obj, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9);
} else {
if (arg8 != null){
func.call(obj, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8);
} else {
if (arg7 != null){
func.call(obj, arg1, arg2, arg3, arg4, arg5, arg6, arg7);
} else {
if (arg6 != null){
func.call(obj, arg1, arg2, arg3, arg4, arg5, arg6);
} else {
if (arg5 != null){
func.call(obj, arg1, arg2, arg3, arg4, arg5);
} else {
if (arg4 != null){
func.call(obj, arg1, arg2, arg3, arg4);
} else {
if (arg3 != null){
func.call(obj, arg1, arg2, arg3);
} else {
if (arg2 != null){
func.call(obj, arg1, arg2);
} else {
if (arg1 != null){
func.call(obj, arg1);
} else {
func.call(obj);
};
};
};
};
};
};
};
};
};
};
skxScheduler.clearTimers();
};
timer.addEventListener(TimerEvent.TIMER, f);
timer.repeatCount = 1;
timer.start();
return (id);
}
private static function clearTimers():void{
var _local1:Array;
var _local2:int;
_local1 = new Array();
_local2 = 0;
while (_local2 < m_aSchedules.length) {
if (((m_aSchedules[_local2]) && ((m_aSchedules[_local2].currentCount == 0)))){
_local1.push(m_aSchedules[_local2]);
};
_local2++;
};
m_aSchedules = _local1;
}
public static function cancelAll():void{
while (m_aSchedules.length) {
if (m_aSchedules[(m_aSchedules.length - 1)]){
m_aSchedules[(m_aSchedules.length - 1)].stop();
};
m_aSchedules.pop();
};
m_aSchedules = new Array();
}
}
}//package skxSource
Section 141
//skxSoundChannel (skxSource.skxSoundChannel)
package skxSource {
import flash.events.*;
import flash.utils.*;
import flash.media.*;
public class skxSoundChannel {
private static var m_oSounds:Array = new Array();
private static var m_oSoundChannel:Dictionary = new Dictionary();
private static var m_oSoundTransform:SoundTransform = new SoundTransform(1, 0);
private static var m_nVolume:Number = 1;
private static var m_tFadingTimer:Timer = new skxTimer(100);
private static var m_oPlayingSound:Sound = null;
public static function pauseSound(_arg1:Sound):void{
if (m_oSoundChannel[_arg1]){
m_oSoundChannel[_arg1].stop();
};
}
public static function clearAll():Boolean{
if (skxSystem.checkSoundDevice() == false){
return (false);
};
stopAllSounds();
m_oSoundChannel = new Dictionary();
return (true);
}
public static function stopAllSounds():void{
var _local1:Object;
if (skxSystem.checkSoundDevice() == false){
return;
};
for (_local1 in m_oSoundChannel) {
if (m_oSoundChannel[_local1]){
m_oSoundChannel[_local1].stop();
m_oSoundChannel[_local1] = null;
};
};
}
public static function getSoundChannel():Dictionary{
return (m_oSoundChannel);
}
public static function setVolume(_arg1:Number):Boolean{
var _local2:Object;
if (skxSystem.checkSoundDevice() == false){
return (false);
};
m_nVolume = _arg1;
m_oSoundTransform.volume = m_nVolume;
for (_local2 in m_oSoundChannel) {
if (m_oSoundChannel[_local2]){
m_oSoundChannel[_local2].soundTransform = m_oSoundTransform;
};
};
return (true);
}
public static function stopSound(_arg1:Sound):void{
if (m_oSoundChannel[_arg1]){
m_oSoundChannel[_arg1].stop();
m_oSoundChannel[_arg1] = null;
};
}
public static function getVolume():Number{
return (m_nVolume);
}
public static function playSound(_arg1:Sound, _arg2:Number=0, _arg3:uint=1, _arg4:Boolean=false, _arg5:Function=null):void{
var f:Function;
var sName = _arg1;
var delay = _arg2;
var iLoops = _arg3;
var bForcePlay = _arg4;
var cb = _arg5;
if (skxSystem.checkSoundDevice() == false){
return;
};
if (((!(m_oSoundChannel[sName])) || (bForcePlay))){
f = function (_arg1:Event=null):void{
m_oSoundChannel[sName] = null;
if (cb){
cb.call(null);
};
};
m_oSoundChannel[sName] = sName.play(delay, iLoops, m_oSoundTransform);
if (m_oSoundChannel[sName]){
m_oSoundChannel[sName].addEventListener(Event.SOUND_COMPLETE, f, false, 50000000, false);
};
};
}
public static function isSoundPlaying(_arg1:Sound):Boolean{
if (skxSystem.checkSoundDevice() == false){
return (false);
};
if (m_oSoundChannel[_arg1]){
return (true);
};
return (false);
}
public static function getCount():int{
return (m_oSounds.length);
}
public static function fadeVolume(_arg1:Number, _arg2:Number, _arg3:int):void{
var i:int;
var factor:Number;
var f:Function;
var nVol = _arg1;
var ms = _arg2;
var steps = _arg3;
if (skxSystem.checkSoundDevice() == false){
return;
};
if (m_tFadingTimer.running){
m_tFadingTimer.stop();
m_tFadingTimer = new skxTimer((ms / steps));
};
i = 0;
factor = ((nVol - getVolume()) / steps);
m_tFadingTimer.delay = (ms / steps);
f = function (_arg1:Object):void{
setVolume((getVolume() + factor));
if ((((getVolume() == nVol)) || ((i >= steps)))){
m_tFadingTimer.stop();
m_tFadingTimer.removeEventListener(TimerEvent.TIMER, f);
setVolume(nVol);
f = null;
return;
};
i++;
};
m_tFadingTimer.addEventListener(TimerEvent.TIMER, f);
m_tFadingTimer.start();
}
}
}//package skxSource
Section 142
//skxSprite (skxSource.skxSprite)
package skxSource {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.geom.*;
import flash.media.*;
import fl.motion.*;
import flash.filters.*;
public class skxSprite extends Sprite {
private var m_pVelocity:Point;
protected var m_startPositionX:Number;// = 0
protected var m_startPositionY:Number;// = 0
protected var m_imageFile:String;// = ""
private var m_bActive:Boolean;// = true
private var m_oColor;// = null
public var m_Depth:int;// = -1
private var m_pForce:Point;
protected var m_targetMoveCallback:Boolean;// = false
private var m_iTime:int;// = 0
private var m_pPivotRatio:Point;
private var m_iAnimatorTotalTime:int;// = 0
private var m_iAnimatorTotalStep:int;// = 0
protected var m_bkillAtLifeSpan:Boolean;// = true
private var m_autoRotation:Number;// = 0
private var m_oDefMountTranform:Matrix;// = null
protected var m_targetMoveSpd;// = 0
private var m_timer:Timer;
private var m_oMount:skxSprite;// = null
private var m_pDamp:Point;
private var m_curScrollXPos:Number;// = 0
private var m_height:Number;
protected var m_bStarted:Boolean;// = false
protected var m_dGraphLine:Dictionary;
private var m_aTrackedObjects:Array;// = null
public var m_listIndex:int;// = 0
private var m_oMountOffsetX:Number;// = 0
private var m_oMountOffsetY:Number;// = 0
private var m_nAnimatorTime:Number;// = 0
private var m_imageMap:skxImage;
private var m_curScrollYPos:Number;// = 0
public var m_bDead:Boolean;// = false
protected var m_nLifeSpan:Number;// = -1
protected var m_isMoving:Boolean;// = false
private var m_isScaling:Boolean;// = false
private var m_isRotating:Boolean;// = false
private var m_xPitch:Number;// = 0
private var m_iMouseDragIndex:int;// = -1
private var m_pPivot:Point;
protected var m_targetPositionX:Number;// = 0
protected var m_targetPositionY:Number;// = 0
private var m_nYSort:Number;// = 0
private var m_iCurrentFrame:int;// = 0
private var m_iAnimatorCurStep:int;// = 0
private var m_nMass:Number;// = 1
protected var m_nLife:Number;// = 0
private var m_targetRotation:Number;// = 0
private var m_yPitch:Number;// = 0
private var m_pMaxVelocity:Point;
private var m_sImageName:String;// = ""
private var m_bInMotion:Boolean;// = false
protected var m_scrollXSpeed:Number;// = 0
private var m_oFilterRect:Rectangle;// = null
private var m_nXSort:Number;// = 0
private var m_bDragging:Boolean;// = false
private var m_pAcc:Point;
private var m_Rows:Number;// = 0
private var m_bTrackRotation:Boolean;// = false
protected var m_bCancelStateDelay:Boolean;// = false
protected var m_targetScaleSpd;// = 0
protected var m_animSeq:Dictionary;
private var m_bSort:Boolean;// = true
protected var m_targetRotateDir;// = 0
private var m_oFilter:Array;// = null
private var m_oImageData:BitmapData;// = null
protected var m_scrollYSpeed:Number;// = 0
private var m_iFrameCol:uint;// = 0
private var m_bCheckVisibility:Boolean;// = false
private var m_oAnimator:Animator;// = null
public var m_bUpdatable:Boolean;// = false
private var m_nAnimatorTotalTime:Number;// = 0
private var m_iFrameRow:uint;// = 0
private var m_oWindow:skxWindow;// = null
public var m_oMouseMoveOffset:Point;// = null
private var m_width:Number;
private var m_iTotalFrames:int;// = 0
private var m_pGraphOffset:Point;
private var m_iMouseIndex:int;// = -1
private var m_Cols:Number;// = 0
protected var m_nTargetVelX;// = 0
protected var m_nTargetVelY;// = 0
protected var m_targetScaleX:Number;// = 1
protected var m_targetScaleY:Number;// = 1
protected var m_CurAnimation:skxAnimation;
private var m_sMouseCollisionType:String;// = "rect"
private var m_bMouseOver:Boolean;// = false
protected var m_targetPosition:Number;// = 0
protected var m_sState:String;// = ""
public var m_iMouseAdded:Boolean;// = false
protected var m_targetRotateSpd;// = 0
public function skxSprite(){
m_oAnimator = null;
m_oWindow = null;
m_listIndex = 0;
m_iTime = 0;
m_oMountOffsetX = 0;
m_oMountOffsetY = 0;
m_autoRotation = 0;
m_imageFile = "";
m_oColor = null;
m_bCancelStateDelay = false;
m_bUpdatable = false;
m_sMouseCollisionType = "rect";
m_bActive = true;
m_bSort = true;
m_isScaling = false;
m_isMoving = false;
m_isRotating = false;
m_bDead = false;
m_targetRotation = 0;
m_pGraphOffset = new Point();
m_targetPositionX = 0;
m_targetPositionY = 0;
m_targetPosition = 0;
m_startPositionX = 0;
m_startPositionY = 0;
m_targetScaleX = 1;
m_targetScaleY = 1;
m_oMouseMoveOffset = null;
m_targetScaleSpd = 0;
m_targetMoveSpd = 0;
m_targetRotateSpd = 0;
m_targetRotateDir = 0;
m_nTargetVelX = 0;
m_nTargetVelY = 0;
m_targetMoveCallback = false;
m_bMouseOver = false;
m_bDragging = false;
m_animSeq = new Dictionary(true);
m_CurAnimation = undefined;
m_bTrackRotation = false;
m_bStarted = false;
m_nAnimatorTotalTime = 0;
m_nAnimatorTime = 0;
m_iAnimatorTotalTime = 0;
m_iAnimatorCurStep = 0;
m_iAnimatorTotalStep = 0;
m_aTrackedObjects = null;
m_xPitch = 0;
m_yPitch = 0;
m_oMount = null;
m_oDefMountTranform = null;
m_Rows = 0;
m_Cols = 0;
m_iFrameRow = 0;
m_iFrameCol = 0;
m_iTotalFrames = 0;
m_iCurrentFrame = 0;
m_scrollXSpeed = 0;
m_scrollYSpeed = 0;
m_Depth = -1;
m_sState = "";
m_nLife = 0;
m_nLifeSpan = -1;
m_curScrollXPos = 0;
m_curScrollYPos = 0;
m_imageMap = undefined;
m_sImageName = "";
m_pPivot = new Point();
m_pPivotRatio = new Point(0.5, 0.5);
m_pVelocity = new Point();
m_pAcc = new Point();
m_pForce = new Point();
m_pDamp = new Point(1, 1);
m_nMass = 1;
m_pMaxVelocity = new Point(-1, -1);
m_bInMotion = false;
m_nXSort = 0;
m_nYSort = 0;
m_oFilter = null;
m_oImageData = null;
m_oFilterRect = null;
m_iMouseIndex = -1;
m_iMouseDragIndex = -1;
m_iMouseAdded = false;
m_bkillAtLifeSpan = true;
m_bCheckVisibility = false;
m_dGraphLine = new Dictionary();
super();
m_width = 0;
m_height = 0;
m_listIndex = -1;
m_timer = null;
m_oColor = {r:1, g:1, b:1};
mouseEnabled = false;
setActive(false);
}
public function getYSort():Number{
return (m_nYSort);
}
public function onMouseOver():void{
}
public function getWidth():Number{
return (m_width);
}
public function setColorOffset(_arg1:Number, _arg2:Number, _arg3:Number):void{
var _local4:ColorTransform;
if (((((!((m_oColor.r == _arg1))) || (!((m_oColor.g == _arg2))))) || (!((m_oColor.b == _arg3))))){
_local4 = transform.colorTransform;
_local4.redOffset = _arg1;
_local4.greenOffset = _arg2;
_local4.blueOffset = _arg3;
transform.colorTransform = _local4;
};
}
public function getHeight():Number{
return (m_height);
}
public function onFrameChange():void{
}
public function setColor(_arg1:Number, _arg2:Number, _arg3:Number):void{
var _local4:ColorTransform;
if (((((!((m_oColor.r == _arg1))) || (!((m_oColor.g == _arg2))))) || (!((m_oColor.b == _arg3))))){
_local4 = transform.colorTransform;
_local4.redMultiplier = _arg1;
_local4.greenMultiplier = _arg2;
_local4.blueMultiplier = _arg3;
transform.colorTransform = _local4;
m_oColor = {r:_arg1, g:_arg2, b:_arg3};
};
}
public function setGraphLine(_arg1:String, _arg2:Array=null):void{
var _local3:Array;
var _local4:Number;
var _local5:ColorTransform;
if (_arg2){
m_dGraphLine[_arg1] = _arg2;
} else {
_local3 = new Array();
_local4 = 0;
if (_arg1 == "scaleX"){
_local4 = 1;
};
if (_arg1 == "scaleY"){
_local4 = 1;
};
if (_arg1 == "posX"){
_local4 = y;
};
if (_arg1 == "posY"){
_local4 = x;
};
if (_arg1 == "rotation"){
_local4 = rotation;
};
if (_arg1 == "alpha"){
_local4 = alpha;
};
if (_arg1 == "forceX"){
_local4 = 0;
};
if (_arg1 == "forceY"){
_local4 = 0;
};
if (_arg1 == "dampX"){
_local4 = 1;
};
if (_arg1 == "dampY"){
_local4 = 1;
};
if (_arg1 == "velX"){
_local4 = 0;
};
if (_arg1 == "velY"){
_local4 = 0;
};
if (_arg1 == "frame"){
_local4 = 1;
};
if (_arg1 == "ro"){
_local5 = transform.colorTransform;
_local4 = _local5.redOffset;
};
if (_arg1 == "go"){
_local5 = transform.colorTransform;
_local4 = _local5.greenOffset;
};
if (_arg1 == "bo"){
_local5 = transform.colorTransform;
_local4 = _local5.blueOffset;
};
_local3.push(new Point(0, _local4));
_local3.push(new Point(1, _local4));
m_dGraphLine[_arg1] = _local3;
};
}
public function disMount():void{
setMount(null);
}
public function clearFilter():void{
m_oFilter = null;
m_oImageData = null;
setPivot(m_pPivotRatio.x, m_pPivotRatio.y);
}
public function addObjectToTrack(_arg1):void{
if (!m_aTrackedObjects){
m_aTrackedObjects = new Array();
};
m_aTrackedObjects.push(_arg1);
}
public function setXDamp(_arg1:Number):void{
m_pDamp.x = _arg1;
}
public function updateMoveTo(_arg1:Number):void{
if (m_isMoving){
if ((m_targetPosition + (_arg1 * m_targetMoveSpd)) < 1){
m_targetPosition = (m_targetPosition + (_arg1 * m_targetMoveSpd));
x = (m_startPositionX + (m_nTargetVelX * m_targetPosition));
y = (m_startPositionY + (m_nTargetVelY * m_targetPosition));
} else {
finishMoveTo(true, m_targetMoveCallback);
};
};
}
public function getXScrollSpeed():Number{
return (m_scrollXSpeed);
}
public function onMouseDrag(_arg1:Number, _arg2:Number):void{
}
public function updateScaleTo(_arg1:Number):void{
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
if (m_isScaling){
_local2 = skxUtil.getDistance(scaleX, scaleY, m_targetScaleX, m_targetScaleY);
if (_local2 <= 0.001){
scaleX = m_targetScaleX;
scaleY = m_targetScaleY;
m_isScaling = false;
m_targetScaleX = 1;
m_targetScaleY = 1;
m_targetMoveSpd = 0;
} else {
_local3 = ((m_targetScaleX - scaleX) / _local2);
_local4 = ((m_targetScaleY - scaleY) / _local2);
_local5 = skxUtil.getDistance((scaleX + ((_local3 * m_targetScaleSpd) * _arg1)), (scaleY + ((_local4 * m_targetScaleSpd) * _arg1)), m_targetScaleX, m_targetScaleY);
if (_local2 > _local5){
scaleX = (scaleX + ((_local3 * m_targetScaleSpd) * _arg1));
scaleY = (scaleY + ((_local4 * m_targetScaleSpd) * _arg1));
} else {
scaleX = m_targetScaleX;
scaleY = m_targetScaleY;
m_isScaling = false;
m_targetScaleX = 1;
m_targetScaleY = 1;
m_targetScaleSpd = 0;
};
};
};
}
public function onRender(_arg1:BitmapData, _arg2:Object=null):void{
var _local3:int;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:Point;
var _local9:ColorTransform;
var _local10:BitmapData;
var _local11:*;
var _local12:Matrix;
var _local13:Matrix;
var _local14:int;
var _local15:int;
if (((m_bCheckVisibility) && (!(isVisible())))){
return;
};
_local3 = (getFrame() - 1);
_local4 = scaleX;
_local5 = scaleY;
if (((_arg2) && (_arg2.FRAME))){
_local3 = (_arg2.FRAME - 1);
};
if (((_arg2) && (_arg2.SCALE))){
_local4 = _arg2.SCALE.x;
_local5 = _arg2.SCALE.y;
};
if (((((((((((m_imageMap) && (m_imageMap.getData(_local3)))) && (visible))) && ((alpha > 0)))) && (!((_local4 == 0))))) && (!((_local5 == 0))))){
m_oDefMountTranform = transform.matrix.clone();
updateMount();
_local6 = (x + m_pGraphOffset.x);
_local7 = (y + m_pGraphOffset.y);
if (((_arg2) && (_arg2.POINT))){
_local6 = _arg2.POINT.x;
_local7 = _arg2.POINT.y;
};
_local8 = new Point();
if (getWindow()){
_local8 = getWindow().getCameraPos();
};
_local9 = transform.colorTransform;
if (((_arg2) && (_arg2.COLOR))){
_local9.redMultiplier = _arg2.COLOR.r;
_local9.greenMultiplier = _arg2.COLOR.g;
_local9.blueMultiplier = _arg2.COLOR.b;
};
if (!m_oFilter){
if ((((((_local5 == 1)) && ((_local4 == 1)))) && ((rotation == 0)))){
if ((((((((((((((_local9.redMultiplier == 1)) && ((_local9.blueMultiplier == 1)))) && ((_local9.greenMultiplier == 1)))) && ((_local9.redOffset == 0)))) && ((_local9.greenOffset == 0)))) && ((_local9.blueOffset == 0)))) && ((alpha == 1)))){
_arg1.copyPixels(m_imageMap.getData(_local3), getRectangle(), new Point(((_local6 + getXPivot()) - _local8.x), ((_local7 + getYPivot()) - _local8.y)), null, null, true);
} else {
_local10 = m_imageMap.getData(_local3).clone();
_local10.colorTransform(m_imageMap.getData(_local3).rect, _local9);
_arg1.copyPixels(_local10, _local10.rect, new Point(((_local6 + getXPivot()) - _local8.x), ((_local7 + getYPivot()) - _local8.y)), null, null, true);
};
} else {
if (rotation){
_local11 = ((Math.PI * 2) * (rotation / 360));
_local12 = new Matrix();
_local12.translate((-(getXPitch()) / 2), (-(getYPitch()) / 2));
_local12.rotate(_local11);
_local12.translate((getXPitch() / 2), (getYPitch() / 2));
_local12.translate(((_local6 + getXPivot()) - _local8.x), ((_local7 + getYPivot()) - _local8.y));
_arg1.draw(m_imageMap.getData(_local3), _local12, _local9, null, null, true);
} else {
_local13 = new Matrix();
_local13.translate(getXPivot(), getYPivot());
_local13.scale(_local4, _local5);
_local13.translate((_local6 - _local8.x), (_local7 - _local8.y));
_arg1.draw(m_imageMap.getData(_local3), _local13, _local9, null, null, false);
};
};
} else {
if (m_oFilter){
m_oImageData = m_imageMap.getData(_local3).clone();
_local14 = 0;
while (_local14 < m_oFilter.length) {
m_oImageData.applyFilter(m_oImageData, getRectangle(), new Point(0, 0), m_oFilter[_local14]);
_local14++;
};
if (rotation){
_local15 = rotation;
_local11 = ((Math.PI * 2) * (rotation / 360));
_local12 = new Matrix();
_local12.translate(getXPivot(), getYPivot());
_local12.rotate(_local11);
_local12.translate((_local6 - _local8.x), (_local7 - _local8.y));
_arg1.draw(m_oImageData, _local12, null, null, null, false);
} else {
_local13 = new Matrix();
_local13.translate(getXPivot(), getYPivot());
_local13.scale(_local4, _local5);
_local13.translate((_local6 - _local8.x), (_local7 - _local8.y));
_arg1.draw(m_oImageData, _local13, _local9, null, null, false);
};
};
};
transform.matrix = m_oDefMountTranform;
};
}
public function setMouseEnabled(_arg1:Boolean):void{
if (getWindow()){
mouseEnabled = _arg1;
if (_arg1){
m_iMouseAdded = true;
getWindow().m_aMouseArr[this] = this;
} else {
if (getWindow().getObjFocus() == this){
getWindow().setObjFocus(null);
};
if (m_bMouseOver){
onMouseOff();
m_bMouseOver = false;
};
delete getWindow().m_aMouseArr[this];
};
};
}
public function setAnimationState(_arg1:String, _arg2:Boolean=false):Boolean{
m_sState = _arg1;
if (m_animSeq[_arg1]){
m_CurAnimation = m_animSeq[_arg1];
m_CurAnimation.Owner = this;
if (_arg2){
m_CurAnimation.reset();
};
setFrame(m_CurAnimation.getFrame());
return (true);
} else {
m_CurAnimation = null;
};
return (false);
}
public function setXForce(_arg1:Number):void{
m_pForce.x = _arg1;
}
public function getXSort():Number{
return (m_nXSort);
}
public function isDragging():Boolean{
return (m_bDragging);
}
public function finishMoveTo(_arg1:Boolean=true, _arg2:Boolean=false):void{
if (!m_isMoving){
return;
};
if (_arg1){
x = m_targetPositionX;
y = m_targetPositionY;
};
m_isMoving = false;
m_targetPositionX = 0;
m_targetPositionY = 0;
m_nTargetVelY = 0;
m_nTargetVelX = 0;
m_targetMoveSpd = 0;
m_targetMoveCallback = false;
if (_arg2){
onMoveToTarget();
};
}
public function getXPitch():Number{
return (m_xPitch);
}
public function setMaxVelocity(_arg1:Number, _arg2:Number):void{
m_pMaxVelocity.x = _arg1;
m_pMaxVelocity.y = _arg2;
}
public function getKillAtLifeSpan():Boolean{
return (m_bkillAtLifeSpan);
}
protected function onTimer(_arg1:Event=null):void{
}
public function updateAnimation(_arg1:Number):void{
if (((((m_CurAnimation) && ((m_bDead == false)))) && (m_imageMap))){
m_CurAnimation.updateFrame(_arg1);
if (m_CurAnimation.hasFrameChanged()){
setFrame(m_CurAnimation.getFrame());
};
};
}
public function setKillAtLifeSpan(_arg1:Boolean):void{
m_bkillAtLifeSpan = _arg1;
}
public function getAutoRotation():Number{
return (m_autoRotation);
}
private function updateMount():void{
var _local1:int;
var _local2:Matrix;
var _local3:skxSprite;
if (m_oMount){
_local1 = rotation;
_local2 = m_oDefMountTranform.clone();
_local3 = getMount();
while (_local3) {
_local2.concat(_local3.transform.matrix);
_local3 = _local3.getMount();
};
if (!m_bTrackRotation){
_local2.rotate(_local1);
};
transform.matrix = _local2;
};
}
public function setYScrollSpeed(_arg1:Number){
m_scrollYSpeed = _arg1;
}
public function setMount(_arg1:skxSprite, _arg2="none", _arg3="none", _arg4:Boolean=true):void{
m_oMount = _arg1;
if (_arg2 != "none"){
x = _arg2;
};
if (_arg3 != "none"){
y = _arg3;
};
m_bTrackRotation = _arg4;
}
public function isActive():Boolean{
return (m_bActive);
}
public function setMouseCollisionType(_arg1:String):void{
m_sMouseCollisionType = _arg1;
}
public function setPivot(_arg1:Number, _arg2:Number):void{
m_pPivotRatio.x = _arg1;
m_pPivotRatio.y = _arg2;
updatePivot();
}
public function getDepth():int{
return (m_Depth);
}
public function getCurrentState():String{
if (m_CurAnimation){
return (m_CurAnimation.Name);
};
return ("");
}
public function updatePivot():void{
if (getImage()){
m_pPivot.x = ((m_pPivotRatio.x * getXPitch()) * -1);
m_pPivot.y = ((m_pPivotRatio.y * getYPitch()) * -1);
};
}
public function onDestroy():void{
destroy();
}
public function updateRotateTo(_arg1:Number):void{
if (((m_isRotating) && ((m_autoRotation == 0)))){
if (m_targetRotateDir > 0){
if ((rotation + (m_targetRotateSpd * _arg1)) < m_targetRotation){
rotation = (rotation + (m_targetRotateSpd * _arg1));
} else {
rotation = m_targetRotation;
m_isRotating = false;
m_targetRotateSpd = 0;
m_targetRotation = 0;
m_targetRotateDir = 0;
};
} else {
if ((rotation + (m_targetRotateSpd * _arg1)) > m_targetRotation){
rotation = (rotation + (m_targetRotateSpd * _arg1));
} else {
rotation = m_targetRotation;
m_isRotating = false;
m_targetRotateSpd = 0;
m_targetRotation = 0;
m_targetRotateDir = 0;
};
};
} else {
rotation = (rotation + (m_autoRotation * _arg1));
};
}
public function setSort(_arg1:Boolean):void{
m_bSort = _arg1;
if (_arg1 == false){
m_listIndex = -1;
};
}
protected function onWindowEvent(_arg1:skxWindowEvent):void{
}
public function getForce():Point{
return (m_pForce);
}
public function rotateTo(_arg1:Number, _arg2:Number, _arg3:Boolean=true){
if (((m_oAnimator) && (m_bInMotion))){
m_bInMotion = false;
m_oAnimator.end();
};
m_isRotating = true;
m_targetRotateDir = 1;
if (_arg1 < 0){
m_targetRotateDir = -1;
};
if (_arg3){
if ((360 - _arg1) < (_arg1 - rotation)){
m_targetRotateDir = -1;
m_targetRotation = ((360 - _arg1) * -1);
} else {
m_targetRotateDir = 1;
m_targetRotation = _arg1;
};
} else {
m_targetRotation = _arg1;
};
m_targetRotateSpd = (_arg2 * m_targetRotateDir);
}
public function setYForce(_arg1:Number):void{
m_pForce.y = _arg1;
}
public function getYPitch():Number{
return (m_yPitch);
}
private function updatePhysics(_arg1:Number):void{
m_pAcc.x = (m_pAcc.x + ((m_pForce.x / m_nMass) * _arg1));
m_pAcc.y = (m_pAcc.y + ((m_pForce.y / m_nMass) * _arg1));
m_pVelocity.x = (m_pVelocity.x + ((m_pAcc.x * m_pDamp.x) * _arg1));
m_pVelocity.y = (m_pVelocity.y + ((m_pAcc.y * m_pDamp.y) * _arg1));
if (((!((m_pMaxVelocity.x == -1))) && ((m_pVelocity.x > m_pMaxVelocity.x)))){
m_pVelocity.x = m_pMaxVelocity.x;
} else {
if (((!((m_pMaxVelocity.x == -1))) && ((m_pVelocity.x < (m_pMaxVelocity.x * -1))))){
m_pVelocity.x = (m_pMaxVelocity.x * -1);
};
};
if (((!((m_pMaxVelocity.y == -1))) && ((m_pVelocity.y > m_pMaxVelocity.y)))){
m_pVelocity.y = m_pMaxVelocity.y;
} else {
if (((!((m_pMaxVelocity.y == -1))) && ((m_pVelocity.y < (m_pMaxVelocity.y * -1))))){
m_pVelocity.y = (m_pMaxVelocity.y * -1);
};
};
x = (x + ((m_pVelocity.x * _arg1) * m_pDamp.x));
y = (y + ((m_pVelocity.y * _arg1) * m_pDamp.y));
}
public function setTimerOn(_arg1:Number):void{
if (m_timer){
m_timer.stop();
m_timer.removeEventListener(TimerEvent.TIMER, onTimer);
m_timer = null;
};
if ((((_arg1 > 0)) && ((_arg1 < Number.MAX_VALUE)))){
m_timer = new skxTimer(_arg1);
m_timer.addEventListener(TimerEvent.TIMER, onTimer, false, 0, true);
m_timer.start();
};
}
public function setMouseDrag(_arg1:Boolean):void{
var _local2:Point;
if (getWindow()){
m_bDragging = _arg1;
if (_arg1){
_local2 = getWindow().getMousePos();
m_oMouseMoveOffset = new Point((x - _local2.x), (y - _local2.y));
getWindow().m_aMouseDragArr[this] = this;
} else {
delete getWindow().m_aMouseDragArr[this];
};
};
}
public function setState(_arg1:String, _arg2:Boolean=false):void{
setAnimationState(_arg1, _arg2);
}
public function finishScaleTo(_arg1:Boolean=true):void{
if (!m_isScaling){
return;
};
if (_arg1){
scaleX = m_targetScaleX;
scaleY = m_targetScaleY;
};
m_isScaling = false;
m_targetScaleX = 1;
m_targetScaleY = 1;
m_targetMoveSpd = 0;
}
public function setStateDispatcher(_arg1:EventDispatcher, _arg2:Boolean=false){
if (_arg2){
_arg1.addEventListener(skxStateEvent.STATE, onState, false, 0, true);
} else {
_arg1.removeEventListener(skxStateEvent.STATE, onState);
};
}
public function scaleTo(_arg1:Number, _arg2:Number, _arg3:Number){
if (((m_oAnimator) && (m_bInMotion))){
m_bInMotion = false;
m_oAnimator.end();
};
m_isScaling = true;
m_targetScaleX = _arg1;
m_targetScaleY = _arg2;
m_targetScaleSpd = _arg3;
}
public function setAnimStates(_arg1:Dictionary):void{
m_animSeq = _arg1;
}
public function getGraphLineData():Dictionary{
return (m_dGraphLine);
}
public function onMouseOff():void{
}
public function getXPivot():Number{
return (m_pPivot.x);
}
public function getColor():Object{
return (m_oColor);
}
public function getYScrollSpeed():Number{
return (m_scrollYSpeed);
}
public function onStart(_arg1:Event=null):void{
if (m_bStarted != true){
m_bStarted = true;
};
}
public function getLifeSpan():Number{
return (m_nLifeSpan);
}
private function updateMotion(_arg1):void{
if (m_bInMotion){
if (m_nAnimatorTime >= m_nAnimatorTotalTime){
m_iAnimatorCurStep++;
m_nAnimatorTime = 0;
m_oAnimator.nextFrame();
};
m_nAnimatorTime = (m_nAnimatorTime + _arg1);
setFilter(filters);
};
}
protected function onState(_arg1:skxStateEvent=null):void{
var _local2:Array;
var _local3:String;
var _local4:String;
_local2 = _arg1.state().split("-");
if (_local2.length < 2){
skxDisplay.Error("Invalid state string sent.");
return;
};
_local3 = _local2[0];
_local4 = _local2[1];
if ((((_local3 == "ALL")) || ((_local3 == name)))){
switch (_local4){
case "DESTROY":
destroy();
return;
};
};
}
public function resetPhysics():void{
m_pAcc.x = 0;
m_pAcc.y = 0;
setVelocity(0, 0);
}
public function pointInSprite(_arg1:Number, _arg2:Number):Boolean{
var _local3:Point;
var _local4:Point;
var _local5:BitmapData;
if (m_sMouseCollisionType == "rect"){
if (getRectangle().contains(((_arg1 - x) - getXPivot()), ((_arg2 - y) - getYPivot()))){
return (true);
};
} else {
if (m_sMouseCollisionType == "pixel"){
_local3 = new Point(1, 1);
_local4 = new Point(((_arg1 - x) - getXPivot()), ((_arg2 - y) - getYPivot()));
if (((((getRectangle().contains(((_arg1 - x) - getXPivot()), ((_arg2 - y) - getYPivot()))) && (m_imageMap))) && (m_imageMap.getData((getFrame() - 1))))){
_local5 = m_imageMap.getData((getFrame() - 1));
if (_local5.hitTest(_local3, 0, _local4)){
return (true);
};
};
};
};
return (false);
}
public function setActive(_arg1:Boolean=true):void{
m_bActive = _arg1;
}
public function defaultAllGraphLines():void{
setGraphLine("scaleX");
setGraphLine("scaleY");
setGraphLine("posX");
setGraphLine("posY");
setGraphLine("rotation");
setGraphLine("alpha");
setGraphLine("forceX");
setGraphLine("forceY");
setGraphLine("dampX");
setGraphLine("dampY");
setGraphLine("velX");
setGraphLine("velY");
setGraphLine("frame");
setGraphLine("ro");
setGraphLine("go");
setGraphLine("bo");
}
public function setImage(_arg1):Boolean{
var _local2:String;
var _local3:skxImage;
var _local4:*;
_local2 = (_arg1 as String);
_local3 = (_arg1 as skxImage);
if (_local2){
m_sImageName = _local2;
_local4 = skxResourceMgr.getResource(_local2);
if (((_local4) && (_local4.DATA))){
m_imageMap = _local4.DATA;
m_Rows = _local4.ROWS;
m_Cols = _local4.COL;
m_height = (_local4.HEIGHT * _local4.SCALEY);
m_width = (_local4.WIDTH * _local4.SCALEX);
m_iTotalFrames = m_imageMap.getTotalFrames();
m_iCurrentFrame = 1;
m_xPitch = m_imageMap.m_nPitchX;
m_yPitch = m_imageMap.m_nPitchY;
setPivot(0.5, 0.5);
return (true);
};
return (false);
} else {
if (_local3){
m_imageMap = _local3;
m_Rows = _local3.m_iRows;
m_Cols = _local3.m_iCol;
m_height = (_local3.m_iHeight * _local3.m_nScaleY);
m_width = (_local3.m_iWidth * _local3.m_nScaleX);
m_iTotalFrames = m_imageMap.getTotalFrames();
m_iCurrentFrame = 1;
m_xPitch = m_imageMap.m_nPitchX;
m_yPitch = m_imageMap.m_nPitchY;
setPivot(0.5, 0.5);
return (true);
};
};
return (false);
}
public function setAlpha(_arg1:Number):void{
alpha = _arg1;
}
public function onMotionEnd():void{
}
public function moveTo(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Boolean=false):void{
var _local5:Number;
if (((m_oAnimator) && (m_bInMotion))){
m_bInMotion = false;
m_oAnimator.end();
};
m_isMoving = true;
m_targetMoveCallback = _arg4;
m_targetPositionX = _arg1;
m_targetPositionY = _arg2;
m_startPositionX = x;
m_startPositionY = y;
m_targetPosition = 0;
if ((((x == m_targetPositionX)) && ((y == m_targetPositionY)))){
finishMoveTo(true, m_targetMoveCallback);
return;
};
_local5 = skxUtil.getDistance(x, y, m_targetPositionX, m_targetPositionY);
m_targetMoveSpd = (_arg3 / _local5);
m_nTargetVelX = (m_targetPositionX - x);
m_nTargetVelY = (m_targetPositionY - y);
}
public function setFrame(_arg1:int):void{
if (((((m_imageMap) && ((_arg1 >= 1)))) && ((_arg1 <= m_imageMap.getTotalFrames())))){
m_iCurrentFrame = _arg1;
onFrameChange();
};
}
public function setYVelocity(_arg1:Number):void{
m_pVelocity.y = _arg1;
}
public function onAnimationEnd(_arg1:String):void{
}
public function getYPivot():Number{
return (m_pPivot.y);
}
public function checkVisibility(_arg1:Boolean):void{
m_bCheckVisibility = _arg1;
}
public function nextFrame():void{
var _local1:int;
if (m_imageMap){
_local1 = (getFrame() + 1);
if (_local1 > m_imageMap.getTotalFrames()){
_local1 = 1;
};
m_iCurrentFrame = _local1;
onFrameChange();
};
}
public function getVelocity():Point{
return (m_pVelocity);
}
protected function onMoveToTarget():void{
}
public function setDamp(_arg1:Number, _arg2:Number):void{
setXDamp(_arg1);
setYDamp(_arg2);
}
public function getSort():Boolean{
return (m_bSort);
}
public function getMount():skxSprite{
return (m_oMount);
}
public function setTimerOff():Boolean{
if (m_timer){
m_timer.stop();
return (true);
};
return (false);
}
public function setMass(_arg1:Number):void{
m_nMass = _arg1;
}
public function setYSort(_arg1:Number):void{
m_nYSort = _arg1;
}
public function setLife(_arg1:Number):void{
m_nLife = _arg1;
}
public function setFilter(_arg1:Array):void{
if (_arg1){
m_oFilter = _arg1;
} else {
clearFilter();
};
}
public function getFilter():Array{
return (m_oFilter);
}
protected function onUpdateGraph(_arg1:Number=0):void{
var _local2:Number;
var _local3:ColorTransform;
_local2 = 0;
if (m_nLife > m_nLifeSpan){
_local2 = 1;
} else {
if (((getLife()) && (m_nLifeSpan))){
_local2 = (getLife() / m_nLifeSpan);
};
};
if (m_dGraphLine["scaleX"]){
scaleX = getGraphLinePos("scaleX", _local2);
};
if (m_dGraphLine["scaleY"]){
scaleY = getGraphLinePos("scaleY", _local2);
};
if (m_dGraphLine["posX"]){
m_pGraphOffset.x = getGraphLinePos("posX", _local2);
};
if (m_dGraphLine["posY"]){
m_pGraphOffset.y = getGraphLinePos("posY", _local2);
};
if (m_dGraphLine["rotation"]){
rotation = getGraphLinePos("rotation", _local2);
};
if (m_dGraphLine["alpha"]){
alpha = getGraphLinePos("alpha", _local2);
};
if (m_dGraphLine["forceX"]){
setXForce(getGraphLinePos("forceX", _local2));
};
if (m_dGraphLine["forceY"]){
setYForce(getGraphLinePos("forceY", _local2));
};
if (m_dGraphLine["dampX"]){
setXDamp(getGraphLinePos("dampX", _local2));
};
if (m_dGraphLine["dampY"]){
setYDamp(getGraphLinePos("dampY", _local2));
};
if (m_dGraphLine["velX"]){
setXVelocity((getVelocity().x + (getGraphLinePos("velX", _local2) * _arg1)));
};
if (m_dGraphLine["velY"]){
setYVelocity((getVelocity().y + (getGraphLinePos("velY", _local2) * _arg1)));
};
if (m_dGraphLine["frame"]){
setFrame(getGraphLinePos("frame", _local2));
};
if (m_dGraphLine["ro"]){
_local3 = transform.colorTransform;
_local3.redOffset = (getGraphLinePos("ro", _local2) * _arg1);
transform.colorTransform = _local3;
};
if (m_dGraphLine["go"]){
_local3 = transform.colorTransform;
_local3.redOffset = (getGraphLinePos("go", _local2) * _arg1);
transform.colorTransform = _local3;
};
if (m_dGraphLine["bo"]){
_local3 = transform.colorTransform;
_local3.redOffset = (getGraphLinePos("bo", _local2) * _arg1);
transform.colorTransform = _local3;
};
}
public function getRectangle():Rectangle{
if (((((m_imageMap) && (getFrame()))) && (m_imageMap.getData((getFrame() - 1))))){
return (m_imageMap.getData((getFrame() - 1)).rect);
};
return (null);
}
private function onMotionComplete(_arg1:Event=null):void{
m_bInMotion = false;
m_nAnimatorTime = 0;
m_oAnimator = null;
onMotionEnd();
}
public function getState():String{
return (m_sState);
}
public function resetTransform():void{
scaleX = 1;
scaleY = 1;
rotation = 0;
alpha = 1;
}
private function updateRollOver():void{
var _local1:Point;
var _local2:Boolean;
if (((!(getRectangle())) || (!(mouseEnabled)))){
return;
};
_local1 = getWindow().getMousePos();
_local2 = false;
if (pointInSprite(_local1.x, _local1.y)){
_local2 = true;
};
if (((!(m_bMouseOver)) && (_local2))){
if (!getWindow().getSingleMouseFocus()){
onMouseOver();
m_bMouseOver = true;
getWindow().setObjFocus(this);
} else {
if (getWindow().getObjFocus() == null){
onMouseOver();
m_bMouseOver = true;
getWindow().setObjFocus(this);
};
};
} else {
if (((m_bMouseOver) && (((!(_local2)) || (!(visible)))))){
if (!getWindow().getSingleMouseFocus()){
onMouseOff();
m_bMouseOver = false;
} else {
if (getWindow().getObjFocus() == this){
onMouseOff();
m_bMouseOver = false;
getWindow().setObjFocus(null);
};
};
};
};
}
public function setProp(_arg1:Dictionary):void{
if (_arg1["image"]){
setImage(String(_arg1["image"]));
};
if (_arg1["depth"]){
setDepth(_arg1["depth"]);
};
if (_arg1["x"]){
x = _arg1["x"];
};
if (_arg1["y"]){
y = _arg1["y"];
};
if (_arg1["frame"]){
setFrame(_arg1["frame"]);
};
if (_arg1["name"]){
name = _arg1["name"];
};
if (_arg1["alpha"]){
alpha = _arg1["alpha"];
};
if (_arg1["scalex"]){
scaleX = _arg1["scalex"];
};
if (_arg1["scaley"]){
scaleY = _arg1["scaley"];
};
if (_arg1["rotation"]){
rotation = _arg1["rotation"];
};
if (_arg1["sortx"]){
setXSort(_arg1["sortx"]);
};
if (_arg1["sorty"]){
setYSort(_arg1["sorty"]);
};
}
public function getWindow():skxWindow{
return (m_oWindow);
}
public function setLifeSpan(_arg1:Number):void{
m_nLifeSpan = _arg1;
}
public function setXSort(_arg1:Number):void{
m_nXSort = _arg1;
}
public function setWindow(_arg1:skxWindow):void{
m_oWindow = _arg1;
}
public function prevFrame():void{
var _local1:int;
if (m_imageMap){
_local1 = (getFrame() - 1);
if (_local1 <= 0){
_local1 = m_imageMap.getTotalFrames();
};
m_iCurrentFrame = _local1;
onFrameChange();
};
}
public function isScaling():Boolean{
return (m_isScaling);
}
public function getGraphLinePos(_arg1:String, _arg2:Number):Number{
var _local3:Array;
var _local4:int;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:Number;
if (m_dGraphLine[_arg1]){
_local3 = m_dGraphLine[_arg1];
_local4 = (_local3.length - 1);
while (_local4 >= 0) {
if (_arg2 >= _local3[_local4].x){
break;
};
_local4--;
};
if (((_local3[_local4]) && (_local3[(_local4 + 1)]))){
_local5 = (_local3[_local4].y - _local3[(_local4 + 1)].y);
_local6 = (_local3[_local4].x - _local3[(_local4 + 1)].x);
_local7 = (_local5 / _local6);
if (_local7){
_local8 = (_local3[_local4].y - (_local7 * _local3[_local4].x));
return (((_local7 * _arg2) + _local8));
};
return (_local3[_local4].y);
} else {
if (_local3[_local4]){
return (_local3[_local4].y);
};
};
};
return (0);
}
public function onMouseClick(_arg1:Number, _arg2:Number){
}
public function setXVelocity(_arg1:Number):void{
m_pVelocity.x = _arg1;
}
public function setWindowDispatcher(_arg1:EventDispatcher, _arg2:Boolean=false){
if (_arg2){
_arg1.addEventListener(Event.MOUSE_LEAVE, onWindowEvent, false, 0, true);
} else {
_arg1.removeEventListener(Event.MOUSE_LEAVE, onWindowEvent);
};
}
public function onMouseUp(_arg1:Number, _arg2:Number){
}
public function resetColor():void{
setColor(1, 1, 1);
}
public function getDamp():Point{
return (m_pDamp);
}
public function setVelocity(_arg1:Number, _arg2:Number):void{
setXVelocity(_arg1);
setYVelocity(_arg2);
}
public function getAnimStates():Dictionary{
return (m_animSeq);
}
public function getMass():Number{
return (m_nMass);
}
public function setXScrollSpeed(_arg1:Number){
m_scrollXSpeed = _arg1;
}
public function getLife():Number{
return (m_nLife);
}
public function setDepth(_arg1:int):void{
m_Depth = _arg1;
}
public function copyMotion(_arg1:XML, _arg2:Number=1, _arg3:int=1, _arg4:Function=null):void{
var f:Function;
var xml = _arg1;
var time = _arg2;
var steps = _arg3;
var custFun = _arg4;
if (((m_oAnimator) && (m_bInMotion))){
m_oAnimator.end();
};
m_bInMotion = true;
m_oAnimator = new Animator(xml, this);
m_nAnimatorTotalTime = Number((time / steps));
m_nAnimatorTime = 0;
m_iAnimatorTotalStep = steps;
m_iAnimatorCurStep = 0;
m_oAnimator.time = 0;
f = function (_arg1:Object=null):void{
m_oAnimator.removeEventListener(MotionEvent.MOTION_END, f);
onMotionComplete();
if (((this) && (custFun))){
custFun.call();
custFun = null;
};
f = null;
};
m_oAnimator.addEventListener(MotionEvent.MOTION_END, f);
}
public function getIsMoving():Boolean{
return (m_isMoving);
}
public function onUpdate(_arg1:Number=0):void{
if (m_bDead){
return;
};
if (m_bUpdatable){
if (m_nLifeSpan != -1){
m_nLife = (m_nLife + _arg1);
onUpdateGraph(_arg1);
if ((((m_nLifeSpan < m_nLife)) && (m_bkillAtLifeSpan))){
m_bDead = true;
onDeath();
return;
};
};
if (isActive()){
updateAnimation(_arg1);
updateMoveTo(_arg1);
updateScaleTo(_arg1);
updatePhysics(_arg1);
};
};
updateTrackedObjects();
if (getWindow()){
updateRollOver();
if (((((((((getWindow().getCurBuffer()) && (!((getWindow().scaleX == 0))))) && (!((getWindow().scaleY == 0))))) && (!((getWindow().alpha == 0))))) && (getWindow().visible))){
onRender(getWindow().getCurBuffer());
};
if (((mouseEnabled) && (m_iMouseAdded))){
m_iMouseAdded = false;
};
};
}
public function setForce(_arg1:Number, _arg2:Number):void{
setXForce(_arg1);
setYForce(_arg2);
}
public function getGraphLine(_arg1):Array{
return (m_dGraphLine[_arg1]);
}
public function setYDamp(_arg1:Number):void{
m_pDamp.y = _arg1;
}
private function updateTrackedObjects():void{
var _local1:int;
if (m_aTrackedObjects){
_local1 = 0;
while (_local1 < m_aTrackedObjects.length) {
m_aTrackedObjects[_local1].x = x;
m_aTrackedObjects[_local1].y = y;
m_aTrackedObjects[_local1].scaleX = scaleX;
m_aTrackedObjects[_local1].scaleY = scaleY;
m_aTrackedObjects[_local1].alpha = alpha;
m_aTrackedObjects[_local1].rotation = rotation;
_local1++;
};
};
}
public function getImage():skxImage{
return (m_imageMap);
}
protected function onScaleToTarget():void{
}
public function getFrame():int{
return (m_iCurrentFrame);
}
public function onMouseDown(_arg1:Number, _arg2:Number){
}
public function getTotalFrames():int{
return (m_iTotalFrames);
}
protected function onDeath():void{
destroy();
}
public function getImageName():String{
return (m_sImageName);
}
public function setAutoRotation(_arg1:Number){
m_autoRotation = _arg1;
}
public function isVisible():Boolean{
var _local1:Point;
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Number;
if (((getWindow()) && ((rotation == 0)))){
_local1 = getWindow().getCameraPos();
_local2 = (getXPitch() * scaleX);
_local3 = (getYPitch() * scaleY);
_local4 = (x - (m_pPivotRatio.x * _local2));
_local5 = (x + (_local2 - (m_pPivotRatio.x * _local2)));
_local6 = (y - (m_pPivotRatio.y * _local3));
_local7 = (y + (_local3 - (m_pPivotRatio.y * _local3)));
if (((((_local4 - _local1.x) > getWindow().m_iScrWidth)) || (((_local5 - _local1.x) < 0)))){
return (false);
};
if (((((_local6 - _local1.y) > getWindow().m_iScrHeight)) || (((_local7 - _local1.y) < 0)))){
return (false);
};
};
return (true);
}
public function setGraphLineData(_arg1:Dictionary):void{
m_dGraphLine = _arg1;
}
public function destroy():void{
var _local1:int;
setActive(false);
m_bDead = true;
setTimerOff();
setMouseEnabled(false);
setMouseDrag(false);
alpha = 0;
visible = false;
if (m_imageMap){
m_imageMap = null;
};
disMount();
_local1 = 0;
while (_local1 < this.numChildren) {
removeChildAt(_local1);
_local1++;
};
if (m_timer){
m_timer.removeEventListener(TimerEvent.TIMER, onTimer);
};
if (m_oWindow){
m_oWindow.removeObject(this);
m_oWindow = null;
};
delete ??getglobalscope
[this];
}
}
}//package skxSource
Section 143
//skxStateEvent (skxSource.skxStateEvent)
package skxSource {
import flash.events.*;
public class skxStateEvent extends Event {
private var _state:String;// = ""
public static const STATE:String = "State";
public function skxStateEvent(_arg1:String, _arg2:String, _arg3:Boolean=true, _arg4:Boolean=false):void{
_state = "";
_state = _arg2;
super(_arg1, _arg3, _arg4);
}
public function state():String{
return (_state);
}
override public function clone():Event{
return (new skxStateEvent(type, _state));
}
}
}//package skxSource
Section 144
//skxSystem (skxSource.skxSystem)
package skxSource {
import flash.media.*;
import flash.system.*;
public class skxSystem {
private static var s_iSoundDeviceEnabled:int = -1;
public static function showCapabilities():void{
}
public static function getMajorVersion():String{
var _local1:String;
var _local2:Array;
var _local3:Array;
var _local4:String;
_local1 = Capabilities.version;
_local2 = _local1.split(",");
_local3 = _local2[0].split(" ");
_local4 = _local3[1];
return (_local4);
}
public static function checkVersion(_arg1:String):Boolean{
var _local2:String;
var _local3:Array;
var _local4:Array;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:Array;
var _local9:Number;
var _local10:Number;
var _local11:Number;
_local2 = Capabilities.version;
_local3 = _local2.split(",");
_local4 = _local3[0].split(" ");
_local5 = parseInt(_local4[1]);
_local6 = parseInt(_local3[1]);
_local7 = parseInt(_local3[2]);
_local8 = _arg1.split(".");
_local9 = parseInt(_local8[0]);
_local10 = parseInt(_local8[1]);
_local11 = parseInt(_local8[2]);
if (_local5 > _local9){
return (true);
};
if ((((_local5 >= _local9)) && ((_local6 > _local10)))){
return (true);
};
if ((((((_local5 >= _local9)) && ((_local6 >= _local10)))) && ((_local7 >= _local11)))){
return (true);
};
return (false);
}
public static function getMinorVersion():String{
var _local1:String;
var _local2:Array;
var _local3:Array;
var _local4:String;
_local1 = Capabilities.version;
_local2 = _local1.split(",");
_local3 = _local2[0].split(" ");
_local4 = _local2[1];
return (_local4);
}
public static function getPlatform():String{
var _local1:String;
var _local2:Array;
var _local3:Array;
_local1 = Capabilities.version;
_local2 = _local1.split(",");
_local3 = _local2[0].split(" ");
if (_local3.length > 0){
return (_local3[0]);
};
return ("UNABLE TO DETECT PLATFORM.");
}
public static function getFullVersion():String{
var _local1:String;
var _local2:Array;
var _local3:Array;
var _local4:String;
var _local5:String;
var _local6:String;
_local1 = Capabilities.version;
_local2 = _local1.split(",");
_local3 = _local2[0].split(" ");
_local4 = _local3[1];
_local5 = _local2[1];
_local6 = _local2[2];
return (String(((((_local4 + ".") + _local5) + ".") + _local6)));
}
public static function checkSoundDevice():Boolean{
return (true);
}
public static function getBuildNumber():String{
var _local1:String;
var _local2:Array;
var _local3:Array;
var _local4:String;
_local1 = Capabilities.version;
_local2 = _local1.split(",");
_local3 = _local2[0].split(" ");
_local4 = _local2[2];
return (_local4);
}
}
}//package skxSource
Section 145
//skxTimer (skxSource.skxTimer)
package skxSource {
import flash.events.*;
import flash.utils.*;
public class skxTimer extends Timer {
public var name:String;// = ""
private var m_bIgnoreTimeShift:Boolean;// = false
private var m_bStopped:Boolean;// = true
private var m_iStartTime:int;// = 0
public var m_iDefaultDelay:int;// = 0
private static var m_aTimerContainer:Array = new Array();
public function skxTimer(_arg1:Number, _arg2:int=0, _arg3:Boolean=false):void{
name = "";
m_iStartTime = 0;
m_iDefaultDelay = 0;
m_bIgnoreTimeShift = false;
m_bStopped = true;
m_aTimerContainer.push(this);
m_iDefaultDelay = _arg1;
m_bIgnoreTimeShift = _arg3;
m_bStopped = true;
super(_arg1, _arg2);
}
override public function stop():void{
var _local1:Number;
super.stop();
if ((((m_bIgnoreTimeShift == false)) && ((m_bStopped == false)))){
addEventListener(TimerEvent.TIMER, resetDelay);
m_bStopped = true;
_local1 = (m_iDefaultDelay - (getTimer() - m_iStartTime));
if (_local1 > 0){
delay = _local1;
} else {
delay = 25;
};
};
}
private function onHit(_arg1:TimerEvent):void{
m_iStartTime = getTimer();
}
override public function start():void{
if ((((m_bIgnoreTimeShift == false)) && ((m_bStopped == true)))){
m_iStartTime = getTimer();
m_bStopped = false;
addEventListener(TimerEvent.TIMER, onHit);
};
super.start();
}
private function resetDelay(_arg1:TimerEvent):void{
delay = m_iDefaultDelay;
removeEventListener(TimerEvent.TIMER, resetDelay);
}
public static function clear():void{
var _local1:int;
_local1 = 0;
while (_local1 < m_aTimerContainer.length) {
m_aTimerContainer[_local1].stop();
m_aTimerContainer[_local1] = null;
_local1++;
};
m_aTimerContainer = null;
m_aTimerContainer = new Array();
}
}
}//package skxSource
Section 146
//skxUser (skxSource.skxUser)
package skxSource {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.media.*;
import mdm.*;
import flash.net.*;
import flash.system.*;
public class skxUser {
private static var m_sCurrentUser:String = "";
private static var m_sLocalID:String = "";
private static var m_oData:Dictionary = new Dictionary(true);
private static var m_bSaving:Boolean = false;
private static var m_iUserCount:int = 0;
public static function isSaving():Boolean{
return (m_bSaving);
}
public static function userExists(_arg1:String=""):Boolean{
if (_arg1 == ""){
if (m_oData[m_sCurrentUser]){
return (true);
};
return (false);
};
if (m_oData[_arg1]){
return (true);
};
return (false);
}
public static function setCurData(_arg1:String, _arg2):Boolean{
return (setData(m_sCurrentUser, _arg1, _arg2));
}
public static function setLocalID(_arg1:String):void{
m_sLocalID = _arg1;
}
public static function setUser(_arg1:String):Boolean{
if (_arg1 == ""){
return (false);
};
if (userExists(_arg1)){
m_sCurrentUser = _arg1;
return (true);
};
m_oData[_arg1] = new Dictionary(true);
m_sCurrentUser = _arg1;
m_iUserCount++;
return (false);
}
public static function getAllUserNames():Array{
var _local1:Array;
var _local2:*;
_local1 = new Array();
for (_local2 in m_oData) {
if (m_oData[_local2]){
_local1.push(String(_local2));
};
};
return (_local1);
}
public static function getUserCount():int{
return (m_iUserCount);
}
public static function deleteUser(_arg1:String):Boolean{
var _local2:Dictionary;
var _local3:*;
if (m_oData[_arg1]){
m_oData[_arg1] = null;
_local2 = new Dictionary(true);
for (_local3 in m_oData) {
if (m_oData[_local3]){
_local2[_local3] = m_oData[_local3];
};
};
m_oData = _local2;
m_iUserCount = (m_iUserCount - 1);
};
if (_arg1 == m_sCurrentUser){
m_sCurrentUser = "";
return (true);
};
return (false);
}
public static function storeLocally(_arg1:String):Boolean{
var _local2:Dictionary;
var _local3:String;
var _local4:*;
var _local5:*;
if (m_oData[_arg1]){
m_bSaving = true;
_local2 = getUserData(_arg1);
_local3 = String(("USER=" + _arg1));
for (_local4 in _local2) {
_local3 = (_local3 + String(((("\n" + _local4) + "|") + _local2[_local4])));
};
_local5 = SharedObject.getLocal(m_sLocalID);
_local5.data[_arg1] = _local3;
if (_local5.flush()){
m_bSaving = false;
};
return (true);
};
m_bSaving = false;
return (false);
}
public static function storeCurLocally():Boolean{
return (storeLocally(m_sCurrentUser));
}
public static function getUserData(_arg1:String):Dictionary{
if (!m_oData[_arg1]){
m_oData[_arg1] = new Dictionary(true);
m_iUserCount++;
};
return (m_oData[_arg1]);
}
public static function getCurData(_arg1:String):Object{
return (getData(m_sCurrentUser, _arg1));
}
public static function changeUserName(_arg1:String, _arg2:String):void{
m_oData[_arg2] = m_oData[_arg1];
m_oData[_arg1] = null;
}
public static function getData(_arg1:String, _arg2:String):Object{
var _local3:Dictionary;
if (userExists(_arg1)){
_local3 = getUserData(_arg1);
if (_local3[_arg2]){
return (_local3[_arg2]);
};
return (null);
};
return (null);
}
public static function storeAllUsers():void{
var _local1:*;
m_bSaving = true;
for (_local1 in m_oData) {
if (m_oData[_local1]){
storeLocally(String(_local1));
};
};
m_bSaving = false;
}
public static function setData(_arg1:String, _arg2:String, _arg3):Boolean{
var _local4:Dictionary;
if (_arg1 == ""){
return (false);
};
_local4 = getUserData(_arg1);
if (getData(_arg1, _arg2)){
_local4[_arg2] = _arg3;
return (true);
};
_local4[_arg2] = _arg3;
return (false);
}
public static function getCurrentUser():String{
return (m_sCurrentUser);
}
public static function clearLocalData():Boolean{
var _local1:*;
m_sCurrentUser = "";
m_iUserCount = 0;
_local1 = SharedObject.getLocal(m_sLocalID);
if (_local1){
_local1.clear();
return (true);
};
return (false);
}
public static function loadLocally(_arg1:String):Boolean{
var _local2:*;
var _local3:String;
var _local4:Array;
var _local5:int;
var _local6:Array;
if (_arg1 == ""){
return (false);
};
_local2 = SharedObject.getLocal(m_sLocalID);
if (_local2){
if (_local2.data[_arg1]){
_local3 = _local2.data[_arg1];
_local4 = _local3.split("\n");
_local5 = 1;
while (_local5 < _local4.length) {
_local6 = _local4[_local5].split("|");
if (_local6.length == 2){
setData(_arg1, String(_local6[0]), _local6[1]);
};
_local5++;
};
if (_local4.length > 0){
return (true);
};
};
};
return (false);
}
public static function loadAllUsers():Boolean{
var _local1:SharedObject;
var _local2:int;
var _local3:*;
_local1 = SharedObject.getLocal(m_sLocalID);
if (_local1){
_local2 = 0;
for (_local3 in _local1.data) {
m_sCurrentUser = _local3;
loadLocally(m_sCurrentUser);
_local2++;
};
if (_local2){
return (true);
};
};
return (false);
}
}
}//package skxSource
Section 147
//skxUtil (skxSource.skxUtil)
package skxSource {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
import flash.geom.*;
import flash.media.*;
import flash.filters.*;
public class skxUtil {
public static function popFromArray(_arg1:int, _arg2:Array):Object{
var _local3:int;
var _local4:*;
if ((((((_arg2.length > 0)) && ((_arg1 < _arg2.length)))) && ((_arg1 >= 0)))){
_local3 = _arg1;
_local4 = _arg2[_local3];
removeObjectFromArray(_local4, _arg2);
return (_local4);
};
return (null);
}
public static function getMoney(_arg1):String{
var _local2:String;
var _local3:String;
var _local4:int;
var _local5:int;
var _local6:String;
_local2 = String(_arg1);
_local3 = "";
if (_local2.length <= 3){
return (_local2);
};
_local4 = (_local2.length - 1);
_local5 = 0;
while (_local4 >= 0) {
if (_local5 == 3){
_local3 = (_local3 + ",");
_local5 = 0;
};
_local3 = (_local3 + _local2.charAt(_local4));
_local4--;
_local5++;
};
_local6 = "";
_local4 = (_local3.length - 1);
while (_local4 >= 0) {
_local6 = (_local6 + _local3.charAt(_local4));
_local4--;
};
return (_local6);
}
public static function displayChildrenName(_arg1):void{
var _local2:int;
_local2 = 0;
while (_local2 < _arg1.numChildren) {
if (_arg1.getChildAt(_local2)){
};
_local2++;
};
}
public static function skxBounceIn(_arg1:Number):Number{
return ((1 - skxBounceOut((1 - _arg1))));
}
public static function getVolume():Number{
return (SoundMixer.soundTransform.volume);
}
public static function CatmullRom(_arg1:Point, _arg2:Point, _arg3:Point, _arg4:Point, _arg5:Number):Point{
var _local6:Number;
var _local7:Number;
var _local8:Point;
_local6 = (_arg5 * _arg5);
_local7 = (_local6 * _arg5);
_local8 = new Point();
_local8.x = (0.5 * ((((2 * _arg2.x) + ((-(_arg1.x) + _arg3.x) * _arg5)) + (((((2 * _arg1.x) - (5 * _arg2.x)) + (4 * _arg3.x)) - _arg4.x) * _local6)) + ((((-(_arg1.x) + (3 * _arg2.x)) - (3 * _arg3.x)) + _arg4.x) * _local7)));
_local8.y = (0.5 * ((((2 * _arg2.y) + ((-(_arg1.y) + _arg3.y) * _arg5)) + (((((2 * _arg1.y) - (5 * _arg2.y)) + (4 * _arg3.y)) - _arg4.y) * _local6)) + ((((-(_arg1.y) + (3 * _arg2.y)) - (3 * _arg3.y)) + _arg4.y) * _local7)));
return (_local8);
}
public static function getAbsInt(_arg1:uint):uint{
return (((_arg1 < 0)) ? -(_arg1) : _arg1);
}
public static function goToAndStopChildren(_arg1:MovieClip, _arg2):void{
var _local3:int;
var _local4:MovieClip;
_local3 = 0;
while (_local3 < _arg1.length) {
_local4 = (_arg1.getChildAt(_local3) as MovieClip);
if (_local4){
_local4.gotoAndStop(_arg2);
};
_local3++;
};
}
public static function fadeTo(_arg1, _arg2:int, _arg3:int, _arg4:Number, _arg5:Function=null):void{
var i:int;
var factor:Number;
var f:Function;
var obj = _arg1;
var ms = _arg2;
var steps = _arg3;
var alp = _arg4;
var cb = _arg5;
if ((((((obj.alpha == alp)) || ((steps == 0)))) || (!(obj)))){
return;
};
i = 0;
factor = ((alp - obj.alpha) / steps);
f = function ():void{
if ((((i >= steps)) || ((obj.alpha == alp)))){
f = null;
obj.alpha = alp;
if (cb != null){
skxScheduler.schedule(cb.call, 10);
};
return;
} else {
obj.alpha = (obj.alpha + factor);
i++;
skxScheduler.schedule(f, (ms / steps));
};
};
skxScheduler.schedule(f, (ms / steps));
}
public static function skxQuadIn(_arg1:Number):Number{
return ((_arg1 * _arg1));
}
public static function setVolume(_arg1:Number):void{
var _local2:SoundTransform;
_local2 = SoundMixer.soundTransform;
_local2.volume = _arg1;
SoundMixer.soundTransform = _local2;
}
public static function displayPivot(_arg1){
var _local2:int;
var _local3:Shape;
_local2 = 0;
while (_local2 < _arg1.numChildren) {
_local3 = new Shape();
_local3.graphics.beginFill(0xFF0000);
_local3.graphics.drawRect(0, 0, 5, 5);
_local3.graphics.endFill();
_local3.x = -2.5;
_local3.y = -2.5;
_arg1.getChildAt(_local2).addChild(_local3);
_local2++;
};
}
public static function hopTo(_arg1, _arg2:Point, _arg3:Number, _arg4:int, _arg5:int, _arg6:Function=null, _arg7:Function=null, _arg8:Function=null){
var steps:Number;
var spos:Point;
var cpos:Point;
var tpos:Point;
var vec:Point;
var tStep:Number;
var t:Number;
var i:int;
var pi:Number;
var midpoint:Boolean;
var f:Function;
var obj = _arg1;
var pos = _arg2;
var height = _arg3;
var step = _arg4;
var time = _arg5;
var midFn = _arg6;
var endFn = _arg7;
var stepFn = _arg8;
steps = (1 / step);
spos = new Point(obj.x, obj.y);
cpos = new Point(((obj.x + pos.x) / 2), ((obj.y + pos.y) / 2));
tpos = new Point(cpos.x, (Math.min(cpos.y, spos.y) + height));
vec = new Point();
vec.y = (height * -1);
vec.x = 0;
tStep = (time / step);
t = 0;
i = 0;
pi = (Math.PI / 180);
midpoint = false;
f = function ():void{
var _local1:Number;
var _local2:Number;
var _local3:Number;
var _local4:Number;
if (t < 1){
if ((((t >= 0.5)) && ((midpoint == false)))){
if (midFn != null){
midFn.call(null);
};
midpoint = true;
};
_local1 = t;
if (stepFn){
_local1 = stepFn.call(null, t);
};
_local2 = (((1 - _local1) * spos.x) + (_local1 * pos.x));
_local3 = (((1 - _local1) * spos.y) + (_local1 * pos.y));
_local4 = Math.sin(((_local1 * 180) * pi));
obj.x = (_local2 + (vec.x * _local4));
obj.y = (_local3 + (vec.y * _local4));
i++;
t = (t + steps);
} else {
obj.x = pos.x;
obj.y = pos.y;
if (endFn != null){
endFn.call(null);
};
f = null;
return;
};
skxScheduler.schedule(f, tStep);
};
skxScheduler.schedule(f, tStep);
}
public static function safeInsert(_arg1, _arg2:Array):Array{
var _local3:int;
_local3 = 0;
while (_local3 < _arg2.length) {
if (_arg2[_local3] == _arg1){
return (_arg2);
};
_local3++;
};
_arg2.push(_arg1);
return (_arg2);
}
public static function transferObjects(_arg1:MovieClip):MovieClip{
var _local2:MovieClip;
var _local3:int;
var _local4:*;
_local2 = new MovieClip();
_local2.gotoAndStop(1);
_local3 = 0;
while (_local3 < _arg1.numChildren) {
_local4 = _arg1.getChildAt(_local3);
if (_local4){
_local2.addChild(_local4);
_local2[_local4.name] = _local4;
};
_local3++;
};
return (_local2);
}
public static function moveTo(_arg1, _arg2:int, _arg3:int, _arg4:Number, _arg5:Number, _arg6:Function=null):void{
var i:int;
var factorx:Number;
var factory:Number;
var f:Function;
var obj = _arg1;
var ms = _arg2;
var steps = _arg3;
var x = _arg4;
var y = _arg5;
var cb = _arg6;
if ((((((((obj.x == x)) && ((obj.y == y)))) || ((steps == 0)))) || (!(obj)))){
return;
};
i = 0;
factorx = ((x - obj.x) / steps);
factory = ((y - obj.y) / steps);
f = function ():void{
if ((((i >= steps)) || ((((obj.x == x)) && ((obj.y == y)))))){
obj.x = x;
obj.y = y;
f = null;
if (cb != null){
skxScheduler.schedule(cb.call, 10);
};
return;
} else {
obj.x = (obj.x + factorx);
obj.y = (obj.y + factory);
skxScheduler.schedule(f, (ms / steps));
};
i++;
};
skxScheduler.schedule(f, (ms / steps));
}
public static function getColor(_arg1:Number, _arg2:Number, _arg3:Number):Number{
var _local4:String;
_local4 = ((("0x" + _arg1.toString(16)) + _arg2.toString(16)) + _arg3.toString(16));
return (parseInt(_local4, 16));
}
public static function blendTo(_arg1, _arg2:int, _arg3:int, _arg4:Number, _arg5:Number, _arg6:Number=0, _arg7:Number=1, _arg8:Function=null):void{
var bc:ColorTransform;
var bb:Number;
var br:Number;
var bg:Number;
var ba:Number;
var i:Number;
var f:Function;
var obj = _arg1;
var ms = _arg2;
var steps = _arg3;
var r = _arg4;
var g = _arg5;
var b = _arg6;
var a = _arg7;
var cb = _arg8;
if (((!(obj)) || (!(obj.transform)))){
return;
};
bc = obj.transform.colorTransform;
bb = bc.blueMultiplier;
br = bc.redMultiplier;
bg = bc.greenMultiplier;
ba = bc.alphaMultiplier;
i = 0;
f = function ():void{
var _local1:Number;
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
_local1 = (i / ms);
if (_local1 >= 1){
bc.blueMultiplier = _local4;
bc.redMultiplier = _local2;
bc.greenMultiplier = _local3;
obj.alpha = _local5;
obj.transform.colorTransform = bc;
f = null;
if (cb != null){
skxScheduler.schedule(cb.call, 10);
};
return;
};
_local2 = (((1 - _local1) * br) + (_local1 * r));
_local3 = (((1 - _local1) * bg) + (_local1 * g));
_local4 = (((1 - _local1) * bb) + (_local1 * b));
_local5 = (((1 - _local1) * ba) + (_local1 * a));
bc.blueMultiplier = _local4;
bc.redMultiplier = _local2;
bc.greenMultiplier = _local3;
obj.alpha = _local5;
obj.transform.colorTransform = bc;
i = (i + (ms / steps));
skxScheduler.schedule(f, (ms / steps));
};
skxScheduler.schedule(f, (ms / steps));
}
public static function fadeVolume(_arg1:Number, _arg2:Number, _arg3:int):void{
var i:int;
var factor:Number;
var f:Function;
var nVol = _arg1;
var ms = _arg2;
var steps = _arg3;
i = 0;
factor = ((nVol - getVolume()) / steps);
f = function ():void{
skxUtil.setVolume((getVolume() + factor));
if ((((skxUtil.getVolume() == nVol)) || ((i >= steps)))){
skxUtil.setVolume(nVol);
f = null;
return;
};
skxScheduler.schedule(f, (ms / steps));
i++;
};
skxScheduler.schedule(f, (ms / steps));
}
public static function clamp(_arg1:Number, _arg2:Number, _arg3:Number):Number{
if (_arg1 < _arg2){
return (_arg2);
};
if (_arg1 > _arg3){
return (_arg3);
};
return (_arg1);
}
public static function getModulus(_arg1:Number, _arg2:Number):Number{
return ((_arg1 & (_arg2 - 1)));
}
public static function blurTo(_arg1, _arg2:int, _arg3:int, _arg4:Number, _arg5:Number, _arg6:Number=0, _arg7:Number=0):void{
var i:int;
var xfactor:Number;
var yfactor:Number;
var xp:Number;
var yp:Number;
var def:*;
var t:Number;
var f:Function;
var obj = _arg1;
var ms = _arg2;
var steps = _arg3;
var xb = _arg4;
var yb = _arg5;
var sx = _arg6;
var sy = _arg7;
i = 0;
xfactor = (xb / steps);
yfactor = (yb / steps);
xp = sx;
yp = sy;
def = obj.filters;
t = (ms / steps);
f = function ():void{
if ((((i >= steps)) || ((obj.visible == false)))){
obj.filters = def;
obj.visible = false;
f = null;
return;
};
obj.filters = [new BlurFilter(xp, yp, 2)];
skxScheduler.schedule(f, t);
xp = (xp + xfactor);
yp = (yp + yfactor);
i++;
};
skxScheduler.schedule(f, t);
}
public static function removeObjectFromArray(_arg1, _arg2:Array):void{
_arg2.splice(_arg2.indexOf(_arg1), 1);
}
public static function skxQuadOut(_arg1:Number):Number{
var _local2:Number;
_local2 = (1 - _arg1);
return ((1 - (_local2 * _local2)));
}
public static function skxSineOut(_arg1:Number):Number{
return (Math.sin((_arg1 * (Math.PI / 2))));
}
public static function displayAllChildrenName(_arg1, _arg2:int=0):void{
var _local3:int;
var _local4:String;
_local3 = _arg2;
_local4 = "";
while (_local3) {
_local3--;
_local4 = String((_local4 + " "));
};
if ((_arg1 as DisplayObjectContainer)){
_local3 = 0;
while (_local3 < _arg1.numChildren) {
if (_arg1.getChildAt(_local3)){
displayAllChildrenName(_arg1.getChildAt(_local3), (_arg2 + 1));
};
_local3++;
};
};
}
public static function quickShuffle(_arg1:Array):Array{
var _local2:int;
var _local3:Array;
var _local4:int;
var _local5:int;
var _local6:Object;
_local2 = _arg1.length;
_local3 = _arg1.slice();
_local5 = 0;
while (_local5 < _local2) {
_local4 = skxRandom.getRandomInt(0, (_local2 - 1));
_local3[_local4] = _arg1[_local5];
_local5++;
};
return (_local3);
}
public static function skxCubicIn(_arg1:Number):Number{
return (((_arg1 * _arg1) * _arg1));
}
public static function stringToDict(_arg1:String):Dictionary{
var _local2:Array;
var _local3:Dictionary;
var _local4:int;
var _local5:Array;
var _local6:String;
_local2 = _arg1.split("\n");
_local3 = new Dictionary();
_local4 = 0;
while (_local4 < _local2.length) {
if (((_local2[_local4]) && (!((_local2[_local4].charAt(0) == "#"))))){
_local5 = _local2[_local4].split(",");
_local6 = _local5[0];
popFromArray(0, _local5);
_local3[_local6] = _local5;
};
_local4++;
};
return (_local3);
}
public static function skxSineIn(_arg1:Number):Number{
return ((1 - Math.cos((_arg1 * (Math.PI / 2)))));
}
public static function playMovieClip(_arg1:MovieClip, _arg2:int, _arg3:int, _arg4:int, _arg5:int=0):void{
var _local6:int;
_local6 = 0;
while (_local6 < _arg3) {
skxScheduler.schedule(_arg1.gotoAndStop, ((_local6 * _arg4) + _arg5), null, (_arg2 + _local6));
_local6++;
};
}
public static function parseXMLArray(_arg1:XML):Array{
var _local2:Array;
var _local3:XMLList;
var _local4:XML;
_local2 = new Array();
_local3 = _arg1.children();
for each (_local4 in _local3) {
_local2.push(_local4);
};
return (_local2);
}
public static function duplicateDisplayObject(_arg1:DisplayObject, _arg2:Boolean=false):DisplayObject{
var _local3:Class;
var _local4:DisplayObject;
var _local5:Rectangle;
_local3 = _arg1["constructor"];
_local4 = new (_local3);
_local4.transform = _arg1.transform;
_local4.filters = _arg1.filters;
_local4.cacheAsBitmap = _arg1.cacheAsBitmap;
_local4.opaqueBackground = _arg1.opaqueBackground;
if (_arg1.scale9Grid){
_local5 = _arg1.scale9Grid;
_arg1.scale9Grid.x = (_local5.x / 20);
_local5.y = (_local5.y / 20);
_local5.width = (_local5.width / 20);
_local5.height = (_local5.height / 20);
_local4.scale9Grid = _local5;
};
if (((_arg2) && (_arg1.parent))){
_arg1.parent.addChild(_local4);
};
return (_local4);
}
public static function returnGridPos(_arg1:int, _arg2:int):Point{
var _local3:int;
var _local4:int;
_local3 = (((_arg1 - 1) % _arg2) + 1);
_local4 = (((_arg1 - 1) / _arg2) + 1);
return (new Point(_local3, _local4));
}
public static function shuffleArray(_arg1:Array):Array{
var _local2:Number;
var _local3:Array;
var _local4:Number;
var _local5:Number;
var _local6:Object;
_local2 = _arg1.length;
_local3 = _arg1.slice();
_local5 = 0;
while (_local5 < _local2) {
_local6 = _local3[_local5];
_local4 = skxRandom.getRandomInt(0, (_local2 - 1));
_local3[_local5] = _local3[_local4];
_local3[_local4] = _local6;
_local5++;
};
return (_local3);
}
public static function getRegPoints(_arg1:MovieClip, _arg2:int, _arg3:String="", _arg4:Point=null):Array{
var _local5:int;
var _local6:Array;
var _local7:Point;
var _local8:int;
var _local9:*;
_local5 = _arg2;
_local6 = new Array();
_local7 = new Point();
_local8 = 1;
while (_local8 < _local5) {
_local9 = _arg1.getChildByName(String((_arg3 + _local8)));
if (_local9){
_local7 = new Point();
_local7.x = _local9.x;
_local7.y = _local9.y;
if (_arg4){
_local7.x = (_local7.x + _arg4.x);
_local7.y = (_local7.y + _arg4.y);
};
_local6.push(_local7);
} else {
if (_local7){
_local6.push(_local7);
};
};
_local8++;
};
return (_local6);
}
public static function parseXML(_arg1:XML):Dictionary{
var _local2:Dictionary;
var _local3:XMLList;
var _local4:XML;
_local2 = new Dictionary(true);
_local3 = _arg1.children();
for each (_local4 in _local3) {
_local2[_local4.name()] = _local4;
};
return (_local2);
}
public static function skxLinear(_arg1:Number):Number{
return (_arg1);
}
public static function skxBounceOut(_arg1:Number):Number{
if (_arg1 < (1 / 2.75)){
return (((7.5625 * _arg1) * _arg1));
};
if (_arg1 < (2 / 2.75)){
_arg1 = (_arg1 - (1.5 / 2.75));
return ((((7.5625 * _arg1) * _arg1) + 0.75));
};
if (_arg1 < (2.5 / 2.75)){
_arg1 = (_arg1 - (2.25 / 2.75));
return ((((7.5625 * _arg1) * _arg1) + 0.9375));
};
_arg1 = (_arg1 - (2.625 / 2.75));
return ((((7.5625 * _arg1) * _arg1) + 0.984375));
}
public static function skxCubicOut(_arg1:Number):Number{
var _local2:Number;
_local2 = (1 - _arg1);
return ((1 - ((_local2 * _local2) * _local2)));
}
public static function scaleTo(_arg1, _arg2:int, _arg3:int, _arg4:Number, _arg5:Function=null):void{
var cache:Boolean;
var i:int;
var factor:Number;
var f:Function;
var obj = _arg1;
var ms = _arg2;
var steps = _arg3;
var scale = _arg4;
var cb = _arg5;
if ((((((obj.scaleX == scale)) || ((steps == 0)))) || (!(obj)))){
return;
};
cache = obj.cacheAsBitmap;
obj.cacheAsBitmap = false;
i = 0;
factor = ((scale - obj.scaleX) / steps);
f = function ():void{
if ((((i >= steps)) || ((((obj.scaleX == scale)) && ((obj.scaleY == scale)))))){
obj.scaleX = scale;
obj.scaleY = scale;
obj.cacheAsBitmap = cache;
f = null;
if (cb != null){
skxScheduler.schedule(cb.call, 10);
};
return;
} else {
obj.scaleX = (obj.scaleX + factor);
obj.scaleY = (obj.scaleY + factor);
skxScheduler.schedule(f, (ms / steps));
};
i++;
};
skxScheduler.schedule(f, (ms / steps));
}
public static function scrollNumberBy(_arg1:TextField, _arg2:Number, _arg3:Number, _arg4:int, _arg5:int, _arg6:Boolean=false, _arg7:String=""):void{
var i:int;
var factor:Number;
var value:int;
var f:Function;
var text = _arg1;
var cvalue = _arg2;
var evalue = _arg3;
var inc = _arg4;
var time = _arg5;
var bAsMoney = _arg6;
var prepend = _arg7;
i = 0;
factor = inc;
value = cvalue;
f = function ():void{
if (evalue < (value + factor)){
if (bAsMoney){
text.text = String((prepend + skxUtil.getMoney(evalue)));
} else {
text.text = String(evalue);
};
f = null;
return;
} else {
value = (value + factor);
if (bAsMoney){
text.text = String((prepend + skxUtil.getMoney(value)));
} else {
text.text = String(value);
};
skxScheduler.schedule(f, time);
};
};
skxScheduler.schedule(f, time);
}
public static function goToFrameIn(_arg1, _arg2, _arg3:int, _arg4:String=null):void{
var f:Function;
var ref = _arg1;
var frame = _arg2;
var delay = _arg3;
var scene = _arg4;
f = function ():void{
if (((("gotoAndStop" in ref)) && (ref.gotoAndStop))){
ref.gotoAndStop(frame, scene);
f = null;
};
};
skxScheduler.schedule(f, delay);
}
public static function takeSnapshot(_arg1, _arg2:Number=-1, _arg3:Number=-1, _arg4:int=-1, _arg5:Number=0, _arg6:Number=0, _arg7:Boolean=false):BitmapData{
var _local8:Number;
var _local9:Number;
var _local10:Matrix;
var _local11:BitmapData;
var _local12:MovieClip;
if ((((_arg1.height == 0)) || ((_arg1.width == 0)))){
return (null);
};
if (_arg4 != -1){
_local12 = (_arg1 as MovieClip);
if (_local12){
_local12.gotoAndStop(_arg4);
};
_local8 = _local12.height;
_local9 = _local12.width;
if (((!((_arg2 == -1))) && ((_arg2 >= 1)))){
_local9 = _arg2;
};
if (((!((_arg3 == -1))) && ((_arg3 >= 1)))){
_local8 = _arg3;
};
_local10 = _local12.transform.matrix.clone();
_local10.translate((_arg5 * -1), (_arg6 * -1));
_local11 = new BitmapData(_local9, _local8, true, 0);
_local11.draw(_local12, _local10, _local12.transform.colorTransform, "normal");
return (_local11);
};
_local8 = _arg1.height;
_local9 = _arg1.width;
if (_arg2 != -1){
_local9 = _arg2;
};
if (_arg3 != -1){
_local8 = _arg3;
};
_local10 = _arg1.transform.matrix.clone();
_local10.translate(_arg5, _arg6);
_local11 = new BitmapData(_local9, _local8, true, 0);
_local11.draw(_arg1, _local10, _arg1.transform.colorTransform, "normal");
return (_local11);
}
public static function arcTo(_arg1, _arg2:Point, _arg3:Number, _arg4:int, _arg5:int, _arg6:Function=null, _arg7:Function=null){
var steps:Number;
var spos:Point;
var cpos:Point;
var rise:Number;
var run:Number;
var m2:Number;
var b:Number;
var vec:Point;
var mag:Number;
var tStep:Number;
var t:Number;
var i:int;
var pi:Number;
var f:Function;
var obj = _arg1;
var pos = _arg2;
var height = _arg3;
var step = _arg4;
var time = _arg5;
var endFn = _arg6;
var stepFn = _arg7;
steps = (1 / step);
spos = new Point(obj.x, obj.y);
cpos = new Point(((obj.x + pos.x) / 2), ((obj.y + pos.y) / 2));
rise = (obj.y - pos.y);
run = (obj.x - pos.x);
m2 = ((run / rise) * -1);
b = (cpos.y - (m2 * cpos.x));
vec = new Point();
vec.y = ((m2 * (cpos.x + 1)) + b);
vec.x = (cpos.x + 1);
vec.x = (vec.x - cpos.x);
vec.y = (vec.y - cpos.y);
mag = Math.sqrt(((vec.x * vec.x) + (vec.y * vec.y)));
vec.x = ((vec.x / mag) * height);
vec.y = ((vec.y / mag) * height);
tStep = (time / step);
t = 0;
i = 0;
pi = (Math.PI / 180);
f = function ():void{
var _local1:Number;
var _local2:Number;
var _local3:Number;
var _local4:Number;
if (t < 1){
_local1 = t;
if (stepFn){
_local1 = stepFn.call(null, t);
};
_local2 = (((1 - _local1) * spos.x) + (_local1 * pos.x));
_local3 = (((1 - _local1) * spos.y) + (_local1 * pos.y));
_local4 = Math.sin(((_local1 * 180) * pi));
obj.x = (_local2 + (vec.x * _local4));
obj.y = (_local3 + (vec.y * _local4));
i++;
t = (t + steps);
} else {
obj.x = pos.x;
obj.y = pos.y;
if (endFn != null){
endFn.call(null);
};
f = null;
return;
};
skxScheduler.schedule(f, tStep);
};
skxScheduler.schedule(f, tStep);
}
public static function scrollNumber(_arg1:TextField, _arg2:Number, _arg3:Number, _arg4:int, _arg5:Number, _arg6:Boolean=false, _arg7:String=""):void{
var i:int;
var factor:Number;
var value:int;
var f:Function;
var text = _arg1;
var cvalue = _arg2;
var evalue = _arg3;
var steps = _arg4;
var time = _arg5;
var bAsMoney = _arg6;
var prepend = _arg7;
i = 0;
factor = ((evalue - cvalue) / steps);
value = cvalue;
f = function ():void{
value = (value + factor);
if (bAsMoney){
text.text = String((prepend + skxUtil.getMoney(value)));
} else {
text.text = String(value);
};
if ((((value == evalue)) || ((i >= steps)))){
if (bAsMoney){
text.text = String((prepend + skxUtil.getMoney(evalue)));
} else {
text.text = String(evalue);
};
f = null;
return;
};
skxScheduler.schedule(f, (time / steps));
i++;
};
skxScheduler.schedule(f, (time / steps));
}
public static function loadStringTable(_arg1:String, _arg2:int=1, _arg3:String=","):Dictionary{
var _local4:Dictionary;
var _local5:RegExp;
var _local6:String;
var _local7:Array;
var _local8:Array;
var _local9:*;
_local4 = new Dictionary();
if (_arg1){
_local5 = /\r/g;
_local6 = _arg1.replace(_local5, "");
_local7 = _local6.split("\n");
_local9 = 0;
while (_local9 < _local7.length) {
_local8 = _local7[_local9].split(_arg3);
_local4[_local8[0]] = _local8[_arg2];
_local9++;
};
};
return (_local4);
}
public static function skxElasticOut(_arg1:Number):Number{
return (((Math.pow(2, (-10 * _arg1)) * Math.sin((((_arg1 - 0.075) * (2 * Math.PI)) / 0.3))) + 1));
}
public static function getDistance(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return (Math.sqrt((Math.pow((_arg1 - _arg3), 2) + Math.pow((_arg2 - _arg4), 2))));
}
public static function disableMouseOnChildren(_arg1, _arg2:Boolean, _arg3:Boolean=false):void{
var _local4:int;
if (((_arg3) && ((_arg1 as TextField)))){
} else {
if ((_arg1 as InteractiveObject)){
_arg1.mouseEnabled = _arg2;
};
};
if ((_arg1 as DisplayObjectContainer)){
_local4 = 0;
while (_local4 < _arg1.numChildren) {
disableMouseOnChildren(_arg1.getChildAt(_local4), _arg2, _arg3);
_local4++;
};
};
}
public static function getRounded(_arg1:Number, _arg2:Number):Number{
return ((Math.round((Math.pow(10, _arg2) * _arg1)) / Math.pow(10, _arg2)));
}
}
}//package skxSource
Section 148
//skxWhirled (skxSource.skxWhirled)
package skxSource {
import flash.utils.*;
import com.whirled.game.*;
public class skxWhirled {
private static var m_oCtrl:GameControl;
public static var m_inGame:Boolean = false;
public static function init(_arg1):void{
skxAPI.send = send;
skxAPI.receive = receive;
m_oCtrl = new GameControl(_arg1.stage, false);
skxScene.m_Stage = m_oCtrl;
}
public static function receive(_arg1:Object):void{
}
public static function getControl():GameControl{
return (m_oCtrl);
}
public static function send(_arg1:Object):void{
}
}
}//package skxSource
Section 149
//skxWindow (skxSource.skxWindow)
package skxSource {
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
import flash.geom.*;
import flash.media.*;
public class skxWindow extends MovieClip {
private var m_nYLastMousPos:Number;// = 0
private var m_oFPSTimer:Timer;// = null
private var m_bBreakMouseEvent:Boolean;// = false
private var m_oTimer:Timer;
private var m_pCameraPosition:Point;
private var m_tFPSText:TextField;// = null
private var m_iFPSFrame:int;// = 0
private var m_iFPSTime:int;// = 0
private var m_nUpdateNum:Number;// = 0
private var m_oClasses:Dictionary;
private var m_oBuffers:Bitmap;// = null
private var m_mouseX:Number;// = 0
private var m_mouseY:Number;// = 0
private var m_bFirstUpdate:Boolean;// = false
private var m_bMouseEventsEnabled:Boolean;// = true
private var m_iTime:Number;// = 0
private var m_bUpdating:Boolean;// = false
protected var m_oUpdDispatcher:EventDispatcher;
private var m_oRect:Rectangle;
private var m_nXLastMousPos:Number;// = 0
public var m_iScrHeight:int;// = 0
private var m_bPause:Boolean;// = true
private var m_iUpdateSpd:int;// = 35
private var m_bSingleMouseFocus:Boolean;// = true
private var m_bMouseHasMoved:Boolean;// = false
public var m_iUpdatedObjects:int;// = 0
public var m_aMouseDragArr:Dictionary;
private var m_oHitArea:Sprite;
private var m_oBlack:BitmapData;
private var m_pNextCameraPosition:Point;
public var m_iScrWidth:int;// = 0
protected var m_aObjects:Array;
private var m_oBufferData:BitmapData;// = null
protected var m_oStateDispatcher:EventDispatcher;
private var m_iCurBuffer:int;// = 0
protected var m_oSortDispatcher:EventDispatcher;
private var m_bClearWindow:Boolean;// = true
private var m_sBackgroundImage:skxImage;// = null
private var m_iLastUpdate:int;// = 0
private var m_sBackgroundFrame:int;// = 0
private var m_iGlobalSpd:Number;// = 1
public var m_aMouseArr:Dictionary;
private var m_oSpriteFocus:skxSprite;// = null
private var m_bFPS:Boolean;// = false
private var m_bMouseOver:Boolean;// = false
protected var m_oWindowDispatcher:EventDispatcher;
public function skxWindow(_arg1:int=800, _arg2:int=600):void{
m_oUpdDispatcher = new EventDispatcher();
m_oSortDispatcher = new EventDispatcher();
m_oStateDispatcher = new EventDispatcher();
m_oWindowDispatcher = new EventDispatcher();
m_bMouseEventsEnabled = true;
m_bFirstUpdate = false;
m_iUpdateSpd = 35;
m_oTimer = new skxTimer(m_iUpdateSpd);
m_pCameraPosition = new Point();
m_pNextCameraPosition = new Point();
m_iLastUpdate = 0;
m_iTime = 0;
m_iGlobalSpd = 1;
m_aMouseArr = new Dictionary();
m_aMouseDragArr = new Dictionary();
m_bPause = true;
m_bUpdating = false;
m_bMouseOver = false;
m_oHitArea = new Sprite();
m_oClasses = new Dictionary(true);
m_nUpdateNum = 0;
m_aObjects = new Array(0);
m_iUpdatedObjects = 0;
m_bFPS = false;
m_tFPSText = null;
m_oFPSTimer = null;
m_iFPSTime = 0;
m_iFPSFrame = 0;
m_mouseX = 0;
m_mouseY = 0;
m_oBufferData = null;
m_oBuffers = null;
m_iCurBuffer = 0;
m_sBackgroundImage = null;
m_sBackgroundFrame = 0;
m_iScrWidth = 0;
m_iScrHeight = 0;
m_nXLastMousPos = 0;
m_nYLastMousPos = 0;
m_bMouseHasMoved = false;
m_bClearWindow = true;
m_bSingleMouseFocus = true;
m_oSpriteFocus = null;
m_bBreakMouseEvent = false;
super();
addClass("sprite", skxSprite);
cacheAsBitmap = false;
m_oRect = new Rectangle(0, 0, _arg1, _arg2);
m_oBufferData = new BitmapData(_arg1, _arg2, true, 0x111111);
m_oBuffers = new Bitmap(m_oBufferData);
addChildAt(m_oBuffers, 0);
setAntialiasing(false);
m_iScrWidth = _arg1;
m_iScrHeight = _arg2;
addEventListener(Event.ADDED_TO_STAGE, onAdded);
addEventListener(Event.REMOVED_FROM_STAGE, onRemoved);
}
public function clearObjects():void{
var _local1:int;
_local1 = 0;
while (_local1 < m_aObjects.length) {
m_aObjects[_local1].onDestroy();
m_aObjects[_local1] = null;
_local1++;
};
m_aMouseArr = new Dictionary();
m_aMouseDragArr = new Dictionary();
clearBackground();
setObjFocus(null);
m_aObjects = new Array();
}
public function setSingleMouseFocus(_arg1:Boolean):void{
m_bSingleMouseFocus = _arg1;
}
private function updateCameraPos():void{
m_pCameraPosition.x = m_pNextCameraPosition.x;
m_pCameraPosition.y = m_pNextCameraPosition.y;
}
private function onMouseMovePri(_arg1:MouseEvent):void{
var _local2:Point;
if (!m_bMouseEventsEnabled){
return;
};
if (m_bMouseHasMoved == false){
_local2 = globalToLocal(new Point(_arg1.stageX, _arg1.stageY));
_local2.x = (_local2.x + m_pCameraPosition.x);
_local2.y = (_local2.y + m_pCameraPosition.y);
if (((!((m_mouseX == _local2.x))) || (!((m_mouseY == _local2.y))))){
m_bMouseHasMoved = true;
m_mouseX = _local2.x;
m_mouseY = _local2.y;
};
};
}
public function getObject(_arg1:String):skxSprite{
var _local2:int;
_local2 = 0;
while (_local2 < m_aObjects.length) {
if (((m_aObjects[_local2]) && ((m_aObjects[_local2].name == _arg1)))){
return (m_aObjects[_local2]);
};
_local2++;
};
return (null);
}
public function loadLevel(_arg1, _arg2:String="XML"):void{
clearObjects();
parseLevel(skxLevelLoader.loadLevel(_arg1, _arg2));
renderWindow();
}
private function onMouseDownObjects(_arg1:MouseEvent):void{
var _local2:Point;
var _local3:skxSprite;
if (!m_bMouseEventsEnabled){
return;
};
_local2 = globalToLocal(new Point(_arg1.stageX, _arg1.stageY));
_local2.x = (_local2.x + m_pCameraPosition.x);
_local2.y = (_local2.y + m_pCameraPosition.y);
onMouseDown(_local2.x, _local2.y);
for each (_local3 in m_aMouseArr) {
if (m_bBreakMouseEvent){
break;
};
if (((((_local3.mouseEnabled) && (_local3.visible))) && (!(_local3.m_iMouseAdded)))){
if (_local3.onMouseDown(_local2.x, _local2.y) == true){
breakMouseEvent();
break;
};
};
};
}
public function getCameraPos():Point{
return (m_pCameraPosition);
}
public function hideFPS():void{
m_bFPS = false;
if (m_oFPSTimer){
m_oFPSTimer.removeEventListener(TimerEvent.TIMER, updateFPS);
removeChild(m_tFPSText);
m_oFPSTimer.stop();
m_oFPSTimer = null;
m_tFPSText = null;
};
}
private function onAdded(_arg1:Event):void{
addEventListener(Event.ENTER_FRAME, update, false, int.MAX_VALUE);
addEventListener(MouseEvent.CLICK, onMouseClickObjects, false, int.MAX_VALUE, true);
addEventListener(MouseEvent.MOUSE_DOWN, onMouseDownObjects, false, int.MAX_VALUE, true);
addEventListener(MouseEvent.MOUSE_UP, onMouseUpObjects, false, int.MAX_VALUE, true);
addEventListener(MouseEvent.MOUSE_MOVE, onMouseMovePri, false, int.MAX_VALUE, true);
addEventListener(MouseEvent.MOUSE_OUT, onMouseUpObjects, false, int.MAX_VALUE, true);
addEventListener(MouseEvent.ROLL_OUT, onMouseUpObjects, false, int.MAX_VALUE, true);
addEventListener(Event.MOUSE_LEAVE, onMouseUpObjects, false, int.MAX_VALUE, true);
}
public function onWindowUpdate():void{
}
public function getGlobalSpd():int{
return (m_iGlobalSpd);
}
public function setWindowClear(_arg1:Boolean):void{
m_bClearWindow = _arg1;
}
public function isUpdating():Boolean{
return (m_bUpdating);
}
public function clearWindow():void{
if (!m_sBackgroundImage){
m_oBufferData.fillRect(m_oRect, 0);
} else {
if (m_sBackgroundImage.getData((m_sBackgroundFrame - 1))){
m_oBufferData.copyPixels(m_sBackgroundImage.getData((m_sBackgroundFrame - 1)), m_oRect, new Point(0, 0));
};
};
}
private function onMouseUpObjects(_arg1:MouseEvent):void{
var _local2:Point;
var _local3:skxSprite;
if (!m_bMouseEventsEnabled){
return;
};
_local2 = globalToLocal(new Point(_arg1.stageX, _arg1.stageY));
_local2.x = (_local2.x + m_pCameraPosition.x);
_local2.y = (_local2.y + m_pCameraPosition.y);
onMouseUp(_local2.x, _local2.y);
for each (_local3 in m_aMouseArr) {
if (m_bBreakMouseEvent){
break;
};
if (((((_local3.mouseEnabled) && (_local3.visible))) && (!(_local3.m_iMouseAdded)))){
if (_local3.onMouseUp(_local2.x, _local2.y) == true){
breakMouseEvent();
return;
};
};
};
}
public function setCameraPos(_arg1:Number=0, _arg2:Number=0):void{
m_pNextCameraPosition.x = _arg1;
m_pNextCameraPosition.y = _arg2;
}
public function setAntialiasing(_arg1:Boolean):void{
m_oBuffers.smoothing = _arg1;
}
private function parseLevel(_arg1:Array):void{
var _local2:int;
var _local3:*;
var _local4:skxSprite;
onPreLevel(_arg1);
_local2 = 0;
while (_local2 < _arg1.length) {
if (m_oClasses[_arg1[_local2].CLASS]){
_local3 = new (m_oClasses[_arg1[_local2].CLASS]);
if (_local3.setProp){
_local3.setProp(_arg1[_local2].DATA);
};
_local4 = (_local3 as skxSprite);
if (_local4){
addObject(_local4);
};
};
_local2++;
};
}
public function onMouseRollOut(_arg1:MouseEvent):void{
m_oWindowDispatcher.dispatchEvent(new skxWindowEvent(skxWindowEvent.WINDOW, false));
}
public function setObjFocus(_arg1:skxSprite):void{
m_oSpriteFocus = _arg1;
}
public function setGlobalSpd(_arg1:Number):void{
m_iGlobalSpd = _arg1;
m_nUpdateNum = (m_nUpdateNum * _arg1);
}
public function update(_arg1:Event=null):void{
var _local2:Number;
var _local3:int;
var _local4:int;
if (((!(m_bPause)) && (!(m_bUpdating)))){
m_bUpdating = true;
_local2 = 0;
if (m_bFirstUpdate){
m_bFirstUpdate = false;
m_iLastUpdate = getTimer();
} else {
_local4 = getTimer();
_local2 = ((_local4 - m_iLastUpdate) / 1000);
m_iLastUpdate = _local4;
};
onWindowUpdate();
updateCameraPos();
updateMouseMove();
getCurBuffer().lock();
clearWindow();
m_aObjects.sortOn("m_Depth", Array.NUMERIC);
_local3 = 0;
while (_local3 < m_aObjects.length) {
m_aObjects[_local3].onUpdate(_local2);
_local3++;
};
onPostRender(getCurBuffer());
getCurBuffer().unlock();
if (m_bFPS){
m_iFPSFrame++;
addChild(m_tFPSText);
};
m_bBreakMouseEvent = false;
m_bUpdating = false;
};
}
public function displayFPS():void{
m_bFPS = true;
m_tFPSText = new TextField();
m_tFPSText.autoSize = "left";
m_tFPSText.background = true;
m_tFPSText.backgroundColor = 0xFFFFFF;
m_tFPSText.border = true;
m_tFPSText.borderColor = 0;
m_tFPSText.x = 5;
m_tFPSText.y = 5;
addChild(m_tFPSText);
m_oFPSTimer = new skxTimer(1000);
m_oFPSTimer.addEventListener(TimerEvent.TIMER, updateFPS, false, 0, true);
m_oFPSTimer.start();
m_iFPSFrame = 0;
m_iFPSTime = 0;
}
public function Unpause():void{
m_bPause = false;
m_bFirstUpdate = true;
if (((m_oTimer) && (!((m_oTimer.running == true))))){
m_oTimer.start();
};
}
public function getMousePos():Point{
return (new Point(m_mouseX, m_mouseY));
}
public function removeObject(_arg1:skxSprite, _arg2:Boolean=true):void{
var _local3:int;
_arg1.setStateDispatcher(m_oStateDispatcher, false);
_arg1.setWindowDispatcher(m_oWindowDispatcher, false);
if (_arg1 == getObjFocus()){
setObjFocus(null);
};
_local3 = 0;
while (_local3 < m_aObjects.length) {
if (m_aObjects[_local3] == _arg1){
break;
};
_local3++;
};
skxUtil.popFromArray(_local3, m_aObjects);
}
public function setMouseEvent(_arg1:Boolean):void{
m_bMouseEventsEnabled = _arg1;
mouseEnabled = _arg1;
if (_arg1 == false){
breakMouseEvent();
};
}
public function onMouseMove(_arg1:Number, _arg2:Number):void{
}
public function setSpeed(_arg1:int):void{
m_iUpdateSpd = _arg1;
if (_arg1 == -1){
m_oTimer.stop();
m_oTimer = null;
} else {
m_oTimer.delay = m_iUpdateSpd;
};
}
public function onMouseRollOver(_arg1:MouseEvent):void{
m_oWindowDispatcher.dispatchEvent(new skxWindowEvent(skxWindowEvent.WINDOW, true));
}
public function getSingleMouseFocus():Boolean{
return (m_bSingleMouseFocus);
}
public function onMouseClick(_arg1:Number, _arg2:Number):void{
}
public function renderWindow():void{
var _local1:int;
clearWindow();
if (((((((!((scaleX == 0))) && (!((scaleY == 0))))) && (!((alpha == 0))))) && (visible))){
_local1 = 0;
while (_local1 < m_aObjects.length) {
if (((m_aObjects[_local1].visible) && ((m_aObjects[_local1].alpha > 0)))){
m_aObjects[_local1].onRender(m_oBufferData);
};
_local1++;
};
if (m_bFPS){
m_iFPSFrame++;
addChild(m_tFPSText);
};
};
}
public function setBackground(_arg1, _arg2:int=1):Boolean{
var _local3:String;
var _local4:skxImage;
var _local5:*;
_local3 = (_arg1 as String);
_local4 = (_arg1 as skxImage);
if (((m_sBackgroundImage) && (!(skxResourceMgr.getResource(m_sBackgroundImage.m_sName))))){
m_sBackgroundImage.dispose();
m_sBackgroundImage = null;
};
if (_local3){
_local5 = skxResourceMgr.getResource(_arg1);
if (_local5){
m_sBackgroundImage = _local5.DATA;
m_sBackgroundFrame = _arg2;
return (true);
};
} else {
if (_local4){
m_sBackgroundImage = _local4;
m_sBackgroundFrame = _arg2;
return (true);
};
};
return (false);
}
public function getElapsedTime():Number{
return (m_iTime);
}
public function getUpdateRate():Number{
return (m_nUpdateNum);
}
public function addObject(_arg1:skxSprite):void{
if (m_aObjects.indexOf(_arg1) == -1){
_arg1.setWindow(this);
m_aObjects.push(_arg1);
_arg1.setStateDispatcher(m_oStateDispatcher, true);
_arg1.setWindowDispatcher(m_oWindowDispatcher, true);
_arg1.onStart();
};
}
public function onMouseUp(_arg1:Number, _arg2:Number):void{
}
private function updateMouseMove():void{
var _local1:skxSprite;
if (!m_bMouseEventsEnabled){
return;
};
if (m_bMouseHasMoved == true){
onMouseMove((m_mouseX + m_pCameraPosition.x), (m_mouseY + m_pCameraPosition.y));
for each (_local1 in m_aMouseDragArr) {
if (_local1.isDragging()){
_local1.x = ((_local1.m_oMouseMoveOffset.x + m_mouseX) + m_pCameraPosition.x);
_local1.y = ((_local1.m_oMouseMoveOffset.y + m_mouseY) + m_pCameraPosition.y);
_local1.onMouseDrag((m_mouseX + m_pCameraPosition.x), (m_mouseY + m_pCameraPosition.y));
};
};
m_bMouseHasMoved = false;
};
}
public function breakMouseEvent():void{
m_bBreakMouseEvent = true;
}
public function updateUpdateModel():void{
m_iUpdatedObjects++;
if (m_iUpdatedObjects >= m_aObjects.length){
m_bUpdating = false;
if (m_bFPS){
m_iFPSFrame++;
addChild(m_tFPSText);
};
};
}
public function clearBackground():void{
m_sBackgroundImage = null;
m_sBackgroundFrame = 0;
}
public function addClass(_arg1:String, _arg2:Class):void{
m_oClasses[_arg1] = _arg2;
}
private function updateFPS(_arg1:TimerEvent):void{
var _local2:int;
m_iFPSTime++;
_local2 = (m_iFPSFrame / m_iFPSTime);
m_tFPSText.text = String(_local2);
}
private function onRemoved(_arg1:Event):void{
removeEventListener(Event.ENTER_FRAME, update);
removeEventListener(MouseEvent.CLICK, onMouseClickObjects);
removeEventListener(MouseEvent.MOUSE_DOWN, onMouseDownObjects);
removeEventListener(MouseEvent.MOUSE_UP, onMouseUpObjects);
removeEventListener(MouseEvent.MOUSE_MOVE, onMouseMovePri);
removeEventListener(MouseEvent.MOUSE_OUT, onMouseUpObjects);
removeEventListener(MouseEvent.ROLL_OUT, onMouseUpObjects);
removeEventListener(Event.MOUSE_LEAVE, onMouseUpObjects);
}
private function onMouseClickObjects(_arg1:MouseEvent):void{
var _local2:Point;
var _local3:int;
var _local4:skxSprite;
if (!m_bMouseEventsEnabled){
return;
};
_local2 = globalToLocal(new Point(_arg1.stageX, _arg1.stageY));
_local2.x = (_local2.x + m_pCameraPosition.x);
_local2.y = (_local2.y + m_pCameraPosition.y);
onMouseClick(_local2.x, _local2.y);
_local3 = 0;
for each (_local4 in m_aMouseArr) {
if (m_bBreakMouseEvent){
break;
};
if (((((((((_local4.mouseEnabled) && (_local4.visible))) && (!(_local4.m_iMouseAdded)))) && (_local4.getRectangle()))) && (_local4.pointInSprite(_local2.x, _local2.y)))){
if (_local4.onMouseClick(_local2.x, _local2.y) == true){
breakMouseEvent();
break;
};
if (m_bSingleMouseFocus){
break;
};
};
};
}
public function onPostRender(_arg1:BitmapData):void{
}
public function getObjFocus():skxSprite{
return (m_oSpriteFocus);
}
public function onPreLevel(_arg1:Array):void{
}
public function onMouseDown(_arg1:Number, _arg2:Number):void{
}
public function Pause():Boolean{
m_bPause = true;
if (((m_oTimer) && ((m_oTimer.running == true)))){
m_oTimer.stop();
return (true);
};
return (false);
}
public function sendState(_arg1:String):void{
m_oStateDispatcher.dispatchEvent(new skxStateEvent(skxStateEvent.STATE, _arg1));
}
public function getCurBuffer():BitmapData{
return (m_oBufferData);
}
}
}//package skxSource
Section 150
//skxWindowEvent (skxSource.skxWindowEvent)
package skxSource {
import flash.events.*;
public class skxWindowEvent extends Event {
private var _over:Boolean;// = false
public static const WINDOW:String = "Window";
public function skxWindowEvent(_arg1:String, _arg2:Boolean, _arg3:Boolean=true, _arg4:Boolean=false):void{
_over = false;
super(_arg1, _arg3, _arg4);
_over = _arg2;
}
public function over():Boolean{
return (_over);
}
override public function clone():Event{
return (new skxWindowEvent(type, _over));
}
}
}//package skxSource
Section 151
//AdBlock (AdBlock)
package {
import flash.display.*;
public dynamic class AdBlock extends MovieClip {
public var qbLogo:MovieClip;
}
}//package
Section 152
//Background (Background)
package {
import flash.display.*;
public dynamic class Background extends MovieClip {
}
}//package
Section 153
//Explosion (Explosion)
package {
import flash.display.*;
public dynamic class Explosion extends MovieClip {
}
}//package
Section 154
//internalApplication (internalApplication)
package {
import flash.display.*;
public final class internalApplication {
private var resolver:mdm_Application;// = null
public function internalApplication():void{
resolver = null;
super();
}
public function set onAppExit(_arg1:Function):void{
internal_resolver().onAppExit = _arg1;
}
public function set onFormMinimize(_arg1:Function):void{
internal_resolver().onFormMinimize = _arg1;
}
public function delay(_arg1:Number, _arg2:Boolean=true):void{
internal_resolver().delay(_arg1);
}
public function doEvents(_arg1:Boolean=true):void{
internal_resolver().doEvents();
}
public function get Screensaver():mdm_resolver{
return (internal_resolver().Screensaver);
}
public function set onFormChangeFocus(_arg1:Function):void{
internal_resolver().onFormChangeFocus = _arg1;
}
public function get isMinimized():Boolean{
return (internal_resolver().isMinimized);
}
public function exitWithModalResult(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().exitWithModalResult(_arg1);
}
public function restore(_arg1:Boolean=true):void{
internal_resolver().restore();
}
public function init(_arg1:Sprite, _arg2:Function=null):void{
internal_resolver().init(_arg1, _arg2);
}
public function exitWithCode(_arg1:Number, _arg2:Boolean=true):void{
internal_resolver().exitWithCode(_arg1);
}
public function set onBottomHit(_arg1:Function):void{
internal_resolver().onBottomHit = _arg1;
}
public function set onDragDrop(_arg1:Function):void{
internal_resolver().onDragDrop = _arg1;
}
public function bringToFront(_arg1:Boolean=true):void{
internal_resolver().bringToFront();
}
public function shake(_arg1:Number, _arg2:Boolean=true):void{
internal_resolver().shake(_arg1);
}
public function minimizeToTray(_arg1:Boolean, _arg2:Boolean=true):void{
internal_resolver().minimizeToTray(_arg1);
}
public function set onAppMinimize(_arg1:Function):void{
internal_resolver().onAppMinimize = _arg1;
}
public function get Library():mdm_resolver{
return (internal_resolver().Library);
}
public function set onTopHit(_arg1:Function):void{
internal_resolver().onTopHit = _arg1;
}
public function set onFormRestore(_arg1:Function):void{
internal_resolver().onFormRestore = _arg1;
}
public function minimize(_arg1:Boolean=true):void{
internal_resolver().minimize();
}
public function get filename():String{
return (internal_resolver().filename);
}
public function setProxyUsername(_arg1:String):void{
internal_resolver().setProxyUsername(_arg1);
}
public function exit(_arg1:String, _arg2:String="", _arg3:Boolean=true):void{
internal_resolver().exit(_arg1, _arg2);
}
public function getCMDParams(_arg1:Number):String{
return (internal_resolver().getCMDParams(_arg1));
}
public function get Timer():mdm_resolver{
return (internal_resolver().Timer);
}
public function getFormNames():Array{
return (internal_resolver().getFormNames());
}
public function switchFullScreen(_arg1:Boolean):void{
internal_resolver().switchFullScreen(_arg1);
}
public function set title(_arg1:String):void{
internal_resolver().title = _arg1;
}
public function sendToBack(_arg1:Boolean=true):void{
internal_resolver().sendToBack();
}
public function get path():String{
var _local1:String;
var _local2:RegExp;
var _local3:Boolean;
_local1 = internal_resolver().path;
_local2 = /\\\\/g;
_local3 = (_local1.indexOf("\\\\") == 0);
_local1 = ((_local3) ? "\\" : "" + _local1.replace(_local2, "\\"));
return (_local1);
}
public function set onFormResize(_arg1:Function):void{
internal_resolver().onFormResize = _arg1;
}
public function get filenameUnix():String{
return (internal_resolver().filenameUnix);
}
public function getHttpProxyPort():String{
return (internal_resolver().getHttpProxyPort());
}
public function printVar(_arg1:String, _arg2:Boolean=false, _arg3:Boolean=true):void{
internal_resolver().printVar(_arg1, _arg2);
}
public function set onRightHit(_arg1:Function):void{
internal_resolver().onRightHit = _arg1;
}
private function internal_resolver():mdm_Application{
if (resolver == null){
resolver = new mdm_Application();
};
return (resolver);
}
public function enableExitHandler(_arg1:Boolean=true):void{
internal_resolver().enableExitHandler();
}
public function maximize(_arg1:Boolean=true):void{
internal_resolver().maximize();
}
public function get pathUnix():String{
return (internal_resolver().pathUnix);
}
public function getGlobalVar(_arg1:String):String{
return (internal_resolver().getGlobalVar(_arg1));
}
public function get Kiosk():mdm_resolver{
return (internal_resolver().Kiosk);
}
public function set onAppChangeFocus(_arg1:Function):void{
internal_resolver().onAppChangeFocus = _arg1;
}
public function showTips(_arg1:String):Boolean{
return (internal_resolver().showTips(_arg1));
}
public function get filenameUnicode():String{
return (internal_resolver().filenameUnicode);
}
public function set onAppRestore(_arg1:Function):void{
internal_resolver().onAppRestore = _arg1;
}
public function getHttpsProxyPort():String{
return (internal_resolver().getHttpsProxyPort());
}
public function getHttpsProxyServer():String{
return (internal_resolver().getHttpsProxyServer());
}
public function set onFormMaximize(_arg1:Function):void{
internal_resolver().onFormMaximize = _arg1;
}
public function createForm(_arg1:String, _arg2:String, _arg3:String, _arg4:Number, _arg5:Number, _arg6:Number, _arg7:Number){
return (internal_resolver().createForm(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7));
}
public function set onLeftHit(_arg1:Function):void{
internal_resolver().onLeftHit = _arg1;
}
public function set onArrowKeyPress(_arg1:Function):void{
internal_resolver().onArrowKeyPress = _arg1;
}
public function set onSplashClosed(_arg1:Function):void{
internal_resolver().onSplashClosed = _arg1;
}
public function setProxyPassword(_arg1:String):void{
internal_resolver().setProxyPassword(_arg1);
}
public function set onMDMScriptException(_arg1:Function):void{
internal_resolver().onMDMScriptException = _arg1;
}
public function set onFormClose(_arg1:Function):void{
internal_resolver().onFormClose = _arg1;
}
public function say(_arg1:String, _arg2:Boolean=true):void{
internal_resolver().say(_arg1);
}
public function exitWithDialog(_arg1:String, _arg2:Boolean):void{
internal_resolver().exitWithDialog(_arg1);
}
public function getEnvVar(_arg1:String):String{
return (internal_resolver().getEnvVar(_arg1));
}
public function getHttpProxyServer():String{
return (internal_resolver().getHttpProxyServer());
}
public function textAreaEnhance(_arg1:Boolean, _arg2:Boolean=true):void{
internal_resolver().textAreaEnhance(_arg1);
}
public function get Trial():mdm_resolver{
return (internal_resolver().Trial);
}
public function get pathUnicode():String{
var _local1:String;
var _local2:RegExp;
var _local3:Boolean;
_local1 = internal_resolver().path;
_local2 = /\\\\/g;
_local3 = (_local1.indexOf("\\\\") == 0);
_local1 = ((_local3) ? "\\" : "" + _local1.replace(_local2, "\\"));
return (_local1);
}
public function getSecureVar(_arg1:String):String{
return (internal_resolver().getSecureVar(_arg1));
}
public function setEnvVar(_arg1:String, _arg2:String, _arg3:Boolean=true):void{
internal_resolver().setEnvVar(_arg1, _arg2);
}
public function set onFormReposition(_arg1:Function):void{
internal_resolver().onFormReposition = _arg1;
}
}
}//package
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import mdm.*;
dynamic class mdm_Application extends mdm_resolver {
private var m_onInitCallback:Function;// = null
private var m_bInitDispatched:Boolean;// = false
private function mdm_Application():void{
m_onInitCallback = null;
m_bInitDispatched = false;
super();
SetClassName("mdm.Application");
AddEvents();
AddObject("Library", null);
AddObject("Screensaver", null);
AddObject("Timer", new mdm_Timer());
AddObject("Trial", null);
AddObject("Kiosk", null);
}
public function init(_arg1:Sprite, _arg2:Function=null):void{
var strURL:String;
var dispObj = _arg1;
var onInitCallback = _arg2;
strURL = null;
try {
strURL = dispObj.root.loaderInfo.url;
} catch(e:Error) {
} finally {
if (strURL == null){
try {
!ERROR! strURL = (dispObj as Object).url;
} catch(e:Error) {
};
};
};
AssocURL(strURL);
mdmSetup();
m_spr = dispObj;
Alert2.init(dispObj.stage);
if (onInitCallback != null){
m_onInitCallback = onInitCallback;
dispObj.addEventListener("enterFrame", onInitialise);
};
}
private function onInitialise(_arg1:Event):void{
if (((!(m_bInitDispatched)) && (!((m_onInitCallback == null))))){
m_bInitDispatched = true;
m_onInitCallback();
};
}
private function AddEvents():void{
AddEvent("onAppChangeFocus", true);
AddEvent("onAppExit", false);
AddEvent("onAppMinimize", false);
AddEvent("onAppRestore", false);
AddEvent("onArrowKeyPress", true);
AddEvent("onBottomHit", false);
AddEvent("onDragDrop", true);
AddEvent("onFormChangeFocus", true);
AddEvent("onFormClose", false);
AddEvent("onFormMaximize", true);
AddEvent("onFormMinimize", true);
AddEvent("onFormReposition", true);
AddEvent("onFormResize", true);
AddEvent("onFormRestore", true);
AddEvent("onLeftHit", false);
AddEvent("onMDMScriptException", true);
AddEvent("onRightHit", false);
AddEvent("onSplashClosed", false);
AddEvent("onTopHit", false);
}
}
dynamic class mdm_Timer extends mdm_resolver {
private function mdm_Timer():void{
SetClassName("mdm.Application.Timer");
AddEvents();
}
private function AddEvents():void{
AddEvent("onTimer0", false);
AddEvent("onTimer1", false);
AddEvent("onTimer2", false);
AddEvent("onTimer3", false);
AddEvent("onTimer4", false);
AddEvent("onTimer5", false);
AddEvent("onTimer6", false);
AddEvent("onTimer7", false);
AddEvent("onTimer8", false);
AddEvent("onTimer9", false);
AddEvent("onTimer10", false);
}
}
class Base64 {
private static const BASE64_CHARS:String = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
private function Base64(){
throw (new Error("Base64 class is static container only"));
}
public static function encode(_arg1:String):String{
var _local2:ByteArray;
_local2 = new ByteArray();
_local2.writeUTFBytes(_arg1);
return (encodeByteArray(_local2));
}
public static function decodeToByteArray(_arg1:String):ByteArray{
var _local2:ByteArray;
var _local3:Array;
var _local4:Array;
var _local5:uint;
var _local6:uint;
var _local7:uint;
_local2 = new ByteArray();
_local3 = new Array(4);
_local4 = new Array(3);
_local5 = 0;
while (_local5 < _arg1.length) {
_local6 = 0;
while ((((_local6 < 4)) && (((_local5 + _local6) < _arg1.length)))) {
_local3[_local6] = BASE64_CHARS.indexOf(_arg1.charAt((_local5 + _local6)));
_local6++;
};
_local4[0] = ((_local3[0] << 2) + ((_local3[1] & 48) >> 4));
_local4[1] = (((_local3[1] & 15) << 4) + ((_local3[2] & 60) >> 2));
_local4[2] = (((_local3[2] & 3) << 6) + _local3[3]);
_local7 = 0;
while (_local7 < _local4.length) {
if (_local3[(_local7 + 1)] == 64){
break;
};
_local2.writeByte(_local4[_local7]);
_local7++;
};
_local5 = (_local5 + 4);
};
_local2.position = 0;
return (_local2);
}
public static function encodeByteArray(_arg1:ByteArray):String{
var _local2:String;
var _local3:Array;
var _local4:Array;
var _local5:uint;
var _local6:uint;
var _local7:uint;
_local2 = "";
_local4 = new Array(4);
_arg1.position = 0;
while (_arg1.bytesAvailable > 0) {
_local3 = new Array();
_local5 = 0;
while ((((_local5 < 3)) && ((_arg1.bytesAvailable > 0)))) {
_local3[_local5] = _arg1.readUnsignedByte();
_local5++;
};
_local4[0] = ((_local3[0] & 252) >> 2);
_local4[1] = (((_local3[0] & 3) << 4) | (_local3[1] >> 4));
_local4[2] = (((_local3[1] & 15) << 2) | (_local3[2] >> 6));
_local4[3] = (_local3[2] & 63);
_local6 = _local3.length;
while (_local6 < 3) {
_local4[(_local6 + 1)] = 64;
_local6++;
};
_local7 = 0;
while (_local7 < _local4.length) {
_local2 = (_local2 + BASE64_CHARS.charAt(_local4[_local7]));
_local7++;
};
};
return (_local2);
}
public static function decode(_arg1:String):String{
var _local2:ByteArray;
_local2 = decodeToByteArray(_arg1);
return (_local2.readUTFBytes(_local2.length));
}
}
Section 155
//mdm_resolver (mdm_resolver)
package {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import mdm.*;
import flash.net.*;
import flash.system.*;
import flash.external.*;
public dynamic class mdm_resolver extends Proxy {
private var m_strClassName:String;// = null
private var strPropsMac:String;// = "Application<{!!z!!}>path<{z}>string<{z}>ppsv<{z}>Macintosh HD:<{!z!}>pathUnix<{z}>string<{z}>ppsv<{z}>/<{!z!}>openedFilename<{z}>string<{z}>get<{z}><{!z!}>openedFilenameUnix<{z}>string<{z}>get<{z}><{!z!}>filename<{z}>string<{z}>ppsv<{z}>Macintosh HD:Users:<{!z!}>filenameUnix<{z}>string<{z}>ppsv<{z}>/Users/Contents/MacOS/files<{!z!}><{!z!!}>System<{!!z!!}>screenWidth<{z}>string<{z}>ppsv<{z}>1024<{!z!}>screenHeight<{z}>string<{z}>ppsv<{z}>768<{!z!}>localTime<{z}>string<{z}>get<{z}><{!z!}>macVerString<{z}>string<{z}>ppsv<{z}>Mac OS X 10.4.7<{!z!}><{!z!!}>System.Paths<{!!z!!}>fonts<{z}>string<{z}>ppsv<{z}>Macintosh HD:System:Library:Fonts:<{!z!}>desktop<{z}>string<{z}>ppsv<{z}>Macintosh HD:Users:user:Desktop:<{!z!}>temp<{z}>string<{z}>ppsv<{z}>Macintosh HD:private:var:tmp:folders.501:TemporaryItems:<{!z!}>desktopUnix<{z}>string<{z}>ppsv<{z}>/Users/user/Desktop<{!z!}>tempUnix<{z}>string<{z}>ppsv<{z}>/private/var/tmp/folders.501/TemporaryItems<{!z!}>fontsUnix<{z}>string<{z}>ppsv<{z}>/System/Library/Fonts<{!z!}>preferences<{z}>string<{z}>ppsv<{z}>Macintosh HD:Users:user:Library:Preferences:<{!z!}>preferencesUnix<{z}>string<{z}>ppsv<{z}>/Users/user/Library/Preferences<{!z!}><{!z!!}>MacShell<{!!z!!}>exitCode<{z}>string<{z}>get<{z}> <{!z!}>output<{z}>string<{z}>get<{z}> <{!z!}>isRunning<{z}>boolean<{z}>get<{z}> <{!z!}><{!z!!}>AppleScript<{!!z!!}><{!z!!}>Application.Library<{!!z!!}><{!z!!}>Encryption<{!!z!!}><{!z!!}>Network.Mail<{!!z!!}><{!z!!}>Image<{!!z!!}><{!z!!}>Dialogs<{!!z!!}><{!z!!}>Image.ScreenCapture<{!!z!!}><{!z!!}>Database<{!!z!!}><{!z!!}>Database.MySQL<{!!z!!}><{!z!!}>Exception<{!!z!!}><{!z!!}>Input<{!!z!!}><{!z!!}>Input.Mouse<{!!z!!}><{!z!!}>Dialogs.BrowseFolder<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>Dialogs.BrowseFile<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>filterList<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}>creatorCode<{z}>string<{z}>getset<{z}> <{!z!}>buttonText<{z}>string<{z}>getset<{z}> <{!z!}>dialogText<{z}>string<{z}>getset<{z}> <{!z!}>allowMultiple<{z}>boolean<{z}>getset<{z}> <{!z!}><{!z!!}>Dialogs.BrowseFileToSave<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}>creatorCode<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>Menu.Main<{!!z!!}>menuType<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>Network<{!!z!!}>IPAddress<{z}>string<{z}>getset<{z}> <{!z!}>isPresent<{z}>string<{z}>ppsv<{z}>true<{!z!}><{!z!!}>FileSystem<{!!z!!}><{!z!!}>@Browser<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>url<{z}>string<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>true<{!z!}>source<{z}>string<{z}>getset<{z}>0<{!z!}>title<{z}>string<{z}>get<{z}>0<{!z!}>isBusy<{z}>boolean<{z}>get<{z}>false<{!z!}>favorites<{z}>array<{z}>get<{z}>[]<{!z!}>useragent<{z}>string<{z}>set<{z}>0<{!z!}><{!z!!}>@Forms<{!!z!!}>id<{z}>string<{z}>@set<{z}>0<{!z!}>type<{z}>string<{z}>@set<{z}>standard<{!z!}>isCreated<{z}>string<{z}>getset<{!z!}>x<{z}>string<{z}>getset<{!z!}>y<{z}>string<{z}>getset<{!z!}>width<{z}>string<{z}>getset<{!z!}>height<{z}>string<{z}>getset<{!z!}>title<{z}>string<{z}>getset<{!z!}>visible<{z}>boolean<{z}>getset<{!z!}><{!z!!}>@HTTP<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}><{!z!!}>"
protected var m_dynEvents:Object;
private var strProps:String;// = "Extensions<{!!z!!}><{!z!!}>Extensions.kernel32<{!!z!!}><{!z!!}>GlobalVariables<{!!z!!}><{z}>string<{z}>ppsv<{z}><{!z!}><{!z!!}>@Browser<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>url<{z}>string<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>true<{!z!}>source<{z}>string<{z}>getset<{z}>0<{!z!}>title<{z}>string<{z}>get<{z}>0<{!z!}>isBusy<{z}>boolean<{z}>get<{z}>false<{!z!}>favorites<{z}>array<{z}>get<{z}>[]<{!z!}>useragent<{z}>string<{z}>set<{z}>0<{!z!}><{!z!!}>@ActiveX<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>true<{!z!}><{!z!!}>@MediaPlayer6<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>true<{!z!}>duration<{z}>string<{z}>getset<{z}>0<{!z!}>position<{z}>string<{z}>getset<{z}>0<{!z!}>balance<{z}>string<{z}>getset<{z}>0<{!z!}>volume<{z}>string<{z}>getset<{z}>0<{!z!}>isInstalled<{z}>boolean<{z}>getset<{z}>true<{!z!}>canSeek<{z}>boolean<{z}>getset<{z}>false<{!z!}>canScan<{z}>boolean<{z}>getset<{z}>false<{!z!}><{!z!!}>@MediaPlayer9<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>duration<{z}>string<{z}>getset<{z}>0<{!z!}>position<{z}>string<{z}>getset<{z}>0<{!z!}>currentMarker<{z}>string<{z}>getset<{z}>0<{!z!}>volume<{z}>string<{z}>getset<{z}>0<{!z!}>balance<{z}>string<{z}>getset<{z}>0<{!z!}>markerCount<{z}>string<{z}>getset<{z}>0<{!z!}>source<{z}>string<{z}>getset<{z}>0<{!z!}>mediaName<{z}>string<{z}>getset<{z}>0<{!z!}>mediaWidth<{z}>string<{z}>getset<{z}>0<{!z!}>mediaHeight<{z}>string<{z}>getset<{z}>0<{!z!}>isInstalled<{z}>boolean<{z}>getset<{z}>0<{!z!}>canSeek<{z}>boolean<{z}>getset<{z}>false<{!z!}>canScan<{z}>boolean<{z}>getset<{z}>false<{!z!}><{!z!!}>@QuickTime<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>duration<{z}>string<{z}>getset<{z}>0<{!z!}>position<{z}>string<{z}>getset<{z}>0<{!z!}>isInstalled<{z}>boolean<{z}>getset<{z}>0<{!z!}><{!z!!}>@RealMedia<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>duration<{z}>string<{z}>getset<{z}>0<{!z!}>position<{z}>string<{z}>getset<{z}>0<{!z!}>isInstalled<{z}>boolean<{z}>getset<{z}>0<{!z!}><{!z!!}>@Shockwave<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>bgcolor<{z}>string<{z}>getset<{z}>0<{!z!}>currentFrame<{z}>string<{z}>getset<{z}>0<{!z!}><{!z!!}>@PDF7<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>scrollbars<{z}>string<{z}>getset<{z}>0<{!z!}>toolbar<{z}>string<{z}>getset<{z}>0<{!z!}><{!z!!}>@PDF6<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>scrollbars<{z}>string<{z}>getset<{z}>0<{!z!}>toolbar<{z}>string<{z}>getset<{z}>0<{!z!}><{!z!!}>Application<{!!z!!}>title<{z}>string<{z}>getset<{z}> <{!z!}>isMinimized<{z}>boolean<{z}>get<{z}> <{!z!}>path<{z}>string<{z}>ppsv<{z}>C:\projects\fsp2.0\fsp2.0wrap_newtrans\<{!z!}>pathUnicode<{z}>string<{z}>ppsv<{z}>C:projectssp2.0sp2.0wrap_newtrans<{!z!}>filename<{z}>string<{z}>ppsv<{z}>fwrapper.exe<{!z!}>filenameUnicode<{z}>string<{z}>ppsv<{z}>fwrapper.exe<{!z!}><{!z!!}>Application.Screensaver<{!!z!!}><{!z!!}>System<{!!z!!}>localTime<{z}>string<{z}>getset<{z}> <{!z!}>CPUSpeed<{z}>string<{z}>getset<{z}> <{!z!}>RAMSize<{z}>string<{z}>getset<{z}> <{!z!}>screenWidth<{z}>string<{z}>ppsv<{z}>1280<{!z!}>screenHeight<{z}>string<{z}>ppsv<{z}>1024<{!z!}>computerName<{z}>string<{z}>ppsv<{z}>STAV<{!z!}>computerCompany<{z}>string<{z}>ppsv<{z}><{!z!}>computerOwner<{z}>string<{z}>ppsv<{z}> <{!z!}>winVerString<{z}>string<{z}>ppsv<{z}>Windows XP<{!z!}>language<{z}>string<{z}>ppsv<{z}>English (United Kingdom)<{!z!}>winVerStringDetail<{z}>string<{z}>ppsv<{z}>Microsoft Windows XP Professional<{!z!}>osVersion<{z}>string<{z}>getset<{z}> <{!z!}>CDDrive<{z}>string<{z}>getset<{z}> <{!z!}>servicePack<{z}>string<{z}>ppsv<{z}>Service Pack 2<{!z!}>isAdmin<{z}>boolean<{z}>ppsv<{z}>true<{!z!}><{!z!!}>System.Paths<{!!z!!}>programs<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerStart MenuPrograms<{!z!}>programFiles<{z}>string<{z}>ppsv<{z}>C:Program Files<{!z!}>windows<{z}>string<{z}>ppsv<{z}>C:WINDOWS<{!z!}>system<{z}>string<{z}>ppsv<{z}>C:WINDOWSsystem32<{!z!}>temp<{z}>string<{z}>ppsv<{z}>C:DOCUME~1OwnerLOCALS~1Temp<{!z!}>desktop<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerDesktop<{!z!}>personal<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerMy Documents<{!z!}>favorites<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerFavorites<{!z!}>startup<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerStart MenuProgramsStartup<{!z!}>recent<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerRecent<{!z!}>fonts<{z}>string<{z}>ppsv<{z}>C:WINDOWSFonts<{!z!}>history<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerLocal SettingsHistory<{!z!}>cookies<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerCookies<{!z!}>network<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerNetHood<{!z!}>startMenu<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerStart Menu<{!z!}>appData<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerApplication Data<{!z!}>commonAdminTools<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart MenuProgramsAdministrative Tools<{!z!}>commonAppData<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersApplication Data<{!z!}>commonPrograms<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart MenuPrograms<{!z!}>commonStartMenu<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart Menu<{!z!}>commonStartup<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart MenuProgramsStartup<{!z!}>allUsersAppData<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersApplication Data<{!z!}>allUsersPrograms<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart MenuPrograms<{!z!}>allUsersStartMenu<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart Menu<{!z!}>allUsersStartup<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart MenuProgramsStartup<{!z!}><{!z!!}>Dialogs.BrowseFile<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}>filterList<{z}>string<{z}>getset<{z}> <{!z!}>defaultExtension<{z}>string<{z}>getset<{z}> <{!z!}>buttonText<{z}>string<{z}>getset<{z}> <{!z!}>filterText<{z}>string<{z}>getset<{z}> <{!z!}>defaultFilename<{z}>string<{z}>getset<{z}> <{!z!}>allowMultiple<{z}>boolean<{z}>getset<{z}> <{!z!}><{!z!!}>Dialogs<{!z!!}>Dialogs.BrowseFileUnicode<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}>filterList<{z}>string<{z}>getset<{z}> <{!z!}>defaultExtension<{z}>string<{z}>getset<{z}> <{!z!}>defaultFilename<{z}>string<{z}>getset<{z}> <{!z!}>allowMultiple<{z}>boolean<{z}>getset<{z}> <{!z!}><{!z!!}>Menu<{!!z!!}><{!z!!}>Menu.Tray<{!!z!!}>iconHint<{z}>string<{z}>set<{z}> <{!z!}>menuType<{z}>string<{z}>set<{z}> <{!z!}><{!z!!}>Menu.Main<{!!z!!}>menuType<{z}>string<{z}>set<{z}> <{!z!}><{!z!!}>Menu.Context<{!!z!!}>menuType<{z}>string<{z}>set<{z}> <{!z!}><{!z!!}>Database.MySQL<{!!z!!}><{!z!!}>Database<{!!z!!}><{!z!!}>Database.MSAccess<{!!z!!}><{!z!!}>Database.ADO<{!!z!!}><{!z!!}>FileExplorer<{!!z!!}><{!z!!}>FileExplorer.ComboBox<{!!z!!}><{!z!!}>FileExplorer.ListView<{!!z!!}><{!z!!}>FileExplorer.TreeView<{!!z!!}><{!z!!}>Input.Mouse<{!!z!!}><{!z!!}>Input.Joystick<{!!z!!}><{!z!!}>Input.Tablet<{!!z!!}><{!z!!}>String<{!!z!!}><{!z!!}>@DLL<{!!z!!}><{!z!!}>Network<{!!z!!}>IPAddress<{z}>string<{z}>getset<{z}> <{!z!}>isPresent<{z}>string<{z}>ppsv<{z}>true<{!z!}><{!z!!}>Process<{!!z!!}>lastId<{z}>integer<{z}>get<{z}>-1<{!z!}>isOpen<{z}>boolean<{z}>get<{z}>false<{!z!}><{!z!!}>@FTP<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>initialDir<{z}>string<{z}>getset<{z}> <{!z!}>currentDir<{z}>string<{z}>getset<{z}> <{!z!}>isConnected<{z}>boolean<{z}>getset<{z}> <{!z!}>account<{z}>string<{z}>getset<{z}> <{!z!}>async<{z}>boolean<{z}>getset<{z}> <{!z!}>error<{z}>string<{z}>getset<{z}> <{!z!}>success<{z}>boolean<{z}>getset<{z}> <{!z!}>loggerData<{z}>string<{z}>getset<{z}> <{!z!}>isBusy<{z}>boolean<{z}>getset<{z}> <{!z!}>lastReply<{z}>string<{z}>getset<{z}> <{!z!}>noop<{z}>string<{z}>getset<{z}> <{!z!}>passive<{z}>string<{z}>getset<{z}> <{!z!}>serverType<{z}>string<{z}>getset<{z}> <{!z!}>supportsResume<{z}>boolean<{z}>getset<{z}> <{!z!}>timeout<{z}>string<{z}>getset<{z}> <{!z!}>transferMode<{z}>string<{z}>getset<{z}> <{!z!}>transferTime<{z}>string<{z}>getset<{z}> <{!z!}>bytesTransferred<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>@Forms<{!!z!!}>id<{z}>string<{z}>@set<{z}>0<{!z!}>type<{z}>string<{z}>@set<{z}>standard<{!z!}>title<{z}>string<{z}>@set<{!z!}>titleUnicode<{z}>string<{z}>@set<{!z!}>alpha<{z}>number<{z}>getset<{!z!}>baseURL<{z}>string<{z}>getset<{!z!}>bgColor<{z}>string<{z}>getset<{!z!}>isCreated<{z}>boolean<{z}>get<{!z!}>windowState<{z}>string<{z}>getset<{!z!}>x<{z}>string<{z}>getset<{!z!}>y<{z}>string<{z}>getset<{!z!}>width<{z}>string<{z}>getset<{!z!}>height<{z}>string<{z}>getset<{!z!}>visible<{z}>boolean<{z}>getset<{!z!}><{!z!!}>COMPort<{!!z!!}>initialDTR<{z}>string<{z}>getset<{z}>-1<{!z!}>initialRTS<{z}>string<{z}>getset<{z}> <{!z!}>txBuffer<{z}>integer<{z}>set<{z}> <{!z!}>rxBuffer<{z}>integer<{z}>set<{z}> <{!z!}>ports<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>Flash<{!z!!}>FileSystem<{!z!!}>Network.UDP.Socket<{!z!!}>System.DirectX<{!z!!}>Network.Mail<{!z!!}>Dialogs.BrowseFolder<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>System.JScript<{!z!!}>System.VBScript<{!z!!}>Encryption<{!z!!}>Image<{!z!!}>Image.ScreenCapture<{!z!!}>Exception<{!z!!}>Exception.DebugWindow<{!z!!}>Network.UDP.TFTP<{!z!!}>Network.HTTPD<{!z!!}>System.Registry<{!z!!}>Network.TCP.ProxyHTTP<{!z!!}>Clipboard<{!z!!}>Input.Twain<{!z!!}>Application.Library<{!z!!}>Network.TCP.FileServer<{!z!!}>Application.Timer<{!z!!}>Application.Trial<{!!z!!}>usesLeft<{z}>integer<{z}>ppsv<{z}><{!z!}>daysLeft<{z}>integer<{z}>ppsv<{z}><{!z!}>tampered<{z}>boolean<{z}>get<{z}><{!z!}>expired<{z}>boolean<{z}>get<{z}><{!z!}><{!z!!}>FileSystem.BinaryFile<{!z!!}>@HTTP<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}><{!z!!}>"
protected var m_dynamicID:int;// = -1
private var alert:MovieClip;
private var m_dynamic:Boolean;// = false
protected var m_objs:Object;
private static var m_doneInit:Boolean = false;
private static var m_properties:Object;
protected static var m_dynMP9:Object = new Object();
private static var m_bHaveEI:Boolean = false;
private static var m_cbID:int = 0;
protected static var m_macSocket:XMLSocket;
protected static var m_dynBrowsers:Object = new Object();
protected static var m_bSimulate:Boolean = false;
private static var m_strURL:String = null;
private static var m_bTestedEI:Boolean = false;
protected static var m_strFormID:String = "!}id}!";
public static var m_spr:Sprite;
protected static var m_events:Object = new Object();
protected static var m_dynMP6:Object = new Object();
protected static var m_macPort:int = -1;
protected static var m_dynHTTP:Object = new Object();
private static var m_cmdCounter:int = 0;
public static var ids:int = 0;
protected static var m_dynFTP:Object = new Object();
public function mdm_resolver():void{
m_strClassName = null;
m_dynamic = false;
m_dynamicID = -1;
strProps = "Extensions<{!!z!!}><{!z!!}>Extensions.kernel32<{!!z!!}><{!z!!}>GlobalVariables<{!!z!!}><{z}>string<{z}>ppsv<{z}><{!z!}><{!z!!}>@Browser<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>url<{z}>string<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>true<{!z!}>source<{z}>string<{z}>getset<{z}>0<{!z!}>title<{z}>string<{z}>get<{z}>0<{!z!}>isBusy<{z}>boolean<{z}>get<{z}>false<{!z!}>favorites<{z}>array<{z}>get<{z}>[]<{!z!}>useragent<{z}>string<{z}>set<{z}>0<{!z!}><{!z!!}>@ActiveX<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>true<{!z!}><{!z!!}>@MediaPlayer6<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>true<{!z!}>duration<{z}>string<{z}>getset<{z}>0<{!z!}>position<{z}>string<{z}>getset<{z}>0<{!z!}>balance<{z}>string<{z}>getset<{z}>0<{!z!}>volume<{z}>string<{z}>getset<{z}>0<{!z!}>isInstalled<{z}>boolean<{z}>getset<{z}>true<{!z!}>canSeek<{z}>boolean<{z}>getset<{z}>false<{!z!}>canScan<{z}>boolean<{z}>getset<{z}>false<{!z!}><{!z!!}>@MediaPlayer9<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>duration<{z}>string<{z}>getset<{z}>0<{!z!}>position<{z}>string<{z}>getset<{z}>0<{!z!}>currentMarker<{z}>string<{z}>getset<{z}>0<{!z!}>volume<{z}>string<{z}>getset<{z}>0<{!z!}>balance<{z}>string<{z}>getset<{z}>0<{!z!}>markerCount<{z}>string<{z}>getset<{z}>0<{!z!}>source<{z}>string<{z}>getset<{z}>0<{!z!}>mediaName<{z}>string<{z}>getset<{z}>0<{!z!}>mediaWidth<{z}>string<{z}>getset<{z}>0<{!z!}>mediaHeight<{z}>string<{z}>getset<{z}>0<{!z!}>isInstalled<{z}>boolean<{z}>getset<{z}>0<{!z!}>canSeek<{z}>boolean<{z}>getset<{z}>false<{!z!}>canScan<{z}>boolean<{z}>getset<{z}>false<{!z!}><{!z!!}>@QuickTime<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>duration<{z}>string<{z}>getset<{z}>0<{!z!}>position<{z}>string<{z}>getset<{z}>0<{!z!}>isInstalled<{z}>boolean<{z}>getset<{z}>0<{!z!}><{!z!!}>@RealMedia<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>duration<{z}>string<{z}>getset<{z}>0<{!z!}>position<{z}>string<{z}>getset<{z}>0<{!z!}>isInstalled<{z}>boolean<{z}>getset<{z}>0<{!z!}><{!z!!}>@Shockwave<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>bgcolor<{z}>string<{z}>getset<{z}>0<{!z!}>currentFrame<{z}>string<{z}>getset<{z}>0<{!z!}><{!z!!}>@PDF7<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>scrollbars<{z}>string<{z}>getset<{z}>0<{!z!}>toolbar<{z}>string<{z}>getset<{z}>0<{!z!}><{!z!!}>@PDF6<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>0<{!z!}>scrollbars<{z}>string<{z}>getset<{z}>0<{!z!}>toolbar<{z}>string<{z}>getset<{z}>0<{!z!}><{!z!!}>Application<{!!z!!}>title<{z}>string<{z}>getset<{z}> <{!z!}>isMinimized<{z}>boolean<{z}>get<{z}> <{!z!}>path<{z}>string<{z}>ppsv<{z}>C:\\projects\\fsp2.0\\fsp2.0wrap_newtrans\\<{!z!}>pathUnicode<{z}>string<{z}>ppsv<{z}>C:projects\fsp2.0\fsp2.0wrap_newtrans<{!z!}>filename<{z}>string<{z}>ppsv<{z}>fwrapper.exe<{!z!}>filenameUnicode<{z}>string<{z}>ppsv<{z}>fwrapper.exe<{!z!}><{!z!!}>Application.Screensaver<{!!z!!}><{!z!!}>System<{!!z!!}>localTime<{z}>string<{z}>getset<{z}> <{!z!}>CPUSpeed<{z}>string<{z}>getset<{z}> <{!z!}>RAMSize<{z}>string<{z}>getset<{z}> <{!z!}>screenWidth<{z}>string<{z}>ppsv<{z}>1280<{!z!}>screenHeight<{z}>string<{z}>ppsv<{z}>1024<{!z!}>computerName<{z}>string<{z}>ppsv<{z}>STAV<{!z!}>computerCompany<{z}>string<{z}>ppsv<{z}><{!z!}>computerOwner<{z}>string<{z}>ppsv<{z}> <{!z!}>winVerString<{z}>string<{z}>ppsv<{z}>Windows XP<{!z!}>language<{z}>string<{z}>ppsv<{z}>English (United Kingdom)<{!z!}>winVerStringDetail<{z}>string<{z}>ppsv<{z}>Microsoft Windows XP Professional<{!z!}>osVersion<{z}>string<{z}>getset<{z}> <{!z!}>CDDrive<{z}>string<{z}>getset<{z}> <{!z!}>servicePack<{z}>string<{z}>ppsv<{z}>Service Pack 2<{!z!}>isAdmin<{z}>boolean<{z}>ppsv<{z}>true<{!z!}><{!z!!}>System.Paths<{!!z!!}>programs<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerStart MenuPrograms<{!z!}>programFiles<{z}>string<{z}>ppsv<{z}>C:Program Files<{!z!}>windows<{z}>string<{z}>ppsv<{z}>C:WINDOWS<{!z!}>system<{z}>string<{z}>ppsv<{z}>C:WINDOWSsystem32<{!z!}>temp<{z}>string<{z}>ppsv<{z}>C:DOCUME~1OwnerLOCALS~1Temp<{!z!}>desktop<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerDesktop<{!z!}>personal<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerMy Documents<{!z!}>favorites<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerFavorites<{!z!}>startup<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerStart MenuProgramsStartup<{!z!}>recent<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerRecent<{!z!}>fonts<{z}>string<{z}>ppsv<{z}>C:WINDOWSFonts<{!z!}>history<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerLocal SettingsHistory<{!z!}>cookies<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerCookies<{!z!}>network<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerNetHood<{!z!}>startMenu<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerStart Menu<{!z!}>appData<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsOwnerApplication Data<{!z!}>commonAdminTools<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart MenuProgramsAdministrative Tools<{!z!}>commonAppData<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersApplication Data<{!z!}>commonPrograms<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart MenuPrograms<{!z!}>commonStartMenu<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart Menu<{!z!}>commonStartup<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart MenuProgramsStartup<{!z!}>allUsersAppData<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersApplication Data<{!z!}>allUsersPrograms<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart MenuPrograms<{!z!}>allUsersStartMenu<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart Menu<{!z!}>allUsersStartup<{z}>string<{z}>ppsv<{z}>C:Documents and SettingsAll UsersStart MenuProgramsStartup<{!z!}><{!z!!}>Dialogs.BrowseFile<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}>filterList<{z}>string<{z}>getset<{z}> <{!z!}>defaultExtension<{z}>string<{z}>getset<{z}> <{!z!}>buttonText<{z}>string<{z}>getset<{z}> <{!z!}>filterText<{z}>string<{z}>getset<{z}> <{!z!}>defaultFilename<{z}>string<{z}>getset<{z}> <{!z!}>allowMultiple<{z}>boolean<{z}>getset<{z}> <{!z!}><{!z!!}>Dialogs<{!z!!}>Dialogs.BrowseFileUnicode<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}>filterList<{z}>string<{z}>getset<{z}> <{!z!}>defaultExtension<{z}>string<{z}>getset<{z}> <{!z!}>defaultFilename<{z}>string<{z}>getset<{z}> <{!z!}>allowMultiple<{z}>boolean<{z}>getset<{z}> <{!z!}><{!z!!}>Menu<{!!z!!}><{!z!!}>Menu.Tray<{!!z!!}>iconHint<{z}>string<{z}>set<{z}> <{!z!}>menuType<{z}>string<{z}>set<{z}> <{!z!}><{!z!!}>Menu.Main<{!!z!!}>menuType<{z}>string<{z}>set<{z}> <{!z!}><{!z!!}>Menu.Context<{!!z!!}>menuType<{z}>string<{z}>set<{z}> <{!z!}><{!z!!}>Database.MySQL<{!!z!!}><{!z!!}>Database<{!!z!!}><{!z!!}>Database.MSAccess<{!!z!!}><{!z!!}>Database.ADO<{!!z!!}><{!z!!}>FileExplorer<{!!z!!}><{!z!!}>FileExplorer.ComboBox<{!!z!!}><{!z!!}>FileExplorer.ListView<{!!z!!}><{!z!!}>FileExplorer.TreeView<{!!z!!}><{!z!!}>Input.Mouse<{!!z!!}><{!z!!}>Input.Joystick<{!!z!!}><{!z!!}>Input.Tablet<{!!z!!}><{!z!!}>String<{!!z!!}><{!z!!}>@DLL<{!!z!!}><{!z!!}>Network<{!!z!!}>IPAddress<{z}>string<{z}>getset<{z}> <{!z!}>isPresent<{z}>string<{z}>ppsv<{z}>true<{!z!}><{!z!!}>Process<{!!z!!}>lastId<{z}>integer<{z}>get<{z}>-1<{!z!}>isOpen<{z}>boolean<{z}>get<{z}>false<{!z!}><{!z!!}>@FTP<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>initialDir<{z}>string<{z}>getset<{z}> <{!z!}>currentDir<{z}>string<{z}>getset<{z}> <{!z!}>isConnected<{z}>boolean<{z}>getset<{z}> <{!z!}>account<{z}>string<{z}>getset<{z}> <{!z!}>async<{z}>boolean<{z}>getset<{z}> <{!z!}>error<{z}>string<{z}>getset<{z}> <{!z!}>success<{z}>boolean<{z}>getset<{z}> <{!z!}>loggerData<{z}>string<{z}>getset<{z}> <{!z!}>isBusy<{z}>boolean<{z}>getset<{z}> <{!z!}>lastReply<{z}>string<{z}>getset<{z}> <{!z!}>noop<{z}>string<{z}>getset<{z}> <{!z!}>passive<{z}>string<{z}>getset<{z}> <{!z!}>serverType<{z}>string<{z}>getset<{z}> <{!z!}>supportsResume<{z}>boolean<{z}>getset<{z}> <{!z!}>timeout<{z}>string<{z}>getset<{z}> <{!z!}>transferMode<{z}>string<{z}>getset<{z}> <{!z!}>transferTime<{z}>string<{z}>getset<{z}> <{!z!}>bytesTransferred<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>@Forms<{!!z!!}>id<{z}>string<{z}>@set<{z}>0<{!z!}>type<{z}>string<{z}>@set<{z}>standard<{!z!}>title<{z}>string<{z}>@set<{!z!}>titleUnicode<{z}>string<{z}>@set<{!z!}>alpha<{z}>number<{z}>getset<{!z!}>baseURL<{z}>string<{z}>getset<{!z!}>bgColor<{z}>string<{z}>getset<{!z!}>isCreated<{z}>boolean<{z}>get<{!z!}>windowState<{z}>string<{z}>getset<{!z!}>x<{z}>string<{z}>getset<{!z!}>y<{z}>string<{z}>getset<{!z!}>width<{z}>string<{z}>getset<{!z!}>height<{z}>string<{z}>getset<{!z!}>visible<{z}>boolean<{z}>getset<{!z!}><{!z!!}>COMPort<{!!z!!}>initialDTR<{z}>string<{z}>getset<{z}>-1<{!z!}>initialRTS<{z}>string<{z}>getset<{z}> <{!z!}>txBuffer<{z}>integer<{z}>set<{z}> <{!z!}>rxBuffer<{z}>integer<{z}>set<{z}> <{!z!}>ports<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>Flash<{!z!!}>FileSystem<{!z!!}>Network.UDP.Socket<{!z!!}>System.DirectX<{!z!!}>Network.Mail<{!z!!}>Dialogs.BrowseFolder<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>System.JScript<{!z!!}>System.VBScript<{!z!!}>Encryption<{!z!!}>Image<{!z!!}>Image.ScreenCapture<{!z!!}>Exception<{!z!!}>Exception.DebugWindow<{!z!!}>Network.UDP.TFTP<{!z!!}>Network.HTTPD<{!z!!}>System.Registry<{!z!!}>Network.TCP.ProxyHTTP<{!z!!}>Clipboard<{!z!!}>Input.Twain<{!z!!}>Application.Library<{!z!!}>Network.TCP.FileServer<{!z!!}>Application.Timer<{!z!!}>Application.Trial<{!!z!!}>usesLeft<{z}>integer<{z}>ppsv<{z}><{!z!}>daysLeft<{z}>integer<{z}>ppsv<{z}><{!z!}>tampered<{z}>boolean<{z}>get<{z}><{!z!}>expired<{z}>boolean<{z}>get<{z}><{!z!}><{!z!!}>FileSystem.BinaryFile<{!z!!}>@HTTP<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}><{!z!!}>";
strPropsMac = "Application<{!!z!!}>path<{z}>string<{z}>ppsv<{z}>Macintosh HD:<{!z!}>pathUnix<{z}>string<{z}>ppsv<{z}>/<{!z!}>openedFilename<{z}>string<{z}>get<{z}><{!z!}>openedFilenameUnix<{z}>string<{z}>get<{z}><{!z!}>filename<{z}>string<{z}>ppsv<{z}>Macintosh HD:Users:<{!z!}>filenameUnix<{z}>string<{z}>ppsv<{z}>/Users/Contents/MacOS/files<{!z!}><{!z!!}>System<{!!z!!}>screenWidth<{z}>string<{z}>ppsv<{z}>1024<{!z!}>screenHeight<{z}>string<{z}>ppsv<{z}>768<{!z!}>localTime<{z}>string<{z}>get<{z}><{!z!}>macVerString<{z}>string<{z}>ppsv<{z}>Mac OS X 10.4.7<{!z!}><{!z!!}>System.Paths<{!!z!!}>fonts<{z}>string<{z}>ppsv<{z}>Macintosh HD:System:Library:Fonts:<{!z!}>desktop<{z}>string<{z}>ppsv<{z}>Macintosh HD:Users:user:Desktop:<{!z!}>temp<{z}>string<{z}>ppsv<{z}>Macintosh HD:private:var:tmp:folders.501:TemporaryItems:<{!z!}>desktopUnix<{z}>string<{z}>ppsv<{z}>/Users/user/Desktop<{!z!}>tempUnix<{z}>string<{z}>ppsv<{z}>/private/var/tmp/folders.501/TemporaryItems<{!z!}>fontsUnix<{z}>string<{z}>ppsv<{z}>/System/Library/Fonts<{!z!}>preferences<{z}>string<{z}>ppsv<{z}>Macintosh HD:Users:user:Library:Preferences:<{!z!}>preferencesUnix<{z}>string<{z}>ppsv<{z}>/Users/user/Library/Preferences<{!z!}><{!z!!}>MacShell<{!!z!!}>exitCode<{z}>string<{z}>get<{z}> <{!z!}>output<{z}>string<{z}>get<{z}> <{!z!}>isRunning<{z}>boolean<{z}>get<{z}> <{!z!}><{!z!!}>AppleScript<{!!z!!}><{!z!!}>Application.Library<{!!z!!}><{!z!!}>Encryption<{!!z!!}><{!z!!}>Network.Mail<{!!z!!}><{!z!!}>Image<{!!z!!}><{!z!!}>Dialogs<{!!z!!}><{!z!!}>Image.ScreenCapture<{!!z!!}><{!z!!}>Database<{!!z!!}><{!z!!}>Database.MySQL<{!!z!!}><{!z!!}>Exception<{!!z!!}><{!z!!}>Input<{!!z!!}><{!z!!}>Input.Mouse<{!!z!!}><{!z!!}>Dialogs.BrowseFolder<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>Dialogs.BrowseFile<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>filterList<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}>creatorCode<{z}>string<{z}>getset<{z}> <{!z!}>buttonText<{z}>string<{z}>getset<{z}> <{!z!}>dialogText<{z}>string<{z}>getset<{z}> <{!z!}>allowMultiple<{z}>boolean<{z}>getset<{z}> <{!z!}><{!z!!}>Dialogs.BrowseFileToSave<{!!z!!}>defaultDirectory<{z}>string<{z}>getset<{z}> <{!z!}>title<{z}>string<{z}>getset<{z}> <{!z!}>creatorCode<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>Menu.Main<{!!z!!}>menuType<{z}>string<{z}>getset<{z}> <{!z!}><{!z!!}>Network<{!!z!!}>IPAddress<{z}>string<{z}>getset<{z}> <{!z!}>isPresent<{z}>string<{z}>ppsv<{z}>true<{!z!}><{!z!!}>FileSystem<{!!z!!}><{!z!!}>@Browser<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}>width<{z}>integer<{z}>getset<{z}>300<{!z!}>height<{z}>integer<{z}>getset<{z}>200<{!z!}>x<{z}>integer<{z}>getset<{z}>0<{!z!}>y<{z}>integer<{z}>getset<{z}>0<{!z!}>url<{z}>string<{z}>getset<{z}>0<{!z!}>visible<{z}>boolean<{z}>getset<{z}>true<{!z!}>source<{z}>string<{z}>getset<{z}>0<{!z!}>title<{z}>string<{z}>get<{z}>0<{!z!}>isBusy<{z}>boolean<{z}>get<{z}>false<{!z!}>favorites<{z}>array<{z}>get<{z}>[]<{!z!}>useragent<{z}>string<{z}>set<{z}>0<{!z!}><{!z!!}>@Forms<{!!z!!}>id<{z}>string<{z}>@set<{z}>0<{!z!}>type<{z}>string<{z}>@set<{z}>standard<{!z!}>isCreated<{z}>string<{z}>getset<{!z!}>x<{z}>string<{z}>getset<{!z!}>y<{z}>string<{z}>getset<{!z!}>width<{z}>string<{z}>getset<{!z!}>height<{z}>string<{z}>getset<{!z!}>title<{z}>string<{z}>getset<{!z!}>visible<{z}>boolean<{z}>getset<{!z!}><{!z!!}>@HTTP<{!!z!!}>id<{z}>integer<{z}>set<{z}>-1<{!z!}><{!z!!}>";
super();
m_objs = new Object();
m_dynEvents = new Object();
}
private function InitialiseObject(_arg1:String):void{
var _local2:Array;
var _local3:String;
var _local4:Object;
var _local5:int;
var _local6:String;
var _local7:Array;
var _local8:int;
_local2 = _arg1.split("<{!!z!!}>");
_local3 = _local2[0];
_local4 = m_properties;
_local5 = ((_local3.charAt(0))=="@") ? 1 : 0;
_local6 = String(("mdm." + _local3.substring(_local5)));
if (_local3.substring(0, 11) == "Extensions."){
ExtensionsArray.push(_local3.slice(11));
} else {
m_properties[_local6] = new Array();
if (_local2[1] != null){
_local7 = _local2[1].split("<{!z!}>");
_local8 = 0;
while (_local8 < _local7.length) {
m_properties[_local6][_local8] = _local7[_local8].split("<{z}>");
_local8++;
};
};
};
}
private function Deserialise(_arg1:String){
var index:int;
var ch:String;
var GetNextChar:Function;
var TrimWhiteSpace:Function;
var DeserialiseString:Function;
var DeserialiseArray:Function;
var DeserialiseObject:Function;
var DeserialiseNumber:Function;
var DeserialiseDate:Function;
var DeserialiseXML:Function;
var DeserialiseBoolean:Function;
var DeserialiseValue:Function;
var strInput = _arg1;
GetNextChar = function ():String{
ch = strInput.charAt(index);
index = (index + 1);
return (ch);
};
TrimWhiteSpace = function ():void{
while (ch) {
if (ch <= " "){
GetNextChar();
} else {
if (ch == "/"){
switch (GetNextChar()){
case "/":
do {
} while (((((GetNextChar()) && (!((ch == "\n"))))) && (!((ch == "\r")))));
break;
case "*":
GetNextChar();
while (true) {
if (ch){
if (ch == "*"){
if (GetNextChar() == "/"){
GetNextChar();
break;
};
} else {
GetNextChar();
};
};
};
break;
default:
break;
};
} else {
break;
};
};
};
};
DeserialiseString = function ():String{
var _local1:int;
var _local2:String;
var _local3:int;
var _local4:int;
var _local5:Boolean;
_local2 = "";
_local5 = false;
if (ch == "\""){
while (GetNextChar()) {
if ((((index == strInput.length)) || ((ch == "\"")))){
if (ch == "\""){
GetNextChar();
};
return (_local2.split("@q@").join("\""));
} else {
_local2 = (_local2 + ch);
};
};
};
return (new String());
};
DeserialiseArray = function ():Array{
var _local1:Array;
_local1 = [];
if (ch == "["){
GetNextChar();
TrimWhiteSpace();
if (ch == "]"){
GetNextChar();
return (_local1);
};
while (ch) {
_local1.push(DeserialiseValue());
TrimWhiteSpace();
if (ch == "]"){
GetNextChar();
return (_local1);
};
if (ch != ","){
break;
};
GetNextChar();
TrimWhiteSpace();
};
};
return (new Array());
};
DeserialiseObject = function ():Object{
var _local1:String;
var _local2:Object;
_local2 = {};
if (ch == "{"){
GetNextChar();
TrimWhiteSpace();
if (ch == "}"){
GetNextChar();
return (_local2);
};
while (ch) {
_local1 = DeserialiseString();
TrimWhiteSpace();
if (ch != ":"){
break;
};
GetNextChar();
_local2[_local1] = DeserialiseValue();
TrimWhiteSpace();
if (ch == "}"){
GetNextChar();
return (_local2);
};
if (ch != ","){
break;
};
GetNextChar();
TrimWhiteSpace();
};
};
return (new Object());
};
DeserialiseNumber = function ():Number{
var _local1:String;
var _local2:Number;
_local1 = "";
if (ch == "-"){
_local1 = "-";
GetNextChar();
};
while ((((ch >= "0")) && ((ch <= "9")))) {
_local1 = (_local1 + ch);
GetNextChar();
};
if (ch == "."){
_local1 = (_local1 + ".");
while (((((GetNextChar()) && ((ch >= "0")))) && ((ch <= "9")))) {
_local1 = (_local1 + ch);
};
};
_local2 = Number(_local1);
if (!isFinite(_local2)){
return (Number(0));
};
return (Number(_local2));
};
DeserialiseDate = function ():Date{
var _local1:String;
_local1 = "";
if (ch == "#"){
while (GetNextChar()) {
if (ch == "#"){
GetNextChar();
return (new Date(parseInt(_local1)));
};
_local1 = (_local1 + ch);
};
};
return (new Date());
};
DeserialiseXML = function ():XML{
var _local1:String;
var _local2:int;
_local1 = "";
if (ch == "<"){
GetNextChar();
GetNextChar();
_local2 = strInput.indexOf("</*>");
while (GetNextChar()) {
if (index == (_local2 - 1)){
while (index < (_local2 + 5)) {
GetNextChar();
};
return (new XML(_local1));
} else {
_local1 = (_local1 + ch);
};
};
};
return (new XML());
};
DeserialiseBoolean = function (){
switch (ch){
case "t":
if ((((((GetNextChar() == "r")) && ((GetNextChar() == "u")))) && ((GetNextChar() == "e")))){
GetNextChar();
return (true);
};
break;
case "f":
if ((((((((GetNextChar() == "a")) && ((GetNextChar() == "l")))) && ((GetNextChar() == "s")))) && ((GetNextChar() == "e")))){
GetNextChar();
return (false);
};
break;
case "n":
if ((((((GetNextChar() == "u")) && ((GetNextChar() == "l")))) && ((GetNextChar() == "l")))){
GetNextChar();
return (null);
};
break;
};
return ("");
};
DeserialiseValue = function (){
TrimWhiteSpace();
switch (ch){
case "{":
return (DeserialiseObject());
case "[":
return (DeserialiseArray());
case "\"":
return (DeserialiseString());
case "-":
return (DeserialiseNumber());
case "#":
return (DeserialiseDate());
case "<":
return (DeserialiseXML());
default:
return (((((ch >= "0")) && ((ch <= "9")))) ? DeserialiseNumber() : DeserialiseBoolean());
};
};
index = 0;
ch = " ";
return (DeserialiseValue());
}
protected function SetClassName(_arg1:String):void{
m_strClassName = _arg1;
}
private function SendCmdMac(_arg1:String):void{
var _local2:String;
var _local3:String;
var _local4:int;
var _local5:String;
var _local6:int;
var _local7:int;
var _local8:SharedObject;
var _local9:String;
var _local10:int;
var _local11:String;
var _local12:String;
if (GetHostPlatform() == "Mac"){
_local2 = "xppcmd";
_local3 = "s000000000000";
_local4 = ++m_cmdCounter;
_local5 = (_arg1 + _local4.toString());
_local6 = 0xFA00;
_local7 = (Math.round((_local5.length / _local6)) + 1);
_local8 = SharedObject.getLocal(_local2, "/", false);
_local9 = _local7.toString();
_local8.data.v = "\r";
_local8.data.v = (_local8.data.v + "s000000000000");
_local8.data.v = (_local8.data.v + "\x02");
_local8.data.v = (_local8.data.v + "\x00");
_local8.data.v = (_local8.data.v + "\x01");
_local8.data.v = (_local8.data.v + _local7.toString());
_local8.data.v = (_local8.data.v + "\x00");
_local8.data.v = (_local8.data.v + "\x00");
_local8.data.v = (_local8.data.v + "\r");
_local10 = 1;
while (_local10 <= _local7) {
_local11 = _local10.toString();
while (_local11.length < 3) {
_local11 = ("0" + _local11);
};
_local12 = String(_local5.substr(((_local10 - 1) * _local6), _local6));
_local8.data.v = (_local8.data.v + (("s" + _local11) + "000000000"));
_local8.data.v = (_local8.data.v + "\x02");
_local8.data.v = (_local8.data.v + "ú");
_local8.data.v = (_local8.data.v + "\x00");
_local8.data.v = (_local8.data.v + _local12);
_local10++;
};
_local8.flush();
};
}
protected function GetClassName():String{
return (m_strClassName);
}
protected function GetHostPlatform():String{
return (Capabilities.os.substring(0, 3));
}
protected function IsDynamic():Boolean{
return (m_dynamic);
}
protected function AddEvent(_arg1:String, _arg2:Boolean):void{
m_events[_arg1] = (_arg2) ? dummyCBParams : dummyCB;
}
private function WorkOutFormID():void{
var _local1:String;
var _local2:Array;
var _local3:int;
_local1 = null;
if (m_strURL != null){
_local1 = m_strURL;
};
if (_local1 != null){
if (GetHostPlatform() == "Win"){
_local2 = _local1.split("~swd");
if (_local2.length == 2){
_local1 = _local2[1];
_local2 = _local1.split(".");
if (_local2.length == 2){
_local3 = (_local2[0].valueOf() - 1);
m_strFormID = _local3.toString();
while (m_strFormID.length < 6) {
m_strFormID = ("0" + m_strFormID);
};
};
};
} else {
if (GetHostPlatform() == "Mac"){
_local2 = _local1.split("/");
if (_local2.length){
_local1 = _local2[(_local2.length - 1)];
_local2 = _local1.split(".");
if (_local2.length == 2){
_local3 = (_local2[0].valueOf() - 1);
m_strFormID = _local3.toString();
while (m_strFormID.length < 6) {
m_strFormID = ("0" + m_strFormID);
};
};
};
};
};
};
}
protected function SetDynamic(_arg1:int):void{
m_dynamic = true;
m_dynamicID = _arg1;
}
private function SetupRealBasicSocket():void{
var onConnect:Function;
var onClose:Function;
var onData:Function;
var onSecurityError:Function;
var onIOError:Function;
m_macPort = (50000 + int(m_strFormID));
m_macSocket = new XMLSocket();
onConnect = function (_arg1:Event):void{
};
onClose = function (_arg1:Event):void{
};
onData = function (_arg1:DataEvent):void{
var _local2:Array;
var _local3:Array;
var _local4:String;
_local2 = _arg1.data.split("!}}^{}!");
if (_local2[0] == "mdm.__callFunction"){
_local3 = _local2[1].split("!}}v{}!");
if (_local3[0] != "mdm.__dispatchEvent"){
_local4 = _local3.join("!}}v{}!");
OnEvent(_local4);
};
if (GetHostPlatform() == "Mac"){
if ((((_local3.length > 1)) && ((((_local3[0] == "mdm.__dispatchEvent")) && ((_local3[1] == "AppExit")))))){
_local3.shift();
_local4 = _local3.join("!}}v{}!");
OnEvent(_local4);
};
};
};
};
onSecurityError = function (_arg1:SecurityErrorEvent):void{
};
onIOError = function (_arg1:SecurityErrorEvent):void{
};
m_macSocket.addEventListener(Event.CONNECT, onConnect);
m_macSocket.addEventListener(Event.CLOSE, onClose);
m_macSocket.addEventListener(DataEvent.DATA, onData);
m_macSocket.addEventListener(SecurityErrorEvent.SECURITY_ERROR, onSecurityError);
m_macSocket.addEventListener(IOErrorEvent.IO_ERROR, onIOError);
m_macSocket.connect("127.0.0.1", m_macPort);
}
protected function AddObject(_arg1:String, _arg2:mdm_resolver):void{
if (_arg2 == null){
m_objs[_arg1] = new mdm_resolver();
m_objs[_arg1].m_strClassName = String(((m_strClassName + ".") + _arg1));
} else {
m_objs[_arg1] = _arg2;
};
}
public function ShowMessage(_arg1:String):void{
if (m_spr != null){
alert = new AlertBox(_arg1);
m_spr.addChild(alert);
};
}
private function HaveEI():Boolean{
return (m_bHaveEI);
}
protected function CallAsync(_arg1:String, _arg2:Array):void{
var _local3:Array;
var _local4:String;
var _local5:String;
var _local6:String;
var _local7:Array;
var _local8:String;
_local3 = _arg2;
_local5 = "";
if (_local3[(_local3.length - 1)] === ASYNC){
_local3.pop();
};
_local6 = ((m_strClassName + ".") + _arg1);
if (IsDynamic()){
_local5 = m_dynamicID.toString();
};
_local7 = _local6.split(".");
if ((((_local7[0] == "mdm")) && ((_local7[1] == "Forms")))){
_local6 = ((((_local7[0] + ".") + _local7[1]) + ".") + _local7[3]);
_local5 = _local7[2];
};
if (_local5 != ""){
_local3.unshift(_local5);
};
_local8 = ("mdmCB" + m_cbID.toString());
m_cbID = (m_cbID + 1);
ExternalInterface.addCallback(_local8, _local3[(_local3.length - 1)]);
_local3.pop();
_local3.push(_local8);
_local3 = esc(_local3);
_local4 = (_local3.length) ? (("\"" + _local3.join("\",\"")) + "\"") : "";
if ((((GetHostPlatform() == "Win")) && (HaveEI()))){
fscommand(_local6, _local4);
} else {
if (GetHostPlatform() == "Mac"){
};
};
}
protected function CallSyncNoReturn(_arg1:String, _arg2:Array):void{
var _local3:*;
_local3 = CallSync(_arg1, _arg2);
}
protected function CallSync(_arg1:String, _arg2:Array){
var _local3:Array;
var _local4:String;
var _local5:String;
var _local6:String;
var _local7:String;
var _local8:String;
var _local9:Array;
var _local10:Array;
var _local11:Array;
var _local12:Array;
var _local13:Array;
_local3 = _arg2;
_local5 = "";
if (_local3[(_local3.length - 1)] === SYNC){
_local3.pop();
};
_local8 = ((m_strClassName + ".") + _arg1);
if (IsDynamic()){
_local5 = m_dynamicID.toString();
};
_local9 = _local8.split(".");
if ((((_local9[0] == "mdm")) && ((_local9[1] == "Forms")))){
_local8 = ((((_local9[0] + ".") + _local9[1]) + ".") + _local9[3]);
_local5 = _local9[2];
};
if (_local5 != ""){
_local3.unshift(_local5);
};
if ((((GetHostPlatform() == "Win")) || ((GetHostPlatform() == "Lin")))){
_local3 = esc(_local3);
_local4 = (_local3.length) ? ("<{zinc}>" + (("\"" + _local3.join("\",\"")) + "\"")) : "";
} else {
if (GetHostPlatform() == "Mac"){
if (HaveEI()){
_local3 = esc(_local3);
_local4 = (_local3.length) ? ("<{zinc}>" + (("\"" + _local3.join("\",\"")) + "\"")) : "";
} else {
_local6 = (new Date().getTime() + "<{zinc}>");
_local4 = (_local3.length) ? ("<{zinc}>" + _local3.join("<{zincp}>")) : "";
};
};
};
if ((((((GetHostPlatform() == "Win")) || ((GetHostPlatform() == "Lin")))) && (HaveEI()))){
_local7 = ExternalInterface.call(_local8, m_strFormID, _local4);
if (_local7 != null){
return (Deserialise(_local7));
};
} else {
if (GetHostPlatform() == "Mac"){
if (HaveEI()){
if (_local4.indexOf("\\n") != -1){
_local10 = _local4.split("\\n");
_local4 = _local10.join("@@<{dbsn}>@@");
};
if (_local4.indexOf("\n") != -1){
_local11 = _local4.split("\n");
_local4 = _local11.join("@@<{sbsn}>@@");
};
if (_local4.indexOf("\\r") != -1){
_local12 = _local4.split("\\r");
_local4 = _local12.join("@@<{dbsr}>@@");
};
if (_local4.indexOf("\r") != -1){
_local13 = _local4.split("\r");
_local4 = _local13.join("@@<{sbsr}>@@");
};
_local7 = ExternalInterface.call(_local8, m_strFormID, _local4);
if (_local7 != null){
return (Deserialise(_local7));
};
} else {
SendCmdMac((((((m_strFormID + "<{zinc}>") + _local8) + _local4) + "<{zinc}>") + _local6));
_local7 = WaitReturnMac();
if (_local7 != null){
return (Deserialise(_local7));
};
};
};
};
return ("");
}
protected function AddDynamicEvent(_arg1:String, _arg2:Boolean):void{
m_dynEvents[_arg1] = (_arg2) ? dummyCBParams : dummyCB;
}
private function InitialiseObjects(_arg1:String):void{
var _local2:Array;
var _local3:int;
_local2 = _arg1.split("<{!z!!}>");
_local3 = 0;
while (_local3 < _local2.length) {
InitialiseObject(_local2[_local3]);
_local3++;
};
}
protected function MakeFormProperties(_arg1:String):void{
m_properties[_arg1] = new Array();
m_properties[_arg1] = m_properties["mdm.forms"];
}
override "http://www.adobe.com/2006/actionscript/flash/proxy"?? function getProperty(_arg1){
var _local2:Array;
var _local3:int;
var _local4:String;
var _local5:Array;
if (!m_doneInit){
return ("");
};
if (m_objs[_arg1] != null){
return (m_objs[_arg1]);
};
_local2 = m_properties[m_strClassName];
if (_local2 == null){
return ("");
};
_local3 = 0;
while (_local3 < _local2.length) {
if (_local2[_local3][0] == _arg1){
if ((((_local2[_local3][2] == "get")) || ((_local2[_local3][2] == "getset")))){
_local4 = String(("get" + _arg1));
_local5 = new Array();
return (CallSync(_local4, _local5));
};
if (_local2[_local3][2] == "ppsv"){
if (_local2[_local3][1] == "integer"){
return (new int(_local2[_local3][3]));
};
if (_local2[_local3][1] == "string"){
return (new String(_local2[_local3][3]));
};
if (_local2[_local3][1] == "boolean"){
return (new Boolean(_local2[_local3][3]));
};
} else {
break;
};
};
_local3++;
};
return ("");
}
override "http://www.adobe.com/2006/actionscript/flash/proxy"?? function callProperty(_arg1, ... _args){
var _local3:Array;
if (!m_doneInit){
return ("");
};
_local3 = _args;
if (_local3[(_local3.length - 1)] !== ASYNC){
return (CallSync(_arg1, _local3));
};
return (CallAsync(_arg1, _local3));
}
override "http://www.adobe.com/2006/actionscript/flash/proxy"?? function nextNameIndex(_arg1:int):int{
return (0);
}
override "http://www.adobe.com/2006/actionscript/flash/proxy"?? function setProperty(_arg1, _arg2):void{
var _local3:Array;
var _local4:int;
var _local5:String;
var _local6:Array;
if (!m_doneInit){
return;
};
_local3 = m_properties[m_strClassName];
if (_local3 != null){
_local4 = 0;
while (_local4 < _local3.length) {
if (_local3[_local4][0] == _arg1){
if ((((_local3[_local4][2] == "set")) || ((_local3[_local4][2] == "getset")))){
_local5 = String(("set" + _arg1));
_local6 = new Array();
_local6.push(_arg2);
CallSync(_local5, _local6);
break;
} else {
break;
};
};
_local4++;
};
};
if (m_strClassName == "mdm.Menu.Context"){
if (_arg1 != "menuType"){
Menu.Context.AddEvent(_arg1, false);
Menu.Context.SetEvent(_arg1, _arg2);
};
} else {
if (m_strClassName == "mdm.Menu.Main"){
if (_arg1 != "menuType"){
Menu.Main.AddEvent(_arg1, false);
Menu.Main.SetEvent(_arg1, _arg2);
};
} else {
if (m_strClassName == "mdm.Menu.Tray"){
if (((!((_arg1 == "menuType"))) && (!((_arg1 == "iconHint"))))){
Menu.Tray.AddEvent(_arg1, false);
Menu.Tray.SetEvent(_arg1, _arg2);
};
} else {
if (IsDynamic()){
if (m_dynEvents[_arg1] != null){
SetDynamicEvent(_arg1, _arg2);
};
} else {
if (m_events[_arg1] != null){
SetEvent(_arg1, _arg2);
};
};
};
};
};
}
private function WriteSO(_arg1:String):void{
var _local2:SharedObject;
if (GetHostPlatform() == "Mac"){
_local2 = SharedObject.getLocal(_arg1, "/");
if (_local2.data.v != "<init />"){
_local2.data.v = "<init />";
};
_local2.flush();
};
}
private function dlm(_arg1:String, _arg2:String):String{
return ((((_arg1 + "!}}^") + _arg2) + "^{}!"));
}
protected function mdmSetup():void{
var strDefs:String;
var strEI:String;
var numProps:int;
var arr:Array;
var myPattern:RegExp;
var i:int;
if (!m_doneInit){
if (!m_bSimulate){
WorkOutFormID();
};
try {
strEI = ExternalInterface.call("mdm.hasEI", "");
if (strEI != null){
m_bHaveEI = true;
if (m_strFormID == "!}id}!"){
if ((((GetHostPlatform() == "Win")) || ((GetHostPlatform() == "Lin")))){
m_strFormID = strEI;
};
};
} else {
if (m_strFormID == "!}id}!"){
m_strFormID = "000000";
};
};
} catch(e:Error) {
};
if ((((((GetHostPlatform() == "Win")) || ((GetHostPlatform() == "Lin")))) && (HaveEI()))){
if (!m_bSimulate){
strDefs = ExternalInterface.call("mdm.initialise", m_strFormID, "");
} else {
strDefs = strProps;
};
};
if (GetHostPlatform() == "Mac"){
if (!m_bSimulate){
if (HaveEI()){
strDefs = ExternalInterface.call("mdm.initialise", m_strFormID, "");
};
} else {
strDefs = strPropsMac;
};
};
m_properties = new Object();
if (strDefs != null){
InitialiseObjects(strDefs);
};
if (GetHostPlatform() == "Win"){
if (((!(m_bSimulate)) && (HaveEI()))){
numProps = m_properties["mdm.System.Paths"].length;
arr = m_properties["mdm.System.Paths"];
myPattern = /\\\\/g;
i = 0;
while (i < numProps) {
if ((((arr[i][2] == "ppsv")) && ((arr[i][1] == "string")))){
arr[i][3] = arr[i][3].replace(myPattern, "\\");
};
i = (i + 1);
};
ExternalInterface.addCallback("MDMAS3EVENTCALLBACK", eventCallback);
ExternalInterface.call("mdm.flash9ready", m_strFormID, "");
};
};
if ((((GetHostPlatform() == "Mac")) || ((GetHostPlatform() == "Lin")))){
if (((!(m_bSimulate)) && (HaveEI()))){
ExternalInterface.call("mdm.flash9ready", m_strFormID, "");
};
};
if ((((((GetHostPlatform() == "Mac")) || ((GetHostPlatform() == "Lin")))) && (HaveEI()))){
InitEventsGatherer();
};
m_doneInit = true;
};
}
private function WaitReturnMac():String{
var _local1:String;
var _local2:String;
var _local3:String;
var _local4:SharedObject;
var _local5:Number;
var _local6:int;
var _local7:String;
if (GetHostPlatform() == "Mac"){
_local1 = "xppres";
_local2 = "s000000000000";
_local3 = "";
_local4 = SharedObject.getLocal((_local1 + m_cmdCounter), "/", false);
_local5 = (Number(_local4.data[_local2]) + 1);
_local6 = 1;
while (_local6 < _local5) {
_local7 = _local6.toString();
while (_local7.length < 3) {
_local7 = ("0" + _local7);
};
_local2 = (("s" + _local7) + "000000000");
_local3 = (_local3 + _local4.data[_local2]);
_local6++;
};
return (_local3);
//unresolved jump
};
return ("");
}
private function InitEventsGatherer():void{
var f:Function;
f = function ():void{
var _local1:String;
var _local2:Array;
var _local3:int;
if ((((((GetHostPlatform() == "Mac")) || ((GetHostPlatform() == "Lin")))) && (HaveEI()))){
_local1 = ExternalInterface.call("mdm.Application.collectEvents", m_strFormID, "");
if (_local1 != ""){
_local2 = _local1.split("!!!{}event{{!!!");
if (_local2.length > 0){
_local3 = 0;
while (_local3 < _local2.length) {
OnEvent(_local2[_local3]);
_local3++;
};
};
};
};
};
setInterval(f, (1000 / 20));
}
private function esc(_arg1:Array):Array{
var _local2:int;
_local2 = 0;
while (_local2 < _arg1.length) {
if (typeof(_arg1[_local2]) == "string"){
_arg1[_local2] = _arg1[_local2].split(",").join("@co@").split("\"").join("@dq@").split("&").join("@amp@");
};
_local2++;
};
return (_arg1);
}
private function Serialise():void{
}
protected function SetEvent(_arg1:String, _arg2:Function):void{
m_events[_arg1] = _arg2;
}
protected function SetDynamicEvent(_arg1:String, _arg2:Function):void{
m_dynEvents[_arg1] = _arg2;
}
private static function OnEvent(_arg1:String):void{
var _local2:Boolean;
var _local3:String;
var _local4:String;
var _local5:Array;
var _local6:String;
var _local7:Boolean;
var _local8:String;
var _local9:int;
var _local10:Object;
var _local11:FTP;
var _local12:Browser;
var _local13:HTTP;
var _local14:MediaPlayer6;
var _local15:MediaPlayer;
var _local16:String;
var _local17:String;
var _local18:Array;
var _local19:Array;
_local2 = m_doneInit;
_local4 = _arg1;
_local5 = _local4.split("!}}v{}!");
_local6 = _local5[0];
if (_local5.length){
_local5.shift();
};
_local7 = false;
_local8 = "";
_local9 = 0;
_local10 = new Object();
if (_local6.substr(0, 5) == "onFTP"){
_local7 = true;
if (_local5.length){
_local9 = _local5.shift();
};
if (_local9 >= 0){
_local8 = ("on" + _local6.slice(5));
_local11 = m_dynFTP[_local9];
if (_local11 != null){
if (_local11.internal_resolver().m_dynEvents[_local8] != null){
var _local20 = _local11.internal_resolver().m_dynEvents;
_local20[_local8]();
};
};
};
} else {
if (_local6.substr(0, 9) == "onBrowser"){
_local7 = true;
if (_local5.length){
_local9 = _local5.shift();
};
if (_local9 >= 0){
_local8 = ("on" + _local6.slice(9));
_local12 = m_dynBrowsers[_local9];
if (_local12 != null){
if (_local12.internal_resolver().m_dynEvents[_local8] != null){
if (_local8 == "onDocumentComplete"){
_local10["url"] = _local5[0];
_local20 = _local12.internal_resolver().m_dynEvents;
_local20[_local8](_local10);
};
};
};
};
} else {
if (_local6.substr(0, 6) == "onHTTP"){
_local7 = true;
if (_local5.length){
_local9 = _local5.shift();
};
if (_local9 >= 0){
_local8 = ("on" + _local6.slice(6));
_local13 = m_dynHTTP[_local9];
if (_local13 != null){
if (_local13.internal_resolver().m_dynEvents[_local8] != null){
if (_local8 == "onBinaryTransferComplete"){
_local10["filename"] = _local5[0];
_local20 = _local13.internal_resolver().m_dynEvents;
_local20[_local8](_local10);
} else {
if (_local8 == "onError"){
_local20 = _local13.internal_resolver().m_dynEvents;
_local20[_local8]();
} else {
if (_local8 == "onProgress"){
_local10["bytesTotal"] = _local5[0];
_local10["bytesTransferred"] = _local5[1];
_local20 = _local13.internal_resolver().m_dynEvents;
_local20[_local8](_local10);
} else {
if (_local8 == "onTransferComplete"){
_local10["data"] = _local5[0];
_local20 = _local13.internal_resolver().m_dynEvents;
_local20[_local8](_local10);
};
};
};
};
};
};
};
} else {
if (_local6.substr(0, 6) == "onWMP6"){
_local7 = true;
if (_local5.length){
_local9 = _local5.shift();
};
if (_local9 >= 0){
_local8 = _local6;
_local14 = m_dynMP6[_local9];
if (_local14 != null){
if (_local14.internal_resolver().m_dynEvents[_local8] != null){
if (_local8 == "onMPChangeState"){
_local10["oldState"] = _local5[0];
_local10["newState"] = _local5[1];
_local20 = _local14.internal_resolver().m_dynEvents;
_local20[_local8](_local10);
};
};
};
};
} else {
if (_local6.substr(0, 5) == "onWMP"){
_local7 = true;
if (_local5.length){
_local9 = _local5.shift();
};
if (_local9 >= 0){
_local8 = _local6;
_local15 = m_dynMP9[_local9];
if (_local15 != null){
if (_local15.internal_resolver().m_dynEvents[_local8] != null){
if (_local8 == "onWMPBuffering"){
_local10["status"] = _local5[0];
_local20 = _local15.internal_resolver().m_dynEvents;
_local20[_local8](_local10);
} else {
if (_local8 == "onWMPChangeState"){
_local10["newState"] = _local5[0];
_local20 = _local15.internal_resolver().m_dynEvents;
_local20[_local8](_local10);
} else {
if (_local8 == "onWMPError"){
_local10["error"] = _local5[0];
_local20 = _local15.internal_resolver().m_dynEvents;
_local20[_local8](_local10);
} else {
if (_local8 == "onWMPPositionChanged"){
_local10["newPosition"] = _local5[0];
_local20 = _local15.internal_resolver().m_dynEvents;
_local20[_local8](_local10);
};
};
};
};
};
};
};
};
};
};
};
};
if (!_local7){
_local8 = _local6;
if (_local6.substr(0, 11) == "onMenuClick"){
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8]();
};
} else {
if (_local6.substr(0, 18) == "onContextMenuClick"){
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8]();
};
} else {
if (_local6.substr(0, 15) == "onTrayMenuClick"){
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8]();
};
};
};
};
if (_local6.substr(0, 6) == "onForm"){
if (_local8 == "onFormChangeFocus"){
_local3 = _local5.shift();
_local10["status"] = _local5[0];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onFormClose"){
_local3 = _local5.shift();
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8]();
};
} else {
if (_local8 == "onFormMaximize"){
_local3 = _local5.shift();
_local10["clientWidth"] = _local5[0];
_local10["clientHeight"] = _local5[1];
_local10["width"] = _local5[2];
_local10["height"] = _local5[3];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onFormMinimize"){
_local3 = _local5.shift();
_local10["clientWidth"] = _local5[0];
_local10["clientHeight"] = _local5[1];
_local10["width"] = _local5[2];
_local10["height"] = _local5[3];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onFormReposition"){
_local3 = _local5.shift();
_local10["x"] = _local5[0];
_local10["y"] = _local5[1];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onFormResize"){
_local3 = _local5.shift();
_local10["clientWidth"] = _local5[0];
_local10["clientHeight"] = _local5[1];
_local10["width"] = _local5[2];
_local10["height"] = _local5[3];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onFormRestore"){
_local3 = _local5.shift();
_local10["clientWidth"] = _local5[0];
_local10["clientHeight"] = _local5[1];
_local10["width"] = _local5[2];
_local10["height"] = _local5[3];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
};
};
};
};
};
};
};
} else {
if ((((((((((((((((_local8 == "onAppExit")) || ((_local8 == "onAppMinimize")))) || ((_local8 == "onAppRestore")))) || ((_local8 == "onBottomHit")))) || ((_local8 == "onLeftHit")))) || ((_local8 == "onRightHit")))) || ((_local8 == "onSplashClosed")))) || ((_local8 == "onTopHit")))){
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8]();
};
} else {
if (_local8.substr(0, 10) == "onAppTimer"){
_local16 = ("onTimer" + _local8.substr(10));
if (m_events[_local16] != null){
_local20 = m_events;
_local20[_local16]();
};
} else {
if (_local8 == "AppExit"){
if (m_events["onAppExit"] != null){
_local20 = m_events;
_local20["onAppExit"]();
};
} else {
if (_local8 == "onArrowKeyPress"){
_local10["status"] = _local5[0];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onAppChangeFocus"){
_local10["focus"] = _local5[0];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onDragDrop"){
_local17 = _arg1;
_local18 = _local17.split("!}}v{}!");
_local19 = _local18[1].split("|");
_local10["files"] = _local19;
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
_local10["files"] = null;
} else {
if (_local8 == "onMDMScriptException"){
_local10["formType"] = _local5[0];
_local10["command"] = _local5[1];
_local10["message"] = _local5[2];
_local10["frameNumber"] = _local5[3];
_local10["parameter"] = _local5[4];
_local10["value"] = _local5[5];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local6.substr(0, 5) == "onCOM"){
if (_local8 == "onCOMPortCTSChanged"){
_local10["timeCode"] = _local5[0];
_local10["state"] = _local5[1];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onCOMPortDSRChanged"){
_local10["timeCode"] = _local5[0];
_local10["state"] = _local5[1];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onCOMPortData"){
_local10["timeCode"] = _local5[0];
_local10["data"] = _local5[1];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onCOMPortHEXData"){
_local10["timeCode"] = _local5[0];
_local10["hexData"] = _local5[1];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onCOMPortDataSent"){
_local10["timeCode"] = _local5[0];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onCOMPortError"){
_local10["timeCode"] = _local5[0];
_local10["error"] = _local5[1];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onCOMPortSendProgress"){
_local10["timeCode"] = _local5[0];
_local10["bytes"] = _local5[1];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
};
};
};
};
};
};
};
} else {
if (_local8 == "onFileListViewDblClick"){
_local10["type"] = _local5[0];
_local10["name"] = _local5[1];
_local10["association"] = _local5[2];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if ((((((((_local8 == "onJoystick1ButtonDown")) || ((_local8 == "onJoystick1Move")))) || ((_local8 == "onJoystick2ButtonDown")))) || ((_local8 == "onJoystick2Move")))){
_local10["xlevel"] = _local5[0];
_local10["ylevel"] = _local5[1];
_local10["b1"] = _local5[2];
_local10["b2"] = _local5[3];
_local10["b3"] = _local5[4];
_local10["b4"] = _local5[5];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onTabletEvent"){
_local10["x"] = _local5[0];
_local10["y"] = _local5[1];
_local10["pressure"] = _local5[2];
_local10["buttons"] = _local5[3];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local8 == "onRequest"){
_local10["document"] = _local5[0];
_local10["parameters"] = _local5[1];
_local10["remoteIP"] = _local5[2];
if (m_events[_local8] != null){
_local20 = m_events;
_local20[_local8](_local10);
};
} else {
if (_local6.substr(0, 5) == "onUDP"){
if (_local8 == "onUDPSocketData"){
_local10["data"] = _local5[0];
if (m_events["onData"] != null){
_local20 = m_events;
_local20["onData"](_local10);
};
};
} else {
if (_local6.substr(0, 5) == "onTCP"){
if (_local8 == "onTCPSocketData"){
_local10["data"] = _local5[0];
if (m_events["onSocketData"] != null){
_local20 = m_events;
_local20["onSocketData"](_local10);
};
} else {
if (_local8 == "onTCPSocketConnect"){
if (m_events["onSocketConnect"] != null){
_local20 = m_events;
_local20["onSocketConnect"]();
};
} else {
if (_local8 == "onTCPSocketClose"){
if (m_events["onSocketClose"] != null){
_local20 = m_events;
_local20["onSocketClose"]();
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
};
_local10 = null;
}
public static function AssocURL(_arg1:String):void{
m_strURL = _arg1;
}
public static function InitCallbacks():void{
ExternalInterface.addCallback("MDMAS3EVENTCALLBACK", eventCallback);
}
public static function eventCallback(_arg1:String):void{
OnEvent(_arg1);
}
}
}//package
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.utils.*;
class AlertBox extends MovieClip {
private function AlertBox(_arg1:String){
var _local2:SimpleButton;
var _local3:TextField;
var _local4:Sprite;
var _local5:Sprite;
super();
_local2 = new SimpleButton();
_local4 = new Sprite();
_local4.graphics.lineStyle(2, 0x202020);
_local4.graphics.beginFill(0xFF00FF);
_local4.graphics.drawRect(10, 10, 300, 200);
_local5 = new Sprite();
_local5.graphics.lineStyle(2, 0x202020);
_local5.graphics.beginFill(0xFF0000);
_local5.graphics.drawRect(10, 10, 300, 200);
_local2.upState = _local5;
_local2.overState = _local5;
_local2.downState = _local4;
_local2.useHandCursor = true;
_local2.hitTestState = _local5;
_local2.addEventListener(MouseEvent.CLICK, closeMe);
addChild(_local2);
_local3 = new TextField();
_local3.autoSize = TextFieldAutoSize.LEFT;
_local3.selectable = false;
_local3.textColor = 0xFFFFFF;
_local3.text = _arg1;
_local3.x = ((_local2.width - _local3.width) / 2);
_local3.y = ((_local2.height - _local3.height) / 2);
_local5.addChild(_local3);
}
private function closeMe(_arg1:Event):void{
_arg1.currentTarget.parent.removeChild(_arg1.currentTarget);
}
}
private const dummyCB:Function = function ():void{
};
private const dummyCBParams:Function = function (_arg1:Object):void{
};
class Base64 {
private static const BASE64_CHARS:String = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
private function Base64(){
throw (new Error("Base64 class is static container only"));
}
public static function encode(_arg1:String):String{
var _local2:ByteArray;
_local2 = new ByteArray();
_local2.writeUTFBytes(_arg1);
return (encodeByteArray(_local2));
}
public static function decodeToByteArray(_arg1:String):ByteArray{
var _local2:ByteArray;
var _local3:Array;
var _local4:Array;
var _local5:uint;
var _local6:uint;
var _local7:uint;
_local2 = new ByteArray();
_local3 = new Array(4);
_local4 = new Array(3);
_local5 = 0;
while (_local5 < _arg1.length) {
_local6 = 0;
while ((((_local6 < 4)) && (((_local5 + _local6) < _arg1.length)))) {
_local3[_local6] = BASE64_CHARS.indexOf(_arg1.charAt((_local5 + _local6)));
_local6++;
};
_local4[0] = ((_local3[0] << 2) + ((_local3[1] & 48) >> 4));
_local4[1] = (((_local3[1] & 15) << 4) + ((_local3[2] & 60) >> 2));
_local4[2] = (((_local3[2] & 3) << 6) + _local3[3]);
_local7 = 0;
while (_local7 < _local4.length) {
if (_local3[(_local7 + 1)] == 64){
break;
};
_local2.writeByte(_local4[_local7]);
_local7++;
};
_local5 = (_local5 + 4);
};
_local2.position = 0;
return (_local2);
}
public static function encodeByteArray(_arg1:ByteArray):String{
var _local2:String;
var _local3:Array;
var _local4:Array;
var _local5:uint;
var _local6:uint;
var _local7:uint;
_local2 = "";
_local4 = new Array(4);
_arg1.position = 0;
while (_arg1.bytesAvailable > 0) {
_local3 = new Array();
_local5 = 0;
while ((((_local5 < 3)) && ((_arg1.bytesAvailable > 0)))) {
_local3[_local5] = _arg1.readUnsignedByte();
_local5++;
};
_local4[0] = ((_local3[0] & 252) >> 2);
_local4[1] = (((_local3[0] & 3) << 4) | (_local3[1] >> 4));
_local4[2] = (((_local3[1] & 15) << 2) | (_local3[2] >> 6));
_local4[3] = (_local3[2] & 63);
_local6 = _local3.length;
while (_local6 < 3) {
_local4[(_local6 + 1)] = 64;
_local6++;
};
_local7 = 0;
while (_local7 < _local4.length) {
_local2 = (_local2 + BASE64_CHARS.charAt(_local4[_local7]));
_local7++;
};
};
return (_local2);
}
public static function decode(_arg1:String):String{
var _local2:ByteArray;
_local2 = decodeToByteArray(_arg1);
return (_local2.readUTFBytes(_local2.length));
}
}
Section 156
//MochiAd (MochiAd)
package {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.net.*;
import flash.system.*;
public class MochiAd {
public static function getVersion():String{
return ("2.7");
}
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?cacheBust=") + new Date().getTime()));
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 fn:Function;
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();
fn = function ():void{
options.ad_finished();
};
setTimeout(fn, 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 157
//MUSA1 (MUSA1)
package {
import flash.media.*;
public dynamic class MUSA1 extends Sound {
}
}//package
Section 158
//MUSA2 (MUSA2)
package {
import flash.media.*;
public dynamic class MUSA2 extends Sound {
}
}//package
Section 159
//MUSA3 (MUSA3)
package {
import flash.media.*;
public dynamic class MUSA3 extends Sound {
}
}//package
Section 160
//MUSA4 (MUSA4)
package {
import flash.media.*;
public dynamic class MUSA4 extends Sound {
}
}//package
Section 161
//MUSB1 (MUSB1)
package {
import flash.media.*;
public dynamic class MUSB1 extends Sound {
}
}//package
Section 162
//MUSB2 (MUSB2)
package {
import flash.media.*;
public dynamic class MUSB2 extends Sound {
}
}//package
Section 163
//MUSB3 (MUSB3)
package {
import flash.media.*;
public dynamic class MUSB3 extends Sound {
}
}//package
Section 164
//MUSB4 (MUSB4)
package {
import flash.media.*;
public dynamic class MUSB4 extends Sound {
}
}//package
Section 165
//MUSC1 (MUSC1)
package {
import flash.media.*;
public dynamic class MUSC1 extends Sound {
}
}//package
Section 166
//MUSC2 (MUSC2)
package {
import flash.media.*;
public dynamic class MUSC2 extends Sound {
}
}//package
Section 167
//MUSC3 (MUSC3)
package {
import flash.media.*;
public dynamic class MUSC3 extends Sound {
}
}//package
Section 168
//MUSC4 (MUSC4)
package {
import flash.media.*;
public dynamic class MUSC4 extends Sound {
}
}//package
Section 169
//MUSD1 (MUSD1)
package {
import flash.media.*;
public dynamic class MUSD1 extends Sound {
}
}//package
Section 170
//MUSD2 (MUSD2)
package {
import flash.media.*;
public dynamic class MUSD2 extends Sound {
}
}//package
Section 171
//MUSD3 (MUSD3)
package {
import flash.media.*;
public dynamic class MUSD3 extends Sound {
}
}//package
Section 172
//MUSD4 (MUSD4)
package {
import flash.media.*;
public dynamic class MUSD4 extends Sound {
}
}//package
Section 173
//NEWAIMER (NEWAIMER)
package {
import flash.display.*;
public dynamic class NEWAIMER extends MovieClip {
}
}//package
Section 174
//NEWBOMB (NEWBOMB)
package {
import flash.display.*;
public dynamic class NEWBOMB extends MovieClip {
}
}//package
Section 175
//NEWBOMBglow (NEWBOMBglow)
package {
import flash.display.*;
public dynamic class NEWBOMBglow extends MovieClip {
}
}//package
Section 176
//NEWBRUSH (NEWBRUSH)
package {
import flash.display.*;
public dynamic class NEWBRUSH extends MovieClip {
}
}//package
Section 177
//NEWHATZ (NEWHATZ)
package {
import flash.display.*;
public dynamic class NEWHATZ extends MovieClip {
}
}//package
Section 178
//NEWHATZMAGIC (NEWHATZMAGIC)
package {
import flash.display.*;
public dynamic class NEWHATZMAGIC extends MovieClip {
public function NEWHATZMAGIC(){
addFrameScript(9, frame10);
}
function frame10(){
stop();
}
}
}//package
Section 179
//NEWPOOFMAGIC (NEWPOOFMAGIC)
package {
import flash.display.*;
public dynamic class NEWPOOFMAGIC extends MovieClip {
}
}//package
Section 180
//NEWQB (NEWQB)
package {
import flash.display.*;
public dynamic class NEWQB extends MovieClip {
}
}//package
Section 181
//NEWSTONE (NEWSTONE)
package {
import flash.display.*;
public dynamic class NEWSTONE extends MovieClip {
}
}//package
Section 182
//sndBLINK1 (sndBLINK1)
package {
import flash.media.*;
public dynamic class sndBLINK1 extends Sound {
}
}//package
Section 183
//sndBLINK2 (sndBLINK2)
package {
import flash.media.*;
public dynamic class sndBLINK2 extends Sound {
}
}//package
Section 184
//sndBLUETOG1 (sndBLUETOG1)
package {
import flash.media.*;
public dynamic class sndBLUETOG1 extends Sound {
}
}//package
Section 185
//sndBLUETOG2 (sndBLUETOG2)
package {
import flash.media.*;
public dynamic class sndBLUETOG2 extends Sound {
}
}//package
Section 186
//sndBLUETOG3 (sndBLUETOG3)
package {
import flash.media.*;
public dynamic class sndBLUETOG3 extends Sound {
}
}//package
Section 187
//sndBLUETOG4 (sndBLUETOG4)
package {
import flash.media.*;
public dynamic class sndBLUETOG4 extends Sound {
}
}//package
Section 188
//sndBOILTALLY (sndBOILTALLY)
package {
import flash.media.*;
public dynamic class sndBOILTALLY extends Sound {
}
}//package
Section 189
//sndBOMB (sndBOMB)
package {
import flash.media.*;
public dynamic class sndBOMB extends Sound {
}
}//package
Section 190
//sndBOUNCEBLUE (sndBOUNCEBLUE)
package {
import flash.media.*;
public dynamic class sndBOUNCEBLUE extends Sound {
}
}//package
Section 191
//sndBOUNCEGEN (sndBOUNCEGEN)
package {
import flash.media.*;
public dynamic class sndBOUNCEGEN extends Sound {
}
}//package
Section 192
//sndBOUNCEGREEN (sndBOUNCEGREEN)
package {
import flash.media.*;
public dynamic class sndBOUNCEGREEN extends Sound {
}
}//package
Section 193
//sndBOUNCEORANGE (sndBOUNCEORANGE)
package {
import flash.media.*;
public dynamic class sndBOUNCEORANGE extends Sound {
}
}//package
Section 194
//sndBOUNCEPURPLE (sndBOUNCEPURPLE)
package {
import flash.media.*;
public dynamic class sndBOUNCEPURPLE extends Sound {
}
}//package
Section 195
//sndBOUNCERED (sndBOUNCERED)
package {
import flash.media.*;
public dynamic class sndBOUNCERED extends Sound {
}
}//package
Section 196
//sndBOUNCEYELLOW (sndBOUNCEYELLOW)
package {
import flash.media.*;
public dynamic class sndBOUNCEYELLOW extends Sound {
}
}//package
Section 197
//sndBUTTON (sndBUTTON)
package {
import flash.media.*;
public dynamic class sndBUTTON extends Sound {
}
}//package
Section 198
//sndCHARTOG1 (sndCHARTOG1)
package {
import flash.media.*;
public dynamic class sndCHARTOG1 extends Sound {
}
}//package
Section 199
//sndCHARTOG2 (sndCHARTOG2)
package {
import flash.media.*;
public dynamic class sndCHARTOG2 extends Sound {
}
}//package
Section 200
//sndCHARTOG3 (sndCHARTOG3)
package {
import flash.media.*;
public dynamic class sndCHARTOG3 extends Sound {
}
}//package
Section 201
//sndCHARTOG4 (sndCHARTOG4)
package {
import flash.media.*;
public dynamic class sndCHARTOG4 extends Sound {
}
}//package
Section 202
//sndCHOCTOG1 (sndCHOCTOG1)
package {
import flash.media.*;
public dynamic class sndCHOCTOG1 extends Sound {
}
}//package
Section 203
//sndCHOCTOG2 (sndCHOCTOG2)
package {
import flash.media.*;
public dynamic class sndCHOCTOG2 extends Sound {
}
}//package
Section 204
//sndCHOCTOG3 (sndCHOCTOG3)
package {
import flash.media.*;
public dynamic class sndCHOCTOG3 extends Sound {
}
}//package
Section 205
//sndCHOCTOG4 (sndCHOCTOG4)
package {
import flash.media.*;
public dynamic class sndCHOCTOG4 extends Sound {
}
}//package
Section 206
//sndCLAP1 (sndCLAP1)
package {
import flash.media.*;
public dynamic class sndCLAP1 extends Sound {
}
}//package
Section 207
//sndCLAP2 (sndCLAP2)
package {
import flash.media.*;
public dynamic class sndCLAP2 extends Sound {
}
}//package
Section 208
//sndCRYBLUE (sndCRYBLUE)
package {
import flash.media.*;
public dynamic class sndCRYBLUE extends Sound {
}
}//package
Section 209
//sndCRYCHAR (sndCRYCHAR)
package {
import flash.media.*;
public dynamic class sndCRYCHAR extends Sound {
}
}//package
Section 210
//sndCRYCHOC (sndCRYCHOC)
package {
import flash.media.*;
public dynamic class sndCRYCHOC extends Sound {
}
}//package
Section 211
//sndCRYGEN2 (sndCRYGEN2)
package {
import flash.media.*;
public dynamic class sndCRYGEN2 extends Sound {
}
}//package
Section 212
//sndCRYGREEN (sndCRYGREEN)
package {
import flash.media.*;
public dynamic class sndCRYGREEN extends Sound {
}
}//package
Section 213
//sndCRYGREY (sndCRYGREY)
package {
import flash.media.*;
public dynamic class sndCRYGREY extends Sound {
}
}//package
Section 214
//sndCRYORANGE (sndCRYORANGE)
package {
import flash.media.*;
public dynamic class sndCRYORANGE extends Sound {
}
}//package
Section 215
//sndCRYPINK (sndCRYPINK)
package {
import flash.media.*;
public dynamic class sndCRYPINK extends Sound {
}
}//package
Section 216
//sndCRYPURPLE (sndCRYPURPLE)
package {
import flash.media.*;
public dynamic class sndCRYPURPLE extends Sound {
}
}//package
Section 217
//sndCRYRED (sndCRYRED)
package {
import flash.media.*;
public dynamic class sndCRYRED extends Sound {
}
}//package
Section 218
//sndCRYVAN (sndCRYVAN)
package {
import flash.media.*;
public dynamic class sndCRYVAN extends Sound {
}
}//package
Section 219
//sndCRYYELLOW (sndCRYYELLOW)
package {
import flash.media.*;
public dynamic class sndCRYYELLOW extends Sound {
}
}//package
Section 220
//sndFALLBLUE (sndFALLBLUE)
package {
import flash.media.*;
public dynamic class sndFALLBLUE extends Sound {
}
}//package
Section 221
//sndFALLGEN2 (sndFALLGEN2)
package {
import flash.media.*;
public dynamic class sndFALLGEN2 extends Sound {
}
}//package
Section 222
//sndFALLGREEN (sndFALLGREEN)
package {
import flash.media.*;
public dynamic class sndFALLGREEN extends Sound {
}
}//package
Section 223
//sndFALLORANGE (sndFALLORANGE)
package {
import flash.media.*;
public dynamic class sndFALLORANGE extends Sound {
}
}//package
Section 224
//sndFALLPURPLE (sndFALLPURPLE)
package {
import flash.media.*;
public dynamic class sndFALLPURPLE extends Sound {
}
}//package
Section 225
//sndFALLRED (sndFALLRED)
package {
import flash.media.*;
public dynamic class sndFALLRED extends Sound {
}
}//package
Section 226
//sndFALLYELLOW (sndFALLYELLOW)
package {
import flash.media.*;
public dynamic class sndFALLYELLOW extends Sound {
}
}//package
Section 227
//sndFOOTSTEP (sndFOOTSTEP)
package {
import flash.media.*;
public dynamic class sndFOOTSTEP extends Sound {
}
}//package
Section 228
//sndGAMEOVER (sndGAMEOVER)
package {
import flash.media.*;
public dynamic class sndGAMEOVER extends Sound {
}
}//package
Section 229
//sndGEN2TOG1 (sndGEN2TOG1)
package {
import flash.media.*;
public dynamic class sndGEN2TOG1 extends Sound {
}
}//package
Section 230
//sndGEN2TOG2 (sndGEN2TOG2)
package {
import flash.media.*;
public dynamic class sndGEN2TOG2 extends Sound {
}
}//package
Section 231
//sndGEN2TOG3 (sndGEN2TOG3)
package {
import flash.media.*;
public dynamic class sndGEN2TOG3 extends Sound {
}
}//package
Section 232
//sndGEN2TOG4 (sndGEN2TOG4)
package {
import flash.media.*;
public dynamic class sndGEN2TOG4 extends Sound {
}
}//package
Section 233
//sndGENTOG1 (sndGENTOG1)
package {
import flash.media.*;
public dynamic class sndGENTOG1 extends Sound {
}
}//package
Section 234
//sndGENTOG2 (sndGENTOG2)
package {
import flash.media.*;
public dynamic class sndGENTOG2 extends Sound {
}
}//package
Section 235
//sndGENTOG3 (sndGENTOG3)
package {
import flash.media.*;
public dynamic class sndGENTOG3 extends Sound {
}
}//package
Section 236
//sndGENTOG4 (sndGENTOG4)
package {
import flash.media.*;
public dynamic class sndGENTOG4 extends Sound {
}
}//package
Section 237
//sndGREENTOG1 (sndGREENTOG1)
package {
import flash.media.*;
public dynamic class sndGREENTOG1 extends Sound {
}
}//package
Section 238
//sndGREENTOG2 (sndGREENTOG2)
package {
import flash.media.*;
public dynamic class sndGREENTOG2 extends Sound {
}
}//package
Section 239
//sndGREENTOG3 (sndGREENTOG3)
package {
import flash.media.*;
public dynamic class sndGREENTOG3 extends Sound {
}
}//package
Section 240
//sndGREENTOG4 (sndGREENTOG4)
package {
import flash.media.*;
public dynamic class sndGREENTOG4 extends Sound {
}
}//package
Section 241
//sndGREYTOG1 (sndGREYTOG1)
package {
import flash.media.*;
public dynamic class sndGREYTOG1 extends Sound {
}
}//package
Section 242
//sndGREYTOG2 (sndGREYTOG2)
package {
import flash.media.*;
public dynamic class sndGREYTOG2 extends Sound {
}
}//package
Section 243
//sndGREYTOG3 (sndGREYTOG3)
package {
import flash.media.*;
public dynamic class sndGREYTOG3 extends Sound {
}
}//package
Section 244
//sndGREYTOG4 (sndGREYTOG4)
package {
import flash.media.*;
public dynamic class sndGREYTOG4 extends Sound {
}
}//package
Section 245
//sndHUH (sndHUH)
package {
import flash.media.*;
public dynamic class sndHUH extends Sound {
}
}//package
Section 246
//sndLVLDONE (sndLVLDONE)
package {
import flash.media.*;
public dynamic class sndLVLDONE extends Sound {
}
}//package
Section 247
//sndMAGICAPPEAR (sndMAGICAPPEAR)
package {
import flash.media.*;
public dynamic class sndMAGICAPPEAR extends Sound {
}
}//package
Section 248
//sndMAGICCOLOR (sndMAGICCOLOR)
package {
import flash.media.*;
public dynamic class sndMAGICCOLOR extends Sound {
}
}//package
Section 249
//sndMAGICSHOT (sndMAGICSHOT)
package {
import flash.media.*;
public dynamic class sndMAGICSHOT extends Sound {
}
}//package
Section 250
//sndORANGETOG1 (sndORANGETOG1)
package {
import flash.media.*;
public dynamic class sndORANGETOG1 extends Sound {
}
}//package
Section 251
//sndORANGETOG2 (sndORANGETOG2)
package {
import flash.media.*;
public dynamic class sndORANGETOG2 extends Sound {
}
}//package
Section 252
//sndORANGETOG3 (sndORANGETOG3)
package {
import flash.media.*;
public dynamic class sndORANGETOG3 extends Sound {
}
}//package
Section 253
//sndORANGETOG4 (sndORANGETOG4)
package {
import flash.media.*;
public dynamic class sndORANGETOG4 extends Sound {
}
}//package
Section 254
//sndPAINT (sndPAINT)
package {
import flash.media.*;
public dynamic class sndPAINT extends Sound {
}
}//package
Section 255
//sndPINKTOG1 (sndPINKTOG1)
package {
import flash.media.*;
public dynamic class sndPINKTOG1 extends Sound {
}
}//package
Section 256
//sndPINKTOG2 (sndPINKTOG2)
package {
import flash.media.*;
public dynamic class sndPINKTOG2 extends Sound {
}
}//package
Section 257
//sndPINKTOG3 (sndPINKTOG3)
package {
import flash.media.*;
public dynamic class sndPINKTOG3 extends Sound {
}
}//package
Section 258
//sndPINKTOG4 (sndPINKTOG4)
package {
import flash.media.*;
public dynamic class sndPINKTOG4 extends Sound {
}
}//package
Section 259
//sndPOINTS (sndPOINTS)
package {
import flash.media.*;
public dynamic class sndPOINTS extends Sound {
}
}//package
Section 260
//sndPURPLETOG1 (sndPURPLETOG1)
package {
import flash.media.*;
public dynamic class sndPURPLETOG1 extends Sound {
}
}//package
Section 261
//sndPURPLETOG2 (sndPURPLETOG2)
package {
import flash.media.*;
public dynamic class sndPURPLETOG2 extends Sound {
}
}//package
Section 262
//sndPURPLETOG3 (sndPURPLETOG3)
package {
import flash.media.*;
public dynamic class sndPURPLETOG3 extends Sound {
}
}//package
Section 263
//sndPURPLETOG4 (sndPURPLETOG4)
package {
import flash.media.*;
public dynamic class sndPURPLETOG4 extends Sound {
}
}//package
Section 264
//sndRANDOM1 (sndRANDOM1)
package {
import flash.media.*;
public dynamic class sndRANDOM1 extends Sound {
}
}//package
Section 265
//sndRANDOM2 (sndRANDOM2)
package {
import flash.media.*;
public dynamic class sndRANDOM2 extends Sound {
}
}//package
Section 266
//sndRANDOM3 (sndRANDOM3)
package {
import flash.media.*;
public dynamic class sndRANDOM3 extends Sound {
}
}//package
Section 267
//sndRANDOM4 (sndRANDOM4)
package {
import flash.media.*;
public dynamic class sndRANDOM4 extends Sound {
}
}//package
Section 268
//sndREDTOG1 (sndREDTOG1)
package {
import flash.media.*;
public dynamic class sndREDTOG1 extends Sound {
}
}//package
Section 269
//sndREDTOG2 (sndREDTOG2)
package {
import flash.media.*;
public dynamic class sndREDTOG2 extends Sound {
}
}//package
Section 270
//sndREDTOG3 (sndREDTOG3)
package {
import flash.media.*;
public dynamic class sndREDTOG3 extends Sound {
}
}//package
Section 271
//sndREDTOG4 (sndREDTOG4)
package {
import flash.media.*;
public dynamic class sndREDTOG4 extends Sound {
}
}//package
Section 272
//sndSLIDEBLUE (sndSLIDEBLUE)
package {
import flash.media.*;
public dynamic class sndSLIDEBLUE extends Sound {
}
}//package
Section 273
//sndSLIDEGEN2 (sndSLIDEGEN2)
package {
import flash.media.*;
public dynamic class sndSLIDEGEN2 extends Sound {
}
}//package
Section 274
//sndSLIDEGREEN (sndSLIDEGREEN)
package {
import flash.media.*;
public dynamic class sndSLIDEGREEN extends Sound {
}
}//package
Section 275
//sndSLIDEORANGE (sndSLIDEORANGE)
package {
import flash.media.*;
public dynamic class sndSLIDEORANGE extends Sound {
}
}//package
Section 276
//sndSLIDEPURPLE (sndSLIDEPURPLE)
package {
import flash.media.*;
public dynamic class sndSLIDEPURPLE extends Sound {
}
}//package
Section 277
//sndSLIDERED (sndSLIDERED)
package {
import flash.media.*;
public dynamic class sndSLIDERED extends Sound {
}
}//package
Section 278
//sndSLIDEYELLOW (sndSLIDEYELLOW)
package {
import flash.media.*;
public dynamic class sndSLIDEYELLOW extends Sound {
}
}//package
Section 279
//sndSPIN (sndSPIN)
package {
import flash.media.*;
public dynamic class sndSPIN extends Sound {
}
}//package
Section 280
//sndSPLASH (sndSPLASH)
package {
import flash.media.*;
public dynamic class sndSPLASH extends Sound {
}
}//package
Section 281
//sndSPLAT (sndSPLAT)
package {
import flash.media.*;
public dynamic class sndSPLAT extends Sound {
}
}//package
Section 282
//sndTAHDAH (sndTAHDAH)
package {
import flash.media.*;
public dynamic class sndTAHDAH extends Sound {
}
}//package
Section 283
//sndVANTOG1 (sndVANTOG1)
package {
import flash.media.*;
public dynamic class sndVANTOG1 extends Sound {
}
}//package
Section 284
//sndVANTOG2 (sndVANTOG2)
package {
import flash.media.*;
public dynamic class sndVANTOG2 extends Sound {
}
}//package
Section 285
//sndVANTOG3 (sndVANTOG3)
package {
import flash.media.*;
public dynamic class sndVANTOG3 extends Sound {
}
}//package
Section 286
//sndVANTOG4 (sndVANTOG4)
package {
import flash.media.*;
public dynamic class sndVANTOG4 extends Sound {
}
}//package
Section 287
//sndWAVE (sndWAVE)
package {
import flash.media.*;
public dynamic class sndWAVE extends Sound {
}
}//package
Section 288
//sndYELLOWTOG1 (sndYELLOWTOG1)
package {
import flash.media.*;
public dynamic class sndYELLOWTOG1 extends Sound {
}
}//package
Section 289
//sndYELLOWTOG2 (sndYELLOWTOG2)
package {
import flash.media.*;
public dynamic class sndYELLOWTOG2 extends Sound {
}
}//package
Section 290
//sndYELLOWTOG3 (sndYELLOWTOG3)
package {
import flash.media.*;
public dynamic class sndYELLOWTOG3 extends Sound {
}
}//package
Section 291
//sndYELLOWTOG4 (sndYELLOWTOG4)
package {
import flash.media.*;
public dynamic class sndYELLOWTOG4 extends Sound {
}
}//package
Section 292
//soundClearBlocks (soundClearBlocks)
package {
import flash.media.*;
public dynamic class soundClearBlocks extends Sound {
}
}//package
Section 293
//TextSample (TextSample)
package {
import flash.display.*;
import flash.text.*;
public dynamic class TextSample extends MovieClip {
public var blah:TextField;
}
}//package