var _STRINGS={Ad:{Mobile:{Preroll:{ReadyIn:"The game is ready in ",Loading:"Your game is loading...",Close:"Close"},Header:{ReadyIn:"The game is ready in ",Loading:"Your game is loading...",Close:"Close"},End:{ReadyIn:"Advertisement ends in ",Loading:"Please wait ...",Close:"Close"}}},Splash:{Loading:"Loading ...",TapToStart:"TAP TO START"},Game:{Score:"Score:",Coins:"Coins:",Shop:"SHOP",Protect:"PROTECT THE BALLOON",Use:"Use",Best:"Best",High:"High",HighScore:"Hi-Score:",Woops:"Whoops!",BuyItems:"Buy Items", ToUnlock:" points to unlock",StartTutorial:"Start the tutorial?",MoreGames:"More Games",Play:"Play",Settings:"Settings",Select:"Select",Selected:"Selected",ShareFacebook:"Share Facebook",GamePause:"Game Pause",GameOver:"Game Over",OK:"OK",Yes:"Yes",No:"No"},ItemsBalloon:{1:"Original Balloon",2:"Ombre Balloon",3:"Chevron Balloon",4:"Polca Dot Balloon",5:"Panda Balloon",6:"Donut Balloon",7:"Moustache Balloon"}},_LVL=[[{type:"EntityRectangle",x:60,y:-470,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle", x:60,y:-495,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-520,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-545,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-570,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-595,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-620,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-645,settings:{w:420,h:20,checkObstacle:1}}, {type:"EntityRectangle",x:60,y:-670,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-695,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-720,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-745,settings:{w:420,h:20,checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityCircle",x:115,y:-460,settings:{checkObstacle:1}},{type:"EntityCircle",x:170,y:-350,settings:{checkObstacle:1}},{type:"EntityCircle",x:280,y:-350,settings:{checkObstacle:1}}, {type:"EntityCircle",x:390,y:-350,settings:{checkObstacle:1}},{type:"EntityCircle",x:60,y:-350,settings:{checkObstacle:1}},{type:"EntityCircle",x:225,y:-460,settings:{checkObstacle:1}},{type:"EntityCircle",x:335,y:-460,settings:{checkObstacle:1}},{type:"EntityCircle",x:280,y:-570,settings:{checkObstacle:1}},{type:"EntityCircle",x:170,y:-570,settings:{checkObstacle:1}},{type:"EntityCircle",x:225,y:-680,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityObstacleDynamic",x:276, y:-460,settings:{checkObstacle:1}},{type:"EntityObstacleDynamic",x:52,y:-460,settings:{checkObstacle:1}},{type:"EntityObstacleDynamic",x:164,y:-648,settings:{checkObstacle:1}},{type:"EntityObstacleDynamic",x:276,y:-836,settings:{checkObstacle:1}},{type:"EntityObstacleDynamic",x:52,y:-836,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityDiamond",x:45,y:-500,settings:{checkObstacle:1}},{type:"EntityDiamond",x:45,y:-580,settings:{checkObstacle:1}},{type:"EntityDiamond",x:45, y:-660,settings:{checkObstacle:1}},{type:"EntityDiamond",x:205,y:-500,settings:{checkObstacle:1}},{type:"EntityDiamond",x:205,y:-580,settings:{checkObstacle:1}},{type:"EntityDiamond",x:205,y:-660,settings:{checkObstacle:1}},{type:"EntityDiamond",x:365,y:-740,settings:{checkObstacle:1}},{type:"EntityDiamond",x:365,y:-580,settings:{checkObstacle:1}},{type:"EntityDiamond",x:365,y:-500,settings:{checkObstacle:1}},{type:"EntityDiamond",x:45,y:-740,settings:{checkObstacle:1}},{type:"EntityDiamond",x:205, y:-740,settings:{checkObstacle:1}},{type:"EntityDiamond",x:365,y:-660,settings:{checkObstacle:1}},{type:"EntityDiamond",x:45,y:-420,settings:{checkObstacle:1}},{type:"EntityDiamond",x:205,y:-420,settings:{checkObstacle:1}},{type:"EntityDiamond",x:365,y:-420,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityPentagon",x:60,y:-450,settings:{checkObstacle:1}},{type:"EntityPentagon",x:165,y:-450,settings:{checkObstacle:1}},{type:"EntityPentagon",x:270,y:-450,settings:{checkObstacle:1}}, {type:"EntityPentagon",x:375,y:-450,settings:{checkObstacle:1}},{type:"EntityPentagon",x:165,y:-660,settings:{checkObstacle:1}},{type:"EntityPentagon",x:215,y:-556,settings:{checkObstacle:1}},{type:"EntityPentagon",x:320,y:-556,settings:{checkObstacle:1}},{type:"EntityPentagon",x:110,y:-556,settings:{checkObstacle:1}},{type:"EntityPentagon",x:268,y:-660,settings:{checkObstacle:1}},{type:"EntityPentagon",x:215,y:-760,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityBigPentagon", x:280,y:-510,settings:{checkObstacle:1}},{type:"EntityBigPentagon",x:60,y:-510,settings:{checkObstacle:1}},{type:"EntityBigPentagon",x:176,y:-724,settings:{checkObstacle:1}},{type:"EntityBigPentagon",x:280,y:-938,settings:{checkObstacle:1}},{type:"EntityBigPentagon",x:60,y:-938,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityBigOval",x:60,y:-500,settings:{checkObstacle:1}},{type:"EntityBigOval",x:210,y:-500,settings:{checkObstacle:1}},{type:"EntityBigOval",x:360,y:-500, settings:{checkObstacle:1}},{type:"EntityBigOval",x:130,y:-700,settings:{checkObstacle:1}},{type:"EntityBigOval",x:290,y:-700,settings:{checkObstacle:1}},{type:"EntityBigOval",x:210,y:-900,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityCircle",x:36,y:-784,settings:{r:180,checkObstacle:0}},{type:"EntityCircle",x:412,y:-784,settings:{r:180,checkObstacle:0}},{type:"EntityCircle",x:-44,y:-524,settings:{r:180,checkObstacle:0}},{type:"EntityCircle",x:364,y:-516,settings:{r:180, checkObstacle:0}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityRectangle",x:135,y:-748,settings:{w:25,h:420,nColor:"#253D54",isStatic:1,dynamicType:2,isObstacle:0,checkObstacle:0}},{type:"EntityRectangle",x:360,y:-748,settings:{w:25,h:420,nColor:"#253D54",isStatic:1,dynamicType:2,isObstacle:0,checkObstacle:0}},{type:"EntityRectangle",x:165,y:-348,settings:{w:190,h:20}},{type:"EntityCircle",x:165,y:-390,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:205,y:-390,settings:{checkObstacle:1, r:15}},{type:"EntityCircle",x:245,y:-390,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:285,y:-390,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:325,y:-390,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:165,y:-435,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:205,y:-435,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:245,y:-435,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:285,y:-435,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:325, y:-435,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:165,y:-525,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:205,y:-525,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:245,y:-525,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:285,y:-525,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:325,y:-525,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:165,y:-570,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:205,y:-570,settings:{checkObstacle:1, r:15}},{type:"EntityCircle",x:245,y:-570,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:285,y:-570,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:325,y:-570,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:165,y:-660,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:205,y:-660,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:245,y:-660,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:285,y:-660,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:325, y:-660,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:165,y:-705,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:205,y:-705,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:245,y:-705,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:285,y:-705,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:325,y:-705,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:165,y:-480,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:205,y:-480,settings:{checkObstacle:1, r:15}},{type:"EntityCircle",x:245,y:-480,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:285,y:-480,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:325,y:-480,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:165,y:-615,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:205,y:-615,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:245,y:-615,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:285,y:-615,settings:{checkObstacle:1,r:15}},{type:"EntityCircle",x:325, y:-615,settings:{checkObstacle:1,r:15}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityRectangle",x:-15,y:-800,settings:{w:50,h:480,nColor:"#253D54",isStatic:1,dynamicType:2}},{type:"EntityRectangle",x:510,y:-800,settings:{w:50,h:480,nColor:"#253D54",isStatic:1,dynamicType:2}},{type:"EntityRectangle",x:-15,y:-800,settings:{w:190,h:50,nColor:"#253D54",isStatic:1,dynamicType:2}},{type:"EntityRectangle",x:370,y:-800,settings:{w:190,h:50,nColor:"#253D54",isStatic:1,dynamicType:2}},{type:"EntityRectangle", x:165,y:-348,settings:{w:220,h:20,checkObstacle:1}},{type:"EntitySmallStars",x:60,y:-720,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:170,y:-720,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:280,y:-720,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:390,y:-720,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:116,y:-604,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:230,y:-604,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:340,y:-604,settings:{checkObstacle:1}}, {type:"EntitySmallStars",x:60,y:-500,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:170,y:-500,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:280,y:-500,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:390,y:-500,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityRectangle",x:-15,y:-800,settings:{w:50,h:480,nColor:"#253D54",isStatic:1,dynamicType:2}},{type:"EntityRectangle",x:515,y:-800,settings:{w:50,h:480,nColor:"#253D54",isStatic:1,dynamicType:2}}, {type:"EntityRectangle",x:-15,y:-800,settings:{w:190,h:50,nColor:"#253D54",isStatic:1,dynamicType:2}},{type:"EntityRectangle",x:375,y:-800,settings:{w:190,h:50,nColor:"#253D54",isStatic:1,dynamicType:2}},{type:"EntityRectangle",x:-72,y:-632,settings:{w:190,h:50,nColor:"#253D54",isStatic:1,dynamicType:2}},{type:"EntityRectangle",x:436,y:-552,settings:{w:190,h:50,nColor:"#253D54",isStatic:1,dynamicType:2}},{type:"EntityRectangle",x:-16,y:-336,settings:{w:190,h:50,nColor:"#253D54",isStatic:1,dynamicType:2}}, {type:"EntityRectangle",x:375,y:-336,settings:{w:190,h:50,nColor:"#253D54",isStatic:1,dynamicType:2}},{type:"EntityPlus",x:416,y:-660,settings:{checkObstacle:1}},{type:"EntityPlus",x:88,y:-716,settings:{checkObstacle:1}},{type:"EntityPlus",x:208,y:-484,settings:{checkObstacle:1}},{type:"EntityPlus",x:168,y:-740,settings:{checkObstacle:1}},{type:"EntityPlus",x:224,y:-676,settings:{checkObstacle:1}},{type:"EntityPlus",x:324,y:-740,settings:{checkObstacle:1}},{type:"EntityPlus",x:76,y:-564,settings:{checkObstacle:1}}, {type:"EntityPlus",x:164,y:-596,settings:{checkObstacle:1}},{type:"EntityPlus",x:292,y:-544,settings:{checkObstacle:1}},{type:"EntityPlus",x:112,y:-460,settings:{checkObstacle:1}},{type:"EntityPlus",x:376,y:-532,settings:{checkObstacle:1}},{type:"EntityPlus",x:408,y:-736,settings:{checkObstacle:1}},{type:"EntityPlus",x:244,y:-788,settings:{checkObstacle:1}},{type:"EntityPlus",x:324,y:-632,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityRectangle",x:0,y:-800,settings:{w:60, h:450,nColor:"#253D54",dynamicType:2,isStatic:1}},{type:"EntityRectangle",x:480,y:-800,settings:{w:60,h:450,nColor:"#253D54",dynamicType:2,isStatic:1}},{type:"EntityRectangle",x:220,y:-800,settings:{checkObstacle:1}},{type:"EntityRectangle",x:100,y:-800,settings:{checkObstacle:1}},{type:"EntityRectangle",x:340,y:-800,settings:{checkObstacle:1}},{type:"EntityRectangle",x:100,y:-690,settings:{checkObstacle:1}},{type:"EntityRectangle",x:220,y:-690,settings:{checkObstacle:1}},{type:"EntityRectangle", x:340,y:-690,settings:{checkObstacle:1}},{type:"EntityRectangle",x:100,y:-580,settings:{checkObstacle:1}},{type:"EntityRectangle",x:220,y:-580,settings:{checkObstacle:1}},{type:"EntityRectangle",x:340,y:-580,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityRectangle",x:0,y:-800,settings:{w:60,h:450,nColor:"#253D54",isStatic:1,dynamicType:2,isObstacle:0}},{type:"EntityRectangle",x:480,y:-800,settings:{w:60,h:450,nColor:"#253D54",isStatic:1,dynamicType:2,isObstacle:0}},{type:"EntityCircle", x:370,y:-656,settings:{checkObstacle:1}},{type:"EntityCircle",x:215,y:-808,settings:{checkObstacle:1}},{type:"EntityCircle",x:70,y:-656,settings:{checkObstacle:1}},{type:"EntityCircle",x:215,y:-512,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:348,y:-512,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:220,y:-660,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:360,y:-800,settings:{checkObstacle:1}},{type:"EntitySmallStars",x:92,y:-796,settings:{checkObstacle:1}},{type:"EntitySmallStars", x:96,y:-508,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityRectangle",x:0,y:-800,settings:{w:60,h:450,nColor:"#253D54",dynamicType:2,isStatic:1}},{type:"EntityRectangle",x:480,y:-800,settings:{w:60,h:450,nColor:"#253D54",dynamicType:2,isStatic:1}},{type:"EntityBigStars",x:260,y:-468,settings:{checkObstacle:1}},{type:"EntityBigStars",x:240,y:-892,settings:{checkObstacle:1}},{type:"EntityBigStars",x:72,y:-684,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}], [{type:"EntityRectangle",x:0,y:-800,settings:{w:60,h:450,nColor:"#253D54",dynamicType:2,isStatic:1}},{type:"EntityRectangle",x:480,y:-800,settings:{w:60,h:450,nColor:"#253D54",dynamicType:2,isStatic:1}},{type:"EntityCircle",x:244,y:-728,settings:{r:10}},{type:"EntityCircle",x:124,y:-796,settings:{r:10}},{type:"EntityCircle",x:88,y:-732,settings:{r:10}},{type:"EntityCircle",x:120,y:-652,settings:{r:10}},{type:"EntityCircle",x:252,y:-796,settings:{r:10}},{type:"EntityCircle",x:244,y:-536,settings:{r:10}}, {type:"EntityCircle",x:340,y:-792,settings:{r:10}},{type:"EntityCircle",x:420,y:-788,settings:{r:10}},{type:"EntityCircle",x:424,y:-716,settings:{r:10}},{type:"EntityCircle",x:380,y:-664,settings:{r:10}},{type:"EntityCircle",x:176,y:-728,settings:{r:10}},{type:"EntityCircle",x:432,y:-612,settings:{r:10}},{type:"EntityCircle",x:292,y:-640,settings:{r:10}},{type:"EntityCircle",x:108,y:-576,settings:{r:10}},{type:"EntityCircle",x:164,y:-608,settings:{r:10}},{type:"EntityCircle",x:236,y:-592,settings:{r:10}}, {type:"EntityCircle",x:328,y:-564,settings:{r:10}},{type:"EntityCircle",x:412,y:-548,settings:{r:10}},{type:"EntityCircle",x:428,y:-492,settings:{r:10}},{type:"EntityCircle",x:108,y:-504,settings:{r:10}},{type:"EntityCircle",x:176,y:-536,settings:{r:10}},{type:"EntityCircle",x:100,y:-400,settings:{r:10}},{type:"EntityCircle",x:332,y:-512,settings:{r:10}},{type:"EntityCircle",x:132,y:-444,settings:{r:10}},{type:"EntityCircle",x:292,y:-472,settings:{r:10}},{type:"EntityCircle",x:372,y:-456,settings:{r:10}}, {type:"EntityCircle",x:424,y:-436,settings:{r:10}},{type:"EntityCircle",x:396,y:-404,settings:{r:10}},{type:"EntityCircle",x:200,y:-408,settings:{r:10}},{type:"EntityCircle",x:344,y:-420,settings:{r:10}},{type:"EntityCircle",x:400,y:-404,settings:{r:10}},{type:"EntityCircle",x:360,y:-720,settings:{r:10}},{type:"EntityCircle",x:188,y:-668,settings:{r:10}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityRectangle",x:60,y:-260,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-285, settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-310,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-335,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-360,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityCircle",x:440,y:-400,settings:{r:15,checkObstacle:1}},{type:"EntityCircle",x:76,y:-400,settings:{r:15,checkObstacle:1}},{type:"EntityCircle",x:124,y:-400,settings:{r:15,checkObstacle:1}},{type:"EntityCircle",x:172,y:-400,settings:{r:15, checkObstacle:1}},{type:"EntityCircle",x:220,y:-400,settings:{r:15,checkObstacle:1}},{type:"EntityCircle",x:264,y:-400,settings:{r:15,checkObstacle:1}},{type:"EntityCircle",x:308,y:-400,settings:{r:15,checkObstacle:1}},{type:"EntityCircle",x:352,y:-400,settings:{r:15,checkObstacle:1}},{type:"EntityCircle",x:396,y:-400,settings:{r:15,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-430,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-455,settings:{w:420,h:20,checkObstacle:1}}, {type:"EntityRectangle",x:60,y:-480,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-505,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-530,settings:{w:420,h:20,checkObstacle:1}},{type:"EntityCircle",x:368,y:-620,settings:{r:40,checkObstacle:1}},{type:"EntityCircle",x:84,y:-620,settings:{r:40,checkObstacle:1}},{type:"EntityCircle",x:232,y:-620,settings:{r:40,checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityRectangle",x:150,y:-296,settings:{w:20, h:20,checkObstacle:1}},{type:"EntityRectangle",x:175,y:-296,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:200,y:-296,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:225,y:-296,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:250,y:-296,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:275,y:-296,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:300,y:-296,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:325, y:-296,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:375,y:-296,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityCircle",x:196,y:-460,settings:{r:80,checkObstacle:1}},{type:"EntityRectangle",x:150,y:-484,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:175,y:-484,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:200,y:-484,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:225,y:-484,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle", x:250,y:-484,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:275,y:-484,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:300,y:-484,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:325,y:-484,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:350,y:-484,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityCircle",x:116,y:-656,settings:{r:80,checkObstacle:1}},{type:"EntityCircle",x:292,y:-652,settings:{r:80,checkObstacle:1}},{type:"EntityRectangle", x:375,y:-484,settings:{w:20,h:20,checkObstacle:1}},{type:"EntityRectangle",x:350,y:-296,settings:{w:20,h:20,checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityRectangle",x:60,y:-380,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:142,y:-380,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:224,y:-380,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:306,y:-380,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:388,y:-380,settings:{w:80, h:5,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-410,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:142,y:-410,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:224,y:-410,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:306,y:-410,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:388,y:-410,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-440,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:142,y:-440, settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:224,y:-440,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:306,y:-440,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:388,y:-440,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-470,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:142,y:-470,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:224,y:-470,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle", x:306,y:-470,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:388,y:-470,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-500,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:142,y:-500,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:224,y:-500,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:306,y:-500,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:388,y:-500,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle", x:60,y:-530,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:142,y:-530,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:224,y:-530,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:306,y:-530,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:388,y:-530,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-560,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:142,y:-560,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle", x:224,y:-560,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:306,y:-560,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:388,y:-560,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-590,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:142,y:-590,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:224,y:-590,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:306,y:-590,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle", x:388,y:-590,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-620,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:142,y:-620,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:224,y:-620,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:306,y:-620,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:388,y:-620,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:60,y:-650,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle", x:142,y:-650,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:224,y:-650,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:306,y:-650,settings:{w:80,h:5,checkObstacle:1}},{type:"EntityRectangle",x:388,y:-650,settings:{w:80,h:5,checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityRectangle",x:188,y:-268,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:247,y:-267,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:307,y:-267,settings:{w:40, h:40,checkObstacle:1}},{type:"EntityRectangle",x:367,y:-267,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:187,y:-378,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:247,y:-378,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:307,y:-378,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:367,y:-378,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:188,y:-485,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:190, y:-592,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:250,y:-485,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:310,y:-485,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:370,y:-485,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:250,y:-592,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:310,y:-592,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityRectangle",x:370,y:-592,settings:{w:40,h:40,checkObstacle:1}},{type:"EntityPlus", x:210,y:-328,settings:{checkObstacle:1}},{type:"EntityPlus",x:390,y:-328,settings:{checkObstacle:1}},{type:"EntityPlus",x:270,y:-328,settings:{checkObstacle:1}},{type:"EntityPlus",x:330,y:-328,settings:{checkObstacle:1}},{type:"EntityPlus",x:150,y:-544,settings:{checkObstacle:1}},{type:"EntityPlus",x:150,y:-652,settings:{checkObstacle:1}},{type:"EntityPlus",x:150,y:-436,settings:{checkObstacle:1}},{type:"EntityPlus",x:210,y:-436,settings:{checkObstacle:1}},{type:"EntityPlus",x:270,y:-436,settings:{checkObstacle:1}}, {type:"EntityPlus",x:330,y:-436,settings:{checkObstacle:1}},{type:"EntityPlus",x:390,y:-436,settings:{checkObstacle:1}},{type:"EntityPlus",x:210,y:-544,settings:{checkObstacle:1}},{type:"EntityPlus",x:270,y:-544,settings:{checkObstacle:1}},{type:"EntityPlus",x:330,y:-544,settings:{checkObstacle:1}},{type:"EntityPlus",x:390,y:-544,settings:{checkObstacle:1}},{type:"EntityPlus",x:210,y:-652,settings:{checkObstacle:1}},{type:"EntityPlus",x:270,y:-652,settings:{checkObstacle:1}},{type:"EntityPlus",x:330, y:-652,settings:{checkObstacle:1}},{type:"EntityPlus",x:390,y:-652,settings:{checkObstacle:1}},{type:"EntityPlus",x:150,y:-328,settings:{checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntitySmallPentagon",x:-264,y:-520,settings:{checkObstacle:1,isFall:1}},{type:"EntitySmallPentagon",x:-460,y:-756,settings:{checkObstacle:1,isFall:1}},{type:"EntitySmallPentagon",x:-172,y:-672,settings:{checkObstacle:1,isFall:1}},{type:"EntitySmallPentagon",x:548,y:-868,settings:{checkObstacle:1,isFall:1, fallLeft:1}},{type:"EntitySmallPentagon",x:608,y:-672,settings:{checkObstacle:1,isFall:1,fallLeft:1}},{type:"EntitySmallPentagon",x:808,y:-972,settings:{checkObstacle:1,isFall:1,fallLeft:1}},{type:"EntitySmallPentagon",x:-288,y:-780,settings:{checkObstacle:1,isFall:1}},{type:"EntitySmallPentagon",x:-416,y:-584,settings:{checkObstacle:1,isFall:1}},{type:"EntitySmallPentagon",x:820,y:-676,settings:{checkObstacle:1,isFall:1,fallLeft:1}},{type:"EntitySmallPentagon",x:732,y:-808,settings:{checkObstacle:1, isFall:1,fallLeft:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityCircle",x:188,y:-852,settings:{r:80,checkObstacle:1}},{type:"EntityCircle",x:140,y:-455,settings:{r:60,checkObstacle:1}},{type:"EntityCircle",x:285,y:-455,settings:{r:60,checkObstacle:1}},{type:"EntityCircle",x:344,y:-572,settings:{r:20,checkObstacle:1}},{type:"EntityCircle",x:152,y:-572,settings:{r:20,checkObstacle:1}},{type:"EntityCircle",x:196,y:-532,settings:{r:20,checkObstacle:1}},{type:"EntityCircle",x:248,y:-500,settings:{r:20, checkObstacle:1}},{type:"EntityCircle",x:300,y:-532,settings:{r:20,checkObstacle:1}},{type:"EntityCircle",x:256,y:-600,settings:{r:10,checkObstacle:1}},{type:"EntityCircle",x:228,y:-600,settings:{r:10,checkObstacle:1}},{type:"EntityCircle",x:256,y:-572,settings:{r:10,checkObstacle:1}},{type:"EntityCircle",x:284,y:-600,settings:{r:10,checkObstacle:1}},{type:"EntityCircle",x:256,y:-628,settings:{r:10,checkObstacle:1}},{type:"EntityCircle",x:256,y:-656,settings:{r:10,checkObstacle:1}},{type:"EntityCircle", x:256,y:-684,settings:{r:10,checkObstacle:1}},{type:"EntityCircle",x:190,y:-320,settings:{r:80,checkObstacle:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityPlus",x:-328,y:-648,settings:{isFall:1}},{type:"EntityPlus",x:-116,y:-820,settings:{isFall:1}},{type:"EntityPlus",x:-336,y:-764,settings:{isFall:1}},{type:"EntityPlus",x:-272,y:-892,settings:{isFall:1}},{type:"EntityPlus",x:-424,y:-812,settings:{isFall:1}},{type:"EntityPlus",x:-552,y:-712,settings:{isFall:1}},{type:"EntityPlus",x:828,y:-892, settings:{isFall:1,fallLeft:1}},{type:"EntityPlus",x:952,y:-792,settings:{isFall:1,fallLeft:1}},{type:"EntityPlus",x:1076,y:-684,settings:{isFall:1,fallLeft:1}},{type:"EntityPlus",x:576,y:-820,settings:{isFall:1,fallLeft:1}},{type:"EntityPlus",x:812,y:-764,settings:{isFall:1,fallLeft:1}},{type:"EntityPlus",x:824,y:-648,settings:{isFall:1,fallLeft:1}},{type:"EntityPlus",x:-212,y:-736,settings:{isFall:1}},{type:"EntityPlus",x:684,y:-724,settings:{isFall:1,fallLeft:1}},{type:"EntitySensor",x:0,y:-290}], [{type:"EntityBigOval",x:-228,y:-556,settings:{isFall:1}},{type:"EntityBigOval",x:-404,y:-696,settings:{isFall:1}},{type:"EntityBigOval",x:840,y:-740,settings:{isFall:1,fallLeft:1}},{type:"EntityBigOval",x:652,y:-968,settings:{isFall:1,fallLeft:1}},{type:"EntityBigOval",x:-148,y:-784,settings:{isFall:1}},{type:"EntityBigOval",x:-260,y:-972,settings:{isFall:1}},{type:"EntityBigOval",x:548,y:-784,settings:{isFall:1,fallLeft:1}},{type:"EntityBigOval",x:664,y:-588,settings:{isFall:1,fallLeft:1}},{type:"EntitySensor", x:0,y:-290}],[{type:"EntitySmallTriangle",x:-164,y:-692,settings:{isFall:1}},{type:"EntitySmallTriangle",x:728,y:-656,settings:{isFall:1,fallLeft:1}},{type:"EntitySmallTriangle",x:-352,y:-752,settings:{isFall:1}},{type:"EntitySmallTriangle",x:-564,y:-624,settings:{isFall:1}},{type:"EntitySmallTriangle",x:-364,y:-584,settings:{isFall:1}},{type:"EntitySmallTriangle",x:-196,y:-484,settings:{isFall:1}},{type:"EntitySmallTriangle",x:556,y:-588,settings:{isFall:1,fallLeft:1}},{type:"EntitySmallTriangle", x:648,y:-776,settings:{isFall:1,fallLeft:1}},{type:"EntitySmallTriangle",x:884,y:-724,settings:{isFall:1,fallLeft:1}},{type:"EntitySmallTriangle",x:888,y:-508,settings:{isFall:1,fallLeft:1}},{type:"EntitySensor",x:0,y:-290}],[{type:"EntityCircle",x:-264,y:-780,settings:{r:100,isFall:1}},{type:"EntityCircle",x:-360,y:-500,settings:{r:50,isFall:1}},{type:"EntityCircle",x:-392,y:-652,settings:{r:30,isFall:1}},{type:"EntityCircle",x:-368,y:-848,settings:{r:100,isFall:1}},{type:"EntityCircle",x:688,y:-592, settings:{r:100,isFall:1,fallLeft:1}},{type:"EntityCircle",x:632,y:-440,settings:{r:50,isFall:1,fallLeft:1}},{type:"EntityCircle",x:592,y:-516,settings:{r:50,isFall:1,fallLeft:1}},{type:"EntityCircle",x:588,y:-772,settings:{r:30,isFall:1,fallLeft:1}},{type:"EntityCircle",x:-304,y:-608,settings:{r:100,isFall:1}},{type:"EntityCircle",x:560,y:-692,settings:{r:100,isFall:1,fallLeft:1}},{type:"EntityCircle",x:716,y:-768,settings:{r:50,isFall:1,fallLeft:1}},{type:"EntitySensor",x:0,y:-290}]];var _SETTINGS={API:{Enabled:!1,Log:{Events:{InitializeGame:!1,EndGame:!1,Level:{Begin:!1,End:!1,Win:!1,Lose:!1,Draw:!1}}}},Ad:{Mobile:{Preroll:{Enabled:!1,Duration:5,Width:300,Height:250,Rotation:{Enabled:!1,Weight:{MobileAdInGamePreroll:40,MobileAdInGamePreroll2:40,MobileAdInGamePreroll3:20}}},Header:{Enabled:!1,Duration:5,Width:320,Height:50,Rotation:{Enabled:!1,Weight:{MobileAdInGameHeader:40,MobileAdInGameHeader2:40,MobileAdInGameHeader3:20}}},Footer:{Enabled:!1,Duration:5,Width:320,Height:50, Rotation:{Enabled:!1,Weight:{MobileAdInGameFooter:40,MobileAdInGameFooter2:40,MobileAdInGameFooter3:20}}},End:{Enabled:!1,Duration:1,Width:300,Height:250,Rotation:{Enabled:!1,Weight:{MobileAdInGameEnd:40,MobileAdInGameEnd2:40,MobileAdInGameEnd3:20}}}}},Language:{Default:"en"},DeveloperBranding:{Splash:{Enabled:!1},Logo:{Enabled:!1,Link:"http://google.com",LinkEnabled:!1,NewWindow:!0,Width:166,Height:61}},Branding:{Splash:{Enabled:!1},Logo:{Enabled:!1,Link:"http://google.com",LinkEnabled:!1,NewWindow:!1, Width:166,Height:61}},MoreGames:{Enabled:!0,Link:"https://selenite.cc",NewWindow:!0}};var MobileAdInGamePreroll={ad_duration:_SETTINGS.Ad.Mobile.Preroll.Duration,ad_width:_SETTINGS.Ad.Mobile.Preroll.Width,ad_height:_SETTINGS.Ad.Mobile.Preroll.Height,ready_in:_STRINGS.Ad.Mobile.Preroll.ReadyIn,loading:_STRINGS.Ad.Mobile.Preroll.Loading,close:_STRINGS.Ad.Mobile.Preroll.Close+"          ",Initialize:function(){if(_SETTINGS.Ad.Mobile.Preroll.Rotation.Enabled){var b=_SETTINGS.Ad.Mobile.Preroll.Rotation.Weight,c=b.MobileAdInGamePreroll,d= c+b.MobileAdInGamePreroll2,b=d+b.MobileAdInGamePreroll3,e=Math.floor(100*Math.random());console.log("seed: ",e);e<=c?this.selectedOverlayName="MobileAdInGamePreroll":e<=d?this.selectedOverlayName="MobileAdInGamePreroll2":e<=b&&(this.selectedOverlayName="MobileAdInGamePreroll3");console.log("Ad rotating preroll enabled")}else this.selectedOverlayName="MobileAdInGamePreroll",console.log("Ad rotating preroll disabled");console.log("selected:",this.selectedOverlayName);this.overlay=$("#"+this.selectedOverlayName); this.box=$("#"+this.selectedOverlayName+"-Box");this.game=$("#game");this.boxContents={footer:$("#"+this.selectedOverlayName+"-Box-Footer"),header:$("#"+this.selectedOverlayName+"-Box-Header"),close:$("#"+this.selectedOverlayName+"-Box-Close"),body:$("#"+this.selectedOverlayName+"-Box-Body")};this.box.width(this.ad_width);this.box.height(this.ad_height);this.box.css("left",(this.overlay.width()-this.box.width())/2);this.box.css("top",(this.overlay.height()-this.box.height()-this.boxContents.header.height()- this.boxContents.footer.height())/2);this.overlay.show(this.Timer(this.ad_duration))},Timer:function(b){var c=b,d=setInterval(function(){MobileAdInGamePreroll.boxContents.header.text(MobileAdInGamePreroll.ready_in+c+"...");MobileAdInGamePreroll.boxContents.footer.text(MobileAdInGamePreroll.loading);c--;0>c&&(clearInterval(d),MobileAdInGamePreroll.boxContents.close.css("left",MobileAdInGamePreroll.boxContents.body.width()-23),MobileAdInGamePreroll.boxContents.close.show(),MobileAdInGamePreroll.boxContents.header.html(MobileAdInGamePreroll.close), MobileAdInGamePreroll.boxContents.footer.text(""))},1E3)},Close:function(){this.boxContents.close.hide();this.overlay.hide()}};var MobileAdInGameHeader={ad_duration:_SETTINGS.Ad.Mobile.Header.Duration,ad_width:_SETTINGS.Ad.Mobile.Header.Width,ad_height:_SETTINGS.Ad.Mobile.Header.Height,Initialize:function(){if(_SETTINGS.Ad.Mobile.Header.Rotation.Enabled){var b=_SETTINGS.Ad.Mobile.Header.Rotation.Weight,c=b.MobileAdInGameHeader,d=c+b.MobileAdInGameHeader2,b=d+b.MobileAdInGameHeader3,e=Math.floor(100*Math.random());console.log("seed: ",e);e<=c?this.selectedOverlayName="MobileAdInGameHeader":e<=d?this.selectedOverlayName="MobileAdInGameHeader2": e<=b&&(this.selectedOverlayName="MobileAdInGameHeader3");console.log("Ad rotating header enabled")}else this.selectedOverlayName="MobileAdInGameHeader",console.log("Ad rotating header disabled");this.div=$("#"+this.selectedOverlayName);this.game=$("#game");this.div.width(this.ad_width);this.div.height(this.ad_height);this.div.css("left",this.game.position().left+(this.game.width()-this.div.width())/2);this.div.css("top",0);this.div.show(this.Timer(this.ad_duration))},Timer:function(b){var c=setInterval(function(){b--; 0>b&&(MobileAdInGameHeader.div.hide(),clearInterval(c))},1E3)}};var MobileAdInGameFooter={ad_duration:_SETTINGS.Ad.Mobile.Footer.Duration,ad_width:_SETTINGS.Ad.Mobile.Footer.Width,ad_height:_SETTINGS.Ad.Mobile.Footer.Height,Initialize:function(){if(_SETTINGS.Ad.Mobile.Footer.Rotation.Enabled){var b=_SETTINGS.Ad.Mobile.Footer.Rotation.Weight,c=b.MobileAdInGameFooter,d=c+b.MobileAdInGameFooter2,b=d+b.MobileAdInGameFooter3,e=Math.floor(100*Math.random());console.log("seed: ",e);e<=c?this.selectedOverlayName="MobileAdInGameFooter":e<=d?this.selectedOverlayName="MobileAdInGameFooter2": e<=b&&(this.selectedOverlayName="MobileAdInGameFooter3");console.log("Ad rotating footer enabled")}else this.selectedOverlayName="MobileAdInGameFooter",console.log("Ad rotating footer disabled");this.div=$("#"+this.selectedOverlayName);this.game=$("#game");this.div.width(this.ad_width);this.div.height(this.ad_height);this.div.css("left",this.game.position().left+(this.game.width()-this.div.width())/2);this.div.css("top",this.game.height()-this.div.height()-5);this.div.show(this.Timer(this.ad_duration))}, Timer:function(b){var c=setInterval(function(){b--;0>b&&(MobileAdInGameFooter.div.hide(),clearInterval(c))},1E3)}};var MobileAdInGameEnd={ad_duration:_SETTINGS.Ad.Mobile.End.Duration,ad_width:_SETTINGS.Ad.Mobile.End.Width,ad_height:_SETTINGS.Ad.Mobile.End.Height,ready_in:_STRINGS.Ad.Mobile.End.ReadyIn,loading:_STRINGS.Ad.Mobile.End.Loading,close:_STRINGS.Ad.Mobile.End.Close+"          ",Initialize:function(){if(_SETTINGS.Ad.Mobile.End.Rotation.Enabled){var b=_SETTINGS.Ad.Mobile.End.Rotation.Weight,c=b.MobileAdInGameEnd,d=c+b.MobileAdInGameEnd2,b=d+b.MobileAdInGameEnd3, e=Math.floor(100*Math.random());console.log("seed: ",e);e<=c?this.selectedOverlayName="MobileAdInGameEnd":e<=d?this.selectedOverlayName="MobileAdInGameEnd2":e<=b&&(this.selectedOverlayName="MobileAdInGameEnd3");console.log("Ad rotating end enabled")}else this.selectedOverlayName="MobileAdInGameEnd",console.log("Ad rotating end disabled");console.log("selected:",this.selectedOverlayName);this.overlay=$("#"+this.selectedOverlayName);this.box=$("#"+this.selectedOverlayName+"-Box");this.game=$("#game"); this.boxContents={footer:$("#"+this.selectedOverlayName+"-Box-Footer"),header:$("#"+this.selectedOverlayName+"-Box-Header"),close:$("#"+this.selectedOverlayName+"-Box-Close"),body:$("#"+this.selectedOverlayName+"-Box-Body")};this.box.width(this.ad_width);this.box.height(this.ad_height);this.box.css("left",(this.overlay.width()-this.box.width())/2);this.box.css("top",(this.overlay.height()-this.box.height()-this.boxContents.header.height()-this.boxContents.footer.height())/2);this.overlay.show(this.Timer(this.ad_duration))}, Timer:function(b){var c=b,d=setInterval(function(){MobileAdInGameEnd.boxContents.header.text(MobileAdInGameEnd.ready_in+c+"...");MobileAdInGameEnd.boxContents.footer.text(MobileAdInGameEnd.loading);c--;0>c&&(clearInterval(d),MobileAdInGameEnd.boxContents.close.css("left",MobileAdInGameEnd.boxContents.body.width()-23),MobileAdInGameEnd.boxContents.close.show(),MobileAdInGameEnd.boxContents.header.html(MobileAdInGameEnd.close),MobileAdInGameEnd.boxContents.footer.text(""))},1E3)},Close:function(){this.boxContents.close.hide(); this.overlay.hide()}};!function(b,c){"object"==typeof module&&"object"==typeof module.exports?module.exports=b.document?c(b,!0):function(b){if(!b.document)throw Error("jQuery requires a window with a document");return c(b)}:c(b)}("undefined"!=typeof window?window:this,function(b,c){function d(b,c){c=c||X;var d=c.createElement("script");d.text=b;c.head.appendChild(d).parentNode.removeChild(d)}function e(b){var c=!!b&&"length"in b&&b.length,d=p.type(b);return"function"!==d&&!p.isWindow(b)&&("array"===d||0===c||"number"== typeof c&&0tbody",b)[0]||b:b}function fa(b){return b.type=(null!==b.getAttribute("type"))+"/"+b.type,b}function O(b){var c=Kc.exec(b.type);return c?b.type=c[1]:b.removeAttribute("type"),b}function P(b,c){var d,g,l,r,e,f;if(1===c.nodeType){if(S.hasData(b)&&(d=S.access(b),g=S.set(c,d),f=d.events))for(l in delete g.handle,g.events={},f){d=0;for(g=f[l].length;dc;c+=2)"margin"===d&&(r+=p.css(b,d+Sa[c],!0,l)),g?("content"===d&&(r-=p.css(b,"padding"+Sa[c],!0,l)),"margin"!==d&&(r-=p.css(b,"border"+Sa[c]+"Width",!0,l))):(r+=p.css(b,"padding"+Sa[c],!0,l),"padding"!==d&&(r+=p.css(b,"border"+Sa[c]+"Width",!0,l)));return r}function Z(b,c,d){var g,l=Bb(b),r=s(b,c,l),e="border-box"===p.css(b,"boxSizing",!1, l);return Qb.test(r)?r:(g=e&&(da.boxSizingReliable()||r===b.style[c]),"auto"===r&&(r=b["offset"+c[0].toUpperCase()+c.slice(1)]),r=parseFloat(r)||0,r+H(b,c,d||(e?"border":"content"),g,l)+"px")}function R(b,c,d,g,l){return new R.prototype.init(b,c,d,g,l)}function l(){Cb&&(!1===X.hidden&&b.requestAnimationFrame?b.requestAnimationFrame(l):b.setTimeout(l,p.fx.interval),p.fx.tick())}function q(){return b.setTimeout(function(){bb=void 0}),bb=p.now()}function K(b,c){var d,g=0,l={height:b};for(c=c?1:0;4>g;g+= 2-c)d=Sa[g],l["margin"+d]=l["padding"+d]=b;return c&&(l.opacity=l.width=b),l}function r(b,c,d){for(var g,l=(N.tweeners[c]||[]).concat(N.tweeners["*"]),r=0,e=l.length;rd&&r?c: (r||s.notifyWith(b,[m,1,0]),s.resolveWith(b,[m]),!1)},m=s.promise({elem:b,props:p.extend({},c),opts:p.extend(!0,{specialEasing:{},easing:p.easing._default},d),originalProperties:c,originalOptions:d,startTime:bb||q(),duration:d.duration,tweens:[],createTween:function(c,d){var g=p.Tween(b,m.opts,c,d,m.opts.specialEasing[c]||m.opts.easing);return m.tweens.push(g),g},stop:function(c){var d=0,g=c?m.tweens.length:0;if(l)return this;for(l=!0;db?this[b+this.length]:this[b]},pushStack:function(b){b=p.merge(this.constructor(),b);return b.prevObject=this,b},each:function(b){return p.each(this,b)},map:function(b){return this.pushStack(p.map(this,function(c,d){return b.call(c,d,c)}))},slice:function(){return this.pushStack(ya.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(b){var c=this.length;b= +b+(0>b?c:0);return this.pushStack(0<=b&&bW.cacheLength&&delete b[c.shift()],b[d+" "]=g}var c=[];return b},pa=function(b){return b[ia]=!0,b},ra=function(b){var c=Y.createElement("fieldset");try{return!!b(c)}catch(d){return!1}finally{c.parentNode&&c.parentNode.removeChild(c)}},ib=function(b,c){for(var d=b.split("|"),g=d.length;g--;)W.attrHandle[d[g]]=c},sb=function(b,c){var d=c&&b,g=d&&1===b.nodeType&&1===c.nodeType&&b.sourceIndex-c.sourceIndex;if(g)return g;if(d)for(;d=d.nextSibling;)if(d=== c)return-1;return b?1:-1},tb=function(b){return function(c){return"input"===c.nodeName.toLowerCase()&&c.type===b}},Ib=function(b){return function(c){var d=c.nodeName.toLowerCase();return("input"===d||"button"===d)&&c.type===b}},ub=function(b){return function(c){return"form"in c?c.parentNode&&!1===c.disabled?"label"in c?"label"in c.parentNode?c.parentNode.disabled===b:c.disabled===b:c.isDisabled===b||c.isDisabled!==!b&&Qc(c)===b:c.disabled===b:"label"in c&&c.disabled===b}},Ca=function(b){return pa(function(c){return c= +c,pa(function(d,g){for(var l,r=b([],d.length,c),e=r.length;e--;)d[l=r[e]]&&(d[l]=!(g[l]=d[l]))})})},fb=function(b){return b&&"undefined"!=typeof b.getElementsByTagName&&b},vb=function(){},Ta=function(b){for(var c=0,d=b.length,g="";c+~]|[\x20\t\r\n\f])[\x20\t\r\n\f]*/,Yc=/=[\x20\t\r\n\f]*([^\]'"]*?)[\x20\t\r\n\f]*\]/g,Zc=RegExp(":((?:\\\\.|[\\w-]|[^\x00-\\xa0])+)(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|\\[[\\x20\\t\\r\\n\\f]*((?:\\\\.|[\\w-]|[^\x00-\\xa0])+)(?:[\\x20\\t\\r\\n\\f]*([*^$|!~]?=)[\\x20\\t\\r\\n\\f]*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|((?:\\\\.|[\\w-]|[^\x00-\\xa0])+))|)[\\x20\\t\\r\\n\\f]*\\])*)|.*)\\)|)"), $c=/^(?:\\.|[\w-]|[^\x00-\xa0])+$/,Jb={ID:/^#((?:\\.|[\w-]|[^\x00-\xa0])+)/,CLASS:/^\.((?:\\.|[\w-]|[^\x00-\xa0])+)/,TAG:/^((?:\\.|[\w-]|[^\x00-\xa0])+|[*])/,ATTR:RegExp("^\\[[\\x20\\t\\r\\n\\f]*((?:\\\\.|[\\w-]|[^\x00-\\xa0])+)(?:[\\x20\\t\\r\\n\\f]*([*^$|!~]?=)[\\x20\\t\\r\\n\\f]*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|((?:\\\\.|[\\w-]|[^\x00-\\xa0])+))|)[\\x20\\t\\r\\n\\f]*\\]"),PSEUDO:RegExp("^:((?:\\\\.|[\\w-]|[^\x00-\\xa0])+)(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|\\[[\\x20\\t\\r\\n\\f]*((?:\\\\.|[\\w-]|[^\x00-\\xa0])+)(?:[\\x20\\t\\r\\n\\f]*([*^$|!~]?=)[\\x20\\t\\r\\n\\f]*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|((?:\\\\.|[\\w-]|[^\x00-\\xa0])+))|)[\\x20\\t\\r\\n\\f]*\\])*)|.*)\\)|)"), CHILD:RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\([\\x20\\t\\r\\n\\f]*(even|odd|(([+-]|)(\\d*)n|)[\\x20\\t\\r\\n\\f]*(?:([+-]|)[\\x20\\t\\r\\n\\f]*(\\d+)|))[\\x20\\t\\r\\n\\f]*\\)|)","i"),bool:RegExp("^(?:checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped)$","i"),needsContext:RegExp("^[\\x20\\t\\r\\n\\f]*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\([\\x20\\t\\r\\n\\f]*((?:-\\d)?\\d*)[\\x20\\t\\r\\n\\f]*\\)|)(?=[^-]|$)", "i")},ad=/^(?:input|select|textarea|button)$/i,bd=/^h\d$/i,wb=/^[^{]+\{\s*\[native \w/,Pc=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,Sb=/[+~]/,Ga=/\\([\da-f]{1,6}[\x20\t\r\n\f]?|([\x20\t\r\n\f])|.)/ig,Ha=function(b,c,d){b="0x"+c-65536;return b!==b||d?c:0>b?String.fromCharCode(b+65536):String.fromCharCode(b>>10|55296,1023&b|56320)},dc=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ec=function(b,c){return c?"\x00"===b?"\ufffd":b.slice(0,-1)+"\\"+b.charCodeAt(b.length-1).toString(16)+" ":"\\"+b},ic=function(){wa()}, Qc=Ua(function(b){return!0===b.disabled&&("form"in b||"label"in b)},{dir:"parentNode",next:"legend"});try{Ma.apply($a=hc.call(va.childNodes),va.childNodes),$a[va.childNodes.length].nodeType}catch(Ed){Ma={apply:$a.length?function(b,c){Uc.apply(b,hc.call(c))}:function(b,c){for(var d=b.length,g=0;b[d++]=c[g++];);b.length=d-1}}}ea=ca.support={};jb=ca.isXML=function(b){b=b&&(b.ownerDocument||b).documentElement;return!!b&&"HTML"!==b.nodeName};wa=ca.setDocument=function(b){var c,d;b=b?b.ownerDocument||b: va;return b!==Y&&9===b.nodeType&&b.documentElement?(Y=b,ma=Y.documentElement,la=!jb(Y),va!==Y&&(d=Y.defaultView)&&d.top!==d&&(d.addEventListener?d.addEventListener("unload",ic,!1):d.attachEvent&&d.attachEvent("onunload",ic)),ea.attributes=ra(function(b){return b.className="i",!b.getAttribute("className")}),ea.getElementsByTagName=ra(function(b){return b.appendChild(Y.createComment("")),!b.getElementsByTagName("*").length}),ea.getElementsByClassName=wb.test(Y.getElementsByClassName),ea.getById=ra(function(b){return ma.appendChild(b).id= ia,!Y.getElementsByName||!Y.getElementsByName(ia).length}),ea.getById?(W.filter.ID=function(b){var c=b.replace(Ga,Ha);return function(b){return b.getAttribute("id")===c}},W.find.ID=function(b,c){if("undefined"!=typeof c.getElementById&&la){var d=c.getElementById(b);return d?[d]:[]}}):(W.filter.ID=function(b){var c=b.replace(Ga,Ha);return function(b){return(b="undefined"!=typeof b.getAttributeNode&&b.getAttributeNode("id"))&&b.value===c}},W.find.ID=function(b,c){if("undefined"!=typeof c.getElementById&& la){var d,g,l,aa=c.getElementById(b);if(aa){if(d=aa.getAttributeNode("id"),d&&d.value===b)return[aa];l=c.getElementsByName(b);for(g=0;aa=l[g++];)if(d=aa.getAttributeNode("id"),d&&d.value===b)return[aa]}return[]}}),W.find.TAG=ea.getElementsByTagName?function(b,c){return"undefined"!=typeof c.getElementsByTagName?c.getElementsByTagName(b):ea.qsa?c.querySelectorAll(b):void 0}:function(b,c){var d,g=[],l=0,aa=c.getElementsByTagName(b);if("*"===b){for(;d=aa[l++];)1===d.nodeType&&g.push(d);return g}return aa}, W.find.CLASS=ea.getElementsByClassName&&function(b,c){if("undefined"!=typeof c.getElementsByClassName&&la)return c.getElementsByClassName(b)},Aa=[],ja=[],(ea.qsa=wb.test(Y.querySelectorAll))&&(ra(function(b){ma.appendChild(b).innerHTML="";b.querySelectorAll("[msallowcapture^='']").length&&ja.push("[*^$]=[\\x20\\t\\r\\n\\f]*(?:''|\"\")");b.querySelectorAll("[selected]").length||ja.push("\\[[\\x20\\t\\r\\n\\f]*(?:value|checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped)"); b.querySelectorAll("[id~="+ia+"-]").length||ja.push("~=");b.querySelectorAll(":checked").length||ja.push(":checked");b.querySelectorAll("a#"+ia+"+*").length||ja.push(".#.+[+~]")}),ra(function(b){b.innerHTML="";var c=Y.createElement("input");c.setAttribute("type","hidden");b.appendChild(c).setAttribute("name","D");b.querySelectorAll("[name=d]").length&&ja.push("name[\\x20\\t\\r\\n\\f]*[*^$|!~]?=");2!==b.querySelectorAll(":enabled").length&& ja.push(":enabled",":disabled");ma.appendChild(b).disabled=!0;2!==b.querySelectorAll(":disabled").length&&ja.push(":enabled",":disabled");b.querySelectorAll("*,:x");ja.push(",.*:")})),(ea.matchesSelector=wb.test(Ra=ma.matches||ma.webkitMatchesSelector||ma.mozMatchesSelector||ma.oMatchesSelector||ma.msMatchesSelector))&&ra(function(b){ea.disconnectedMatch=Ra.call(b,"*");Ra.call(b,"[s!='']:x");Aa.push("!=",":((?:\\\\.|[\\w-]|[^\x00-\\xa0])+)(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|\\[[\\x20\\t\\r\\n\\f]*((?:\\\\.|[\\w-]|[^\x00-\\xa0])+)(?:[\\x20\\t\\r\\n\\f]*([*^$|!~]?=)[\\x20\\t\\r\\n\\f]*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|((?:\\\\.|[\\w-]|[^\x00-\\xa0])+))|)[\\x20\\t\\r\\n\\f]*\\])*)|.*)\\)|)")}), ja=ja.length&&RegExp(ja.join("|")),Aa=Aa.length&&RegExp(Aa.join("|")),c=wb.test(ma.compareDocumentPosition),rb=c||wb.test(ma.contains)?function(b,c){var d=9===b.nodeType?b.documentElement:b,g=c&&c.parentNode;return b===g||!(!g||1!==g.nodeType||!(d.contains?d.contains(g):b.compareDocumentPosition&&16&b.compareDocumentPosition(g)))}:function(b,c){if(c)for(;c=c.parentNode;)if(c===b)return!0;return!1},Tb=c?function(b,c){if(b===c)return Fa=!0,0;var d=!b.compareDocumentPosition-!c.compareDocumentPosition; return d?d:(d=(b.ownerDocument||b)===(c.ownerDocument||c)?b.compareDocumentPosition(c):1,1&d||!ea.sortDetached&&c.compareDocumentPosition(b)===d?b===Y||b.ownerDocument===va&&rb(va,b)?-1:c===Y||c.ownerDocument===va&&rb(va,c)?1:xa?Xa(xa,b)-Xa(xa,c):0:4&d?-1:1)}:function(b,c){if(b===c)return Fa=!0,0;var d,g=0;d=b.parentNode;var l=c.parentNode,aa=[b],r=[c];if(!d||!l)return b===Y?-1:c===Y?1:d?-1:l?1:xa?Xa(xa,b)-Xa(xa,c):0;if(d===l)return sb(b,c);for(d=b;d=d.parentNode;)aa.unshift(d);for(d=c;d=d.parentNode;)r.unshift(d); for(;aa[g]===r[g];)g++;return g?sb(aa[g],r[g]):aa[g]===va?-1:r[g]===va?1:0},Y):Y};ca.matches=function(b,c){return ca(b,null,null,c)};ca.matchesSelector=function(b,c){if((b.ownerDocument||b)!==Y&&wa(b),c=c.replace(Yc,"='$1']"),ea.matchesSelector&&la&&!Gb[c+" "]&&(!Aa||!Aa.test(c))&&(!ja||!ja.test(c)))try{var d=Ra.call(b,c);if(d||ea.disconnectedMatch||b.document&&11!==b.document.nodeType)return d}catch(g){}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"}, "+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(b){return b[1]=b[1].replace(Ga,Ha),b[3]=(b[3]||b[4]||b[5]||"").replace(Ga,Ha),"~="===b[2]&&(b[3]=" "+b[3]+" "),b.slice(0,4)},CHILD:function(b){return b[1]=b[1].toLowerCase(),"nth"===b[1].slice(0,3)?(b[3]||ca.error(b[0]),b[4]=+(b[4]?b[5]+(b[6]||1):2*("even"===b[3]||"odd"===b[3])),b[5]=+(b[7]+b[8]||"odd"===b[3])):b[3]&&ca.error(b[0]),b},PSEUDO:function(b){var c,d=!b[6]&&b[2];return Jb.CHILD.test(b[0])?null:(b[3]? b[2]=b[4]||b[5]||"":d&&Zc.test(d)&&(c=Na(d,!0))&&(c=d.indexOf(")",d.length-c)-d.length)&&(b[0]=b[0].slice(0,c),b[2]=d.slice(0,c)),b.slice(0,3))}},filter:{TAG:function(b){var c=b.replace(Ga,Ha).toLowerCase();return"*"===b?function(){return!0}:function(b){return b.nodeName&&b.nodeName.toLowerCase()===c}},CLASS:function(b){var c=fc[b+" "];return c||(c=RegExp("(^|[\\x20\\t\\r\\n\\f])"+b+"([\\x20\\t\\r\\n\\f]|$)"))&&fc(b,function(b){return c.test("string"==typeof b.className&&b.className||"undefined"!= typeof b.getAttribute&&b.getAttribute("class")||"")})},ATTR:function(b,c,d){return function(g){g=ca.attr(g,b);return null==g?"!="===c:!c||(g+="","="===c?g===d:"!="===c?g!==d:"^="===c?d&&0===g.indexOf(d):"*="===c?d&&-1b.nodeType)return!1;return!0},parent:function(b){return!W.pseudos.empty(b)},header:function(b){return bd.test(b.nodeName)}, input:function(b){return ad.test(b.nodeName)},button:function(b){var c=b.nodeName.toLowerCase();return"input"===c&&"button"===b.type||"button"===c},text:function(b){var c;return"input"===b.nodeName.toLowerCase()&&"text"===b.type&&(null==(c=b.getAttribute("type"))||"text"===c.toLowerCase())},first:Ca(function(){return[0]}),last:Ca(function(b,c){return[c-1]}),eq:Ca(function(b,c,d){return[0>d?d+c:d]}),even:Ca(function(b,c){for(var d=0;dd?d+c:d;0<=--c;)b.push(c);return b}),gt:Ca(function(b,c,d){for(d=0>d?d+c:d;++d:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i,Gc=/^.[^:#\[\.,]*$/;p.filter=function(b,c,d){var g=c[0];return d&&(b=":not("+b+")"),1===c.length&&1===g.nodeType?p.find.matchesSelector(g,b)?[g]:[]:p.find.matches(b,p.grep(c,function(b){return 1===b.nodeType}))};p.fn.extend({find:function(b){var c,d,g=this.length,l=this;if("string"!=typeof b)return this.pushStack(p(b).filter(function(){for(c=0;c)[^>]*|#([\w-]+))$/;(p.fn.init=function(b,c,d){var g,l;if(!b)return this;if(d=d||mc,"string"==typeof b){if(g="<"===b[0]&&">"===b[b.length-1]&&3<=b.length?[null,b,null]:cd.exec(b),!g||!g[1]&& c)return!c||c.jquery?(c||d).find(b):this.constructor(c).find(b);if(g[1]){if(c=c instanceof p?c[0]:c,p.merge(this,p.parseHTML(g[1],c&&c.nodeType?c.ownerDocument||c:X,!0)),lc.test(g[1])&&p.isPlainObject(c))for(g in c)p.isFunction(this[g])?this[g](c[g]):this.attr(g,c[g]);return this}return l=X.getElementById(g[2]),l&&(this[0]=l,this.length=1),this}return b.nodeType?(this[0]=b,this.length=1,this):p.isFunction(b)?void 0!==d.ready?d.ready(b):b(p):p.makeArray(b,this)}).prototype=p.fn;mc=p(X);var dd=/^(?:parents|prev(?:Until|All))/, ed={children:!0,contents:!0,next:!0,prev:!0};p.fn.extend({has:function(b){var c=p(b,this),d=c.length;return this.filter(function(){for(var b=0;bd.nodeType&&(e?-1=f&&(l!==g&&(s=void 0,q=[b]),d.rejectWith(s,q))}};c?aa():(p.Deferred.getStackHook&&(aa.stackTrace=p.Deferred.getStackHook()),b.setTimeout(aa))}}var f=0;return p.Deferred(function(b){d[0][3].add(e(0,b,p.isFunction(r)?r:m,b.notifyWith));d[1][3].add(e(0,b,p.isFunction(c)?c:m));d[2][3].add(e(0,b,p.isFunction(l)?l:g))}).promise()},promise:function(b){return null!=b?p.extend(b,r):r}},e={};return p.each(d,function(b,c){var g=c[2],f=c[5];r[c[1]]=g.add;f&&g.add(function(){l= f},d[3-b][2].disable,d[0][2].lock);g.add(c[3].fire);e[c[0]]=function(){return e[c[0]+"With"](this===e?void 0:this,arguments),this};e[c[0]+"With"]=g.fireWith}),r.promise(e),c&&c.call(e,e),e},when:function(b){var c=arguments.length,d=c,g=Array(d),l=ya.call(arguments),r=p.Deferred(),e=function(b){return function(d){g[b]=this;l[b]=1=c&&(t(b,r.done(e(d)).resolve,r.reject,!c),"pending"===r.state()||p.isFunction(l[d]&&l[d].then)))return r.then(); for(;d--;)t(l[d],e(d),r.reject);return r.promise()}});var fd=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;p.Deferred.exceptionHook=function(c,d){b.console&&b.console.warn&&c&&fd.test(c.name)&&b.console.warn("jQuery.Deferred exception: "+c.message,c.stack,d)};p.readyException=function(c){b.setTimeout(function(){throw c;})};var Ub=p.Deferred();p.fn.ready=function(b){return Ub.then(b)["catch"](function(b){p.readyException(b)}),this};p.extend({isReady:!1,readyWait:1,ready:function(b){(!0=== b?--p.readyWait:p.isReady)||(p.isReady=!0,!0!==b&&0<--p.readyWait||Ub.resolveWith(X,[p]))}});p.ready.then=Ub.then;"complete"===X.readyState||"loading"!==X.readyState&&!X.documentElement.doScroll?b.setTimeout(p.ready):(X.addEventListener("DOMContentLoaded",z),b.addEventListener("load",z));var Ia=function(b,c,d,g,l,r,e){var f=0,s=b.length,q=null==d;if("object"===p.type(d))for(f in l=!0,d)Ia(b,c,f,d[f],!0,r,e);else if(void 0!==g&&(l=!0,p.isFunction(g)||(e=!0),q&&(e?(c.call(b,g),c=null):(q=c,c=function(b, c,d){return q.call(p(b),d)})),c))for(;f\x20\t\r\n\f]+)/i,$b=/^$|\/(?:java|ecma)script/i,sa={option:[1,""],thead:[1,"","
"],col:[2,"","
"], tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};sa.optgroup=sa.option;sa.tbody=sa.tfoot=sa.colgroup=sa.caption=sa.thead;sa.th=sa.td;var Jc=/<|&#?\w+;/,Lb=X.createDocumentFragment().appendChild(X.createElement("div")),Mb=X.createElement("input");Mb.setAttribute("type","radio");Mb.setAttribute("checked","checked");Mb.setAttribute("name","t");Lb.appendChild(Mb);da.checkClone=Lb.cloneNode(!0).cloneNode(!0).lastChild.checked;Lb.innerHTML= "";da.noCloneChecked=!!Lb.cloneNode(!0).lastChild.defaultValue;!0;var Nb=X.documentElement,gd=/^key/,hd=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,qc=/^([^.]*)(?:\.(.+)|)/;p.event={global:{},add:function(b,c,d,g,l){var r,e,f,s,q,j,m,N,t,u;if(q=S.get(b)){d.handler&&(r=d,d=r.handler,l=r.selector);l&&p.find.matchesSelector(Nb,l);d.guid||(d.guid=p.guid++);(s=q.events)||(s=q.events={});(e=q.handle)||(e=q.handle=function(c){return"undefined"!=typeof p&&p.event.triggered!==c.type? p.event.dispatch.apply(b,arguments):void 0});c=(c||"").match(ta)||[""];for(q=c.length;q--;)f=qc.exec(c[q])||[],t=u=f[1],f=(f[2]||"").split(".").sort(),t&&(m=p.event.special[t]||{},t=(l?m.delegateType:m.bindType)||t,m=p.event.special[t]||{},j=p.extend({type:t,origType:u,data:g,handler:d,guid:d.guid,selector:l,needsContext:l&&p.expr.match.needsContext.test(l),namespace:f.join(".")},r),(N=s[t])||(N=s[t]=[],N.delegateCount=0,m.setup&&!1!==m.setup.call(b,g,f,e)||b.addEventListener&&b.addEventListener(t, e)),m.add&&(m.add.call(b,j),j.handler.guid||(j.handler.guid=d.guid)),l?N.splice(N.delegateCount++,0,j):N.push(j),p.event.global[t]=!0)}},remove:function(b,c,d,g,l){var r,e,f,s,q,j,m,N,t,u,C,V=S.hasData(b)&&S.get(b);if(V&&(s=V.events)){c=(c||"").match(ta)||[""];for(q=c.length;q--;)if(f=qc.exec(c[q])||[],t=C=f[1],u=(f[2]||"").split(".").sort(),t){m=p.event.special[t]||{};t=(g?m.delegateType:m.bindType)||t;N=s[t]||[];f=f[2]&&RegExp("(^|\\.)"+u.join("\\.(?:.*\\.|)")+"(\\.|$)");for(e=r=N.length;r--;)j= N[r],!l&&C!==j.origType||d&&d.guid!==j.guid||f&&!f.test(j.namespace)||g&&g!==j.selector&&("**"!==g||!j.selector)||(N.splice(r,1),j.selector&&N.delegateCount--,m.remove&&m.remove.call(b,j));e&&!N.length&&(m.teardown&&!1!==m.teardown.call(b,u,V.handle)||p.removeEvent(b,t,V.handle),delete s[t])}else for(t in s)p.event.remove(b,t+c[q],d,g,!0);p.isEmptyObject(s)&&S.remove(b,"handle events")}},dispatch:function(b){var c=p.event.fix(b),d,g,l,r,e,f,s=Array(arguments.length);g=(S.get(this,"events")||{})[c.type]|| [];var q=p.event.special[c.type]||{};s[0]=c;for(d=1;d\x20\t\r\n\f]*)[^>]*)\/>/gi,jd=/\s*$/g;p.extend({htmlPrefilter:function(b){return b.replace(id,"<$1>")},clone:function(b,c,d){var g,l,r,e,f=b.cloneNode(!0),q=p.contains(b.ownerDocument,b);if(!da.noCloneChecked&&!(1!==b.nodeType&&11!==b.nodeType||p.isXMLDoc(b))){e=D(f);r=D(b);g=0;for(l=r.length;gp.inArray(this,b)&&(p.cleanData(D(this)),d&&d.replaceChild(c,this))},b)}});p.each({appendTo:"append",prependTo:"prepend", insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(b,c){p.fn[b]=function(b){for(var d=[],g=p(b),l=g.length-1,r=0;r<=l;r++)b=r===l?this:this.clone(!0),p(g[r])[c](b),cb.apply(d,b.get());return this.pushStack(d)}});var ac=/^margin/,Qb=RegExp("^("+nc+")(?!px)[a-z%]+$","i"),Bb=function(c){var d=c.ownerDocument.defaultView;return d&&d.opener||(d=b),d.getComputedStyle(c)},Pb=function(){if(Ba){Ba.style.cssText="box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%"; Ba.innerHTML="";Nb.appendChild(Ob);var c=b.getComputedStyle(Ba);rc="1%"!==c.top;sc="2px"===c.marginLeft;tc="4px"===c.width;Ba.style.marginRight="50%";uc="4px"===c.marginRight;Nb.removeChild(Ob);Ba=null}},rc,tc,uc,sc,Ob=X.createElement("div"),Ba=X.createElement("div");Ba.style&&(Ba.style.backgroundClip="content-box",Ba.cloneNode(!0).style.backgroundClip="",da.clearCloneStyle="content-box"===Ba.style.backgroundClip,Ob.style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute", Ob.appendChild(Ba),p.extend(da,{pixelPosition:function(){return Pb(),rc},boxSizingReliable:function(){return Pb(),tc},pixelMarginRight:function(){return Pb(),uc},reliableMarginLeft:function(){return Pb(),sc}}));!0;var kd=/^(none|table(?!-c[ea]).+)/,vc=/^--/,ld={position:"absolute",visibility:"hidden",display:"block"},wc={letterSpacing:"0",fontWeight:"400"},cc=["Webkit","Moz","ms"],bc=X.createElement("div").style;p.extend({cssHooks:{opacity:{get:function(b,c){if(c){var d=s(b,"opacity");return""=== d?"1":d}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(b,c,d,g){if(b&&3!==b.nodeType&&8!==b.nodeType&&b.style){var l,r,e,f=p.camelCase(c),q=vc.test(c),s=b.style;return q||(c=F(f)),e=p.cssHooks[c]||p.cssHooks[f],void 0===d?e&&"get"in e&&void 0!==(l=e.get(b,!1,g))?l:s[c]:(r=typeof d,"string"===r&&(l=mb.exec(d))&&l[1]&& (d=B(b,c,l),r="number"),null!=d&&d===d&&("number"===r&&(d+=l&&l[3]||(p.cssNumber[f]?"":"px")),da.clearCloneStyle||""!==d||0!==c.indexOf("background")||(s[c]="inherit"),e&&"set"in e&&void 0===(d=e.set(b,d,g))||(q?s.setProperty(c,d):s[c]=d)),void 0)}},css:function(b,c,d,g){var l,r,e,f=p.camelCase(c);return vc.test(c)||(c=F(f)),e=p.cssHooks[c]||p.cssHooks[f],e&&"get"in e&&(l=e.get(b,!0,d)),void 0===l&&(l=s(b,c,g)),"normal"===l&&c in wc&&(l=wc[c]),""===d||d?(r=parseFloat(l),!0===d||isFinite(r)?r||0:l): l}});p.each(["height","width"],function(b,c){p.cssHooks[c]={get:function(b,d,g){if(d)return!kd.test(p.css(b,"display"))||b.getClientRects().length&&b.getBoundingClientRect().width?Z(b,c,g):oc(b,ld,function(){return Z(b,c,g)})},set:function(b,d,g){var l,r=g&&Bb(b);g=g&&H(b,c,g,"border-box"===p.css(b,"boxSizing",!1,r),r);return g&&(l=mb.exec(d))&&"px"!==(l[3]||"px")&&(b.style[c]=d,d=p.css(b,c)),C(b,d,g)}}});p.cssHooks.marginLeft=u(da.reliableMarginLeft,function(b,c){if(c)return(parseFloat(s(b,"marginLeft"))|| b.getBoundingClientRect().left-oc(b,{marginLeft:0},function(){return b.getBoundingClientRect().left}))+"px"});p.each({margin:"",padding:"",border:"Width"},function(b,c){p.cssHooks[b+c]={expand:function(d){var g=0,l={};for(d="string"==typeof d?d.split(" "):[d];4>g;g++)l[b+Sa[g]+c]=d[g]||d[g-2]||d[0];return l}};ac.test(b)||(p.cssHooks[b+c].set=C)});p.fn.extend({css:function(b,c){return Ia(this,function(b,c,d){var g,l={},r=0;if(Array.isArray(c)){d=Bb(b);for(g=c.length;rg.indexOf(" "+r+" ")&&(g+=r+" ");g=V(g);l!==g&&d.setAttribute("class",g)}return this},removeClass:function(b){var c,d,g,l,r,e,f=0;if(p.isFunction(b))return this.each(function(c){p(this).removeClass(b.call(this, c,ga(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof b&&b)for(c=b.match(ta)||[];d=this[f++];)if(l=ga(d),g=1===d.nodeType&&" "+V(l)+" "){for(e=0;r=c[e++];)for(;-1l?s:r?l:0;dt.indexOf(":")&&"on"+t,c=c[p.expando]?c:new p.Event(t,"object"==typeof c&&c),c.isTrigger=l?2:3,c.namespace=r.join("."),c.rnamespace=c.namespace?RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,c.result=void 0,c.target||(c.target=g),d=null==d?[c]:p.makeArray(d,[c]),m=p.event.special[t]||{},l||!m.trigger||!1!==m.trigger.apply(g, d))){if(!l&&!m.noBubble&&!p.isWindow(g)){s=m.delegateType||t;for(yc.test(s+t)||(e=e.parentNode);e;e=e.parentNode)N.push(e),f=e;f===(g.ownerDocument||X)&&N.push(f.defaultView||f.parentWindow||b)}for(r=0;(e=N[r++])&&!c.isPropagationStopped();)c.type=1c||304===c;if(f){F=u;for(var n=H,y,A,Z,ha,B=F.contents,E=F.dataTypes;"*"===E[0];)E.shift(),void 0===y&&(y=F.mimeType||n.getResponseHeader("Content-Type")); if(y)for(A in B)if(B[A]&&B[A].test(y)){E.unshift(A);break}if(E[0]in f)Z=E[0];else{for(A in f){if(!E[0]||F.converters[A+" "+E[0]]){Z=A;break}ha||(ha=A)}Z=Z||ha}F=f=Z?(Z!==E[0]&&E.unshift(Z),f[Z]):void 0}var oa;a:{f=u;y=F;A=H;Z=q;var ka,G,na;F={};n=f.dataTypes.slice();if(n[1])for(ka in f.converters)F[ka.toLowerCase()]=f.converters[ka];for(ha=n.shift();ha;)if(f.responseFields[ha]&&(A[f.responseFields[ha]]=y),!na&&Z&&f.dataFilter&&(y=f.dataFilter(y,f.dataType)),na=ha,ha=n.shift())if("*"===ha)ha=na;else if("*"!== na&&na!==ha){if(ka=F[na+" "+ha]||F["* "+ha],!ka)for(oa in F)if(G=oa.split(" "),G[1]===ha&&(ka=F[na+" "+G[0]]||F["* "+G[0]])){!0===ka?ka=F[oa]:!0!==F[oa]&&(ha=G[0],n.unshift(G[1]));break}if(!0!==ka)if(ka&&f["throws"])y=ka(y);else try{y=ka(y)}catch(ua){oa={state:"parsererror",error:ka?ua:"No conversion from "+na+" to "+ha};break a}}oa={state:"success",data:y}}F=oa;q?(u.ifModified&&(R=H.getResponseHeader("Last-Modified"),R&&(p.lastModified[r]=R),R=H.getResponseHeader("etag"),R&&(p.etag[r]=R)),204=== c||"HEAD"===u.type?ga="nocontent":304===c?ga="notmodified":(ga=F.state,N=F.data,t=F.error,q=!t)):(t=ga,!c&&ga||(ga="error",0>c&&(c=0)));H.status=c;H.statusText=(d||ga)+"";q?K.resolveWith(C,[N,ga,H]):K.rejectWith(C,[H,ga,t]);H.statusCode(z);z=void 0;m&&V.trigger(q?"ajaxSuccess":"ajaxError",[H,u,q?N:t]);x.fireWith(C,[H,ga]);m&&(V.trigger("ajaxComplete",[H,u]),--p.active||p.event.trigger("ajaxStop"))}}"object"==typeof c&&(d=c,c=void 0);d=d||{};var l,r,e,f,s,q,j,m,N,t,u=p.ajaxSetup({},d),C=u.context|| u,V=u.context&&(C.nodeType||C.jquery)?p(C):p.event,K=p.Deferred(),x=p.Callbacks("once memory"),z=u.statusCode||{},F={},R={},ga="canceled",H={readyState:0,getResponseHeader:function(b){var c;if(j){if(!f)for(f={};c=xd.exec(e);)f[c[1].toLowerCase()]=c[2];c=f[b.toLowerCase()]}return null==c?null:c},getAllResponseHeaders:function(){return j?e:null},setRequestHeader:function(b,c){return null==j&&(b=R[b.toLowerCase()]=R[b.toLowerCase()]||b,F[b]=c),this},overrideMimeType:function(b){return null==j&&(u.mimeType= b),this},statusCode:function(b){var c;if(b)if(j)H.always(b[H.status]);else for(c in b)z[c]=[z[c],b[c]];return this},abort:function(b){b=b||ga;return l&&l.abort(b),g(0,b),this}};if(K.promise(H),u.url=((c||u.url||yb.href)+"").replace(zd,yb.protocol+"//"),u.type=d.method||d.type||u.method||u.type,u.dataTypes=(u.dataType||"*").toLowerCase().match(ta)||[""],null==u.crossDomain){q=X.createElement("a");try{q.href=u.url,q.href=q.href,u.crossDomain=Wb.protocol+"//"+Wb.host!=q.protocol+"//"+q.host}catch(n){u.crossDomain= !0}}if(u.data&&u.processData&&"string"!=typeof u.data&&(u.data=p.param(u.data,u.traditional)),na(Bc,u,d,H),j)return H;(m=p.event&&u.global)&&0===p.active++&&p.event.trigger("ajaxStart");u.type=u.type.toUpperCase();u.hasContent=!yd.test(u.type);r=u.url.replace(vd,"");u.hasContent?u.data&&u.processData&&0===(u.contentType||"").indexOf("application/x-www-form-urlencoded")&&(u.data=u.data.replace(ud,"+")):(t=u.url.slice(r.length),u.data&&(r+=(Vb.test(r)?"&":"?")+u.data,delete u.data),!1===u.cache&&(r= r.replace(wd,"$1"),t=(Vb.test(r)?"&":"?")+"_="+zc++ +t),u.url=r+t);u.ifModified&&(p.lastModified[r]&&H.setRequestHeader("If-Modified-Since",p.lastModified[r]),p.etag[r]&&H.setRequestHeader("If-None-Match",p.etag[r]));(u.data&&u.hasContent&&!1!==u.contentType||d.contentType)&&H.setRequestHeader("Content-Type",u.contentType);H.setRequestHeader("Accept",u.dataTypes[0]&&u.accepts[u.dataTypes[0]]?u.accepts[u.dataTypes[0]]+("*"!==u.dataTypes[0]?", "+Cc+"; q=0.01":""):u.accepts["*"]);for(N in u.headers)H.setRequestHeader(N, u.headers[N]);if(u.beforeSend&&(!1===u.beforeSend.call(C,H,u)||j))return H.abort();if(ga="abort",x.add(u.complete),H.done(u.success),H.fail(u.error),l=na(Rb,u,d,H)){if(H.readyState=1,m&&V.trigger("ajaxSend",[H,u]),j)return H;u.async&&0").prop({charset:b.scriptCharset,src:b.url}).on("load error",d=function(b){c.remove();d=null;b&&l("error"===b.type?404:200,b.type)});X.head.appendChild(c[0])},abort:function(){d&&d()}}}});var Dc=[],Xb=/(=)\?(?=&|$)|\?\?/;p.ajaxSetup({jsonp:"callback", jsonpCallback:function(){var b=Dc.pop()||p.expando+"_"+zc++;return this[b]=!0,b}});p.ajaxPrefilter("json jsonp",function(c,d,g){var l,r,e,f=!1!==c.jsonp&&(Xb.test(c.url)?"url":"string"==typeof c.data&&0===(c.contentType||"").indexOf("application/x-www-form-urlencoded")&&Xb.test(c.data)&&"data");if(f||"jsonp"===c.dataTypes[0])return l=c.jsonpCallback=p.isFunction(c.jsonpCallback)?c.jsonpCallback():c.jsonpCallback,f?c[f]=c[f].replace(Xb,"$1"+l):!1!==c.jsonp&&(c.url+=(Vb.test(c.url)?"&":"?")+c.jsonp+ "="+l),c.converters["script json"]=function(){return e||p.error(l+" was not called"),e[0]},c.dataTypes[0]="json",r=b[l],b[l]=function(){e=arguments},g.always(function(){void 0===r?p(b).removeProp(l):b[l]=r;c[l]&&(c.jsonpCallback=d.jsonpCallback,Dc.push(l));e&&p.isFunction(r)&&r(e[0]);e=r=void 0}),"script"});var Bd=da,Ec,Fc=X.implementation.createHTMLDocument("").body;Ec=(Fc.innerHTML="
",2===Fc.childNodes.length);Bd.createHTMLDocument=Ec;p.parseHTML=function(b,c,d){if("string"!= typeof b)return[];"boolean"==typeof c&&(d=c,c=!1);var g,l,r;return c||(da.createHTMLDocument?(c=X.implementation.createHTMLDocument(""),g=c.createElement("base"),g.href=X.location.href,c.head.appendChild(g)):c=X),l=lc.exec(b),r=!d&&[],l?[c.createElement(l[1])]:(l=G([b],c,r),r&&r.length&&p(r).remove(),p.merge([],l.childNodes))};p.fn.load=function(b,c,d){var g,l,r,e=this,f=b.indexOf(" ");return-1").append(p.parseHTML(b)).find(g):b)}).always(d&&function(b,c){e.each(function(){d.apply(this,r||[b.responseText,c,b])})}),this};p.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(b,c){p.fn[c]=function(b){return this.on(c,b)}});p.expr.pseudos.animated=function(b){return p.grep(p.timers,function(c){return b===c.elem}).length};p.offset={setOffset:function(b, c,d){var g,l,r,e,f,q,s=p.css(b,"position"),j=p(b),m={};"static"===s&&(b.style.position="relative");f=j.offset();r=p.css(b,"top");q=p.css(b,"left");("absolute"===s||"fixed"===s)&&-1<(r+q).indexOf("auto")?(g=j.position(),e=g.top,l=g.left):(e=parseFloat(r)||0,l=parseFloat(q)||0);p.isFunction(c)&&(c=c.call(b,d,p.extend({},f)));null!=c.top&&(m.top=c.top-f.top+e);null!=c.left&&(m.left=c.left-f.left+l);"using"in c?c.using.call(b,m):j.css(m)}};p.fn.extend({offset:function(b){if(arguments.length)return void 0=== b?this:this.each(function(c){p.offset.setOffset(this,b,c)});var c,d,g,l,r=this[0];if(r)return r.getClientRects().length?(g=r.getBoundingClientRect(),c=r.ownerDocument,d=c.documentElement,l=c.defaultView,{top:g.top+l.pageYOffset-d.clientTop,left:g.left+l.pageXOffset-d.clientLeft}):{top:0,left:0}},position:function(){if(this[0]){var b,c,d=this[0],g={top:0,left:0};return"fixed"===p.css(d,"position")?c=d.getBoundingClientRect():(b=this.offsetParent(),c=this.offset(),f(b[0],"html")||(g=b.offset()),g={top:g.top+ p.css(b[0],"borderTopWidth",!0),left:g.left+p.css(b[0],"borderLeftWidth",!0)}),{top:c.top-g.top-p.css(d,"marginTop",!0),left:c.left-g.left-p.css(d,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var b=this.offsetParent;b&&"static"===p.css(b,"position");)b=b.offsetParent;return b||Nb})}});p.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(b,c){var d="pageYOffset"===c;p.fn[b]=function(g){return Ia(this,function(b,g,l){var r;return p.isWindow(b)?r=b:9===b.nodeType&& (r=b.defaultView),void 0===l?r?r[c]:b[g]:void(r?r.scrollTo(d?r.pageXOffset:l,d?l:r.pageYOffset):b[g]=l)},b,g,arguments.length)}});p.each(["top","left"],function(b,c){p.cssHooks[c]=u(da.pixelPosition,function(b,d){if(d)return d=s(b,c),Qb.test(d)?p(b).position()[c]+"px":d})});p.each({Height:"height",Width:"width"},function(b,c){p.each({padding:"inner"+b,content:c,"":"outer"+b},function(d,g){p.fn[g]=function(l,r){var e=arguments.length&&(d||"boolean"!=typeof l),f=d||(!0===l||!0===r?"margin":"border"); return Ia(this,function(c,d,l){var r;return p.isWindow(c)?0===g.indexOf("outer")?c["inner"+b]:c.document.documentElement["client"+b]:9===c.nodeType?(r=c.documentElement,Math.max(c.body["scroll"+b],r["scroll"+b],c.body["offset"+b],r["offset"+b],r["client"+b])):void 0===l?p.css(c,d,f):p.style(c,d,l,f)},c,e?l:void 0,e)}})});p.fn.extend({bind:function(b,c,d){return this.on(b,null,c,d)},unbind:function(b,c){return this.off(b,null,c)},delegate:function(b,c,d,g){return this.on(c,b,d,g)},undelegate:function(b, c,d){return 1===arguments.length?this.off(b,"**"):this.off(c,b||"**",d)}});p.holdReady=function(b){b?p.readyWait++:p.ready(!0)};p.isArray=Array.isArray;p.parseJSON=JSON.parse;p.nodeName=f;"function"==typeof define&&define.amd&&define("jquery",[],function(){return p});var Cd=b.jQuery,Dd=b.$;return p.noConflict=function(c){return b.$===p&&(b.$=Dd),c&&b.jQuery===p&&(b.jQuery=Cd),p},c||(b.jQuery=b.$=p),p}); function getInternetExplorerVersion(){var b=-1;"Microsoft Internet Explorer"==navigator.appName&&null!=/MSIE ([0-9]{1,}[.0-9]{0,})/.exec(navigator.userAgent)&&(b=parseFloat(RegExp.$1));return b}var ie=getInternetExplorerVersion();function getQueryVariable(b){for(var c=window.location.search.substring(1).split("&"),d=0;d=d[f].start&&e<= d[f].end){b=f;break}}void 0!==e&&"[object Object]"===Object.prototype.toString.call(d[b])&&(this.isPlaying=this.settings.spritemap[b],this.context.play&&this.context.play(),this.wasReady=this.setCurrentTime(e))}},stop:function(){this.__lastPosition=0;this.isPlaying=null;this.backgroundMusic?this.backgroundHackForiOS():this.context.pause();return!0},pause:function(){this.isPlaying=null;this.__lastPosition=this.getCurrentTime();this.context.pause();return this.__lastPosition},resume:function(b){b="number"=== typeof b?b:this.__lastPosition;if(null!==b)return this.play(b),this.__lastPosition=null,!0;this.context.play();return!1},HTML5API:{getVolume:function(){return this.context.volume||1},setVolume:function(b){this.context.volume=b;return 1E-4>Math.abs(this.context.volume-b)?!0:!1},getCurrentTime:function(){return this.context.currentTime||0},setCurrentTime:function(b){try{return this.context.currentTime=b,!0}catch(c){return!1}}},FLASHAPI:{getVolume:function(){return this.context&&"function"===typeof this.context.getVolume? this.context.getVolume():1},setVolume:function(b){return this.context&&"function"===typeof this.context.setVolume?(this.context.setVolume(b),!0):!1},getCurrentTime:function(){return this.context&&"function"===typeof this.context.getCurrentTime?this.context.getCurrentTime():0},setCurrentTime:function(b){return this.context&&"function"===typeof this.context.setCurrentTime?this.context.setCurrentTime(b):!1}}}; if(void 0===this.jukebox)throw"jukebox.Manager requires jukebox.Player (Player.js) to run properly."; jukebox.Manager=function(b){this.features={};this.codecs={};this.__players={};this.__playersLength=0;this.__clones={};this.__queue=[];this.settings={};for(var c in this.defaults)this.settings[c]=this.defaults[c];if("[object Object]"===Object.prototype.toString.call(b))for(var d in b)this.settings[d]=b[d];this.__detectFeatures();jukebox.Manager.__initialized=!1===this.settings.useGameLoop?window.setInterval(function(){jukebox.Manager.loop()},20):!0}; jukebox.Manager.prototype={defaults:{useFlash:!1,useGameLoop:!1},__detectFeatures:function(){var b=window.Audio&&new Audio;if(b&&b.canPlayType&&!1===this.settings.useFlash){for(var c=[{e:"3gp",m:["audio/3gpp","audio/amr"]},{e:"aac",m:["audio/aac","audio/aacp"]},{e:"amr",m:["audio/amr","audio/3gpp"]},{e:"caf",m:["audio/IMA-ADPCM","audio/x-adpcm",'audio/x-aiff; codecs="IMA-ADPCM, ADPCM"']},{e:"m4a",m:'audio/mp4{audio/mp4; codecs="mp4a.40.2,avc1.42E01E"{audio/mpeg4{audio/mpeg4-generic{audio/mp4a-latm{audio/MP4A-LATM{audio/x-m4a'.split("{")}, {e:"mp3",m:["audio/mp3","audio/mpeg",'audio/mpeg; codecs="mp3"',"audio/MPA","audio/mpa-robust"]},{e:"mpga",m:["audio/MPA","audio/mpa-robust","audio/mpeg","video/mpeg"]},{e:"mp4",m:["audio/mp4","video/mp4"]},{e:"ogg",m:["application/ogg","audio/ogg",'audio/ogg; codecs="theora, vorbis"',"video/ogg",'video/ogg; codecs="theora, vorbis"']},{e:"wav",m:["audio/wave","audio/wav",'audio/wav; codecs="1"',"audio/x-wav","audio/x-pn-wav"]},{e:"webm",m:["audio/webm",'audio/webm; codecs="vorbis"',"video/webm"]}], d,e,f=0,j=c.length;fMath.abs(b.volume-0.1337));navigator.userAgent.match(/iPhone|iPod|iPad/i)&&(this.features.channels=1)}this.features.flashaudio= !!navigator.mimeTypes["application/x-shockwave-flash"]||!!navigator.plugins["Shockwave Flash"]||!1;if(window.ActiveXObject)try{new ActiveXObject("ShockwaveFlash.ShockwaveFlash.10"),this.features.flashaudio=!0}catch(g){}!0===this.settings.useFlash&&(this.features.flashaudio=!0);!0===this.features.flashaudio&&!this.features.html5audio&&(this.codecs.mp3="audio/mp3",this.codecs.mpga="audio/mpeg",this.codecs.mp4="audio/mp4",this.codecs.m4a="audio/mp4",this.codecs["3gp"]="audio/3gpp",this.codecs.amr="audio/amr", this.features.volume=!0,this.features.channels=1)},__getPlayerById:function(b){return this.__players&&void 0!==this.__players[b]?this.__players[b]:null},__getClone:function(b,c){for(var d in this.__clones){var e=this.__clones[d];if(null===e.isPlaying&&e.origin===b)return e}if("[object Object]"===Object.prototype.toString.call(c)){d={};for(var f in c)d[f]=c[f];d.autoplay=!1;f=new jukebox.Player(d,b);f.isClone=!0;f.wasReady=!1;return this.__clones[f.id]=f}return null},loop:function(){if(0!==this.__playersLength)if(this.__queue.length&& this.__playersLengthb.isPlaying.end&&(!0===b.isPlaying.loop?b.play(b.isPlaying.start,!0):b.stop()):b.isClone&&null===b.isPlaying?this.remove(b):void 0!==b.backgroundMusic&&null===b.isPlaying&&c>b.backgroundMusic.end&&b.backgroundHackForiOS()},getPlayableResource:function(b){"[object Array]"!==Object.prototype.toString.call(b)&&(b=[b]);for(var c=0,d=b.length;c=b){d._volume=b;if(d._muted)return d; d.usingWebAudio&&d.masterGain.gain.setValueAtTime(b,c.ctx.currentTime);for(var e=0;eparseInt(j[0].split("/")[1], 10);b._codecs={mp3:!(j||!f&&!d.canPlayType("audio/mp3;").replace(/^no$/,"")),mpeg:!!f,opus:!!d.canPlayType('audio/ogg; codecs="opus"').replace(/^no$/,""),ogg:!!d.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/,""),oga:!!d.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/,""),wav:!!d.canPlayType('audio/wav; codecs="1"').replace(/^no$/,""),aac:!!d.canPlayType("audio/aac;").replace(/^no$/,""),caf:!!d.canPlayType("audio/x-caf;").replace(/^no$/,""),m4a:!!(d.canPlayType("audio/x-m4a;")|| d.canPlayType("audio/m4a;")||d.canPlayType("audio/aac;")).replace(/^no$/,""),mp4:!!(d.canPlayType("audio/x-mp4;")||d.canPlayType("audio/mp4;")||d.canPlayType("audio/aac;")).replace(/^no$/,""),weba:!!d.canPlayType('audio/webm; codecs="vorbis"').replace(/^no$/,""),webm:!!d.canPlayType('audio/webm; codecs="vorbis"').replace(/^no$/,""),dolby:!!d.canPlayType('audio/mp4; codecs="ec-3"').replace(/^no$/,""),flac:!!(d.canPlayType("audio/x-flac;")||d.canPlayType("audio/flac;")).replace(/^no$/,"")};return b}, _enableMobileAudio:function(){var b=this||c,d=/iPhone|iPad|iPod|Android|BlackBerry|BB10|Silk|Mobi/i.test(b._navigator&&b._navigator.userAgent),e=!!("ontouchend"in window||b._navigator&&0=e){if("loaded"!==b._state)return b._queue.push({event:"volume",action:function(){b.volume.apply(b,d)}}),b;"undefined"===typeof f&&(b._volume=e);f=b._getSoundIds(f);for(var m=0;mc&&n>=d)clearInterval(b._interval),b._interval=null,b._fadeTo=null,m.volume(d,b._id), m._emit("fade",b._id)},f)},_stopFade:function(b){var d=this._soundById(b);d&&d._interval&&(this._webAudio&&d._node.gain.cancelScheduledValues(c.ctx.currentTime),clearInterval(d._interval),d._interval=null,this.volume(d._fadeTo,b),d._fadeTo=null,this._emit("fade",b));return this},loop:function(){var b=arguments,c,d;if(0===b.length)return this._loop;if(1===b.length)if("boolean"===typeof b[0])this._loop=c=b[0];else return(b=this._soundById(parseInt(b[0],10)))?b._loop:!1;else 2===b.length&&(c=b[0],d= parseInt(b[1],10));d=this._getSoundIds(d);for(var e=0;ee&&(d=/safari/.test(c._navigator&&c._navigator.userAgent.toLowerCase()),c._navigator&&c._navigator.standalone&&!d||c._navigator&&!c._navigator.standalone&&!d))c.usingWebAudio=!1;c.usingWebAudio&&(c.masterGain="undefined"===typeof c.ctx.createGain?c.ctx.createGainNode():c.ctx.createGain(),c.masterGain.gain.setValueAtTime(c._muted?0:1,c.ctx.currentTime),c.masterGain.connect(c.ctx.destination));c._setup()};"function"===typeof define&&define.amd&&define([],function(){return{Howler:c, Howl:d}});"undefined"!==typeof exports&&(exports.Howler=c,exports.Howl=d);"undefined"!==typeof window?(window.HowlerGlobal=b,window.Howler=c,window.Howl=d,window.Sound=e):"undefined"!==typeof global&&(global.HowlerGlobal=b,global.Howler=c,global.Howl=d,global.Sound=e)})(); (function(){HowlerGlobal.prototype._pos=[0,0,0];HowlerGlobal.prototype._orientation=[0,0,-1,0,1,0];HowlerGlobal.prototype.stereo=function(b){if(!this.ctx||!this.ctx.listener)return this;for(var c=this._howls.length-1;0<=c;c--)this._howls[c].stereo(b);return this};HowlerGlobal.prototype.pos=function(b,c,d){if(!this.ctx||!this.ctx.listener)return this;c="number"!==typeof c?this._pos[1]:c;d="number"!==typeof d?this._pos[2]:d;if("number"===typeof b)this._pos=[b,c,d],"undefined"!==typeof this.ctx.listener.positionX? (this.ctx.listener.positionX.setTargetAtTime(this._pos[0],Howler.ctx.currentTime,0.1),this.ctx.listener.positionY.setTargetAtTime(this._pos[1],Howler.ctx.currentTime,0.1),this.ctx.listener.positionZ.setTargetAtTime(this._pos[2],Howler.ctx.currentTime,0.1)):this.ctx.listener.setPosition(this._pos[0],this._pos[1],this._pos[2]);else return this._pos;return this};HowlerGlobal.prototype.orientation=function(b,c,d,e,g,t){if(!this.ctx||!this.ctx.listener)return this;var z=this._orientation;c="number"!== typeof c?z[1]:c;d="number"!==typeof d?z[2]:d;e="number"!==typeof e?z[3]:e;g="number"!==typeof g?z[4]:g;t="number"!==typeof t?z[5]:t;if("number"===typeof b)this._orientation=[b,c,d,e,g,t],"undefined"!==typeof this.ctx.listener.forwardX?(this.ctx.listener.forwardX.setTargetAtTime(b,Howler.ctx.currentTime,0.1),this.ctx.listener.forwardY.setTargetAtTime(c,Howler.ctx.currentTime,0.1),this.ctx.listener.forwardZ.setTargetAtTime(d,Howler.ctx.currentTime,0.1),this.ctx.listener.upX.setTargetAtTime(b,Howler.ctx.currentTime, 0.1),this.ctx.listener.upY.setTargetAtTime(c,Howler.ctx.currentTime,0.1),this.ctx.listener.upZ.setTargetAtTime(d,Howler.ctx.currentTime,0.1)):this.ctx.listener.setOrientation(b,c,d,e,g,t);else return z;return this};var b=Howl.prototype.init;Howl.prototype.init=function(c){this._orientation=c.orientation||[1,0,0];this._stereo=c.stereo||null;this._pos=c.pos||null;this._pannerAttr={coneInnerAngle:"undefined"!==typeof c.coneInnerAngle?c.coneInnerAngle:360,coneOuterAngle:"undefined"!==typeof c.coneOuterAngle? c.coneOuterAngle:360,coneOuterGain:"undefined"!==typeof c.coneOuterGain?c.coneOuterGain:0,distanceModel:"undefined"!==typeof c.distanceModel?c.distanceModel:"inverse",maxDistance:"undefined"!==typeof c.maxDistance?c.maxDistance:1E4,panningModel:"undefined"!==typeof c.panningModel?c.panningModel:"HRTF",refDistance:"undefined"!==typeof c.refDistance?c.refDistance:1,rolloffFactor:"undefined"!==typeof c.rolloffFactor?c.rolloffFactor:1};this._onstereo=c.onstereo?[{fn:c.onstereo}]:[];this._onpos=c.onpos? [{fn:c.onpos}]:[];this._onorientation=c.onorientation?[{fn:c.onorientation}]:[];return b.call(this,c)};Howl.prototype.stereo=function(b,c){var d=this;if(!d._webAudio)return d;if("loaded"!==d._state)return d._queue.push({event:"stereo",action:function(){d.stereo(b,c)}}),d;var m="undefined"===typeof Howler.ctx.createStereoPanner?"spatial":"stereo";if("undefined"===typeof c)if("number"===typeof b)d._stereo=b,d._pos=[b,0,0];else return d._stereo;for(var g=d._getSoundIds(c),t=0;tthis.width||f>this.height)){var m=ig.system.scale,g=Math.floor(e*m),t=Math.floor(f*m),z=j?-1:1,y=n?-1:1;if(j||n)ig.system.context.save(),ig.system.context.scale(z,y);ig.system.context.drawImage(this.data,Math.floor(d*e)%this.width*m,Math.floor(d*e/this.width)*f*m,g,t,ig.system.getDrawPos(b)*z-(j?g:0),ig.system.getDrawPos(c)*y-(n?t:0),g,t);(j|| n)&&ig.system.context.restore();ig.Image.drawCount++}}});ig.Image.drawCount=0;ig.Image.cache={};ig.Image.reloadCache=function(){for(var b in ig.Image.cache)ig.Image.cache[b].reload()}});ig.baked=!0; ig.module("impact.font").requires("impact.image").defines(function(){ig.Font=ig.Image.extend({widthMap:[],indices:[],firstChar:32,alpha:1,letterSpacing:1,lineSpacing:0,onload:function(b){this._loadMetrics(this.data);this.parent(b)},widthForString:function(b){if(-1!==b.indexOf("\n")){b=b.split("\n");for(var c=0,d=0;db||b>=this.indices.length)return 0;var e=ig.system.scale,f=this.widthMap[b]*e,j=(this.height-2)*e;ig.system.context.drawImage(this.data,this.indices[b]*e,0,f,j,ig.system.getDrawPos(c),ig.system.getDrawPos(d),f,j);return this.widthMap[b]+this.letterSpacing},_loadMetrics:function(b){this.height=b.height-1;this.widthMap=[];this.indices= [];for(var c=ig.getImagePixels(b,0,b.height-1,b.width,1),d=0,e=0,f=0;fc.data[j]&&e&&(this.widthMap.push(e),this.indices.push(f-e),d++,e=0)}this.widthMap.push(e);this.indices.push(f-e)}});ig.Font.ALIGN={LEFT:0,RIGHT:1,CENTER:2}});ig.baked=!0; ig.module("impact.sound").defines(function(){ig.SoundManager=ig.Class.extend({clips:{},volume:1,format:null,init:function(){if(!ig.Sound.enabled||!window.Audio)ig.Sound.enabled=!1;else{for(var b=new Audio,c=0;c=b?(this.stop(),this.currentTrack.volume=this._volume,clearInterval(this._fadeInterval)):this.currentTrack.volume=b},_endedCallback:function(){this._loop?this.play():this.next()}});ig.Sound=ig.Class.extend({path:"",volume:1,currentClip:null,multiChannel:!0,init:function(b,c){this.path=b;this.multiChannel=!1!==c;this.load()},load:function(b){ig.Sound.enabled?ig.ready?ig.soundManager.load(this.path, this.multiChannel,b):ig.addResource(this):b&&b(this.path,!0)},play:function(){ig.Sound.enabled&&(this.currentClip=ig.soundManager.get(this.path),this.currentClip.volume=ig.soundManager.volume*this.volume,this.currentClip.play())},stop:function(){this.currentClip&&(this.currentClip.pause(),this.currentClip.currentTime=0)}});ig.Sound.FORMAT={MP3:{ext:"mp3",mime:"audio/mpeg"},M4A:{ext:"m4a",mime:"audio/mp4; codecs=mp4a"},OGG:{ext:"ogg",mime:"audio/ogg; codecs=vorbis"},WEBM:{ext:"webm",mime:"audio/webm; codecs=vorbis"}, CAF:{ext:"caf",mime:"audio/x-caf"}};ig.Sound.use=[ig.Sound.FORMAT.OGG,ig.Sound.FORMAT.MP3];ig.Sound.channels=4;ig.Sound.enabled=!0});ig.baked=!0; ig.module("impact.loader").requires("impact.image","impact.font","impact.sound").defines(function(){ig.Loader=ig.Class.extend({resources:[],gameClass:null,status:0,done:!1,_unloaded:[],_drawStatus:0,_intervalId:0,_loadCallbackBound:null,init:function(b,c){this.gameClass=b;this.resources=c;this._loadCallbackBound=this._loadCallback.bind(this);for(var d=0;db?this.initMouse():0ig.system.width||c>ig.system.height||(0>b+d||0>c+d)||(1!=this.alpha&&(ig.system.context.globalAlpha=this.alpha),0==this.angle?this.sheet.image.drawTile(b,c,this.tile,this.sheet.width,this.sheet.height,this.flip.x,this.flip.y):(ig.system.context.save(),ig.system.context.translate(ig.system.getDrawPos(b+this.pivot.x),ig.system.getDrawPos(c+this.pivot.y)),ig.system.context.rotate(this.angle), this.sheet.image.drawTile(-this.pivot.x,-this.pivot.y,this.tile,this.sheet.width,this.sheet.height,this.flip.x,this.flip.y),ig.system.context.restore()),1!=this.alpha&&(ig.system.context.globalAlpha=1))}})});ig.baked=!0; ig.module("impact.entity").requires("impact.animation","impact.impact").defines(function(){ig.Entity=ig.Class.extend({id:0,settings:{},size:{x:16,y:16},offset:{x:0,y:0},pos:{x:0,y:0},last:{x:0,y:0},vel:{x:0,y:0},accel:{x:0,y:0},friction:{x:0,y:0},maxVel:{x:100,y:100},zIndex:0,gravityFactor:0,standing:!1,bounciness:0,minBounceVelocity:40,anims:{},animSheet:null,currentAnim:null,health:10,type:0,checkAgainst:0,collides:0,_killed:!1,slopeStanding:{min:(44).toRad(),max:(136).toRad()},init:function(b, c,d){this.id=++ig.Entity._lastId;this.pos.x=this.last.x=b;this.pos.y=this.last.y=c;ig.merge(this,d)},reset:function(b,c,d){var e=this.constructor.prototype;this.pos.x=b;this.pos.y=c;this.last.x=b;this.last.y=c;this.vel.x=e.vel.x;this.vel.y=e.vel.y;this.accel.x=e.accel.x;this.accel.y=e.accel.y;this.health=e.health;this._killed=e._killed;this.standing=e.standing;this.type=e.type;this.checkAgainst=e.checkAgainst;this.collides=e.collides;ig.merge(this,d)},addAnim:function(b,c,d,e){if(!this.animSheet)throw"No animSheet to add the animation "+ b+" to.";c=new ig.Animation(this.animSheet,c,d,e);this.anims[b]=c;this.currentAnim||(this.currentAnim=c);return c},update:function(){this.last.x=this.pos.x;this.last.y=this.pos.y;this.vel.y+=ig.game.gravity*ig.system.tick*this.gravityFactor;this.vel.x=this.getNewVelocity(this.vel.x,this.accel.x,this.friction.x,this.maxVel.x);this.vel.y=this.getNewVelocity(this.vel.y,this.accel.y,this.friction.y,this.maxVel.y);var b=ig.game.collisionMap.trace(this.pos.x,this.pos.y,this.vel.x*ig.system.tick,this.vel.y* ig.system.tick,this.size.x,this.size.y);this.handleMovementTrace(b);this.currentAnim&&this.currentAnim.update()},getNewVelocity:function(b,c,d,e){return c?(b+c*ig.system.tick).limit(-e,e):d?(c=d*ig.system.tick,0b+c?b+c:0):b.limit(-e,e)},handleMovementTrace:function(b){this.standing=!1;b.collision.y&&(0this.minBounceVelocity?this.vel.y*=-this.bounciness:(0 this.minBounceVelocity?this.vel.x*-this.bounciness:0);if(b.collision.slope){var c=b.collision.slope;if(0this.slopeStanding.min&&c=this.health&&this.kill()},touches:function(b){return!(this.pos.x>=b.pos.x+b.size.x||this.pos.x+this.size.x<=b.pos.x||this.pos.y>=b.pos.y+b.size.y||this.pos.y+this.size.y<=b.pos.y)},distanceTo:function(b){var c=this.pos.x+this.size.x/2-(b.pos.x+b.size.x/2);b=this.pos.y+this.size.y/2-(b.pos.y+b.size.y/2);return Math.sqrt(c*c+b*b)},angleTo:function(b){return Math.atan2(b.pos.y+ b.size.y/2-(this.pos.y+this.size.y/2),b.pos.x+b.size.x/2-(this.pos.x+this.size.x/2))},check:function(){},collideWith:function(){},ready:function(){},erase:function(){}});ig.Entity._lastId=0;ig.Entity.COLLIDES={NEVER:0,LITE:1,PASSIVE:2,ACTIVE:4,FIXED:8};ig.Entity.TYPE={NONE:0,A:1,B:2,BOTH:3};ig.Entity.checkPair=function(b,c){b.checkAgainst&c.type&&b.check(c);c.checkAgainst&b.type&&c.check(b);b.collides&&c.collides&&b.collides+c.collides>ig.Entity.COLLIDES.ACTIVE&&ig.Entity.solveCollision(b,c)};ig.Entity.solveCollision= function(b,c){var d=null;if(b.collides==ig.Entity.COLLIDES.LITE||c.collides==ig.Entity.COLLIDES.FIXED)d=b;else if(c.collides==ig.Entity.COLLIDES.LITE||b.collides==ig.Entity.COLLIDES.FIXED)d=c;b.last.x+b.size.x>c.last.x&&b.last.xc.last.y&&b.last.yb.minBounceVelocity?b.vel.y*=-b.bounciness:(b.standing=!0,b.vel.y=0)):(d=(b.vel.y-c.vel.y)/2,b.vel.y=-d,c.vel.y=d,f=c.vel.x*ig.system.tick,d=ig.game.collisionMap.trace(b.pos.x,b.pos.y,f,-e/2,b.size.x,b.size.y),b.pos.y=d.pos.y,b=ig.game.collisionMap.trace(c.pos.x,c.pos.y,0,e/2,c.size.x,c.size.y),c.pos.y=b.pos.y)}});ig.baked=!0; ig.module("impact.map").defines(function(){ig.Map=ig.Class.extend({tilesize:8,width:1,height:1,data:[[]],name:null,init:function(b,c){this.tilesize=b;this.data=c;this.height=c.length;this.width=c[0].length;this.pxWidth=this.width*this.tilesize;this.pxHeight=this.height*this.tilesize},getTile:function(b,c){var d=Math.floor(b/this.tilesize),e=Math.floor(c/this.tilesize);return 0<=d&&dthis.lastSlope&&(this.lastSlope=j|0)},trace:function(b,c,f,j,n,m){var g={collision:{x:!1,y:!1,slope:!1},pos:{x:b,y:c},tile:{x:0,y:0}},t=Math.ceil(Math.max(Math.abs(f),Math.abs(j))/this.tilesize);if(1j?this.tilesize:0,A=Math.max(Math.floor(f/this.tilesize),0),D=Math.min(Math.ceil((f+g)/this.tilesize),this.height);j=Math.floor((b.pos.x+B)/this.tilesize);var x=Math.floor((c+B)/this.tilesize);if(0x||x>=this.width)x=-1;if(0<=j&&jthis.lastSlope||1n?this.tilesize:0;A=Math.max(Math.floor(b.pos.x/this.tilesize),0);I=Math.min(Math.ceil((b.pos.x+m)/this.tilesize),this.width);G=Math.floor((b.pos.y+B)/this.tilesize); D=Math.floor((f+B)/this.tilesize);if(0D||D>=this.height)D=-1;if(0<=G&&Gthis.lastSlope||1B?g:0)-(z+A[0])*this.tilesize;t=j+m+(0n*-B+m*c)return I;z=Math.sqrt(c*c+B*B);y=B/z;z=-c/z;var D=g*y+t*z,A=y*D,D=z*D;if(A*A+D*D>=n*n+m*m)return I||0.5>c*(t-m)-B*(g-n);b.pos.x=f+n-A;b.pos.y=j+m-D;b.collision.slope={x:c,y:B,nx:y,ny:z};return!0}return!1}});var b=1/3,c=2/3;ig.CollisionMap.defaultTileDef={5:[0,1,1,c,!0],6:[0,c,1,b,!0],7:[0,b,1,0,!0],3:[0,1,1,0.5,!0],4:[0,0.5,1,0,!0],2:[0, 1,1,0,!0],10:[0.5,1,1,0,!0],21:[0,1,0.5,0,!0],32:[c,1,1,0,!0],43:[b,1,c,0,!0],54:[0,1,b,0,!0],27:[0,0,1,b,!0],28:[0,b,1,c,!0],29:[0,c,1,1,!0],25:[0,0,1,0.5,!0],26:[0,0.5,1,1,!0],24:[0,0,1,1,!0],11:[0,0,0.5,1,!0],22:[0.5,0,1,1,!0],33:[0,0,b,1,!0],44:[b,0,c,1,!0],55:[c,0,1,1,!0],16:[1,b,0,0,!0],17:[1,c,0,b,!0],18:[1,1,0,c,!0],14:[1,0.5,0,0,!0],15:[1,1,0,0.5,!0],13:[1,1,0,0,!0],8:[0.5,1,0,0,!0],19:[1,1,0.5,0,!0],30:[b,1,0,0,!0],41:[c,1,b,0,!0],52:[1,1,c,0,!0],38:[1,c,0,1,!0],39:[1,b,0,c,!0],40:[1,0, 0,b,!0],36:[1,0.5,0,1,!0],37:[1,0,0,0.5,!0],35:[1,0,0,1,!0],9:[1,0,0.5,1,!0],20:[0.5,0,0,1,!0],31:[1,0,c,1,!0],42:[c,0,b,1,!0],53:[b,0,0,1,!0],12:[0,0,1,0,!1],23:[1,1,0,1,!1],34:[1,0,1,1,!1],45:[0,1,0,0,!1]};ig.CollisionMap.staticNoCollision={trace:function(b,c,f,j){return{collision:{x:!1,y:!1,slope:!1},pos:{x:b+f,y:c+j},tile:{x:0,y:0}}}}});ig.baked=!0; ig.module("impact.background-map").requires("impact.map","impact.image").defines(function(){ig.BackgroundMap=ig.Map.extend({tiles:null,scroll:{x:0,y:0},distance:1,repeat:!1,tilesetName:"",foreground:!1,enabled:!0,preRender:!1,preRenderedChunks:null,chunkSize:512,debugChunks:!1,anims:{},init:function(b,c,d){this.parent(b,c);this.setTileset(d)},setTileset:function(b){this.tilesetName=b instanceof ig.Image?b.path:b;this.tiles=new ig.Image(this.tilesetName);this.preRenderedChunks=null},setScreenPos:function(b, c){this.scroll.x=b/this.distance;this.scroll.y=c/this.distance},preRenderMapToChunks:function(){var b=this.width*this.tilesize*ig.system.scale,c=this.height*this.tilesize*ig.system.scale;this.chunkSize=Math.min(Math.max(b,c),this.chunkSize);var d=Math.ceil(b/this.chunkSize),e=Math.ceil(c/this.chunkSize);this.preRenderedChunks=[];for(var f=0;f=this.height||0>t){if(!this.repeat)continue;t=(t%this.height+this.height)%this.height}for(var z=-1,y=n;y=this.width||0>b){if(!this.repeat)continue;b=(b%this.width+this.width)%this.width}if(b=this.data[t][b])(c=this.anims[b- 1])?c.draw(y,j):this.tiles.drawTile(y,j,b-1,this.tilesize)}}}})});ig.baked=!0; ig.module("impact.game").requires("impact.impact","impact.entity","impact.collision-map","impact.background-map").defines(function(){ig.Game=ig.Class.extend({clearColor:"#000000",gravity:0,screen:{x:0,y:0},_rscreen:{x:0,y:0},entities:[],namedEntities:{},collisionMap:ig.CollisionMap.staticNoCollision,backgroundMaps:[],backgroundAnims:{},autoSort:!1,sortBy:null,cellSize:64,_deferredKill:[],_levelToLoad:null,_doSortEntities:!1,staticInstantiate:function(){this.sortBy=this.sortBy||ig.Game.SORT.Z_INDEX; ig.game=this;return null},loadLevel:function(b){this.screen={x:0,y:0};this.entities=[];this.namedEntities={};for(var c=0;ce&&window.focus(),("touchstart"==c.type||"mousedown"==c.type)&&this.mousemove(c),e=this.bindings[e])this.actions[e]=!0,this.locks[e]||(this.presses[e]= !0,this.locks[e]=!0),c.stopPropagation(),c.preventDefault()}})});ig.baked=!0; ig.module("plugins.handlers.dom-handler").defines(function(){ig.DomHandler=ig.Class.extend({JQUERYAVAILABLE:!1,init:function(){this.JQUERYAVAILABLE=this._jqueryAvailable()},_jqueryAvailable:function(){return"undefined"!==typeof jQuery},addEvent:function(b,c,d,e){if(this.JQUERYAVAILABLE)b.on(c,d);else b.addEventListener(c,d,e)},create:function(b){return this.JQUERYAVAILABLE?$("<"+b+">"):ig.$new(b)},getElementByClass:function(b){return this.JQUERYAVAILABLE?$("."+b):document.getElementsByClassName(b)}, getElementById:function(b){return this.JQUERYAVAILABLE?0<$(b).length?$(b):null:ig.$(b)},appendChild:function(b,c){this.JQUERYAVAILABLE?b.append(c):b.appendChild(c)},appendToBody:function(b){this.JQUERYAVAILABLE?$("body").append(b):document.body.appendChild(b)},resize:function(b,c,d){if(this.JQUERYAVAILABLE)b.width(c.toFixed(2)),b.height(d.toFixed(2));else{var e=b.style.visibility;c="width:"+c.toFixed(2)+"px; height:"+d.toFixed(2)+"px;";this.attr(b,"style",c);b.style.visibility=e}},resizeOffsetLeft:function(b, c,d,e){if(this.JQUERYAVAILABLE)b.width(c.toFixed(2)),b.height(d.toFixed(2)),b.css("left",e);else{var f=b.style.visibility;c="width:"+c.toFixed(2)+"px; height:"+d.toFixed(2)+"px; left: "+e.toFixed(2)+"px;";this.attr(b,"style",c);b.style.visibility=f}},resizeOffset:function(b,c,d,e,f){if(this.JQUERYAVAILABLE)b.width(c.toFixed(2)),b.height(d.toFixed(2)),b.css("left",e),b.css("top",f);else{var j=b.style.visibility;c="width:"+c.toFixed(2)+"px; height:"+d.toFixed(2)+"px; left: "+e.toFixed(2)+"px; top: "+ f.toFixed(2)+"px;";this.attr(b,"style",c);b.style.visibility=j}},css:function(b,c){if(this.JQUERYAVAILABLE)b.css(c);else{var d="",e;for(e in c)d+=e+":"+c[e]+";";this.attr(b,"style",d)}},getOffsets:function(b){return this.JQUERYAVAILABLE?(b=b.offset(),{left:b.left,top:b.top}):{left:b.offsetLeft,top:b.offsetTop}},attr:function(b,c,d){if("undefined"===typeof d)return this.JQUERYAVAILABLE?b.attr(c):b.getAttribute(c);this.JQUERYAVAILABLE?b.attr(c,d):b.setAttribute(c,d)},show:function(b){this.JQUERYAVAILABLE? (b.show(),b.css("visibility","visible")):b&&(b.style?b.style.visibility="visible":b[0]&&(b[0].style.visibility="visible"))},hide:function(b){this.JQUERYAVAILABLE?(b.hide(),b.css("visibility","hidden")):b&&(b.style?b.style.visibility="hidden":b[0]&&(b[0].style.visibility="hidden"))},getQueryVariable:function(b){for(var c=window.location.search.substring(1).split("&"),d=0;dthis.maxScalingOnMobile&&(c=this.maxScalingOnMobile),cthis.maxScalingOnDesktop&&(c=this.maxScalingOnDesktop),cd&&(d=0);0>e&&(e=0);ig.domHandler.resizeOffset(c,Math.floor(ig.sizeHandler.mobile.actualSize.x),Math.floor(ig.sizeHandler.mobile.actualSize.y),d,e);var f=!1;if(this.portraitMode?window.innerHeightwindow.innerWidth)if(this.enableStretchToFitOnAntiPortraitModeFlag)ig.domHandler.resizeOffset(c,Math.floor(window.innerWidth), Math.floor(window.innerHeight),0,0);else{var f=new Vector2(window.innerWidth/this.mobile.actualResolution.y,window.innerHeight/this.mobile.actualResolution.x),d=Math.min(f.x,f.y),f=this.mobile.actualResolution.y*d,j=this.mobile.actualResolution.x*d,d=Math.floor(ig.sizeHandler.windowSize.x/2-f/2),e=Math.floor(ig.sizeHandler.windowSize.y/2-j/2);0>d&&(d=0);0>e&&(e=0);ig.domHandler.resizeOffset(c,Math.floor(f),Math.floor(j),d,e)}}else ig.domHandler.resize(c,Math.floor(ig.sizeHandler.mobile.actualSize.x), Math.floor(ig.sizeHandler.mobile.actualSize.y));else this.enableStretchToFitOnDesktopFlag?ig.domHandler.resize(c,Math.floor(ig.sizeHandler.desktop.actualSize.x),Math.floor(ig.sizeHandler.desktop.actualSize.y)):(d=Math.floor(ig.sizeHandler.windowSize.x/2-ig.sizeHandler.desktop.actualSize.x/2),e=Math.floor(ig.sizeHandler.windowSize.y/2-ig.sizeHandler.desktop.actualSize.y/2),0>d&&(d=0),0>e&&(e=0),ig.domHandler.resizeOffset(c,Math.floor(ig.sizeHandler.desktop.actualSize.x),Math.floor(ig.sizeHandler.desktop.actualSize.y), d,e))}for(var n in this.adsToResize)b=ig.domHandler.getElementById("#"+n),c=ig.domHandler.getElementById("#"+n+"-Box"),f=(window.innerWidth-this.adsToResize[n]["box-width"])/2+"px",d=(window.innerHeight-this.adsToResize[n]["box-height"])/2+"px",b&&ig.domHandler.css(b,{width:window.innerWidth,height:window.innerHeight}),c&&ig.domHandler.css(c,{left:f,top:d});for(n in this.dynamicClickableEntityDivs){b=Math.min(ig.sizeHandler.scaleRatioMultiplier.x,ig.sizeHandler.scaleRatioMultiplier.y);c=ig.domHandler.getElementById("#"+ n);if(ig.ua.mobile)var m=this.dynamicClickableEntityDivs[n].entity_pos_x,j=this.dynamicClickableEntityDivs[n].entity_pos_y,d=this.dynamicClickableEntityDivs[n].width,f=this.dynamicClickableEntityDivs[n].height,e=Math.floor(m*this.scaleRatioMultiplier.x)+"px",j=Math.floor(j*this.scaleRatioMultiplier.y)+"px",d=Math.floor(d*this.scaleRatioMultiplier.x)+"px",f=Math.floor(f*this.scaleRatioMultiplier.y)+"px";else var f=ig.domHandler.getElementById("#canvas"),f=ig.domHandler.getOffsets(f),e=f.left,g=f.top, m=this.dynamicClickableEntityDivs[n].entity_pos_x,j=this.dynamicClickableEntityDivs[n].entity_pos_y,d=this.dynamicClickableEntityDivs[n].width,f=this.dynamicClickableEntityDivs[n].height,e=Math.floor(e+m*b)+"px",j=Math.floor(g+j*b)+"px",d=Math.floor(d*b)+"px",f=Math.floor(f*b)+"px";ig.domHandler.css(c,{"float":"left",position:"absolute",left:e,top:j,width:d,height:f,"z-index":3});this.dynamicClickableEntityDivs[n]["font-size"]&&ig.domHandler.css(c,{"font-size":this.dynamicClickableEntityDivs[n]["font-size"]* b+"px"})}$("#ajaxbar").width(this.windowSize.x);$("#ajaxbar").height(this.windowSize.y)},resize:function(){this.sizeCalcs();this.resizeLayers()},reorient:function(){console.log("changing orientation ...");if(ig.ua.mobile){var b=!1,b=this.portraitMode?window.innerHeightwindow.innerWidth,c=this.domHandler.getElementById("#orientate"),d=this.domHandler.getElementById("#game");b?(this.domHandler.show(c),this.domHandler.hide(d),console.log("portrait"+window.innerWidth+ ","+window.innerHeight)):(this.domHandler.show(d),this.domHandler.hide(c),console.log("landscape"+window.innerWidth+","+window.innerHeight))}ig.ua.mobile?(this.resize(),this.resizeAds()):this.resize()},resizeAds:function(){for(var b in this.adsToResize){var c=ig.domHandler.getElementById("#"+b),d=ig.domHandler.getElementById("#"+b+"-Box"),e=(window.innerWidth-this.adsToResize[b]["box-width"])/2+"px",f=(window.innerHeight-this.adsToResize[b]["box-height"])/2+"px";c&&ig.domHandler.css(c,{width:window.innerWidth, height:window.innerHeight});d&&ig.domHandler.css(d,{left:e,top:f})}},samsungFix:function(){ig.ua.android&&!(4.2>parseFloat(navigator.userAgent.slice(navigator.userAgent.indexOf("Android")+8,navigator.userAgent.indexOf("Android")+11)))&&(!(0>navigator.userAgent.indexOf("GT"))&&!(0b?0:isNaN(b)?1:1b?0:isNaN(b)?1:1b){this.soundList[c].volume(0);break}isNaN(b)?this.soundList[c].volume(1):1b){this.soundList[c].volume(0);break}isNaN(b)?this.soundList[c].volume(1):1=b?this.jukeboxPlayer.setVolume(this.minVolume):isNaN(b)?this.jukeboxPlayer.setVolume(1): 1=d.indexOf("chrome")&&(j=c),d.indexOf("win64")&&(j=c));var n=new XMLHttpRequest;n.open("GET",j,!0);n.responseType="arraybuffer";n.onload=function(){this.webaudio.context.decodeAudioData(n.response, function(b){this.webaudio.buffer=b;this.webaudio.source_loop={};this.bgmPlaying?this.play(null,!0):this.stop()}.bind(this),function(){console.log('Error decoding audio "'+j+'".')})}.bind(this);n.send();if(4==n.readyState&&"undefined"!==typeof Audio){this.useHTML5Audio=!0;try{new Audio}catch(m){this.useHTML5Audio=!1}this.useHTML5Audio&&(console.log("Using HTML5 Audio"),this.webaudio=null,this.audio=new Audio,this.isSupported=!0,this.initHTML5Audio(b))}break}},initIOSWebAudioUnlock:function(){if(this.webaudio){webaudio= this.webaudio;var b=function(){var c=webaudio.context,d=c.createBuffer(1,1,22050),e=c.createBufferSource();e.buffer=d;e.connect(c.destination);"undefined"===typeof e.start?e.noteOn(0):e.start(0);setTimeout(function(){(e.playbackState===e.PLAYING_STATE||e.playbackState===e.FINISHED_STATE)&&window.removeEventListener("touchend",b,!1)}.bind(this),0)};window.addEventListener("touchend",b,!1)}},initHTML5Audio:function(b){if(this.useHTML5Audio&&this.audio){var c=this.audio;this.codecs={};this.codecs={mp3:!!c.canPlayType("audio/mpeg;").replace(/^no$/, ""),opus:!!c.canPlayType('audio/ogg; codecs="opus"').replace(/^no$/,""),ogg:!!c.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/,""),wav:!!c.canPlayType('audio/wav; codecs="1"').replace(/^no$/,""),aac:!!c.canPlayType("audio/aac;").replace(/^no$/,""),m4a:!!(c.canPlayType("audio/x-m4a;")||c.canPlayType("audio/m4a;")||c.canPlayType("audio/aac;")).replace(/^no$/,""),mp4:!!(c.canPlayType("audio/x-mp4;")||c.canPlayType("audio/mp4;")||c.canPlayType("audio/aac;")).replace(/^no$/,""),weba:!!c.canPlayType('audio/webm; codecs="vorbis"').replace(/^no$/, "")};this.is={ff:Boolean(null!=window.mozInnerScreenX&&/firefox/.test(navigator.userAgent.toLowerCase())),ie:Boolean(document.all&&!window.opera),opera:Boolean(window.opera),chrome:Boolean(window.chrome),safari:Boolean(!window.chrome&&/safari/.test(navigator.userAgent.toLowerCase())&&window.getComputedStyle&&!window.globalStorage&&!window.opera)};this.playDelay=-60;this.stopDelay=30;this.is.chrome&&(this.playDelay=-25);this.is.chrome&&(this.stopDelay=25);this.is.ff&&(this.playDelay=-25);this.is.ff&& (this.stopDelay=85);this.is.opera&&(this.playDelay=5);this.is.opera&&(this.stopDelay=0);for(var d in b){this.soundList[d]=d;var e=b[d].path,c=e+"."+ig.Sound.FORMAT.OGG.ext,e=e+"."+ig.Sound.FORMAT.MP3.ext,f=null;this.codecs[ig.Sound.FORMAT.OGG.ext.toLowerCase()]?f=c:this.codecs[ig.Sound.FORMAT.MP3.ext.toLowerCase()]&&(f=e);if(f){ig.ua.mobile?ig.ua.iOS&&(f=e):(b=navigator.userAgent.toLowerCase(),-1!=b.indexOf("safari")&&-1>=b.indexOf("chrome")&&(f=e));this.audio.addEventListener("error",function(){this.audio.error&& 4===this.audio.error.code&&(this.isSupported=!1)},!1);this.audio.src=f;this.audio._pos=0;this.audio.preload="auto";this.audio.volume=this._volume;this.inactiveAudio=new Audio;this.inactiveAudio.src=f;this.inactiveAudio._pos=0;this.inactiveAudio.preload="auto";this.inactiveAudio.volume=this._volume;this.inactiveAudio.load();var j=function(){this._duration=this.audio.duration;this._loaded||(this._loaded=!0);this.bgmPlaying?this.play(null,!0):this.stop();this.audio.removeEventListener("canplaythrough", j,!1)}.bind(this);this.audio.addEventListener("canplaythrough",j,!1);this.audio.load();break}}}},play:function(b,c){if(this.isSupported)if(this.bgmPlaying=!0,this.webaudio){if(!c&&this.reinitOnPlay&&this.webaudio.source_loop.buffer==this.webaudio.buffer){if(this.webaudio.source_loop._playing&&(this.webaudio.source_loop[this.webaudio.compatibility.stop](0),this.webaudio.source_loop._playing=!1,this.pausedTime+=this.webaudio.context.currentTime-this.webaudio.source_loop._startTime,this.pausedTime%= this.webaudio.source_loop.buffer.duration,this.webaudio.source_loop._startTime=0,"noteOn"===this.webaudio.compatibility.start))this.webaudio.source_once[this.webaudio.compatibility.stop](0);try{this.webaudio.context.close();this.webaudio.context=new this.AudioContext;this.webaudio.gainNode=this.webaudio.context.createGain();this.webaudio.gainNode.connect(this.webaudio.context.destination);this.webaudio.gainNode.gain.value=this._volume;var d="start",e="stop",f=this.webaudio.context.createBufferSource(); "function"!==typeof f.start&&(d="noteOn");this.webaudio.compatibility.start=d;"function"!==typeof f.stop&&(e="noteOff");this.webaudio.compatibility.stop=e;this.webaudio.source_loop={};this.play(null,!0)}catch(j){}}if(this.webaudio.buffer){if(!this.muteFlag&&(this.bgmPlaying=!0,!this.webaudio.source_loop._playing)){this.webaudio.source_loop=this.webaudio.context.createBufferSource();this.webaudio.source_loop.buffer=this.webaudio.buffer;this.webaudio.source_loop.loop=!0;this.webaudio.source_loop.connect(this.webaudio.gainNode); if(null==b||isNaN(b))b=0,this.pausedTime&&(b=this.pausedTime);this.webaudio.source_loop._startTime=this.webaudio.context.currentTime;if("noteOn"===this.webaudio.compatibility.start)this.webaudio.source_once=this.webaudio.context.createBufferSource(),this.webaudio.source_once.buffer=this.webaudio.buffer,this.webaudio.source_once.connect(this.webaudio.gainNode),this.webaudio.source_once.noteGrainOn(0,b,this.webaudio.buffer.duration-b),this.webaudio.source_loop[this.webaudio.compatibility.start](this.webaudio.context.currentTime+ (this.webaudio.buffer.duration-b));else this.webaudio.source_loop[this.webaudio.compatibility.start](0,b);this.webaudio.source_loop._playing=!0}}else this.bgmPlaying=!0}else if(this.audio){var n=this.audio;if(!this.muteFlag)if(this.bgmPlaying=!0,isNaN(b)&&(b=0,this.pausedTime&&(b=this.pausedTime)),d=this._duration-b,this._onEndTimer&&(clearTimeout(this._onEndTimer),this._onEndTimer=null),this._onEndTimer=setTimeout(function(){this.audio.currentTime=0;this.audio.pause();this.pausedTime=0;if(this.inactiveAudio){var b= this.audio;this.audio=this.inactiveAudio;this.inactiveAudio=b}this.play()}.bind(this),1E3*d+this.playDelay),4===n.readyState||!n.readyState&&navigator.isCocoonJS)n.readyState=4,n.currentTime=b,n.muted=this.muteFlag||n.muted,n.volume=this._volume,setTimeout(function(){n.play()},0);else{clearTimeout(this._onEndTimer);this._onEndTimer=null;var m=function(){typeof("function"==this.play)&&(this.play(),n.removeEventListener("canplaythrough",m,!1))}.bind(this);n.addEventListener("canplaythrough",m,!1)}}}, stop:function(){this.bgmPlaying=!1;if(this.isSupported)if(this.webaudio){if(this.webaudio.source_loop._playing&&(this.webaudio.source_loop[this.webaudio.compatibility.stop](0),this.webaudio.source_loop._playing=!1,this.pausedTime+=this.webaudio.context.currentTime-this.webaudio.source_loop._startTime,this.pausedTime%=this.webaudio.source_loop.buffer.duration,this.webaudio.source_loop._startTime=0,"noteOn"===this.webaudio.compatibility.start))this.webaudio.source_once[this.webaudio.compatibility.stop](0)}else if(this.audio){var b= this.audio;4==b.readyState&&(this.pausedTime=b.currentTime,b.currentTime=0,b.pause(),clearTimeout(this._onEndTimer),this._onEndTimer=null)}},volume:function(b){if(isNaN(b)||null==b)return this.getVolume();this.isSupported&&(this._volume=b,0>this._volume?this._volume=0:1=b&&(b=c.settings.spritemap.music.start,ig.ua.android?this.forcelooped||(c.play(b,!0),this.forcelooped=!0,setTimeout(function(){ig.soundHandler.forcelooped=!1},d)):c.setCurrentTime(b)))}else"ImpactMusicPlayer"==this.bgmPlayer.tagName&&(null!=window.mozInnerScreenX&&/firefox/.test(navigator.userAgent.toLowerCase()),b=Boolean(window.chrome),!window.chrome&&/safari/.test(navigator.userAgent.toLowerCase()),d=0.1,ig.ua.mobile&&(d=0.115,ig.ua.android&&(d=0.45,b&&(d=0.3))),c=0,"mp3"== ig.soundManager.format.ext&&(c=0.05),ig.music.currentTrack&&(b=ig.music.currentTrack.duration-d,ig.music.currentTrack.currentTime>=b&&(ig.ua.android?this.forcelooped||(ig.music.currentTrack.pause(),ig.music.currentTrack.currentTime=c,ig.music.currentTrack.play(),this.forcelooped=!0,setTimeout(function(){ig.soundHandler.forcelooped=!1},d)):ig.music.currentTrack.currentTime=c)))}}})});ig.baked=!0; ig.module("plugins.io.storage").defines(function(){ig.Storage=ig.Class.extend({staticInstantiate:function(){return!ig.Storage.instance?null:ig.Storage.instance},init:function(){ig.Storage.instance=this},isCapable:function(){return"undefined"!==typeof window.localStorage},isSet:function(b){return null!==this.get(b)},initUnset:function(b,c){null===this.get(b)&&this.set(b,c)},get:function(b){if(!this.isCapable())return null;try{return JSON.parse(localStorage.getItem(b))}catch(c){return window.localStorage.getItem(b)}}, getInt:function(b){return~~this.get(b)},getFloat:function(b){return parseFloat(this.get(b))},getBool:function(b){return!!this.get(b)},key:function(b){return this.isCapable()?window.localStorage.key(b):null},set:function(b,c){if(!this.isCapable())return null;try{window.localStorage.setItem(b,JSON.stringify(c))}catch(d){console.log(d)}},setHighest:function(b,c){c>this.getFloat(b)&&this.set(b,c)},remove:function(b){if(!this.isCapable())return null;window.localStorage.removeItem(b)},clear:function(){if(!this.isCapable())return null; window.localStorage.clear()}})});ig.baked=!0; ig.module("plugins.io.mouse").defines(function(){Mouse=ig.Class.extend({bindings:{click:[ig.KEY.MOUSE1]},init:function(){ig.input.initMouse();for(var b in this.bindings){this[b]=b;for(var c=0;cd?d:b},pollGamepads:function(){if(this.isSupported){this.leftStick.x=0;this.leftStick.y=0;this.rightStick.x=0;this.rightStick.y=0;this.list=navigator.getGamepads();for(var b in this.bindings){for(var c= !1,d=0;d=b-40&&this.touches[c].x<=b+40&&this.touches.splice(c,1)}}},windowKeyDown:function(b){var c=parseInt(ig.system.canvas.offsetWidth)||ig.system.realWidth,d=parseInt(ig.system.canvas.offsetHeight)||ig.system.realHeight,c=ig.system.scale*(c/ig.system.realWidth),d=ig.system.scale*(d/ig.system.realHeight);if(window.navigator.msPointerEnabled){var e={left:0,top:0};ig.system.canvas.getBoundingClientRect&&(e=ig.system.canvas.getBoundingClientRect()); b=b.changedTouches?b.changedTouches:[b];for(var f=0;fthis.getFloat(b)&&this.set(b,c)},get:function(b){return"undefined"==typeof this.tempData[b]?null:JSON.parse(this.tempData[b])},getInt:function(b){return~~this.get(b)},getFloat:function(b){return parseFloat(this.get(b))}, getBool:function(b){return!!this.get(b)},isSet:function(b){return null!==this.get(b)},remove:function(b){delete this.tempData[b]},clear:function(){this.tempData={}}})});ig.baked=!0; ig.module("plugins.io.io-manager").requires("plugins.io.storage","plugins.io.mouse","plugins.io.keyboard","plugins.io.gamepad","plugins.io.multitouch","plugins.io.multitouch-input","plugins.io.gamepad-input","plugins.io.fake-storage").defines(function(){IoManager=ig.Class.extend({storage:null,localStorageSupport:!1,mouse:null,keyboard:null,multitouch:null,gamepad:null,init:function(){ig.multitouchInput=new ig.MultitouchInput;ig.gamepadInput=new ig.GamepadInput;this.unbindAll();this.initStorage(); this.initMouse();this.initKeyboard()},unbindAll:function(){ig.input.unbindAll();ig.gamepadInput.unbindAll()},initStorage:function(){try{window.localStorage.setItem("test","test"),this.storage=new ig.Storage}catch(b){console.log("using fake storage"),this.storage=new ig.FakeStorage}finally{window.localStorage.removeItem("test")}},initMouse:function(){this.mouse=new Mouse},initKeyboard:function(){this.keyboard=new Keyboard},initMultitouch:function(){this.multitouch=new Multitouch},initGamepad:function(){this.gamepad= new Gamepad},press:function(b){return ig.input.pressed(b)||this.gamepad&&this.gamepad.press(b)?!0:!1},held:function(b){return ig.input.state(b)||this.gamepad&&this.gamepad.state(b)?!0:!1},release:function(b){return ig.input.released(b)||this.gamepad&&this.gamepad.released(b)?!0:!1},getClickPos:function(){return this.mouse.getPos()},getTouchesPos:function(){return this.multitouch.getTouchesPos()},checkOverlap:function(b,c,d,e,f){return b.x>c+e||b.xd+f||b.ythis._drawStatus)){ig.system.context.fillStyle="#000";ig.system.context.fillRect(0,0,ig.system.width,ig.system.height);var b,c,d;b=this.loadingbar0.width;w2=this.loadingbar1.width;c=this.loadingbar0.height;h2=this.loadingbar1.height;d=0.5*ig.system.width-b/2;b=(b-w2)/2;c=(c-h2)/2;this.splash.draw(0,0);this.loadingbar0.draw(d, 380);0.96<=this._drawStatus&&(this._drawStatus=1);ig.system.context.drawImage(this.loadingbar1.data,0,0,w2*this._drawStatus,h2,d+b,380+c,w2*this._drawStatus,h2);ig.system.context.fillStyle="#FFFFFF";ig.system.context.textAlign="center";ig.system.context.font="22pt mainfont";ig.system.context.fillText(_STRINGS.Splash.Loading,ig.system.width/2,450)}},tapToStartDiv:function(b){this.desktopCoverDIV=document.createElement("div");this.desktopCoverDIV.id=this.desktopCoverDIVID;this.desktopCoverDIV.setAttribute("class", "play");this.desktopCoverDIV.setAttribute("style","position: absolute; display: block; z-index: 999999; background-color: rgba(23, 32, 53, 0.7); visibility: visible; font-size: 10vmin; text-align: center; vertical-align: middle; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none;");this.desktopCoverDIV.innerHTML="
"+ _STRINGS.Splash.TapToStart+"
";(document.getElementById("play").parentNode||document.getElementById("ajaxbar")).appendChild(this.desktopCoverDIV);try{"undefined"!==typeof ig.sizeHandler?"undefined"!==typeof ig.sizeHandler.coreDivsToResize&&(ig.sizeHandler.coreDivsToResize.push("#"+this.desktopCoverDIVID),"function"===typeof ig.sizeHandler.reorient&&ig.sizeHandler.reorient()):"undefined"!==typeof coreDivsToResize&&(coreDivsToResize.push(this.desktopCoverDIVID),"function"===typeof sizeHandler&& sizeHandler())}catch(c){console.log(c)}this.desktopCoverDIV.addEventListener("click",function(){try{"undefined"!==typeof ig.soundHandler?("undefined"!==typeof ig.soundHandler.bgmPlayer?"undefined"!==typeof ig.soundHandler.bgmPlayer.webaudio&&"undefined"!==typeof ig.soundHandler.bgmPlayer.webaudio.context&&ig.soundHandler.bgmPlayer.webaudio.context.resume():(ig.soundHandler=null,ig.soundHandler="undefined"!==typeof ig.soundList?new ig.SoundHandler(ig.soundList):new ig.SoundHandler),"undefined"!==typeof ig.soundHandler.sfxPlayer? "function"===typeof ig.soundHandler.sfxPlayer.play&&ig.soundHandler.sfxPlayer.play("staticSound"):"undefined"!==typeof ig.soundHandler.staticSound?"function"===typeof ig.soundHandler.staticSound.play&&ig.soundHandler.staticSound.play():"function"===typeof ig.soundHandler.playSound&&ig.soundHandler.playSound("staticSound")):"undefined"!==typeof Howl?(ig.global.staticSound=new Howl({src:["media/audio/play/static.ogg","media/audio/play/static.mp3"]}),ig.global.staticSound.play()):"undefined"!==typeof createjs&& "undefined"!==typeof createjs.Sound&&"function"===typeof createjs.Sound.play&&createjs.Sound.play("opening")}catch(c){console.log(c)}this.setAttribute("style","visibility: hidden;");"function"===typeof b&&b();ig.system.setGame(MyGame)})}})});ig.baked=!0; ig.module("plugins.tween").requires("impact.entity").defines(function(){Array.prototype.indexOf||(Array.prototype.indexOf=function(b){for(var c=0;c(b*=2)?0.5*b*b:-0.5*(--b*(b-2)-1)};ig.Tween.Easing.Cubic.EaseIn=function(b){return b*b*b};ig.Tween.Easing.Cubic.EaseOut=function(b){return--b*b*b+1};ig.Tween.Easing.Cubic.EaseInOut=function(b){return 1>(b*=2)?0.5*b*b*b:0.5*((b-=2)*b*b+2)};ig.Tween.Easing.Quartic.EaseIn=function(b){return b*b*b*b};ig.Tween.Easing.Quartic.EaseOut=function(b){return-(--b*b*b*b-1)};ig.Tween.Easing.Quartic.EaseInOut=function(b){return 1>(b*=2)?0.5*b*b*b*b:-0.5*((b-=2)*b*b*b-2)};ig.Tween.Easing.Quintic.EaseIn= function(b){return b*b*b*b*b};ig.Tween.Easing.Quintic.EaseOut=function(b){return(b-=1)*b*b*b*b+1};ig.Tween.Easing.Quintic.EaseInOut=function(b){return 1>(b*=2)?0.5*b*b*b*b*b:0.5*((b-=2)*b*b*b*b+2)};ig.Tween.Easing.Sinusoidal.EaseIn=function(b){return-Math.cos(b*Math.PI/2)+1};ig.Tween.Easing.Sinusoidal.EaseOut=function(b){return Math.sin(b*Math.PI/2)};ig.Tween.Easing.Sinusoidal.EaseInOut=function(b){return-0.5*(Math.cos(Math.PI*b)-1)};ig.Tween.Easing.Exponential.EaseIn=function(b){return 0==b?0:Math.pow(2, 10*(b-1))};ig.Tween.Easing.Exponential.EaseOut=function(b){return 1==b?1:-Math.pow(2,-10*b)+1};ig.Tween.Easing.Exponential.EaseInOut=function(b){return 0==b?0:1==b?1:1>(b*=2)?0.5*Math.pow(2,10*(b-1)):0.5*(-Math.pow(2,-10*(b-1))+2)};ig.Tween.Easing.Circular.EaseIn=function(b){return-(Math.sqrt(1-b*b)-1)};ig.Tween.Easing.Circular.EaseOut=function(b){return Math.sqrt(1- --b*b)};ig.Tween.Easing.Circular.EaseInOut=function(b){return 1>(b/=0.5)?-0.5*(Math.sqrt(1-b*b)-1):0.5*(Math.sqrt(1-(b-=2)*b)+1)};ig.Tween.Easing.Elastic.EaseIn= function(b){var c,d=0.1,e=0.4;if(0==b)return 0;if(1==b)return 1;e||(e=0.3);!d||1>d?(d=1,c=e/4):c=e/(2*Math.PI)*Math.asin(1/d);return-(d*Math.pow(2,10*(b-=1))*Math.sin(2*(b-c)*Math.PI/e))};ig.Tween.Easing.Elastic.EaseOut=function(b){var c,d=0.1,e=0.4;if(0==b)return 0;if(1==b)return 1;e||(e=0.3);!d||1>d?(d=1,c=e/4):c=e/(2*Math.PI)*Math.asin(1/d);return d*Math.pow(2,-10*b)*Math.sin(2*(b-c)*Math.PI/e)+1};ig.Tween.Easing.Elastic.EaseInOut=function(b){var c,d=0.1,e=0.4;if(0==b)return 0;if(1==b)return 1; e||(e=0.3);!d||1>d?(d=1,c=e/4):c=e/(2*Math.PI)*Math.asin(1/d);return 1>(b*=2)?-0.5*d*Math.pow(2,10*(b-=1))*Math.sin(2*(b-c)*Math.PI/e):0.5*d*Math.pow(2,-10*(b-=1))*Math.sin(2*(b-c)*Math.PI/e)+1};ig.Tween.Easing.Back.EaseIn=function(b){return b*b*(2.70158*b-1.70158)};ig.Tween.Easing.Back.EaseOut=function(b){return(b-=1)*b*(2.70158*b+1.70158)+1};ig.Tween.Easing.Back.EaseInOut=function(b){return 1>(b*=2)?0.5*b*b*(3.5949095*b-2.5949095):0.5*((b-=2)*b*(3.5949095*b+2.5949095)+2)};ig.Tween.Easing.Bounce.EaseIn= function(b){return 1-ig.Tween.Easing.Bounce.EaseOut(1-b)};ig.Tween.Easing.Bounce.EaseOut=function(b){return(b/=1)<1/2.75?7.5625*b*b:b<2/2.75?7.5625*(b-=1.5/2.75)*b+0.75:b<2.5/2.75?7.5625*(b-=2.25/2.75)*b+0.9375:7.5625*(b-=2.625/2.75)*b+0.984375};ig.Tween.Easing.Bounce.EaseInOut=function(b){return 0.5>b?0.5*ig.Tween.Easing.Bounce.EaseIn(2*b):0.5*ig.Tween.Easing.Bounce.EaseOut(2*b-1)+0.5};ig.Tween.Interpolation={Linear:function(b,c){var d=b.length-1,e=d*c,f=Math.floor(e),j=TWEEN.Interpolation.Utils.Linear; return 0>c?j(b[0],b[1],e):1d?d:f+1],e-f)}}});ig.baked=!0; ig.module("plugins.patches.entity-patch").requires("impact.entity").defines(function(){ig.Entity.inject({handleMovementTrace:function(b){this.standing=!1;b.collision.y&&(0this.minBounceVelocity?this.vel.y*=-this.bounciness:(0this.minBounceVelocity?this.vel.x*-this.bounciness:0);if(b.collision.slope){var c=b.collision.slope;if(0this.slopeStanding.min&&cd?n(b[0],b[1],f): 1e?e:j+1],f-j)},Bezier:function(b,d){for(var e=0,f=b.length-1,j=Math.pow,n=ig.Tween.Interpolation.Utils.Bernstein,m=0;m<=f;m++)e+=j(1-d,f-m)*j(d,m)*b[m]*n(f,m);return e},CatmullRom:function(b,d){var e=b.length-1,f=e*d,j=Math.floor(f),n=ig.Tween.Interpolation.Utils.CatmullRom;return b[0]===b[e]?(0>d&&(j=Math.floor(f=e*(1+d))),n(b[(j-1+e)%e],b[j],b[(j+1)%e],b[(j+2)%e],f-j)):0>d?b[0]-(n(b[0],b[0],b[1],b[1],-f)-b[0]):1this.getFloat(b)&&this.set(b,c)},remove:function(b){if(!this.isCapable())return null;window.localStorage.removeItem(b)},clear:function(){if(!this.isCapable())return null; window.localStorage.clear()}})});ig.baked=!0; ig.module("plugins.nimpact").requires("impact.entity").defines(function(){ig.Entity.inject({anchor:{x:0,y:0},scale:{x:1,y:1},collides:ig.Entity.COLLIDES.NEVER,type:ig.Entity.TYPE.NONE,children:[],init:function(b,c,d){this.parent(b,c,d)},draw:function(){var b=ig.system.context;b.save();b.translate(ig.system.getDrawPos(this.pos.x.round()-ig.game.screen.x),ig.system.getDrawPos(this.pos.y.round()-ig.game.screen.y));b.scale(this.scale.x,this.scale.y);null!=this.currentAnim&&this.currentAnim.draw(0,0); b.restore()},setScale:function(b,c){var d=this.size.x,e=this.size.y;this.scale.x=b;this.scale.y=c||this.scale.x;var f=this.scale.x/ig.system.scale,j=this.scale.y/ig.system.scale,n=d*f,m=e*j;this.size.x=0<=n?n:-n;this.size.y=0<=m?m:-m;this.pos.x=0f?!0:!1,this.anims[g].flip.y=0>j?!0:!1},setAnchor:function(b, c){this.anchor.x=b;this.anchor.y=null==c?b:c;this.pos.x-=this.size.x*this.anchor.x;this.pos.y-=this.size.y*this.anchor.y},nSetPos:function(b,c){this.pos.x=b;this.pos.y=c;this.setAnchor(this.anchor.x,this.anchor.y);this.setScale(this.scale.x,this.scale.y)},getCenter:function(){return{x:this.pos.x+this.size.x/2,y:this.pos.y+this.size.y/2}},getCenterX:function(){return this.pos.x+this.size.x/2},getCenterY:function(){return this.pos.y+this.size.y/2},spawnEntity:function(b,c,d,e){e=ig.merge({zIndex:this.zIndex+ 1,parents:this},e);b=ig.game.spawnEntity(b,c,d,e);this.children.push(b);return b},kill:function(){for(var b=0;bb.length;)b="0"+b;for(;2>c.length;)c="0"+ c;for(;2>d.length;)d="0"+d;return"#"+b+c+d},getInvertedColor:function(){return new ColorRGB(255-this.r,255-this.g,255-this.b,255-this.a)},clone:function(){return new ColorRGB(this.r,this.g,this.b,this.a)}}});this.START_BRANDING_SPLASH;ig.baked=!0; ig.module("plugins.branding.splash").requires("impact.impact","impact.entity").defines(function(){ig.BrandingSplash=ig.Class.extend({init:function(){ig.game.spawnEntity(EntityBranding,0,0);console.log("spawn branding")}});EntityBranding=ig.Entity.extend({gravityFactor:0,size:{x:32,y:32},splash:new ig.Image("branding/splash1.png"),init:function(b,c,d){this.parent(b,c,d);320>=ig.system.width?(this.size.x=320,this.size.y=200):(this.size.x=480,this.size.y=240);this.pos.x=(ig.system.width-this.size.x)/ 2;this.pos.y=-this.size.y-200;this.endPosY=(ig.system.height-this.size.y)/2;b=this.tween({pos:{y:this.endPosY}},0.5,{easing:ig.Tween.Easing.Bounce.EaseIn});c=this.tween({},2.5,{onComplete:function(){ig.game.director.loadLevel(ig.game.director.currentLevel)}});b.chain(c);b.start();this.currentAnim=this.anims.idle},createClickableLayer:function(){console.log("Build clickable layer");this.checkClickableLayer("branding-splash",_SETTINGS.Branding.Logo.Link,_SETTINGS.Branding.Logo.NewWindow)},doesClickableLayerExist:function(b){for(k in dynamicClickableEntityDivs)if(k== b)return!0;return!1},checkClickableLayer:function(b,c,d){"undefined"==typeof wm&&(this.doesClickableLayerExist(b)?(ig.game.showOverlay([b]),$("#"+b).find("[href]").attr("href",c)):this.createClickableOutboundLayer(b,c,"media/graphics/misc/invisible.png",d))},createClickableOutboundLayer:function(b,c,d,e){var f=ig.$new("div");f.id=b;document.body.appendChild(f);f=$("#"+f.id);f.css("float","left");f.css("position","absolute");if(ig.ua.mobile){var j=window.innerHeight/mobileHeight,n=window.innerWidth/ mobileWidth;f.css("left",this.pos.x*n);f.css("top",this.pos.y*j);f.css("width",this.size.x*n);f.css("height",this.size.y*j)}else j=w/2-destW/2,n=h/2-destH/2,console.log(j,n),f.css("left",j+this.pos.x*multiplier),f.css("top",n+this.pos.y*multiplier),f.css("width",this.size.x*multiplier),f.css("height",this.size.y*multiplier);e?f.html(""):f.html(""); dynamicClickableEntityDivs[b]={};dynamicClickableEntityDivs[b].width=this.size.x*multiplier;dynamicClickableEntityDivs[b].height=this.size.y*multiplier;dynamicClickableEntityDivs[b].entity_pos_x=this.pos.x;dynamicClickableEntityDivs[b].entity_pos_y=this.pos.y},draw:function(){ig.system.context.fillStyle="#ffffff";ig.system.context.fillRect(0,0,ig.system.width,ig.system.height);ig.system.context.fillStyle="#000";ig.system.context.font="12px Arial";ig.system.context.textAlign="left";320>=ig.system.width? ig.system.context.fillText("powered by MarketJS.com",ig.system.width-150,ig.system.height-15):ig.system.context.fillText("powered by MarketJS.com",ig.system.width-160,ig.system.height-15);this.parent();this.splash&&ig.system.context.drawImage(this.splash.data,0,0,this.splash.data.width,this.splash.data.height,this.pos.x,this.pos.y,this.size.x,this.size.y)}})});this.END_BRANDING_SPLASH;ig.baked=!0; ig.module("game.entities.buttons.button").requires("impact.entity").defines(function(){EntityButton=ig.Entity.extend({collides:ig.Entity.COLLIDES.NEVER,type:ig.Entity.TYPE.A,fillColor:null,layer:0,isClicked:!1,scale:{x:1,y:1},enabled:!0,isShown:!0,withText:!1,anchor:{x:0.5,y:0},buttonText:"",init:function(b,c,d){this.parent(b,c,d);this.setAnim();this.setAnchor(this.anchor.x,this.anchor.y);this.layer=ig.game.currentLayer;this.scaleX0=this.scale.x;this.scaleY0=this.scale.y;this.scaleX1=0.9*this.scaleX0; this.scaleY1=0.9*this.scaleY0;this.scaleX2=1.04*this.scaleX0;this.scaleY2=1.04*this.scaleY0},ready:function(){this.parent();this.clickTime=ig.system.clock.delta()},setAnim:function(){this.animSheet=new ig.AnimationSheet(this.animImage.path,this.animImage.width,this.animImage.height);this.addAnim("idle",1,[0],!0);this.size.x=this.animSheet.width*this.scale.x;this.size.y=this.animSheet.height*this.scale.y},clicked:function(){var b=this.clickTime;this.clickTime=ig.system.clock.delta();!(0.35>this.clickTime- b)&&this.enabled&&ig.game.currentLayer==this.layer&&(this.isClicked=!0,this.tween({scale:{x:this.scaleX1,y:this.scaleY1}},0.025).start(),ig.soundHandler.sfxPlayer.play("button"))},released:function(){this.isClicked&&this.enabled&&(ig.domHandler.getElementById("#canvas").css("cursor","default"),this.isClicked=!1,this.tween({scale:{x:this.scaleX0,y:this.scaleY0}},0.025,{onComplete:function(){this.callback()}.bind(this)}).start())},leave:function(){this.isClicked=!1;ig.domHandler.getElementById("#canvas").css("cursor", "default");this.tween({scale:{x:this.scaleX0,y:this.scaleY0}},0.025).start()},over:function(){ig.game.currentLayer==this.layer&&this.enabled&&(ig.domHandler.getElementById("#canvas").css("cursor","pointer"),this.tween({scale:{x:this.scaleX2,y:this.scaleY2}},0.025).start())},draw:function(){if(this.isShown){var b=ig.system.context;b.save();b.translate(ig.system.getDrawPos(this.pos.x.round()-ig.game.screen.x+this.size.x/2-this.offset.x),ig.system.getDrawPos(this.pos.y.round()-ig.game.screen.y+this.size.y/ 2-this.offset.y));b.scale(this.scale.x,this.scale.y);this.currentAnim&&this.currentAnim.draw(-this.size.x/2,-this.size.y/2);this.withText&&this.drawText();b.restore()}},callback:function(){},drawText:function(){ig.game.drawText(this.buttonText,0,10,28,"#FFF","center")},setShown:function(b){this.isShown=this.enabled=b}})});ig.baked=!0; ig.module("plugins.clickable-div-layer").requires("plugins.data.vector").defines(function(){ClickableDivLayer=ig.Class.extend({pos:new Vector2(0,0),size:new Vector2(0,0),identifier:null,invisImagePath:"media/graphics/misc/invisible.png",init:function(b){this.pos=new Vector2(b.pos.x,b.pos.y);this.size=new Vector2(b.size.x,b.size.y);var c="more-games",d="www.google.com",e=!1;b.div_layer_name&&(c=b.div_layer_name);b.link&&(d=b.link);b.newWindow&&(e=b.newWindow);this.createClickableLayer(c,d,e)},createClickableLayer:function(b, c,d){this.identifier=b;var e=ig.domHandler.getElementById("#"+b);e?(ig.domHandler.show(e),ig.domHandler.attr(e,"href",c)):this.createClickableOutboundLayer(b,c,this.invisImagePath,d)},update:function(b,c){this.pos.x===b&&this.pos.y===c||(ig.sizeHandler.dynamicClickableEntityDivs[this.identifier]={},ig.sizeHandler.dynamicClickableEntityDivs[this.identifier].width=this.size.x,ig.sizeHandler.dynamicClickableEntityDivs[this.identifier].height=this.size.y,ig.sizeHandler.dynamicClickableEntityDivs[this.identifier].entity_pos_x= this.pos.x,ig.sizeHandler.dynamicClickableEntityDivs[this.identifier].entity_pos_y=this.pos.y)},createClickableOutboundLayer:function(b,c,d,e){var f=ig.domHandler.create("div");ig.domHandler.attr(f,"id",b);var j=ig.domHandler.create("a");e?(ig.domHandler.attr(j,"href",c),ig.domHandler.attr(j,"target","_blank")):ig.domHandler.attr(j,"href",c);c=ig.domHandler.create("img");ig.domHandler.css(c,{width:"100%",height:"100%"});ig.domHandler.attr(c,"src",d);d=Math.min(ig.sizeHandler.scaleRatioMultiplier.x, ig.sizeHandler.scaleRatioMultiplier.y);if(ig.ua.mobile){e=ig.domHandler.getElementById("#canvas");e=ig.domHandler.getOffsets(e);var n=e.left,m=e.top;console.log(e.left);ig.sizeHandler.disableStretchToFitOnMobileFlag?(e=Math.floor(n+this.pos.x*ig.sizeHandler.scaleRatioMultiplier.x)+"px",m=Math.floor(m+this.pos.y*ig.sizeHandler.scaleRatioMultiplier.y)+"px",n=Math.floor(this.size.x*ig.sizeHandler.scaleRatioMultiplier.x)+"px",d=Math.floor(this.size.y*ig.sizeHandler.scaleRatioMultiplier.y)+"px"):(e=Math.floor(this.pos.x* ig.sizeHandler.sizeRatio.x)+"px",m=Math.floor(this.pos.y*ig.sizeHandler.sizeRatio.y)+"px",n=Math.floor(this.size.x*ig.sizeHandler.sizeRatio.x)+"px",d=Math.floor(this.size.y*ig.sizeHandler.sizeRatio.y)+"px")}else e=ig.domHandler.getElementById("#canvas"),e=ig.domHandler.getOffsets(e),n=e.left,m=e.top,ig.sizeHandler.enableStretchToFitOnDesktopFlag?(e=Math.floor(n+this.pos.x*ig.sizeHandler.sizeRatio.x)+"px",m=Math.floor(m+this.pos.y*ig.sizeHandler.sizeRatio.y)+"px",n=Math.floor(this.size.x*ig.sizeHandler.sizeRatio.x)+ "px",d=Math.floor(this.size.y*ig.sizeHandler.sizeRatio.y)+"px"):(e=Math.floor(n+this.pos.x*d)+"px",m=Math.floor(m+this.pos.y*d)+"px",n=Math.floor(this.size.x*d)+"px",d=Math.floor(this.size.y*d)+"px");ig.domHandler.css(f,{"float":"left",position:"absolute",left:e,top:m,width:n,height:d,"z-index":3});ig.domHandler.addEvent(f,"mousemove",ig.input.mousemove.bind(ig.input),!1);ig.domHandler.appendChild(j,c);ig.domHandler.appendChild(f,j);ig.domHandler.appendToBody(f);ig.sizeHandler.dynamicClickableEntityDivs[b]= {};ig.sizeHandler.dynamicClickableEntityDivs[b].width=this.size.x;ig.sizeHandler.dynamicClickableEntityDivs[b].height=this.size.y;ig.sizeHandler.dynamicClickableEntityDivs[b].entity_pos_x=this.pos.x;ig.sizeHandler.dynamicClickableEntityDivs[b].entity_pos_y=this.pos.y}})});ig.baked=!0; ig.module("game.entities.buttons.button-branding-logo").requires("game.entities.buttons.button","plugins.clickable-div-layer").defines(function(){EntityButtonBrandingLogo=EntityButton.extend({type:ig.Entity.TYPE.A,gravityFactor:0,logo:new ig.AnimationSheet("branding/logo.png",_SETTINGS.Branding.Logo.Width,_SETTINGS.Branding.Logo.Height),zIndex:10001,size:{x:64,y:66},clickableLayer:null,link:null,newWindow:!1,div_layer_name:"branding-logo",name:"brandinglogo",init:function(b,c,d){this.parent(b,c,d); if(!ig.global.wm){if("undefined"==typeof wm)if(_SETTINGS.Branding.Logo.Enabled)this.size.x=_SETTINGS.Branding.Logo.Width,this.size.y=_SETTINGS.Branding.Logo.Height,this.anims.idle=new ig.Animation(this.logo,0,[0],!0),this.currentAnim=this.anims.idle,d&&d.centralize&&(this.pos.x=ig.system.width/2-this.size.x/2,console.log("centralize true ... centering branded logo ...")),_SETTINGS.Branding.Logo.LinkEnabled&&(this.link=_SETTINGS.Branding.Logo.Link,this.newWindow=_SETTINGS.Branding.Logo.NewWindow,this.clickableLayer= new ClickableDivLayer(this));else{this.kill();return}this.div_layer_name=d.div_layer_name?d.div_layer_name:"branding-logo"}},show:function(){var b=ig.domHandler.getElementById("#"+this.div_layer_name);ig.domHandler.show(b)},hide:function(){var b=ig.domHandler.getElementById("#"+this.div_layer_name);ig.domHandler.hide(b)},clicked:function(){},clicking:function(){},released:function(){}})});ig.baked=!0; ig.module("game.entities.branding-logo-placeholder").requires("impact.entity","game.entities.buttons.button-branding-logo").defines(function(){EntityBrandingLogoPlaceholder=ig.Entity.extend({gravityFactor:0,size:{x:32,y:32},_wmDrawBox:!0,_wmBoxColor:"rgba(0, 0, 255, 0.7)",init:function(b,c,d){this.parent(b,c,d);if(d)switch(console.log("settings found ... using that div layer name"),b=d.div_layer_name,console.log("settings.centralize:",d.centralize),d.centralize){case "true":console.log("centralize true"); centralize=!0;break;case "false":console.log("centralize false");centralize=!1;break;default:console.log("default ... centralize false"),centralize=!1}else b="branding-logo",centralize=!1;if("undefined"==typeof wm){if(_SETTINGS.Branding.Logo.Enabled)try{ig.game.spawnEntity(EntityButtonBrandingLogo,this.pos.x,this.pos.y,{div_layer_name:b,centralize:centralize})}catch(e){console.log(e)}this.kill()}}})});ig.baked=!0; ig.module("game.entities.buttons.button-more-games").requires("game.entities.buttons.button","plugins.clickable-div-layer").defines(function(){EntityButtonMoreGames=EntityButton.extend({type:ig.Entity.TYPE.A,gravityFactor:0,animImage:new ig.Image("media/graphics/games/ui/moregames-btn.png"),size:{x:64,y:64},zIndex:750,alpha:0,clickableLayer:null,link:null,newWindow:!1,div_layer_name:"more-games",name:"moregames",init:function(b,c,d){this.parent(b,c,d);ig.global.wm||(this.currentAnim.alpha=0,this.fadeIn(), this.div_layer_name=d.div_layer_name?d.div_layer_name:"more-games",_SETTINGS.MoreGames.Enabled?(_SETTINGS.MoreGames.Link&&(this.link=_SETTINGS.MoreGames.Link),_SETTINGS.MoreGames.NewWindow&&(this.newWindow=_SETTINGS.MoreGames.NewWindow),this.clickableLayer=new ClickableDivLayer(this)):this.kill())},show:function(){var b=ig.domHandler.getElementById("#"+this.div_layer_name);ig.domHandler.show(b)},hide:function(){var b=ig.domHandler.getElementById("#"+this.div_layer_name);ig.domHandler.hide(b)},fadeIn:function(){this.tween({currentAnim:{alpha:1}}, 1).start()}})});1;2;3;4;5;6;7;8;9;10;11;12;13;14;15;16;17;18;19;20;21;22;23;24;25;26;27;28;29;30;31;32;33;34;35;36;37;38;39;40;41;42;43;44;45;46;47;48;49;50;51;52;53;54;55;56;57;58;59;60;61;62;63;64;65;66;67;68;69;70;71;72;73;74;75;76;77;78;79;80;81;82;83;84;85;86;87;88;89;90;91;92;93;94;95;96;97;98;99;100;101;102;103;104;105;106;107;108;109;110;111;112;113;114;115;116;117;118;119;120;121;122;123;124;125;126;127;128;129;130;131;132;133;134;135;136;137;138;139;140;141;142;143;144;145;146;147;148;149; 150;151;152;153;154;155;156;157;158;159;160;161;162;163;164;165;166;167;168;169;170;171;172;173;174;175;176;177;178;179;180;181;182;183;184;185;186;187;188;189;190;191;192;193;194;195;196;197;198;199;200;201;202;203;204;205;206;207;208;209;210;211;212;213;214;215;216;217;218;219;220;221;222;223;224;225;226;227;228;229;230;231;232;233;234;235;236;237;238;239;240;241;242;243;244;245;246;247;248;249;250;251;252;253;254;255;256;257;258;259;260;261;262;263;264;265;266;267;268;269;270;271;272;273;274;275; 276;277;278;279;280;281;282;283;284;285;286;287;288;289;290;291;292;293;294;295;296;297;298;299;300;301;302;303;304;305;306;307;308;309;310;311;312;313;314;315;316;317;318;319;320;321;322;323;324;325;326;327;328;329;330;331;332;333;334;335;336;337;338;339;340;341;342;343;344;345;346;347;348;349;350;351;352;353;354;355;356;357;358;359;360;361;362;363;364;365;366;367;368;369;370;371;372;373;374;375;376;377;378;379;380;381;382;383;384;385;386;387;388;389;390;391;392;393;394;395;396;397;398;399;400;401; 402;403;404;405;406;407;408;409;410;411;412;413;414;415;416;417;418;419;420;421;422;423;424;425;426;427;428;429;430;431;432;433;434;435;436;437;438;439;440;441;442;443;444;445;446;447;448;449;450;451;452;453;454;455;456;457;458;459;460;461;462;463;464;465;466;467;468;469;470;471;472;473;474;475;476;477;478;479;480;481;482;483;484;485;486;487;488;489;490;491;492;493;494;495;496;497;var Box2D={SCALE:0.1}; (function(b,c){function d(){}var e=function(){var b,c,d,e,g=Function.call,t=Object.prototype,z=g.bind(t.hasOwnProperty),y=g.bind(t.propertyIsEnumerable),A=g.bind(t.toString),B=z(t,"__defineGetter__");B&&(b=g.bind(t.__defineGetter__),c=g.bind(t.__defineSetter__),d=g.bind(t.__lookupGetter__),e=g.bind(t.__lookupSetter__));var I=function(b){return null==b||"object"!=typeof b&&"function"!=typeof b};Object.getPrototypeOf||(Object.getPrototypeOf=function(b){var c=b.__proto__;return c||null===c?c:"[object Function]"=== A(b.constructor)?b.constructor.prototype:b instanceof Object?t:null});g=function(b){try{return b.sentinel=0,0===Object.getOwnPropertyDescriptor(b,"sentinel").value}catch(c){return!1}};if(Object.defineProperty){var D=g({});if(!("undefined"==typeof document||g(document.createElement("div")))||!D)var x=Object.getOwnPropertyDescriptor}if(!Object.getOwnPropertyDescriptor||x)Object.getOwnPropertyDescriptor=function(b,c){if(I(b))throw new TypeError("Object.getOwnPropertyDescriptor called on a non-object: "+ b);if(x)try{return x.call(Object,b,c)}catch(f){}var g;if(!z(b,c))return g;if(g={enumerable:y(b,c),configurable:!0},B){var j=b.__proto__,E=b!==t;E&&(b.__proto__=t);var s=d(b,c),u=e(b,c);if(E&&(b.__proto__=j),s||u)return s&&(g.get=s),u&&(g.set=u),g}return g.value=b[c],g.writable=!0,g};if(Object.getOwnPropertyNames||(Object.getOwnPropertyNames=function(b){return Object.keys(b)}),!Object.create){var G;G="undefined"==typeof document?function(){return{__proto__:null}}:function(){var b,c,d,e,f,g=function(){if(!document.domain)return!1; try{return!!new ActiveXObject("htmlfile")}catch(b){return!1}}()?((f=new ActiveXObject("htmlfile")).write("