Section 1
//AllSymbols_3 (AncientJewels_fla.AllSymbols_3)
package AncientJewels_fla {
import flash.display.*;
public dynamic class AllSymbols_3 extends MovieClip {
public function AllSymbols_3(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package AncientJewels_fla
Section 2
//Combo_172 (AncientJewels_fla.Combo_172)
package AncientJewels_fla {
import flash.display.*;
import flash.text.*;
public dynamic class Combo_172 extends MovieClip {
public var combo:TextField;
}
}//package AncientJewels_fla
Section 3
//preloader_screen_1 (AncientJewels_fla.preloader_screen_1)
package AncientJewels_fla {
import flash.display.*;
public dynamic class preloader_screen_1 extends MovieClip {
public var gg_button:SimpleButton;
}
}//package AncientJewels_fla
Section 4
//LevelInfo (Common.LevelInfo)
package Common {
import flash.events.*;
import flash.display.*;
import flash.net.*;
import Utillity.*;
public class LevelInfo {
public var available_bonus:Array;
public var row_count:int;
public var time:int;
public var back:DisplayObject;
public var col_count:int;
public var black_part:Number;
public var num_figures:int;
public var map:Array;
private static var pure_level:LevelInfo;
private function loadTextMapData(_arg1:String):Array{
var _local2:Array;
var _local3:Array;
var _local4:int;
_local2 = _arg1.split(/[ ,\t\r\n]+/, (row_count * col_count));
_local3 = new Array();
_local4 = 0;
while (_local4 < _local2.length) {
_local3.push(parseInt(_local2[_local4]));
_local4++;
};
return (_local3);
}
public function load(_arg1:XML, _arg2:LevelInfo):void{
var mapData_type:String;
var loader:URLLoader;
var back_loader:Loader;
var xml = _arg1;
var default_level = _arg2;
try {
if (xml.@["row_count"].toString().length > 0){
row_count = parseInt(xml.@["row_count"].toString());
if (isNaN(row_count)){
row_count = default_level.row_count;
};
} else {
row_count = default_level.row_count;
};
if (xml.@["col_count"].toString().length > 0){
col_count = parseInt(xml.@["col_count"].toString());
if (isNaN(col_count)){
col_count = default_level.col_count;
};
} else {
col_count = default_level.col_count;
};
if (xml.@["num_figures"].toString().length > 0){
num_figures = parseInt(xml.@["num_figures"].toString());
if (isNaN(num_figures)){
num_figures = default_level.num_figures;
};
} else {
num_figures = default_level.num_figures;
};
if (xml.@["black_part"].toString().length > 0){
black_part = (parseFloat(xml.@["black_part"].toString()) / 100);
if (isNaN(black_part)){
black_part = new Number(default_level.black_part);
};
} else {
black_part = new Number(default_level.black_part);
};
if (xml.@["time"].toString().length > 0){
time = parseInt(xml.@["time"].toString());
if (isNaN(time)){
time = default_level.time;
};
} else {
time = default_level.time;
};
if (xml.child("map").length() > 0){
if (xml["map"].@["type"].toString().length > 0){
mapData_type = xml["map"].@["type"];
if (xml["map"].text().toString().length > 0){
if (mapData_type == "file"){
loader = new URLLoader();
loader.dataFormat = "text";
loader.addEventListener(Event.COMPLETE, function (_arg1:Event):void{
map = loadTextMapData(String(_arg1.target.data));
});
loader.addEventListener(IOErrorEvent.IO_ERROR, function (_arg1:IOErrorEvent):void{
map = default_level.map.slice();
trace(("Error->load map: " + _arg1.toString()));
});
loader.load(new URLRequest(xml["map"].text()));
} else {
if (mapData_type == "text"){
map = loadTextMapData(xml["map"].text());
} else {
map = default_level.map.slice();
};
};
} else {
map = default_level.map.slice();
};
} else {
map = default_level.map.slice();
};
} else {
map = default_level.map.slice();
};
if ((((xml.child("bonus").length() > 0)) && ((xml["bonus"].text().toString().length > 0)))){
available_bonus = xml["bonus"].text().toString().split(/[ ,\t\r\n]+/);
} else {
available_bonus = default_level.available_bonus.slice();
};
if ((((xml.child("back").length() > 0)) && ((xml["back"].text().toString().length > 0)))){
if (xml["back"].@["location"].toString().length > 0){
if (xml["back"].@["location"] == "file"){
back_loader = new Loader();
back_loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, function (_arg1:IOErrorEvent):void{
back = default_level.back;
trace(("Error->load back: " + _arg1.toString()));
});
back_loader.load(new URLRequest(xml["back"].text()));
back = back_loader;
} else {
if (xml["back"].@["location"] == "library"){
back = LibraryMovies.getMovieFromLibrary(xml["back"].text());
trace(("back = " + back));
trace(("w = " + back.width));
trace(("h = " + back.height));
} else {
back = default_level.back;
};
};
} else {
back = default_level.back;
};
} else {
back = default_level.back;
};
} catch(e:Error) {
trace(("Error load LevelInfo." + e.getStackTrace()));
};
}
public static function getPureLevel():LevelInfo{
var _local1:int;
if (pure_level == null){
pure_level = new (LevelInfo);
pure_level.time = 200;
pure_level.row_count = 11;
pure_level.col_count = 13;
pure_level.num_figures = 5;
pure_level.black_part = 0;
pure_level.available_bonus = new Array();
pure_level.map = new Array((pure_level.row_count * pure_level.col_count));
_local1 = 0;
while (_local1 < pure_level.map.length) {
pure_level.map[_local1] = 1;
_local1++;
};
pure_level.map[0] = 2;
};
return (pure_level);
}
}
}//package Common
Section 5
//Preloader (Common.Preloader)
package Common {
import flash.events.*;
import flash.display.*;
import States.*;
import flash.net.*;
import flash.ui.*;
public class Preloader extends MovieClip {
var progress_bar:MovieClip;
private var load_items:Array;
var percent:Number;// = 0
var bytesLoaded:Number;// = 0
var percents_field:MovieClip;
public var preloader_clip:MovieClip;
var bytesTotal:Number;// = 0
public function Preloader(){
bytesLoaded = 0;
bytesTotal = 0;
percent = 0;
load_items = [function (_arg1:Function){
StringTable.getInstance().loadFromFile("string_table.xml", _arg1);
trace("\nstart load 'string_table.xml'");
}, function (_arg1:Function){
Settings.getInstance().loadFromFile(_arg1);
trace("\nstart load settings");
}];
super();
stage.scaleMode = StageScaleMode.NO_SCALE;
loadItem();
}
private function onLoadItem(_arg1:Event=null):void{
if (load_items.length != 0){
load_items.pop()(onLoadItem);
return;
};
trace("Preloader-> end load all\n");
initApp();
}
private function loadItem(_arg1:Event=null):void{
Settings.getInstance().loadFromXml(XmlSettings.settings);
StringTable.getInstance().loadFromXml(XmlSettings.string_table);
trace("Preloader-> end load all\n");
initApp();
}
protected function onMoreGamesClick(_arg1:MouseEvent):void{
var e = _arg1;
try {
navigateToURL(new URLRequest(Settings.getInstance().getProperty("more_games_link")), "_blank");
} catch(err:Error) {
trace(("Error->MainMenuState: navigateToUrl throw exception \n" + err.getStackTrace()));
};
}
protected function onDownloadAdvanced(_arg1:ContextMenuEvent):void{
var e = _arg1;
try {
navigateToURL(new URLRequest(Settings.getInstance().getProperty("download_link")), "_blank");
} catch(err:Error) {
trace(("Error->MainMenuState: navigateToUrl throw exception \n" + err.getStackTrace()));
};
}
public function update(_arg1:Event):void{
bytesLoaded = stage.loaderInfo.bytesLoaded;
if (bytesTotal > 0){
percent = Math.floor(((bytesLoaded / bytesTotal) * 100));
percents_field.percents.text = ((StringTable.getInstance().getString("loading") + percent) + "%");
progress_bar.scaleX = (bytesLoaded / bytesTotal);
};
if ((((bytesLoaded == bytesTotal)) || ((bytesTotal == 0)))){
removeEventListener(Event.ENTER_FRAME, update, false);
stop();
if (contains(progress_bar)){
removeChild(progress_bar);
};
if (contains(percents_field)){
removeChild(percents_field);
};
trace("all percents loaded");
stage.addChild(StateManager.getInstance());
StateManager.getInstance().pushState(MainMenuState.getInstance());
};
}
public function initApp():void{
var _local1:ContextMenu;
var _local2:ContextMenuItem;
_local1 = new ContextMenu();
_local1.hideBuiltInItems();
_local2 = new ContextMenuItem(StringTable.getInstance().getString("download_contextMenuName"));
_local1.customItems.push(_local2);
_local2.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, onDownloadAdvanced);
contextMenu = _local1;
preloader_clip.gg_button.addEventListener(MouseEvent.CLICK, onMoreGamesClick);
bytesTotal = stage.loaderInfo.bytesTotal;
addEventListener(Event.ENTER_FRAME, update, false, 0, true);
progress_bar = new Progress_Bar();
percents_field = new Percents();
addChild(progress_bar);
progress_bar.x = Settings.getInstance().getNumberProperty("preloader_progressbar_x", "50.0");
progress_bar.y = Settings.getInstance().getNumberProperty("preloader_progressbar_y", "530.0");
addChild(percents_field);
percents_field.x = Settings.getInstance().getNumberProperty("preloader_text_x", "50.0");
percents_field.y = Settings.getInstance().getNumberProperty("preloader_text_y", "480.0");
progress_bar.scaleX = 0.001;
percents_field.percents.text = (StringTable.getInstance().getString("loading") + "0%");
}
}
}//package Common
Section 6
//Profile (Common.Profile)
package Common {
import flash.utils.*;
public class Profile {
public var level:int;// = 0
public var isView_firstTime:Dictionary;
public var score:int;// = 0
private static var instance:Profile = null;
public function Profile(_arg1:EnforceSingletone){
score = 0;
level = 0;
isView_firstTime = new Dictionary(true);
super();
resetProfile(true);
}
public function resetProfile(_arg1:Boolean=false):void{
if (_arg1){
isView_firstTime["help"] = false;
isView_firstTime["half_time"] = false;
isView_firstTime["bomb"] = false;
isView_firstTime["lightning"] = false;
isView_firstTime["dynamyte"] = false;
isView_firstTime["clock"] = false;
isView_firstTime["black_figure"] = false;
isView_firstTime["chain"] = false;
isView_firstTime["double_chain"] = false;
isView_firstTime["double_stone"] = false;
};
score = 0;
level = 0;
}
public function setLevel(_arg1:int):void{
this.level = _arg1;
}
public function loadProfile(_arg1:String):void{
}
public function incLevel():int{
return (++level);
}
public function decLevel():int{
return (--level);
}
public function saveProfile():void{
}
public function getLevel():int{
return (level);
}
public function setScore(_arg1:int):void{
this.score = _arg1;
}
public function addScore(_arg1:int):int{
score = (score + _arg1);
return (score);
}
public function getAllProfiles():Array{
return (new Array());
}
public function getScore():int{
return (score);
}
public static function getInstance():Profile{
if (instance == null){
instance = new Profile(new EnforceSingletone());
};
return (instance);
}
}
}//package Common
class EnforceSingletone {
private function EnforceSingletone(){
}
}
Section 7
//Settings (Common.Settings)
package Common {
import flash.events.*;
import flash.utils.*;
import flash.net.*;
public class Settings {
protected var callback:Function;
protected var is_loaded:Boolean;// = false
protected var default_path:String;// = "settings.xml"
protected var levels:Array;
protected var properties:Dictionary;
private static var instance:Settings = null;
public function Settings(_arg1:EnforceSingletone){
default_path = "settings.xml";
is_loaded = false;
levels = new Array();
properties = new Dictionary(true);
super();
}
public function setDefaultPath(_arg1:String):void{
default_path = _arg1;
}
public function getProperty(_arg1:String, _arg2:String="def"):String{
if (properties[_arg1] != null){
return (properties[_arg1]);
};
return (_arg2);
}
public function loadFromFile(_arg1:Function=null):void{
var _local2:URLLoader;
is_loaded = false;
_local2 = new URLLoader();
_local2.addEventListener(Event.COMPLETE, onCompleteLoad, false, 0, true);
_local2.load(new URLRequest(default_path));
this.callback = _arg1;
}
public function loadFromXml(_arg1:XML):void{
parse(_arg1);
is_loaded = true;
trace("end load settings");
}
public function isLoaded():Boolean{
return (is_loaded);
}
public function getDefaultPath():String{
return (default_path);
}
public function getLevel(_arg1:int):LevelInfo{
if (((((is_loaded) && ((_arg1 >= 0)))) && ((_arg1 < levels.length)))){
return (levels[_arg1]);
};
return (null);
}
public function getCurLevel():LevelInfo{
var _local1:int;
_local1 = Profile.getInstance().level;
if (((((is_loaded) && ((_local1 >= 0)))) && ((_local1 < levels.length)))){
return (levels[_local1]);
};
return (null);
}
public function getNumLevels():int{
return (levels.length);
}
public function getBooleanProperty(_arg1:String, _arg2:String="false"):Boolean{
var _local3:String;
_local3 = getProperty(_arg1, _arg2);
if (_local3 == "true"){
return (true);
};
if (_local3 == "false"){
return (false);
};
trace((("Error->Settings->getNumberProperty: settings property [" + _arg1) + "] is not Boolean"));
return (getBooleanProperty(_arg2));
}
public function getIntProperty(_arg1:String, _arg2:String="0"):int{
var name = _arg1;
var default_property = _arg2;
try {
return (parseInt(getProperty(name, default_property)));
} catch(e:Error) {
trace(("Error->Settings->getIntProperty: " + e.getStackTrace()));
};
return (getIntProperty(default_property));
}
private function parse(_arg1:XML):void{
var property:XML;
var default_level:LevelInfo;
var level:XML;
var lev_info:LevelInfo;
var xml = _arg1;
try {
for each (property in xml.children()) {
if (property.name() != "levels"){
properties[property.name()] = property.text();
};
};
default_level = new LevelInfo();
if (xml["levels"].child("default_level").length() <= 0){
default_level = LevelInfo.getPureLevel();
} else {
default_level.load(xml["levels"].elements("default_level")[0], LevelInfo.getPureLevel());
};
for each (level in xml["levels"].elements("level")) {
lev_info = new LevelInfo();
lev_info.load(level, default_level);
levels.push(lev_info);
};
} catch(e:Error) {
trace(("Error parse settings xml." + e.getStackTrace()));
};
}
public function getNumberProperty(_arg1:String, _arg2:String="0.0"):Number{
var name = _arg1;
var default_property = _arg2;
try {
return (parseFloat(getProperty(name, default_property)));
} catch(e:Error) {
trace(("Error->Settings->getNumberProperty: " + e.getStackTrace()));
};
return (getNumberProperty(default_property));
}
private function onCompleteLoad(_arg1:Event):void{
var xml:XML;
var evt = _arg1;
try {
xml = new XML(evt.target.data);
parse(xml);
trace(levels);
is_loaded = true;
trace("end load settings");
if (callback != null){
callback();
};
callback = null;
} catch(e:Error) {
trace(("Error load settings." + e.getStackTrace()));
};
}
public static function getInstance():Settings{
if (instance == null){
instance = new Settings(new EnforceSingletone());
};
return (instance);
}
}
}//package Common
class EnforceSingletone {
private function EnforceSingletone(){
}
}
Section 8
//SoundManager (Common.SoundManager)
package Common {
import flash.events.*;
import flash.utils.*;
import flash.media.*;
public class SoundManager {
protected var sounds:Dictionary;
protected var transform:SoundTransform;
protected var channels:Array;
public function SoundManager(){
sounds = new Dictionary();
channels = new Array();
transform = new SoundTransform(0.7);
}
public function stopAllSounds(){
var _local1:SoundChannel;
for each (_local1 in channels) {
_local1.addEventListener(Event.SOUND_COMPLETE, onSoundComplete);
_local1.stop();
};
channels = new Array();
}
protected function onSoundComplete(_arg1:Event):void{
var _local2:int;
_local2 = channels.indexOf(_arg1.target);
if (_local2 >= 0){
channels[_local2].removeEventListener(Event.SOUND_COMPLETE, onSoundComplete);
channels.splice(_local2, 1);
};
}
public function getGlobalVolume():Number{
return (transform.volume);
}
public function playSound(_arg1:String, _arg2:Number=0, _arg3:Boolean=true, _arg4:Number=-1):SoundChannel{
var _local5:Sound;
var _local6:SoundChannel;
var _local7:Class;
if (sounds[_arg1] == null){
_local7 = (getDefinitionByName(_arg1) as Class);
if (_local7 == null){
trace(("Error: no sound " + _arg1));
return (null);
};
sounds[_arg1] = new (_local7);
};
_local5 = sounds[_arg1];
if (_arg2 == -1){
_arg2 = int.MAX_VALUE;
};
_local6 = _local5.play(0, _arg2, transform);
if (_arg3){
channels.push(_local6);
_local6.addEventListener(Event.SOUND_COMPLETE, onSoundComplete);
};
if (_arg4 == -1){
_local6.soundTransform = transform;
} else {
_local6.soundTransform = new SoundTransform(_arg4);
};
return (_local6);
}
public function setGlobalVolume(_arg1:Number){
var _local2:SoundChannel;
transform.volume = _arg1;
for each (_local2 in channels) {
_local2.soundTransform = transform;
};
}
}
}//package Common
class EnforceSingletone {
private function EnforceSingletone(){
}
}
Section 9
//State (Common.State)
package Common {
import flash.display.*;
public class State extends MovieClip {
var state_name:String;// = "no_name"
var is_initiliazed:Boolean;// = false
public function State(){
is_initiliazed = false;
state_name = "no_name";
super();
}
public function getName():String{
return (state_name);
}
public function onResume():void{
}
public function setName(_arg1:String):void{
state_name = _arg1;
}
public function onPop():void{
}
public function internalInit():void{
if (!is_initiliazed){
is_initiliazed = true;
onPreInit();
};
onInit();
}
public function onPreInit():void{
}
public function onInit():void{
}
public function onPush():void{
}
public function isInitiliazed():Boolean{
return (is_initiliazed);
}
public function onCleanup():void{
}
}
}//package Common
Section 10
//StateManager (Common.StateManager)
package Common {
import flash.display.*;
public class StateManager extends MovieClip {
protected var states:Array;
public var fx_soundManager:SoundManager;
public var music_soundManager:SoundManager;
protected var last_state:State;// = null
protected var items_count;// = 0
private static var instance:StateManager = null;
public function StateManager(){
states = new Array();
last_state = null;
items_count = 0;
music_soundManager = new SoundManager();
fx_soundManager = new SoundManager();
super();
music_soundManager.setGlobalVolume(Settings.getInstance().getNumberProperty("volume", "0.7"));
fx_soundManager.setGlobalVolume(Settings.getInstance().getNumberProperty("volume", "0.7"));
}
public function getTopStateName():String{
if (getTopState() == null){
trace("StateManager->getTopStateName-> 'states array length == 0'");
return (null);
};
return (getTopState().getName());
}
public function pushState(_arg1:State):void{
if (states.length != 0){
last_state = states[(states.length - 1)];
last_state.onPush();
last_state.stop();
} else {
last_state = _arg1;
};
states.push(_arg1);
addChild(_arg1);
_arg1.internalInit();
trace("StateManager->push: ", states);
}
public function getTopState():State{
if (states.length == 0){
return (null);
};
return (states[(states.length - 1)]);
}
public function changeState(_arg1:State):void{
if (states.length != 0){
last_state = states[(states.length - 1)];
};
while (states.length != 0) {
popState();
};
pushState(_arg1);
}
public function popState():void{
if (states.length != 0){
last_state = states[(states.length - 1)];
states.pop();
removeChild(last_state);
if (states.length != 0){
states[(states.length - 1)].gotoAndPlay(0);
states[(states.length - 1)].onResume();
};
last_state.onCleanup();
};
trace("StateManager->pop: ", states);
}
public function getLastState():State{
return (last_state);
}
public static function getInstance():StateManager{
if (instance == null){
instance = new (StateManager);
};
return (instance);
}
}
}//package Common
Section 11
//StringTable (Common.StringTable)
package Common {
import flash.events.*;
import flash.utils.*;
import flash.net.*;
public class StringTable {
var callback:Function;
private var file_name:String;// = ""
var loader:URLLoader;
private var table:Dictionary;// = null
private var is_loaded:Boolean;// = false
private static var instance:StringTable = null;
public function StringTable(){
table = null;
is_loaded = false;
file_name = "";
super();
}
private function parse(_arg1:XML):Dictionary{
var array:*;
var lang:String;
var str:XML;
var xml = _arg1;
try {
array = new Dictionary();
lang = xml.@["lang"];
for each (str in xml.elements()) {
array[str.@["alias"].toString()] = ("" + str.@[lang].toString());
};
return (array);
} catch(e:Error) {
trace(("Error parse string table xml." + e));
};
return (null);
}
public function loadFromFile(_arg1:String, _arg2:Function=null):void{
this.file_name = _arg1;
loader = new URLLoader();
loader.dataFormat = URLLoaderDataFormat.TEXT;
loader.addEventListener(Event.COMPLETE, onCompleteLoad, false, 0, true);
loader.load(new URLRequest(_arg1));
this.callback = _arg2;
}
public function isLoaded():Boolean{
return (is_loaded);
}
public function addString(_arg1:String, _arg2:String):void{
table[_arg1] = _arg2;
}
public function getString(_arg1:String):String{
if (((!((table == null))) && (!((table[_arg1] == null))))){
return (table[_arg1]);
};
trace("Warning! Alias", (("\"" + _arg1) + "\""), "is not found");
return ("?????");
}
public function getTable():Dictionary{
var _local1:Dictionary;
var _local2:String;
if (table != null){
_local1 = new Dictionary();
for (_local2 in table) {
_local1[_local2] = table[_local2];
};
return (_local1);
};
return (null);
}
private function onCompleteLoad(_arg1:Event):void{
var table_xml:XML;
var evt = _arg1;
try {
table_xml = new XML(evt.target.data);
table = parse(table_xml);
is_loaded = true;
if (callback != null){
callback();
};
loader.removeEventListener(Event.COMPLETE, onCompleteLoad);
loader = null;
callback = null;
} catch(e:TypeError) {
trace("Error load string table xml file.");
};
}
public function loadFromXml(_arg1:XML):void{
table = parse(_arg1);
is_loaded = true;
}
public static function getInstance():StringTable{
if (instance == null){
instance = new (StringTable);
};
return (instance);
}
}
}//package Common
Section 12
//BaseCell (Game.BaseCell)
package Game {
import flash.utils.*;
import flash.display.*;
public class BaseCell {
protected var available_movies:Dictionary;
var prev_width:Number;
protected var cur_movies:Dictionary;
protected var main_movie:MovieClip;
var prev_height:Number;
public function BaseCell(_arg1:int=0, _arg2:int=0){
main_movie = new MovieClip();
available_movies = new Dictionary(true);
cur_movies = new Dictionary(true);
super();
if ((((_arg1 > 0)) && ((_arg2 > 0)))){
createTopMovie(_arg1, _arg2);
};
}
public function get width():Number{
return (main_movie.width);
}
public function getMainMovie():MovieClip{
return (main_movie);
}
public function get visible():Boolean{
return (main_movie.visible);
}
public function removeMovie(_arg1:MovieClip):void{
if (main_movie.contains(_arg1)){
_arg1.stop();
main_movie.removeChild(_arg1);
};
}
public function addEventListener(_arg1:String, _arg2:Function):void{
var _local3:MovieClip;
_local3 = available_movies["top_movie"];
if (_local3 != null){
_local3.addEventListener(_arg1, _arg2, false, 0, true);
};
}
public function setCurTypeMovie(_arg1:String, _arg2:MovieClip):void{
var _local3:MovieClip;
_local3 = cur_movies[_arg1];
if (_local3 != null){
if (_local3 != _arg2){
addMovie(_arg2);
if (main_movie.contains(_local3)){
main_movie.swapChildren(_arg2, _local3);
};
removeMovie(_local3);
cur_movies[_arg1] = _arg2;
};
} else {
cur_movies[_arg1] = _arg2;
if (!main_movie.contains(_arg2)){
addMovie(_arg2);
};
};
}
public function removeEventListener(_arg1:String, _arg2:Function):void{
var _local3:MovieClip;
_local3 = available_movies["top_movie"];
if (_local3 != null){
_local3.removeEventListener(_arg1, _arg2);
};
}
public function getMovie(_arg1:String):MovieClip{
return (available_movies[_arg1]);
}
public function addMovie(_arg1:MovieClip):void{
var _local2:MovieClip;
_local2 = available_movies["top_movie"];
_arg1.gotoAndPlay(0);
main_movie.addChild(_arg1);
_arg1.x = 0;
_arg1.y = 0;
if (_local2 != null){
main_movie.swapChildren(_arg1, _local2);
};
if ((((((_local2 == null)) && ((width > 0)))) && ((height > 0)))){
createTopMovie(width, height);
};
}
public function setCurTypeMovieByName(_arg1:String, _arg2:String):MovieClip{
var _local3:MovieClip;
if (getMovie(_arg2) != null){
_local3 = getMovie(_arg2);
setCurTypeMovie(_arg1, _local3);
return (_local3);
};
return (null);
}
public function set y(_arg1:Number):void{
main_movie.y = _arg1;
}
public function set visible(_arg1:Boolean):void{
main_movie.visible = _arg1;
}
public function getMovieName(_arg1:MovieClip):String{
var _local2:String;
for (_local2 in available_movies) {
if (available_movies[_local2] == _arg1){
return (_local2);
};
};
return (null);
}
public function get height():Number{
return (main_movie.height);
}
public function getCurTypeMovie(_arg1:String):MovieClip{
return (cur_movies[_arg1]);
}
public function removeMovieByName(_arg1:String, _arg2:Boolean):void{
var _local3:MovieClip;
_local3 = available_movies[_arg1];
if (_local3 != null){
delete available_movies[_arg1];
_local3["parent_cell"] = null;
if (_arg2){
removeMovie(_local3);
};
};
}
public function set x(_arg1:Number):void{
main_movie.x = _arg1;
}
private function createTopMovie(_arg1:int, _arg2:int):void{
var _local3:MovieClip;
available_movies["top_movie"] = new MovieClip();
_local3 = available_movies["top_movie"];
_local3["parent_cell"] = this;
_local3.x = 0;
_local3.y = 0;
_local3.graphics.beginFill(0xFFFFFF, 0);
_local3.graphics.drawRect((-(_arg1) / 2), (-(_arg2) / 2), _arg1, _arg2);
_local3.graphics.endFill();
main_movie.addChild(_local3);
}
public function addNamedMovie(_arg1:String, _arg2:MovieClip, _arg3:Boolean=false):void{
available_movies[_arg1] = _arg2;
_arg2["parent_cell"] = this;
if (_arg3){
addMovie(_arg2);
};
}
public function get y():Number{
return (main_movie.y);
}
public function get x():Number{
return (main_movie.x);
}
}
}//package Game
Section 13
//BonusInfo (Game.BonusInfo)
package Game {
public class BonusInfo {
public var cell:Cell;
public var figure:int;
public var type:String;
public function BonusInfo(_arg1:Cell, _arg2:String, _arg3:int){
this.cell = _arg1;
this.type = _arg2;
this.figure = _arg3;
}
}
}//package Game
Section 14
//Cell (Game.Cell)
package Game {
public class Cell extends BaseCell {
public var col:int;
private var chain:Zep;// = null
public var row:int;
private var figure:Figure;// = null
public var cell_type:int;// = 0
public function Cell(_arg1:int, _arg2:int, _arg3:int=0, _arg4:int=0, _arg5:Figure=null){
cell_type = 0;
figure = null;
chain = null;
super(_arg3, _arg4);
this.row = _arg1;
this.col = _arg2;
setFigure(_arg5);
}
public function setChain(_arg1:Zep):void{
this.chain = _arg1;
if (_arg1 != null){
_arg1.setParent(this);
};
}
public function getChain():Zep{
return (chain);
}
public function getNeighbourType(_arg1:Cell):String{
if ((((Math.abs((this.row - _arg1.row)) == 1)) && (((this.col - _arg1.col) == 0)))){
return ("vertical");
};
if ((((Math.abs((this.col - _arg1.col)) == 1)) && (((this.row - _arg1.row) == 0)))){
return ("horizontal");
};
return ("none");
}
public function getFigure():Figure{
return (figure);
}
public function setFigure(_arg1:Figure):void{
this.figure = _arg1;
if (_arg1 != null){
_arg1.setParent(this);
};
}
}
}//package Game
Section 15
//Figure (Game.Figure)
package Game {
public class Figure extends BaseCell {
private var parent:Cell;
public var is_move:Boolean;// = false
public var vel_y:Number;// = 0
public var vel_x:Number;// = 0
public var value:int;// = -2
public var bonus:String;// = null
public function Figure(){
vel_x = 0;
vel_y = 0;
is_move = false;
value = -2;
bonus = null;
super();
}
public function setParent(_arg1:Cell):void{
parent = _arg1;
}
public function isMoving():Boolean{
return (((!((vel_x == 0))) || (!((vel_y == 0)))));
}
public function getParent():Cell{
return (parent);
}
public function move():void{
if (((!((vel_x == 0))) || (!((vel_y == 0))))){
x = (x + vel_x);
y = (y + vel_y);
};
}
}
}//package Game
Section 16
//GameField (Game.GameField)
package Game {
import Common.*;
import flash.events.*;
import flash.utils.*;
import flash.display.*;
import flash.geom.*;
import States.*;
import Utillity.*;
public class GameField extends MovieClip {
protected var lightning_num_cells:int;
protected var moved_fg_1:Figure;// = null
protected var vel_alpha:Number;// = 0.1
protected var DEF_CELL_VEL:Number;// = 7
protected var moved_fg_2:Figure;// = null
protected var num_figures:int;
protected var numShowMovie_inFrame:Number;// = 3
protected var drag_figure:Figure;
protected var row_count:int;// = 11
protected var black_part:Number;
protected var move_anm:MovieClip;
protected var next_ind:int;// = 0
protected var mapData_type:String;// = "text"
protected var cell_size:Number;// = 40
protected var cell_movies:Array;
protected var random_timer:Timer;
protected var is_check_viewFirstTime:Boolean;// = false
protected var num_random_cells:int;
protected var is_show:Boolean;// = false
protected var selected_figure:Figure;// = null
protected var bonus_create:Array;
protected var combo_count:int;// = 0
protected var available_bonus:Array;
protected var is_drag:Boolean;// = false
protected var cur_showCell_ind:int;
protected var is_hide:Boolean;// = false
protected var move_timer:Timer;
protected var cells:Array;
protected var lightning_count:int;// = 0
protected var need_checkBonus_firstTime:Array;
var num_figuresAtField:int;// = 0
protected var is_moved:Boolean;// = false
protected var col_count:int;// = 13
protected var blocks:Array;
protected var all_movies:Array;
protected var dynamite_combo_type:int;
protected var dynamite_combo_cell:Cell;// = null
protected var dynamite_num_combo:int;
protected var dynamite_combo_count:int;// = 0
protected var is_stop:Boolean;// = true
protected var mouse_down:int;
protected var level_points:int;// = 0
protected var combo_mc:MovieClip;
protected static const BLACK_FIGURE:int = -1;
static var instance:GameField = null;
public function GameField(_arg1:EnforceSingletone){
DEF_CELL_VEL = 7;
cell_size = 40;
row_count = 11;
col_count = 13;
mapData_type = "text";
need_checkBonus_firstTime = new Array();
selected_figure = null;
moved_fg_1 = null;
moved_fg_2 = null;
is_moved = false;
is_stop = true;
bonus_create = new Array();
combo_count = 0;
dynamite_combo_count = 0;
dynamite_combo_cell = null;
is_drag = false;
lightning_count = 0;
random_timer = new Timer((5000 + Random.randomInt(5000)), 1);
move_timer = new Timer(5000, 1);
level_points = 0;
num_figuresAtField = 0;
is_check_viewFirstTime = false;
is_show = false;
is_hide = false;
vel_alpha = 0.1;
numShowMovie_inFrame = 3;
next_ind = 0;
cell_movies = ["square", "stone", "stone2", "figure", "chain", "chain2"];
super();
addEventListener(Event.ENTER_FRAME, update);
addEventListener(MouseEvent.MOUSE_DOWN, mouseDownListener);
addEventListener(MouseEvent.MOUSE_MOVE, mouseMoveListener);
addEventListener(MouseEvent.MOUSE_UP, mouseUpListener);
addEventListener(MouseEvent.ROLL_OVER, mouseUpListener);
}
protected function addCellDefaultMovies(_arg1:Cell):void{
_arg1.addNamedMovie("square", new Square(), true);
if (_arg1.cell_type > 1){
if ((((((_arg1.cell_type == 2)) || ((_arg1.cell_type == 6)))) || ((_arg1.cell_type == 7)))){
_arg1.addNamedMovie("stone", new Stone(), true);
_arg1.addNamedMovie("stone_away", new Stone_Away());
_arg1.setCurTypeMovieByName("stone_type", "stone");
};
if ((((((_arg1.cell_type == 3)) || ((_arg1.cell_type == 8)))) || ((_arg1.cell_type == 9)))){
_arg1.addNamedMovie("stone", new Stone());
_arg1.addNamedMovie("stone_away", new Stone_Away());
_arg1.setCurTypeMovie("stone_type", new MovieClip());
_arg1.addNamedMovie("stone2", new Stone2(), true);
_arg1.addNamedMovie("stone2_away", new Stone2_Away());
_arg1.setCurTypeMovieByName("stone2_type", "stone2");
};
};
}
protected function addFigureDefaultMovies(_arg1:Figure):void{
var _local2:String;
var _local3:String;
if (_arg1 != null){
_local2 = getFigureMoviePrefix(_arg1.bonus);
if (_arg1.value == BLACK_FIGURE){
_local3 = "Black";
} else {
_local3 = _arg1.value.toString();
};
_arg1.addNamedMovie("figure", LibraryMovies.getMovieFromLibrary(((_local2 + "_") + _local3)), true);
_arg1.setCurTypeMovieByName("figure_type", "figure");
_arg1.addNamedMovie("away", LibraryMovies.getMovieFromLibrary((((_local2 + "_") + _local3) + "_Away")));
_arg1.addNamedMovie("choose", LibraryMovies.getMovieFromLibrary((((_local2 + "_") + _local3) + "_Choose")));
_arg1.addNamedMovie("rollover", LibraryMovies.getMovieFromLibrary((((_local2 + "_") + _local3) + "_Rollover")));
if (_arg1.bonus == null){
_arg1.addNamedMovie("random", LibraryMovies.getMovieFromLibrary((((_local2 + "_") + _local3) + "_Random")));
};
};
}
protected function addCellListeners(_arg1:Cell):void{
if ((((((_arg1.cell_type == 2)) || ((_arg1.cell_type == 6)))) || ((_arg1.cell_type == 7)))){
_arg1.getMovie("stone_away").addEventListener(Event.ENTER_FRAME, stoneAwayListener, false, 0, true);
};
if ((((((_arg1.cell_type == 3)) || ((_arg1.cell_type == 8)))) || ((_arg1.cell_type == 9)))){
_arg1.getMovie("stone_away").addEventListener(Event.ENTER_FRAME, stoneAwayListener, false, 0, true);
_arg1.getMovie("stone2_away").addEventListener(Event.ENTER_FRAME, stoneAwayListener, false, 0, true);
};
}
protected function mixFigures(_arg1:Array):void{
var _local2:Cell;
var _local3:int;
var _local4:Array;
var _local5:Array;
var _local6:Array;
var _local7:Cell;
var _local8:Boolean;
var _local9:Array;
var _local10:int;
var _local11:Cell;
var _local12:int;
var _local13:Cell;
var _local14:Function;
var _local15:Cell;
trace("mix figures!");
for each (_local4 in _arg1) {
_local5 = new Array();
for each (_local2 in _local4) {
if ((((((_local2.cell_type > 0)) && (!((_local2.getFigure() == null))))) && ((_local2.getChain() == null)))){
_local5.push(_local2);
};
};
if (_local5.length <= 1){
} else {
while (_local5.length > 1) {
_local10 = Random.randomInt(_local5.length);
_local11 = _local5[_local10];
_local5.splice(_local10, 1);
_local12 = Random.randomInt(_local5.length);
_local13 = _local5[_local12];
_local5.splice(_local12, 1);
swapFigures(_local11, _local13);
};
_local8 = true;
_local9 = [findHorzLineMatch, findVertLineMatch];
while (_local8) {
trace("mixFigures: check matches!");
_local8 = false;
for each (_local2 in cells) {
for each (_local14 in _local9) {
_local6 = _local14(_local2, null);
if (_local6 != null){
_local8 = true;
for each (_local15 in _local6) {
if ((((((_local15.cell_type > 0)) && (!((_local15.getFigure() == null))))) && ((_local15.getChain() == null)))){
_local7 = _local4[Random.randomInt(cells.length)];
while (true) {
if (((((((((!((_local7 == null))) && ((_local7.cell_type > 0)))) && (!((_local7.getFigure() == null))))) && ((_local7.getChain() == null)))) && (!((_local7.getFigure().value == _local15.getFigure().value))))){
break;
};
_local7 = _local4[Random.randomInt(cells.length)];
};
swapFigures(_local15, _local7);
break;
};
};
};
};
};
};
};
};
}
protected function setMovieAlpha(_arg1:MovieClip, _arg2:Number):void{
if (_arg1 != null){
_arg1.alpha = _arg2;
};
}
public function stopField():void{
is_stop = true;
if (move_timer.running){
move_timer.stop();
};
if (random_timer.running){
random_timer.stop();
};
}
protected function initFigure(_arg1:Figure):void{
addFigureDefaultMovies(_arg1);
addFigureListeners(_arg1);
}
protected function getMatchCell(_arg1:Array):Cell{
if (((!((moved_fg_1 == null))) && ((_arg1.indexOf(moved_fg_1.getParent()) >= 0)))){
return (moved_fg_1.getParent());
};
if (((!((moved_fg_2 == null))) && ((_arg1.indexOf(moved_fg_2.getParent()) >= 0)))){
return (moved_fg_2.getParent());
};
return (_arg1[0]);
}
protected function getMoveType(_arg1:Cell, _arg2:Cell):String{
if ((_arg1.row - _arg2.row) != 0){
return ("vertical");
};
if ((_arg1.col - _arg2.col) != 0){
return ("horizontal");
};
return ("unknown");
}
protected function addChainDefaultMovies(_arg1:Cell):void{
var _local2:Zep;
if (_arg1.cell_type > 1){
_local2 = _arg1.getChain();
if (_local2 == null){
trace("addChainDefaultMovies-> chain == null !!!");
return;
};
if ((((((_arg1.cell_type == 4)) || ((_arg1.cell_type == 6)))) || ((_arg1.cell_type == 8)))){
_local2.addNamedMovie("chain", new Chain(), true);
_local2.addNamedMovie("chain_away", new Chain_Away());
_local2.setCurTypeMovieByName("chain_type", "chain");
};
if ((((((_arg1.cell_type == 5)) || ((_arg1.cell_type == 7)))) || ((_arg1.cell_type == 9)))){
_local2.addNamedMovie("chain", new Chain());
_local2.addNamedMovie("chain_away", new Chain_Away());
_local2.setCurTypeMovie("chain_type", new MovieClip());
_local2.addNamedMovie("chain2", new Chain2(), true);
_local2.addNamedMovie("chain2_away", new Chain2_Away());
_local2.setCurTypeMovieByName("chain2_type", "chain2");
};
};
}
protected function createExplosionBonus(_arg1:Cell, _arg2:int, _arg3:String):void{
var _local4:int;
var _local5:Array;
var _local6:int;
var _local7:int;
var _local8:Cell;
var _local9:MovieClip;
_local4 = (_arg2 / 2);
_local6 = -(_local4);
while (_local6 <= _local4) {
_local7 = -(_local4);
while (_local7 <= _local4) {
_local8 = getCell((_arg1.row + _local6), (_arg1.col + _local7));
if (((!((_local8 == null))) && ((_local8.cell_type > 0)))){
_local5 = awayCell(_local8);
if (((!((_local5 == null))) && ((_local5.length == 2)))){
var _local10 = _local5;
_local10[0](_local5[1]);
};
_local9 = LibraryMovies.getMovieFromLibrary(_arg3);
addChild(_local9);
_local9.x = getCellX(_local8.col);
_local9.y = getCellY(_local8.row);
_local9.addEventListener(Event.ENTER_FRAME, removeFromFieldAfterEndListener, false, 0, true);
};
_local7++;
};
_local6++;
};
}
protected function findHorzLineMatch(_arg1:Cell, _arg2:Array):Array{
var _local3:int;
var _local4:int;
var _local5:int;
var _local6:Array;
var _local7:Array;
var _local8:int;
var _local9:int;
var _local10:Cell;
if ((((((_arg1 == null)) || ((_arg1.cell_type == 0)))) || ((_arg1.getFigure() == null)))){
return (null);
};
_local3 = _arg1.row;
_local4 = _arg1.col;
_local5 = _arg1.getFigure().value;
if (_local5 == BLACK_FIGURE){
return (null);
};
_local6 = new Array();
_local7 = [-1, 1];
_local6.push(_arg1);
for each (_local8 in _local7) {
_local9 = 1;
while (_local9 < 8) {
_local10 = getCell(_local3, (_local4 + (_local8 * _local9)));
if (((!((_arg2 == null))) && ((_arg2.indexOf(_local10) >= 0)))){
break;
};
if (((((!((_local10 == null))) && (!((_local10.getFigure() == null))))) && ((_local10.getFigure().value == _local5)))){
_local6.push(_local10);
} else {
break;
};
_local9++;
};
};
if (_local6.length >= 3){
return (_local6);
};
return (null);
}
protected function getCellMovie(_arg1:Cell, _arg2:String):MovieClip{
switch (_arg2){
case "square":
return (_arg1.getMovie("square"));
case "stone":
return (_arg1.getMovie("stone"));
case "stone2":
return (_arg1.getMovie("stone2"));
case "figure":
if (_arg1.getFigure() != null){
return (_arg1.getFigure().getMovie("figure"));
};
break;
case "chain":
if (_arg1.getChain() != null){
return (_arg1.getChain().getMovie("chain"));
};
break;
case "chain2":
if (_arg1.getChain() != null){
return (_arg1.getChain().getMovie("chain2"));
};
break;
};
return (null);
}
protected function findBlock(_arg1:Cell, _arg2:Array):void{
var _local3:int;
var _local4:int;
var _local5:Cell;
if (_arg2.indexOf(_arg1) >= 0){
return;
};
_arg2.push(_arg1);
_local3 = -1;
while (_local3 <= 1) {
_local4 = -1;
while (_local4 <= 1) {
_local5 = getCell((_arg1.row + _local3), (_arg1.col + _local4));
if (((((!((_local5 == null))) && ((_local5.cell_type > 0)))) && ((_arg2.indexOf(_local5) < 0)))){
findBlock(_local5, _arg2);
};
_local4++;
};
_local3++;
};
}
protected function cellRollOverListener(_arg1:MouseEvent):void{
var _local2:Figure;
var _local3:MovieClip;
if (((((((((!(is_moved)) && (!(is_show)))) && (!(is_hide)))) && (!(is_stop)))) && ((drag_figure == null)))){
_local2 = _arg1.target.parent_cell;
_local3 = _local2.getCurTypeMovie("figure_type");
if (_local3 == _local2.getMovie("figure")){
_local2.setCurTypeMovieByName("figure_type", "rollover");
} else {
if (_local3 == _local2.getMovie("rollover")){
_local3.removeEventListener(Event.ENTER_FRAME, onRollOverAnimationEnd);
};
};
};
}
protected function onClickHintAnimation(_arg1:MouseEvent):void{
var _local2:MouseEvent;
var _local3:Figure;
if (move_anm != null){
move_anm.stop();
if (contains(move_anm)){
removeChild(move_anm);
};
move_anm.removeEventListener(Event.ENTER_FRAME, onHintAnimation);
move_anm.removeEventListener(MouseEvent.CLICK, onClickHintAnimation);
move_anm = null;
} else {
trace("onClickHintAnimation: move_anm == null !!!");
};
if (_arg1 != null){
_local2 = (_arg1.clone() as MouseEvent);
_local2.localX = (_arg1.localX + _arg1.target.x);
_local2.localY = (_arg1.localY + _arg1.target.y);
this.dispatchEvent(_local2);
_local3 = getFigureUnder(_arg1.stageX, _arg1.stageY);
if (_local3 != null){
selectFigure(_local3);
};
};
}
protected function onEndLevel(_arg1:MouseEvent):void{
var _local2:Cell;
var _local3:Array;
var _local4:int;
var _local5:MovieClip;
if (((((!(is_show)) && (!(is_moved)))) && (!(is_stop)))){
all_movies = new Array();
for each (_local2 in cells) {
if (_local2.cell_type > 0){
_local3 = new Array();
_local4 = 0;
while (_local4 < cell_movies.length) {
_local5 = getCellMovie(_local2, cell_movies[_local4]);
if (_local5 != null){
_local3.push(_local5);
};
_local4++;
};
all_movies.push(_local3);
};
};
next_ind = (all_movies.length - 1);
is_hide = true;
random_timer.stop();
move_timer.stop();
};
}
protected function incrementAndCheckDynamiteCombo():int{
dynamite_combo_count++;
if (dynamite_combo_count >= dynamite_num_combo){
trace("create dynamite");
if (dynamite_combo_cell.getFigure() != null){
dynamite_combo_cell = findNearEmptyCell(dynamite_combo_cell);
dynamite_combo_type = Random.randomInt(num_figures);
};
if (available_bonus.indexOf("dynamite") >= 0){
bonus_create.push(new BonusInfo(dynamite_combo_cell, "dynamite", dynamite_combo_type));
};
resetDynamiteComboCount();
};
return (dynamite_combo_count);
}
protected function canGenerateCell(_arg1:Cell):Boolean{
var _local2:Cell;
_local2 = getCell((_arg1.row - 1), _arg1.col);
if ((((_arg1.getFigure() == null)) && ((((_arg1.row == 0)) || (((((!((_local2 == null))) && ((_local2.cell_type == 0)))) && (!(canCreateLeftOrRightCell(_arg1))))))))){
return (true);
};
return (false);
}
protected function generateField():void{
var _local1:int;
var _local2:Cell;
var _local3:Cell;
_local1 = 0;
while (_local1 < cells.length) {
_local2 = cells[_local1];
if (_local2.cell_type > 0){
if (_local2.cell_type >= 4){
_local2.setChain(new Zep());
};
};
_local1++;
};
calculateField();
_local1 = 0;
while (_local1 < cells.length) {
_local2 = cells[_local1];
if (((!((_local2.getChain() == null))) && ((_local2.getFigure() == null)))){
_local2.setFigure(new Figure());
generateRandomFigure(_local2.getFigure(), true);
};
_local1++;
};
num_figuresAtField = getNumFigures();
trace(("num_figuresAtField = " + num_figuresAtField));
_local1 = 0;
while (_local1 < Math.round((num_figuresAtField * black_part))) {
_local2 = cells[Random.randomInt(cells.length)];
_local3 = getCell((_local2.row + 1), _local2.col);
if ((((_local2.row == (row_count - 1))) || (((!((_local3 == null))) && ((_local3.cell_type == 0)))))){
_local1--;
} else {
if (((!((_local2.getFigure() == null))) && ((((((_local2.cell_type == 1)) || ((_local2.cell_type == 2)))) || ((_local2.cell_type == 3)))))){
_local2.getFigure().value = BLACK_FIGURE;
} else {
_local1--;
};
};
_local1++;
};
}
protected function placeCells():void{
var _local1:Cell;
for each (_local1 in cells) {
placeCell(_local1);
};
}
protected function findMaxCol(_arg1:Array):int{
var _local2:int;
var _local3:Cell;
_local2 = _arg1[0].col;
for each (_local3 in _arg1) {
if (_local3.col > _local2){
_local2 = _local3.col;
};
};
return (_local2);
}
protected function removeFigureListeners(_arg1:Figure):void{
if (_arg1 != null){
_arg1.removeEventListener(MouseEvent.ROLL_OVER, cellRollOverListener);
_arg1.removeEventListener(MouseEvent.ROLL_OUT, cellRollOutListener);
_arg1.removeEventListener(MouseEvent.CLICK, figureClickListener);
};
}
protected function containsAnyFigure(_arg1:Cell, _arg2:Number=0, _arg3:Number=0, _arg4:Number=0, _arg5:Number=0):Boolean{
var _local6:Rectangle;
var _local7:Cell;
_local6 = _arg1.getMainMovie().getBounds(this);
_arg1.getMainMovie().getBounds(this).left = (_local6.left + (_arg3 + 3));
_local6.top = (_local6.top + (_arg2 + 3));
_local6.right = (_local6.right + (_arg5 - 3));
_local6.bottom = (_local6.bottom + (_arg4 - 3));
for each (_local7 in cells) {
if ((((((_local7.cell_type > 0)) && (!((_local7.getFigure() == null))))) && (!((_local7 == _arg1))))){
if (_local6.intersects(_local7.getFigure().getMainMovie().getBounds(this))){
return (true);
};
};
};
return (false);
}
protected function removeFromFieldAfterEndListener(_arg1:Event):void{
var _local2:MovieClip;
_local2 = (_arg1.target as MovieClip);
if ((((_local2.currentFrame >= (_local2.totalFrames - 1))) && (contains(_local2)))){
_local2.stop();
removeChild(_local2);
_local2.removeEventListener(Event.ENTER_FRAME, removeFromFieldAfterEndListener);
};
}
protected function findBlocksToMix():Array{
var _local1:Array;
var _local2:Cell;
var _local3:Boolean;
var _local4:Array;
_local1 = new Array();
while (true) {
_local3 = false;
for each (_local2 in cells) {
if ((((_local2.cell_type > 0)) && ((getBlock(_local2, _local1) == null)))){
_local3 = true;
break;
};
};
if (_local3){
trace("new_block");
_local4 = new Array();
findBlock(_local2, _local4);
_local1.push(_local4);
} else {
break;
};
};
return (_local1);
}
protected function findNoneLineMatch(_arg1:Cell, _arg2:Array):Array{
var _local3:int;
var _local4:int;
var _local5:Array;
var _local6:Array;
var _local7:String;
var _local8:Array;
var _local9:int;
var _local10:int;
if (_arg1 == null){
return (null);
};
_local3 = _arg1.row;
_local4 = _arg1.col;
_local5 = findHorzLineMatch(_arg1, _arg2);
_local6 = findVertLineMatch(_arg1, _arg2);
if (((!((_local5 == null))) && (!((_local6 == null))))){
_local8 = _local5.concat(_local6);
_local5.concat(_local6).splice(_local8.lastIndexOf(_arg1), 1);
_local9 = ((findMinRow(_local6) - _local3) * (findMaxRow(_local6) - _local3));
_local10 = ((findMinCol(_local5) - _local4) * (findMaxCol(_local5) - _local4));
if (_local8.length == 8){
_local7 = "match_8";
};
if (_local8.length == 7){
_local7 = "match_7";
};
if (_local8.length == 6){
_local7 = "match_6";
};
if ((((_local9 == 0)) && ((_local10 == 0)))){
_local7 = "match_L";
};
if ((((((((_local9 == 0)) && ((_local10 < 0)))) || ((((_local9 < 0)) && ((_local10 == 0)))))) && ((_local8.length == 5)))){
_local7 = "match_T";
};
if ((((((_local9 < 0)) && ((_local10 < 0)))) && ((_local8.length == 5)))){
_local7 = "match_+";
};
_local8.push(_local7);
return (_local8);
};
return (null);
}
protected function needLeftCell(_arg1:Cell):Boolean{
var _local2:Cell;
var _local3:Cell;
var _local4:Cell;
var _local5:Cell;
if ((((_arg1.row < (row_count - 1))) && ((_arg1.col > 0)))){
_local2 = getCell(_arg1.row, (_arg1.col - 1));
_local3 = getCell((_arg1.row - 1), _arg1.col);
_local4 = getCell((_arg1.row - 1), (_arg1.col - 1));
_local5 = getCell((_arg1.row + 1), (_arg1.col - 1));
if (((((!((_local2 == null))) && ((_local2.cell_type > 0)))) && (((((!((_local2.getFigure() == null))) && ((_local2.getChain() == null)))) || (canGenerateCellNow(_local2)))))){
return (false);
};
if ((((_local5.getFigure() == null)) && ((_local5.cell_type > 0)))){
if (_local2 != null){
if ((((_local2.cell_type > 0)) && ((_local2.getFigure() == null)))){
if (_arg1.getFigure().is_move){
return (true);
};
if (_local3 != null){
if (((!(canGenerateCellOver(_arg1))) && (!(canGenerateCellOver(_local2))))){
return (true);
};
};
};
if ((((_local2.cell_type == 0)) || (!((_local2.getChain() == null))))){
return (true);
};
};
};
};
return (false);
}
protected function mouseDownListener(_arg1:MouseEvent):void{
is_drag = false;
if (move_anm != null){
onClickHintAnimation(null);
};
if (((((((((!(is_moved)) && (!(is_show)))) && (!(is_hide)))) && (!(is_stop)))) && ((drag_figure == null)))){
drag_figure = getFigureUnder((_arg1.stageX - x), (_arg1.stageY - y));
if (drag_figure != null){
if (drag_figure.getParent().getChain() != null){
drag_figure = null;
};
};
};
}
protected function figureAwayListener(_arg1:Event):void{
var _local2:MovieClip;
_local2 = (_arg1.target as MovieClip);
if (((((!((_local2.parent == null))) && ((_local2.currentFrame >= (_local2.totalFrames - 1))))) && (!((_local2["parent_cell"] == null))))){
removeFigureListeners(_local2["parent_cell"]);
_local2.removeEventListener(Event.ENTER_FRAME, figureAwayListener);
removeChild(_local2["parent_cell"].getMainMovie());
_local2.stop();
_local2["parent_cell"] = null;
};
}
protected function initShowField():void{
var _local1:int;
var _local2:Cell;
var _local3:int;
var _local4:MovieClip;
_local1 = 0;
while (_local1 < cells.length) {
_local2 = cells[_local1];
if (_local2.cell_type > 0){
setAllCellMovieAlpha(_local2, 0);
};
_local1++;
};
all_movies = new Array();
_local3 = 0;
while (_local3 < cell_movies.length) {
_local1 = 0;
while (_local1 < cells.length) {
_local2 = cells[_local1];
if (_local2.cell_type > 0){
_local4 = getCellMovie(_local2, cell_movies[_local3]);
if (_local4 != null){
all_movies.push(_local4);
};
};
_local1++;
};
_local3++;
};
is_show = true;
next_ind = 0;
}
protected function onRollOverAnimationEnd(_arg1:Event):void{
var _local2:MovieClip;
_local2 = (_arg1.target as MovieClip);
if (((((!((_local2 == null))) && ((_local2.currentFrame >= (_local2.totalFrames - 1))))) && (!((_local2["parent_cell"] == null))))){
_local2.removeEventListener(Event.ENTER_FRAME, onRollOverAnimationEnd);
if (_local2["parent_cell"].getCurTypeMovie("figure_type") == _local2["parent_cell"].getMovie("rollover")){
_local2["parent_cell"].setCurTypeMovieByName("figure_type", "figure");
};
};
}
protected function setAllCellMovieAlpha(_arg1:Cell, _arg2:Number):void{
var _local3:int;
_local3 = 0;
while (_local3 < cell_movies.length) {
setMovieAlpha(getCellMovie(_arg1, cell_movies[_local3]), _arg2);
_local3++;
};
}
protected function update(_arg1:Event):void{
var cell:Cell;
var figure:Figure;
var i:int;
var mc:MovieClip;
var isSet_AnyAlpha:Boolean;
var mc_array:Array;
var message:String;
var fld_bnds:Rectangle;
var bonus_str:String;
var under_cell:Cell;
var info_ind:int;
var exist_new_cell:Boolean;
var time_left_score:int;
var statistics:Array;
var check_functions:Array;
var funcs:Array;
var target_cell:Cell;
var dx:Number;
var mdx:Number;
var dy:Number;
var mdy:Number;
var away_cell:Cell;
var multiplier:int;
var cell_point:int;
var was_combo:Boolean;
var bonuses:Array;
var returned_bonus:Array;
var match_cells:Array;
var match_type:String;
var bonus_info:BonusInfo;
var exist_moved_cell:Boolean;
var e = _arg1;
if (is_stop){
return;
};
if (is_show){
isSet_AnyAlpha = false;
i = 0;
while (i < numShowMovie_inFrame) {
if (next_ind >= all_movies.length){
break;
};
mc = all_movies[next_ind++];
mc.alpha = vel_alpha;
i = (i + 1);
};
i = 0;
while (i < next_ind) {
mc = all_movies[i];
if (mc.alpha < 1){
mc.alpha = (mc.alpha + vel_alpha);
isSet_AnyAlpha = true;
if (mc.alpha > 1){
mc.alpha = 1;
};
};
i = (i + 1);
};
if (!isSet_AnyAlpha){
is_show = false;
all_movies = null;
GameState.getInstance().startTimer();
};
return;
};
if (is_hide){
isSet_AnyAlpha = false;
i = 0;
while (i < numShowMovie_inFrame) {
if (next_ind < 0){
break;
};
mc_array = all_movies[next_ind--];
for each (mc in mc_array) {
mc.alpha = (1 - vel_alpha);
};
i = (i + 1);
};
i = (all_movies.length - 1);
while (i > next_ind) {
mc_array = all_movies[i];
for each (mc in mc_array) {
if (mc.alpha > 0){
mc.alpha = (mc.alpha - vel_alpha);
isSet_AnyAlpha = true;
if (mc.alpha < 0){
mc.alpha = 0;
};
};
};
i = (i - 1);
};
if (!isSet_AnyAlpha){
is_hide = false;
all_movies = null;
stopField();
time_left_score = (GameState.getInstance().getTime() * Settings.getInstance().getIntProperty("numberPoints_forSecond", "1"));
GameState.getInstance().addScore(time_left_score);
statistics = [level_points, time_left_score, (level_points + time_left_score)];
GameState.getInstance().fadeMusic();
StateManager.getInstance().pushState(new LevelCompleteWindowState(statistics, function (){
reset();
GameState.getInstance().loadNextLevel();
}));
};
return;
};
if (!is_check_viewFirstTime){
check_functions = [[function ():Boolean{
return (Profile.getInstance().isView_firstTime["black_figure"]);
}, function (_arg1:Boolean){
Profile.getInstance().isView_firstTime["black_figure"] = _arg1;
}, function (_arg1:Cell):Boolean{
if (((!((_arg1.getFigure() == null))) && ((_arg1.getFigure().value == BLACK_FIGURE)))){
return (true);
};
return (false);
}, "firstTime_blackFigure"], [function ():Boolean{
return (Profile.getInstance().isView_firstTime["chain"]);
}, function (_arg1:Boolean){
Profile.getInstance().isView_firstTime["chain"] = _arg1;
}, function (_arg1:Cell):Boolean{
if ((((((_arg1.cell_type == 4)) || ((_arg1.cell_type == 6)))) || ((_arg1.cell_type == 8)))){
return (true);
};
return (false);
}, "firstTime_chain"], [function ():Boolean{
return (Profile.getInstance().isView_firstTime["double_stone"]);
}, function (_arg1:Boolean){
Profile.getInstance().isView_firstTime["double_stone"] = _arg1;
}, function (_arg1:Cell):Boolean{
if ((((((_arg1.cell_type == 3)) || ((_arg1.cell_type == 8)))) || ((_arg1.cell_type == 9)))){
return (true);
};
return (false);
}, "firstTime_doubleStone"], [function ():Boolean{
return (Profile.getInstance().isView_firstTime["double_chain"]);
}, function (_arg1:Boolean){
Profile.getInstance().isView_firstTime["double_chain"] = _arg1;
}, function (_arg1:Cell):Boolean{
if ((((((_arg1.cell_type == 5)) || ((_arg1.cell_type == 7)))) || ((_arg1.cell_type == 9)))){
return (true);
};
return (false);
}, "firstTime_doubleChain"]];
for each (funcs in check_functions) {
if (!funcs[0]()){
target_cell = null;
for each (cell in cells) {
if (funcs[2](cell)){
target_cell = cell;
break;
};
};
if (target_cell != null){
var _local5 = funcs;
_local5[1](true);
stopField();
GameState.getInstance().stopTimer();
fld_bnds = getBounds(StateManager.getInstance());
message = StringTable.getInstance().getString(funcs[3]);
StateManager.getInstance().pushState(new HintMessage(message, new Point((getCellX(target_cell.col) + fld_bnds.x), (getCellY(target_cell.row) + fld_bnds.y)), function (){
startField();
GameState.getInstance().startTimer();
}));
return;
};
};
};
is_check_viewFirstTime = true;
};
for each (bonus_str in available_bonus) {
if (need_checkBonus_firstTime[bonus_str]){
i = 0;
while (i < cells.length) {
cell = cells[i];
if (((((!((cell.getFigure() == null))) && ((cell.getFigure().bonus == bonus_str)))) && (isFigureOnPlace(cell)))){
need_checkBonus_firstTime[bonus_str] = false;
Profile.getInstance().isView_firstTime[bonus_str] = true;
stopField();
GameState.getInstance().stopTimer();
fld_bnds = getBounds(StateManager.getInstance());
message = StringTable.getInstance().getString(("firstTime_" + bonus_str));
StateManager.getInstance().pushState(new HintMessage(message, new Point((getCellX(cell.col) + fld_bnds.x), (getCellY(cell.row) + fld_bnds.y)), function (){
startField();
GameState.getInstance().startTimer();
}));
return;
};
i = (i + 1);
};
};
};
for each (cell in cells) {
figure = cell.getFigure();
if ((((figure == null)) || ((figure == drag_figure)))){
} else {
if (figure.x != cell.x){
dx = (cell.x - figure.x);
mdx = Math.abs(dx);
if (mdx < DEF_CELL_VEL){
figure.x = cell.x;
figure.vel_x = 0;
} else {
figure.vel_x = ((DEF_CELL_VEL * dx) / mdx);
};
} else {
figure.vel_x = 0;
};
if (figure.y != cell.y){
dy = (cell.y - figure.y);
mdy = Math.abs(dy);
if (mdy < DEF_CELL_VEL){
figure.y = cell.y;
figure.vel_y = 0;
} else {
figure.vel_y = ((DEF_CELL_VEL * dy) / mdy);
figure.is_move = true;
};
} else {
figure.vel_y = 0;
};
};
};
is_moved = false;
for each (cell in cells) {
if (cell.getFigure() != null){
if (cell.getFigure().isMoving()){
is_moved = true;
cell.getFigure().move();
};
};
};
if (!is_moved){
was_combo = false;
bonuses = new Array();
for each (cell in cells) {
match_cells = findNoneLineMatch(cell, null);
if (match_cells != null){
match_type = match_cells.splice((match_cells.length - 1), 1);
trace(("match_type = " + match_type));
dynamite_combo_cell = getMatchCell(match_cells);
dynamite_combo_type = dynamite_combo_cell.getFigure().value;
if (!was_combo){
combo_count++;
showComboCount(combo_count);
};
if (combo_count <= 1){
StateManager.getInstance().fx_soundManager.playSound("burst1");
};
multiplier = combo_count;
if (multiplier > 7){
multiplier = 7;
};
cell_point = (15 * multiplier);
GameState.getInstance().addScore((cell_point * match_cells.length));
level_points = (level_points + (cell_point * match_cells.length));
switch (match_type){
case "match_8":
case "match_7":
case "match_6":
case "match_T":
if (available_bonus.indexOf("lightning") >= 0){
bonus_create.push(new BonusInfo(getMatchCell(match_cells), "lightning", match_cells[0].getFigure().value));
};
break;
case "match_+":
case "match_L":
if (available_bonus.indexOf("bomb") >= 0){
bonus_create.push(new BonusInfo(getMatchCell(match_cells), "bomb", match_cells[0].getFigure().value));
};
break;
};
for each (away_cell in match_cells) {
returned_bonus = awayCell(away_cell, cell_point);
if (((!((returned_bonus == null))) && ((returned_bonus.length == 2)))){
bonuses.push(returned_bonus);
};
};
if (!was_combo){
incrementAndCheckDynamiteCombo();
was_combo = true;
};
moved_fg_1 = null;
moved_fg_2 = null;
if (move_anm != null){
onClickHintAnimation(null);
};
};
};
for each (cell in cells) {
match_cells = findHorzLineMatch(cell, null);
if (match_cells != null){
trace(("match.length = " + match_cells.length));
dynamite_combo_cell = getMatchCell(match_cells);
dynamite_combo_type = dynamite_combo_cell.getFigure().value;
if ((((match_cells.length == 5)) && ((available_bonus.indexOf("clock") >= 0)))){
bonus_create.push(new BonusInfo(getMatchCell(match_cells), "clock", match_cells[0].getFigure().value));
};
if (!was_combo){
combo_count++;
showComboCount(combo_count);
};
if (combo_count <= 1){
StateManager.getInstance().fx_soundManager.playSound("burst1");
};
multiplier = combo_count;
if (multiplier > 7){
multiplier = 7;
};
switch (match_cells.length){
case 3:
cell_point = (5 * multiplier);
break;
case 4:
cell_point = (10 * multiplier);
break;
default:
cell_point = (15 * multiplier);
break;
};
GameState.getInstance().addScore((cell_point * match_cells.length));
level_points = (level_points + (cell_point * match_cells.length));
for each (away_cell in match_cells) {
returned_bonus = awayCell(away_cell, cell_point);
if (((!((returned_bonus == null))) && ((returned_bonus.length == 2)))){
bonuses.push(returned_bonus);
};
};
if (!was_combo){
incrementAndCheckDynamiteCombo();
was_combo = true;
};
moved_fg_1 = null;
moved_fg_2 = null;
if (random_timer.running){
random_timer.stop();
};
if (move_anm != null){
onClickHintAnimation(null);
};
} else {
match_cells = findVertLineMatch(cell, null);
if (match_cells != null){
trace(("match.length = " + match_cells.length));
dynamite_combo_cell = getMatchCell(match_cells);
dynamite_combo_type = dynamite_combo_cell.getFigure().value;
if ((((match_cells.length == 5)) && ((available_bonus.indexOf("clock") >= 0)))){
bonus_create.push(new BonusInfo(getMatchCell(match_cells), "clock", match_cells[0].getFigure().value));
};
if (!was_combo){
combo_count++;
showComboCount(combo_count);
};
if (combo_count <= 1){
StateManager.getInstance().fx_soundManager.playSound("burst1");
};
multiplier = combo_count;
if (multiplier > 7){
multiplier = 7;
};
switch (match_cells.length){
case 3:
cell_point = (5 * multiplier);
break;
case 4:
cell_point = (10 * multiplier);
break;
default:
cell_point = (15 * multiplier);
break;
};
GameState.getInstance().addScore((cell_point * match_cells.length));
level_points = (level_points + (cell_point * match_cells.length));
for each (away_cell in match_cells) {
returned_bonus = awayCell(away_cell, cell_point);
if (((!((returned_bonus == null))) && ((returned_bonus.length == 2)))){
bonuses.push(returned_bonus);
};
};
if (!was_combo){
incrementAndCheckDynamiteCombo();
was_combo = true;
};
moved_fg_1 = null;
moved_fg_2 = null;
if (random_timer.running){
random_timer.stop();
};
if (move_anm != null){
onClickHintAnimation(null);
};
};
};
};
for each (returned_bonus in bonuses) {
_local5 = returned_bonus;
_local5[0](returned_bonus[1]);
};
if (!random_timer.running){
random_timer.delay = (5000 + Random.randomInt(5000));
random_timer.repeatCount = 1;
random_timer.start();
};
};
if (!is_moved){
if (!move_timer.running){
startMoveTimer();
};
} else {
if (move_timer.running){
move_timer.stop();
};
if (move_anm != null){
onClickHintAnimation(null);
};
if (random_timer.running){
random_timer.stop();
};
};
if (((((((!((moved_fg_1 == null))) && (!((moved_fg_2 == null))))) && (!(moved_fg_1.isMoving())))) && (!(moved_fg_2.isMoving())))){
StateManager.getInstance().fx_soundManager.playSound("BadMove_Fx");
swapFigures(moved_fg_1.getParent(), moved_fg_2.getParent());
moved_fg_1 = null;
moved_fg_2 = null;
};
info_ind = 0;
while (info_ind < bonus_create.length) {
bonus_info = bonus_create[info_ind];
if (((((!((bonus_info.cell == null))) && ((bonus_info.cell.getFigure() == null)))) && (!((bonus_info.type == null))))){
cell = bonus_info.cell;
cell.setFigure(new Figure());
cell.getFigure().bonus = bonus_info.type;
cell.getFigure().value = bonus_info.figure;
initFigure(cell.getFigure());
placeCell(cell);
addChild(cell.getFigure().getMainMovie());
StateManager.getInstance().fx_soundManager.playSound("BonusAppear_Fx");
info_ind = (info_ind - 1);
bonus_create.splice(info_ind, 1);
if (!Profile.getInstance().isView_firstTime[bonus_info.type]){
need_checkBonus_firstTime[bonus_info.type] = true;
};
};
info_ind = (info_ind + 1);
};
for each (cell in cells) {
if (((((!((cell.getFigure() == null))) && (isFigureOnPlace(cell)))) && ((((((cell.cell_type == 1)) || ((cell.cell_type == 2)))) || ((cell.cell_type == 3)))))){
under_cell = getCell((cell.row + 1), cell.col);
if (under_cell != null){
if ((((under_cell.cell_type > 0)) && ((under_cell.getFigure() == null)))){
cell.getFigure().is_move = true;
swapFigures(cell, under_cell);
continue;
};
};
};
};
for each (cell in cells) {
if (((((!((cell.getFigure() == null))) && (isFigureOnPlace(cell)))) && ((((((cell.cell_type == 1)) || ((cell.cell_type == 2)))) || ((cell.cell_type == 3)))))){
if (needLeftCell(cell)){
cell.getFigure().is_move = true;
swapFigures(cell, getCell((cell.row + 1), (cell.col - 1)));
} else {
if (needRightCell(cell)){
cell.getFigure().is_move = true;
swapFigures(cell, getCell((cell.row + 1), (cell.col + 1)));
continue;
};
};
};
};
for each (cell in cells) {
if (((((!((cell.getFigure() == null))) && (isFigureOnPlace(cell)))) && (cell.getFigure().is_move))){
cell.getFigure().is_move = false;
};
};
exist_new_cell = false;
for each (cell in cells) {
if (cell.cell_type != 0){
if (canGenerateCellNow(cell)){
cell.setFigure(new Figure());
if ((((black_part > 0)) && ((getNumBlackFigures() < Math.round((num_figuresAtField * black_part)))))){
cell.getFigure().value = BLACK_FIGURE;
} else {
generateRandomFigure(cell.getFigure(), false);
};
initFigure(cell.getFigure());
placeCell(cell);
cell.getFigure().y = (cell.getFigure().y - ((3 * cell_size) / 4));
cell.getFigure().is_move = true;
addChild(cell.getFigure().getMainMovie());
exist_new_cell = true;
};
};
};
if (isGameCompleted()){
random_timer.stop();
move_timer.stop();
GameState.getInstance().stopTimer();
};
if (((!(exist_new_cell)) && (!(is_moved)))){
exist_moved_cell = false;
for each (cell in cells) {
if (((!((cell.getFigure() == null))) && (cell.getFigure().is_move))){
exist_moved_cell = true;
break;
};
};
if (!exist_moved_cell){
if (isGameCompleted()){
all_movies = new Array();
for each (cell in cells) {
if (cell.cell_type > 0){
mc_array = new Array();
i = 0;
while (i < cell_movies.length) {
mc = getCellMovie(cell, cell_movies[i]);
if (mc != null){
mc_array.push(mc);
};
i = (i + 1);
};
all_movies.push(mc_array);
};
};
next_ind = (all_movies.length - 1);
is_hide = true;
};
};
};
}
protected function stoneAwayListener(_arg1:Event):void{
var _local2:MovieClip;
var _local3:Cell;
_local2 = (_arg1.target as MovieClip);
if (((((!((_local2.parent == null))) && ((_local2.currentFrame >= (_local2.totalFrames - 1))))) && (!((_local2["parent_cell"] == null))))){
_local3 = _local2["parent_cell"];
_local3.removeMovie(_local2);
_local2.removeEventListener(Event.ENTER_FRAME, stoneAwayListener);
};
}
protected function getBlock(_arg1:Cell, _arg2:Array):Array{
var _local3:Array;
for each (_local3 in _arg2) {
if (_local3.indexOf(_arg1) >= 0){
return (_local3);
};
};
return (null);
}
protected function addFigureListeners(_arg1:Figure):void{
_arg1.addEventListener(MouseEvent.ROLL_OVER, cellRollOverListener);
_arg1.addEventListener(MouseEvent.ROLL_OUT, cellRollOutListener);
_arg1.addEventListener(MouseEvent.CLICK, figureClickListener);
_arg1.getMovie("away").addEventListener(Event.ENTER_FRAME, figureAwayListener);
}
protected function createClockBonus(_arg1:Cell):void{
var _local2:MovieClip;
var _local3:int;
if (_arg1 != null){
_local2 = new Amount_Time();
_local3 = Settings.getInstance().getIntProperty("clock", "100");
_local2.amount.text = ((("+" + _local3) + " ") + StringTable.getInstance().getString("clock_unit"));
GameState.getInstance().addTime(_local3);
addChild(_local2);
_local2.x = getCellX(_arg1.col);
_local2.y = getCellX(_arg1.row);
_local2.addEventListener(Event.ENTER_FRAME, removeFromFieldAfterEndListener, false, 0, true);
};
}
public function load(_arg1:LevelInfo):void{
var i:int;
var temp_button:SimpleButton;
var lev_info = _arg1;
try {
DEF_CELL_VEL = Settings.getInstance().getNumberProperty("figure_velocity", "7.0");
cell_size = Settings.getInstance().getIntProperty("cell_size", "40");
dynamite_num_combo = Settings.getInstance().getIntProperty("dynamite_combo", "6");
lightning_num_cells = Settings.getInstance().getIntProperty("lightning_cells", "7");
num_random_cells = Settings.getInstance().getIntProperty("random_cell", "10");
move_timer = new Timer(Settings.getInstance().getNumberProperty("hintTimer_interval", "5000"), 1);
vel_alpha = Settings.getInstance().getNumberProperty("showAlpha_velosity", "0.1");
numShowMovie_inFrame = Settings.getInstance().getIntProperty("numberCells_perFrame", "3");
row_count = lev_info.row_count;
col_count = lev_info.col_count;
cells = new Array();
i = 0;
while (i < (row_count * col_count)) {
cells.push(new Cell((i / col_count), (i % col_count), cell_size, cell_size));
i = (i + 1);
};
num_figures = lev_info.num_figures;
black_part = lev_info.black_part;
i = 0;
while (i < cells.length) {
cells[i].cell_type = lev_info.map[i];
i = (i + 1);
};
available_bonus = lev_info.available_bonus;
GameState.getInstance().setBack(lev_info.back);
generateField();
initField();
initShowField();
placeCells();
blocks = findBlocksToMix();
random_timer.addEventListener(TimerEvent.TIMER_COMPLETE, onRandomTimerComplete, false, 0, true);
move_timer.addEventListener(TimerEvent.TIMER_COMPLETE, onMoveTimerComplete, false, 0, true);
is_stop = false;
StateManager.getInstance().fx_soundManager.playSound("BeginLevel_Fx");
temp_button = new TempButton2();
temp_button.x = 100;
temp_button.y = 500;
temp_button.addEventListener(MouseEvent.MOUSE_DOWN, onEndLevel);
temp_button = new TempButton();
temp_button.x = 450;
temp_button.y = 450;
temp_button.addEventListener(MouseEvent.CLICK, function (_arg1:MouseEvent):void{
var _local2:Cell;
var _local3:Point;
if (((((((!(is_stop)) && (!(is_moved)))) && (!(is_show)))) && (!(is_hide)))){
mixFigures(blocks);
};
_local2 = cells[Random.randomInt(cells.length)];
_local3 = new Point((getCellX(_local2.col) + x), (getCellY(_local2.row) + y));
});
} catch(e:Error) {
trace(("Error load GameField." + e.getStackTrace()));
};
}
protected function findMinCol(_arg1:Array):int{
var _local2:int;
var _local3:Cell;
_local2 = _arg1[0].col;
for each (_local3 in _arg1) {
if (_local3.col < _local2){
_local2 = _local3.col;
};
};
return (_local2);
}
protected function findVertLineMatch(_arg1:Cell, _arg2:Array):Array{
var _local3:int;
var _local4:int;
var _local5:int;
var _local6:Array;
var _local7:Array;
var _local8:int;
var _local9:int;
var _local10:Cell;
if ((((((_arg1 == null)) || ((_arg1.cell_type == 0)))) || ((_arg1.getFigure() == null)))){
return (null);
};
_local3 = _arg1.row;
_local4 = _arg1.col;
_local5 = _arg1.getFigure().value;
if (_local5 == BLACK_FIGURE){
return (null);
};
_local6 = new Array();
_local7 = [-1, 1];
_local6.push(_arg1);
for each (_local8 in _local7) {
_local9 = 1;
while (_local9 < 8) {
if (((!((_arg2 == null))) && ((_arg2.indexOf(_local10) >= 0)))){
break;
};
_local10 = getCell((_local3 + (_local8 * _local9)), _local4);
if (((((!((_local10 == null))) && (!((_local10.getFigure() == null))))) && ((_local10.getFigure().value == _local5)))){
_local6.push(_local10);
} else {
break;
};
_local9++;
};
};
if (_local6.length >= 3){
return (_local6);
};
return (null);
}
protected function mouseMoveListener(_arg1:MouseEvent):void{
var _local2:Figure;
if (((!((drag_figure == null))) && (_arg1.buttonDown))){
if (((((((!(is_moved)) && (!(is_show)))) && (!(is_hide)))) && (!(is_stop)))){
if (drag_figure.getCurTypeMovie("figure_type") != drag_figure.getMovie("figure")){
drag_figure.setCurTypeMovieByName("figure_type", "figure");
};
_local2 = getFigureUnder((_arg1.stageX - x), (_arg1.stageY - y));
if (((((((((!((_local2 == drag_figure))) && (!((_local2 == null))))) && (!((drag_figure == null))))) && ((_local2.getParent().getChain() == null)))) && (!((drag_figure.getParent().getNeighbourType(_local2.getParent()) == "none"))))){
StateManager.getInstance().fx_soundManager.playSound("Select_Fx");
swapFigures(drag_figure.getParent(), _local2.getParent());
moved_fg_1 = drag_figure;
moved_fg_2 = _local2;
if (selected_figure != null){
selected_figure.setCurTypeMovieByName("figure_type", "figure");
selected_figure = null;
};
if (_local2.getCurTypeMovie("figure_type") != _local2.getMovie("figure")){
_local2.setCurTypeMovieByName("figure_type", "figure");
};
resetDynamiteComboCount();
combo_count = 0;
drag_figure = null;
is_drag = true;
};
} else {
drag_figure = null;
};
};
}
protected function findMaxRow(_arg1:Array):int{
var _local2:int;
var _local3:Cell;
_local2 = _arg1[0].row;
for each (_local3 in _arg1) {
if (_local3.row > _local2){
_local2 = _local3.row;
};
};
return (_local2);
}
protected function canGenerateCellNow(_arg1:Cell):Boolean{
if (((canGenerateCell(_arg1)) && (!(containsAnyFigure(_arg1, ((-3 * cell_size) / 4), 0, ((-3 * cell_size) / 4)))))){
return (true);
};
return (false);
}
protected function selectFigure(_arg1:Figure):void{
if (_arg1.getCurTypeMovie("figure_type") == _arg1.getMovie("away")){
return;
};
if (selected_figure == null){
_arg1.setCurTypeMovieByName("figure_type", "choose");
selected_figure = _arg1;
StateManager.getInstance().fx_soundManager.playSound("Select_Fx");
} else {
selected_figure.setCurTypeMovieByName("figure_type", "figure");
if (selected_figure == _arg1){
selected_figure = null;
} else {
StateManager.getInstance().fx_soundManager.playSound("Select_Fx");
switch (_arg1.getParent().getNeighbourType(selected_figure.getParent())){
case "vertical":
case "horizontal":
swapFigures(_arg1.getParent(), selected_figure.getParent());
moved_fg_1 = _arg1;
moved_fg_2 = selected_figure;
selected_figure = null;
_arg1.setCurTypeMovieByName("figure_type", "figure");
break;
case "none":
_arg1.setCurTypeMovieByName("figure_type", "choose");
selected_figure = _arg1;
break;
};
};
};
}
protected function showComboCount(_arg1:int):void{
var _local2:int;
if (_arg1 > 1){
if (((!((combo_mc == null))) && (contains(combo_mc)))){
removeChild(combo_mc);
combo_mc.stop();
combo_mc.removeEventListener(Event.ENTER_FRAME, removeFromFieldAfterEndListener);
};
_local2 = ((_arg1 > 7)) ? 7 : _arg1;
StateManager.getInstance().fx_soundManager.playSound(("burst" + _local2));
combo_mc = new Show_Combo();
combo_mc.combo.combo.text = ("combo x" + _arg1);
addChild(combo_mc);
combo_mc.x = ((width / 2) - (combo_mc.width / 4));
combo_mc.y = ((height / 2) - (combo_mc.height / 4));
combo_mc.addEventListener(Event.ENTER_FRAME, removeFromFieldAfterEndListener, false, 0, true);
};
}
protected function placeCell(_arg1:Cell):void{
_arg1.x = getCellX(_arg1.col);
_arg1.y = getCellY(_arg1.row);
if (_arg1.getFigure() != null){
_arg1.getFigure().x = getCellX(_arg1.col);
_arg1.getFigure().y = getCellY(_arg1.row);
};
if (_arg1.getChain() != null){
_arg1.getChain().x = getCellX(_arg1.col);
_arg1.getChain().y = getCellY(_arg1.row);
};
}
private function swapFigures(_arg1:Cell, _arg2:Cell):void{
var _local3:Figure;
_local3 = _arg1.getFigure();
_arg1.setFigure(_arg2.getFigure());
_arg2.setFigure(_local3);
}
protected function isOverNullCell(_arg1:Cell):Boolean{
var _local2:int;
var _local3:Cell;
_local2 = (_arg1.row - 1);
while (_local2 >= 0) {
_local3 = getCell(_local2, _arg1.col);
if (((!((_local3 == null))) && ((_local3.cell_type == 0)))){
return (true);
};
_local2--;
};
return (false);
}
protected function chainClickListener(_arg1:MouseEvent):void{
if (move_timer.running){
move_timer.stop();
};
}
protected function chainAwayListener(_arg1:Event):void{
var _local2:MovieClip;
var _local3:Zep;
_local2 = (_arg1.target as MovieClip);
if (((((!((_local2.parent == null))) && ((_local2.currentFrame >= (_local2.totalFrames - 1))))) && (!((_local2["parent_cell"] == null))))){
_local3 = _local2["parent_cell"];
_local3.removeMovie(_local2);
_local2.removeEventListener(Event.ENTER_FRAME, chainAwayListener);
if (_local2 == _local3.getMovie("chain_away")){
removeChild(_local3.getMainMovie());
};
};
}
protected function onHintAnimation(_arg1:Event):void{
var _local2:MovieClip;
_local2 = MovieClip(_arg1.target);
if (_local2.currentFrame == (_local2.totalFrames - 1)){
if (_local2["loop_count"] == null){
_local2["loop_count"] = 1;
} else {
if (_local2["loop_count"] == 10){
onClickHintAnimation(null);
} else {
var _local3 = _local2;
var _local4 = "loop_count";
var _local5 = (_local3[_local4] + 1);
_local3[_local4] = _local5;
};
};
};
}
protected function findMove(_arg1:Array, _arg2:int=0):Array{
var move_cells:Array;
var get_cell_fnc:Array;
var i:int;
var cell:Cell;
var cell_fnc:Function;
var tmp_cell:Cell;
var cells = _arg1;
var offset = _arg2;
move_cells = new Array();
get_cell_fnc = [function (_arg1:int, _arg2:int):Cell{
return (getCell((_arg1 - 1), _arg2));
}, function (_arg1:int, _arg2:int):Cell{
return (getCell(_arg1, (_arg2 - 1)));
}, function (_arg1:int, _arg2:int):Cell{
return (getCell((_arg1 + 1), _arg2));
}, function (_arg1:int, _arg2:int):Cell{
return (getCell(_arg1, (_arg2 + 1)));
}];
i = offset;
while (i < cells.length) {
cell = cells[i];
if (((!((cell.getFigure() == null))) && ((((((cell.cell_type == 1)) || ((cell.cell_type == 2)))) || ((cell.cell_type == 3)))))){
for each (cell_fnc in get_cell_fnc) {
tmp_cell = cell_fnc(cell.row, cell.col);
if (tmp_cell != null){
if (((((((!((tmp_cell.getFigure() == null))) && ((tmp_cell.cell_type == 1)))) || ((tmp_cell.cell_type == 2)))) || ((tmp_cell.cell_type == 3)))){
swapFigures(cell, tmp_cell);
if (((!((findHorzLineMatch(cell, null) == null))) || (findVertLineMatch(cell, null)))){
swapFigures(cell, tmp_cell);
move_cells.push(cell, tmp_cell);
return (move_cells);
};
swapFigures(cell, tmp_cell);
};
};
};
};
i = (i + 1);
};
return (null);
}
protected function checkBelowMatchWithBonus(_arg1:Cell):Boolean{
var _local2:Array;
var _local3:Boolean;
var _local4:int;
var _local5:Cell;
_local2 = new Array();
_local2.push(_arg1);
_local3 = !((_arg1.getFigure().bonus == null));
_local4 = 1;
while (_local4 < row_count) {
_local5 = getCell((_arg1.row + _local4), _arg1.col);
if ((((_local5 == null)) || ((_local5.cell_type == 0)))){
return (false);
};
if (_local5.getFigure() == null){
} else {
if (_local5.getFigure().value != _arg1.getFigure().value){
return (false);
};
if (_local5.getFigure().bonus != null){
_local3 = true;
};
_local2.push(_local5);
};
_local4++;
};
if ((((_local2.length >= 3)) && (_local3))){
trace("!!! below exist match with bonus");
return (true);
};
return (false);
}
protected function mouseUpListener(_arg1:MouseEvent):void{
drag_figure = null;
}
protected function onMoveTimerComplete(_arg1:Event):void{
var blocks_withoutMove:Array;
var block:Array;
var move_cells:Array;
var min_row:int;
var min_col:int;
var cell:Cell;
var e = _arg1;
move_timer.stop();
blocks_withoutMove = new Array();
for each (block in blocks) {
if (findMove(block) == null){
blocks_withoutMove.push(block);
};
};
if (blocks_withoutMove.length > 0){
trace("not more moves");
stopField();
GameState.getInstance().stopTimer();
StateManager.getInstance().pushState(new MessageState(StringTable.getInstance().getString("no_moves"), function (){
mixFigures(blocks_withoutMove);
GameState.getInstance().startTimer();
startField();
}));
return;
};
move_cells = null;
while (move_cells == null) {
move_cells = findMove(cells, Random.randomInt(cells.length));
};
min_row = findMinRow(move_cells);
min_col = findMinCol(move_cells);
if (move_anm != null){
onClickHintAnimation(null);
};
if (getMoveType(move_cells[0], move_cells[1]) == "horizontal"){
move_anm = new HorizontalMove();
} else {
move_anm = new VerticalMove();
};
addChild(move_anm);
cell = getCell(min_row, min_col);
move_anm.x = (getCellX(cell.col) - (cell_size / 2));
move_anm.y = (getCellY(cell.row) - (cell_size / 2));
move_anm.addEventListener(Event.ENTER_FRAME, onHintAnimation, false, 0, true);
move_anm.addEventListener(MouseEvent.MOUSE_DOWN, onClickHintAnimation, false, 0, true);
}
protected function getFigureUnder(_arg1:Number, _arg2:Number, _arg3:Figure=null):Figure{
var _local4:Cell;
for each (_local4 in cells) {
if ((((((_local4.cell_type > 0)) && (!((_local4.getFigure() == null))))) && (!((_local4.getFigure() == _arg3))))){
if (_local4.getFigure().getMainMovie().getBounds(this).contains(_arg1, _arg2)){
return (_local4.getFigure());
};
};
};
return (null);
}
protected function calculateField():void{
var _local1:Cell;
var _local2:Figure;
var _local3:Boolean;
var _local4:Array;
var _local5:Function;
var _local6:Array;
var _local7:int;
var _local8:Cell;
_local3 = false;
while (!(_local3)) {
_local3 = true;
_local4 = [findNoneLineMatch, findHorzLineMatch, findVertLineMatch];
for each (_local1 in cells) {
for each (_local5 in _local4) {
_local6 = _local5(_local1, null);
if (_local6 != null){
_local7 = 0;
while (_local7 < _local6.length) {
if ((_local6[_local7] is Cell)){
_local6[_local7].setFigure(null);
};
_local7++;
};
_local3 = false;
};
};
};
for each (_local1 in cells) {
if (((!((_local1.getFigure() == null))) && ((((((_local1.cell_type == 1)) || ((_local1.cell_type == 2)))) || ((_local1.cell_type == 3)))))){
_local8 = getCell((_local1.row + 1), _local1.col);
if (_local8 != null){
if ((((_local8.cell_type > 0)) && ((_local8.getFigure() == null)))){
_local1.getFigure().is_move = true;
swapFigures(_local1, _local8);
_local3 = false;
};
};
};
};
for each (_local1 in cells) {
if (((!((_local1.getFigure() == null))) && ((((((_local1.cell_type == 1)) || ((_local1.cell_type == 2)))) || ((_local1.cell_type == 3)))))){
if (needLeftCell(_local1)){
_local1.getFigure().is_move = true;
swapFigures(_local1, getCell((_local1.row + 1), (_local1.col - 1)));
} else {
if (needRightCell(_local1)){
_local1.getFigure().is_move = true;
swapFigures(_local1, getCell((_local1.row + 1), (_local1.col + 1)));
continue;
};
};
};
};
for each (_local1 in cells) {
if (_local1.cell_type != 0){
if (canGenerateCellNow(_local1)){
_local1.setFigure(new Figure());
generateRandomFigure(_local1.getFigure(), false);
_local3 = false;
};
};
};
};
}
protected function onRandomTimerComplete(_arg1:Event):void{
var _local2:Cell;
var _local3:Array;
_local3 = new Array();
for each (_local2 in cells) {
if (((((((((!((_local2 == null))) && (!((_local2.getFigure() == null))))) && ((((((_local2.cell_type == 2)) || ((_local2.cell_type == 3)))) || ((((_local2.cell_type >= 6)) && ((_local2.cell_type <= 9)))))))) && (!(_local2.getFigure().isMoving())))) && ((_local2.getFigure().bonus == null)))){
if (_local2.getFigure().getCurTypeMovie("figure_type") == _local2.getFigure().getMovie("figure")){
_local2.getFigure().getMovie("random").addEventListener(Event.ENTER_FRAME, onEndRandomAnimation, false, 0, true);
_local2.getFigure().setCurTypeMovieByName("figure_type", "random");
};
};
};
}
protected function findMinRow(_arg1:Array):int{
var _local2:int;
var _local3:Cell;
_local2 = _arg1[0].row;
for each (_local3 in _arg1) {
if (_local3.row < _local2){
_local2 = _local3.row;
};
};
return (_local2);
}
public function reset():void{
var _local1:Cell;
while (numChildren > 0) {
removeChildAt(0);
};
available_bonus = null;
selected_figure = null;
moved_fg_1 = null;
moved_fg_2 = null;
is_moved = false;
is_stop = true;
bonus_create = new Array();
combo_count = 0;
combo_mc = null;
dynamite_combo_count = 0;
dynamite_combo_cell = null;
dynamite_combo_type = 0;
drag_figure = null;
is_drag = false;
lightning_count = 0;
random_timer.stop();
move_timer.stop();
move_anm = null;
cur_showCell_ind = 0;
is_show = false;
is_hide = false;
next_ind = 0;
all_movies = null;
blocks = null;
is_check_viewFirstTime = false;
level_points = 0;
}
protected function getNumStones():int{
var _local1:int;
var _local2:Cell;
_local1 = 0;
for each (_local2 in cells) {
if ((((((((((((_local2.cell_type == 2)) || ((_local2.cell_type == 3)))) || ((_local2.cell_type == 6)))) || ((_local2.cell_type == 7)))) || ((_local2.cell_type == 8)))) || ((_local2.cell_type == 9)))){
_local1++;
};
};
return (_local1);
}
protected function createDynamiteBonus(_arg1:Cell, _arg2:int, _arg3:String):void{
var _local4:int;
var _local5:int;
var _local6:Cell;
var _local7:MovieClip;
var _local8:Array;
_local4 = (_arg2 / 2);
_local5 = -(_local4);
while (_local5 <= _local4) {
_local6 = getCell(_arg1.row, (_arg1.col + _local5));
if (((!((_local6 == null))) && ((_local6.cell_type > 0)))){
_local8 = awayCell(_local6);
if (((!((_local8 == null))) && ((_local8.length == 2)))){
var _local9 = _local8;
_local9[0](_local8[1]);
};
_local7 = LibraryMovies.getMovieFromLibrary(_arg3);
addChild(_local7);
_local7.x = getCellX(_local6.col);
_local7.y = getCellY(_local6.row);
_local7.addEventListener(Event.ENTER_FRAME, removeFromFieldAfterEndListener, false, 0, true);
};
_local5++;
};
_local5 = -(_local4);
while (_local5 <= _local4) {
if (_local5 == 0){
} else {
_local6 = getCell((_arg1.row + _local5), _arg1.col);
if (((!((_local6 == null))) && ((_local6.cell_type > 0)))){
_local8 = awayCell(_local6);
if (((!((_local8 == null))) && ((_local8.length == 2)))){
_local9 = _local8;
_local9[0](_local8[1]);
};
_local7 = LibraryMovies.getMovieFromLibrary(_arg3);
addChild(_local7);
_local7.x = getCellX(_local6.col);
_local7.y = getCellY(_local6.row);
_local7.addEventListener(Event.ENTER_FRAME, removeFromFieldAfterEndListener, false, 0, true);
};
};
_local5++;
};
}
protected function decrementCellType(_arg1:Cell){
if (_arg1 != null){
switch (_arg1.cell_type){
case 2:
case 4:
_arg1.cell_type = 1;
break;
case 3:
case 6:
_arg1.cell_type = 2;
break;
case 5:
case 9:
case 7:
_arg1.cell_type--;
break;
case 8:
_arg1.cell_type = 3;
break;
};
};
}
protected function awayCell(_arg1:Cell, _arg2:int=0):Array{
var returned_bonus:Array;
var cur_fr:int;
var cell = _arg1;
var cell_point = _arg2;
returned_bonus = new Array();
if (((!((cell == null))) && (!((cell.getFigure() == null))))){
if (cell.getFigure().bonus != null){
switch (cell.getFigure().bonus){
case "bomb":
returned_bonus.push(function (_arg1:Cell):void{
trace("execute bonus: bomb");
createExplosionBonus(_arg1, 3, "Bomb_Animation");
StateManager.getInstance().fx_soundManager.playSound("Explosion_Fx");
});
returned_bonus.push(cell);
break;
case "dynamite":
returned_bonus.push(function (_arg1:Cell):void{
trace("execute bonus: dynamite");
createDynamiteBonus(_arg1, 5, "Dynamite_Animation");
StateManager.getInstance().fx_soundManager.playSound("Explosion_Fx");
});
returned_bonus.push(cell);
break;
case "clock":
returned_bonus.push(function (_arg1:Cell):void{
trace("execute bonus: clock");
createClockBonus(_arg1);
});
returned_bonus.push(cell);
break;
case "lightning":
returned_bonus.push(function (_arg1:Cell):void{
trace("execute bonus: lightning");
initLightning(_arg1);
});
returned_bonus.push(cell);
break;
};
cell.getFigure().bonus = null;
};
};
if (cell != null){
switch (cell.cell_type){
case 1:
awayFigure(cell, cell_point);
break;
case 2:
cell.setCurTypeMovieByName("stone_type", "stone_away");
awayFigure(cell, cell_point);
break;
case 3:
cell.setCurTypeMovieByName("stone2_type", "stone2_away");
cur_fr = getStoneMovieCurrentFrame();
cell.setCurTypeMovieByName("stone_type", "stone").gotoAndPlay(cur_fr);
awayFigure(cell, cell_point);
break;
case 4:
cell.getChain().setCurTypeMovieByName("chain_type", "chain_away");
cell.setChain(null);
break;
case 5:
cell.getChain().setCurTypeMovieByName("chain2_type", "chain2_away");
cell.getChain().setCurTypeMovieByName("chain_type", "chain");
break;
case 6:
cell.getChain().setCurTypeMovieByName("chain_type", "chain_away");
cell.setChain(null);
break;
case 7:
cell.getChain().setCurTypeMovieByName("chain2_type", "chain2_away");
cell.getChain().setCurTypeMovieByName("chain_type", "chain");
break;
case 8:
cell.getChain().setCurTypeMovieByName("chain_type", "chain_away");
cell.setChain(null);
break;
case 9:
cell.getChain().setCurTypeMovieByName("chain2_type", "chain2_away");
cell.getChain().setCurTypeMovieByName("chain_type", "chain");
break;
};
decrementCellType(cell);
};
return (returned_bonus);
}
protected function awayFigure(_arg1:Cell, _arg2:int):void{
var _local3:MovieClip;
if (_arg1.getFigure() != null){
if (_arg2 > 0){
_local3 = new Cell_Point_Animation();
_local3.cell_point.points.text = ("" + _arg2);
addChild(_local3);
_local3.x = getCellX(_arg1.col);
_local3.y = getCellY(_arg1.row);
_local3.addEventListener(Event.ENTER_FRAME, removeFromFieldAfterEndListener, false, 0, true);
};
_arg1.getFigure().setCurTypeMovieByName("figure_type", "away");
_arg1.setFigure(null);
};
}
public function isGameCompleted():Boolean{
return ((getNumStones() == 0));
}
protected function addChainListeners(_arg1:Cell):void{
_arg1.getChain().addEventListener(MouseEvent.CLICK, chainClickListener);
if ((((((_arg1.cell_type == 4)) || ((_arg1.cell_type == 6)))) || ((_arg1.cell_type == 8)))){
_arg1.getChain().getMovie("chain_away").addEventListener(Event.ENTER_FRAME, chainAwayListener);
};
if ((((((_arg1.cell_type == 5)) || ((_arg1.cell_type == 7)))) || ((_arg1.cell_type == 9)))){
_arg1.getChain().getMovie("chain_away").addEventListener(Event.ENTER_FRAME, chainAwayListener);
_arg1.getChain().getMovie("chain2_away").addEventListener(Event.ENTER_FRAME, chainAwayListener);
};
}
protected function getCellY(_arg1:int):Number{
return (((_arg1 * cell_size) + (cell_size / 2)));
}
protected function getCellX(_arg1:int):Number{
return (((_arg1 * cell_size) + (cell_size / 2)));
}
protected function getNumBlackFigures():int{
var _local1:Cell;
var _local2:int;
_local2 = 0;
for each (_local1 in cells) {
if (((!((_local1.getFigure() == null))) && ((_local1.getFigure().value == BLACK_FIGURE)))){
_local2++;
};
};
return (_local2);
}
protected function initLightning(_arg1:Cell):void{
var _local2:Array;
var _local3:int;
var _local4:int;
var _local5:int;
var _local6:Cell;
is_stop = true;
lightning_count++;
_local2 = new Array();
_local3 = getNumFigures();
_local4 = ((lightning_num_cells <= _local3)) ? lightning_num_cells : _local3;
_local5 = 0;
while (_local5 < _local4) {
_local6 = cells[Random.randomInt(cells.length)];
while ((((((((_local6.cell_type == 0)) || ((_local6.getFigure() == null)))) || ((_local2.indexOf(_local6) >= 0)))) || ((_arg1 == _local6)))) {
_local6 = cells[Random.randomInt(cells.length)];
};
_local2.push(_local6);
_local5++;
};
addChild(new LightningData(_local2, new Point(getCellX(_arg1.col), getCellY(_arg1.row)), this, onEndLightning, awayCell));
StateManager.getInstance().fx_soundManager.playSound("Lightning_Fx");
}
protected function generateRandomFigure(_arg1:Figure, _arg2:Boolean=true):void{
var _local3:Array;
var _local4:Array;
_arg1.value = Random.randomInt(num_figures);
if (_arg2){
_local3 = findHorzLineMatch(_arg1.getParent(), null);
_local4 = findVertLineMatch(_arg1.getParent(), null);
while (((!((_local3 == null))) || (!((_local4 == null))))) {
_arg1.value = Random.randomInt(num_figures);
_local3 = findHorzLineMatch(_arg1.getParent(), null);
_local4 = findVertLineMatch(_arg1.getParent(), null);
};
};
}
protected function getNumFigures():int{
var _local1:int;
var _local2:Cell;
_local1 = 0;
for each (_local2 in cells) {
if (_local2.getFigure() != null){
_local1++;
};
};
return (_local1);
}
protected function getFigureMoviePrefix(_arg1:String):String{
switch (_arg1){
case "bomb":
return ("Bomb");
case "clock":
return ("Clock");
case "lightning":
return ("Lightning");
case "dynamite":
return ("Dynamite");
default:
return ("Figura");
};
}
protected function cellRollOutListener(_arg1:MouseEvent):void{
var _local2:Figure;
var _local3:MovieClip;
if (drag_figure == null){
_local2 = _arg1.target.parent_cell;
_local3 = _local2.getCurTypeMovie("figure_type");
if (_local3 == _local2.getMovie("rollover")){
_local3.addEventListener(Event.ENTER_FRAME, onRollOverAnimationEnd, false, 0, true);
};
};
}
protected function needRightCell(_arg1:Cell):Boolean{
var _local2:Cell;
var _local3:Cell;
var _local4:Cell;
var _local5:Cell;
if ((((_arg1.row < (row_count - 1))) && ((_arg1.col < (col_count - 1))))){
_local2 = getCell(_arg1.row, (_arg1.col + 1));
_local3 = getCell((_arg1.row - 1), _arg1.col);
_local4 = getCell((_arg1.row - 1), (_arg1.col + 1));
_local5 = getCell((_arg1.row + 1), (_arg1.col + 1));
if (((((!((_local2 == null))) && ((_local2.cell_type > 0)))) && (((((!((_local2.getFigure() == null))) && ((_local2.getChain() == null)))) || (canGenerateCellNow(_local2)))))){
return (false);
};
if ((((_local5.getFigure() == null)) && ((_local5.cell_type > 0)))){
if (_local2 != null){
if ((((_local2.cell_type > 0)) && ((_local2.getFigure() == null)))){
if (_arg1.getFigure().is_move){
return (true);
};
if (_local3 != null){
if (((!(canGenerateCellOver(_arg1))) && (!(canGenerateCellOver(_local2))))){
return (true);
};
};
};
if ((((_local2.cell_type == 0)) || (!((_local2.getChain() == null))))){
return (true);
};
};
};
};
return (false);
}
protected function startMoveTimer():void{
if (move_timer.running){
move_timer.stop();
};
move_timer.delay = Settings.getInstance().getNumberProperty("hintTimer_interval", "5000");
move_timer.repeatCount = 1;
move_timer.start();
}
protected function isChain(_arg1:int):Boolean{
return ((_arg1 >= 4));
}
protected function onEndLightning():void{
lightning_count--;
if (lightning_count <= 0){
is_stop = false;
};
}
protected function resetDynamiteComboCount():void{
dynamite_combo_cell = null;
dynamite_combo_count = 0;
}
protected function initField():void{
var _local1:int;
var _local2:Cell;
_local1 = 0;
while (_local1 < cells.length) {
_local2 = cells[_local1];
if (((!((_local2.getFigure() == null))) && ((_local2.getFigure().value >= -1)))){
initFigure(_local2.getFigure());
};
_local1++;
};
_local1 = 0;
while (_local1 < cells.length) {
if (cells[_local1].cell_type > 0){
addCellDefaultMovies(cells[_local1]);
addCellListeners(cells[_local1]);
};
addChild(cells[_local1].getMainMovie());
_local1++;
};
_local1 = 0;
while (_local1 < cells.length) {
if ((((cells[_local1].cell_type > 0)) && (!((cells[_local1].getFigure() == null))))){
addChild(cells[_local1].getFigure().getMainMovie());
};
_local1++;
};
_local1 = 0;
while (_local1 < cells.length) {
if (cells[_local1].getChain() != null){
addChainDefaultMovies(cells[_local1]);
addChainListeners(cells[_local1]);
addChild(cells[_local1].getChain().getMainMovie());
};
_local1++;
};
}
public function startField():void{
is_stop = false;
move_timer.start();
random_timer.start();
}
protected function findNearEmptyCell(_arg1:Cell):Cell{
var _local2:int;
var _local3:int;
var _local4:int;
var _local5:Cell;
if (_arg1 != null){
_local2 = 1;
while (_local2 < col_count) {
_local3 = -(_local2);
while (_local3 <= _local2) {
_local4 = -(_local2);
while (_local4 <= _local2) {
_local5 = getCell((_arg1.row + _local3), (_arg1.col + _local4));
if (((((!((_local5 == null))) && (!((_local5.cell_type == 0))))) && ((_local5.getFigure() == null)))){
trace("!!!return Non-null near empty cell");
return (_local5);
};
_local4++;
};
_local3++;
};
_local2++;
};
};
trace("!!!return null near empty cell");
return (null);
}
protected function isFigureOnPlace(_arg1:Cell):Boolean{
var _local2:Figure;
_local2 = _arg1.getFigure();
if (_local2 != null){
return ((((Math.abs((_local2.x - _arg1.x)) < DEF_CELL_VEL)) && ((Math.abs((_local2.y - _arg1.y)) < DEF_CELL_VEL))));
};
return (false);
}
protected function canGenerateCellOver(_arg1:Cell):Boolean{
var _local2:int;
var _local3:Cell;
_local2 = (_arg1.row - 1);
while (_local2 >= 0) {
_local3 = getCell(_local2, _arg1.col);
if (_local3 != null){
if ((((_local3.cell_type == 0)) || (!((_local3.getChain() == null))))){
return (false);
};
if (((canGenerateCell(_local3)) || (!((_local3.getFigure() == null))))){
return (true);
};
};
_local2--;
};
return (false);
}
protected function onEndRandomAnimation(_arg1:Event):void{
var _local2:MovieClip;
var _local3:Figure;
_local2 = (_arg1.target as MovieClip);
if (_local2.currentFrame >= (_local2.totalFrames - 1)){
_local3 = _local2["parent_cell"];
if (_local3.getCurTypeMovie("figure_type") == _local3.getMovie("random")){
_local3.setCurTypeMovieByName("figure_type", "figure");
};
_local2.removeEventListener(Event.ENTER_FRAME, onEndRandomAnimation);
};
}
protected function getStoneMovieCurrentFrame():int{
var _local1:Cell;
var _local2:MovieClip;
for each (_local1 in cells) {
_local2 = _local1.getCurTypeMovie("stone_type");
if (((!((_local2 == null))) && ((_local2 == _local1.getMovie("stone"))))){
return (_local2.currentFrame);
};
};
return (0);
}
protected function canCreateLeftOrRightCell(_arg1:Cell):Boolean{
var _local2:Cell;
var _local3:Cell;
_local2 = getCell((_arg1.row - 1), (_arg1.col - 1));
_local3 = getCell((_arg1.row - 1), (_arg1.col + 1));
if (((!((_local2 == null))) && ((_local2.cell_type > 0)))){
return (true);
};
if (((!((_local3 == null))) && ((_local3.cell_type > 0)))){
return (true);
};
return (false);
}
protected function figureClickListener(_arg1:MouseEvent):void{
var _local2:Cell;
var _local3:Figure;
if (is_show){
for each (_local2 in cells) {
if (_local2.cell_type > 0){
setAllCellMovieAlpha(_local2, 1);
};
};
is_show = false;
GameState.getInstance().startTimer();
return;
};
if (move_timer.running){
move_timer.stop();
};
if (((((((((!(is_moved)) && (!(is_show)))) && (!(is_hide)))) && (!(is_stop)))) && (!(is_drag)))){
trace(("click\ttraget = " + _arg1.target));
_local3 = _arg1.target.parent_cell;
resetDynamiteComboCount();
combo_count = 0;
selectFigure(_local3);
};
}
protected function getCell(_arg1:int, _arg2:int):Cell{
if ((((((((_arg1 >= 0)) && ((_arg1 < row_count)))) && ((_arg2 >= 0)))) && ((_arg2 < col_count)))){
return (cells[((_arg1 * col_count) + _arg2)]);
};
return (null);
}
public static function getInstance():GameField{
if (instance == null){
instance = new GameField(new EnforceSingletone());
};
return (instance);
}
}
}//package Game
class EnforceSingletone {
private function EnforceSingletone(){
}
}
Section 17
//LightningData (Game.LightningData)
package Game {
import flash.events.*;
import flash.display.*;
import flash.geom.*;
public class LightningData extends MovieClip {
var origin:Point;
var endLightning:Function;
var lightning_origin:MovieClip;
var lightning_queue:Array;
var deleteFigure:Function;
var scene:MovieClip;
var last_index:int;// = 0
public function LightningData(_arg1:Array, _arg2:Point, _arg3:MovieClip, _arg4:Function, _arg5:Function){
lightning_queue = new Array();
last_index = 0;
super();
lightning_queue = _arg1;
this.endLightning = _arg4;
this.deleteFigure = _arg5;
this.scene = _arg3;
lightning_origin = new Core_Lightning();
_arg3.addChild(lightning_origin);
this.origin = _arg2;
lightning_origin.x = _arg2.x;
lightning_origin.y = _arg2.y;
addEventListener(Event.ENTER_FRAME, update);
}
private function distance(_arg1:Point, _arg2:Point):Number{
return (Math.sqrt((((_arg1.x - _arg2.x) * (_arg1.x - _arg2.x)) + ((_arg1.y - _arg2.y) * (_arg1.y - _arg2.y)))));
}
private function removeLightningDataFromScene():void{
scene.removeChild(lightning_origin);
scene.removeChild(this);
scene = null;
endLightning();
removeEventListener(Event.ENTER_FRAME, update);
}
private function onEndOneLightning(_arg1:Event):void{
var _local2:MovieClip;
var _local3:Array;
_local2 = (_arg1.target as MovieClip);
if ((((_local2.currentFrame >= (_local2.totalFrames - 1))) && (scene.contains(_local2)))){
_local2.removeEventListener(Event.ENTER_FRAME, onEndOneLightning);
scene.removeChild(_local2);
scene.removeChild(_local2["core_lightning"]);
_local3 = deleteFigure(_local2["cell"]);
if (((!((_local3 == null))) && ((_local3.length == 2)))){
var _local4 = _local3;
_local4[0](_local3[1]);
};
if (_local2["lightning_ind"] <= last_index){
removeLightningDataFromScene();
};
};
}
private function update(_arg1:Event):void{
var _local2:Cell;
var _local3:Point;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:MovieClip;
var _local9:MovieClip;
if (lightning_queue.length > 0){
_local2 = lightning_queue.pop();
while ((((lightning_queue.length > 0)) && ((_local2.getFigure() == null)))) {
_local2 = lightning_queue.pop();
};
if ((((lightning_queue.length == 0)) && ((_local2.getFigure() == null)))){
return;
};
_local3 = new Point(_local2.x, _local2.y);
_local4 = distance(origin, _local3);
_local5 = ((_local3.x - origin.x) / _local4);
_local6 = (_local3.y - origin.y);
_local7 = ((180 * Math.acos(_local5)) / Math.PI);
if (_local6 < 0){
_local7 = -(_local7);
};
_local8 = new Lightning();
scene.addChild(_local8);
_local8.x = origin.x;
_local8.y = origin.y;
_local8.scaleX = (_local4 / _local8.width);
_local8.rotation = _local7;
_local8.addEventListener(Event.ENTER_FRAME, onEndOneLightning);
_local9 = new Core_Lightning();
scene.addChild(_local9);
_local9.x = _local3.x;
_local9.y = _local3.y;
_local8["core_lightning"] = _local9;
_local8["lightning_ind"] = lightning_queue.length;
_local8["cell"] = _local2;
last_index = lightning_queue.length;
};
}
}
}//package Game
Section 18
//Zep (Game.Zep)
package Game {
public class Zep extends BaseCell {
private var parent:Cell;
public function getParent():Cell{
return (parent);
}
public function setParent(_arg1:Cell):void{
this.parent = _arg1;
}
}
}//package Game
Section 19
//BaseMessageState (States.BaseMessageState)
package States {
import flash.display.*;
public class BaseMessageState extends ModalWindowState {
var message:String;// = "no message"
var callback:Function;
var window:MovieClip;
public function BaseMessageState(_arg1:String, _arg2:Function=null, _arg3:Number=0.3):void{
message = "no message";
super(_arg3);
this.message = _arg1;
this.callback = _arg2;
}
override public function onPreInit():void{
super.onPreInit();
window = getWindowMovie();
addChild(window);
}
override public function onInit():void{
super.onInit();
window.x = ((width - window.width) / 2);
window.y = ((height - window.height) / 2);
}
override public function onCleanup():void{
if (callback != null){
callback();
};
callback = null;
}
protected function getWindowMovie():MovieClip{
return (new MovieClip());
}
}
}//package States
Section 20
//GameCompleteWindowState (States.GameCompleteWindowState)
package States {
import Common.*;
import flash.events.*;
import flash.display.*;
import flash.net.*;
public class GameCompleteWindowState extends MessageState {
public function GameCompleteWindowState(_arg1:Function=null, _arg2:Number=0.3):void{
var _local3:String;
var _local4:String;
_local3 = "asdasdasd \n l;kl;sdkf;lk \r l;'sdflsdff";
_local4 = StringTable.getInstance().getString("gameComplete_message");
super(_local4, _arg1, _arg2);
}
protected function onDownloadClick(_arg1:MouseEvent):void{
var e = _arg1;
try {
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
navigateToURL(new URLRequest(Settings.getInstance().getProperty("download_link")), "_blank");
} catch(err:Error) {
trace(("Error->GameCompleteWindowState: navigateToUrl throw exception \n" + err.getStackTrace()));
};
}
override public function onPreInit():void{
super.onPreInit();
window.download.addEventListener(MouseEvent.CLICK, onDownloadClick);
}
override public function onInit():void{
super.onInit();
StateManager.getInstance().fx_soundManager.playSound("GameComplete_Fx");
}
override public function onCleanup():void{
window.download.removeEventListener(MouseEvent.CLICK, onDownloadClick);
super.onCleanup();
}
override protected function getWindowMovie():MovieClip{
return (new GameComplete_Window());
}
}
}//package States
Section 21
//GameMenuState (States.GameMenuState)
package States {
import Common.*;
import flash.events.*;
import flash.display.*;
import Game.*;
import flash.net.*;
public class GameMenuState extends ModalWindowState {
var window:MovieClip;
static var instance:GameMenuState = null;
public function GameMenuState(_arg1:EnforceSingletone){
}
protected function onReturnToGameClick(_arg1:MouseEvent):void{
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
GameField.getInstance().startField();
StateManager.getInstance().popState();
GameState.getInstance().startTimer();
}
protected function onAbortGameClick(_arg1:MouseEvent):void{
var message:String;
var e = _arg1;
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
message = StringTable.getInstance().getString("askConfirm_abortGame");
StateManager.getInstance().pushState(new YesNoWindowState(message, function (_arg1:Boolean):void{
if (_arg1){
GameField.getInstance().reset();
Profile.getInstance().resetProfile();
StateManager.getInstance().changeState(MainMenuState.getInstance());
};
}));
}
protected function onDownloadClick(_arg1:MouseEvent):void{
var e = _arg1;
try {
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
navigateToURL(new URLRequest(Settings.getInstance().getProperty("download_link")), "_blank");
} catch(err:Error) {
trace(("Error->GameMenuState: navigateToUrl throw exception \n" + err.getStackTrace()));
};
}
override public function onPreInit():void{
super.onPreInit();
window = new Menu_Window();
addChild(window);
window.return_to_game.addEventListener(MouseEvent.CLICK, onReturnToGameClick);
window.restart_level.addEventListener(MouseEvent.CLICK, onRestartLevelClick);
window.help.addEventListener(MouseEvent.CLICK, onHelpClick);
window.download.addEventListener(MouseEvent.CLICK, onDownloadClick);
window.abort_game.addEventListener(MouseEvent.CLICK, onAbortGameClick);
}
override public function onInit():void{
super.onInit();
window.x = ((width - window.width) / 2);
window.y = ((height - window.height) / 2);
}
protected function onHelpClick(_arg1:MouseEvent):void{
var e = _arg1;
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
HelpState.getInstance().setToNextState(function (){
StateManager.getInstance().popState();
});
StateManager.getInstance().pushState(HelpState.getInstance());
}
protected function onRestartLevelClick(_arg1:MouseEvent):void{
var message:String;
var e = _arg1;
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
message = StringTable.getInstance().getString("askConfirm_restartLevel");
StateManager.getInstance().pushState(new YesNoWindowState(message, function (_arg1:Boolean):void{
if (_arg1){
GameField.getInstance().reset();
StateManager.getInstance().changeState(GameState.getInstance());
};
}));
}
override public function onCleanup():void{
}
public static function getInstance():GameMenuState{
if (instance == null){
instance = new GameMenuState(new EnforceSingletone());
};
return (instance);
}
}
}//package States
class EnforceSingletone {
private function EnforceSingletone(){
}
}
Section 22
//GameState (States.GameState)
package States {
import Common.*;
import flash.events.*;
import flash.utils.*;
import flash.media.*;
import flash.display.*;
import Game.*;
import flash.geom.*;
import flash.net.*;
public class GameState extends State {
var sound_button_on:SimpleButton;
var sound_button_off:SimpleButton;
protected var music:SoundChannel;
var main_window:MovieClip;
var music_button_off:SimpleButton;
var timer:Timer;
var music_button_on:SimpleButton;
var runnigTime_fx:SoundChannel;
var time:int;// = 300
protected var is_fade_music:Boolean;// = false
var back:MovieClip;
static var instance:GameState = null;
public function GameState(_arg1:EnforceSingletone){
back = new MovieClip();
time = 300;
timer = new Timer(1000);
is_fade_music = false;
super();
}
public function loadNextLevel():void{
if (Profile.getInstance().getLevel() < (Settings.getInstance().getNumLevels() - 1)){
Profile.getInstance().incLevel();
loadCurrentLevel();
} else {
stopRunnigTime();
StateManager.getInstance().pushState(new GameCompleteWindowState(function (){
GameField.getInstance().reset();
Profile.getInstance().resetProfile();
StateManager.getInstance().changeState(MainMenuState.getInstance());
}));
};
}
public function addTime(_arg1:int):int{
this.time = (this.time + _arg1);
main_window.time.text = getTimeText(_arg1);
return (this.time);
}
function getTimeText(_arg1:int):String{
var _local2:String;
var _local3:int;
var _local4:int;
_local2 = "";
_local3 = (_arg1 / 60);
_local4 = (_arg1 % 60);
if (_local3 >= 10){
_local2 = (_local2 + _local3);
} else {
_local2 = (_local2 + ("0" + _local3));
};
_local2 = (_local2 + " : ");
if (_local4 >= 10){
_local2 = (_local2 + _local4);
} else {
_local2 = (_local2 + ("0" + _local4));
};
return (_local2);
}
function onMusicButtonDown(_arg1:MouseEvent):void{
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
if (_arg1.target == music_button_on){
music_button_off.x = _arg1.target.x;
music_button_off.y = _arg1.target.y;
main_window.removeChild(DisplayObject(_arg1.target));
main_window.addChild(music_button_off);
StateManager.getInstance().music_soundManager.setGlobalVolume(0);
} else {
if (_arg1.target == music_button_off){
music_button_on.x = _arg1.target.x;
music_button_on.y = _arg1.target.y;
main_window.removeChild(DisplayObject(_arg1.target));
main_window.addChild(music_button_on);
StateManager.getInstance().music_soundManager.setGlobalVolume(Settings.getInstance().getNumberProperty("volume", "0.7"));
};
};
}
public function startTimer():void{
if (!timer.running){
timer.start();
};
}
public function stopMusic():void{
if (music != null){
music.stop();
music = null;
};
}
public function getTime():int{
return (time);
}
public function fadeMusic():void{
is_fade_music = true;
}
public function stopTimer():void{
if (timer.running){
timer.stop();
};
stopRunnigTime();
}
public function playMusic():void{
if (music != null){
music.stop();
};
music = StateManager.getInstance().music_soundManager.playSound("Game_Music", -1);
}
public function setBack(_arg1:DisplayObject):void{
while (this.back.numChildren > 0) {
this.back.removeChildAt(0);
};
if (_arg1 != null){
this.back.addChild(_arg1);
if (_arg1.width == 0){
this.back.x = 0;
this.back.y = 0;
} else {
placeAtCenter(this.back);
};
};
}
public function playRunnigTime():void{
if (runnigTime_fx != null){
runnigTime_fx.stop();
};
runnigTime_fx = StateManager.getInstance().fx_soundManager.playSound("RunningTime_Fx", -1);
}
override public function onPreInit():void{
var temp_button:SimpleButton;
main_window = new MainWindow();
addChild(back);
addChild(main_window);
music_button_on = main_window.music_button;
music_button_off = new MusicButtonOff();
sound_button_on = main_window.sound_button;
sound_button_off = new SoundButtonOff();
music_button_off.addEventListener(MouseEvent.MOUSE_DOWN, onMusicButtonDown);
music_button_on.addEventListener(MouseEvent.MOUSE_DOWN, onMusicButtonDown);
sound_button_off.addEventListener(MouseEvent.MOUSE_DOWN, onSoundButtonDown);
sound_button_on.addEventListener(MouseEvent.MOUSE_DOWN, onSoundButtonDown);
main_window.menu_button.addEventListener(MouseEvent.MOUSE_DOWN, onMenuButtonDown);
main_window.more_games.addEventListener(MouseEvent.MOUSE_DOWN, onMoreGamesDown);
timer.addEventListener(TimerEvent.TIMER, onTimer);
addChild(GameField.getInstance());
addEventListener(Event.ENTER_FRAME, update);
if (Settings.getInstance().getBooleanProperty("debug")){
temp_button = new TempLeft();
addChild(temp_button);
temp_button.x = 0;
temp_button.y = 0;
temp_button.addEventListener(MouseEvent.CLICK, function (_arg1:MouseEvent):void{
if (Profile.getInstance().getLevel() > 0){
GameField.getInstance().reset();
Profile.getInstance().decLevel();
loadCurrentLevel();
};
});
temp_button = new TempRight();
addChild(temp_button);
temp_button.x = 533;
temp_button.y = 0;
temp_button.addEventListener(MouseEvent.CLICK, function (_arg1:MouseEvent):void{
if (Profile.getInstance().getLevel() < (Settings.getInstance().getNumLevels() - 1)){
GameField.getInstance().reset();
Profile.getInstance().incLevel();
loadCurrentLevel();
};
});
};
}
function setTime(){
time = Settings.getInstance().getCurLevel().time;
main_window.time.text = getTimeText(time);
}
public function loadCurrentLevel():void{
stopRunnigTime();
setTime();
main_window.level.text = (Profile.getInstance().getLevel() + 1);
GameField.getInstance().load(Settings.getInstance().getCurLevel());
}
function onMenuButtonDown(_arg1:MouseEvent):void{
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
stopTimer();
GameField.getInstance().stopField();
StateManager.getInstance().pushState(GameMenuState.getInstance());
}
override public function onInit():void{
GameField.getInstance().load(Settings.getInstance().getCurLevel());
placeAtCenter(main_window);
placeAtCenter(GameField.getInstance());
trace(("w = " + GameField.getInstance().width));
trace(("h = " + GameField.getInstance().height));
setTime();
main_window.level.text = (Profile.getInstance().getLevel() + 1);
main_window.score.text = Profile.getInstance().getScore();
playMusic();
}
function onTimer(_arg1:TimerEvent):void{
var message:String;
var target:Point;
var e = _arg1;
time--;
main_window.time.text = getTimeText(time);
if (((!(Profile.getInstance().isView_firstTime["half_time"])) && ((time <= (Settings.getInstance().getCurLevel().time / 2))))){
GameField.getInstance().stopField();
stopTimer();
message = StringTable.getInstance().getString("firstTime_halfTime");
target = new Point((main_window.time.x + (main_window.time.width / 2)), (main_window.time.y + (main_window.time.height / 2)));
StateManager.getInstance().pushState(new HintMessage(message, target, function (){
GameField.getInstance().startField();
startTimer();
}));
Profile.getInstance().isView_firstTime["half_time"] = true;
};
if (time <= (Settings.getInstance().getCurLevel().time * 0.05)){
if (runnigTime_fx == null){
playRunnigTime();
};
} else {
if (runnigTime_fx != null){
stopRunnigTime();
};
};
if (time <= 0){
stopRunnigTime();
timer.stop();
GameField.getInstance().stopField();
StateManager.getInstance().pushState(new TimeoutWindowState());
};
}
public function stopRunnigTime():void{
if (runnigTime_fx != null){
runnigTime_fx.stop();
runnigTime_fx = null;
};
}
protected function placeAtCenter(_arg1:MovieClip):void{
_arg1.x = ((width - _arg1.width) / 2);
_arg1.y = ((height - _arg1.height) / 2);
}
public function addScore(_arg1:int):void{
main_window.score.text = Profile.getInstance().addScore(_arg1);
}
function onSoundButtonDown(_arg1:MouseEvent):void{
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
if (_arg1.target == sound_button_on){
sound_button_off.x = _arg1.target.x;
sound_button_off.y = _arg1.target.y;
main_window.removeChild(DisplayObject(_arg1.target));
main_window.addChild(sound_button_off);
StateManager.getInstance().fx_soundManager.setGlobalVolume(0);
} else {
if (_arg1.target == sound_button_off){
sound_button_on.x = _arg1.target.x;
sound_button_on.y = _arg1.target.y;
main_window.removeChild(DisplayObject(_arg1.target));
main_window.addChild(sound_button_on);
StateManager.getInstance().fx_soundManager.setGlobalVolume(Settings.getInstance().getNumberProperty("volume", "0.7"));
};
};
}
override public function onCleanup():void{
stopRunnigTime();
stopMusic();
}
protected function update(_arg1:Event):void{
var _local2:Number;
if (((is_fade_music) && (!((music == null))))){
_local2 = Settings.getInstance().getNumberProperty("music_fade");
if (music.soundTransform.volume >= _local2){
music.soundTransform = new SoundTransform((music.soundTransform.volume - _local2));
} else {
is_fade_music = false;
stopMusic();
};
};
}
function onMoreGamesDown(_arg1:MouseEvent):void{
var e = _arg1;
try {
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
navigateToURL(new URLRequest(Settings.getInstance().getProperty("more_games_link")), "_blank");
} catch(err:Error) {
trace(("Error->GameState: navigateToUrl throw exception \n" + err.getStackTrace()));
};
}
public static function getInstance():GameState{
if (instance == null){
instance = new GameState(new EnforceSingletone());
};
return (instance);
}
}
}//package States
class EnforceSingletone {
private function EnforceSingletone(){
}
}
Section 23
//HelpState (States.HelpState)
package States {
import Common.*;
import flash.events.*;
import flash.display.*;
public class HelpState extends ModalWindowState {
var cur_page:int;// = 0
var to_next_state:Function;// = null
var pages:Array;
var window:MovieClip;
static var instance:HelpState = null;
public function HelpState(_arg1:EnforceSingletone){
pages = new Array();
cur_page = 0;
to_next_state = null;
super();
pages.push(new Help_Page_0());
pages.push(new Help_Page_1());
pages.push(new Help_Page_2());
}
protected function onRightClick(_arg1:MouseEvent):void{
if (cur_page < (pages.length - 1)){
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
if (contains(pages[cur_page])){
removeChild(pages[cur_page]);
};
cur_page++;
window.right.enabled = !((cur_page == (pages.length - 1)));
window.left.enabled = !((cur_page == 0));
addChildAt(pages[cur_page], getChildIndex(window));
};
}
protected function onOkClick(_arg1:MouseEvent):void{
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
if (to_next_state != null){
to_next_state();
} else {
StateManager.getInstance().popState();
trace("Warning->HelpState: next_state is null!");
};
}
public function setToNextState(_arg1:Function):void{
to_next_state = _arg1;
}
override public function onPreInit():void{
super.onPreInit();
window = new Help_Window();
addChild(window);
window.ok_button.addEventListener(MouseEvent.CLICK, onOkClick);
window.left.addEventListener(MouseEvent.CLICK, onLeftClick);
window.right.addEventListener(MouseEvent.CLICK, onRightClick);
}
override public function onInit():void{
var _local1:MovieClip;
super.onInit();
cur_page = 0;
for each (_local1 in pages) {
if (contains(_local1)){
removeChild(_local1);
};
};
addChildAt(pages[cur_page], getChildIndex(window));
Profile.getInstance().isView_firstTime["help"] = true;
window.left.enabled = false;
window.right.enabled = true;
}
protected function onLeftClick(_arg1:MouseEvent):void{
if (cur_page > 0){
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
if (contains(pages[cur_page])){
removeChild(pages[cur_page]);
};
cur_page--;
window.right.enabled = !((cur_page == (pages.length - 1)));
window.left.enabled = !((cur_page == 0));
addChildAt(pages[cur_page], getChildIndex(window));
};
}
override public function onCleanup():void{
to_next_state = null;
}
public static function getInstance():HelpState{
if (instance == null){
instance = new HelpState(new EnforceSingletone());
};
return (instance);
}
}
}//package States
class EnforceSingletone {
private function EnforceSingletone(){
}
}
Section 24
//HintMessage (States.HintMessage)
package States {
import Common.*;
import flash.display.*;
import flash.geom.*;
public class HintMessage extends MessageState {
var arrow:MovieClip;
var target:Point;
public function HintMessage(_arg1:String, _arg2:Point, _arg3:Function=null, _arg4:Number=0){
super(_arg1, _arg3, _arg4);
this.target = _arg2;
}
override public function onPreInit():void{
super.onPreInit();
arrow = new Hint_Arrow_Animation();
addChild(arrow);
}
override public function onInit():void{
var _local1:Boolean;
var _local2:Boolean;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
super.onInit();
_local1 = false;
_local2 = false;
if (target != null){
if (target.x <= (width / 2)){
_local2 = true;
};
if (target.y <= (height / 2)){
_local1 = true;
};
_local3 = (arrow.width * Math.SQRT1_2);
_local4 = (arrow.width * Math.SQRT1_2);
if (_local2){
arrow.rotation = 45;
_local6 = (target.x + (_local3 + 20));
} else {
arrow.rotation = 135;
_local6 = (target.x - ((window.width + _local3) + 20));
};
if (_local1){
_local5 = (target.y + (_local4 + 20));
} else {
_local5 = (target.y - ((window.height + _local4) + 20));
arrow.rotation = -(arrow.rotation);
};
arrow.x = target.x;
arrow.y = target.y;
if (_local6 < 10){
window.x = 10;
} else {
if ((_local6 + window.width) > (width - 25)){
window.x = (width - (window.width + 25));
} else {
window.x = _local6;
};
};
if (_local5 < 10){
window.y = 10;
} else {
if ((_local5 + window.height) > (height - 10)){
window.y = (height - (window.height + 10));
} else {
window.y = _local5;
};
};
StateManager.getInstance().fx_soundManager.playSound("Hint_Fx");
} else {
trace("Warning->HintMessage: target is null!");
};
}
}
}//package States
Section 25
//LevelCompleteWindowState (States.LevelCompleteWindowState)
package States {
import Common.*;
import flash.display.*;
public class LevelCompleteWindowState extends MessageState {
var statistics:Array;
public function LevelCompleteWindowState(_arg1:Array, _arg2:Function=null, _arg3:Number=0):void{
super(StringTable.getInstance().getString("levelComplete_message"), _arg2, _arg3);
this.statistics = _arg1;
}
override public function onInit():void{
super.onInit();
StateManager.getInstance().fx_soundManager.playSound("LevelComplete_Fx");
window.level_points_str.text = StringTable.getInstance().getString("level_points").replace(new RegExp(/\\[rn]/gim), "\n");
window.time_points_str.text = StringTable.getInstance().getString("timeLeft_points").replace(new RegExp(/\\[rn]/gim), "\n");
window.total_points_str.text = StringTable.getInstance().getString("total_score").replace(new RegExp(/\\[rn]/gim), "\n");
window.level_points.text = ((statistics[0] == null)) ? "???" : statistics[0];
window.time_points.text = ((statistics[1] == null)) ? "???" : statistics[1];
window.total_points.text = ((statistics[2] == null)) ? "???" : statistics[2];
}
override protected function getWindowMovie():MovieClip{
return (new LevelComplete_Window());
}
}
}//package States
Section 26
//MainMenuState (States.MainMenuState)
package States {
import Common.*;
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.net.*;
public class MainMenuState extends ModalWindowState {
protected var music:SoundChannel;
var window:MovieClip;
static var instance:MainMenuState = null;
public function MainMenuState(_arg1:EnforceSingletone){
}
protected function onMoreGamesClick(_arg1:MouseEvent):void{
var e = _arg1;
try {
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
navigateToURL(new URLRequest(Settings.getInstance().getProperty("more_games_link")), "_blank");
} catch(err:Error) {
trace(("Error->MainMenuState: navigateToUrl throw exception \n" + err.getStackTrace()));
};
}
public function stopMusic():void{
if (music != null){
music.stop();
music = null;
};
}
protected function onDownloadClick(_arg1:MouseEvent):void{
var e = _arg1;
try {
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
navigateToURL(new URLRequest(Settings.getInstance().getProperty("download_link")), "_blank");
} catch(err:Error) {
trace(("Error->MainMenuState: navigateToUrl throw exception \n" + err.getStackTrace()));
};
}
public function playMusic():void{
if (music != null){
music.stop();
};
music = StateManager.getInstance().music_soundManager.playSound("Menu_Music", -1);
}
override public function onPreInit():void{
super.onPreInit();
addChild(new Main_Back());
window = new Main_Menu();
addChild(window);
window.play_game.addEventListener(MouseEvent.CLICK, onPlayClick);
window.help.addEventListener(MouseEvent.CLICK, onHelpClick);
window.download.addEventListener(MouseEvent.CLICK, onDownloadClick);
window.more_games.addEventListener(MouseEvent.CLICK, onMoreGamesClick);
}
override public function onInit():void{
super.onInit();
window.x = ((width - window.width) / 2);
window.y = ((height - window.height) / 2);
playMusic();
}
protected function onPlayClick(_arg1:MouseEvent):void{
var e = _arg1;
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
if (!Profile.getInstance().isView_firstTime["help"]){
HelpState.getInstance().setToNextState(function (){
StateManager.getInstance().changeState(GameState.getInstance());
});
StateManager.getInstance().pushState(HelpState.getInstance());
} else {
StateManager.getInstance().changeState(GameState.getInstance());
};
}
protected function onHelpClick(_arg1:MouseEvent):void{
var e = _arg1;
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
HelpState.getInstance().setToNextState(function (){
StateManager.getInstance().popState();
});
StateManager.getInstance().pushState(HelpState.getInstance());
}
override public function onCleanup():void{
stopMusic();
}
public static function getInstance():MainMenuState{
if (instance == null){
instance = new MainMenuState(new EnforceSingletone());
};
return (instance);
}
}
}//package States
class EnforceSingletone {
private function EnforceSingletone(){
}
}
Section 27
//MessageState (States.MessageState)
package States {
import Common.*;
import flash.events.*;
import flash.display.*;
public class MessageState extends BaseMessageState {
public function MessageState(_arg1:String, _arg2:Function=null, _arg3:Number=0.3):void{
super(_arg1, _arg2, _arg3);
}
protected function onOkClick(_arg1:MouseEvent):void{
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
if (StateManager.getInstance().getTopState() == this){
StateManager.getInstance().popState();
};
}
override public function onPreInit():void{
super.onPreInit();
window.ok_button.addEventListener(MouseEvent.CLICK, onOkClick);
}
override public function onInit():void{
super.onInit();
window.message.text = message.replace(new RegExp(/\\[rn]/gim), "\n");
}
override public function onCleanup():void{
window.ok_button.removeEventListener(MouseEvent.CLICK, onOkClick);
super.onCleanup();
}
override protected function getWindowMovie():MovieClip{
return (new Window_Tip());
}
}
}//package States
Section 28
//ModalWindowState (States.ModalWindowState)
package States {
import Common.*;
import flash.display.*;
public class ModalWindowState extends State {
var back_alpha:Number;// = 0.3
var back:MovieClip;
public function ModalWindowState(_arg1:Number=0.3){
back_alpha = 0.3;
super();
this.back_alpha = _arg1;
}
public function setBackAlpha(_arg1:Number):void{
this.back_alpha = _arg1;
}
override public function onPreInit():void{
var _local1:*;
var _local2:Number;
back = new MovieClip();
if (((((!((parent == null))) && ((parent.width > 0)))) && ((parent.height > 0)))){
_local1 = parent.width;
_local2 = parent.height;
} else {
_local1 = 100;
_local2 = 100;
};
back.graphics.beginFill(0, back_alpha);
back.graphics.drawRect(0, 0, _local1, _local2);
back.graphics.endFill();
addChild(back);
}
override public function onInit():void{
back.width = parent.width;
back.height = parent.height;
}
}
}//package States
Section 29
//TimeoutWindowState (States.TimeoutWindowState)
package States {
import Common.*;
import flash.events.*;
import flash.display.*;
import Game.*;
public class TimeoutWindowState extends BaseMessageState {
public function TimeoutWindowState(_arg1:Function=null, _arg2:Number=0.3):void{
var _local3:String;
_local3 = StringTable.getInstance().getString("timeOut_message");
super(_local3, _arg1, _arg2);
}
protected function onMainMenuClick(_arg1:MouseEvent):void{
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
GameField.getInstance().reset();
Profile.getInstance().resetProfile();
StateManager.getInstance().changeState(MainMenuState.getInstance());
}
override public function onPreInit():void{
super.onPreInit();
window.main_menu.addEventListener(MouseEvent.CLICK, onMainMenuClick);
window.play_button.addEventListener(MouseEvent.CLICK, onPlayClick);
}
override public function onInit():void{
super.onInit();
window.message.text = message.replace(new RegExp(/\\[rn]/gim), "\n");
StateManager.getInstance().fx_soundManager.playSound("Timeout_Fx");
}
protected function onPlayClick(_arg1:MouseEvent):void{
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
GameField.getInstance().reset();
GameState.getInstance().loadCurrentLevel();
StateManager.getInstance().popState();
}
override public function onCleanup():void{
window.main_menu.removeEventListener(MouseEvent.CLICK, onMainMenuClick);
window.play_button.removeEventListener(MouseEvent.CLICK, onPlayClick);
super.onCleanup();
}
override protected function getWindowMovie():MovieClip{
return (new TimeOut_Window());
}
}
}//package States
Section 30
//YesNoWindowState (States.YesNoWindowState)
package States {
import Common.*;
import flash.events.*;
import flash.display.*;
public class YesNoWindowState extends BaseMessageState {
public function YesNoWindowState(_arg1:String, _arg2:Function=null, _arg3:Number=0){
super(_arg1, _arg2, _arg3);
}
protected function onOkClick(_arg1:MouseEvent):void{
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
if (callback != null){
callback(true);
};
if (StateManager.getInstance().getTopState() == this){
StateManager.getInstance().popState();
};
}
override public function onPreInit():void{
super.onPreInit();
window.ok_button.addEventListener(MouseEvent.CLICK, onOkClick);
window.cancel_button.addEventListener(MouseEvent.CLICK, onCancelClick);
}
override public function onInit():void{
super.onInit();
window.message.text = message.replace(new RegExp(/\\[rn]/gim), "\n");
}
override public function onCleanup():void{
window.ok_button.removeEventListener(MouseEvent.CLICK, onOkClick);
window.cancel_button.removeEventListener(MouseEvent.CLICK, onCancelClick);
callback = null;
}
protected function onCancelClick(_arg1:MouseEvent):void{
StateManager.getInstance().fx_soundManager.playSound("Click_Fx");
if (callback != null){
callback(false);
};
if (StateManager.getInstance().getTopState() == this){
StateManager.getInstance().popState();
};
}
override protected function getWindowMovie():MovieClip{
return (new YesNo_Window());
}
}
}//package States
Section 31
//LibraryMovies (Utillity.LibraryMovies)
package Utillity {
import flash.utils.*;
import flash.display.*;
public class LibraryMovies {
public static function getClassFromLibrary(_arg1:String):Class{
return ((getDefinitionByName(_arg1) as Class));
}
public static function getMovieFromLibrary(_arg1:String):MovieClip{
var _local2:Class;
_local2 = (getDefinitionByName(_arg1) as Class);
if (_local2 == null){
return (null);
};
return ((new (_local2) as MovieClip));
}
}
}//package Utillity
Section 32
//Random (Utillity.Random)
package Utillity {
public class Random {
public function Random(_arg1:EnforceSingletone){
}
public static function randomInt(_arg1:int):int{
return ((Math.random() * _arg1));
}
}
}//package Utillity
class EnforceSingletone {
private function EnforceSingletone(){
}
}
Section 33
//AbortGame_Button (AbortGame_Button)
package {
import flash.display.*;
public dynamic class AbortGame_Button extends SimpleButton {
}
}//package
Section 34
//Amount_Time (Amount_Time)
package {
import flash.display.*;
import flash.text.*;
public dynamic class Amount_Time extends MovieClip {
public var amount:TextField;
}
}//package
Section 35
//Back (Back)
package {
import flash.display.*;
public dynamic class Back extends MovieClip {
}
}//package
Section 36
//BadMove_Fx (BadMove_Fx)
package {
import flash.media.*;
public dynamic class BadMove_Fx extends Sound {
}
}//package
Section 37
//BeginLevel_Fx (BeginLevel_Fx)
package {
import flash.media.*;
public dynamic class BeginLevel_Fx extends Sound {
}
}//package
Section 38
//Bomb_0 (Bomb_0)
package {
import flash.display.*;
public dynamic class Bomb_0 extends MovieClip {
}
}//package
Section 39
//Bomb_0_Away (Bomb_0_Away)
package {
import flash.display.*;
public dynamic class Bomb_0_Away extends MovieClip {
}
}//package
Section 40
//Bomb_0_Choose (Bomb_0_Choose)
package {
import flash.display.*;
public dynamic class Bomb_0_Choose extends MovieClip {
}
}//package
Section 41
//Bomb_0_Rollover (Bomb_0_Rollover)
package {
import flash.display.*;
public dynamic class Bomb_0_Rollover extends MovieClip {
}
}//package
Section 42
//Bomb_1 (Bomb_1)
package {
import flash.display.*;
public dynamic class Bomb_1 extends MovieClip {
}
}//package
Section 43
//Bomb_1_Away (Bomb_1_Away)
package {
import flash.display.*;
public dynamic class Bomb_1_Away extends MovieClip {
}
}//package
Section 44
//Bomb_1_Choose (Bomb_1_Choose)
package {
import flash.display.*;
public dynamic class Bomb_1_Choose extends MovieClip {
}
}//package
Section 45
//Bomb_1_Rollover (Bomb_1_Rollover)
package {
import flash.display.*;
public dynamic class Bomb_1_Rollover extends MovieClip {
}
}//package
Section 46
//Bomb_2 (Bomb_2)
package {
import flash.display.*;
public dynamic class Bomb_2 extends MovieClip {
}
}//package
Section 47
//Bomb_2_Away (Bomb_2_Away)
package {
import flash.display.*;
public dynamic class Bomb_2_Away extends MovieClip {
}
}//package
Section 48
//Bomb_2_Choose (Bomb_2_Choose)
package {
import flash.display.*;
public dynamic class Bomb_2_Choose extends MovieClip {
}
}//package
Section 49
//Bomb_2_Rollover (Bomb_2_Rollover)
package {
import flash.display.*;
public dynamic class Bomb_2_Rollover extends MovieClip {
}
}//package
Section 50
//Bomb_3 (Bomb_3)
package {
import flash.display.*;
public dynamic class Bomb_3 extends MovieClip {
}
}//package
Section 51
//Bomb_3_Away (Bomb_3_Away)
package {
import flash.display.*;
public dynamic class Bomb_3_Away extends MovieClip {
}
}//package
Section 52
//Bomb_3_Choose (Bomb_3_Choose)
package {
import flash.display.*;
public dynamic class Bomb_3_Choose extends MovieClip {
}
}//package
Section 53
//Bomb_3_Rollover (Bomb_3_Rollover)
package {
import flash.display.*;
public dynamic class Bomb_3_Rollover extends MovieClip {
}
}//package
Section 54
//Bomb_4 (Bomb_4)
package {
import flash.display.*;
public dynamic class Bomb_4 extends MovieClip {
}
}//package
Section 55
//Bomb_4_Away (Bomb_4_Away)
package {
import flash.display.*;
public dynamic class Bomb_4_Away extends MovieClip {
}
}//package
Section 56
//Bomb_4_Choose (Bomb_4_Choose)
package {
import flash.display.*;
public dynamic class Bomb_4_Choose extends MovieClip {
}
}//package
Section 57
//Bomb_4_Rollover (Bomb_4_Rollover)
package {
import flash.display.*;
public dynamic class Bomb_4_Rollover extends MovieClip {
}
}//package
Section 58
//Bomb_5 (Bomb_5)
package {
import flash.display.*;
public dynamic class Bomb_5 extends MovieClip {
}
}//package
Section 59
//Bomb_5_Away (Bomb_5_Away)
package {
import flash.display.*;
public dynamic class Bomb_5_Away extends MovieClip {
}
}//package
Section 60
//Bomb_5_Choose (Bomb_5_Choose)
package {
import flash.display.*;
public dynamic class Bomb_5_Choose extends MovieClip {
}
}//package
Section 61
//Bomb_5_Rollover (Bomb_5_Rollover)
package {
import flash.display.*;
public dynamic class Bomb_5_Rollover extends MovieClip {
}
}//package
Section 62
//Bomb_6 (Bomb_6)
package {
import flash.display.*;
public dynamic class Bomb_6 extends MovieClip {
}
}//package
Section 63
//Bomb_6_Away (Bomb_6_Away)
package {
import flash.display.*;
public dynamic class Bomb_6_Away extends MovieClip {
}
}//package
Section 64
//Bomb_6_Choose (Bomb_6_Choose)
package {
import flash.display.*;
public dynamic class Bomb_6_Choose extends MovieClip {
}
}//package
Section 65
//Bomb_6_Rollover (Bomb_6_Rollover)
package {
import flash.display.*;
public dynamic class Bomb_6_Rollover extends MovieClip {
}
}//package
Section 66
//Bomb_Animation (Bomb_Animation)
package {
import flash.display.*;
public dynamic class Bomb_Animation extends MovieClip {
}
}//package
Section 67
//BonusAppear_Fx (BonusAppear_Fx)
package {
import flash.media.*;
public dynamic class BonusAppear_Fx extends Sound {
}
}//package
Section 68
//burst1 (burst1)
package {
import flash.media.*;
public dynamic class burst1 extends Sound {
}
}//package
Section 69
//burst2 (burst2)
package {
import flash.media.*;
public dynamic class burst2 extends Sound {
}
}//package
Section 70
//burst3 (burst3)
package {
import flash.media.*;
public dynamic class burst3 extends Sound {
}
}//package
Section 71
//burst4 (burst4)
package {
import flash.media.*;
public dynamic class burst4 extends Sound {
}
}//package
Section 72
//burst5 (burst5)
package {
import flash.media.*;
public dynamic class burst5 extends Sound {
}
}//package
Section 73
//burst6 (burst6)
package {
import flash.media.*;
public dynamic class burst6 extends Sound {
}
}//package
Section 74
//burst7 (burst7)
package {
import flash.media.*;
public dynamic class burst7 extends Sound {
}
}//package
Section 75
//Cell_Point (Cell_Point)
package {
import flash.display.*;
import flash.text.*;
public dynamic class Cell_Point extends MovieClip {
public var points:TextField;
}
}//package
Section 76
//Cell_Point_Animation (Cell_Point_Animation)
package {
import flash.display.*;
public dynamic class Cell_Point_Animation extends MovieClip {
public var cell_point:Cell_Point;
}
}//package
Section 77
//Chain (Chain)
package {
import flash.display.*;
public dynamic class Chain extends MovieClip {
}
}//package
Section 78
//Chain_Away (Chain_Away)
package {
import flash.display.*;
public dynamic class Chain_Away extends MovieClip {
}
}//package
Section 79
//Chain2 (Chain2)
package {
import flash.display.*;
public dynamic class Chain2 extends MovieClip {
}
}//package
Section 80
//Chain2_Away (Chain2_Away)
package {
import flash.display.*;
public dynamic class Chain2_Away extends MovieClip {
}
}//package
Section 81
//Click_Fx (Click_Fx)
package {
import flash.media.*;
public dynamic class Click_Fx extends Sound {
}
}//package
Section 82
//Clock_0 (Clock_0)
package {
import flash.display.*;
public dynamic class Clock_0 extends MovieClip {
}
}//package
Section 83
//Clock_0_Away (Clock_0_Away)
package {
import flash.display.*;
public dynamic class Clock_0_Away extends MovieClip {
}
}//package
Section 84
//Clock_0_Choose (Clock_0_Choose)
package {
import flash.display.*;
public dynamic class Clock_0_Choose extends MovieClip {
}
}//package
Section 85
//Clock_0_Rollover (Clock_0_Rollover)
package {
import flash.display.*;
public dynamic class Clock_0_Rollover extends MovieClip {
}
}//package
Section 86
//Clock_1 (Clock_1)
package {
import flash.display.*;
public dynamic class Clock_1 extends MovieClip {
}
}//package
Section 87
//Clock_1_Away (Clock_1_Away)
package {
import flash.display.*;
public dynamic class Clock_1_Away extends MovieClip {
}
}//package
Section 88
//Clock_1_Choose (Clock_1_Choose)
package {
import flash.display.*;
public dynamic class Clock_1_Choose extends MovieClip {
}
}//package
Section 89
//Clock_1_Rollover (Clock_1_Rollover)
package {
import flash.display.*;
public dynamic class Clock_1_Rollover extends MovieClip {
}
}//package
Section 90
//Clock_2 (Clock_2)
package {
import flash.display.*;
public dynamic class Clock_2 extends MovieClip {
}
}//package
Section 91
//Clock_2_Away (Clock_2_Away)
package {
import flash.display.*;
public dynamic class Clock_2_Away extends MovieClip {
}
}//package
Section 92
//Clock_2_Choose (Clock_2_Choose)
package {
import flash.display.*;
public dynamic class Clock_2_Choose extends MovieClip {
}
}//package
Section 93
//Clock_2_Rollover (Clock_2_Rollover)
package {
import flash.display.*;
public dynamic class Clock_2_Rollover extends MovieClip {
}
}//package
Section 94
//Clock_3 (Clock_3)
package {
import flash.display.*;
public dynamic class Clock_3 extends MovieClip {
}
}//package
Section 95
//Clock_3_Away (Clock_3_Away)
package {
import flash.display.*;
public dynamic class Clock_3_Away extends MovieClip {
}
}//package
Section 96
//Clock_3_Choose (Clock_3_Choose)
package {
import flash.display.*;
public dynamic class Clock_3_Choose extends MovieClip {
}
}//package
Section 97
//Clock_3_Rollover (Clock_3_Rollover)
package {
import flash.display.*;
public dynamic class Clock_3_Rollover extends MovieClip {
}
}//package
Section 98
//Clock_4 (Clock_4)
package {
import flash.display.*;
public dynamic class Clock_4 extends MovieClip {
}
}//package
Section 99
//Clock_4_Away (Clock_4_Away)
package {
import flash.display.*;
public dynamic class Clock_4_Away extends MovieClip {
}
}//package
Section 100
//Clock_4_Choose (Clock_4_Choose)
package {
import flash.display.*;
public dynamic class Clock_4_Choose extends MovieClip {
}
}//package
Section 101
//Clock_4_Rollover (Clock_4_Rollover)
package {
import flash.display.*;
public dynamic class Clock_4_Rollover extends MovieClip {
}
}//package
Section 102
//Clock_5 (Clock_5)
package {
import flash.display.*;
public dynamic class Clock_5 extends MovieClip {
}
}//package
Section 103
//Clock_5_Away (Clock_5_Away)
package {
import flash.display.*;
public dynamic class Clock_5_Away extends MovieClip {
}
}//package
Section 104
//Clock_5_Choose (Clock_5_Choose)
package {
import flash.display.*;
public dynamic class Clock_5_Choose extends MovieClip {
}
}//package
Section 105
//Clock_5_Rollover (Clock_5_Rollover)
package {
import flash.display.*;
public dynamic class Clock_5_Rollover extends MovieClip {
}
}//package
Section 106
//Clock_6 (Clock_6)
package {
import flash.display.*;
public dynamic class Clock_6 extends MovieClip {
}
}//package
Section 107
//Clock_6_Away (Clock_6_Away)
package {
import flash.display.*;
public dynamic class Clock_6_Away extends MovieClip {
}
}//package
Section 108
//Clock_6_Rollover (Clock_6_Rollover)
package {
import flash.display.*;
public dynamic class Clock_6_Rollover extends MovieClip {
}
}//package
Section 109
//Combo_Fx (Combo_Fx)
package {
import flash.media.*;
public dynamic class Combo_Fx extends Sound {
}
}//package
Section 110
//Core_Lightning (Core_Lightning)
package {
import flash.display.*;
public dynamic class Core_Lightning extends MovieClip {
}
}//package
Section 111
//Download_Button (Download_Button)
package {
import flash.display.*;
public dynamic class Download_Button extends SimpleButton {
}
}//package
Section 112
//Dynamite_0 (Dynamite_0)
package {
import flash.display.*;
public dynamic class Dynamite_0 extends MovieClip {
}
}//package
Section 113
//Dynamite_0_Away (Dynamite_0_Away)
package {
import flash.display.*;
public dynamic class Dynamite_0_Away extends MovieClip {
}
}//package
Section 114
//Dynamite_0_Choose (Dynamite_0_Choose)
package {
import flash.display.*;
public dynamic class Dynamite_0_Choose extends MovieClip {
}
}//package
Section 115
//Dynamite_0_Rollover (Dynamite_0_Rollover)
package {
import flash.display.*;
public dynamic class Dynamite_0_Rollover extends MovieClip {
}
}//package
Section 116
//Dynamite_1 (Dynamite_1)
package {
import flash.display.*;
public dynamic class Dynamite_1 extends MovieClip {
}
}//package
Section 117
//Dynamite_1_Away (Dynamite_1_Away)
package {
import flash.display.*;
public dynamic class Dynamite_1_Away extends MovieClip {
}
}//package
Section 118
//Dynamite_1_Choose (Dynamite_1_Choose)
package {
import flash.display.*;
public dynamic class Dynamite_1_Choose extends MovieClip {
}
}//package
Section 119
//Dynamite_1_Rollover (Dynamite_1_Rollover)
package {
import flash.display.*;
public dynamic class Dynamite_1_Rollover extends MovieClip {
}
}//package
Section 120
//Dynamite_2 (Dynamite_2)
package {
import flash.display.*;
public dynamic class Dynamite_2 extends MovieClip {
}
}//package
Section 121
//Dynamite_2_Away (Dynamite_2_Away)
package {
import flash.display.*;
public dynamic class Dynamite_2_Away extends MovieClip {
}
}//package
Section 122
//Dynamite_2_Choose (Dynamite_2_Choose)
package {
import flash.display.*;
public dynamic class Dynamite_2_Choose extends MovieClip {
}
}//package
Section 123
//Dynamite_2_Rollover (Dynamite_2_Rollover)
package {
import flash.display.*;
public dynamic class Dynamite_2_Rollover extends MovieClip {
}
}//package
Section 124
//Dynamite_3 (Dynamite_3)
package {
import flash.display.*;
public dynamic class Dynamite_3 extends MovieClip {
}
}//package
Section 125
//Dynamite_3_Away (Dynamite_3_Away)
package {
import flash.display.*;
public dynamic class Dynamite_3_Away extends MovieClip {
}
}//package
Section 126
//Dynamite_3_Choose (Dynamite_3_Choose)
package {
import flash.display.*;
public dynamic class Dynamite_3_Choose extends MovieClip {
}
}//package
Section 127
//Dynamite_3_Rollover (Dynamite_3_Rollover)
package {
import flash.display.*;
public dynamic class Dynamite_3_Rollover extends MovieClip {
}
}//package
Section 128
//Dynamite_4 (Dynamite_4)
package {
import flash.display.*;
public dynamic class Dynamite_4 extends MovieClip {
}
}//package
Section 129
//Dynamite_4_Away (Dynamite_4_Away)
package {
import flash.display.*;
public dynamic class Dynamite_4_Away extends MovieClip {
}
}//package
Section 130
//Dynamite_4_Choose (Dynamite_4_Choose)
package {
import flash.display.*;
public dynamic class Dynamite_4_Choose extends MovieClip {
}
}//package
Section 131
//Dynamite_4_Rollover (Dynamite_4_Rollover)
package {
import flash.display.*;
public dynamic class Dynamite_4_Rollover extends MovieClip {
}
}//package
Section 132
//Dynamite_5 (Dynamite_5)
package {
import flash.display.*;
public dynamic class Dynamite_5 extends MovieClip {
}
}//package
Section 133
//Dynamite_5_Away (Dynamite_5_Away)
package {
import flash.display.*;
public dynamic class Dynamite_5_Away extends MovieClip {
}
}//package
Section 134
//Dynamite_5_Choose (Dynamite_5_Choose)
package {
import flash.display.*;
public dynamic class Dynamite_5_Choose extends MovieClip {
}
}//package
Section 135
//Dynamite_5_Rollover (Dynamite_5_Rollover)
package {
import flash.display.*;
public dynamic class Dynamite_5_Rollover extends MovieClip {
}
}//package
Section 136
//Dynamite_6 (Dynamite_6)
package {
import flash.display.*;
public dynamic class Dynamite_6 extends MovieClip {
}
}//package
Section 137
//Dynamite_6_Away (Dynamite_6_Away)
package {
import flash.display.*;
public dynamic class Dynamite_6_Away extends MovieClip {
}
}//package
Section 138
//Dynamite_6_Choose (Dynamite_6_Choose)
package {
import flash.display.*;
public dynamic class Dynamite_6_Choose extends MovieClip {
}
}//package
Section 139
//Dynamite_6_Rollover (Dynamite_6_Rollover)
package {
import flash.display.*;
public dynamic class Dynamite_6_Rollover extends MovieClip {
}
}//package
Section 140
//Dynamite_Animation (Dynamite_Animation)
package {
import flash.display.*;
public dynamic class Dynamite_Animation extends MovieClip {
}
}//package
Section 141
//Explosion_Fx (Explosion_Fx)
package {
import flash.media.*;
public dynamic class Explosion_Fx extends Sound {
}
}//package
Section 142
//Figura_0 (Figura_0)
package {
import flash.display.*;
public dynamic class Figura_0 extends MovieClip {
}
}//package
Section 143
//Figura_0_Away (Figura_0_Away)
package {
import flash.display.*;
public dynamic class Figura_0_Away extends MovieClip {
}
}//package
Section 144
//Figura_0_Choose (Figura_0_Choose)
package {
import flash.display.*;
public dynamic class Figura_0_Choose extends MovieClip {
}
}//package
Section 145
//Figura_0_Random (Figura_0_Random)
package {
import flash.display.*;
public dynamic class Figura_0_Random extends MovieClip {
}
}//package
Section 146
//Figura_0_Rollover (Figura_0_Rollover)
package {
import flash.display.*;
public dynamic class Figura_0_Rollover extends MovieClip {
}
}//package
Section 147
//Figura_1 (Figura_1)
package {
import flash.display.*;
public dynamic class Figura_1 extends MovieClip {
}
}//package
Section 148
//Figura_1_Away (Figura_1_Away)
package {
import flash.display.*;
public dynamic class Figura_1_Away extends MovieClip {
}
}//package
Section 149
//Figura_1_Choose (Figura_1_Choose)
package {
import flash.display.*;
public dynamic class Figura_1_Choose extends MovieClip {
}
}//package
Section 150
//Figura_1_Random (Figura_1_Random)
package {
import flash.display.*;
public dynamic class Figura_1_Random extends MovieClip {
}
}//package
Section 151
//Figura_1_Rollover (Figura_1_Rollover)
package {
import flash.display.*;
public dynamic class Figura_1_Rollover extends MovieClip {
}
}//package
Section 152
//Figura_2 (Figura_2)
package {
import flash.display.*;
public dynamic class Figura_2 extends MovieClip {
}
}//package
Section 153
//Figura_2_Away (Figura_2_Away)
package {
import flash.display.*;
public dynamic class Figura_2_Away extends MovieClip {
}
}//package
Section 154
//Figura_2_Choose (Figura_2_Choose)
package {
import flash.display.*;
public dynamic class Figura_2_Choose extends MovieClip {
}
}//package
Section 155
//Figura_2_Random (Figura_2_Random)
package {
import flash.display.*;
public dynamic class Figura_2_Random extends MovieClip {
}
}//package
Section 156
//Figura_2_Rollover (Figura_2_Rollover)
package {
import flash.display.*;
public dynamic class Figura_2_Rollover extends MovieClip {
}
}//package
Section 157
//Figura_3 (Figura_3)
package {
import flash.display.*;
public dynamic class Figura_3 extends MovieClip {
}
}//package
Section 158
//Figura_3_Away (Figura_3_Away)
package {
import flash.display.*;
public dynamic class Figura_3_Away extends MovieClip {
}
}//package
Section 159
//Figura_3_Choose (Figura_3_Choose)
package {
import flash.display.*;
public dynamic class Figura_3_Choose extends MovieClip {
}
}//package
Section 160
//Figura_3_Random (Figura_3_Random)
package {
import flash.display.*;
public dynamic class Figura_3_Random extends MovieClip {
}
}//package
Section 161
//Figura_3_Rollover (Figura_3_Rollover)
package {
import flash.display.*;
public dynamic class Figura_3_Rollover extends MovieClip {
}
}//package
Section 162
//Figura_4 (Figura_4)
package {
import flash.display.*;
public dynamic class Figura_4 extends MovieClip {
}
}//package
Section 163
//Figura_4_Away (Figura_4_Away)
package {
import flash.display.*;
public dynamic class Figura_4_Away extends MovieClip {
}
}//package
Section 164
//Figura_4_Choose (Figura_4_Choose)
package {
import flash.display.*;
public dynamic class Figura_4_Choose extends MovieClip {
}
}//package
Section 165
//Figura_4_Random (Figura_4_Random)
package {
import flash.display.*;
public dynamic class Figura_4_Random extends MovieClip {
}
}//package
Section 166
//Figura_4_Rollover (Figura_4_Rollover)
package {
import flash.display.*;
public dynamic class Figura_4_Rollover extends MovieClip {
}
}//package
Section 167
//Figura_5 (Figura_5)
package {
import flash.display.*;
public dynamic class Figura_5 extends MovieClip {
}
}//package
Section 168
//Figura_5_Away (Figura_5_Away)
package {
import flash.display.*;
public dynamic class Figura_5_Away extends MovieClip {
}
}//package
Section 169
//Figura_5_Choose (Figura_5_Choose)
package {
import flash.display.*;
public dynamic class Figura_5_Choose extends MovieClip {
}
}//package
Section 170
//Figura_5_Random (Figura_5_Random)
package {
import flash.display.*;
public dynamic class Figura_5_Random extends MovieClip {
}
}//package
Section 171
//Figura_5_Rollover (Figura_5_Rollover)
package {
import flash.display.*;
public dynamic class Figura_5_Rollover extends MovieClip {
}
}//package
Section 172
//Figura_6 (Figura_6)
package {
import flash.display.*;
public dynamic class Figura_6 extends MovieClip {
}
}//package
Section 173
//Figura_6_Away (Figura_6_Away)
package {
import flash.display.*;
public dynamic class Figura_6_Away extends MovieClip {
}
}//package
Section 174
//Figura_6_Choose (Figura_6_Choose)
package {
import flash.display.*;
public dynamic class Figura_6_Choose extends MovieClip {
}
}//package
Section 175
//Figura_6_Random (Figura_6_Random)
package {
import flash.display.*;
public dynamic class Figura_6_Random extends MovieClip {
}
}//package
Section 176
//Figura_6_Rollover (Figura_6_Rollover)
package {
import flash.display.*;
public dynamic class Figura_6_Rollover extends MovieClip {
}
}//package
Section 177
//Figura_Black (Figura_Black)
package {
import flash.display.*;
public dynamic class Figura_Black extends MovieClip {
}
}//package
Section 178
//Figura_Black_Away (Figura_Black_Away)
package {
import flash.display.*;
public dynamic class Figura_Black_Away extends MovieClip {
}
}//package
Section 179
//Figura_Black_Choose (Figura_Black_Choose)
package {
import flash.display.*;
public dynamic class Figura_Black_Choose extends MovieClip {
}
}//package
Section 180
//Figura_Black_Random (Figura_Black_Random)
package {
import flash.display.*;
public dynamic class Figura_Black_Random extends MovieClip {
}
}//package
Section 181
//Figura_Black_Rollover (Figura_Black_Rollover)
package {
import flash.display.*;
public dynamic class Figura_Black_Rollover extends MovieClip {
}
}//package
Section 182
//Game_Music (Game_Music)
package {
import flash.media.*;
public dynamic class Game_Music extends Sound {
}
}//package
Section 183
//GameComplete_Fx (GameComplete_Fx)
package {
import flash.media.*;
public dynamic class GameComplete_Fx extends Sound {
}
}//package
Section 184
//GameComplete_Window (GameComplete_Window)
package {
import flash.display.*;
import flash.text.*;
public dynamic class GameComplete_Window extends MovieClip {
public var ok_button:SimpleButton;
public var message:TextField;
public var download:Download_Button;
}
}//package
Section 185
//Help_Page_0 (Help_Page_0)
package {
import flash.display.*;
public dynamic class Help_Page_0 extends MovieClip {
}
}//package
Section 186
//Help_Page_1 (Help_Page_1)
package {
import flash.display.*;
public dynamic class Help_Page_1 extends MovieClip {
}
}//package
Section 187
//Help_Page_2 (Help_Page_2)
package {
import flash.display.*;
public dynamic class Help_Page_2 extends MovieClip {
}
}//package
Section 188
//Help_Window (Help_Window)
package {
import flash.display.*;
public dynamic class Help_Window extends MovieClip {
public var ok_button:SimpleButton;
public var left:Left_Button;
public var right:Right_Button;
}
}//package
Section 189
//Hint_Arrow (Hint_Arrow)
package {
import flash.display.*;
public dynamic class Hint_Arrow extends MovieClip {
}
}//package
Section 190
//Hint_Arrow_Animation (Hint_Arrow_Animation)
package {
import flash.display.*;
public dynamic class Hint_Arrow_Animation extends MovieClip {
}
}//package
Section 191
//Hint_Fx (Hint_Fx)
package {
import flash.media.*;
public dynamic class Hint_Fx extends Sound {
}
}//package
Section 192
//HorizontalMove (HorizontalMove)
package {
import flash.display.*;
public dynamic class HorizontalMove extends MovieClip {
}
}//package
Section 193
//Left_Button (Left_Button)
package {
import flash.display.*;
public dynamic class Left_Button extends SimpleButton {
}
}//package
Section 194
//LevelComplete_Fx (LevelComplete_Fx)
package {
import flash.media.*;
public dynamic class LevelComplete_Fx extends Sound {
}
}//package
Section 195
//LevelComplete_Window (LevelComplete_Window)
package {
import flash.display.*;
import flash.text.*;
public dynamic class LevelComplete_Window extends MovieClip {
public var ok_button:SimpleButton;
public var level_points:TextField;
public var message:TextField;
public var total_points:TextField;
public var level_points_str:TextField;
public var time_points_str:TextField;
public var time_points:TextField;
public var total_points_str:TextField;
}
}//package
Section 196
//Lightning (Lightning)
package {
import flash.display.*;
public dynamic class Lightning extends MovieClip {
}
}//package
Section 197
//Lightning_0 (Lightning_0)
package {
import flash.display.*;
public dynamic class Lightning_0 extends MovieClip {
}
}//package
Section 198
//Lightning_0_Away (Lightning_0_Away)
package {
import flash.display.*;
public dynamic class Lightning_0_Away extends MovieClip {
}
}//package
Section 199
//Lightning_0_Choose (Lightning_0_Choose)
package {
import flash.display.*;
public dynamic class Lightning_0_Choose extends MovieClip {
}
}//package
Section 200
//Lightning_0_Rollover (Lightning_0_Rollover)
package {
import flash.display.*;
public dynamic class Lightning_0_Rollover extends MovieClip {
}
}//package
Section 201
//Lightning_1 (Lightning_1)
package {
import flash.display.*;
public dynamic class Lightning_1 extends MovieClip {
}
}//package
Section 202
//Lightning_1_Away (Lightning_1_Away)
package {
import flash.display.*;
public dynamic class Lightning_1_Away extends MovieClip {
}
}//package
Section 203
//Lightning_1_Choose (Lightning_1_Choose)
package {
import flash.display.*;
public dynamic class Lightning_1_Choose extends MovieClip {
}
}//package
Section 204
//Lightning_1_Rollover (Lightning_1_Rollover)
package {
import flash.display.*;
public dynamic class Lightning_1_Rollover extends MovieClip {
}
}//package
Section 205
//Lightning_2 (Lightning_2)
package {
import flash.display.*;
public dynamic class Lightning_2 extends MovieClip {
}
}//package
Section 206
//Lightning_2_Away (Lightning_2_Away)
package {
import flash.display.*;
public dynamic class Lightning_2_Away extends MovieClip {
}
}//package
Section 207
//Lightning_2_Choose (Lightning_2_Choose)
package {
import flash.display.*;
public dynamic class Lightning_2_Choose extends MovieClip {
}
}//package
Section 208
//Lightning_2_Rollover (Lightning_2_Rollover)
package {
import flash.display.*;
public dynamic class Lightning_2_Rollover extends MovieClip {
}
}//package
Section 209
//Lightning_3 (Lightning_3)
package {
import flash.display.*;
public dynamic class Lightning_3 extends MovieClip {
}
}//package
Section 210
//Lightning_3_Away (Lightning_3_Away)
package {
import flash.display.*;
public dynamic class Lightning_3_Away extends MovieClip {
}
}//package
Section 211
//Lightning_3_Choose (Lightning_3_Choose)
package {
import flash.display.*;
public dynamic class Lightning_3_Choose extends MovieClip {
}
}//package
Section 212
//Lightning_3_Rollover (Lightning_3_Rollover)
package {
import flash.display.*;
public dynamic class Lightning_3_Rollover extends MovieClip {
}
}//package
Section 213
//Lightning_4 (Lightning_4)
package {
import flash.display.*;
public dynamic class Lightning_4 extends MovieClip {
}
}//package
Section 214
//Lightning_4_Away (Lightning_4_Away)
package {
import flash.display.*;
public dynamic class Lightning_4_Away extends MovieClip {
}
}//package
Section 215
//Lightning_4_Choose (Lightning_4_Choose)
package {
import flash.display.*;
public dynamic class Lightning_4_Choose extends MovieClip {
}
}//package
Section 216
//Lightning_4_Rollover (Lightning_4_Rollover)
package {
import flash.display.*;
public dynamic class Lightning_4_Rollover extends MovieClip {
}
}//package
Section 217
//Lightning_5 (Lightning_5)
package {
import flash.display.*;
public dynamic class Lightning_5 extends MovieClip {
}
}//package
Section 218
//Lightning_5_Away (Lightning_5_Away)
package {
import flash.display.*;
public dynamic class Lightning_5_Away extends MovieClip {
}
}//package
Section 219
//Lightning_5_Choose (Lightning_5_Choose)
package {
import flash.display.*;
public dynamic class Lightning_5_Choose extends MovieClip {
}
}//package
Section 220
//Lightning_5_Rollover (Lightning_5_Rollover)
package {
import flash.display.*;
public dynamic class Lightning_5_Rollover extends MovieClip {
}
}//package
Section 221
//Lightning_6 (Lightning_6)
package {
import flash.display.*;
public dynamic class Lightning_6 extends MovieClip {
}
}//package
Section 222
//Lightning_6_Away (Lightning_6_Away)
package {
import flash.display.*;
public dynamic class Lightning_6_Away extends MovieClip {
}
}//package
Section 223
//Lightning_6_Choose (Lightning_6_Choose)
package {
import flash.display.*;
public dynamic class Lightning_6_Choose extends MovieClip {
}
}//package
Section 224
//Lightning_6_Rollover (Lightning_6_Rollover)
package {
import flash.display.*;
public dynamic class Lightning_6_Rollover extends MovieClip {
}
}//package
Section 225
//Lightning_Fx (Lightning_Fx)
package {
import flash.media.*;
public dynamic class Lightning_Fx extends Sound {
}
}//package
Section 226
//Main_Back (Main_Back)
package {
import flash.display.*;
public dynamic class Main_Back extends MovieClip {
}
}//package
Section 227
//Main_Menu (Main_Menu)
package {
import flash.display.*;
public dynamic class Main_Menu extends MovieClip {
public var play_game:SimpleButton;
public var help:SimpleButton;
public var more_games:SimpleButton;
public var download:Download_Button;
}
}//package
Section 228
//MainWindow (MainWindow)
package {
import flash.display.*;
import flash.text.*;
public dynamic class MainWindow extends MovieClip {
public var menu_button:MenuButton;
public var more_games:MoreGamesButton;
public var sound_button:SimpleButton;
public var level:TextField;
public var score:TextField;
public var music_button:MusicButtonOn;
public var time:TextField;
}
}//package
Section 229
//Match_Fx (Match_Fx)
package {
import flash.media.*;
public dynamic class Match_Fx extends Sound {
}
}//package
Section 230
//Menu_Music (Menu_Music)
package {
import flash.media.*;
public dynamic class Menu_Music extends Sound {
}
}//package
Section 231
//Menu_Window (Menu_Window)
package {
import flash.display.*;
public dynamic class Menu_Window extends MovieClip {
public var return_to_game:SimpleButton;
public var help:SimpleButton;
public var restart_level:RestartLevel_Button;
public var download:Download_Button;
public var abort_game:AbortGame_Button;
}
}//package
Section 232
//MenuButton (MenuButton)
package {
import flash.display.*;
public dynamic class MenuButton extends SimpleButton {
}
}//package
Section 233
//MoreGamesButton (MoreGamesButton)
package {
import flash.display.*;
public dynamic class MoreGamesButton extends SimpleButton {
}
}//package
Section 234
//MusicButtonOff (MusicButtonOff)
package {
import flash.display.*;
public dynamic class MusicButtonOff extends SimpleButton {
}
}//package
Section 235
//MusicButtonOn (MusicButtonOn)
package {
import flash.display.*;
public dynamic class MusicButtonOn extends SimpleButton {
}
}//package
Section 236
//Percents (Percents)
package {
import flash.display.*;
import flash.text.*;
public dynamic class Percents extends MovieClip {
public var percents:TextField;
}
}//package
Section 237
//Progress_Bar (Progress_Bar)
package {
import flash.display.*;
public dynamic class Progress_Bar extends MovieClip {
}
}//package
Section 238
//RestartLevel_Button (RestartLevel_Button)
package {
import flash.display.*;
public dynamic class RestartLevel_Button extends SimpleButton {
}
}//package
Section 239
//Right_Button (Right_Button)
package {
import flash.display.*;
public dynamic class Right_Button extends SimpleButton {
}
}//package
Section 240
//RunningTime_Fx (RunningTime_Fx)
package {
import flash.media.*;
public dynamic class RunningTime_Fx extends Sound {
}
}//package
Section 241
//Select_Fx (Select_Fx)
package {
import flash.media.*;
public dynamic class Select_Fx extends Sound {
}
}//package
Section 242
//Show_Combo (Show_Combo)
package {
import flash.display.*;
public dynamic class Show_Combo extends MovieClip {
public var combo:MovieClip;
}
}//package
Section 243
//SoundButtonOff (SoundButtonOff)
package {
import flash.display.*;
public dynamic class SoundButtonOff extends SimpleButton {
}
}//package
Section 244
//Square (Square)
package {
import flash.display.*;
public dynamic class Square extends MovieClip {
}
}//package
Section 245
//Stone (Stone)
package {
import flash.display.*;
public dynamic class Stone extends MovieClip {
}
}//package
Section 246
//Stone_Away (Stone_Away)
package {
import flash.display.*;
public dynamic class Stone_Away extends MovieClip {
}
}//package
Section 247
//Stone2 (Stone2)
package {
import flash.display.*;
public dynamic class Stone2 extends MovieClip {
}
}//package
Section 248
//Stone2_Away (Stone2_Away)
package {
import flash.display.*;
public dynamic class Stone2_Away extends MovieClip {
}
}//package
Section 249
//TempButton (TempButton)
package {
import flash.display.*;
public dynamic class TempButton extends SimpleButton {
}
}//package
Section 250
//TempButton2 (TempButton2)
package {
import flash.display.*;
public dynamic class TempButton2 extends SimpleButton {
}
}//package
Section 251
//TempLeft (TempLeft)
package {
import flash.display.*;
public dynamic class TempLeft extends SimpleButton {
}
}//package
Section 252
//TempRight (TempRight)
package {
import flash.display.*;
public dynamic class TempRight extends SimpleButton {
}
}//package
Section 253
//Timeout_Fx (Timeout_Fx)
package {
import flash.media.*;
public dynamic class Timeout_Fx extends Sound {
}
}//package
Section 254
//TimeOut_Window (TimeOut_Window)
package {
import flash.display.*;
import flash.text.*;
public dynamic class TimeOut_Window extends MovieClip {
public var message:TextField;
public var main_menu:SimpleButton;
public var play_button:SimpleButton;
}
}//package
Section 255
//VerticalMove (VerticalMove)
package {
import flash.display.*;
public dynamic class VerticalMove extends MovieClip {
}
}//package
Section 256
//WashingtonFont (WashingtonFont)
package {
import flash.text.*;
public dynamic class WashingtonFont extends Font {
}
}//package
Section 257
//Window_Big (Window_Big)
package {
import flash.display.*;
public dynamic class Window_Big extends MovieClip {
}
}//package
Section 258
//Window_Middle (Window_Middle)
package {
import flash.display.*;
public dynamic class Window_Middle extends MovieClip {
}
}//package
Section 259
//Window_Small (Window_Small)
package {
import flash.display.*;
public dynamic class Window_Small extends MovieClip {
}
}//package
Section 260
//Window_Tip (Window_Tip)
package {
import flash.display.*;
import flash.text.*;
public dynamic class Window_Tip extends MovieClip {
public var ok_button:SimpleButton;
public var message:TextField;
}
}//package
Section 261
//XmlSettings (XmlSettings)
package {
public class XmlSettings {
public static const string_table:XML = <table lang="en">
<string alias="firstTime_halfTime" rus="Не забывай про таймер, он показывает, сколько время у тебя осталось." en="Do not forget about the timer, it shows how much time you have."/>
<string alias="firstTime_bomb" rus="Сделай совпадение бомбы с двумя или более фигурами того же цвета, и она взорвётся. Бомба даётся за каждое совпадение 5 фигур буквой 'L'." en="If two or more figures of the same color match with the bomb it will explode.
Five figures match in the form of letter “L” brings the bonus Bomb."/>
<string alias="firstTime_lightning" rus="Совпадение молнии с фигурами того же цвета очистит несколько клеточек на поле. Молния даётся за каждое совпадение 5 фигур буквой 'T'." en="Combine the lightening with two or more figures of the same color to clear several cells on the field.
Collect 5 identical figures in the form of letter “T” to get the bonus “Lightening”"/>
<string alias="firstTime_dynamite" rus="Для того, чтобы взорвать динамит, сделай совпадение динамита с двумя или более фигурами того же цвета. Динамит ты получишь за combo 5x и больше." en="To explode the dynamite combine it with two or more figures of the same color.
Combo 5x or more gives this bonus."/>
<string alias="firstTime_clock" rus="Сделай совпадение часов с двумя или более фигурами того же цвета, и ты получишь дополнительное время. Часы даются за каждое совпадение 5 фигур в линию." en="If two or more figures of the same color match with the clock you get additional time.
The bonus clock appears for 5 figures match in line. "/>
<string alias="firstTime_blackFigure" rus="Эти фигуры не исчезают, даже если их собрать 3 или больше в ряд." en="These figures do not disappear even if you collect those 3 or more in line."/>
<string alias="firstTime_chain" rus="Разбей цепь, сделав совпадение с фигурой под ней." en="Match with the figure under chain to destroy the chain."/>
<string alias="firstTime_doubleChain" rus="Разбей двойную цепь, сделав 2 совпадения с фигурой под ней." en="To destroy the double chain make two matches under it."/>
<string alias="firstTime_doubleStone" rus="Чтобы очистить поле от таких плит, надо сделать 2 совпадения фигур над ней." en="To clean the field from the slab make two matches under it."/>
<string alias="askConfirm_restartLevel" rus="Уверены, что хотите перезапустить урвень?" en="
Are you sure you wish to restart the level? "/>
<string alias="askConfirm_abortGame" rus="Уверены, что хотите прервать игру?" en="
Are you sure you want to abort?"/>
<string alias="gameComplete_message" rus="Поздравляем! Вы прошли все уровни!
Хочешь больше уровней?
Загрузи advanced-версию." en="Congratulations! You passed all levels available in this version.
Do you wish more?
Download the advanced version please."/>
<string alias="timeOut_message" rus="У вас закончилось время! Попробуйте пройти уровень ещё раз." en="Your time is over.
Try to pass the level again."/>
<string alias="level_points" rus="Заработано очков: " en="Level score: "/>
<string alias="timeLeft_points" rus="Очков за время: " en="Time bonus score: "/>
<string alias="total_score" rus="Всего очков: " en="Total Score: "/>
<string alias="levelComplete_message" rus="Уровень пройден!" en="Level complete!"/>
<string alias="download_contextMenuName" rus="Download advanced version" en="Download advanced version"/>
<string alias="loading" rus="загрузка... " en="Loading..."/>
<string alias="clock_unit" rus="сек." en="sec."/>
<string alias="no_moves" rus="Ходов больше нет. Сейчас фигуры будут перемешаны." en="No more moves, the figures will be mixed now."/>
</table>
;
public static const settings:XML = <settings>
<debug>false</debug>
<cell_size>40.0</cell_size>
<volume>0.7</volume>
<figure_velocity>10.0</figure_velocity>
<!-- кол-во комбо для того, чтобы выпал динамит -->
<dynamite_combo>6</dynamite_combo>
<!-- кол-во клеток, уничтожаемых молнией -->
<lightning_cells>7</lightning_cells>
<!-- кол-во клеток в рандомной анимации -->
<random_cell>1</random_cell>
<!-- кол-во секунд за бонус часы -->
<clock>60</clock>
<hintTimer_interval>5000</hintTimer_interval>
<!-- preloader -->
<preloader_text_x>101</preloader_text_x>
<preloader_text_y>470</preloader_text_y>
<preloader_progressbar_x>101</preloader_progressbar_x>
<preloader_progressbar_y>510</preloader_progressbar_y>
<!-- скрость возрастания альфы вначале уровне -->
<showAlpha_velosity>0.1</showAlpha_velosity>
<!-- количество клеток(фигур, цепей и т.д.), которое появляется за один кадр, вначале уровне -->
<numberCells_perFrame>3</numberCells_perFrame>
<!-- количество очков, которое дается за секунду оставшегося времени -->
<numberPoints_forSecond>10</numberPoints_forSecond>
<download_link>http://www.gameglade.com/onlinegames/ancientjewels/</download_link>
<more_games_link>http://www.gameglade.com/</more_games_link>
<levels>
<default_level row_count="11" col_count="13" num_figures="5" black_part="0">
<!--back location="file">res/back.jpg</back-->
<back location="library">Back</back>
</default_level>
<level time="300"> // level 01
<map type="text">
0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 1 1 1 1 1 0 0 0 0
0 0 0 1 1 1 1 1 1 1 0 0 0
0 0 1 1 1 2 1 2 1 1 1 0 0
0 0 1 1 2 1 2 1 2 1 1 0 0
0 0 1 1 2 2 2 2 2 1 1 0 0
0 0 1 1 1 1 1 1 1 1 1 0 0
0 0 0 1 1 1 0 1 1 1 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0
</map>
// <!--map type="file">res/maps/map001.map</map-->
</level>
<level time="300"> // level 02
<map type="text">
0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 1 1 1 1 1 1 1 0 0 0
0 0 1 1 1 2 2 2 1 1 1 0 0
0 1 1 1 2 1 2 1 2 1 1 1 0
1 1 1 2 2 2 0 2 2 2 1 1 1
1 1 2 1 2 1 2 1 2 1 2 1 1
0 1 1 1 1 2 2 2 1 1 1 1 0
0 0 0 1 1 1 1 1 1 1 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0
</map>
<bonus>bomb</bonus>
</level>
<level time="300"> // level 03
<map type="text">
0 0 0 0 0 1 1 1 0 0 0 0 0
0 0 0 0 1 1 2 1 1 0 0 0 0
0 0 0 1 1 2 2 2 1 1 0 0 0
0 0 1 1 2 2 2 2 2 1 1 0 0
0 1 1 2 2 2 2 2 2 2 1 1 0
0 0 0 0 0 0 4 0 0 0 0 0 0
0 0 0 0 0 1 1 1 0 0 0 0 0
0 0 0 0 1 1 2 1 1 0 0 0 0
0 0 0 1 1 2 2 2 1 1 0 0 0
0 0 1 2 2 2 2 2 2 2 1 0 0
0 1 1 1 2 2 2 2 2 1 1 1 0
</map>
<bonus>bomb</bonus>
</level>
<level time="300"> // level 04
<map type="text">
0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 1 1 1 1 1 1 1 1 0 0 0
0 1 1 1 1 2 2 2 2 2 1 0 0
0 1 1 1 0 1 0 2 2 2 2 1 0
0 1 1 0 1 0 2 2 2 2 2 2 0
0 1 0 1 0 2 2 2 2 2 2 2 0
0 1 2 2 2 2 2 2 2 2 2 2 0
0 1 2 2 2 2 2 2 2 2 2 2 0
0 0 1 2 2 2 2 2 2 2 2 1 0
0 0 0 1 2 2 2 2 2 2 1 1 0
0 0 0 0 0 0 0 0 0 0 0 0 0
</map>
<bonus>bomb clock</bonus>
</level>
<level time="300" num_figures="5" black_part="0"> // level 05
<map type="text">
0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 1 2 1 1 1 1 1 2 2 0 0
0 0 1 2 1 1 1 1 2 2 2 0 0
0 0 0 1 1 1 1 2 2 2 1 0 0
0 0 0 0 1 1 2 2 2 1 1 0 0
0 0 0 0 0 2 2 2 1 1 1 0 0
0 0 0 0 0 0 2 4 4 4 4 0 0
0 0 0 0 0 0 0 1 1 1 1 0 0
0 0 0 0 0 0 0 0 1 2 2 0 0
0 0 0 0 0 0 0 0 0 1 1 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0
</map>
<bonus>bomb clock</bonus>
</level>
<level time="360" num_figures="5" black_part="0"> // level 06
<map type="text">
0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 1 1 1 1 0 1 1 1 1 0 0
0 0 1 1 1 1 0 1 1 1 1 0 0
0 1 1 1 1 1 0 1 1 1 1 1 0
0 1 1 1 1 1 0 1 1 1 1 1 0
0 1 1 1 1 1 0 1 1 1 1 1 0
0 6 6 6 6 6 0 6 6 6 6 6 0
0 1 1 1 1 1 0 1 1 1 1 1 0
0 0 3 3 3 3 0 3 3 3 3 0 0
0 0 1 1 1 1 0 1 1 1 1 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0
</map>
<bonus>bomb clock dynamite</bonus>
</level>
<level time="360" num_figures="5" black_part="0"> // level 07
<map type="text">
0 0 0 1 1 2 2 2 1 1 0 0 0
0 0 1 2 2 2 2 2 2 2 1 0 0
0 0 1 2 2 2 2 2 2 2 1 0 0
0 1 2 2 2 2 2 2 2 2 2 1 0
0 1 1 1 1 0 1 0 1 1 1 1 0
0 0 0 4 4 1 0 1 4 4 0 0 0
0 0 1 2 2 1 3 1 2 2 1 0 0
0 1 2 2 2 3 3 3 2 2 2 1 0
0 0 1 2 2 2 2 2 2 2 1 0 0
0 0 0 1 2 2 2 2 2 1 0 0 0
0 0 0 0 1 2 2 2 1 0 0 0 0
</map>
<bonus>bomb clock dynamite</bonus>
</level>
<level time="360" num_figures="5" black_part="0"> // level 08
<map type="text">
0 0 0 0 0 1 1 1 0 0 0 0 0
0 0 0 1 1 2 2 2 1 1 0 0 0
0 0 1 1 2 2 2 2 2 1 1 0 0
0 0 1 1 2 2 2 2 2 1 1 0 0
0 0 1 1 2 2 2 2 2 1 1 0 0
0 1 1 2 6 6 6 6 6 2 1 1 0
0 1 2 2 3 3 3 3 3 2 2 1 0
0 1 1 2 1 1 1 1 1 2 1 1 0
0 2 2 1 2 2 2 2 2 1 2 2 0
0 1 1 1 1 2 2 2 1 1 1 1 0
0 1 1 0 1 1 0 1 1 0 1 1 0
</map>
<bonus>bomb clock dynamite</bonus>
</level>
<level time="360" num_figures="5" black_part="0"> // level 09
<map type="text">
1 1 0 0 0 0 0 0 0 0 0 1 1
0 1 1 1 1 0 0 0 1 1 1 1 0
0 1 1 1 1 1 1 1 1 1 1 1 0
0 0 2 2 2 2 2 2 2 2 2 0 0
1 0 0 1 1 1 1 1 1 1 0 0 1
1 1 0 0 2 2 2 2 2 0 0 1 1
1 2 2 0 0 3 3 3 0 0 2 2 1
1 1 2 2 0 0 0 0 0 2 2 1 1
1 1 2 2 2 1 1 1 2 2 2 1 1
0 1 1 1 2 2 2 2 2 1 1 1 0
0 0 1 2 1 1 1 1 1 2 1 0 0
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="360" num_figures="5" black_part="0"> // level 10
<map type="text">
1 0 0 0 0 0 0 0 0 0 0 0 1
0 2 2 2 2 2 2 2 2 2 2 2 0
0 2 1 1 1 1 1 1 1 1 1 2 0
0 2 1 2 2 2 2 2 2 2 1 2 0
0 2 1 2 0 2 2 2 0 2 1 2 0
0 2 1 2 2 0 0 0 2 2 1 2 0
0 2 1 2 0 2 2 2 0 2 1 2 0
0 2 1 2 2 2 2 2 2 2 1 2 0
0 2 1 1 1 1 1 1 1 1 1 2 0
0 2 2 2 2 2 2 2 2 2 2 2 0
1 0 0 0 0 0 0 0 0 0 0 0 1
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="420" num_figures="5" black_part="0"> // level 11
<map type="text">
0 1 1 1 2 2 2 2 2 1 1 1 0
1 1 2 2 2 2 2 2 2 2 2 1 1
1 2 2 2 2 2 2 2 2 2 2 2 1
1 1 2 2 2 2 2 2 2 2 2 1 1
0 1 2 2 2 2 2 2 2 2 2 1 0
0 0 4 0 4 0 5 0 4 0 4 0 0
0 1 2 2 2 2 2 2 2 2 2 1 0
1 1 2 2 2 2 2 2 2 2 2 1 1
1 2 2 2 2 2 2 2 2 2 2 2 1
1 1 2 2 2 2 2 2 2 2 2 1 1
0 1 1 1 2 2 2 2 2 1 1 1 0
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="420" num_figures="5" black_part="0"> // level 12
<map type="text">
2 2 2 1 1 0 1 0 1 1 2 2 2
2 3 2 1 0 2 2 2 0 1 2 3 2
2 2 2 0 2 2 2 2 2 0 2 2 2
1 1 0 2 2 2 3 2 2 2 0 1 1
1 0 2 2 2 3 3 3 2 2 2 0 1
0 1 2 2 3 3 3 3 3 2 2 1 0
0 0 2 2 2 3 3 3 2 2 2 0 0
0 0 0 2 2 2 3 2 2 2 0 0 0
0 0 0 0 2 2 2 2 2 0 0 0 0
0 0 0 0 0 2 2 2 0 0 0 0 0
0 0 0 0 0 0 1 0 0 0 0 0 0
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="420" num_figures="5" black_part="0"> // level 13
<map type="text">
0 1 1 0 1 2 2 2 1 0 1 1 0
2 2 2 2 3 3 2 3 3 2 2 2 2
2 2 2 2 3 2 2 2 3 2 2 2 2
1 1 4 0 4 1 2 1 4 0 4 1 1
1 4 0 1 0 1 2 1 0 1 0 4 1
0 0 1 1 0 1 2 1 0 1 1 0 0
0 1 2 2 0 1 2 1 0 2 2 1 0
1 2 2 2 0 2 2 2 0 2 2 2 1
2 2 2 2 2 2 2 2 2 2 2 2 2
2 3 3 2 2 2 2 2 2 2 3 3 2
2 2 2 2 3 3 3 3 3 2 2 2 2
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="420" num_figures="5" black_part="0"> // level 14
<map type="text">
0 0 0 2 2 2 2 2 2 2 0 0 0
0 2 2 2 1 1 1 1 1 2 2 2 0
2 2 2 2 2 1 1 1 2 2 2 2 2
2 2 3 2 3 2 3 2 3 2 3 2 2
2 2 2 2 2 2 0 2 2 2 2 2 2
5 5 5 1 1 0 1 0 1 1 5 5 5
2 2 2 2 1 0 1 0 1 2 2 2 2
2 3 2 1 0 1 1 1 0 1 2 3 2
2 2 2 1 1 2 1 2 1 1 2 2 2
1 1 1 2 2 2 3 2 2 2 1 1 1
1 0 2 2 2 2 2 2 2 2 2 0 1
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="480" num_figures="6" black_part="0"> // level 15
<map type="text">
0 0 0 0 1 1 1 1 1 1 1 1 1
0 0 1 1 2 3 3 3 2 2 2 2 1
0 1 2 2 9 2 2 2 3 2 2 2 1
0 1 2 9 2 2 0 2 3 2 2 1 0
1 2 3 2 2 0 2 2 3 2 2 1 0
1 3 2 2 0 2 2 9 2 2 1 0 0
1 3 2 0 2 2 9 2 2 2 1 0 0
1 3 2 2 2 3 2 2 2 1 0 0 0
1 2 3 3 3 2 2 1 1 0 0 0 0
1 2 2 2 2 1 1 0 0 0 0 0 0
1 1 1 1 1 0 0 0 0 0 0 0 0
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="480" num_figures="6" black_part="0"> // level 16
<map type="text">
1 1 1 1 1 0 1 1 1 1 1 0 0
1 2 2 2 1 0 1 2 2 2 1 0 0
1 3 3 3 1 0 1 2 2 2 1 1 1
1 3 3 3 1 0 1 2 2 2 2 2 1
1 3 3 3 1 0 0 1 6 6 6 6 6
1 2 2 2 1 0 0 0 1 2 2 2 1
6 6 6 6 6 1 0 0 1 3 3 3 1
1 2 2 2 2 2 1 0 1 3 3 3 1
1 1 1 2 2 2 1 0 1 3 3 3 1
0 0 1 2 2 2 1 0 1 2 2 2 1
0 0 1 1 1 1 1 0 1 1 1 1 1
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="480" num_figures="6" black_part="0"> // level 17
<map type="text">
1 1 1 1 0 1 1 1 0 1 1 1 1
1 2 2 1 0 1 1 1 0 1 2 2 1
1 2 2 1 0 1 1 1 0 1 2 2 1
2 2 2 2 0 1 2 1 0 2 2 2 2
2 3 3 2 0 2 2 2 0 2 3 3 2
2 3 3 2 0 2 2 2 0 2 3 3 2
2 3 3 2 2 2 2 2 2 2 3 3 2
2 3 3 2 2 2 2 2 2 2 3 3 2
2 3 3 2 2 2 2 2 2 2 3 3 2
2 2 2 2 1 2 2 2 1 2 3 3 2
1 1 1 1 0 1 1 1 0 1 1 1 1
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="540" num_figures="6" black_part="0"> // level 18
<map type="text">
0 2 1 1 1 1 1 1 1 1 1 2 0
2 1 2 1 1 1 1 1 1 1 2 1 2
1 2 1 1 2 2 2 2 2 1 1 2 1
1 1 1 2 2 0 1 0 2 2 1 1 1
1 1 1 2 0 2 3 2 0 2 1 1 1
0 1 2 2 1 3 3 3 1 2 2 1 0
1 1 1 2 0 2 3 2 0 2 1 1 1
1 1 1 2 2 0 1 0 2 2 1 1 1
1 2 1 1 2 2 2 2 2 1 1 2 1
2 1 2 1 1 1 1 1 1 1 2 1 2
0 2 1 1 1 1 1 1 1 1 1 2 0
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="540" num_figures="6" black_part="0"> // level 19
<map type="text">
1 2 2 2 2 2 2 2 2 2 2 2 1
2 2 2 2 2 2 2 2 2 2 2 2 2
1 2 2 2 2 2 2 2 2 2 2 2 1
0 1 0 1 0 1 0 1 0 1 0 1 0
0 0 1 0 1 0 1 0 1 0 1 0 0
0 1 2 2 2 2 2 2 2 2 2 1 0
0 2 2 3 3 3 3 3 3 3 2 2 0
0 2 2 3 3 3 3 3 3 3 2 2 0
0 1 2 3 3 3 9 3 3 3 2 1 0
0 0 1 2 3 3 3 3 3 2 1 0 0
0 0 0 1 2 2 2 2 2 1 0 0 0
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
<level time="540" num_figures="6" black_part="0"> // level 20
<map type="text">
1 0 2 2 2 2 2 2 2 2 2 2 1
0 2 1 1 1 1 1 1 1 1 1 2 1
2 1 1 3 2 1 1 1 2 2 2 2 2
2 1 3 1 1 2 2 2 2 0 3 2 2
2 1 2 1 2 2 0 1 0 2 2 2 2
2 1 1 2 7 0 1 0 7 1 1 1 2
2 1 2 2 0 1 0 2 1 1 2 2 2
2 1 2 0 2 2 2 1 1 3 3 1 2
2 1 2 3 2 2 2 2 3 3 1 1 2
2 2 2 2 2 2 2 2 2 2 2 2 0
1 1 1 2 2 2 2 2 2 1 1 0 1
</map>
<bonus>bomb clock dynamite lightning</bonus>
</level>
</levels>
</settings>
;
}
}//package
Section 262
//YesNo_Window (YesNo_Window)
package {
import flash.display.*;
import flash.text.*;
public dynamic class YesNo_Window extends MovieClip {
public var ok_button:SimpleButton;
public var message:TextField;
public var cancel_button:SimpleButton;
}
}//package