Section 1
//adddecorations_307 (_fla.adddecorations_307)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class adddecorations_307 extends MovieClip {
public function adddecorations_307(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 2
//addpatterns_305 (_fla.addpatterns_305)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class addpatterns_305 extends MovieClip {
public function addpatterns_305(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 3
//addrings_318 (_fla.addrings_318)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class addrings_318 extends MovieClip {
public function addrings_318(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 4
//addScoreMotion_278 (_fla.addScoreMotion_278)
package _fla {
import flash.display.*;
public dynamic class addScoreMotion_278 extends MovieClip {
public var goal_mc:MovieClip;
public function addScoreMotion_278(){
addFrameScript(0, frame1);
}
function frame1(){
this.mouseEnabled = false;
this.mouseChildren = false;
}
}
}//package _fla
Section 5
//angry1_210 (_fla.angry1_210)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class angry1_210 extends MovieClip {
public function angry1_210(){
addFrameScript(12, frame13);
}
function frame13(){
stop();
MovieClip(root).hideCSer(this.parent.parent);
}
}
}//package _fla
Section 6
//angry2_239 (_fla.angry2_239)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class angry2_239 extends MovieClip {
public function angry2_239(){
addFrameScript(16, frame17);
}
function frame17(){
stop();
MovieClip(root).hideCSer(this.parent.parent);
}
}
}//package _fla
Section 7
//angry3_266 (_fla.angry3_266)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class angry3_266 extends MovieClip {
public function angry3_266(){
addFrameScript(16, frame17);
}
function frame17(){
stop();
MovieClip(root).hideCSer(this.parent.parent);
}
}
}//package _fla
Section 8
//biaoti_55 (_fla.biaoti_55)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class biaoti_55 extends MovieClip {
public function biaoti_55(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 9
//blow_btnmc_408 (_fla.blow_btnmc_408)
package _fla {
import flash.display.*;
public dynamic class blow_btnmc_408 extends MovieClip {
public var blow_btn:SimpleButton;
public function blow_btnmc_408(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package _fla
Section 10
//bonus_302 (_fla.bonus_302)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class bonus_302 extends MovieClip {
public function bonus_302(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 11
//bsdf_84 (_fla.bsdf_84)
package _fla {
import flash.display.*;
public dynamic class bsdf_84 extends MovieClip {
public var door_mc:MovieClip;
public var in_mc:MovieClip;
}
}//package _fla
Section 12
//congratulation_283 (_fla.congratulation_283)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class congratulation_283 extends MovieClip {
public function congratulation_283(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 13
//cry1_189 (_fla.cry1_189)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class cry1_189 extends MovieClip {
public function cry1_189(){
addFrameScript(21, frame22);
}
function frame22(){
stop();
MovieClip(root).hideCSer(this.parent.parent);
}
}
}//package _fla
Section 14
//cry2_233 (_fla.cry2_233)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class cry2_233 extends MovieClip {
public function cry2_233(){
addFrameScript(18, frame19);
}
function frame19(){
stop();
MovieClip(root).hideCSer(this.parent.parent);
}
}
}//package _fla
Section 15
//cry3_257 (_fla.cry3_257)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class cry3_257 extends MovieClip {
public function cry3_257(){
addFrameScript(16, frame17);
}
function frame17(){
stop();
MovieClip(root).hideCSer(this.parent.parent);
}
}
}//package _fla
Section 16
//fackbook_mc_70 (_fla.fackbook_mc_70)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.net.*;
public dynamic class fackbook_mc_70 extends MovieClip {
public var logo_btn:SimpleButton;
public function fackbook_mc_70(){
addFrameScript(0, frame1);
}
function frame1(){
logo_btn.addEventListener(MouseEvent.CLICK, linkHandler);
}
public function linkHandler(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.facebook.com/igirlsgamesfans"), "_blank");
}
}
}//package _fla
Section 17
//gola_117 (_fla.gola_117)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class gola_117 extends MovieClip {
public function gola_117(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 18
//goodjob_295 (_fla.goodjob_295)
package _fla {
import flash.display.*;
public dynamic class goodjob_295 extends MovieClip {
public var score_mc:MovieClip;
public var nextLevel_btn:SimpleButton;
public var bonus_mc:MovieClip;
public var tscore_mc:MovieClip;
}
}//package _fla
Section 19
//goodjobzm_301 (_fla.goodjobzm_301)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class goodjobzm_301 extends MovieClip {
public function goodjobzm_301(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 20
//hand_331 (_fla.hand_331)
package _fla {
import flash.display.*;
public dynamic class hand_331 extends MovieClip {
public var ringh_3:MovieClip;
public var ring_2:MovieClip;
public var ring_3:MovieClip;
public var ringh_2:MovieClip;
public var nail_1:MovieClip;
public var nail_5:MovieClip;
public var nail_2:MovieClip;
public var nail_4:MovieClip;
public var nail_3:MovieClip;
public var ring_4:MovieClip;
public var ringh_4:MovieClip;
}
}//package _fla
Section 21
//helptxtzm_81 (_fla.helptxtzm_81)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class helptxtzm_81 extends MovieClip {
public function helptxtzm_81(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 22
//helpzmsdf_75 (_fla.helpzmsdf_75)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class helpzmsdf_75 extends MovieClip {
public var 新建符号:MovieClip;
public var 新建符号_14:MovieClip;
public var 新建符号_16:MovieClip;
public var 新建符号_13:MovieClip;
public function helpzmsdf_75(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 23
//hono_292 (_fla.hono_292)
package _fla {
import flash.display.*;
public dynamic class hono_292 extends MovieClip {
public var replay_btn:SimpleButton;
public var score_mc:MovieClip;
public var tscore_mc:MovieClip;
}
}//package _fla
Section 24
//huawen_431 (_fla.huawen_431)
package _fla {
import flash.display.*;
public dynamic class huawen_431 extends MovieClip {
public var obj_9:MovieClip;
public var obj_4:MovieClip;
public var obj_3:MovieClip;
public var obj_1:MovieClip;
public var obj_5:MovieClip;
public var obj_6:MovieClip;
public var obj_7:MovieClip;
public var obj_2:MovieClip;
public var obj_8:MovieClip;
}
}//package _fla
Section 25
//iconlist_338 (_fla.iconlist_338)
package _fla {
import flash.display.*;
public dynamic class iconlist_338 extends MovieClip {
public var 新建符号_64:MovieClip;
public var 新建符号:MovieClip;
public var 新建符号_91:MovieClip;
public var 新建符号_16:MovieClip;
public var 新建符号_1:MovieClip;
public var 新建符号_25:MovieClip;
public var 新建符号_22:MovieClip;
}
}//package _fla
Section 26
//icons_433 (_fla.icons_433)
package _fla {
import flash.display.*;
public dynamic class icons_433 extends MovieClip {
public var obj_9:MovieClip;
public var obj_4:MovieClip;
public var obj_3:MovieClip;
public var obj_12:MovieClip;
public var obj_13:MovieClip;
public var obj_10:MovieClip;
public var obj_11:MovieClip;
public var obj_1:MovieClip;
public var obj_5:MovieClip;
public var obj_6:MovieClip;
public var obj_7:MovieClip;
public var obj_2:MovieClip;
public var obj_8:MovieClip;
}
}//package _fla
Section 27
//igirlsgames_loading_4 (_fla.igirlsgames_loading_4)
package _fla {
import flash.display.*;
public dynamic class igirlsgames_loading_4 extends MovieClip {
public function igirlsgames_loading_4(){
addFrameScript(99, frame100);
}
function frame100(){
stop();
}
}
}//package _fla
Section 28
//igirlsgames_loading_6 (_fla.igirlsgames_loading_6)
package _fla {
import flash.display.*;
public dynamic class igirlsgames_loading_6 extends MovieClip {
public var k28:MovieClip;
public var k23:MovieClip;
public var k30:MovieClip;
public var k31:MovieClip;
public var k33:MovieClip;
public var k22:MovieClip;
public var k36:MovieClip;
public var k35:MovieClip;
public var k32:MovieClip;
public var k4:MovieClip;
public var k6:MovieClip;
public var k7:MovieClip;
public var k8:MovieClip;
public var k2:MovieClip;
public var k5:MovieClip;
public var k9:MovieClip;
public var k1:MovieClip;
public var k34:MovieClip;
public var k3:MovieClip;
public var k10:MovieClip;
public var k12:MovieClip;
public var k13:MovieClip;
public var k14:MovieClip;
public var k15:MovieClip;
public var k16:MovieClip;
public var k17:MovieClip;
public var k19:MovieClip;
public var k18:MovieClip;
public var k11:MovieClip;
public var k20:MovieClip;
public var k24:MovieClip;
public var k25:MovieClip;
public var k26:MovieClip;
public var k21:MovieClip;
public var k29:MovieClip;
public var k27:MovieClip;
}
}//package _fla
Section 29
//igirlsgames_loadingyj6_2 (_fla.igirlsgames_loadingyj6_2)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.net.*;
public dynamic class igirlsgames_loadingyj6_2 extends MovieClip {
public var logo_btn:SimpleButton;
public function igirlsgames_loadingyj6_2(){
addFrameScript(0, frame1);
}
function frame1(){
logo_btn.addEventListener(MouseEvent.CLICK, linkHandler);
}
public function linkHandler(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.igirlsgames.com"), "_blank");
}
}
}//package _fla
Section 30
//igirlsgames_logo_63 (_fla.igirlsgames_logo_63)
package _fla {
import flash.display.*;
public dynamic class igirlsgames_logo_63 extends MovieClip {
public function igirlsgames_logo_63(){
addFrameScript(142, frame143);
}
function frame143(){
gotoAndPlay(44);
}
}
}//package _fla
Section 31
//igirlsgames_logo_65 (_fla.igirlsgames_logo_65)
package _fla {
import flash.display.*;
public dynamic class igirlsgames_logo_65 extends MovieClip {
public function igirlsgames_logo_65(){
addFrameScript(7, frame8);
}
function frame8(){
stop();
}
}
}//package _fla
Section 32
//igirlsgames_logo_67 (_fla.igirlsgames_logo_67)
package _fla {
import flash.display.*;
public dynamic class igirlsgames_logo_67 extends MovieClip {
public function igirlsgames_logo_67(){
addFrameScript(7, frame8);
}
function frame8(){
stop();
}
}
}//package _fla
Section 33
//igirlsgames_logo_mc_58 (_fla.igirlsgames_logo_mc_58)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.net.*;
public dynamic class igirlsgames_logo_mc_58 extends MovieClip {
public var logo_btn:SimpleButton;
public function igirlsgames_logo_mc_58(){
addFrameScript(0, frame1);
}
function frame1(){
logo_btn.addEventListener(MouseEvent.CLICK, linkHandler);
}
public function linkHandler(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.igirlsgames.com/gentle-princess-dress-up.html"), "_blank");
}
}
}//package _fla
Section 34
//igirlsgamesload_mc_1 (_fla.igirlsgamesload_mc_1)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class igirlsgamesload_mc_1 extends MovieClip {
public var loading:MovieClip;
public var a;
public var percent_mc:MovieClip;
public var play_btn:SimpleButton;
public function igirlsgamesload_mc_1(){
addFrameScript(0, frame1, 1, frame2);
}
public function enterFrameHandler(_arg1:Event):void{
var _local2:Number;
var _local3:*;
_local2 = int(((root.loaderInfo.bytesLoaded / root.loaderInfo.bytesTotal) * 100));
if (percent_mc.currentFrame < _local2){
percent_mc.play();
} else {
percent_mc.stop();
};
_local3 = 1;
while (_local3 <= 36) {
if (_local3 <= Math.ceil(((percent_mc.currentFrame * 36) / 100))){
loading[("k" + _local3)].visible = true;
};
_local3++;
};
if (((loading.k36.visible) && ((percent_mc.currentFrame >= 100)))){
this.removeEventListener(Event.ENTER_FRAME, enterFrameHandler);
goNext();
};
}
function frame1(){
stop();
a = 1;
while (a <= 36) {
loading[("k" + a)].gotoAndStop(a);
loading[("k" + a)].visible = false;
a++;
};
this.addEventListener(Event.ENTER_FRAME, enterFrameHandler);
}
public function playHandler(_arg1:MouseEvent):void{
play_btn.removeEventListener(MouseEvent.CLICK, playHandler);
MovieClip(root).play();
}
function frame2(){
stop();
play_btn.addEventListener(MouseEvent.CLICK, playHandler);
}
public function goNext():void{
this.play();
}
}
}//package _fla
Section 35
//in_90 (_fla.in_90)
package _fla {
import flash.display.*;
public dynamic class in_90 extends MovieClip {
public function in_90(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package _fla
Section 36
//level_119 (_fla.level_119)
package _fla {
import flash.display.*;
public dynamic class level_119 extends MovieClip {
public var prize_mc:MovieClip;
public var level_mc:MovieClip;
public var bg_mc:MovieClip;
}
}//package _fla
Section 37
//levelnum_123 (_fla.levelnum_123)
package _fla {
import flash.display.*;
public dynamic class levelnum_123 extends MovieClip {
public var bit_1:MovieClip;
public var bit_2:MovieClip;
}
}//package _fla
Section 38
//levelzm_116 (_fla.levelzm_116)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class levelzm_116 extends MovieClip {
public function levelzm_116(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 39
//MainTimeline (_fla.MainTimeline)
package _fla {
import cuitenail.vo.*;
import flash.display.*;
import gs.*;
import flash.events.*;
import mochi.as3.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import gs.easing.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class MainTimeline extends MovieClip {
public var moreGameBtn:SimpleButton;
public var p_1:MovieClip;
public var p_2:MovieClip;
public var p_3:MovieClip;
public var cs_4:MovieClip;
public var cs_5:MovieClip;
public var cs_6:MovieClip;
public var cs_7:MovieClip;
public var cs_8:MovieClip;
public var cs_3:MovieClip;
public var p_4:MovieClip;
public var cs_9:MovieClip;
public var cs_1:MovieClip;
public var cs_2:MovieClip;
public var sample_mc:MovieClip;
public var help_btn:SimpleButton;
public var cs_blow_mc:MovieClip;
public var waitress_2:MovieClip;
public var waitress_3:MovieClip;
public var pause_mc:MovieClip;
public var maxLevel:int;
public var sampleData:Object;
public var waitress_1:MovieClip;
public var pass_mc:MovieClip;
public var pause_btn:SimpleButton;
public var csResult:Object;
public var pt_2:MovieClip;
public var pt_3:MovieClip;
public var pt_4:MovieClip;
public var pt_5:MovieClip;
public var pt_6:MovieClip;
public var levelup_mc:MovieClip;
public var pt_9:MovieClip;
public var pt_8:MovieClip;
public var pt_1:MovieClip;
public var pt_7:MovieClip;
public var maxCS:int;
public var win_mc:MovieClip;
public var prizeArr:Array;
public var lv_11:MovieClip;
public var lv_13:MovieClip;
public var lv_15:MovieClip;
public var lv_12:MovieClip;
public var lv_14:MovieClip;
public var selectedID:int;
public var isOver:Boolean;
public var efChannel:SoundChannel;
public var ppt_1:MovieClip;
public var ppt_3:MovieClip;
public var ppt_4:MovieClip;
public var ppt_2:MovieClip;
public var cs_ring_mc:MovieClip;
public var blow_mc:MovieClip;
public var lv_10:MovieClip;
public var isStart:Boolean;
public var lvMaxCS:int;
public var levelScore:int;
public var arrow_1:MovieClip;
public var arrow_2:MovieClip;
public var arrow_3:MovieClip;
public var arrow_4:MovieClip;
public var arrow_5:MovieClip;
public var arrow_7:MovieClip;
public var arrow_8:MovieClip;
public var arrow_6:MovieClip;
public var arrow_9:MovieClip;
public var levelNum_mc:MovieClip;
public var nt:int;
public var selectedCursor:int;
public var cs_oil_mc:MovieClip;
public var MOREGAME_URI:String;
public var idleArr:Array;
public var lang:String;
public var gameSetting:Array;
public var bbg_2:MovieClip;
public var bbg_3:MovieClip;
public var bbg_4:MovieClip;
public var bbg_1:MovieClip;
public var show_btn:SimpleButton;
public var play2_btn:SimpleButton;
public var addScore_mc:MovieClip;
public var pauseOffset:int;
public var selMker:int;
public var goal_mc:MovieClip;
public var fail_mc:MovieClip;
public var cs_icon_mc:MovieClip;
public var w_mc:MovieClip;
public var score_mc:MovieClip;
public var isBlowing:Boolean;
public var 新建符号_14:MovieClip;
public var wrongNum:int;
public var score:int;
public var lv_2:MovieClip;
public var lv_3:MovieClip;
public var lv_4:MovieClip;
public var lv_6:MovieClip;
public var lv_7:MovieClip;
public var lv_8:MovieClip;
public var lv_9:MovieClip;
public var lv_5:MovieClip;
public var lv_1:MovieClip;
public var play_btn:SimpleButton;
public var efSd:Sound;
public var winshow_mc:MovieClip;
public var gameData:Object;
public var isPause:Boolean;
public var interID:int;
public var goal:int;
public var nextCSID:int;
public var lastCreateCS:int;
public var cursor_mc:MovieClip;
public var isShow:Boolean;
public var 新建符号_1:MovieClip;
public var createCSInterval:int;
public var hand_mc:MovieClip;
public var reset_btn:SimpleButton;
public var order_1:MovieClip;
public var order_2:MovieClip;
public var order_3:MovieClip;
public var order_4:MovieClip;
public var level:int;
public var load_mc:MovieClip;
public var b_1:SimpleButton;
public var b_2:SimpleButton;
public var b_4:SimpleButton;
public var b_3:SimpleButton;
public var cursorType:String;
public var exit_btn:SimpleButton;
public var highscore_btn:SimpleButton;
public var bg_mc:MovieClip;
public var cs_pattern_mc:MovieClip;
public var canStop:Boolean;
public function MainTimeline(){
addFrameScript(0, frame1, 1, frame2, 2, frame3, 3, frame4, 4, frame5);
}
public function checkNailBlow():void{
var _local1:MovieClip;
var _local2:int;
var _local3:int;
if (!hand_mc){
return;
};
_local3 = 1;
while (_local3 <= 5) {
_local1 = hand_mc[("nail_" + _local3)];
if ((((((int(gameData.oil[_local3]) >= 1)) && (cs_blow_mc.hit_mc))) && (_local1.hitTestObject(cs_blow_mc.hit_mc)))){
_local2 = gameData.blowed[_local3];
_local2 = (_local2 + 20);
_local2 = Math.min(100, _local2);
gameData.blowed[_local3] = _local2;
_local1.light_mc.alpha = (_local2 / 100);
};
_local3++;
};
}
public function submitHandler(_arg1:MouseEvent):void{
var o:Object;
var boardID:String;
var e = _arg1;
o = {n:[4, 2, 0, 1, 12, 1, 5, 9, 12, 6, 10, 11, 14, 7, 4, 5], f:function (_arg1:Number, _arg2:String):String{
if (_arg2.length == 16){
return (_arg2);
};
return (this.f((_arg1 + 1), (_arg2 + this.n[_arg1].toString(16))));
}};
boardID = o.f(0, "");
MochiScores.showLeaderboard({boardID:boardID, score:score, onClose:function (){
}});
}
public function initLittle(_arg1:MovieClip, _arg2:int):void{
if (_arg1.parent == p_1){
_arg1.hat_mc.visible = true;
_arg1.oil_mc.gotoAndStop(_arg2);
} else {
_arg1.gotoAndStop(_arg2);
};
_arg1.buttonMode = true;
_arg1.mouseChildren = false;
_arg1.addEventListener(MouseEvent.ROLL_OVER, itemOver);
_arg1.addEventListener(MouseEvent.ROLL_OUT, itemOut);
_arg1.addEventListener(MouseEvent.MOUSE_DOWN, littleDown);
if (_arg1.parent.name == "p_1"){
if ((((_arg2 == 3)) && ((level < 5)))){
_arg1.visible = false;
};
if ((((_arg2 == 8)) && ((level < 10)))){
_arg1.visible = false;
};
};
}
public function $(_arg1:MovieClip, _arg2:Function, _arg3:String, _arg4:String="", _arg5:int=1, _arg6:int=-1):void{
var _local7:InteractiveObject;
var _local8:int;
if (_arg6 != -1){
_local8 = _arg5;
while (_local8 <= _arg6) {
_local7 = (_arg1.getChildByName(((_arg3 + _local8) + _arg4)) as InteractiveObject);
_arg2.apply(null, [_local7, _local8]);
_local8++;
};
} else {
_local8 = _arg5;
while ((_local7 = (_arg1.getChildByName(((_arg3 + _local8) + _arg4)) as InteractiveObject))) {
_arg2.apply(null, [_local7, _local8]);
_local8++;
};
};
}
public function init_uiEvent():void{
pause_btn.addEventListener(MouseEvent.CLICK, pauseHandler);
pass_mc.nextLevel_btn.addEventListener(MouseEvent.CLICK, nextLevelHandler);
win_mc.replay_btn.addEventListener(MouseEvent.CLICK, replayHandler);
win_mc.submit_btn.addEventListener(MouseEvent.CLICK, submitHandler);
fail_mc.replay_btn.addEventListener(MouseEvent.CLICK, retryHandler);
}
public function enable_obj(_arg1:InteractiveObject, _arg2:Boolean):void{
_arg1.mouseEnabled = _arg2;
if ((_arg1 is Sprite)){
(_arg1 as Sprite).buttonMode = _arg2;
};
}
public function cursorMove(_arg1:MouseEvent):void{
cursor_mc.x = stage.mouseX;
cursor_mc.y = stage.mouseY;
}
public function getIdle():int{
var _local1:Array;
var _local2:int;
_local1 = [];
if (lvMaxCS < 1){
return (0);
};
_local2 = 1;
while (_local2 <= maxCS) {
if (idleArr[_local2] == null){
_local1.push(_local2);
};
_local2++;
};
if (_local1.length == 0){
return (0);
};
_local1.sort(sortParam);
idleArr[_local1[0]] = CserVo.getInstance(nt);
idleArr[_local1[0]].id = _local1[0];
lvMaxCS--;
return (_local1[0]);
}
public function moreGameHandler(_arg1:MouseEvent):void{
navigateToURL(new URLRequest(MOREGAME_URI), "_blank");
}
public function exitHandler(_arg1:MouseEvent):void{
clear_help();
this.gotoAndStop("start");
}
function frame3(){
stop();
init_help();
}
function frame4(){
stop();
init_game();
}
function frame5(){
selMker = -1;
stop();
isShow = false;
init_mkBtn();
init_mk();
}
public function init_ui():void{
if (csResult.finished){
levelScore = (levelScore + csResult.money);
};
setDigital(levelNum_mc, "bit_", level, 2);
setDigital(goal_mc, "bit_", goal, 5);
setDigital(score_mc, "bit_", levelScore, 5);
$(this, init_lv_prize, "lv_");
}
public function backHandler(_arg1:MouseEvent):void{
setCursor("default");
clear_mkBtn();
this.gotoAndStop("hall");
}
public function rand(_arg1:int, _arg2:int):int{
return ((Math.floor((Math.random() * ((_arg2 - _arg1) + 1))) + _arg1));
}
function frame2(){
stop();
nextCSID = -1;
canStop = true;
idleArr = [];
wrongNum = 0;
maxCS = 9;
lvMaxCS = 3;
pauseOffset = 0;
lastCreateCS = 0;
level = 1;
maxLevel = 15;
goal = 0;
levelScore = 0;
score = 0;
prizeArr = [];
selectedID = -1;
selectedCursor = -1;
isStart = false;
isOver = false;
isPause = false;
isBlowing = false;
csResult = {isRight:false, finished:false, money:0, doed:0};
init_start();
}
public function init_start():void{
play_btn.addEventListener(MouseEvent.CLICK, playHandler);
help_btn.addEventListener(MouseEvent.CLICK, helpHandler);
highscore_btn.addEventListener(MouseEvent.CLICK, highscoreHandler);
moreGameBtn.addEventListener(MouseEvent.CLICK, moreGameHandler);
CserVo.waitLimit = (40 * 1000);
init_level();
}
public function showEf(_arg1:String):void{
var _local2:Class;
_local2 = (ApplicationDomain.currentDomain.getDefinition(_arg1) as Class);
efSd = (new (_local2) as Sound);
efChannel = efSd.play();
}
function frame1(){
MOREGAME_URI = "http://www.igirlsgames.com/ashleys-sunday-make-up.html";
cursorType = "default";
gameSetting = [undefined, {cs:3, goal:300}];
lang = "en";
MochiBot.track(this, "c3668470");
MochiServices.connect("e2d2743e7b80bf08", root);
stop();
}
public function pauseHandler(_arg1:MouseEvent):void{
pause_mc.showPause(true);
}
public function init_mker(){
$(this, initMkTool, "b_");
pause_btn.addEventListener(MouseEvent.CLICK, pauseHandler);
selectTool(1);
blow_mc.gotoAndStop(1);
blow_mc.addEventListener(MouseEvent.CLICK, blowHandler);
}
public function updateHall():void{
var _local1:int;
if (!cs_1){
return;
};
_local1 = 1;
while (_local1 <= maxCS) {
if (idleArr[_local1]){
this[("pt_" + _local1)].gotoAndStop(idleArr[_local1].pt);
if (idleArr[_local1].dead){
if (this[("cs_" + _local1)].motioning){
} else {
this[("cs_" + _local1)].motioning = true;
this[("waitress_" + Math.ceil((_local1 / 3)))].gotoAndStop(3);
this[("cs_" + _local1)].smile = "angry";
this[("cs_" + _local1)].init();
if (selectedID == _local1){
selectedID = -1;
};
enable_obj(this[("cs_" + _local1)], false);
};
};
};
_local1++;
};
}
public function get_lv_goal():int{
var _local1:Array;
_local1 = [undefined, 200, 400, 500, 600, 700, 900, 1100, 1200, 1300, 1400, 1500, 1600, 1700, 1800, 1900];
if (level < 6){
return (_local1[level]);
};
return (_local1[level]);
}
public function littleDown(_arg1:MouseEvent):void{
var _local2:int;
var _local3:int;
_local2 = get_id(_arg1.currentTarget.parent.name);
_local3 = get_id(_arg1.currentTarget.name);
switch (_local2){
case 1:
if ((((cursorType == "cs_oil")) && ((selectedCursor == _local3)))){
setCursor("default");
return;
};
cs_oil_mc.oil_mc.gotoAndStop(_local3);
setCursor("cs_oil", cs_oil_mc);
selectedCursor = _local3;
p_1[("obj_" + _local3)].hat_mc.visible = false;
break;
case 2:
if ((((cursorType == "cs_pattern")) && ((selectedCursor == _local3)))){
setCursor("default");
return;
};
cs_pattern_mc.gotoAndStop(_local3);
selectedCursor = _local3;
setCursor("cs_pattern", cs_pattern_mc);
break;
case 3:
if ((((cursorType == "cs_icon")) && ((selectedCursor == _local3)))){
setCursor("default");
return;
};
cs_icon_mc.gotoAndStop(_local3);
selectedCursor = _local3;
setCursor("cs_icon", cs_icon_mc);
break;
case 4:
if ((((cursorType == "cs_ring")) && ((selectedCursor == _local3)))){
setCursor("default");
return;
};
cs_ring_mc.gotoAndStop(_local3);
selectedCursor = _local3;
setCursor("cs_ring", cs_ring_mc);
break;
};
}
public function helpHandler(_arg1:MouseEvent):void{
clear_start();
this.gotoAndStop("help");
}
public function updateOrder2():void{
var _local1:Array;
var _local2:int;
var _local3:int;
var _local4:MovieClip;
if (!order_1){
return;
};
_local1 = [];
_local2 = 1;
while (_local2 <= maxCS) {
if (idleArr[_local2]){
_local1.push(idleArr[_local2]);
};
_local2++;
};
if (_local1.length){
_local1.sortOn("eclipseTime", (Array.NUMERIC | Array.DESCENDING));
};
_local3 = _local1.length;
_local2 = 1;
while ((((_local2 <= _local3)) && ((_local2 <= 4)))) {
_local4 = this[("order_" + _local2)];
if (((_local1[(_local2 - 1)].dead) && ((_local1[(_local2 - 1)].id == selectedID)))){
showHandler();
return;
};
if (((_local1[(_local2 - 1)].dead) && (!(_local4.motioning)))){
_local4.motioning = true;
_local4.smile = "angry";
if (_local4.currentFrame == _local1[(_local2 - 1)].roleID){
_local4.init();
};
};
if (!_local4.motioning){
_local4.gotoAndStop(_local1[(_local2 - 1)].roleID);
_local4.visible = true;
};
this[("ppt_" + _local2)].gotoAndStop(_local1[(_local2 - 1)].pt);
this[("ppt_" + _local2)].visible = true;
_local2++;
};
while (_local2 <= 4) {
this[("order_" + _local2)].gotoAndStop(1);
this[("order_" + _local2)].visible = false;
this[("ppt_" + _local2)].visible = false;
_local2++;
};
}
public function selectTool(_arg1:int):void{
if (selMker == _arg1){
return;
};
if (selMker > 0){
this[("bbg_" + selMker)].gotoAndStop(1);
this[("p_" + selMker)].visible = false;
};
selMker = _arg1;
if (selMker > 0){
this[("bbg_" + selMker)].gotoAndStop(2);
this[("p_" + selMker)].visible = true;
};
setCursor("default");
}
public function init_gamedata():void{
gameData = {blowed:[], overflow:[], oil:[], pattern:[], icon_1:[], icon_2:[], ring:[]};
}
public function goGame():void{
this.gotoAndStop("hall");
}
public function addLight(_arg1:MovieClip):void{
_arg1.lightData = {speed:1, blur:5, color:0xFFFFFF};
if (_arg1.hasOwnProperty("lightColor")){
_arg1.lightData.color = _arg1.lightColor;
};
_arg1.addEventListener(Event.ENTER_FRAME, lightHandler);
}
public function initIdle():void{
var _local1:int;
_local1 = 1;
while (_local1 <= maxCS) {
idleArr[_local1] = null;
_local1++;
};
}
public function init_help(){
play2_btn.addEventListener(MouseEvent.CLICK, play2Handler);
exit_btn.addEventListener(MouseEvent.CLICK, exitHandler);
}
public function nailClicked(_arg1:MouseEvent):void{
var _local2:MovieClip;
var _local3:int;
var _local4:int;
_local2 = (_arg1.currentTarget as MovieClip);
_local3 = get_id(_local2.name);
if (cursorType == "cs_oil"){
_local4 = int(gameData.icon_1[_local3]);
if (_local4 > 1){
return;
};
_local4 = int(gameData.icon_2[_local3]);
if (_local4 > 1){
return;
};
gameData.oil[_local3] = selectedCursor;
gameData.blowed[_local3] = 0;
_local2.light_mc.alpha = 0;
_local2.overflow_mc.visible = false;
_local2.oil_mc.gotoAndStop(selectedCursor);
_local2.overflow_mc.gotoAndStop(selectedCursor);
_local2.oil_mc.visible = true;
blow_mc.gotoAndStop(2);
} else {
if (cursorType == "cs_pattern"){
_local4 = int(gameData.oil[_local3]);
if (_local4 < 1){
return;
};
_local4 = int(gameData.blowed[_local3]);
if (_local4 > 90){
} else {
_local2.overflow_mc.visible = true;
};
gameData.pattern[_local3] = selectedCursor;
_local2.pattern_mc.gotoAndStop(selectedCursor);
_local2.pattern_mc.visible = true;
} else {
if (cursorType == "cs_icon"){
_local4 = gameData.oil[_local3];
if (_local4 < 1){
return;
};
_local4 = gameData.blowed[_local3];
if (_local4 > 90){
} else {
_local2.overflow_mc.visible = true;
};
if (_local2.mouseY < 0){
gameData.icon_1[_local3] = selectedCursor;
_local2.icon_1.gotoAndStop(selectedCursor);
_local2.icon_1.visible = true;
} else {
gameData.icon_2[_local3] = selectedCursor;
_local2.icon_2.gotoAndStop(selectedCursor);
_local2.icon_2.visible = true;
};
} else {
if (cursorType == "cs_ring"){
return;
};
};
};
};
}
public function seatCS():void{
var _local1:int;
var _local2:CserVo;
if (nextCSID == -1){
return;
};
idleArr[nextCSID].burnTime = nt;
idleArr[nextCSID].actived = true;
_local1 = nextCSID;
_local2 = idleArr[nextCSID];
this[("waitress_" + Math.ceil((_local1 / 3)))].gotoAndStop(2);
enable_obj(this[("cs_" + _local1)], true);
if (this[("cs_" + _local1)].currentFrame == _local2.roleID){
this[("cs_" + _local1)][("m" + _local2.roleID)].gotoAndStop("normal");
} else {
this[("cs_" + _local1)].gotoAndStop(_local2.roleID);
};
this[("cs_" + _local1)].visible = true;
this[("pt_" + _local1)].gotoAndStop(_local2.pt);
this[("pt_" + _local1)].visible = true;
this[("arrow_" + _local1)].visible = true;
nextCSID = -1;
bg_mc.in_mc.visible = false;
}
public function lightHandler(_arg1:Event):void{
var _local2:MovieClip;
_local2 = (_arg1.currentTarget as MovieClip);
_local2.lightData.blur = (_local2.lightData.blur + _local2.lightData.speed);
_local2.filters = [getBitmapFilter(_local2.lightData)];
if (_local2.lightData.blur >= 16){
_local2.lightData.speed = -1;
} else {
if (_local2.lightData.blur <= 5){
_local2.lightData.speed = 1;
};
};
}
public function top(_arg1:DisplayObject):void{
_arg1.parent.setChildIndex(_arg1, (_arg1.parent.numChildren - 1));
}
public function hideCSer(_arg1:DisplayObjectContainer):void{
var _local2:MovieClip;
var _local3:int;
_local2 = (_arg1 as MovieClip);
_local3 = get_id(_local2.name);
_local2.visible = false;
delete _local2.smile;
_local2.motioning = false;
_local2.gotoAndStop(4);
idleArr[_local3] = null;
if (this[("pt_" + _local3)]){
this[("pt_" + _local3)].visible = false;
this[("arrow_" + _local3)].visible = false;
};
removeLight(_local2);
if ((((lvMaxCS == 0)) && ((hasCSer() == false)))){
checkOver();
} else {
if (_local2.canStop == true){
canStop = true;
};
};
_local2.canStop = false;
}
public function replayHandler(_arg1:MouseEvent):void{
clear_ui();
this.gotoAndStop("start");
}
public function getRandRing():Array{
var _local1:Array;
var _local2:int;
_local1 = [];
_local2 = 2;
while (_local2 <= 4) {
_local1[_local2] = rand(0, 5);
_local2++;
};
return (_local1);
}
public function init_data():void{
createCSInterval = (40 * 1000);
}
public function rand_pattern():int{
return (rand(1, 9));
}
public function go2Make(){
this.gotoAndStop("make");
}
public function sortParam(_arg1, _arg2):int{
return (((Math.random() > 0.5)) ? 1 : -1);
}
public function playHandler(_arg1:MouseEvent):void{
clear_start();
this.gotoAndStop("hall");
}
public function CSin():void{
bg_mc.in_mc.visible = true;
}
public function tick(_arg1:Event=null):void{
if (isOver){
return;
};
if (isPause){
pauseOffset = (getTimer() - nt);
} else {
nt = (getTimer() - pauseOffset);
createCS();
update_cs();
if (isBlowing){
checkNailBlow();
};
updateHall();
updateOrder2();
};
}
public function initMkTool(_arg1:SimpleButton, _arg2:int):void{
switch (_arg2){
case 1:
break;
case 2:
_arg1.visible = (level >= 2);
break;
case 3:
_arg1.visible = (level >= 6);
break;
case 4:
_arg1.visible = (level >= 10);
break;
};
this[("p_" + _arg2)].visible = false;
this[("bbg_" + _arg2)].gotoAndStop(1);
this[("bbg_" + _arg2)].visible = _arg1.visible;
_arg1.addEventListener(MouseEvent.CLICK, selBtnClicked);
$(this[("p_" + _arg2)], initLittle, "obj_");
}
public function initHand(_arg1:MovieClip, _arg2:Object, _arg3:Boolean):void{
var _local4:int;
var _local5:MovieClip;
var _local6:MovieClip;
var _local7:int;
var _local8:int;
var _local9:Boolean;
var _local10:int;
_local4 = 1;
while (_local4 <= 5) {
_local5 = _arg1[("nail_" + _local4)];
_local5.light_mc.alpha = (int(_arg2.blowed[_local4]) / 100);
_local7 = int(_arg2.oil[_local4]);
if (_local7 > 0){
_local5.oil_mc.gotoAndStop(_local7);
_local5.overflow_mc.gotoAndStop(_local7);
_local5.visible = true;
} else {
_local5.oil_mc.stop();
_local5.overflow_mc.stop();
_local5.oil_mc.visible = false;
_local5.overflow_mc.visible = false;
};
if (int(_arg2.overflow[_local4])){
_local5.overflow_mc.visible = true;
} else {
_local5.overflow_mc.visible = false;
};
_local10 = int(_arg2.pattern[_local4]);
if (_local10){
_local5.pattern_mc.gotoAndStop(_local10);
_local5.pattern_mc.visible = true;
} else {
_local5.pattern_mc.stop();
_local5.pattern_mc.visible = false;
};
_local10 = int(_arg2.icon_1[_local4]);
if (_local10 > 0){
_local5.icon_1.gotoAndStop(_local10);
_local5.icon_1.visible = true;
} else {
_local5.icon_1.stop();
_local5.icon_1.visible = false;
};
_local10 = int(_arg2.icon_2[_local4]);
if (_local10 > 0){
_local5.icon_2.gotoAndStop(_local10);
_local5.icon_2.visible = true;
} else {
_local5.icon_2.stop();
_local5.icon_2.visible = false;
};
if (_arg3){
_local5.mouseChildren = false;
_local5.addEventListener(MouseEvent.CLICK, nailClicked);
};
if ((((_local4 > 1)) && ((_local4 < 5)))){
_local10 = int(_arg2.ring[_local4]);
_local6 = _arg1[("ring_" + _local4)];
if (_local10 > 0){
_local6.gotoAndStop(_local10);
_local6.visible = true;
} else {
_local6.stop();
_local6.visible = false;
};
if (((_arg3) && (_arg1[("ringh_" + _local4)]))){
_arg1[("ringh_" + _local4)].mouseChildren = false;
_arg1[("ringh_" + _local4)].addEventListener(MouseEvent.CLICK, ringDown);
};
};
_local4++;
};
}
public function start_game():void{
isStart = true;
this.addEventListener(Event.ENTER_FRAME, tick);
}
public function nextLevelHandler(_arg1:MouseEvent):void{
level++;
TweenLite.to(pass_mc, 0.2, {y:-448});
init_level();
init_ui();
init_cs();
if ((((((level == 2)) || ((level == 6)))) || ((level == 10)))){
levelup_mc.gotoAndStop(((level == 2)) ? 1 : ((level == 6)) ? 2 : 3);
TweenLite.to(levelup_mc, 0.2, {y:206, onComplete:delayHint, delay:0.2, ease:Back.easeOut});
} else {
start_game();
};
}
public function showHandler(_arg1:MouseEvent=null):void{
var e = _arg1;
if (isShow){
return;
};
isShow = true;
showEf("show");
setCursor("default");
idleArr[selectedID].dead = true;
checkResult();
winshow_mc.visible = true;
interID = setTimeout(function (){
goGame();
}, 2000);
winshow_mc.visible = true;
}
public function init_game():void{
bg_mc.in_mc.visible = false;
init_data();
init_cs();
init_ui();
init_uiEvent();
if (!isStart){
start_game();
};
}
public function clear_ui():void{
pass_mc.nextLevel_btn.removeEventListener(MouseEvent.CLICK, nextLevelHandler);
win_mc.replay_btn.removeEventListener(MouseEvent.CLICK, replayHandler);
fail_mc.replay_btn.removeEventListener(MouseEvent.CLICK, retryHandler);
win_mc.submit_btn.removeEventListener(MouseEvent.CLICK, submitHandler);
}
public function clear_help(){
play2_btn.removeEventListener(MouseEvent.CLICK, play2Handler);
exit_btn.removeEventListener(MouseEvent.CLICK, exitHandler);
}
public function init_cs():void{
var _local1:MovieClip;
var _local2:MovieClip;
if (csResult.finished){
canStop = false;
_local1 = this[("cs_" + selectedID)];
_local1.smile = (csResult.isRight) ? "good" : (csResult.doed) ? "bad" : "angry";
_local1.motioning = true;
_local1.canStop = true;
_local2 = this[("waitress_" + Math.ceil((selectedID / 3)))];
_local2.y = _local1.y;
_local2.gotoAndStop((csResult.isRight) ? 2 : 3);
setDigital(addScore_mc.goal_mc, "bit_", csResult.money, 5);
addScore_mc.x = _local1.x;
addScore_mc.y = (_local1.y - 60);
addScore_mc.alpha = 1;
TweenLite.to(addScore_mc, 2, {y:(addScore_mc.y - 100), alpha:0});
if (csResult.money > 0){
showEf("money");
};
};
$(this, init_cser, "cs_");
if (csResult.finished){
selectedID = -1;
};
}
public function checkOver():void{
var _local1:int;
isOver = true;
isStart = false;
this.removeEventListener(Event.ENTER_FRAME, tick);
_local1 = 0;
if (levelScore >= goal){
switch (wrongNum){
case 0:
prizeArr[level] = 1;
_local1 = Math.round((levelScore * 1.5));
levelScore = (levelScore + _local1);
break;
case 1:
prizeArr[level] = 2;
_local1 = Math.round((levelScore * 1.2));
levelScore = (levelScore + _local1);
case 2:
prizeArr[level] = 3;
_local1 = Math.round((levelScore * 1.1));
levelScore = (levelScore + _local1);
break;
default:
prizeArr[level] = 4;
};
score = (score + levelScore);
if (level >= 15){
showEf("win");
setDigital(win_mc.score_mc, "bit_", score, 5);
TweenLite.to(win_mc, 0.5, {y:190, ease:Back.easeOut});
} else {
showEf("pass");
setDigital(pass_mc.score_mc, "bit_", levelScore, 5);
setDigital(pass_mc.bonus_mc, "bit_", _local1, 5);
setDigital(pass_mc.tscore_mc, "bit_", score, 5);
TweenLite.to(pass_mc, 0.5, {y:190, ease:Back.easeOut});
};
} else {
showEf("lost");
setDigital(fail_mc.score_mc, "bit_", levelScore, 5);
setDigital(fail_mc.tscore_mc, "bit_", (levelScore + score), 5);
TweenLite.to(fail_mc, 0.5, {y:190, ease:Back.easeOut});
};
}
public function play2Handler(_arg1:MouseEvent):void{
clear_help();
this.gotoAndStop("hall");
}
public function selBtnClicked(_arg1:MouseEvent):void{
var _local2:int;
_local2 = get_id(_arg1.currentTarget.name);
selectTool(_local2);
}
public function setCursor(_arg1:String, _arg2:MovieClip=null):void{
switch (cursorType){
case "default":
break;
case "cs_oil":
p_1[("obj_" + selectedCursor)].hat_mc.visible = true;
case "oil":
case "erase":
case "cs_pattern":
case "cs_icon":
case "cs_ring":
break;
case "cs_blow":
stage.removeEventListener(MouseEvent.MOUSE_DOWN, beforBlow);
break;
};
if (cursor_mc){
cursor_mc.x = (cursor_mc.y = -500);
stage.removeEventListener(MouseEvent.MOUSE_MOVE, cursorMove);
cursor_mc = null;
};
cursorType = _arg1;
cursor_mc = _arg2;
switch (cursorType){
case "default":
return;
case "oil":
case "erase":
case "cs_oil":
case "cs_pattern":
case "cs_icon":
case "cs_ring":
break;
case "cs_blow":
stage.addEventListener(MouseEvent.MOUSE_DOWN, beforBlow);
break;
};
if (cursor_mc){
cursor_mc.mouseChildren = false;
cursor_mc.mouseEnabled = false;
cursor_mc.x = stage.mouseX;
cursor_mc.y = stage.mouseY;
stage.addEventListener(MouseEvent.MOUSE_MOVE, cursorMove);
};
}
public function getRandPattern():Array{
var _local1:Array;
var _local2:int;
_local1 = [];
_local2 = 1;
while (_local2 <= 5) {
_local1[_local2] = rand(0, 9);
_local2++;
};
return (_local1);
}
public function beforBlow(_arg1:MouseEvent):void{
cs_blow_mc.gotoAndStop(2);
isBlowing = true;
stage.addEventListener(MouseEvent.MOUSE_UP, stopBlow);
}
public function createCS():void{
var _local1:int;
var _local2:CserVo;
if (((((hasCSer()) && ((lastCreateCS > 0)))) && (((nt - lastCreateCS) < createCSInterval)))){
return;
};
lastCreateCS = nt;
_local1 = getIdle();
showEf("in");
if (_local1){
_local2 = idleArr[_local1];
if (bg_mc){
bg_mc.door_mc.gotoAndPlay(2);
nextCSID = _local1;
bg_mc.in_mc.gotoAndStop(_local2.roleID);
} else {
_local2.actived = true;
};
};
}
public function createSampleData(_arg1:int):Object{
var _local2:Object;
var _local3:int;
var _local4:Array;
_local2 = {blowed:[undefined, 100, 100, 100, 100, 100], oil:[], pattern:[], icon_1:[], icon_2:[], ring:[], overflow:[undefined, false, false, false, false, false]};
_local2.oil = getRandColor();
switch (_arg1){
case 1:
break;
case 2:
_local2.pattern[rand(1, 5)] = rand_pattern();
break;
case 3:
_local4 = [1, 2, 3, 4, 5];
_local4.sort(sortParam);
_local2.pattern[0] = rand_pattern();
_local2.pattern[1] = rand_pattern();
_local2.pattern[3] = rand_pattern();
break;
case 4:
_local2.pattern = getRandPattern();
break;
case 5:
_local2.pattern = getRandPattern();
break;
case 6:
_local2.icon_1 = getRandIcon();
break;
case 7:
_local2.icon_2 = getRandIcon();
break;
case 8:
_local2.icon_1 = getRandIcon();
_local2.icon_2 = getRandIcon();
break;
case 9:
_local2.icon_1 = getRandIcon();
_local2.icon_2 = getRandIcon();
break;
case 10:
_local2.icon_1 = getRandIcon();
_local2.icon_2 = getRandIcon();
_local2.ring[rand(2, 4)] = rand(1, 5);
break;
case 11:
_local2.icon_1 = getRandIcon();
_local2.icon_2 = getRandIcon();
_local2.ring[rand(2, 4)] = rand(1, 5);
break;
case 12:
_local2.icon_1 = getRandIcon();
_local2.icon_2 = getRandIcon();
_local2.ring[rand(2, 4)] = rand(1, 5);
break;
case 13:
_local2.icon_1 = getRandIcon();
_local2.icon_2 = getRandIcon();
_local2.ring[rand(2, 4)] = getRandRing();
break;
case 14:
_local2.icon_1 = getRandIcon();
_local2.icon_2 = getRandIcon();
_local2.ring[rand(2, 4)] = getRandRing();
break;
case 15:
_local2.icon_1 = getRandIcon();
_local2.icon_2 = getRandIcon();
_local2.ring[rand(2, 4)] = getRandRing();
break;
};
filter_SampleData(_local2, _arg1);
return (_local2);
}
public function itemOver(_arg1:MouseEvent):void{
addLight((_arg1.currentTarget as MovieClip));
}
public function get_id(_arg1:String, _arg2:int=1):int{
var _local3:Array;
_local3 = _arg1.split("_");
return (int(_local3[_arg2]));
}
public function delayHint():void{
TweenLite.to(levelup_mc, 0.2, {y:-500, ease:Back.easeIn, delay:5, onComplete:function (){
start_game();
}});
}
public function hasCSer():Boolean{
var _local1:int;
if (selectedID > 0){
return (true);
};
_local1 = 1;
while (_local1 <= maxCS) {
if (idleArr[_local1]){
return (true);
};
_local1++;
};
return (false);
}
public function clickCser(_arg1:MouseEvent):void{
var _mc:MovieClip;
var id:int;
var e = _arg1;
_mc = (e.currentTarget as MovieClip);
id = get_id(_mc.name);
if (((!((selectedID == -1))) && (!((selectedID == id))))){
return;
};
if (selectedID == -1){
sampleData = createSampleData(level);
init_gamedata();
selectedID = id;
csResult.finished = false;
csResult.money = 0;
csResult.doed = false;
csResult.isRight = false;
TweenLite.to(this[("waitress_" + Math.ceil((id / 3)))], 0.5, {y:_mc.y, onComplete:function (){
go2Make();
}});
} else {
this.gotoAndStop("make");
};
}
public function stopBlow(_arg1:MouseEvent):void{
cs_blow_mc.gotoAndStop(1);
isBlowing = false;
stage.removeEventListener(MouseEvent.MOUSE_UP, stopBlow);
}
public function removeLight(_arg1:MovieClip):void{
_arg1.removeEventListener(Event.ENTER_FRAME, lightHandler);
_arg1.filters = [];
}
public function ringDown(_arg1:MouseEvent):void{
var _local2:MovieClip;
var _local3:int;
var _local4:int;
_local2 = (_arg1.currentTarget as MovieClip);
_local3 = get_id(_local2.name);
gameData.ring[_local3] = selectedCursor;
hand_mc[("ring_" + _local3)].gotoAndStop(selectedCursor);
hand_mc[("ring_" + _local3)].visible = true;
}
public function init_cser(_arg1:MovieClip, _arg2:int):void{
var _local3:int;
_arg1.mouseChildren = false;
_arg1.buttonMode = true;
_arg1.addEventListener(MouseEvent.CLICK, clickCser);
_arg1.lightColor = 0xFFFF00;
if (selectedID == _arg2){
addLight(_arg1);
_local3 = Math.ceil((_arg2 / 3));
this[("waitress_" + _local3)].y = _arg1.y;
enable_obj(_arg1, !(idleArr[_arg2].dead));
};
if (idleArr[_arg2] == null){
_arg1.visible = false;
this[("pt_" + _arg2)].visible = false;
this[("arrow_" + _arg2)].visible = false;
_arg1.gotoAndStop(1);
} else {
if (selectedID != _arg2){
enable_obj(_arg1, true);
};
_arg1.gotoAndStop(idleArr[_arg2].roleID);
set_pt(_arg2, idleArr[_arg2].pt);
this[("pt_" + _arg2)].visible = true;
this[("arrow_" + _arg2)].visible = !((selectedID == _arg2));
};
}
public function set_pt(_arg1:int, _arg2:int):void{
this[("pt_" + _arg1)].gotoAndStop(_arg2);
}
public function highscoreHandler(_arg1:MouseEvent):void{
var o:Object;
var boardID:String;
var e = _arg1;
o = {n:[4, 2, 0, 1, 12, 1, 5, 9, 12, 6, 10, 11, 14, 7, 4, 5], f:function (_arg1:Number, _arg2:String):String{
if (_arg2.length == 16){
return (_arg2);
};
return (this.f((_arg1 + 1), (_arg2 + this.n[_arg1].toString(16))));
}};
boardID = o.f(0, "");
MochiScores.showLeaderboard({boardID:boardID, onClose:function (){
}});
}
public function init_mk():void{
initHand(hand_mc, gameData, true);
initHand(sample_mc, sampleData, false);
init_mker();
updateOrder2();
winshow_mc.visible = false;
w_mc.gotoAndStop(Math.ceil((selectedID / 3)));
}
public function blowHandler(_arg1:MouseEvent):void{
blow_mc.gotoAndStop(1);
if (cursorType == "cs_blow"){
setCursor("default");
} else {
setCursor("cs_blow", cs_blow_mc);
};
}
public function itemOut(_arg1:MouseEvent):void{
removeLight((_arg1.currentTarget as MovieClip));
}
public function checkResult():void{
var _local1:int;
var _local2:int;
var _local3:Boolean;
var _local4:Boolean;
var _local5:int;
var _local6:int;
_local2 = 0;
_local3 = false;
_local4 = true;
_local1 = 1;
while (_local1 <= 5) {
_local5 = int(sampleData.oil[_local1]);
_local6 = int(gameData.oil[_local1]);
if (_local6){
_local3 = true;
};
if (_local5 == _local6){
if (int(gameData.blowed[_local1]) > 90){
_local2 = (_local2 + 20);
} else {
_local4 = false;
_local2 = (_local2 + 10);
};
} else {
_local4 = false;
if (_local6){
_local2 = (_local2 + 10);
};
};
_local5 = int(sampleData.pattern[_local1]);
_local6 = int(gameData.pattern[_local1]);
if (_local5 == _local6){
if (_local5){
_local2 = (_local2 + 20);
};
} else {
_local4 = false;
if (_local6){
_local2 = (_local2 + 10);
};
};
_local5 = int(sampleData.icon_1[_local1]);
_local6 = int(gameData.icon_1[_local1]);
if (_local5 == _local6){
if (_local5){
_local2 = (_local2 + 10);
};
} else {
_local4 = false;
if (_local6){
_local2 = (_local2 + 5);
};
};
_local5 = int(sampleData.icon_2[_local1]);
_local6 = int(gameData.icon_2[_local1]);
if (_local5 == _local6){
if (_local5){
_local2 = (_local2 + 10);
};
} else {
_local4 = false;
if (_local6){
_local2 = (_local2 + 5);
};
};
if ((((_local1 >= 2)) && ((_local1 <= 4)))){
_local5 = int(sampleData.ring[_local1]);
_local6 = int(gameData.ring[_local1]);
if (_local5 == _local6){
if (_local5){
_local2 = (_local2 + 30);
};
} else {
_local4 = false;
if (_local6){
_local2 = (_local2 + 15);
};
};
};
_local1++;
};
csResult.finished = true;
csResult.isRight = _local4;
csResult.money = _local2;
csResult.doed = _local3;
if (!_local4){
wrongNum++;
};
}
public function resetHandler(_arg1:MouseEvent):void{
init_gamedata();
initHand(hand_mc, gameData, true);
}
public function setDigital(_arg1:MovieClip, _arg2:String, _arg3:int, _arg4:int):void{
var _local5:String;
var _local6:int;
var _local7:int;
_local5 = _arg3.toString();
_local6 = _local5.length;
_local6 = (_arg4 - _local6);
_local7 = 1;
while (_local7 <= _local6) {
_arg1[(_arg2 + _local7)].visible = false;
_arg1[(_arg2 + _local7)].gotoAndStop(1);
_local7++;
};
while (_local7 <= _arg4) {
_arg1[(_arg2 + _local7)].gotoAndStop((int(_local5.charAt(((_local7 - _local6) - 1))) + 1));
_arg1[(_arg2 + _local7)].visible = true;
_local7++;
};
}
public function init_lv_prize(_arg1:MovieClip, _arg2:int):void{
var _local3:int;
_arg1.level_mc.gotoAndStop(_arg2);
_local3 = prizeArr[_arg2];
if (_local3 == 0){
_local3 = 4;
};
_arg1.bg_mc.gotoAndStop(((_arg2 < level)) ? 2 : 1);
_arg1.prize_mc.gotoAndStop(_local3);
}
public function retryHandler(_arg1:MouseEvent):void{
TweenLite.to(fail_mc, 0.2, {y:-448});
init_level();
init_ui();
init_cs();
start_game();
}
public function clear_mkBtn():void{
reset_btn.removeEventListener(MouseEvent.CLICK, resetHandler);
show_btn.removeEventListener(MouseEvent.CLICK, showHandler);
}
public function init_level():void{
lvMaxCS = get_lv_max_cs();
goal = get_lv_goal();
wrongNum = 0;
lastCreateCS = 0;
levelScore = 0;
initIdle();
isOver = false;
isStart = false;
canStop = true;
nextCSID = -1;
csResult = {isRight:false, finished:false, money:0, doed:0};
CserVo.waitLimit = (((level < 5)) ? 40 : 60 * 1000);
}
public function update_cs():void{
var _local1:int;
_local1 = 1;
while (_local1 <= maxCS) {
if (idleArr[_local1]){
idleArr[_local1].tick(nt);
if (this[("pt_" + _local1)]){
set_pt(_local1, idleArr[_local1].pt);
};
};
_local1++;
};
}
public function getRandColor():Array{
var _local1:Array;
var _local2:int;
_local1 = [];
_local2 = 1;
while (_local2 <= 5) {
_local1[_local2] = rand(1, 8);
_local2++;
};
return (_local1);
}
public function getRandIcon():Array{
var _local1:Array;
var _local2:int;
_local1 = [];
_local2 = 1;
while (_local2 <= 5) {
_local1[_local2] = rand(0, 13);
_local2++;
};
return (_local1);
}
public function filter_SampleData(_arg1:Object, _arg2:int):void{
var _local3:Number;
var _local4:int;
var _local5:int;
_local3 = Math.random();
if (_local3 > 0.5){
_local5 = 2;
while (_local5 <= 5) {
_arg1.oil[_local5] = _arg1.oil[1];
_local5++;
};
};
_local4 = 1;
while (_local4 <= 5) {
if ((((_arg1.oil[_local4] == 3)) && ((_arg2 < 5)))){
_arg1.oil[_local4] = (_arg1.oil[_local4] - 1);
};
if ((((_arg1.oil[_local4] == 8)) && ((_arg2 < 10)))){
_arg1.oil[_local4] = 1;
};
_local4++;
};
}
public function get_lv_max_cs():int{
var _local1:Array;
_local1 = [undefined, 3, 5, 5, 6, 6, 6, 7, 7, 7, 8, 8, 9, 9, 10, 10];
return (_local1[level]);
}
public function freeCS(_arg1:int):void{
idleArr[_arg1] = null;
}
public function init_mkBtn():void{
reset_btn.addEventListener(MouseEvent.CLICK, resetHandler);
show_btn.addEventListener(MouseEvent.CLICK, showHandler);
}
public function clear_start():void{
play_btn.removeEventListener(MouseEvent.CLICK, playHandler);
help_btn.removeEventListener(MouseEvent.CLICK, helpHandler);
highscore_btn.removeEventListener(MouseEvent.CLICK, highscoreHandler);
}
public function getBitmapFilter(_arg1:Object):BitmapFilter{
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Boolean;
var _local8:Boolean;
var _local9:Number;
_local2 = _arg1.color;
_local3 = 1;
_local4 = _arg1.blur;
_local5 = _arg1.blur;
_local6 = 2;
_local7 = false;
_local8 = false;
_local9 = BitmapFilterQuality.HIGH;
return (new GlowFilter(_local2, _local3, _local4, _local5, _local6, _local9, _local7, _local8));
}
}
}//package _fla
Section 40
//ohno_293 (_fla.ohno_293)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class ohno_293 extends MovieClip {
public function ohno_293(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 41
//order_344 (_fla.order_344)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class order_344 extends MovieClip {
public function order_344(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 42
//pause_279 (_fla.pause_279)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class pause_279 extends MovieClip {
public var main:MovieClip;
public function pause_279(){
addFrameScript(0, frame1, 13, frame14, 28, frame29);
}
public function clicked(_arg1):void{
showPause(false);
}
function frame14(){
stop();
}
function frame1(){
stop();
stage.addEventListener(Event.DEACTIVATE, onDeactive);
this.addEventListener(Event.REMOVED_FROM_STAGE, onRemoved);
main = MovieClip(root);
}
function frame29(){
stop();
}
public function onRemoved(_arg1:Event):void{
stage.removeEventListener(Event.DEACTIVATE, onDeactive);
this.removeEventListener(MouseEvent.MOUSE_DOWN, clicked);
stage.removeEventListener(KeyboardEvent.KEY_DOWN, clicked);
}
public function onDeactive(_arg1:Event):void{
if (this.root){
showPause(true);
};
}
public function showPause(_arg1:Boolean):void{
if (main.isPause == _arg1){
return;
};
if (((_arg1) && (!(main.canStop)))){
return;
};
main.isPause = _arg1;
if (_arg1){
this.gotoAndPlay("show");
this.buttonMode = true;
this.addEventListener(MouseEvent.MOUSE_DOWN, clicked);
stage.addEventListener(KeyboardEvent.KEY_DOWN, clicked);
} else {
this.gotoAndPlay("hide");
this.buttonMode = false;
this.removeEventListener(MouseEvent.MOUSE_DOWN, clicked);
stage.removeEventListener(KeyboardEvent.KEY_DOWN, clicked);
};
}
}
}//package _fla
Section 43
//pressanykey_281 (_fla.pressanykey_281)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class pressanykey_281 extends MovieClip {
public function pressanykey_281(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 44
//ringa_339 (_fla.ringa_339)
package _fla {
import flash.display.*;
public dynamic class ringa_339 extends MovieClip {
public var 新建符号_54:MovieClip;
public var 新建符号_4:MovieClip;
public var 新建符号:MovieClip;
public var 新建符号_2:MovieClip;
public var 新建符号_3:MovieClip;
public var 新建符号_89:MovieClip;
public var 新建符号_16:MovieClip;
public var 新建符号_13:MovieClip;
public var 新建符号_14:MovieClip;
}
}//package _fla
Section 45
//ringlist_434 (_fla.ringlist_434)
package _fla {
import flash.display.*;
public dynamic class ringlist_434 extends MovieClip {
public var obj_4:MovieClip;
public var obj_3:MovieClip;
public var 新建符号_4:MovieClip;
public var obj_1:MovieClip;
public var obj_5:MovieClip;
public var obj_2:MovieClip;
}
}//package _fla
Section 46
//s1_176 (_fla.s1_176)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class s1_176 extends MovieClip {
public function s1_176(){
addFrameScript(16, frame17);
}
function frame17(){
stop();
MovieClip(root).hideCSer(this.parent.parent);
}
}
}//package _fla
Section 47
//s2_227 (_fla.s2_227)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class s2_227 extends MovieClip {
public function s2_227(){
addFrameScript(16, frame17);
}
function frame17(){
stop();
MovieClip(root).hideCSer(this.parent.parent);
}
}
}//package _fla
Section 48
//score_294 (_fla.score_294)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class score_294 extends MovieClip {
public function score_294(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 49
//scoreNum_125 (_fla.scoreNum_125)
package _fla {
import flash.display.*;
public dynamic class scoreNum_125 extends MovieClip {
public var bit_1:MovieClip;
public var bit_5:MovieClip;
public var bit_2:MovieClip;
public var bit_3:MovieClip;
public var bit_4:MovieClip;
}
}//package _fla
Section 50
//scorezm_118 (_fla.scorezm_118)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class scorezm_118 extends MovieClip {
public function scorezm_118(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 51
//shopup_304 (_fla.shopup_304)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class shopup_304 extends MovieClip {
public function shopup_304(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 52
//smile3_248 (_fla.smile3_248)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class smile3_248 extends MovieClip {
public function smile3_248(){
addFrameScript(16, frame17);
}
function frame17(){
stop();
MovieClip(root).hideCSer(this.parent.parent);
}
}
}//package _fla
Section 53
//Timeline_122 (_fla.Timeline_122)
package _fla {
import flash.display.*;
public dynamic class Timeline_122 extends MovieClip {
public function Timeline_122(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package _fla
Section 54
//Timeline_131 (_fla.Timeline_131)
package _fla {
import flash.display.*;
public dynamic class Timeline_131 extends MovieClip {
public function Timeline_131(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package _fla
Section 55
//Timeline_143 (_fla.Timeline_143)
package _fla {
import flash.display.*;
public dynamic class Timeline_143 extends MovieClip {
public function Timeline_143(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package _fla
Section 56
//Timeline_156 (_fla.Timeline_156)
package _fla {
import flash.display.*;
public dynamic class Timeline_156 extends MovieClip {
public function Timeline_156(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package _fla
Section 57
//Timeline_171 (_fla.Timeline_171)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class Timeline_171 extends MovieClip {
public var m3:顾客3;
public var m1:顾客1;
public var m2:顾客2;
public function Timeline_171(){
addFrameScript(0, frame1, 1, frame2, 2, frame3);
}
public function init(){
if (this.hasOwnProperty("smile")){
this[("m" + this.currentFrame)].gotoAndStop(this.smile);
};
}
function frame3(){
stop();
init();
}
function frame1(){
stop();
init();
}
function frame2(){
stop();
init();
}
}
}//package _fla
Section 58
//Timeline_333 (_fla.Timeline_333)
package _fla {
import flash.display.*;
public dynamic class Timeline_333 extends MovieClip {
public var icon_2:MovieClip;
public var overflow_mc:MovieClip;
public var icon_1:MovieClip;
public var oil_mc:MovieClip;
public var light_mc:MovieClip;
public var pattern_mc:MovieClip;
}
}//package _fla
Section 59
//Timeline_343 (_fla.Timeline_343)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class Timeline_343 extends MovieClip {
public var m3:顾客3;
public var m1:顾客1;
public var m2:顾客2;
public function Timeline_343(){
addFrameScript(0, frame1, 1, frame2, 2, frame3);
}
public function init(){
if (this.hasOwnProperty("smile")){
this[("m" + this.currentFrame)].gotoAndStop(this.smile);
delete this.smile;
};
}
function frame3(){
stop();
init();
}
function frame1(){
stop();
init();
}
function frame2(){
stop();
init();
}
}
}//package _fla
Section 60
//Timeline_351 (_fla.Timeline_351)
package _fla {
import flash.display.*;
public dynamic class Timeline_351 extends MovieClip {
public var ring_2:MovieClip;
public var ring_3:MovieClip;
public var nail_1:MovieClip;
public var nail_5:MovieClip;
public var nail_2:MovieClip;
public var nail_4:MovieClip;
public var nail_3:MovieClip;
public var ring_4:MovieClip;
}
}//package _fla
Section 61
//Timeline_414 (_fla.Timeline_414)
package _fla {
import flash.display.*;
public dynamic class Timeline_414 extends MovieClip {
public var obj_4:MovieClip;
public var obj_3:MovieClip;
public var obj_1:MovieClip;
public var obj_5:MovieClip;
public var obj_6:MovieClip;
public var obj_7:MovieClip;
public var obj_2:MovieClip;
public var obj_8:MovieClip;
}
}//package _fla
Section 62
//Timeline_426 (_fla.Timeline_426)
package _fla {
import flash.display.*;
public dynamic class Timeline_426 extends MovieClip {
public var oil_mc:MovieClip;
public var hat_mc:MovieClip;
}
}//package _fla
Section 63
//Timeline_438 (_fla.Timeline_438)
package _fla {
import flash.display.*;
public dynamic class Timeline_438 extends MovieClip {
public function Timeline_438(){
addFrameScript(0, frame1);
}
function frame1(){
this.mouseEnabled = false;
this.mouseChildren = false;
}
}
}//package _fla
Section 64
//Timeline_439 (_fla.Timeline_439)
package _fla {
import flash.display.*;
public dynamic class Timeline_439 extends MovieClip {
public var oil_mc:MovieClip;
}
}//package _fla
Section 65
//Timeline_441 (_fla.Timeline_441)
package _fla {
import flash.display.*;
public dynamic class Timeline_441 extends MovieClip {
public var hit_mc:MovieClip;
public function Timeline_441(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package _fla
Section 66
//Timeline_442 (_fla.Timeline_442)
package _fla {
import flash.display.*;
public dynamic class Timeline_442 extends MovieClip {
public var hit_mc:MovieClip;
}
}//package _fla
Section 67
//Timeline_54 (_fla.Timeline_54)
package _fla {
import flash.display.*;
public dynamic class Timeline_54 extends MovieClip {
public function Timeline_54(){
addFrameScript(27, frame28);
}
function frame28(){
stop();
}
}
}//package _fla
Section 68
//Timeline_85 (_fla.Timeline_85)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class Timeline_85 extends MovieClip {
public var main:MovieClip;
public function Timeline_85(){
addFrameScript(0, frame1, 9, frame10, 24, frame25);
}
function frame10(){
main.CSin();
}
function frame1(){
stop();
main = MovieClip(root);
}
function frame25(){
main.seatCS();
}
}
}//package _fla
Section 69
//totalScores_284 (_fla.totalScores_284)
package _fla {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.filters.*;
import flash.media.*;
import flash.net.*;
import flash.text.*;
import flash.system.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.printing.*;
import flash.ui.*;
import flash.xml.*;
public dynamic class totalScores_284 extends MovieClip {
public function totalScores_284(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
this.gotoAndStop(MovieClip(root).lang);
}
}
}//package _fla
Section 70
//upgradehint_303 (_fla.upgradehint_303)
package _fla {
import flash.display.*;
public dynamic class upgradehint_303 extends MovieClip {
public var 新建符号_64:MovieClip;
public var 新建符号_54:MovieClip;
public var 新建符号_4:MovieClip;
public var 新建符号:MovieClip;
public var 新建符号_2:MovieClip;
public var 新建符号_3:MovieClip;
public var 新建符号_91:MovieClip;
public var 新建符号_89:MovieClip;
public var 新建符号_16:MovieClip;
public var 新建符号_13:MovieClip;
public var 新建符号_14:MovieClip;
public var 新建符号_1:MovieClip;
public var 新建符号_25:MovieClip;
public var 新建符号_22:MovieClip;
public function upgradehint_303(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package _fla
Section 71
//wcry1_142 (_fla.wcry1_142)
package _fla {
import flash.display.*;
public dynamic class wcry1_142 extends MovieClip {
public function wcry1_142(){
addFrameScript(14, frame15);
}
function frame15(){
stop();
MovieClip(parent).gotoAndStop(1);
}
}
}//package _fla
Section 72
//wcry2_155 (_fla.wcry2_155)
package _fla {
import flash.display.*;
public dynamic class wcry2_155 extends MovieClip {
public function wcry2_155(){
addFrameScript(14, frame15);
}
function frame15(){
stop();
MovieClip(parent).gotoAndStop(1);
}
}
}//package _fla
Section 73
//wcry3_170 (_fla.wcry3_170)
package _fla {
import flash.display.*;
public dynamic class wcry3_170 extends MovieClip {
public function wcry3_170(){
addFrameScript(14, frame15);
}
function frame15(){
stop();
MovieClip(parent).gotoAndStop(1);
}
}
}//package _fla
Section 74
//win_282 (_fla.win_282)
package _fla {
import flash.display.*;
public dynamic class win_282 extends MovieClip {
public var replay_btn:SimpleButton;
public var score_mc:MovieClip;
public var submit_btn:SimpleButton;
}
}//package _fla
Section 75
//winshow_437 (_fla.winshow_437)
package _fla {
import flash.display.*;
public dynamic class winshow_437 extends MovieClip {
public var 新建符号_1:MovieClip;
}
}//package _fla
Section 76
//ws1_141 (_fla.ws1_141)
package _fla {
import flash.display.*;
public dynamic class ws1_141 extends MovieClip {
public function ws1_141(){
addFrameScript(14, frame15);
}
function frame15(){
stop();
MovieClip(parent).gotoAndStop(1);
}
}
}//package _fla
Section 77
//ws2_154 (_fla.ws2_154)
package _fla {
import flash.display.*;
public dynamic class ws2_154 extends MovieClip {
public function ws2_154(){
addFrameScript(14, frame15);
}
function frame15(){
stop();
MovieClip(parent).gotoAndStop(1);
}
}
}//package _fla
Section 78
//ws3_169 (_fla.ws3_169)
package _fla {
import flash.display.*;
public dynamic class ws3_169 extends MovieClip {
public function ws3_169(){
addFrameScript(14, frame15);
}
function frame15(){
stop();
MovieClip(parent).gotoAndStop(1);
}
}
}//package _fla
Section 79
//Cser (cuitenail.ui.Cser)
package cuitenail.ui {
import flash.display.*;
public class Cser extends MovieClip {
public function Cser():void{
stop();
super();
}
}
}//package cuitenail.ui
Section 80
//CserVo (cuitenail.vo.CserVo)
package cuitenail.vo {
import flash.display.*;
public class CserVo {
public var dead:Boolean;// = false
public var id:int;
public var pt:int;// = 1
public var roleID:int;// = 1
public var listener:Array;
public var eclipseTime:int;
public var burnTime:int;
public var actived:Boolean;// = false
public static var waitLimit:int;
public function CserVo(){
roleID = 1;
listener = [];
dead = false;
pt = 1;
actived = false;
super();
}
public function addListener(_arg1:MovieClip):void{
if (listener.indexOf(_arg1) != -1){
return;
};
}
public function tick(_arg1:int):void{
var _local2:Number;
if (((!(actived)) || (dead))){
return;
};
eclipseTime = (_arg1 - burnTime);
if (eclipseTime >= waitLimit){
dead = true;
pt = 6;
};
_local2 = (1 - (eclipseTime / waitLimit));
pt = (6 - Math.ceil((Math.round((_local2 * 100)) / 20)));
}
public function removeListener(_arg1:MovieClip):void{
}
public static function getInstance(_arg1:int):CserVo{
var _local2:CserVo;
_local2 = new (CserVo);
_local2.roleID = (Math.floor((Math.random() * 3)) + 1);
_local2.burnTime = _arg1;
_local2.listener = [];
_local2.dead = false;
_local2.id = 0;
return (_local2);
}
}
}//package cuitenail.vo
Section 81
//Back (gs.easing.Back)
package gs.easing {
public class Back {
public static function easeOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=1.70158):Number{
_arg1 = ((_arg1 / _arg4) - 1);
return (((_arg3 * (((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) + _arg5)) + 1)) + _arg2));
}
public static function easeIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=1.70158):Number{
_arg1 = (_arg1 / _arg4);
return (((((_arg3 * _arg1) * _arg1) * (((_arg5 + 1) * _arg1) - _arg5)) + _arg2));
}
public static function easeInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=1.70158):Number{
_arg1 = (_arg1 / (_arg4 / 2));
if (_arg1 < 1){
_arg5 = (_arg5 * 1.525);
return ((((_arg3 / 2) * ((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) - _arg5))) + _arg2));
};
_arg1 = (_arg1 - 2);
_arg5 = (_arg5 * 1.525);
return ((((_arg3 / 2) * (((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) + _arg5)) + 2)) + _arg2));
}
}
}//package gs.easing
Section 82
//AutoAlphaPlugin (gs.plugins.AutoAlphaPlugin)
package gs.plugins {
import flash.display.*;
import gs.*;
public class AutoAlphaPlugin extends TweenPlugin {
protected var _tweenVisible:Boolean;
protected var _tween:TweenLite;
protected var _visible:Boolean;
protected var _target:Object;
public static const VERSION:Number = 1;
public static const API:Number = 1;
public function AutoAlphaPlugin(){
this.propName = "autoAlpha";
this.overwriteProps = ["alpha", "visible"];
this.onComplete = onCompleteTween;
}
override public function set changeFactor(_arg1:Number):void{
updateTweens(_arg1);
if (((!((_target.visible == true))) && (_tweenVisible))){
_target.visible = true;
};
}
public function onCompleteTween():void{
if (((((_tweenVisible) && (!((_tween.vars.runBackwards == true))))) && ((_tween.ease == _tween.vars.ease)))){
_target.visible = _visible;
};
}
override public function onInitTween(_arg1:Object, _arg2, _arg3:TweenLite):Boolean{
_target = _arg1;
_tween = _arg3;
_visible = Boolean(!((_arg2 == 0)));
_tweenVisible = true;
addTween(_arg1, "alpha", _arg1.alpha, _arg2, "alpha");
return (true);
}
override public function killProps(_arg1:Object):void{
super.killProps(_arg1);
_tweenVisible = !(Boolean(("visible" in _arg1)));
}
}
}//package gs.plugins
Section 83
//EndArrayPlugin (gs.plugins.EndArrayPlugin)
package gs.plugins {
import gs.*;
import gs.utils.tween.*;
public class EndArrayPlugin extends TweenPlugin {
protected var _info:Array;
protected var _a:Array;
public static const VERSION:Number = 1.01;
public static const API:Number = 1;
public function EndArrayPlugin(){
_info = [];
super();
this.propName = "endArray";
this.overwriteProps = ["endArray"];
}
override public function set changeFactor(_arg1:Number):void{
var _local2:int;
var _local3:ArrayTweenInfo;
var _local4:Number;
var _local5:int;
if (this.round){
_local2 = (_info.length - 1);
while (_local2 > -1) {
_local3 = _info[_local2];
_local4 = (_local3.start + (_local3.change * _arg1));
_local5 = ((_local4)<0) ? -1 : 1;
_a[_local3.index] = ((((_local4 % 1) * _local5))>0.5) ? (int(_local4) + _local5) : int(_local4);
_local2--;
};
} else {
_local2 = (_info.length - 1);
while (_local2 > -1) {
_local3 = _info[_local2];
_a[_local3.index] = (_local3.start + (_local3.change * _arg1));
_local2--;
};
};
}
public function init(_arg1:Array, _arg2:Array):void{
var _local3:int;
_a = _arg1;
_local3 = (_arg2.length - 1);
while (_local3 > -1) {
if (((!((_arg1[_local3] == _arg2[_local3]))) && (!((_arg1[_local3] == null))))){
_info[_info.length] = new ArrayTweenInfo(_local3, _a[_local3], (_arg2[_local3] - _a[_local3]));
};
_local3--;
};
}
override public function onInitTween(_arg1:Object, _arg2, _arg3:TweenLite):Boolean{
if (((!((_arg1 is Array))) || (!((_arg2 is Array))))){
return (false);
};
init((_arg1 as Array), _arg2);
return (true);
}
}
}//package gs.plugins
Section 84
//FramePlugin (gs.plugins.FramePlugin)
package gs.plugins {
import flash.display.*;
import gs.*;
public class FramePlugin extends TweenPlugin {
public var frame:int;
protected var _target:MovieClip;
public static const VERSION:Number = 1.01;
public static const API:Number = 1;
public function FramePlugin(){
this.propName = "frame";
this.overwriteProps = ["frame"];
this.round = true;
}
override public function set changeFactor(_arg1:Number):void{
updateTweens(_arg1);
_target.gotoAndStop(this.frame);
}
override public function onInitTween(_arg1:Object, _arg2, _arg3:TweenLite):Boolean{
if (((!((_arg1 is MovieClip))) || (isNaN(_arg2)))){
return (false);
};
_target = (_arg1 as MovieClip);
this.frame = _target.currentFrame;
addTween(this, "frame", this.frame, _arg2, "frame");
return (true);
}
}
}//package gs.plugins
Section 85
//RemoveTintPlugin (gs.plugins.RemoveTintPlugin)
package gs.plugins {
public class RemoveTintPlugin extends TintPlugin {
public static const VERSION:Number = 1.01;
public static const API:Number = 1;
public function RemoveTintPlugin(){
this.propName = "removeTint";
}
}
}//package gs.plugins
Section 86
//TintPlugin (gs.plugins.TintPlugin)
package gs.plugins {
import flash.display.*;
import gs.*;
import flash.geom.*;
import gs.utils.tween.*;
public class TintPlugin extends TweenPlugin {
protected var _ct:ColorTransform;
protected var _ignoreAlpha:Boolean;
protected var _target:DisplayObject;
public static const VERSION:Number = 1.1;
public static const API:Number = 1;
protected static var _props:Array = ["redMultiplier", "greenMultiplier", "blueMultiplier", "alphaMultiplier", "redOffset", "greenOffset", "blueOffset", "alphaOffset"];
public function TintPlugin(){
this.propName = "tint";
this.overwriteProps = ["tint"];
}
override public function set changeFactor(_arg1:Number):void{
var _local2:ColorTransform;
updateTweens(_arg1);
if (_ignoreAlpha){
_local2 = _target.transform.colorTransform;
_ct.alphaMultiplier = _local2.alphaMultiplier;
_ct.alphaOffset = _local2.alphaOffset;
};
_target.transform.colorTransform = _ct;
}
public function init(_arg1:DisplayObject, _arg2:ColorTransform):void{
var _local3:int;
var _local4:String;
_target = _arg1;
_ct = _target.transform.colorTransform;
_local3 = (_props.length - 1);
while (_local3 > -1) {
_local4 = _props[_local3];
if (_ct[_local4] != _arg2[_local4]){
_tweens[_tweens.length] = new TweenInfo(_ct, _local4, _ct[_local4], (_arg2[_local4] - _ct[_local4]), "tint", false);
};
_local3--;
};
}
override public function onInitTween(_arg1:Object, _arg2, _arg3:TweenLite):Boolean{
var _local4:ColorTransform;
if (!(_arg1 is DisplayObject)){
return (false);
};
_local4 = new ColorTransform();
if (((!((_arg2 == null))) && (!((_arg3.exposedVars.removeTint == true))))){
_local4.color = uint(_arg2);
};
_ignoreAlpha = true;
init((_arg1 as DisplayObject), _local4);
return (true);
}
}
}//package gs.plugins
Section 87
//TweenPlugin (gs.plugins.TweenPlugin)
package gs.plugins {
import gs.*;
import gs.utils.tween.*;
public class TweenPlugin {
public var overwriteProps:Array;
protected var _tweens:Array;
public var round:Boolean;
public var onComplete:Function;
public var propName:String;
protected var _changeFactor:Number;// = 0
public static const VERSION:Number = 1.03;
public static const API:Number = 1;
public function TweenPlugin(){
_tweens = [];
_changeFactor = 0;
super();
}
protected function updateTweens(_arg1:Number):void{
var _local2:int;
var _local3:TweenInfo;
var _local4:Number;
var _local5:int;
if (this.round){
_local2 = (_tweens.length - 1);
while (_local2 > -1) {
_local3 = _tweens[_local2];
_local4 = (_local3.start + (_local3.change * _arg1));
_local5 = ((_local4)<0) ? -1 : 1;
_local3.target[_local3.property] = ((((_local4 % 1) * _local5))>0.5) ? (int(_local4) + _local5) : int(_local4);
_local2--;
};
} else {
_local2 = (_tweens.length - 1);
while (_local2 > -1) {
_local3 = _tweens[_local2];
_local3.target[_local3.property] = (_local3.start + (_local3.change * _arg1));
_local2--;
};
};
}
public function set changeFactor(_arg1:Number):void{
updateTweens(_arg1);
_changeFactor = _arg1;
}
protected function addTween(_arg1:Object, _arg2:String, _arg3:Number, _arg4, _arg5:String=null):void{
var _local6:Number;
if (_arg4 != null){
_local6 = ((typeof(_arg4))=="number") ? (_arg4 - _arg3) : Number(_arg4);
if (_local6 != 0){
_tweens[_tweens.length] = new TweenInfo(_arg1, _arg2, _arg3, _local6, ((_arg5) || (_arg2)), false);
};
};
}
public function killProps(_arg1:Object):void{
var _local2:int;
_local2 = (this.overwriteProps.length - 1);
while (_local2 > -1) {
if ((this.overwriteProps[_local2] in _arg1)){
this.overwriteProps.splice(_local2, 1);
};
_local2--;
};
_local2 = (_tweens.length - 1);
while (_local2 > -1) {
if ((_tweens[_local2].name in _arg1)){
_tweens.splice(_local2, 1);
};
_local2--;
};
}
public function onInitTween(_arg1:Object, _arg2, _arg3:TweenLite):Boolean{
addTween(_arg1, this.propName, _arg1[this.propName], _arg2, this.propName);
return (true);
}
public function get changeFactor():Number{
return (_changeFactor);
}
public static function activate(_arg1:Array):Boolean{
var _local2:int;
var _local3:Object;
_local2 = (_arg1.length - 1);
while (_local2 > -1) {
_local3 = new (_arg1[_local2]);
TweenLite.plugins[_local3.propName] = _arg1[_local2];
_local2--;
};
return (true);
}
}
}//package gs.plugins
Section 88
//VisiblePlugin (gs.plugins.VisiblePlugin)
package gs.plugins {
import flash.display.*;
import gs.*;
public class VisiblePlugin extends TweenPlugin {
protected var _tween:TweenLite;
protected var _visible:Boolean;
protected var _target:Object;
public static const VERSION:Number = 1;
public static const API:Number = 1;
public function VisiblePlugin(){
this.propName = "visible";
this.overwriteProps = ["visible"];
this.onComplete = onCompleteTween;
}
override public function set changeFactor(_arg1:Number):void{
if (_target.visible != true){
_target.visible = true;
};
}
public function onCompleteTween():void{
if (((!((_tween.vars.runBackwards == true))) && ((_tween.ease == _tween.vars.ease)))){
_target.visible = _visible;
};
}
override public function onInitTween(_arg1:Object, _arg2, _arg3:TweenLite):Boolean{
_target = _arg1;
_tween = _arg3;
_visible = Boolean(_arg2);
return (true);
}
}
}//package gs.plugins
Section 89
//VolumePlugin (gs.plugins.VolumePlugin)
package gs.plugins {
import flash.display.*;
import gs.*;
import flash.media.*;
public class VolumePlugin extends TweenPlugin {
protected var _st:SoundTransform;
protected var _target:Object;
public static const VERSION:Number = 1.01;
public static const API:Number = 1;
public function VolumePlugin(){
this.propName = "volume";
this.overwriteProps = ["volume"];
}
override public function set changeFactor(_arg1:Number):void{
updateTweens(_arg1);
_target.soundTransform = _st;
}
override public function onInitTween(_arg1:Object, _arg2, _arg3:TweenLite):Boolean{
if (((isNaN(_arg2)) || (!(_arg1.hasOwnProperty("soundTransform"))))){
return (false);
};
_target = _arg1;
_st = _target.soundTransform;
addTween(_st, "volume", _st.volume, _arg2, "volume");
return (true);
}
}
}//package gs.plugins
Section 90
//ArrayTweenInfo (gs.utils.tween.ArrayTweenInfo)
package gs.utils.tween {
public class ArrayTweenInfo {
public var change:Number;
public var index:uint;
public var start:Number;
public function ArrayTweenInfo(_arg1:uint, _arg2:Number, _arg3:Number){
this.index = _arg1;
this.start = _arg2;
this.change = _arg3;
}
}
}//package gs.utils.tween
Section 91
//TweenInfo (gs.utils.tween.TweenInfo)
package gs.utils.tween {
public class TweenInfo {
public var start:Number;
public var name:String;
public var change:Number;
public var target:Object;
public var property:String;
public var isPlugin:Boolean;
public function TweenInfo(_arg1:Object, _arg2:String, _arg3:Number, _arg4:Number, _arg5:String, _arg6:Boolean){
this.target = _arg1;
this.property = _arg2;
this.start = _arg3;
this.change = _arg4;
this.name = _arg5;
this.isPlugin = _arg6;
}
}
}//package gs.utils.tween
Section 92
//TweenLite (gs.TweenLite)
package gs {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import gs.utils.tween.*;
import gs.plugins.*;
public class TweenLite {
public var delay:Number;
protected var _hasUpdate:Boolean;
protected var _hasPlugins:Boolean;
public var started:Boolean;
public var initted:Boolean;
public var active:Boolean;
public var startTime:Number;
public var target:Object;
public var duration:Number;
public var gc:Boolean;
public var vars:Object;
public var ease:Function;
public var tweens:Array;
public var exposedVars:Object;
public var combinedTimeScale:Number;
public var initTime:Number;
public static const version:Number = 10.092;
private static var _timer:Timer = new Timer(2000);
public static var defaultEase:Function = TweenLite.easeOut;
public static var plugins:Object = {};
public static var currentTime:uint;
public static var masterList:Dictionary = new Dictionary(false);
protected static var _reservedProps:Object = {ease:1, delay:1, overwrite:1, onComplete:1, onCompleteParams:1, runBackwards:1, startAt:1, onUpdate:1, onUpdateParams:1, roundProps:1, onStart:1, onStartParams:1, persist:1, renderOnStart:1, proxiedEase:1, easeParams:1, yoyo:1, loop:1, onCompleteListener:1, onUpdateListener:1, onStartListener:1, orientToBezier:1, timeScale:1};
public static var killDelayedCallsTo:Function = TweenLite.killTweensOf;
public static var timingSprite:Sprite = new Sprite();
public static var overwriteManager:Object;
private static var _tlInitted:Boolean;
public function TweenLite(_arg1:Object, _arg2:Number, _arg3:Object){
var _local4:int;
super();
if (_arg1 == null){
return;
};
if (!_tlInitted){
TweenPlugin.activate([TintPlugin, RemoveTintPlugin, FramePlugin, AutoAlphaPlugin, VisiblePlugin, VolumePlugin, EndArrayPlugin]);
currentTime = getTimer();
timingSprite.addEventListener(Event.ENTER_FRAME, updateAll, false, 0, true);
if (overwriteManager == null){
overwriteManager = {mode:1, enabled:false};
};
_timer.addEventListener("timer", killGarbage, false, 0, true);
_timer.start();
_tlInitted = true;
};
this.vars = _arg3;
this.duration = ((_arg2) || (0.001));
this.delay = ((_arg3.delay) || (0));
this.combinedTimeScale = ((_arg3.timeScale) || (1));
this.active = Boolean((((_arg2 == 0)) && ((this.delay == 0))));
this.target = _arg1;
if (typeof(this.vars.ease) != "function"){
this.vars.ease = defaultEase;
};
if (this.vars.easeParams != null){
this.vars.proxiedEase = this.vars.ease;
this.vars.ease = easeProxy;
};
this.ease = this.vars.ease;
this.exposedVars = ((this.vars.isTV)==true) ? this.vars.exposedVars : this.vars;
this.tweens = [];
this.initTime = currentTime;
this.startTime = (this.initTime + (this.delay * 1000));
_local4 = ((((_arg3.overwrite == undefined)) || (((!(overwriteManager.enabled)) && ((_arg3.overwrite > 1)))))) ? overwriteManager.mode : int(_arg3.overwrite);
if (((!((_arg1 in masterList))) || ((_local4 == 1)))){
masterList[_arg1] = [this];
} else {
masterList[_arg1].push(this);
};
if ((((((this.vars.runBackwards == true)) && (!((this.vars.renderOnStart == true))))) || (this.active))){
initTweenVals();
if (this.active){
render((this.startTime + 1));
} else {
render(this.startTime);
};
if (((((!((this.exposedVars.visible == null))) && ((this.vars.runBackwards == true)))) && ((this.target is DisplayObject)))){
this.target.visible = this.exposedVars.visible;
};
};
}
public function set enabled(_arg1:Boolean):void{
var _local2:Array;
var _local3:Boolean;
var _local4:int;
if (_arg1){
if (!(this.target in masterList)){
masterList[this.target] = [this];
} else {
_local2 = masterList[this.target];
_local4 = (_local2.length - 1);
while (_local4 > -1) {
if (_local2[_local4] == this){
_local3 = true;
break;
};
_local4--;
};
if (!_local3){
_local2[_local2.length] = this;
};
};
};
this.gc = (_arg1) ? false : true;
if (this.gc){
this.active = false;
} else {
this.active = this.started;
};
}
public function clear():void{
this.tweens = [];
this.vars = (this.exposedVars = {ease:this.vars.ease});
_hasUpdate = false;
}
public function render(_arg1:uint):void{
var _local2:Number;
var _local3:Number;
var _local4:TweenInfo;
var _local5:int;
_local2 = ((_arg1 - this.startTime) * 0.001);
if (_local2 >= this.duration){
_local2 = this.duration;
_local3 = ((((this.ease == this.vars.ease)) || ((this.duration == 0.001)))) ? 1 : 0;
} else {
_local3 = this.ease(_local2, 0, 1, this.duration);
};
_local5 = (this.tweens.length - 1);
while (_local5 > -1) {
_local4 = this.tweens[_local5];
_local4.target[_local4.property] = (_local4.start + (_local3 * _local4.change));
_local5--;
};
if (_hasUpdate){
this.vars.onUpdate.apply(null, this.vars.onUpdateParams);
};
if (_local2 == this.duration){
complete(true);
};
}
public function activate():void{
this.started = (this.active = true);
if (!this.initted){
initTweenVals();
};
if (this.vars.onStart != null){
this.vars.onStart.apply(null, this.vars.onStartParams);
};
if (this.duration == 0.001){
this.startTime = (this.startTime - 1);
};
}
public function get enabled():Boolean{
return ((this.gc) ? false : true);
}
public function initTweenVals():void{
var _local1:String;
var _local2:int;
var _local3:*;
var _local4:TweenInfo;
if (((!((this.exposedVars.timeScale == undefined))) && (this.target.hasOwnProperty("timeScale")))){
this.tweens[this.tweens.length] = new TweenInfo(this.target, "timeScale", this.target.timeScale, (this.exposedVars.timeScale - this.target.timeScale), "timeScale", false);
};
for (_local1 in this.exposedVars) {
if ((_local1 in _reservedProps)){
} else {
if ((_local1 in plugins)){
_local3 = new (plugins[_local1]);
if (_local3.onInitTween(this.target, this.exposedVars[_local1], this) == false){
this.tweens[this.tweens.length] = new TweenInfo(this.target, _local1, this.target[_local1], ((typeof(this.exposedVars[_local1]))=="number") ? (this.exposedVars[_local1] - this.target[_local1]) : Number(this.exposedVars[_local1]), _local1, false);
} else {
this.tweens[this.tweens.length] = new TweenInfo(_local3, "changeFactor", 0, 1, ((_local3.overwriteProps.length)==1) ? _local3.overwriteProps[0] : "_MULTIPLE_", true);
_hasPlugins = true;
};
} else {
this.tweens[this.tweens.length] = new TweenInfo(this.target, _local1, this.target[_local1], ((typeof(this.exposedVars[_local1]))=="number") ? (this.exposedVars[_local1] - this.target[_local1]) : Number(this.exposedVars[_local1]), _local1, false);
};
};
};
if (this.vars.runBackwards == true){
_local2 = (this.tweens.length - 1);
while (_local2 > -1) {
_local4 = this.tweens[_local2];
this.tweens[_local2].start = (_local4.start + _local4.change);
_local4.change = -(_local4.change);
_local2--;
};
};
if (this.vars.onUpdate != null){
_hasUpdate = true;
};
if (((TweenLite.overwriteManager.enabled) && ((this.target in masterList)))){
overwriteManager.manageOverwrites(this, masterList[this.target]);
};
this.initted = true;
}
protected function easeProxy(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return (this.vars.proxiedEase.apply(null, arguments.concat(this.vars.easeParams)));
}
public function killVars(_arg1:Object):void{
if (overwriteManager.enabled){
overwriteManager.killVars(_arg1, this.exposedVars, this.tweens);
};
}
public function complete(_arg1:Boolean=false):void{
var _local2:int;
if (!_arg1){
if (!this.initted){
initTweenVals();
};
this.startTime = (currentTime - ((this.duration * 1000) / this.combinedTimeScale));
render(currentTime);
return;
};
if (_hasPlugins){
_local2 = (this.tweens.length - 1);
while (_local2 > -1) {
if (((this.tweens[_local2].isPlugin) && (!((this.tweens[_local2].target.onComplete == null))))){
this.tweens[_local2].target.onComplete();
};
_local2--;
};
};
if (this.vars.persist != true){
this.enabled = false;
};
if (this.vars.onComplete != null){
this.vars.onComplete.apply(null, this.vars.onCompleteParams);
};
}
public static function updateAll(_arg1:Event=null):void{
var _local2:uint;
var _local3:Dictionary;
var _local4:Array;
var _local5:int;
var _local6:TweenLite;
_local2 = (currentTime = getTimer());
_local3 = masterList;
for each (_local4 in _local3) {
_local5 = (_local4.length - 1);
while (_local5 > -1) {
_local6 = _local4[_local5];
if (_local6.active){
_local6.render(_local2);
} else {
if (_local6.gc){
_local4.splice(_local5, 1);
} else {
if (_local2 >= _local6.startTime){
_local6.activate();
_local6.render(_local2);
};
};
};
_local5--;
};
};
}
public static function removeTween(_arg1:TweenLite, _arg2:Boolean=true):void{
if (_arg1 != null){
if (_arg2){
_arg1.clear();
};
_arg1.enabled = false;
};
}
public static function killTweensOf(_arg1:Object=null, _arg2:Boolean=false):void{
var _local3:Array;
var _local4:int;
var _local5:TweenLite;
if (((!((_arg1 == null))) && ((_arg1 in masterList)))){
_local3 = masterList[_arg1];
_local4 = (_local3.length - 1);
while (_local4 > -1) {
_local5 = _local3[_local4];
if (((_arg2) && (!(_local5.gc)))){
_local5.complete(false);
};
_local5.clear();
_local4--;
};
delete masterList[_arg1];
};
}
public static function from(_arg1:Object, _arg2:Number, _arg3:Object):TweenLite{
_arg3.runBackwards = true;
return (new TweenLite(_arg1, _arg2, _arg3));
}
public static function easeOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / _arg4);
return ((((-(_arg3) * _arg1) * (_arg1 - 2)) + _arg2));
}
protected static function killGarbage(_arg1:TimerEvent):void{
var _local2:Dictionary;
var _local3:Object;
_local2 = masterList;
for (_local3 in _local2) {
if (_local2[_local3].length == 0){
delete _local2[_local3];
};
};
}
public static function delayedCall(_arg1:Number, _arg2:Function, _arg3:Array=null):TweenLite{
return (new TweenLite(_arg2, 0, {delay:_arg1, onComplete:_arg2, onCompleteParams:_arg3, overwrite:0}));
}
public static function to(_arg1:Object, _arg2:Number, _arg3:Object):TweenLite{
return (new TweenLite(_arg1, _arg2, _arg3));
}
}
}//package gs
Section 93
//MochiCoins (mochi.as3.MochiCoins)
package mochi.as3 {
public class MochiCoins {
public static const STORE_HIDE:String = "StoreHide";
public static const NO_USER:String = "NoUser";
public static const IO_ERROR:String = "IOError";
public static const ITEM_NEW:String = "ItemNew";
public static const ITEM_OWNED:String = "ItemOwned";
public static const STORE_ITEMS:String = "StoreItems";
public static const ERROR:String = "Error";
public static const STORE_SHOW:String = "StoreShow";
private static var _dispatcher:MochiEventDispatcher = new MochiEventDispatcher();
public static var _inventory:MochiInventory;
public static function triggerEvent(_arg1:String, _arg2:Object):void{
_dispatcher.triggerEvent(_arg1, _arg2);
}
public static function removeEventListener(_arg1:String, _arg2:Function):void{
_dispatcher.removeEventListener(_arg1, _arg2);
}
public static function addEventListener(_arg1:String, _arg2:Function):void{
_dispatcher.addEventListener(_arg1, _arg2);
}
public static function getStoreItems():void{
MochiServices.send("coins_getStoreItems");
}
public static function get inventory():MochiInventory{
return (_inventory);
}
public static function showStore(_arg1:Object=null):void{
MochiServices.setContainer();
MochiServices.bringToTop();
MochiServices.send("coins_showStore", {options:_arg1}, null, null);
}
public static function requestFunding(_arg1:Object=null):void{
MochiServices.setContainer();
MochiServices.bringToTop();
MochiServices.send("social_requestFunding", _arg1);
}
public static function showItem(_arg1:Object=null):void{
if (((!(_arg1)) || (!((typeof(_arg1.item) == "string"))))){
return;
};
MochiServices.setContainer();
MochiServices.bringToTop();
MochiServices.send("coins_showItem", {options:_arg1}, null, null);
}
public static function getVersion():String{
return (MochiServices.getVersion());
}
public static function showVideo(_arg1:Object=null):void{
if (((!(_arg1)) || (!((typeof(_arg1.item) == "string"))))){
return;
};
MochiServices.setContainer();
MochiServices.bringToTop();
MochiServices.send("coins_showVideo", {options:_arg1}, null, null);
}
addEventListener(MochiSocial.LOGGED_IN, function (_arg1:Object):void{
_inventory = new MochiInventory();
});
addEventListener(MochiSocial.LOGGED_OUT, function (_arg1:Object):void{
_inventory = null;
});
}
}//package mochi.as3
Section 94
//MochiDigits (mochi.as3.MochiDigits)
package mochi.as3 {
public final class MochiDigits {
private var Sibling:MochiDigits;
private var Fragment:Number;
private var Encoder:Number;
public function MochiDigits(_arg1:Number=0, _arg2:uint=0):void{
Encoder = 0;
setValue(_arg1, _arg2);
}
public function set value(_arg1:Number):void{
setValue(_arg1);
}
public function reencode():void{
var _local1:uint;
_local1 = int((2147483647 * Math.random()));
Fragment = (Fragment ^ (_local1 ^ Encoder));
Encoder = _local1;
}
public function toString():String{
var _local1:String;
_local1 = String.fromCharCode((Fragment ^ Encoder));
if (Sibling != null){
_local1 = (_local1 + Sibling.toString());
};
return (_local1);
}
public function get value():Number{
return (Number(this.toString()));
}
public function setValue(_arg1:Number=0, _arg2:uint=0):void{
var _local3:String;
_local3 = _arg1.toString();
var _temp1 = _arg2;
_arg2 = (_arg2 + 1);
Fragment = (_local3.charCodeAt(_temp1) ^ Encoder);
if (_arg2 < _local3.length){
Sibling = new MochiDigits(_arg1, _arg2);
} else {
Sibling = null;
};
reencode();
}
public function addValue(_arg1:Number):void{
value = (value + _arg1);
}
}
}//package mochi.as3
Section 95
//MochiEventDispatcher (mochi.as3.MochiEventDispatcher)
package mochi.as3 {
public class MochiEventDispatcher {
private var eventTable:Object;
public function MochiEventDispatcher():void{
eventTable = {};
}
public function triggerEvent(_arg1:String, _arg2:Object):void{
var _local3:Object;
if (eventTable[_arg1] == undefined){
return;
};
for (_local3 in eventTable[_arg1]) {
var _local6 = eventTable[_arg1];
_local6[_local3](_arg2);
};
}
public function removeEventListener(_arg1:String, _arg2:Function):void{
var _local3:Object;
if (eventTable[_arg1] == undefined){
eventTable[_arg1] = [];
return;
};
for (_local3 in eventTable[_arg1]) {
if (eventTable[_arg1][_local3] != _arg2){
} else {
eventTable[_arg1].splice(Number(_local3), 1);
};
};
}
public function addEventListener(_arg1:String, _arg2:Function):void{
removeEventListener(_arg1, _arg2);
eventTable[_arg1].push(_arg2);
}
}
}//package mochi.as3
Section 96
//MochiEvents (mochi.as3.MochiEvents)
package mochi.as3 {
import flash.display.*;
public class MochiEvents {
public static const ALIGN_BOTTOM_LEFT:String = "ALIGN_BL";
public static const FORMAT_LONG:String = "LongForm";
public static const ALIGN_BOTTOM:String = "ALIGN_B";
public static const ACHIEVEMENT_RECEIVED:String = "AchievementReceived";
public static const FORMAT_SHORT:String = "ShortForm";
public static const ALIGN_TOP_RIGHT:String = "ALIGN_TR";
public static const ALIGN_BOTTOM_RIGHT:String = "ALIGN_BR";
public static const ALIGN_TOP:String = "ALIGN_T";
public static const ALIGN_LEFT:String = "ALIGN_L";
public static const ALIGN_RIGHT:String = "ALIGN_R";
public static const ALIGN_TOP_LEFT:String = "ALIGN_TL";
public static const ALIGN_CENTER:String = "ALIGN_C";
private static var _dispatcher:MochiEventDispatcher = new MochiEventDispatcher();
private static var gameStart:Number;
private static var levelStart:Number;
public static function endPlay():void{
MochiServices.send("events_clearRoundID", null, null, null);
}
public static function addEventListener(_arg1:String, _arg2:Function):void{
_dispatcher.addEventListener(_arg1, _arg2);
}
public static function trackEvent(_arg1:String, _arg2=null):void{
MochiServices.send("events_trackEvent", {tag:_arg1, value:_arg2}, null, null);
}
public static function removeEventListener(_arg1:String, _arg2:Function):void{
_dispatcher.removeEventListener(_arg1, _arg2);
}
public static function startSession(_arg1:String):void{
MochiServices.send("events_beginSession", {achievementID:_arg1}, null, null);
}
public static function triggerEvent(_arg1:String, _arg2:Object):void{
_dispatcher.triggerEvent(_arg1, _arg2);
}
public static function setNotifications(_arg1:MovieClip, _arg2:Object):void{
var _local3:Object;
var _local4:Object;
_local3 = {};
for (_local4 in _arg2) {
_local3[_local4] = _arg2[_local4];
};
_local3.clip = _arg1;
MochiServices.send("events_setNotifications", _local3, null, null);
}
public static function getVersion():String{
return (MochiServices.getVersion());
}
public static function startPlay(_arg1:String="gameplay"):void{
MochiServices.send("events_setRoundID", {tag:String(_arg1)}, null, null);
}
}
}//package mochi.as3
Section 97
//MochiInventory (mochi.as3.MochiInventory)
package mochi.as3 {
import flash.events.*;
import flash.utils.*;
public dynamic class MochiInventory extends Proxy {
private var _timer:Timer;
private var _names:Array;
private var _consumableProperties:Object;
private var _syncID:Number;
private var _storeSync:Object;
private var _outstandingID:Number;
private var _syncPending:Boolean;
public static const READY:String = "InvReady";
public static const ERROR:String = "Error";
public static const IO_ERROR:String = "IoError";
private static const KEY_SALT:String = " syncMaint";
public static const WRITTEN:String = "InvWritten";
public static const NOT_READY:String = "InvNotReady";
public static const VALUE_ERROR:String = "InvValueError";
private static const CONSUMER_KEY:String = "MochiConsumables";
private static var _dispatcher:MochiEventDispatcher = new MochiEventDispatcher();
public function MochiInventory():void{
MochiCoins.addEventListener(MochiCoins.ITEM_OWNED, itemOwned);
MochiCoins.addEventListener(MochiCoins.ITEM_NEW, newItems);
MochiSocial.addEventListener(MochiSocial.LOGGED_IN, loggedIn);
MochiSocial.addEventListener(MochiSocial.LOGGED_OUT, loggedOut);
_storeSync = new Object();
_syncPending = false;
_outstandingID = 0;
_syncID = 0;
_timer = new Timer(1000);
_timer.addEventListener(TimerEvent.TIMER, sync);
_timer.start();
if (MochiSocial.loggedIn){
loggedIn();
} else {
loggedOut();
};
}
private function newItems(_arg1:Object):void{
if (!this[(_arg1.id + KEY_SALT)]){
this[(_arg1.id + KEY_SALT)] = 0;
};
if (!this[_arg1.id]){
this[_arg1.id] = 0;
};
this[(_arg1.id + KEY_SALT)] = (this[(_arg1.id + KEY_SALT)] + _arg1.count);
this[_arg1.id] = (this[_arg1.id] + _arg1.count);
if (((_arg1.privateProperties) && (_arg1.privateProperties.consumable))){
if (!this[_arg1.privateProperties.tag]){
this[_arg1.privateProperties.tag] = 0;
};
this[_arg1.privateProperties.tag] = (this[_arg1.privateProperties.tag] + (_arg1.privateProperties.inc * _arg1.count));
};
}
override "http://www.adobe.com/2006/actionscript/flash/proxy"?? function getProperty(_arg1){
if (_consumableProperties == null){
triggerEvent(ERROR, {type:NOT_READY});
return (-1);
};
if (_consumableProperties[_arg1]){
return (MochiDigits(_consumableProperties[_arg1]).value);
};
return (undefined);
}
public function release():void{
MochiCoins.removeEventListener(MochiCoins.ITEM_NEW, newItems);
MochiSocial.removeEventListener(MochiSocial.LOGGED_IN, loggedIn);
MochiSocial.removeEventListener(MochiSocial.LOGGED_OUT, loggedOut);
}
override "http://www.adobe.com/2006/actionscript/flash/proxy"?? function hasProperty(_arg1):Boolean{
if (_consumableProperties == null){
triggerEvent(ERROR, {type:NOT_READY});
return (false);
};
if (_consumableProperties[_arg1] == undefined){
return (false);
};
return (true);
}
override "http://www.adobe.com/2006/actionscript/flash/proxy"?? function nextNameIndex(_arg1:int):int{
return (((_arg1)>=_names.length) ? 0 : (_arg1 + 1));
}
override "http://www.adobe.com/2006/actionscript/flash/proxy"?? function setProperty(_arg1, _arg2):void{
var _local3:MochiDigits;
if (_consumableProperties == null){
triggerEvent(ERROR, {type:NOT_READY});
return;
};
if (!(_arg2 is Number)){
triggerEvent(ERROR, {type:VALUE_ERROR, error:"Invalid type", arg:_arg2});
return;
};
if (_consumableProperties[_arg1]){
_local3 = MochiDigits(_consumableProperties[_arg1]);
if (_local3.value == _arg2){
return;
};
_local3.value = _arg2;
} else {
_names.push(_arg1);
_consumableProperties[_arg1] = new MochiDigits(_arg2);
};
_syncID++;
}
private function sync(_arg1:Event=null):void{
var _local2:Object;
var _local3:String;
if (((_syncPending) || ((_syncID == _outstandingID)))){
return;
};
_outstandingID = _syncID;
_local2 = {};
for (_local3 in _consumableProperties) {
_local2[_local3] = MochiDigits(_consumableProperties[_local3]).value;
};
MochiUserData.put(CONSUMER_KEY, _local2, putConsumableBag);
_syncPending = true;
}
override "http://www.adobe.com/2006/actionscript/flash/proxy"?? function nextName(_arg1:int):String{
return (_names[(_arg1 - 1)]);
}
private function loggedIn(_arg1:Object=null):void{
MochiUserData.get(CONSUMER_KEY, getConsumableBag);
}
override "http://www.adobe.com/2006/actionscript/flash/proxy"?? function deleteProperty(_arg1):Boolean{
if (!_consumableProperties[_arg1]){
return (false);
};
_names.splice(_names.indexOf(_arg1), 1);
delete _consumableProperties[_arg1];
return (true);
}
private function itemOwned(_arg1:Object):void{
_storeSync[_arg1.id] = {properties:_arg1.properties, count:_arg1.count};
}
private function putConsumableBag(_arg1:MochiUserData):void{
_syncPending = false;
if (_arg1.error){
triggerEvent(ERROR, {type:IO_ERROR, error:_arg1.error});
_outstandingID = -1;
};
triggerEvent(WRITTEN, {});
}
private function getConsumableBag(_arg1:MochiUserData):void{
var _local2:String;
var _local3:Number;
if (_arg1.error){
triggerEvent(ERROR, {type:IO_ERROR, error:_arg1.error});
return;
};
_consumableProperties = {};
_names = new Array();
if (_arg1.data){
for (_local2 in _arg1.data) {
_names.push(_local2);
_consumableProperties[_local2] = new MochiDigits(_arg1.data[_local2]);
};
};
for (_local2 in _storeSync) {
_local3 = _storeSync[_local2].count;
if (_consumableProperties[(_local2 + KEY_SALT)]){
_local3 = (_local3 - _consumableProperties[(_local2 + KEY_SALT)].value);
};
if (_local3 == 0){
} else {
newItems({id:_local2, count:_local3, properties:_storeSync[_local2].properties});
};
};
triggerEvent(READY, {});
}
private function loggedOut(_arg1:Object=null):void{
_consumableProperties = null;
}
public static function triggerEvent(_arg1:String, _arg2:Object):void{
_dispatcher.triggerEvent(_arg1, _arg2);
}
public static function removeEventListener(_arg1:String, _arg2:Function):void{
_dispatcher.removeEventListener(_arg1, _arg2);
}
public static function addEventListener(_arg1:String, _arg2:Function):void{
_dispatcher.addEventListener(_arg1, _arg2);
}
}
}//package mochi.as3
Section 98
//MochiScores (mochi.as3.MochiScores)
package mochi.as3 {
import flash.display.*;
import flash.text.*;
public class MochiScores {
private static var boardID:String;
public static var onErrorHandler:Object;
public static var onCloseHandler:Object;
public static function showLeaderboard(_arg1:Object=null):void{
var n:Number;
var options = _arg1;
if (options != null){
delete options.clip;
MochiServices.setContainer();
MochiServices.bringToTop();
if (options.name != null){
if ((options.name is TextField)){
if (options.name.text.length > 0){
options.name = options.name.text;
};
};
};
if (options.score != null){
if ((options.score is TextField)){
if (options.score.text.length > 0){
options.score = options.score.text;
};
} else {
if ((options.score is MochiDigits)){
options.score = options.score.value;
};
};
n = Number(options.score);
if (isNaN(n)){
} else {
if ((((n == Number.NEGATIVE_INFINITY)) || ((n == Number.POSITIVE_INFINITY)))){
} else {
if (Math.floor(n) != n){
};
options.score = n;
};
};
};
if (options.onDisplay != null){
options.onDisplay();
} else {
if (MochiServices.clip != null){
if ((MochiServices.clip is MovieClip)){
MochiServices.clip.stop();
//unresolved jump
};
};
};
} else {
options = {};
if ((MochiServices.clip is MovieClip)){
MochiServices.clip.stop();
//unresolved jump
};
};
if (options.onClose != null){
onCloseHandler = options.onClose;
} else {
onCloseHandler = function ():void{
if ((MochiServices.clip is MovieClip)){
MochiServices.clip.play();
//unresolved jump
};
};
};
if (options.onError != null){
onErrorHandler = options.onError;
} else {
onErrorHandler = null;
};
if (options.boardID == null){
if (MochiScores.boardID != null){
options.boardID = MochiScores.boardID;
};
};
MochiServices.warnID(options.boardID, true);
MochiServices.send("scores_showLeaderboard", {options:options}, null, onClose);
}
public static function closeLeaderboard():void{
MochiServices.send("scores_closeLeaderboard");
}
public static function getPlayerInfo(_arg1:Object, _arg2:Object=null):void{
MochiServices.send("scores_getPlayerInfo", null, _arg1, _arg2);
}
public static function requestList(_arg1:Object, _arg2:Object=null):void{
MochiServices.send("scores_requestList", null, _arg1, _arg2);
}
public static function scoresArrayToObjects(_arg1:Object):Object{
var _local2:Object;
var _local3:Number;
var _local4:Number;
var _local5:Object;
var _local6:Object;
var _local7:String;
var _local8:String;
_local2 = {};
for (_local7 in _arg1) {
if (typeof(_arg1[_local7]) == "object"){
if (((!((_arg1[_local7].cols == null))) && (!((_arg1[_local7].rows == null))))){
_local2[_local7] = [];
_local5 = _arg1[_local7];
_local4 = 0;
while (_local4 < _local5.rows.length) {
_local6 = {};
_local3 = 0;
while (_local3 < _local5.cols.length) {
_local6[_local5.cols[_local3]] = _local5.rows[_local4][_local3];
_local3++;
};
_local2[_local7].push(_local6);
_local4++;
};
} else {
_local2[_local7] = {};
for (_local8 in _arg1[_local7]) {
_local2[_local7][_local8] = _arg1[_local7][_local8];
};
};
} else {
_local2[_local7] = _arg1[_local7];
};
};
return (_local2);
}
public static function submit(_arg1:Number, _arg2:String, _arg3:Object=null, _arg4:Object=null):void{
_arg1 = Number(_arg1);
if (isNaN(_arg1)){
} else {
if ((((_arg1 == Number.NEGATIVE_INFINITY)) || ((_arg1 == Number.POSITIVE_INFINITY)))){
} else {
if (Math.floor(_arg1) != _arg1){
};
_arg1 = Number(_arg1);
};
};
MochiServices.send("scores_submit", {score:_arg1, name:_arg2}, _arg3, _arg4);
}
public static function onClose(_arg1:Object=null):void{
if (((((_arg1) && ((_arg1.error == true)))) && (onErrorHandler))){
if (_arg1.errorCode == null){
_arg1.errorCode = "IOError";
};
onErrorHandler(_arg1.errorCode);
MochiServices.doClose();
return;
};
onCloseHandler();
MochiServices.doClose();
}
public static function setBoardID(_arg1:String):void{
MochiServices.warnID(_arg1, true);
MochiScores.boardID = _arg1;
MochiServices.send("scores_setBoardID", {boardID:_arg1});
}
}
}//package mochi.as3
Section 99
//MochiServices (mochi.as3.MochiServices)
package mochi.as3 {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
import flash.net.*;
import flash.system.*;
public class MochiServices {
public static const CONNECTED:String = "onConnected";
private static var _container:Object;
private static var _connected:Boolean = false;
private static var _queue:Array;
private static var _swfVersion:String;
private static var _preserved:Object;
public static var netupAttempted:Boolean = false;
private static var _sendChannel:LocalConnection;
private static var _nextCallbackID:Number;
private static var _clip:MovieClip;
private static var _loader:Loader;
private static var _id:String;
private static var _services:String = "services.swf";
private static var _servURL:String = "http://www.mochiads.com/static/lib/services/";
public static var widget:Boolean = false;
private static var _timer:Timer;
private static var _sendChannelName:String;
private static var _dispatcher:MochiEventDispatcher = new MochiEventDispatcher();
private static var _callbacks:Object;
private static var _connecting:Boolean = false;
private static var _mochiLocalConnection:MovieClip;
private static var _listenChannelName:String = "__ms_";
public static var onError:Object;
public static var netup:Boolean = true;
private static var _mochiLC:String = "MochiLC.swf";
public static function isNetworkAvailable():Boolean{
return (!((Security.sandboxType == "localWithFile")));
}
public static function get connected():Boolean{
return (_connected);
}
private static function onReceive(_arg1:Object):void{
var cb:String;
var cblst:Object;
var method:*;
var methodName:String;
var obj:Object;
var pkg = _arg1;
cb = pkg.callbackID;
cblst = _callbacks[cb];
if (!cblst){
return;
};
method = cblst.callbackMethod;
methodName = "";
obj = cblst.callbackObject;
if (((obj) && ((typeof(method) == "string")))){
methodName = method;
if (obj[method] != null){
method = obj[method];
//unresolved jump
};
};
if (method != undefined){
try {
method.apply(obj, pkg.args);
} catch(error:Error) {
};
} else {
if (obj != null){
try {
obj(pkg.args);
} catch(error:Error) {
};
};
};
delete _callbacks[cb];
}
public static function send(_arg1:String, _arg2:Object=null, _arg3:Object=null, _arg4:Object=null):void{
if (_connected){
_mochiLocalConnection.send(_sendChannelName, "onReceive", {methodName:_arg1, args:_arg2, callbackID:_nextCallbackID});
} else {
if ((((_clip == null)) || (!(_connecting)))){
handleError(_arg2, _arg3, _arg4);
flush(true);
return;
};
_queue.push({methodName:_arg1, args:_arg2, callbackID:_nextCallbackID});
};
if (_clip != null){
if (_callbacks != null){
_callbacks[_nextCallbackID] = {callbackObject:_arg3, callbackMethod:_arg4};
_nextCallbackID++;
};
};
}
private static function init(_arg1:String, _arg2:Object):void{
_id = _arg1;
if (_arg2 != null){
_container = _arg2;
loadCommunicator(_arg1, _container);
};
}
private static function clickMovie(_arg1:String, _arg2:Function):MovieClip{
var _local3:Array;
var _local4:int;
var _local5:Array;
var _local6:Array;
var _local7:MovieClip;
var _local8:LocalConnection;
var _local9:String;
var _local10:ByteArray;
var _local11:ByteArray;
var _local12:uint;
var _local13:uint;
var _local14:Loader;
_local3 = [150, 21, 0, 7, 1, 0, 0, 0, 0, 98, 116, 110, 0, 7, 2, 0, 0, 0, 0, 116, 104, 105, 115, 0, 28, 150, 22, 0, 0, 99, 114, 101, 97, 116, 101, 69, 109, 112, 116, 121, 77, 111, 118, 105, 101, 67, 108, 105, 112, 0, 82, 135, 1, 0, 0, 23, 150, 13, 0, 4, 0, 0, 111, 110, 82, 101, 108, 101, 97, 115, 101, 0, 142, 8, 0, 0, 0, 0, 2, 42, 0, 114, 0, 150, 17, 0, 0, 32, 0, 7, 1, 0, 0, 0, 8, 0, 0, 115, 112, 108, 105, 116, 0, 82, 135, 1, 0, 1, 23, 150, 7, 0, 4, 1, 7, 0, 0, 0, 0, 78, 150, 8, 0, 0, 95, 98, 108, 97, 110, 107, 0, 154, 1, 0, 0, 150, 7, 0, 0, 99, 108, 105, 99, 107, 0, 150, 7, 0, 4, 1, 7, 1, 0, 0, 0, 78, 150, 27, 0, 7, 2, 0, 0, 0, 7, 0, 0, 0, 0, 0, 76, 111, 99, 97, 108, 67, 111, 110, 110, 101, 99, 116, 105, 111, 110, 0, 64, 150, 6, 0, 0, 115, 101, 110, 100, 0, 82, 79, 150, 15, 0, 4, 0, 0, 95, 97, 108, 112, 104, 97, 0, 7, 0, 0, 0, 0, 79, 150, 23, 0, 7, 0xFF, 0, 0xFF, 0, 7, 1, 0, 0, 0, 4, 0, 0, 98, 101, 103, 105, 110, 70, 105, 108, 108, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 109, 111, 118, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 100, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 100, 0, 0, 0, 7, 100, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 100, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 16, 0, 7, 0, 0, 0, 0, 4, 0, 0, 101, 110, 100, 70, 105, 108, 108, 0, 82, 23];
_local5 = [104, 0, 31, 64, 0, 7, 208, 0, 0, 12, 1, 0, 67, 2, 0xFF, 0xFF, 0xFF, 63, 3];
_local6 = [0, 64, 0, 0, 0];
_local7 = new MovieClip();
_local8 = new LocalConnection();
_local9 = ((("_click_" + Math.floor((Math.random() * 999999))) + "_") + Math.floor(new Date().time));
_local8 = new LocalConnection();
_local7.lc = _local8;
_local7.click = _arg2;
_local8.client = _local7;
_local8.connect(_local9);
_local10 = new ByteArray();
_local11 = new ByteArray();
_local11.endian = Endian.LITTLE_ENDIAN;
_local11.writeShort(1);
_local11.writeUTFBytes(((_arg1 + " ") + _local9));
_local11.writeByte(0);
_local12 = ((_local3.length + _local11.length) + 4);
_local13 = (_local12 + 35);
_local10.endian = Endian.LITTLE_ENDIAN;
_local10.writeUTFBytes("FWS");
_local10.writeByte(8);
_local10.writeUnsignedInt(_local13);
for each (_local4 in _local5) {
_local10.writeByte(_local4);
};
_local10.writeUnsignedInt(_local12);
_local10.writeByte(136);
_local10.writeShort(_local11.length);
_local10.writeBytes(_local11);
for each (_local4 in _local3) {
_local10.writeByte(_local4);
};
for each (_local4 in _local6) {
_local10.writeByte(_local4);
};
_local14 = new Loader();
_local14.loadBytes(_local10);
_local7.addChild(_local14);
return (_local7);
}
private static function detach(_arg1:Event):void{
var _local2:LoaderInfo;
_local2 = LoaderInfo(_arg1.target);
_local2.removeEventListener(Event.COMPLETE, detach);
_local2.removeEventListener(IOErrorEvent.IO_ERROR, detach);
_local2.removeEventListener(Event.COMPLETE, loadLCBridgeComplete);
_local2.removeEventListener(IOErrorEvent.IO_ERROR, loadError);
}
public static function stayOnTop():void{
_container.addEventListener(Event.ENTER_FRAME, MochiServices.bringToTop, false, 0, true);
if (_clip != null){
_clip.visible = true;
};
}
private static function loadLCBridgeComplete(_arg1:Event):void{
var _local2:Loader;
_local2 = LoaderInfo(_arg1.target).loader;
_mochiLocalConnection = MovieClip(_local2.content);
listen();
}
public static function disconnect():void{
if (((_connected) || (_connecting))){
if (_clip != null){
if (_clip.parent != null){
if ((_clip.parent is Sprite)){
Sprite(_clip.parent).removeChild(_clip);
_clip = null;
};
};
};
_connecting = (_connected = false);
flush(true);
try {
_mochiLocalConnection.close();
} catch(error:Error) {
};
};
if (_timer != null){
try {
_timer.stop();
_timer.removeEventListener(TimerEvent.TIMER, connectWait);
_timer = null;
} catch(error:Error) {
};
};
}
public static function allowDomains(_arg1:String):String{
var _local2:String;
if (Security.sandboxType != "application"){
Security.allowDomain("*");
Security.allowInsecureDomain("*");
};
if (_arg1.indexOf("http://") != -1){
_local2 = _arg1.split("/")[2].split(":")[0];
if (Security.sandboxType != "application"){
Security.allowDomain(_local2);
Security.allowInsecureDomain(_local2);
};
};
return (_local2);
}
public static function getVersion():String{
return ("3.9.1 as3");
}
public static function doClose():void{
_container.removeEventListener(Event.ENTER_FRAME, MochiServices.bringToTop);
}
public static function warnID(_arg1:String, _arg2:Boolean):void{
var _local3:Number;
_arg1 = _arg1.toLowerCase();
if (_arg1.length != 16){
return;
};
if (_arg1 == "1e113c7239048b3f"){
if (_arg2){
//unresolved jump
};
return;
} else {
if (_arg1 == "84993a1de4031cd8"){
if (_arg2){
//unresolved jump
};
return;
};
};
_local3 = 0;
while (_local3 < _arg1.length) {
switch (_arg1.charAt(_local3)){
case "0":
case "1":
case "2":
case "3":
case "4":
case "5":
case "6":
case "7":
case "8":
case "9":
case "a":
case "b":
case "c":
case "d":
case "e":
case "f":
break;
default:
return;
};
_local3++;
};
}
private static function flush(_arg1:Boolean):void{
var _local2:Object;
var _local3:Object;
if (((_clip) && (_queue))){
while (_queue.length > 0) {
_local2 = _queue.shift();
_local3 = null;
if (_local2 != null){
if (_local2.callbackID != null){
_local3 = _callbacks[_local2.callbackID];
};
delete _callbacks[_local2.callbackID];
if (((_arg1) && (!((_local3 == null))))){
handleError(_local2.args, _local3.callbackObject, _local3.callbackMethod);
};
};
};
};
}
public static function get id():String{
return (_id);
}
private static function onEvent(_arg1:Object):void{
var _local2:String;
var _local3:String;
_local2 = _arg1.target;
_local3 = _arg1.event;
switch (_local2){
case "services":
MochiServices.triggerEvent(_arg1.event, _arg1.args);
break;
case "events":
MochiEvents.triggerEvent(_arg1.event, _arg1.args);
break;
case "coins":
MochiCoins.triggerEvent(_arg1.event, _arg1.args);
break;
case "social":
MochiSocial.triggerEvent(_arg1.event, _arg1.args);
break;
};
}
private static function urlOptions(_arg1:Object):Object{
var _local2:Object;
var _local3:String;
var _local4:Array;
var _local5:Number;
var _local6:Array;
_local2 = {};
if (_arg1.stage){
_local3 = _arg1.stage.loaderInfo.parameters.mochiad_options;
} else {
_local3 = _arg1.loaderInfo.parameters.mochiad_options;
};
if (_local3){
_local4 = _local3.split("&");
_local5 = 0;
while (_local5 < _local4.length) {
_local6 = _local4[_local5].split("=");
_local2[unescape(_local6[0])] = unescape(_local6[1]);
_local5++;
};
};
return (_local2);
}
public static function addLinkEvent(_arg1:String, _arg2:String, _arg3:DisplayObjectContainer, _arg4:Function=null):void{
var vars:Object;
var avm1Click:DisplayObject;
var s:String;
var i:Number;
var x:String;
var req:URLRequest;
var loader:Loader;
var setURL:Function;
var err:Function;
var complete:Function;
var url = _arg1;
var burl = _arg2;
var btn = _arg3;
var onClick = _arg4;
vars = new Object();
vars["mav"] = getVersion();
vars["swfv"] = "9";
vars["swfurl"] = btn.loaderInfo.loaderURL;
vars["fv"] = Capabilities.version;
vars["os"] = Capabilities.os;
vars["lang"] = Capabilities.language;
vars["scres"] = ((Capabilities.screenResolutionX + "x") + Capabilities.screenResolutionY);
s = "?";
i = 0;
for (x in vars) {
if (i != 0){
s = (s + "&");
};
i = (i + 1);
s = (((s + x) + "=") + escape(vars[x]));
};
req = new URLRequest("http://link.mochiads.com/linkping.swf");
loader = new Loader();
setURL = function (_arg1:String):void{
var _local2:Rectangle;
if (avm1Click){
btn.removeChild(avm1Click);
};
avm1Click = clickMovie(_arg1, onClick);
_local2 = btn.getBounds(btn);
btn.addChild(avm1Click);
avm1Click.x = _local2.x;
avm1Click.y = _local2.y;
avm1Click.scaleX = (0.01 * _local2.width);
avm1Click.scaleY = (0.01 * _local2.height);
};
err = function (_arg1:Object):void{
netup = false;
_arg1.target.removeEventListener(_arg1.type, arguments.callee);
setURL(burl);
};
complete = function (_arg1:Object):void{
_arg1.target.removeEventListener(_arg1.type, arguments.callee);
};
if (netup){
setURL((url + s));
} else {
setURL(burl);
};
if (!((netupAttempted) || (_connected))){
netupAttempted = true;
loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, err);
loader.contentLoaderInfo.addEventListener(Event.COMPLETE, complete);
loader.load(req);
};
}
public static function setContainer(_arg1:Object=null, _arg2:Boolean=true):void{
if (_clip.parent){
_clip.parent.removeChild(_clip);
};
if (_arg1 != null){
if ((_arg1 is DisplayObjectContainer)){
_container = _arg1;
};
};
if (_arg2){
if ((_container is DisplayObjectContainer)){
DisplayObjectContainer(_container).addChild(_clip);
};
};
}
private static function handleError(_arg1:Object, _arg2:Object, _arg3:Object):void{
var args = _arg1;
var callbackObject = _arg2;
var callbackMethod = _arg3;
if (args != null){
if (args.onError != null){
args.onError.apply(null, ["NotConnected"]);
};
if (((!((args.options == null))) && (!((args.options.onError == null))))){
args.options.onError.apply(null, ["NotConnected"]);
};
};
if (callbackMethod != null){
args = {};
args.error = true;
args.errorCode = "NotConnected";
if (((!((callbackObject == null))) && ((callbackMethod is String)))){
try {
var _local5 = callbackObject;
_local5[callbackMethod](args);
} catch(error:Error) {
};
} else {
if (callbackMethod != null){
try {
callbackMethod.apply(args);
} catch(error:Error) {
};
};
};
};
}
private static function loadError(_arg1:Object):void{
_clip._mochiad_ctr_failed = true;
MochiServices.disconnect();
MochiServices.onError("IOError");
}
public static function get childClip():Object{
return (_clip);
}
private static function initComChannels():void{
if (!_connected){
_connecting = false;
_connected = true;
_mochiLocalConnection.send(_sendChannelName, "onReceive", {methodName:"handshakeDone"});
_mochiLocalConnection.send(_sendChannelName, "onReceive", {methodName:"registerGame", preserved:_preserved, id:_id, version:getVersion(), parentURL:_container.loaderInfo.loaderURL});
_clip.onReceive = onReceive;
_clip.onEvent = onEvent;
_clip.onError = function ():void{
MochiServices.onError("IOError");
};
while (_queue.length > 0) {
_mochiLocalConnection.send(_sendChannelName, "onReceive", _queue.shift());
};
};
}
public static function triggerEvent(_arg1:String, _arg2:Object):void{
_dispatcher.triggerEvent(_arg1, _arg2);
}
public static function removeEventListener(_arg1:String, _arg2:Function):void{
_dispatcher.removeEventListener(_arg1, _arg2);
}
private static function listen():void{
_mochiLocalConnection.connect(_listenChannelName);
_clip.handshake = function (_arg1:Object):void{
MochiServices.comChannelName = _arg1.newChannel;
};
}
public static function addEventListener(_arg1:String, _arg2:Function):void{
_dispatcher.addEventListener(_arg1, _arg2);
}
private static function loadLCBridge(_arg1:Object):void{
var _local2:Loader;
var _local3:String;
var _local4:URLRequest;
_local2 = new Loader();
_local3 = (_servURL + _mochiLC);
_local4 = new URLRequest(_local3);
_local2.contentLoaderInfo.addEventListener(Event.COMPLETE, detach);
_local2.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, detach);
_local2.contentLoaderInfo.addEventListener(Event.COMPLETE, loadLCBridgeComplete);
_local2.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, loadError);
_local2.load(_local4);
_arg1.addChild(_local2);
}
public static function set comChannelName(_arg1:String):void{
if (_arg1 != null){
if (_arg1.length > 3){
_sendChannelName = (_arg1 + "_fromgame");
initComChannels();
};
};
}
private static function loadCommunicator(_arg1:String, _arg2:Object):MovieClip{
var _local3:String;
var _local4:URLRequest;
var _local5:URLVariables;
if (_clip != null){
return (_clip);
};
if (!MochiServices.isNetworkAvailable()){
return (null);
};
if (urlOptions(_arg2).servURL){
_servURL = urlOptions(_arg2).servURL;
};
_local3 = (_servURL + _services);
if (urlOptions(_arg2).servicesURL){
_local3 = urlOptions(_arg2).servicesURL;
};
_listenChannelName = (_listenChannelName + ((Math.floor(new Date().time) + "_") + Math.floor((Math.random() * 99999))));
MochiServices.allowDomains(_local3);
_clip = new MovieClip();
loadLCBridge(_clip);
_loader = new Loader();
_loader.contentLoaderInfo.addEventListener(Event.COMPLETE, detach);
_loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, detach);
_loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, loadError);
_local4 = new URLRequest(_local3);
_local5 = new URLVariables();
_local5.listenLC = _listenChannelName;
_local5.mochiad_options = _arg2.loaderInfo.parameters.mochiad_options;
_local5.api_version = getVersion();
if (widget){
_local5.widget = true;
};
_local4.data = _local5;
_loader.load(_local4);
_clip.addChild(_loader);
_sendChannel = new LocalConnection();
_queue = [];
_nextCallbackID = 0;
_callbacks = {};
_timer = new Timer(10000, 1);
_timer.addEventListener(TimerEvent.TIMER, connectWait);
_timer.start();
return (_clip);
}
public static function get clip():Object{
return (_container);
}
public static function connect(_arg1:String, _arg2:Object, _arg3:Object=null):void{
var id = _arg1;
var clip = _arg2;
var onError = _arg3;
warnID(id, false);
if ((clip is DisplayObject)){
if (clip.stage == null){
};
if (((!(_connected)) && ((_clip == null)))){
_connecting = true;
init(id, clip);
};
//unresolved jump
};
if (onError != null){
MochiServices.onError = onError;
} else {
if (MochiServices.onError == null){
MochiServices.onError = function (_arg1:String):void{
};
};
};
}
public static function bringToTop(_arg1:Event=null):void{
var e = _arg1;
if (((!((MochiServices.clip == null))) && (!((MochiServices.childClip == null))))){
try {
if (MochiServices.clip.numChildren > 1){
MochiServices.clip.setChildIndex(MochiServices.childClip, (MochiServices.clip.numChildren - 1));
};
} catch(errorObject:Error) {
_container.removeEventListener(Event.ENTER_FRAME, MochiServices.bringToTop);
};
};
}
public static function connectWait(_arg1:TimerEvent):void{
if (!_connected){
_clip._mochiad_ctr_failed = true;
MochiServices.disconnect();
MochiServices.onError("IOError");
} else {
_timer.stop();
_timer.removeEventListener(TimerEvent.TIMER, connectWait);
_timer = null;
};
}
}
}//package mochi.as3
Section 100
//MochiSocial (mochi.as3.MochiSocial)
package mochi.as3 {
public class MochiSocial {
public static const LOGGED_IN:String = "LoggedIn";
public static const ACTION_CANCELED:String = "onCancel";
public static const PROPERTIES_SIZE:String = "PropertiesSize";
public static const IO_ERROR:String = "IOError";
public static const NO_USER:String = "NoUser";
public static const FRIEND_LIST:String = "FriendsList";
public static const PROFILE_DATA:String = "ProfileData";
public static const GAMEPLAY_DATA:String = "GameplayData";
public static const ACTION_COMPLETE:String = "onComplete";
public static const LOGIN_SHOW:String = "LoginShow";
public static const PROFILE_HIDE:String = "ProfileHide";
public static const USER_INFO:String = "UserInfo";
public static const PROPERTIES_SAVED:String = "PropertySaved";
public static const WIDGET_LOADED:String = "WidgetLoaded";
public static const ERROR:String = "Error";
public static const LOGGED_OUT:String = "LoggedOut";
public static const PROFILE_SHOW:String = "ProfileShow";
public static const LOGIN_HIDE:String = "LoginHide";
public static const LOGIN_SHOWN:String = "LoginShown";
public static var _user_info:Object = null;
private static var _dispatcher:MochiEventDispatcher = new MochiEventDispatcher();
public static function requestFan(_arg1:Object=null):void{
MochiServices.setContainer();
MochiServices.bringToTop();
MochiServices.send("social_requestFan", _arg1);
}
public static function postToStream(_arg1:Object=null):void{
MochiServices.setContainer();
MochiServices.bringToTop();
MochiServices.send("social_postToStream", _arg1);
}
public static function getFriendsList(_arg1:Object=null):void{
MochiServices.send("social_getFriendsList", _arg1);
}
public static function requestLogin(_arg1:Object=null):void{
MochiServices.setContainer();
MochiServices.bringToTop();
MochiServices.send("social_requestLogin", _arg1);
}
public static function getVersion():String{
return (MochiServices.getVersion());
}
public static function saveUserProperties(_arg1:Object):void{
MochiServices.send("social_saveUserProperties", _arg1);
}
public static function triggerEvent(_arg1:String, _arg2:Object):void{
_dispatcher.triggerEvent(_arg1, _arg2);
}
public static function removeEventListener(_arg1:String, _arg2:Function):void{
_dispatcher.removeEventListener(_arg1, _arg2);
}
public static function inviteFriends(_arg1:Object=null):void{
MochiServices.setContainer();
MochiServices.bringToTop();
MochiServices.send("social_inviteFriends", _arg1);
}
public static function get loggedIn():Boolean{
return (!((_user_info == null)));
}
public static function addEventListener(_arg1:String, _arg2:Function):void{
_dispatcher.addEventListener(_arg1, _arg2);
}
public static function showLoginWidget(_arg1:Object=null):void{
MochiServices.setContainer();
MochiServices.bringToTop();
MochiServices.send("social_showLoginWidget", {options:_arg1});
}
public static function getAPIURL():String{
if (!_user_info){
return (null);
};
return (_user_info.api_url);
}
public static function hideLoginWidget():void{
MochiServices.send("social_hideLoginWidget");
}
public static function getAPIToken():String{
if (!_user_info){
return (null);
};
return (_user_info.api_token);
}
MochiSocial.addEventListener(MochiSocial.LOGGED_IN, function (_arg1:Object):void{
_user_info = _arg1;
});
MochiSocial.addEventListener(MochiSocial.LOGGED_OUT, function (_arg1:Object):void{
_user_info = null;
});
}
}//package mochi.as3
Section 101
//MochiUserData (mochi.as3.MochiUserData)
package mochi.as3 {
import flash.events.*;
import flash.utils.*;
import flash.net.*;
public class MochiUserData extends EventDispatcher {
public var callback:Function;// = null
public var error:Event;// = null
public var key:String;// = null
public var operation:String;// = null
public var data;// = null
public var _loader:URLLoader;
public function MochiUserData(_arg1:String="", _arg2:Function=null){
key = null;
data = null;
error = null;
operation = null;
callback = null;
super();
this.key = _arg1;
this.callback = _arg2;
}
public function securityErrorHandler(_arg1:SecurityErrorEvent):void{
errorHandler(new IOErrorEvent(IOErrorEvent.IO_ERROR, false, false, ("security error: " + _arg1.toString())));
}
public function putEvent(_arg1):void{
request("put", serialize(_arg1));
}
public function request(_arg1:String, _arg2:ByteArray):void{
var api_url:String;
var api_token:String;
var args:URLVariables;
var req:URLRequest;
var _operation = _arg1;
var _data = _arg2;
operation = _operation;
api_url = MochiSocial.getAPIURL();
api_token = MochiSocial.getAPIToken();
if ((((api_url == null)) || ((api_token == null)))){
errorHandler(new IOErrorEvent(IOErrorEvent.IO_ERROR, false, false, "not logged in"));
return;
};
_loader = new URLLoader();
args = new URLVariables();
args.op = _operation;
args.key = key;
req = new URLRequest((((MochiSocial.getAPIURL() + "/") + "MochiUserData?") + args.toString()));
req.method = URLRequestMethod.POST;
req.contentType = "application/x-mochi-userdata";
req.requestHeaders = [new URLRequestHeader("x-mochi-services-version", MochiServices.getVersion()), new URLRequestHeader("x-mochi-api-token", api_token)];
req.data = _data;
_loader.dataFormat = URLLoaderDataFormat.BINARY;
_loader.addEventListener(Event.COMPLETE, completeHandler);
_loader.addEventListener(IOErrorEvent.IO_ERROR, errorHandler);
_loader.addEventListener(SecurityErrorEvent.SECURITY_ERROR, securityErrorHandler);
try {
_loader.load(req);
} catch(e:SecurityError) {
errorHandler(new IOErrorEvent(IOErrorEvent.IO_ERROR, false, false, ("security error: " + e.toString())));
};
}
public function completeHandler(_arg1:Event):void{
var event = _arg1;
try {
if (_loader.data.length){
data = deserialize(_loader.data);
} else {
data = null;
};
} catch(e:Error) {
errorHandler(new IOErrorEvent(IOErrorEvent.IO_ERROR, false, false, ("deserialize error: " + e.toString())));
return;
};
if (callback != null){
performCallback();
} else {
dispatchEvent(event);
};
close();
}
public function performCallback():void{
try {
callback(this);
} catch(e:Error) {
};
}
public function serialize(_arg1):ByteArray{
var _local2:ByteArray;
_local2 = new ByteArray();
_local2.objectEncoding = ObjectEncoding.AMF3;
_local2.writeObject(_arg1);
_local2.compress();
return (_local2);
}
public function errorHandler(_arg1:IOErrorEvent):void{
data = null;
error = _arg1;
if (callback != null){
performCallback();
} else {
dispatchEvent(_arg1);
};
close();
}
public function getEvent():void{
request("get", serialize(null));
}
override public function toString():String{
return ((((((((("[MochiUserData operation=" + operation) + " key=\"") + key) + "\" data=") + data) + " error=\"") + error) + "\"]"));
}
public function close():void{
if (_loader){
_loader.removeEventListener(Event.COMPLETE, completeHandler);
_loader.removeEventListener(IOErrorEvent.IO_ERROR, errorHandler);
_loader.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, securityErrorHandler);
_loader.close();
_loader = null;
};
error = null;
callback = null;
}
public function deserialize(_arg1:ByteArray){
_arg1.objectEncoding = ObjectEncoding.AMF3;
_arg1.uncompress();
return (_arg1.readObject());
}
public static function get(_arg1:String, _arg2:Function):void{
var _local3:MochiUserData;
_local3 = new MochiUserData(_arg1, _arg2);
_local3.getEvent();
}
public static function put(_arg1:String, _arg2, _arg3:Function):void{
var _local4:MochiUserData;
_local4 = new MochiUserData(_arg1, _arg3);
_local4.putEvent(_arg2);
}
}
}//package mochi.as3
Section 102
//BGMusic (ui.BGMusic)
package ui {
import flash.display.*;
import flash.events.*;
import flash.media.*;
public class BGMusic extends MovieClip {
private static var channel:SoundChannel = null;
private static var position:Number = 0;
private static var soundPlay:Boolean = true;
private static var sound:Sound = null;
public function BGMusic(){
this.mouseChildren = false;
this.buttonMode = true;
if (stage){
init();
} else {
addEventListener(Event.ENTER_FRAME, init);
};
this.addEventListener(MouseEvent.CLICK, toggleSound);
}
private function closeSound():void{
soundPlay = false;
this.stop();
if (channel){
position = channel.position;
channel.stop();
channel.removeEventListener(Event.SOUND_COMPLETE, onComplete);
};
}
private function init(_arg1:Event=null):void{
removeEventListener(Event.ENTER_FRAME, init);
if (!sound){
sound = new bg_sound();
};
if (soundPlay){
showSound();
} else {
closeSound();
};
}
private function showSound():void{
soundPlay = true;
this.play();
if (channel){
channel.removeEventListener(Event.SOUND_COMPLETE, onComplete);
channel.stop();
};
channel = sound.play(position, 0, new SoundTransform(1));
channel.addEventListener(Event.SOUND_COMPLETE, onComplete);
}
private function toggleSound(_arg1:MouseEvent):void{
if (soundPlay){
closeSound();
} else {
showSound();
};
}
private function onComplete(_arg1:Event):void{
if (channel){
channel.stop();
};
position = 0;
channel = sound.play(position, 0, new SoundTransform(1));
channel.addEventListener(Event.SOUND_COMPLETE, onComplete);
}
private function onRemoved(_arg1:Event):void{
removeEventListener(Event.REMOVED_FROM_STAGE, onRemoved);
this.removeEventListener(MouseEvent.CLICK, toggleSound);
if (soundPlay){
closeSound();
soundPlay = true;
};
}
}
}//package ui
Section 103
//bg_sound (bg_sound)
package {
import flash.media.*;
public dynamic class bg_sound extends Sound {
}
}//package
Section 104
//chuigan (chuigan)
package {
import flash.media.*;
public dynamic class chuigan extends Sound {
}
}//package
Section 105
//in (in)
package {
import flash.media.*;
public dynamic class in extends Sound {
}
}//package
Section 106
//ku (ku)
package {
import flash.media.*;
public dynamic class ku extends Sound {
}
}//package
Section 107
//lost (lost)
package {
import flash.media.*;
public dynamic class lost extends Sound {
}
}//package
Section 108
//MochiBot (MochiBot)
package {
import flash.display.*;
import flash.net.*;
import flash.system.*;
public dynamic class MochiBot extends Sprite {
public static function track(_arg1:Sprite, _arg2:String):MochiBot{
var _local3:MochiBot;
var _local4:String;
var _local5:URLVariables;
var _local6:String;
var _local7:URLRequest;
var _local8:Loader;
if (Security.sandboxType == "localWithFile"){
return (null);
};
_local3 = new (MochiBot);
_arg1.addChild(_local3);
Security.allowDomain("*");
Security.allowInsecureDomain("*");
_local4 = "http://core.mochibot.com/my/core.swf";
_local5 = new URLVariables();
_local5["sb"] = Security.sandboxType;
_local5["v"] = Capabilities.version;
_local5["swfid"] = _arg2;
_local5["mv"] = "8";
_local5["fv"] = "9";
_local6 = _local3.root.loaderInfo.loaderURL;
if (_local6.indexOf("http") == 0){
_local5["url"] = _local6;
} else {
_local5["url"] = "local";
};
_local7 = new URLRequest(_local4);
_local7.contentType = "application/x-www-form-urlencoded";
_local7.method = URLRequestMethod.POST;
_local7.data = _local5;
_local8 = new Loader();
_local3.addChild(_local8);
_local8.load(_local7);
return (_local3);
}
}
}//package
Section 109
//money (money)
package {
import flash.media.*;
public dynamic class money extends Sound {
}
}//package
Section 110
//pass (pass)
package {
import flash.media.*;
public dynamic class pass extends Sound {
}
}//package
Section 111
//show (show)
package {
import flash.media.*;
public dynamic class show extends Sound {
}
}//package
Section 112
//win (win)
package {
import flash.media.*;
public dynamic class win extends Sound {
}
}//package
Section 113
//xiao (xiao)
package {
import flash.media.*;
public dynamic class xiao extends Sound {
}
}//package
Section 114
//顾客1 (顾客1)
package {
import cuitenail.ui.*;
public dynamic class 顾客1 extends Cser {
}
}//package
Section 115
//顾客2 (顾客2)
package {
import cuitenail.ui.*;
public dynamic class 顾客2 extends Cser {
}
}//package
Section 116
//顾客3 (顾客3)
package {
import cuitenail.ui.*;
public dynamic class 顾客3 extends Cser {
}
}//package