Frame 1
var amountToLoad = 592822;
Object.Postopia = _level0.Object.Postopia;
_global.VR_LIVES = _level0.VR_LIVES;
_global.VR_SHIELD = _level0.VR_SHIELD;
_global.VR_JETPACK = _level0.VR_JETPACK;
_global.VR_MULTIPLIER = _level0.VR_MULTIPLIER;
_global.VR_BONUS = _level0.VR_BONUS;
vrv = newline;
vrv = vrv + (((((((((VR_LIVES + newline) + VR_SHIELD) + newline) + VR_JETPACK) + newline) + VR_MULTIPLIER) + newline) + VR_BONUS) + newline);
Frame 3
Frame 5
splashTime = getTimer();
play();
Frame 6
play();
Frame 7
if ((_framesloaded > 16) && (getTimer() > (splashTime + 3000))) {
play();
} else {
prevFrame();
}
Frame 14
if (getBytesLoaded() >= ammountToLoad) {
}
Frame 15
startValue = getBytesLoaded();
Frame 16
play();
Frame 17
if (getBytesLoaded() >= amountToLoad) {
loadScreen.loadBar.value._xscale = 100;
gotoAndStop ("performance");
} else {
if (_framesloaded > 55) {
}
var r = ((getBytesLoaded() - startValue) / (amountToLoad - startValue));
loadScreen.loadBar.value._xscale = r * 100;
prevFrame();
}
Frame 25
performance = new PerformanceTest(null, function () {
GameQuality = performance.score;
gotoAndStop ("Start");
});
Frame 30
xLevel1 = "<w startY=\"-275\" startX=\"500\" createBackground=\"HCBG_Canyon_Level1\" preProcess=\"preSetLevel\" name=\"Canyon1\"><objects types=\"SSShape,AirVent,FlagPole,GameHoverCraft,Teleport,SSShapeInstance,GameSpring,LevelEnd,GamePoint,Bird,GamePointMultiplier,GameShield,GameFuel,ElectricCloud,BonusTeleport\">0 150 -250 0 x600 DSGeneric 0 0 0 600 0 65537 600 100 0 0 100 0|1 90 -60 0 1 0 |1 1000 -30 0 1 0 |1 1850 -30 0 1 0 |1 2300 -300 0 1 0 |1 2150 -600 0 1 0 |0 1100 -250 0 s2 DSGeneric 0 0 0 250 0 65537 400 -100 65537 650 -100 65537 650 100 0 0 100 0|0 1900 -350 0 s3 DSGeneric 0 0 0 300 0 65537 300 100 0 0 100 0|0 1000 -1000 0 s4 DSGeneric 0 0 0 250 0 65537 400 100 65537 1100 100 65537 1100 200 0 0 200 0|0 400 -900 0 x400 DSGeneric 0 0 0 400 0 65537 400 100 0 0 100 0|0 1800 -1150 0 x300 DSGeneric 0 0 0 300 0 65537 300 100 0 0 100 0|2 650 -900 0 GameFlag|3 1950 -1250 0 GameFlag|1 1600 -900 0 1 0 |1 1150 -1000 0 1 0 |1 1300 -1350 0 1 0 |1 1150 -1600 0 1 0 |1 1000 -1900 0 1 0 |1 1150 -2200 0 1 0 |1 1000 -2500 0 1 45 |0 1250 -2500 0 s5 DSGeneric 0 0 65537 1100 0 65537 1100 700 65537 1300 800 65537 1000 1100 65537 150 1100 65537 150 700 65537 0 600 65537|0 2400 -1150 0 s6 DSGeneric 0 1450 0 0 0 65537 600 -500 65537 500 1450 0|0 2650 -2500 0 s7 DSGeneric 350 850 0 0 500 65537 0 0 65537 600 0 65537 600 850 0|0 1500 -3300 0 x500 DSGeneric 0 0 0 500 0 65537 500 100 0 0 100 0|1 1900 -2500 0 1 0 |1 2450 -2790 0 1 -38 |1 2700 -2980 0 1 -38 |1 2940 -3170 0 1 -38 |1 2150 -2950 0 1 0 |4 1620 -3300 0 3100 -4250 0|4 2790 -4100 0 1750 -3500 0|0 3000 -3500 0 yl_1000 DSGeneric 0 1000 0 0 0 65537 200 0 0 200 1000 0|0 2700 -4100 0 s9 DSGeneric 300 600 0 0 300 65537 0 0 65537 700 0 65537 700 600 0|1 2960 -4100 0 1 0 |0 1500 -4550 0 s10 DSGeneric 0 0 65537 600 0 65537 1200 450 65537 0 450 0|5 2500 -4450 0 x400|1 2700 -4450 0 1 0 |2 2350 -4780 0 GameFlag|0 1300 -8100 0 s11 DSGeneric 0 0 0 0 4000 65537 -200 4000 0 -200 0 0|1 1400 -4500 0 1 0 |1 1700 -5100 0 1 0 |1 1550 -5400 0 1 45 |5 1800 -5500 0 x300|1 2150 -5500 0 1 0 |5 1450 -5800 0 x600|6 1750 -5800 0 0 1500|5 1850 -6500 0 x600|1 2600 -6500 0 1 0 |5 2150 -6800 0 x300|5 2650 -6850 0 x600|1 3350 -6850 0 1 0 |0 3100 -8050 0 s13 DSGeneric 0 100 65537 150 0 65537 350 0 65537 550 100 65537 550 550 65537 350 750 65537 150 750 65537 0 600 65537|5 3500 -6650 0 x500|1 3440 -6450 0 1 0 |1 3150 -7150 0 1 -22.5 |1 2900 -7400 0 1 0 |1 3000 -7750 0 1 0 |1 2850 -8100 0 1 0 |1 3550 -7150 0 1 22.5 |1 3830 -7400 0 1 0 |1 3720 -7740 0 1 0 |1 3260 -8560 0 1 -25 |0 2960 -8400 0 s14 DSGeneric 0 0 0 400 -200 65537 1850 -200 65537 1850 0 0|1 3650 -8600 0 1 0 |1 4300 -8600 0 1 0 |5 3350 -8900 0 x600|5 4200 -8900 0 x600|1 3500 -8900 0 1 0 |1 4450 -8900 0 1 0 |5 3050 -9200 0 x400|5 4100 -9200 0 x300|1 3200 -9200 0 1 0 |1 4200 -9200 0 1 0 |0 3300 -9550 0 x800 DSGeneric 0 0 0 800 0 65537 800 100 0 0 100 0|1 3650 -9550 0 1 0 |1 3500 -9900 0 1 45 |1 3850 -10000 0 1 0 |1 4050 -10350 0 1 0 |1 3200 -10150 0 1 0 |0 3250 -10450 0 s15 DSGeneric 0 0 0 100 -100 65537 600 -100 65537 700 0 65537|0 3550 -12550 0 s16 DSGeneric 0 0 65537 150 0 0 150 2000 65537 0 2000 0|0 2950 -12000 0 s17 DSGeneric 0 0 0 0 3000 65537 -150 3000 0 -150 0 0|6 3450 -10550 0 0 1500|7 3800 -10550 0|5 2950 -11200 0 x600|4 3100 -11200 0 4150 -10700 0|2 3300 -11200 0 GameFlag|8 420 -350 0|8 500 -350 0|8 580 -350 0|8 1250 -350 0|8 1350 -350 0|8 1460 -420 0|8 1650 -440 0|8 2240 -720 0|8 1950 -950 0|8 1890 -950 0|8 1840 -950 0|8 1380 -2540 0|8 1480 -2540 0|8 1580 -2540 0|8 1660 -2540 0|8 2830 -3480 0|8 2880 -3470 0|8 2930 -3460 0|8 2770 -3490 0|8 2700 -3490 0|8 2630 -3480 0|8 2570 -3460 0|8 2510 -3440 0|8 1470 -3380 0|8 1410 -3380 0|8 1350 -3380 0|8 1570 -4640 0|8 1460 -4940 0|8 1630 -5250 0|8 2930 -4470 0|8 2810 -4490 0|8 2550 -4830 0|8 2450 -4830 0|8 2270 -4830 0|8 2180 -4830 0|8 1860 -5650 0|8 2050 -5650 0|8 1910 -5850 0|8 2000 -6550 0|8 2140 -6550 0|8 2300 -6550 0|8 2440 -6550 0|9 2000 -3380 0|10 2950 -2550 0|10 1280 -3380 0|11 2500 -3240 0|2 1910 -3300 0|0 930 -2570 0 s173 DSGeneric 0 0 0 140 140 65537 -40 320 65537 -40 1020 65537 -330 1310 65537 -330 0 0|0 5040 -8140 0 s177 DSGeneric 0 0 0 380 -220 65537 380 -1000 65537 520 -1000 0 520 210 0 0 210 0|0 3900 -7500 0 s179 DSGeneric 0 0 0 0 -450 65537 180 -550 65537 610 -550 65537 860 -640 65537 1140 -640 65537 1140 0 0|0 4400 -6690 0 s180 DSGeneric 0 0 0 -500 -810 65537 210 -810 0 210 0 0|1 1550 -4850 0 1 0 |0 3400 -4100 0 s188 DSGeneric 0 0 0 -770 -1670 65537 150 -1670 0 150 0 0|0 2630 -5770 0 s189 DSGeneric 0 0 0 670 -670 65537 1500 -670 65537 1770 -920 65537 1770 0 0|1 4210 -6520 0 1 -45 |8 4330 -6700 0|8 4120 -6690 0|8 4270 -6710 0|8 4200 -6700 0|0 4810 -8600 0 s156 DSGeneric 180 -180 65537 320 -900 65537 430 -770 0 200 60 0 0 0 0|8 5340 -9090 0|8 5260 -8950 0|8 5340 -8830 0|8 5260 -8730 0|8 5350 -8630 0|8 5270 -8550 0|8 5350 -8470 0|8 5280 -8400 0|8 5190 -8470 0|8 5180 -8640 0|8 5190 -8840 0|1 4960 -8140 0 1 0 |1 5150 -8390 0 2 0 |10 5260 -9190 0|8 5180 -9090 0|8 4830 -8210 0|8 4600 -8170 0|8 4420 -8150 0|8 4210 -8130 0|8 3630 -8100 0|8 3510 -8150 0|8 3350 -8170 0|8 3180 -8150 0|8 3060 -8090 0|8 5100 -8950 0|8 5100 -8740 0|8 5090 -8550 0|8 3570 -10210 0|8 3930 -10380 0|8 2060 -5860 0|8 2850 -6910 0|8 2960 -6910 0|8 3070 -6910 0|8 3180 -6910 0|8 4180 -6640 0|8 4250 -6650 0|8 4230 -6770 0|8 4130 -6750 0|0 930 -2570 0 s195 DSGeneric -230 -190 0 -230 -1180 0 0 -1180 0 0 0 65537|0 930 -3750 0 s196 DSGeneric 0 -350 0 370 -350 0 0 0 65537|0 1300 -8100 0 s197 DSGeneric 0 -900 0 1650 -900 0 0 0 65537|0 2100 -2500 0 s198 DSGeneric 900 -710 65537 900 0 0 0 0 0|2 2210 -6800 0|8 2870 -2550 0|8 2960 -2630 0|8 2960 -2730 0|8 2960 -2820 0|8 2900 -2770 0|8 2900 -2680 0|8 2860 -2630 0|8 2840 -2720 0|8 2790 -2660 0|8 2810 -2580 0|8 2760 -2540 0|8 2750 -2600 0|8 2690 -2560 0|12 2750 -2760 0|0 4670 -10500 0 s211 DSGeneric 0 100 0 -520 100 0 -520 0 0 0 0 65537|9 1990 -5880 0|9 3650 -10000 0|2 4590 -10500 0|13 2290 -1180 0 -70 0|8 1050 -1250 0|8 980 -1340 0|8 1030 -1420 0|8 920 -1260 0|8 850 -1190 0|8 790 -1120 0|13 1550 -2830 0 0 0|8 1900 -2740 0|8 1900 -2830 0|8 1900 -2930 0|13 2320 -5560 0 -50 0|13 1520 -5920 0 50 0|8 1750 -6250 0|8 1750 -6370 0|8 1750 -6500 0|8 1750 -5960 0|8 1750 -6100 0|9 2730 -6990 0|8 3760 -8710 0|8 3990 -8710 0|8 4210 -8720 0|8 3800 -9770 0|8 3920 -9770 0|8 4040 -9770 0|8 3360 -10970 0|8 3260 -10910 0|8 3160 -10830 0|8 3070 -10750 0|8 3130 -10650 0|8 3200 -10540 0|0 2150 -4780 0 s252 DSGeneric 500 0 65537 500 40 0 0 40 0 0 0 0|0 4750 -10070 0 s250 DSGeneric -80 0 0 -80 -590 65537 -510 -1040 65537 -510 -1670 65537 0 -1670 0 0 0 0|0 4670 -10070 0 s246 DSGeneric 80 0 0 890 930 0 750 930 0 0 0 65537|14 3760 -6650 0 BonusRoom|9 1370 -1030 0|9 1930 -4620 0|13 4370 -10630 0 -75 0|3 4710 -8390 0|</objects></w>";
xLevel2 = "<w startY=\"-10705\" startX=\"4970\" createBackground=\"HCBG_City_Level\" preProcess=\"preSetLevel\" name=\"City1\"><objects types=\"SSShape,AirVent,FlagPole,Teleport,GameSpring,GamePointMultiplier,ElectricBlimp,GameHoverCraft,GamePoint,GameFuel,Bird,GameShield,ElectricCloud,LevelEnd,BonusTeleport\">0 4600 -10540 0 s0 DSGeneric 150 -140 65537 430 -140 65537 570 0 65537 0 0 0|0 5190 -10830 0 s1 DSGeneric 560 0 65537 560 170 0 170 170 0 0 0 0|0 5080 -10890 0 s3 DSGeneric -480 0 0 -480 -120 0 0 -120 65537 0 0 0|0 4250 -10350 0 s6 DSGeneric 530 0 65537 530 500 65537 0 500 65537 0 0 65537|0 5000 -10360 0 s7 DSGeneric 600 0 65537 600 520 0 0 520 65537 0 0 65537|1 5220 -10370 0 1 0 |1 4520 -10360 0 2 0 |1 5420 -10830 0 1 0 |0 4250 -10350 0 s12 DSGeneric -80 0 0 -80 -830 65537 0 -830 0 0 0 65537|0 3810 -9410 0 s14 DSGeneric 200 370 65537 350 370 65537 350 1050 65537 0 1050 0 0 0 0|0 4150 -9320 0 s16 DSGeneric 0 -50 0 1490 -50 65537 1490 0 0 0 0 0|1 4080 -9040 0 1 0 |1 4890 -9380 0 3 0 |0 4160 -8780 0 s22 DSGeneric 0 -50 0 520 -50 65537 520 0 0 0 0 0|0 4900 -8840 0 s23 DSGeneric 760 0 65537 760 50 0 0 50 0 0 0 0|0 4160 -8520 0 s24 DSGeneric 1950 0 65537 1950 150 0 0 150 0 0 0 0|0 5600 -10360 0 s27 DSGeneric 510 -180 65537 510 0 0 0 0 0|0 6110 -10540 0 s28 DSGeneric 0 -900 65537 140 -900 65537 140 0 65537 0 0 0|0 5220 -11220 0 s29 DSGeneric 0 -150 0 520 -150 65537 520 0 0 0 0 0|0 4250 -11180 0 s30 DSGeneric 0 -290 0 800 -290 65537 800 -230 65537 0 0 65537|0 5220 -11740 0 s31 DSGeneric 500 0 65537 500 80 0 0 80 0 0 0 0|0 6620 -11690 0 s35 DSGeneric 690 0 0 690 390 0 470 390 65537 0 0 65537|0 6250 -11380 0 s37 DSGeneric 400 90 65537 400 120 0 0 120 0 0 0 0|0 6480 -10960 0 s38 DSGeneric 0 -30 0 650 -30 65537 650 0 0 0 0 0|0 7310 -11300 0 s39 DSGeneric 240 0 0 240 690 0 0 690 0 0 0 65537|0 6250 -10730 0 s40 DSGeneric 0 -40 0 1070 -40 65537 1070 0 0 0 0 0|1 6430 -11350 0 1 0 |1 6860 -11000 0 1 0 |1 7210 -11290 0 1 180 |1 7310 -10820 0 2 -89 |1 6360 -10770 0 1 0 |2 6660 -10770 0|1 5000 -11020 0 1 0 |1 6010 -10510 0 3 -20 |1 5370 -11380 0 1 0 |3 5000 -11470 0 3820 -10050 0|0 3810 -9850 0 s45 DSGeneric 0 30 0 -430 30 0 -430 -370 0 -370 -370 0 0 0 65537|0 3440 -10220 0 s46 DSGeneric -60 0 0 -60 -1070 0 0 -1070 0 0 0 65537|0 4250 -11470 0 s47 DSGeneric 0 290 0 -290 290 65537 0 0 65537|0 4170 -10990 0 s48 DSGeneric 0 50 0 -500 50 0 -500 0 0 0 0 65537|0 3650 -11880 0 s50 DSGeneric -210 590 65537 -210 0 0 0 0 0|0 3790 -11680 0 s51 DSGeneric 140 -40 65537 540 -40 65537 670 0 65537 0 0 0|0 4080 -12480 0 s53 DSGeneric 460 0 0 460 200 0 200 200 65537 0 0 65537|4 4060 -11720 0 0 1500|4 4010 -12430 0 135 1500|1 4550 -11470 0 1 0 |0 3650 -11880 0 s55 DSGeneric 0 -600 0 430 -600 0 190 -410 65537 190 -190 65537 0 0 65537|0 4180 -10350 0 s58 DSGeneric 80 0 0 80 340 0 -120 340 0 -230 230 0 0 0 65537|2 5800 -12090 0|3 5970 -12100 0 4890 -10750 0|1 3640 -10030 0 1 45 |1 4120 -10300 0 1 -45 |0 3860 -10410 0 s70 DSGeneric 0 60 0 -420 60 0 -420 0 0 0 0 65537|4 3580 -10410 0 0 1500|5 4940 -12190 0|1 3850 -10990 0 1 0 |1 4110 -11340 0 1 -45 |0 6050 -12280 0 s79 DSGeneric 290 0 0 570 590 0 0 250 65537 0 0 65537|0 4540 -12280 0 s84 DSGeneric 0 -30 0 1510 -30 0 1510 0 0 0 0 65537|1 5520 -8530 0 1 0 |1 5000 -8530 0 1 0 |6 5660 -8890 0 -75 0|6 7390 -11080 0 -100 0|0 4560 -9060 0 s75 DSGeneric 0 -50 0 570 -50 65537 570 0 0 0 0 0|1 5200 -9110 0 1 0 |1 5600 -9370 0 1 0 |0 6110 -9490 0 s78 DSGeneric -410 0 0 -410 -160 0 0 -80 65537 0 0 0|7 5980 -9710 0|8 5930 -9680 0|8 5980 -9640 0|8 6030 -9680 0|8 6030 -9730 0|8 5980 -9760 0|8 5930 -9730 0|0 5600 -9840 0 s88 DSGeneric 0 -220 0 610 -220 0 610 -180 0 0 0 65537|0 6210 -10020 0 s89 DSGeneric 0 -40 0 1100 -40 0 1100 0 0 0 0 65537|0 6110 -9820 0 s90 DSGeneric 70 0 65537 70 1300 65537 0 1300 0 0 0 65537|0 7310 -10020 0 s92 DSGeneric 130 0 0 130 860 0 0 860 0 0 0 65537|0 7310 -9840 0 s93 DSGeneric 0 150 0 -570 150 65537 0 0 65537|0 7310 -9310 0 s94 DSGeneric 0 150 0 -550 150 0 0 0 65537|0 6740 -9500 0 s99 DSGeneric -10 40 0 -560 -20 0 -560 -120 0 0 0 65537|0 6180 -9160 0 s100 DSGeneric 580 0 65537 580 90 0 0 90 0 0 0 0|3 6600 -9160 0 5980 -8630 0|2 6300 -9160 0|8 7240 -9890 0|8 7180 -9890 0|8 7180 -9940 0|8 7240 -9940 0|8 6250 -9660 0|8 6300 -9650 0|9 7240 -9360 0|2 4350 -10350 0|5 6330 -11190 0|5 6150 -9920 0|2 5380 -9370 0|2 4840 -11870 0|6 6740 -11440 0 -100 -20|6 3530 -12190 0 100 0|0 4900 -11870 0 s117 DSGeneric 0 400 65537 -130 400 0 -130 0 65537 0 0 65537|1 4690 -11570 0 1 0 |0 3810 -9860 0 s119 DSGeneric 450 0 65537 0 450 65537 0 0 0|10 3950 -11320 0|8 4410 -9600 0|11 3920 -10380 0|8 3630 -11070 0|12 3560 -11870 0 15 0|8 5900 -10820 0|8 5730 -11280 0|8 5980 -10600 0|8 5810 -11070 0|6 3900 -9580 0 50 0|8 5100 -8690 0|8 5260 -8650 0|8 5440 -8670 0|8 4330 -8900 0|8 4450 -8900 0|8 4560 -8890 0|4 4240 -8830 0 0 1500|8 4200 -9580 0|8 4320 -9570 0|8 4240 -9560 0|6 4050 -10610 0 -20 30|11 4270 -8610 0|1 3870 -9350 0 1 58 |8 4110 -9910 0|8 4140 -9950 0|8 4170 -9910 0|8 3600 -10290 0|8 3520 -10290 0|8 3560 -10250 0|4 4580 -8520 0 0 1500|8 5990 -8680 0|8 6020 -8600 0|8 5940 -8610 0|8 4670 -8640 0|8 5180 -9750 0|8 5180 -9680 0|8 5240 -9720 0|8 4090 -9320 0|8 4080 -9230 0|8 4090 -9130 0|8 3770 -10830 0|8 3830 -10830 0|8 3890 -10830 0|8 3710 -11130 0|8 3780 -11070 0|12 6190 -8660 0 -100 10|3 5440 -10370 0 5980 -8630 0|12 4030 -10830 0 0 0|10 3560 -10250 0|12 5920 -12380 0 25 -25|8 4420 -9490 0|8 4410 -9720 0|4 4420 -9370 0 0 700|12 3790 -9160 0 50 0|8 6510 -11220 0|8 6550 -11160 0|8 6590 -11220 0|8 6640 -11160 0|8 7250 -11050 0|8 7210 -11100 0|8 7270 -11110 0|8 6630 -11530 0|8 6680 -11520 0|8 6650 -11480 0|8 5650 -11490 0|8 4680 -11930 0|8 4740 -11980 0|8 4610 -11870 0|8 7080 -9600 0|8 7020 -9600 0|8 7050 -9560 0|4 7050 -9690 0 180 1500|4 7060 -9240 0 -15 1500|10 5760 -12160 0|11 7020 -11140 0|8 6300 -11430 0|8 6360 -11410 0|8 6340 -11480 0|13 4720 -11010 0|10 4100 -9370 0|8 4910 -11080 0|8 4820 -11080 0|8 4860 -8650 0|8 4770 -8650 0|8 4620 -12190 0|8 4690 -12180 0|8 5250 -12180 0|8 5350 -12180 0|8 5450 -12180 0|12 7590 -9900 0 -100 0|8 5410 -11780 0|8 5300 -11780 0|8 5610 -11780 0|8 5540 -11780 0|8 3870 -11430 0|8 4070 -11520 0|8 5480 -11430 0|8 5450 -11470 0|8 5510 -11470 0|8 6300 -11090 0|8 6310 -11040 0|8 6350 -11070 0|0 6050 -12090 0 s227 DSGeneric 0 20 0 -600 20 0 -600 0 0 0 0 65537|0 5230 -12090 0 s228 DSGeneric 0 20 0 -960 20 0 -980 0 0 0 0 65537|8 4560 -12240 0|8 4790 -12180 0|8 4490 -12190 0|1 7310 -10930 0 2 -90 |14 4860 -9110 0 BonusRoom|6 5500 -9440 0 -100 0|6 5370 -11890 0 -75 -75|6 4590 -9450 0 -60 0|6 4680 -9640 0 -40 -20|6 4760 -9730 0 -40 0|10 5260 -8610 0|10 4790 -8910 0|10 5200 -9440 0|8 4060 -11840 0|8 4060 -11970 0|8 4060 -12170 0|8 4170 -12270 0|8 4280 -12160 0|8 4400 -12130 0|10 5110 -10750 0|10 5780 -10500 0|6 4360 -10780 0 0 50|6 5510 -12090 0 -100 0|6 5570 -12270 0 -100 0|8 7250 -9430 0|8 7170 -9370 0|8 7150 -9300 0|8 6370 -9620 0|8 6460 -9600 0|7 3930 -11810 0|</objects></w>";
xLevel3 = "<w startY=\"-10575\" startX=\"9200\" createBackground=\"HCBG_Mountain_Level1\" preProcess=\"preSetLevel\" name=\"Mountain1\"><objects types=\"SSShape,LevelEnd,AirVent,Teleport,GameSpring,FlagPole,Meteor,GameHoverCraft,GameFuel,GamePoint,GamePointMultiplier,ElectricCloud,GameShield,Bird,ElectricBlimp,BonusTeleport\">0 8610 -10470 0 s0 DSGeneric 0 -80 0 660 -80 65537 660 0 0 0 0 0|1 8700 -10550 0|0 8620 -10150 0 s3 DSGeneric -650 0 0 -650 -410 0 -410 -410 65537 0 0 65537|0 9980 -10560 0 s4 DSGeneric 0 410 0 -700 410 0 -290 0 65537 0 0 65537|0 8620 -10090 0 s5 DSGeneric 0 -60 0 660 -60 65537 660 0 0 0 0 0|2 8940 -10160 0 2 0 |0 8480 -10840 0 s7 DSGeneric 0 -60 0 300 -60 65537 300 0 0 0 0 0|0 9060 -10830 0 s8 DSGeneric 0 -70 0 250 -70 65537 250 0 0 0 0 0|3 8120 -10560 0 5090 -10480 0|3 9860 -10570 0 11800 -10750 0|4 8640 -10900 0 0 3000|4 9160 -10900 0 0 1500|0 9360 -11530 0 s16 DSGeneric 620 0 65537 620 70 0 0 70 0 0 0 0|5 8310 -12200 0|0 9980 -10560 0 s25 DSGeneric 0 -2460 65537 80 -2460 0 80 0 0 0 0 0|0 7970 -10550 0 s26 DSGeneric -90 0 0 -90 -2470 0 0 -2470 0 0 0 65537|0 8460 -12200 0 s27 DSGeneric 0 50 0 -490 50 0 -490 0 0 0 0 65537|0 7540 -10560 0 s30 DSGeneric -50 10 0 -50 -990 65537 0 -990 0 0 0 0|0 7490 -10550 0 s31 DSGeneric 0 40 0 -530 40 0 -530 0 0 0 0 65537|6 9110 -10320 0|6 8440 -10680 0|0 5600 -11240 0 s35 DSGeneric 0 -50 0 450 -50 65537 450 0 0 0 0 0|0 7490 -11550 0 s36 DSGeneric -600 -270 65537 -1920 -270 65537 -2520 0 65537 -2520 -340 0 0 -340 0 0 0 0|0 5440 -11450 0 s37 DSGeneric 370 -200 65537 730 -50 65537 1050 -210 65537 1520 0 65537 0 0 0|0 4970 -11550 0 s38 DSGeneric 0 1160 65537 -50 1160 0 -50 0 0 0 0 0|0 4970 -10390 0 s39 DSGeneric 1630 0 65537 1630 70 0 0 70 0 0 0 0|0 6600 -10390 0 s40 DSGeneric 360 -160 65537 360 0 0 0 0 0|2 7380 -10550 0 2 0 |2 7090 -10930 0 1 0 |2 6520 -11440 0 1 180 |2 6770 -11050 0 1 0 |2 6820 -10490 0 1 -20 |0 5290 -10600 0 s47 DSGeneric 390 0 65537 390 30 0 0 30 0 0 0 0|3 5500 -10400 0 8380 -10660 0|2 5230 -10400 0 1 0 |2 5960 -10390 0 1 0 |2 6380 -10390 0 1 0 |2 6160 -10880 0 1 180 |0 6370 -10960 0 s55 DSGeneric 0 30 0 -1100 30 0 -1100 0 0 0 0 65537|2 5550 -10960 0 1 0 |7 5490 -10720 0|8 5340 -11570 0|8 7110 -11550 0|9 5470 -11630 0|9 6170 -11620 0|9 6030 -11690 0|9 6310 -11690 0|9 6780 -11650 0|9 6960 -11590 0|9 5670 -11720 0|10 6160 -11700 0|9 5870 -11740 0|11 8390 -9000 0 -50 0|11 8680 -9110 0 -50 0|11 9030 -8870 0 -50 0|11 9360 -9070 0 -50 0|11 9600 -8930 0 -50 0|5 9770 -8760 0|2 8560 -8770 0 1 0 |2 9190 -9130 0 1 180 |2 8900 -8770 0 1 0 |2 9530 -8770 0 1 0 |2 8220 -8770 0 1 0 |6 9340 -8840 0|6 9850 -8890 0|6 8380 -8870 0|3 9960 -8770 0 9250 -10680 0|6 6530 -11140 0|6 5730 -11370 0|6 6270 -10560 0|6 6530 -10700 0|5 5950 -11290 0|11 6250 -11190 0 150 0|11 5290 -11120 0 150 0|0 11670 -10650 0 s100 DSGeneric 300 0 65537 300 530 0 -140 530 65537 -140 310 65537 0 170 65537 0 0 65537|0 11970 -10650 0 s101 DSGeneric 0 -510 65537 60 -510 65537 60 0 65537 0 0 0|0 11620 -11110 0 s102 DSGeneric -780 0 0 -780 -50 0 0 -50 65537 0 0 0|0 11530 -10340 0 s104 DSGeneric 0 40 0 -460 40 0 -460 0 0 0 0 65537|0 10840 -10130 0 s106 DSGeneric 470 0 65537 470 40 0 0 40 0 0 0 0|0 12030 -10650 0 s112 DSGeneric 390 0 65537 710 320 65537 500 530 65537 -60 530 65537 0 0 0|0 12530 -9440 0 s114 DSGeneric 1140 -1120 65537 1220 -1040 0 90 90 0 0 0 0|2 10840 -10210 0 1 90 |2 11600 -10420 0 1 -45 |2 11690 -9610 0 1 0 |2 12440 -9540 0 3 45 |2 12920 -9830 0 1 -45 |2 12680 -10270 0 1 135 |2 12470 -10610 0 1 50 |2 12340 -11420 0 2 135 |5 11990 -11160 0|2 12250 -10660 0 1 0 |2 11790 -11020 0 1 0 |4 13560 -10450 0 -45 2500|9 12980 -10760 0|9 12920 -10740 0|9 12870 -10700 0|9 12830 -10650 0|9 12820 -10590 0|9 12820 -10530 0|9 12850 -10470 0|9 12900 -10430 0|9 12960 -10410 0|9 13030 -10410 0|9 13090 -10430 0|9 13140 -10480 0|9 13160 -10530 0|9 13170 -10590 0|9 13160 -10650 0|9 13130 -10710 0|9 13080 -10740 0|9 13030 -10760 0|10 13000 -10590 0|11 13530 -10570 0 -50 0|11 12240 -9830 0 -50 0|11 11620 -9670 0 -50 0|11 11840 -10050 0 -50 0|11 11060 -10590 0 -50 0|3 11520 -11170 0 9250 -10680 0|3 11020 -9610 0 9250 -10650 0|9 9040 -10580 0|12 8680 -10220 0|3 9830 -11540 0 9700 -15000 0|0 7970 -13030 0 s160 DSGeneric -90 0 0 760 -2210 0 850 -2210 0 0 0 65537|0 9980 -13020 0 s162 DSGeneric 0 -2250 65537 80 -2250 0 80 0 0 0 0 0|0 9110 -14740 0 s164 DSGeneric 870 0 65537 870 70 0 0 70 0 0 0 0|2 8840 -14220 0 1 0 |2 9980 -14820 0 3 -90 |2 9980 -14490 0 2 -90 |2 9060 -13900 0 1 0 |2 9410 -13760 0 1 0 |2 8720 -13420 0 1 0 |2 9250 -13150 0 1 0 |2 9710 -12770 0 2 0 |2 8910 -12430 0 1 0 |2 9430 -12220 0 1 0 |0 9980 -14290 0 s176 DSGeneric 0 60 0 -390 60 0 -390 0 0 0 0 65537|5 9860 -14290 0|2 9980 -14350 0 2 -90 |9 9880 -14620 0|9 9230 -14090 0|9 9490 -13470 0|9 9610 -13470 0|9 9560 -13370 0|9 9430 -13370 0|9 9370 -13470 0|9 8860 -13500 0|9 8940 -13500 0|9 9030 -13500 0|9 9160 -13490 0|9 9110 -12700 0|9 9020 -12730 0|9 9330 -12660 0|9 9210 -12660 0|9 8640 -11160 0|9 8640 -11350 0|9 8640 -11520 0|9 8640 -11700 0|9 8640 -11870 0|9 8640 -12050 0|9 8640 -12240 0|9 8640 -12400 0|9 5950 -10720 0|9 6090 -10680 0|9 6240 -10680 0|9 6360 -10790 0|9 8860 -10580 0|9 8940 -10790 0|9 8940 -10960 0|5 12000 -9610 0|9 11000 -10200 0|9 11150 -10200 0|9 11340 -10200 0|9 11520 -10840 0|9 11410 -10770 0|9 11290 -10700 0|9 11370 -10580 0|9 11470 -10480 0|12 11430 -9670 0|0 8630 -12910 0 s203 DSGeneric -430 0 0 -430 -110 0 0 -110 65537 0 0 0|9 8950 -13610 0|9 8850 -13610 0|9 8840 -13730 0|9 9520 -14830 0|9 9520 -14830 0|9 9410 -14830 0|9 9320 -14830 0|9 9230 -14830 0|9 9140 -14830 0|9 9030 -14830 0|13 8950 -14420 0|11 8280 -13570 0 75 0|14 9450 -12670 0 -60 0|9 9320 -12280 0|9 9260 -12170 0|9 9180 -12060 0|9 9110 -11960 0|9 8980 -11770 0|9 9670 -11610 0|9 9540 -11610 0|9 8930 -11320 0|12 9410 -14220 0|13 13010 -10520 0|9 11350 -11260 0|9 11220 -11260 0|9 11220 -11260 0|9 11860 -11340 0|9 11700 -11340 0|9 12330 -11090 0|9 12400 -11150 0|9 12470 -11090 0|9 12400 -11030 0|9 12650 -11250 0|9 12720 -11170 0|0 9980 -12170 0 s239 DSGeneric -250 0 0 -260 0 0 -260 -140 0 0 -140 65537 0 0 0|9 9530 -12680 0|3 9220 -10150 0 8080 -8890 0|0 8040 -9200 0 s245 DSGeneric 0 440 65537 2070 440 65537 2070 0 65537 0 0 65537|9 11560 -9950 0|9 11660 -9900 0|9 11760 -9850 0|9 11860 -9800 0|9 12090 -9730 0|9 12230 -9730 0|9 12340 -9720 0|9 12460 -9720 0|9 11020 -9850 0|9 11120 -9840 0|9 11210 -9860 0|9 11070 -9920 0|9 11160 -9920 0|9 7380 -10720 0|9 7380 -10840 0|9 7380 -10960 0|9 7380 -11080 0|9 7380 -11190 0|9 7380 -11290 0|9 5110 -10710 0|9 5110 -10850 0|9 5110 -10990 0|9 5100 -11140 0|9 5130 -11310 0|9 5210 -11450 0|9 5500 -11100 0|9 5640 -11100 0|9 5790 -11100 0|9 5930 -11100 0|9 6070 -11100 0|0 10840 -9310 0 s281 DSGeneric -10 -300 0 1520 -300 65537 1690 -130 65537 1580 0 0 0 0 0|0 10830 -9610 0 s278 DSGeneric -80 0 0 -90 0 0 -80 -1810 0 10 -1810 0 0 0 65537|0 13670 -10550 0 s290 DSGeneric -1000 -870 65537 -2830 -870 65537 -2830 -990 0 -1020 -990 0 90 -90 0 0 0 0|9 6510 -11750 0|9 6170 -11770 0|9 6100 -11650 0|9 6240 -11650 0|9 6090 -11740 0|9 6240 -11730 0|6 11420 -10050 0|15 8310 -13020 0 BonusRoom|13 6170 -11690 0|14 7230 -11400 0 0 40|6 9490 -14600 0|6 9620 -10650 0|2 12120 -10960 0 1 0 |14 9920 -11560 0 -100 0|14 8200 -13050 0 100 0|7 8510 -14230 0|7 11120 -10000 0|</objects></w>";
xLevel4 = "<w startY=\"-11005\" startX=\"8490\" createBackground=\"HCBG_Atmosphere1\" preProcess=\"preSetLevel\" name=\"Atmosphere1\"><objects types=\"AirVent,SSShape,GameSpring,GamePoint,FlagPole,GamePointMultiplier,GameHoverCraft,GameFuel,LevelEnd,Meteor,Satellite,ElectricCloud,BonusTeleport\">0 8670 -10820 0 3 70 |0 8330 -10830 0 3 -70 |1 9600 -11050 0 s7 DSGeneric -10 640 65537 -560 640 65537 -740 260 65537 0 0 65537|1 9600 -11050 0 s8 DSGeneric 1060 0 65537 1060 60 0 0 60 0 0 0 0|1 10660 -11230 0 s9 DSGeneric -680 0 65537 0 -180 65537 0 0 65537|1 10860 -10830 0 s10 DSGeneric 0 200 0 -1080 200 0 -190 0 65537 0 0 65537|0 10780 -11760 0 2 180 |1 10860 -11760 0 s14 DSGeneric 30 0 0 30 1790 0 0 1790 0 0 0 65537|1 10860 -11760 0 s15 DSGeneric -570 0 65537 -570 -40 0 0 -40 0 0 0 0|0 10450 -11350 0 1 -18 |1 10290 -12700 0 s17 DSGeneric 30 0 0 30 940 0 0 940 0 0 0 65537|1 10290 -11580 0 s18 DSGeneric 0 -180 0 -420 -180 0 -240 0 65537 0 0 65537|2 10190 -11580 0 0 1900|3 9670 -10770 0|3 9770 -10800 0|3 9870 -10830 0|3 9970 -10860 0|3 10110 -10890 0|3 10250 -10920 0|3 10380 -10940 0|3 10520 -10950 0|1 8600 -10980 0 s29 DSGeneric 270 650 65537 220 690 0 50 330 65537 -270 330 65537 -410 690 65537 -450 670 0 -210 0 65537 0 0 65537|1 8580 -10360 0 s30 DSGeneric 230 480 65537 -390 480 65537 -160 0 65537 0 0 65537|0 9000 -9720 0 2 -26 |0 10720 -9830 0 1 -45 |0 10280 -9980 0 1 -45 |0 9290 -9720 0 1 45 |2 9950 -10350 0 180 1500|1 9590 -10460 0 s39 DSGeneric 1050 0 65537 1050 110 65537 200 110 65537 0 50 65537 0 0 0|0 10340 -9470 0 2 -45 |0 9550 -9470 0 2 45 |1 10290 -9420 0 s42 DSGeneric -690 0 0 -460 -230 65537 -230 -230 0 0 0 65537|1 9580 -9420 0 s45 DSGeneric 730 0 65537 1280 -550 65537 1280 50 0 -760 50 0 -760 -220 0 -370 -370 65537 0 0 65537|4 8480 -10360 0|4 9940 -9420 0|3 9770 -9460 0|3 9840 -9460 0|3 10070 -9460 0|3 10140 -9460 0|3 10100 -9510 0|3 9800 -9510 0|1 8820 -9640 0 s57 DSGeneric -670 0 0 -580 280 65537 -80 280 65537 0 0 65537|1 8150 -9640 0 s59 DSGeneric -780 0 0 -410 -130 65537 0 0 65537|1 7370 -9640 0 s60 DSGeneric 0 30 0 -740 30 0 -740 0 0 0 0 65537|1 7150 -11120 0 s64 DSGeneric -320 0 0 -320 -40 0 20 -40 65537 980 310 65537 960 350 0 0 0 0|1 6630 -12100 0 s65 DSGeneric 0 2460 65537 -50 2460 0 -50 0 0 0 0 0|1 9460 -9950 0 s66 DSGeneric -400 0 0 -270 -60 65537 -90 -60 65537 0 0 65537|2 9140 -9980 0 -24 2400|2 7850 -9730 0 19 3000|2 7570 -9710 0 -21 1500|0 7190 -10340 0 1 0 |0 7040 -10670 0 1 0 |0 6870 -9640 0 2 0 |0 7530 -10710 0 1 -71 |3 7180 -10980 0|3 7290 -10950 0|3 7410 -10910 0|3 7530 -10870 0|3 7640 -10830 0|3 7750 -10790 0|1 7610 -10520 0 s80 DSGeneric 0 170 0 300 170 65537 370 0 0 0 0 0|4 7810 -10350 0|3 8180 -9740 0|3 8280 -9760 0|3 8380 -9770 0|3 8500 -9770 0|3 8610 -9770 0|3 8720 -9760 0|3 8820 -9740 0|0 7600 -10540 0 1 -71 |1 6630 -10330 0 s91 DSGeneric 180 0 65537 180 40 0 0 40 0 0 0 0|2 6720 -10330 0 0 2000|5 8500 -9650 0|4 6690 -9640 0|0 6900 -11160 0 2 0 |1 7030 -11820 0 s97 DSGeneric 210 -70 65537 1790 -70 65537 2010 0 65537 0 0 0|1 6630 -12100 0 s98 DSGeneric 0 -390 0 910 -390 0 0 0 65537|1 7320 -11530 0 s100 DSGeneric 180 -50 65537 680 -50 65537 810 0 65537 0 0 0|1 7540 -12490 0 s101 DSGeneric 0 -340 0 1270 -340 0 1270 0 65537 0 0 65537|1 8810 -12830 0 s102 DSGeneric 0 -70 0 1480 -70 0 1480 130 0 1220 0 65537 0 0 65537|3 8280 -9400 0|3 8370 -9400 0|3 8610 -9400 0|3 8700 -9400 0|6 8490 -9420 0|7 7730 -10070 0|1 7550 -10780 0 s109 DSGeneric 180 70 0 60 430 0 20 310 65537 80 180 65537 -40 130 65537 0 0 65537|1 8290 -11100 0 s110 DSGeneric 0 -40 0 400 -40 65537 400 0 0 0 0 0|8 8490 -11140 0|4 7700 -11580 0|0 9040 -12210 0 1 0 |0 7160 -11860 0 1 -20 |0 10290 -12550 0 3 -89 |0 10220 -12740 0 1 205 |0 10100 -12800 0 1 206 |1 10080 -12210 0 s118 DSGeneric 10 30 0 -970 30 0 -970 0 0 0 0 65537|1 9850 -12630 0 s119 DSGeneric 0 30 0 -450 30 0 -450 0 0 0 0 65537|4 9730 -12630 0|0 8880 -12490 0 1 0 |3 9270 -12360 0|3 9370 -12360 0|3 9480 -12360 0|3 9580 -12360 0|3 9680 -12360 0|3 9790 -12360 0|3 9900 -12360 0|3 10010 -12360 0|3 9040 -12730 0|3 9160 -12730 0|3 9280 -12730 0|3 9400 -12730 0|3 9520 -12730 0|3 9630 -12730 0|1 7360 -12170 0 s137 DSGeneric 1090 0 65537 1090 40 0 0 40 0 0 0 0|3 7420 -12290 0|3 7550 -12310 0|3 7670 -12330 0|3 7800 -12340 0|3 8100 -12340 0|3 8250 -12340 0|3 8410 -12330 0|3 7470 -12010 0|3 7570 -12010 0|3 7680 -12010 0|3 7790 -12010 0|3 7900 -12010 0|3 8020 -12010 0|3 8130 -12010 0|3 8250 -12010 0|3 8370 -12010 0|3 8870 -11630 0|3 10000 -11130 0|3 10290 -11130 0|3 10610 -11130 0|3 9070 -10150 0|3 8990 -10320 0|3 8920 -10460 0|3 8860 -10620 0|3 8780 -10770 0|3 8710 -10940 0|3 8290 -10270 0|3 8230 -10140 0|3 8180 -10030 0|3 8120 -9900 0|5 7950 -12350 0|5 6870 -10950 0|3 6720 -11240 0|3 6720 -11080 0|3 6720 -10920 0|3 6720 -10780 0|3 6720 -10620 0|3 6720 -10470 0|1 7970 -10530 0 s182 DSGeneric -90 0 0 70 -310 0 160 -280 0 0 0 65537|1 9780 -11310 0 s183 DSGeneric -810 190 0 -810 120 0 -110 -80 65537 0 0 65537|1 9120 -11700 0 s184 DSGeneric 260 150 65537 -190 160 0 -190 100 0 0 0 65537|3 8830 -11670 0|3 8790 -11710 0|3 8760 -11630 0|3 8830 -11750 0|3 8870 -11790 0|3 8720 -11750 0|3 8690 -11710 0|3 8760 -11790 0|3 8730 -11670 0|3 10630 -11680 0|3 10330 -11660 0|3 10190 -11840 0|3 10190 -12060 0|3 10190 -12320 0|3 10020 -11300 0|3 9930 -11360 0|3 9850 -11380 0|3 9830 -11790 0|3 9700 -11740 0|3 9550 -11680 0|3 9400 -11610 0|3 9040 -11900 0|3 9180 -11820 0|3 9300 -11720 0|3 9170 -12000 0|3 9290 -11930 0|3 9430 -11840 0|3 9600 -11910 0|3 9770 -11990 0|3 9440 -12030 0|9 7860 -10750 0|9 6770 -10460 0|9 8350 -11720 0|9 8000 -11700 0|9 9330 -12720 0|10 9950 -10210 0|11 10960 -11140 0 -150 0|10 8830 -11260 0|11 8740 -12240 0 0 0|11 10490 -12560 0 -150 0|9 10050 -10540 0|11 9480 -10530 0 0 0|3 9710 -10550 0|3 9830 -10550 0|3 9940 -10550 0|3 10170 -10550 0|3 10300 -10550 0|3 10430 -10550 0|3 10570 -10540 0|3 9950 -10160 0|3 9950 -10030 0|3 9950 -9880 0|3 9950 -9730 0|10 9620 -12730 0|12 7950 -12170 0 BonusRoom|0 8490 -9360 0 1 0 |6 7170 -9900 0|3 7380 -9730 0|3 7230 -9730 0|3 7080 -9730 0|3 6940 -9730 0|6 8790 -12020 0|</objects></w>";
xBonusLevel = "<w startY=\"-65\" startX=\"300\" createBackground=\"HGBG_BonusRoom\" preProcess=\"preSetLevel\" name=\"Bonus1\"><objects types=\"GamePoint,AirVent,SSShape,BonusTeleport,GamePointMultiplier,GameSpring\">0 100 -1200 0|0 150 -1150 0|0 100 -1100 0|0 150 -1050 0|0 100 -1000 0|0 150 -950 0|0 100 -900 0|0 150 -850 0|0 100 -800 0|0 150 -750 0|0 100 -700 0|0 150 -650 0|0 100 -600 0|0 150 -550 0|0 100 -500 0|0 150 -450 0|0 100 -400 0|0 150 -350 0|0 100 -300 0|0 150 -250 0|0 100 -200 0|0 150 -150 0|0 700 -1200 0|0 750 -1150 0|0 700 -1100 0|0 750 -1050 0|0 700 -1000 0|0 750 -950 0|0 700 -900 0|0 750 -850 0|0 700 -800 0|0 750 -750 0|0 700 -700 0|0 750 -650 0|0 700 -600 0|0 750 -550 0|0 700 -500 0|0 750 -450 0|0 700 -400 0|0 750 -350 0|0 700 -300 0|0 750 -250 0|0 700 -200 0|0 750 -150 0|1 430 -40 0 2 0 |1 310 -770 0 1 0 |1 560 -770 0 1 0 |2 860 -120 0 s48 DSGeneric 710 0 65537 710 60 0 0 60 0 0 0 0|3 1420 -120 0 BonusRoom|1 1640 -40 0 1 0 |0 2030 -1130 0|0 1960 -1130 0|0 1890 -1130 0|0 1820 -1130 0|0 1750 -1130 0|0 1680 -1130 0|0 1610 -1130 0|0 1540 -1130 0|0 1470 -1130 0|0 1400 -1130 0|0 1330 -1130 0|4 430 -1190 0|1 2010 -50 0 1 0 |5 1190 -120 0 0 2000|2 30 -2610 0 s76 DSGeneric 0 2570 65537 -20 2570 0 -20 0 0 0 0 0|5 2130 -960 0 0 2000|2 2320 -960 0 s78 DSGeneric 0 30 0 -340 30 0 -340 0 0 0 0 65537|2 2090 -1860 0 s79 DSGeneric 50 -50 0 270 170 0 220 220 0 0 0 65537|5 2160 -1780 0 -135 1500|0 2130 -1130 0|0 2130 -1220 0|0 2130 -1310 0|0 2130 -1400 0|0 2130 -1480 0|0 2130 -1550 0|0 2130 -1630 0|0 2080 -1680 0|0 2030 -1640 0|0 1970 -1580 0|1 2840 -460 0 3 0 |2 3000 -2710 0 s126 DSGeneric 30 0 0 30 2670 0 0 2670 0 0 0 65537|2 30 -40 0 s127 DSGeneric 2970 0 65537 2970 50 0 0 50 0 0 0 0|1 2380 -40 0 1 0 |1 2730 -50 0 1 0 |0 2970 -170 0|0 2920 -150 0|0 2890 -90 0|0 1760 -160 0|0 1830 -160 0|0 1900 -160 0|0 1860 -210 0|0 1790 -210 0|0 1750 -270 0|0 1820 -270 0|0 1890 -270 0|0 2130 -280 0|0 2210 -280 0|0 2300 -280 0|0 2250 -220 0|0 2170 -220 0|0 2130 -170 0|0 2210 -170 0|0 2290 -170 0|0 2470 -290 0|0 2540 -290 0|0 2620 -290 0|0 2500 -220 0|0 2580 -220 0|0 2460 -160 0|0 2540 -160 0|0 2620 -160 0|4 2960 -90 0|0 1910 -1520 0|0 1860 -1470 0|0 1810 -1420 0|0 1760 -1370 0|0 1710 -1320 0|0 2720 -1600 0|0 2680 -1560 0|0 2660 -1500 0|0 2690 -1460 0|0 2720 -1420 0|0 2720 -1370 0|0 2690 -1310 0|0 2670 -1260 0|0 2690 -1210 0|0 2710 -1170 0|0 2720 -1090 0|0 2690 -1060 0|0 2680 -1010 0|0 2690 -960 0|0 2720 -910 0|0 2720 -850 0|0 2700 -800 0|0 2670 -750 0|0 2670 -690 0|0 2700 -650 0|0 2730 -600 0|0 1400 -890 0|0 1510 -850 0|0 1620 -800 0|0 1740 -760 0|0 1890 -720 0|0 2020 -720 0|0 2170 -710 0|0 2300 -690 0|0 2460 -630 0|0 2580 -580 0|0 2660 -530 0|0 430 -920 0|0 430 -980 0|0 430 -1040 0|0 430 -1100 0|0 310 -1190 0|0 560 -1190 0|2 860 -1830 0 s156 DSGeneric 60 0 0 60 1450 65537 0 1450 65537 0 0 65537|2 1660 -1430 0 s159 DSGeneric 0 -430 0 430 -430 0 0 0 65537|</objects></w>";
Frame 36
function processLevelXML(xObj) {
var wn = xObj.firstChild;
var objN = wn.firstChild;
var objData = objN.firstChild.nodeValue;
var attr = wn.attributes;
var name = attr.name;
var lev = new SSLevel(name);
lev.preProcess = eval (attr.preProcess);
lev.createBackground = eval (attr.createBackground);
lev.startX = Number(attr.startX);
lev.startY = Number(attr.startY);
var types = objN.attributes.types.split(",");
var i = types.length;
while ((--i) > -1) {
types[i] = eval (types[i]);
}
var objStr = objData.split("|");
var i = -1;
var c = objStr.length;
while ((++i) < c) {
var a = objStr[i].split(" ");
var j = a.length;
var cn = ((a[0] = types[a[0]]));
while (--j) {
var v = a[j];
var char = v.charAt(0);
if ((char == "\"") || (char == "'")) {
a[j] = v.substring(1, v.length - 1);
continue;
}
v = Number(v);
if (isNaN(v)) {
var tmp = eval (a[j]);
if (tmp != null) {
a[j] = tmp;
}
} else {
a[j] = v;
}
}
lev.addObject.apply(lev, a);
}
return(lev);
}
function loadXMLFiles(onComplete) {
lfFileList = arguments.splice(1);
lfFileList.onComplete = onComplete;
lfIndex = lfFileList.length;
lfLoadNext();
}
function lfOnLoad() {
if (!lfIndex) {
lfFileList.onComplete(lfFileList);
return(undefined);
}
lfLoadNext();
}
function lfLoadNext() {
lfIndex--;
var _local2 = lfFileList[lfIndex];
var _local1 = new XML();
_local1.ignoreWhite = true;
_local1.onLoad = lfOnLoad;
_local1.load(_local2);
lfFileList[lfIndex] = _local1;
}
function startNewGame() {
if (_root.GameScore > 0) {
_level0.sendScore(GameScore);
}
var _local2 = new CallStack();
_local2.call(_root, fadeOut);
_local2.wait(1);
_local2.call(_root, startGame);
_local2.start();
}
function quitGame() {
GameScore = mcInterface.score;
_level0.quitGame(GameScore);
}
function gotoNextLevel() {
var _local2 = new CallStack();
_local2.call(_root, fadeOut);
_local2.wait(1);
_local2.call(_root, gotoAndStop, "Game");
_local2.start();
}
function startGame() {
GameScore = 0;
GameLives = (VR_LIVES ? 5 : 3);
GameLevel = -1;
if (testMode) {
if (Key.isDown(49)) {
GameLevel = -1;
} else if (Key.isDown(50)) {
GameLevel = 0;
} else if (Key.isDown(51)) {
GameLevel = 1;
} else if (Key.isDown(52)) {
GameLevel = 2;
}
gotoAndStop ("game");
} else {
gotoAndStop ("game");
}
}
function exitLevel() {
stopAllSounds();
GameScore = mcInterface.score;
GameLives = mcInterface.lives;
var _local2 = new CallStack();
_local2.call(_root, fadeOut);
_local2.wait(1);
if ((GameLevel + 1) >= levels.length) {
_local2.call(_root, gotoAndStop, "winGame");
} else {
_local2.call(_root, gotoAndStop, "NextLevel");
}
_local2.start();
}
function loseGame() {
stopAllSounds();
GameScore = mcInterface.score;
gotoAndStop ("loseGame");
}
function fadeIn() {
mcFade.gotoAndPlay("on");
}
function fadeOut() {
mcFade.gotoAndPlay(2);
}
function nextLevel() {
GameLevel++;
LevelHealth = 1;
LevelFlags = 0;
var _local2 = bonusRoom.build(mcGame, GameWorld);
_local2.startPopShown = true;
_local2.musicID = "music" + GameLevel;
var _local3 = levels[GameLevel];
_local3.onComplete = function (base, ssw) {
ssw.musicID = "music" + GameLevel;
base.setActiveWorld(ssw);
base.start();
_root.fadeIn();
};
_local3.build(mcGame, GameWorld);
}
function preSetLevel(ssw) {
var _local2;
_local2 = new HangGlider();
ssw.addObject(_local2);
ssw.onEndLevel = exitLevel;
_local2.moveTo(this.startX, this.startY, 0);
_local2.startX = this.startX;
_local2.startY = this.startY;
_local2.score = GameScore;
_local2.lives = GameLives;
_local2.flags = LevelFlags;
_local2.health = LevelHealth;
mcInterface.init(mcGame, _local2);
}
function returnToMainLevel(obj) {
var _local2 = obj.world.prevWorld.character;
moveBetweenWorlds(obj, obj.world.prevWorld);
}
function gotoBonusRoom(obj) {
var _local2 = mcGame.getWorld(bonusRoom.name);
_local2.gotoBonusRoom = returnToMainLevel;
_local2.prevWorld = mcGame.activeWorld;
var _local1 = _local2.character;
_local1.moveTo(_local1.startX, _local1.startY, 0);
_local1.velocity.x = 0;
_local1.velocity.y = 0;
_local1.direction.x = 1;
moveBetweenWorlds(obj, _local2);
}
function moveBetweenWorlds(obj, w) {
var _local3 = w.character;
_local3.score = obj.score;
_local3.health = obj.health;
_local3.flags = obj.flags;
var _local2 = new CallStack();
mcGame.pause();
_local2.call(_root, fadeOut);
_local2.wait(1);
_local2.call(_root, stopAllSounds);
_local2.call(mcGame.activeWorld.musicClip.sound, Sound.prototype.stop);
_local2.call(mcGame, mcGame.setActiveWorld, w);
_local2.call(_root, fadeIn);
_local2.call(mcGame, mcGame.resume);
_local2.call(w.musicClip.sound, Sound.prototype.stop);
_local2.call(w.musicClip.sound, Sound.prototype.start, 0, 1048575);
_local2.start();
}
function HCBG_Canyon_Level1(ssw) {
var _local1 = new SSBackground("Canyon0", 4000, 600, 600);
ssw.addBackground(_local1);
_local1.setPattern((o = new GDK.Grid(1, 1, 1)));
_local1 = new SSBackground("Canyon1", 1600, 300, 200, 1.5);
ssw.addBackground(_local1);
var _local4;
var _local3;
_local1.setPattern((o = new GDK.Grid(9, 10, 0)));
o.copyFromArray([13, 11, 10, 12, 5, 5, 5, 5, 5, 10, 4, 6, 10, 1, 11, 10, 11, 3, 13, 4, 0, 2, 1, 4, 2, 12, 5, 3, 7, 0, 2, 11, 7, 2, 11, 3, 0, 0, 0, 2, 4, 0, 2, 4, 0, 5, 5, 5, 13, 12, 5, 13, 12, 5, 10, 11, 10, 1, 11, 3, 3, 10, 11, 2, 4, 2, 1, 4, 0, 0, 2, 4, 2, 4, 2, 11, 7, 0, 0, 6, 7, 2, 12, 13, 4, 0, 0, 0, 0, 0]);
}
function HCBG_City_Level(ssw) {
var _local1 = new SSBackground("City", 3000, 500, 500);
ssw.addBackground(_local1);
_local1.setPattern((o = new GDK.Grid(2, 2, 1)));
o.setCell(0, 0, 1);
o.setCell(1, 0, 2);
o.setCell(0, 1, 3);
o.setCell(1, 1, 4);
}
function HCBG_Mountain_Level1(ssw) {
var _local1 = new SSBackground("Mountains0", 7000, 500, 500);
ssw.addBackground(_local1);
_local1.setPattern((o = new GDK.Grid(2, 2, 1)));
o.setCell(1, 1, 4);
o.setCell(0, 1, 3);
o.setCell(1, 0, 2);
o.setCell(0, 0, 1);
_local1 = new SSBackground("Mountains1", 4000, 300, 200, 2);
ssw.addBackground(_local1);
_local1.setPattern((o = new GDK.Grid(11, 8, 0)));
o.copyFromArray([1, 1, 1, 1, 1, 7, 4, 2, 1, 1, 1, 1, 1, 1, 1, 7, 6, 5, 3, 4, 2, 1, 1, 1, 1, 7, 6, 0, 0, 0, 5, 3, 8, 8, 3, 8, 6, 0, 0, 0, 0, 0, 0, 0]);
}
function HCBG_Atmosphere1(ssw) {
var _local1 = new SSBackground("Atmosphere0", 8000, 500, 320);
_local1.stationary = true;
ssw.addBackground(_local1);
_local1.setPattern((o = new GDK.Grid(1, 1, 1)));
}
function HGBG_BonusRoom(ssw) {
var _local1 = new SSBackground("BonusRoomTile", 8000, 500, 500);
ssw.addBackground(_local1);
_local1.setPattern((o = new GDK.Grid(1, 1, 1)));
_local1.offsetX = 250;
_local1.offsetY = 125;
}
_global.GameBase = this;
var lfFileList;
var lfIndex;
var mcInterface;
var GameScore;
var GameLives;
var GameLevel;
var LevelFlags;
var LevelHealth;
if (!levels) {
var levels = [];
levels[0] = processLevelXML(new XML(xLevel1));
levels[1] = processLevelXML(new XML(xLevel2));
levels[2] = processLevelXML(new XML(xLevel3));
levels[3] = processLevelXML(new XML(xLevel4));
bonusRoom = processLevelXML(new XML(xBonusLevel));
}
startGame();
stop();
Frame 43
nextLevel();
Frame 51
fadeIn();
_quality = "HIGH";
Frame 64
gotoAndStop ("game");
_quality = "HIGH";
Frame 71
fadeIn();
_quality = "HIGH";
Frame 79
fadeIn();
_quality = "HIGH";
Symbol 44 Button
on (release) {
nextFrame();
}
Symbol 62 Button
on (release) {
prevFrame();
}
Symbol 88 MovieClip Frame 1
stop();
Symbol 88 MovieClip Frame 2
stop();
Symbol 88 MovieClip Frame 3
stop();
Symbol 88 MovieClip Frame 4
stop();
Symbol 88 MovieClip Frame 5
stop();
Symbol 88 MovieClip Frame 6
stop();
Symbol 684 MovieClip [__Packages.PerformanceTest] Frame 0
class PerformanceTest
{
var remainingLoops, onComplete, flashMajorVersion, flashMinorVersion, intervalID, log, processor;
function PerformanceTest (itterations, onComplete) {
if (itterations) {
loops = itterations;
}
remainingLoops = loops;
if (onComplete) {
this.onComplete = onComplete;
}
var _local2 = System.capabilities.version.substr(4).split(",");
flashMajorVersion = Number(_local2[0]);
flashMinorVersion = Number(_local2[2]);
complete = false;
intervalID = setInterval(function (o) {
o.test();
}, 0, this);
}
function test() {
if (remainingLoops <= 0) {
finalize();
clearInterval(intervalID);
return(undefined);
}
remainingLoops--;
var _local4 = getTimer();
var _local3;
var _local2 = 0;
while (_local2 < 6400) {
_local3 = {};
_local2++;
}
time = time + (getTimer() - _local4);
}
function finalize() {
score = Math.floor((loops / time) * 10000);
if (flashMajorVersion >= 7) {
log = Math.log(score * 0.015);
} else {
log = Math.log(score * 0.023);
}
processor = log * 1000;
complete = true;
onComplete(this);
}
function toString() {
if (score) {
return((((((((("Loops:\t" + loops) + "\nFlash Version: \t") + System.capabilities.version) + "\nTotal Time:\t") + time) + "\nScore: \t") + score) + "\nProcessor: \t") + processor);
}
return("Test In Process.");
}
var score = 0;
var time = 0;
var loops = 20;
var complete = false;
}
Symbol 685 MovieClip [__Packages.Vector] Frame 0
class Vector
{
function Vector (x, y, z) {
if ((x || (y)) || (z)) {
this.x = (x ? (x) : 0);
this.y = (y ? (y) : 0);
this.z = (z ? (z) : 0);
}
}
function loc(x, y, z) {
this.x = x;
this.y = y;
this.z = z;
}
function copy() {
return(new Vector(x, y, z));
}
function copyTo(a) {
a.x = x;
a.y = y;
a.z = z;
}
function copyFrom(a) {
x = a.x;
y = a.y;
z = a.z;
}
function distanceToVector(a) {
var _local4 = a.x - x;
var _local3 = a.y - y;
var _local2 = a.z - z;
return(Math.sqrt(((_local4 * _local4) + (_local3 * _local3)) + (_local2 * _local2)));
}
function distanceToCoordinates(x, y, z) {
var _local4 = this.x - x;
var _local3 = this.y - y;
var _local2 = this.z - z;
return(Math.sqrt(((_local4 * _local4) + (_local3 * _local3)) + (_local2 * _local2)));
}
function get magnitude() {
return(Math.sqrt(((x * x) + (y * y)) + (z * z)));
}
function get length() {
return(Math.sqrt(((x * x) + (y * y)) + (z * z)));
}
function set length(newLength) {
var _local2 = newLength / Math.sqrt(((x * x) + (y * y)) + (z * z));
x = x * _local2;
y = y * _local2;
z = z * _local2;
//return(length);
}
function dot(v) {
return(((x * v.x) + (y * v.y)) + (z * v.z));
}
function cross(v) {
if (!v) {
v = VECPZ;
}
return(new Vector((y * v.z) - (z * v.y), (z * v.x) - (x * v.z), (x * v.y) - (y * v.x)));
}
function normalize() {
var _local2 = Math.sqrt(((x * x) + (y * y)) + (z * z));
x = x / _local2;
y = y / _local2;
z = z / _local2;
return(this);
}
function getNormalized() {
var _local2 = Math.sqrt(((x * x) + (y * y)) + (z * z));
return(new Vector(x / _local2, y / _local2, z / _local2));
}
function multiply(scalar) {
x = x * scalar;
y = y * scalar;
z = z * scalar;
}
function divide(scalar) {
if (!scalar) {
x = 0;
y = 0;
z = 0;
return(undefined);
}
x = x / scalar;
y = y / scalar;
z = z / scalar;
}
function reverse() {
x = x * -1;
y = y * -1;
z = z * -1;
}
function getReversed() {
return(new Vector(-x, -y, -z));
}
function toString() {
return(((((("Vector(" + x) + ",") + y) + ",") + z) + ")");
}
static var ZERO = new Vector(0, 0, 0);
static var VECPX = new Vector(1, 0, 0);
static var VECNX = new Vector(-1, 0, 0);
static var VECPY = new Vector(0, 1, 0);
static var VECNY = new Vector(0, -1, 0);
static var VECPZ = new Vector(0, 0, 1);
static var VECNZ = new Vector(0, 0, -1);
var x = 0;
var y = 0;
var z = 0;
}
Symbol 686 MovieClip [__Packages.SSDrawStyle] Frame 0
class SSDrawStyle extends Array
{
var groups, root, target, push;
function SSDrawStyle () {
super();
}
function setup(points, edges) {
var _local2 = edges.length;
var _local4;
var _local5 = edges[0].props & 65535;
_local4 = [edges[0]];
groups = [_local4];
while (_local2-- , _local2 > 0) {
_local5 = edges[_local2].props & 65535;
if (_local5 != _local5) {
_local4 = [edges[_local2]];
groups.push(_local4);
} else {
_local4.push(edges[_local2]);
}
}
if ((_local4 != edges[0]) && ((_local4[0].props & 65535) == (edges[0].props & 65535))) {
groups[0] = groups.pop().concat(groups[0]);
}
}
function calculateLighting(normal, ambient, diffuse, specular) {
var _local2;
_local2 = lightDirection.dot(normal);
if (_local2 <= 0) {
return(new RGB(diffuse.r - ((specular.r - diffuse.r) * _local2), diffuse.g - ((specular.g - diffuse.g) * _local2), diffuse.b - ((specular.b - diffuse.b) * _local2)));
}
return(new RGB(diffuse.r + ((ambient.r - diffuse.r) * _local2), diffuse.g + ((ambient.g - diffuse.g) * _local2), diffuse.b + ((ambient.b - diffuse.b) * _local2)));
}
function draw(root) {
var _local3 = -1;
this.root = (target = root);
target.clear();
created = 0;
var _local2;
_local3++;
while (_local2 = this[_local3] , _local2) {
_local2[0].apply(this, _local2[1]);
}
}
function instruction(method) {
push([method, arguments.splice(1)]);
}
function solidShape(color) {
push([_solid, arguments]);
}
function bitmapShape(texture) {
push([_bitmap, arguments]);
}
function gradientShape() {
push([_gradient, arguments]);
}
function makeTarget() {
push([_makeTarget, arguments]);
}
function setTarget(targetName) {
push([_setTarget, arguments]);
}
function goRoot() {
push([_goRoot, arguments]);
}
function goRootTarget() {
push([_goRootTarget, arguments]);
}
function attachAndPlaceMovie() {
push([_attachAndPlaceMC, arguments]);
}
function _solid(color, p, p1) {
var _local3 = target;
_local3.beginFill(color);
var _local2 = p.length;
_local3.moveTo(p[0].x, p[0].y);
while (_local2-- , _local2 > -1) {
_local3.lineTo(p[_local2].x, p[_local2].y);
}
_local2 = p1.length;
if (_local2) {
_local3.moveTo(p1[0].x, p1[0].y);
while (_local2-- , _local2 > -1) {
_local3.lineTo(p1[_local2].x, p1[_local2].y);
}
}
_local3.endFill();
}
function _gradient(type, colors, alphas, ratios, matrix, p) {
var _local4 = target;
_local4.beginGradientFill(type, colors, alphas, ratios, matrix);
var _local2 = p.length;
_local4.moveTo(p[0].x, p[0].y);
while (_local2-- , _local2 > -1) {
_local4.lineTo(p[_local2].x, p[_local2].y);
}
_local4.endFill();
}
function _bitmap(tileID, p) {
var _local4 = target;
_local4.beginFill(16763904);
var _local2 = p.length;
_local4.moveTo(p[0].x, p[0].y);
while (_local2-- , _local2 > -1) {
_local4.lineTo(p[_local2].x, p[_local2].y);
}
_local4.endFill();
}
function _makeTarget(name, depth, linkageID) {
if (target[name]) {
return(undefined);
}
if (name == null) {
name = "mc" + created;
}
if (linkageID != null) {
target.attachMovie(linkageID, name, (depth ? (depth) : (created)));
} else {
target.createEmptyMovieClip(name, (depth ? (depth) : (created)));
}
created++;
}
function _setTarget(name) {
target = target[name];
}
function _goRoot() {
target = root;
}
function _goRootTarget(name) {
target = root[name];
}
function _attachAndPlaceMC(assetID, depth, x, y) {
var _local2 = target.attachMovie(assetID, (assetID + "_") + depth, depth);
_local2._x = x;
_local2._y = y;
}
static var mainColor = 16763904;
static var gradientAlpha = [0, 100];
static var gradientColors = [0, 100];
static var lightDirection = new Vector(1, 1).normalize();
var created = 0;
}
Symbol 687 MovieClip [__Packages.RGB] Frame 0
class RGB extends Number
{
function RGB (r, g, b) {
super();
switch (arguments.length) {
case 3 :
this.r = r;
this.g = g;
this.b = b;
break;
case 0 :
break;
case 1 :
hex(r);
}
}
function hex(i) {
r = i >>> 16;
g = (i - (r << 16)) >>> 8;
b = i % 256;
}
function toHex() {
var _local4 = ((r << 16) + (g << 8)) + b;
var _local5 = "";
var _local3 = 20;
while (_local3 > -1) {
var _local2 = _local4 >>> _local3;
_local5 = _local5 + ((_local2 > 9) ? (chr(55 + _local2)) : (_local2));
_local4 = _local4 - (_local2 << _local3);
_local3 = _local3 - 4;
}
return("0x" + _local5);
}
function valueOf() {
return(((r << 16) + (g << 8)) + b);
}
function toString() {
return(((((("RGB(" + r) + ",") + g) + ",") + b) + ")");
}
var r = 0;
var g = 0;
var b = 0;
}
Symbol 688 MovieClip [__Packages.GDK.Generic] Frame 0
class GDK.Generic
{
var world, onAddToScene, children, onRemoveFromScene, onBeginParent, onEndParent, onAddChild, displayNode, parent, assetID, onDisplay, target, onAddDisplay, onRemoveDisplay, name;
function Generic () {
uniqueID = created++;
setRenderable(renderable);
setAffectChildren(affectChildren);
}
function addToScene() {
if (inScene) {
return(undefined);
}
world.addActiveObject(this);
inScene = true;
addDisplay();
onAddToScene();
if (children) {
var _local2 = children.length;
while (_local2-- , _local2 > -1) {
children[_local2].addToScene();
}
}
}
function removeFromScene() {
if (!inScene) {
return(undefined);
}
removeDisplay();
inScene = false;
world.removeActiveObject(this);
onRemoveFromScene();
if (children) {
var _local2 = children.length;
while (_local2-- , _local2 > -1) {
children[_local2].removeFromScene();
}
}
}
function setAffectChildren(b) {
if (affectChildren == b) {
return(undefined);
}
if ((affectChildren = b)) {
if (children) {
onBeginParent();
}
} else if (children) {
onEndParent();
}
}
function addChild(child, isolated) {
if ((!allowChildren) || (child.parent == this)) {
return(false);
}
child.parent.removeChild(child);
child.parent = this;
if (world && (world != child.world)) {
world.addObject(child, true);
}
if (children == undefined) {
onBeginParent();
hasChildren = true;
children = [child];
} else {
children.push(child);
}
if (inScene && (!isolated)) {
child.addToScene();
}
onAddChild(child);
return(true);
}
function removeChild(child) {
if ((!children) || (child.parent != this)) {
return(undefined);
}
var _local2 = children.length;
while (_local2-- , _local2 > -1) {
if (children[_local2] == child) {
children.splice(_local2, 1);
break;
}
}
child.parent = undefined;
if (!children.length) {
onEndParent();
hasChildren = false;
delete children;
}
}
function addToWorld(newWorld) {
newWorld.addObject(this);
}
function removeFromWorld() {
world.removeObject(this);
}
function detachFromParent(parent) {
parent.removeChild(this);
}
function becomeChildTo(parent) {
parent.addChild(this);
}
function requestDisplaySpace() {
if (!displayNode) {
var _local2 = parent;
while (_local2) {
if (_local2.isDisplayNode) {
break;
}
_local2 = _local2.parent;
}
displayNode = (_local2 ? (_local2.target) : (world.target));
}
if (assetID != null) {
return(displayNode.attachMovie(assetID, "mc" + uniqueID, 2130690045 - uniqueID));
}
return(displayNode.createEmptyMovieClip("mc" + uniqueID, 2130690045 - uniqueID));
}
function setDisplay() {
onDisplay.apply(this, arguments);
}
function addDisplay() {
if ((!renderable) || (target)) {
return(undefined);
}
queueForDisplay();
target = requestDisplaySpace();
onAddDisplay();
}
function removeDisplay() {
target.swapDepths(0);
target.removeMovieClip();
delete target;
onRemoveDisplay();
}
function setAssetID(newAssetID) {
if (assetID == newAssetID) {
return(undefined);
}
if (inScene) {
removeDisplay();
}
assetID = newAssetID;
if (inScene) {
addDisplay();
}
}
function queueForDisplay() {
if (renderable) {
world.queueForDisplay(this);
}
}
function setRenderable(b) {
if (b) {
delete queueForDisplay;
if (inScene) {
addDisplay();
}
} else if (inScene) {
removeDisplay();
}
}
function toString() {
return(((className + " #") + uniqueID) + (name ? (("(" + name) + ")") : ""));
}
static var created = 0;
var className = "Generic";
var uniqueID = -1;
var renderable = false;
var inScene = false;
var affectChildren = true;
var allowChildren = true;
var hasChildren = false;
var isDisplayNode = false;
}
Symbol 689 MovieClip [__Packages.GDK.Node] Frame 0
class GDK.Node extends GDK.Generic
{
var onCollision, world, onMove, queueForDisplay, children, target, affectChildren;
function Node () {
super();
}
function checkCollisionList(objects, flag, options, maxCol) {
if (maxCol == null) {
maxCol = Number.MAX_VALUE;
}
if (flag == null) {
flag = collisionMask;
}
var _local4 = 0;
var _local5;
var _local2 = objects.length;
collisionID++;
while (_local2-- , _local2 > -1) {
if (objects[_local2] == this) {
continue;
}
if ((collisionID != objects[_local2].lastCollisionID) && ((flag & objects[_local2].collisionMask) > 0)) {
objects[_local2].lastCollisionID = collisionID;
_local5 = checkCollision(objects[_local2]);
if (_local5) {
_local4++;
if (((!(_local5 & COLLISION_SKIP_EVENT)) && (onCollision(objects[_local2], options) == COLLISION_CANCEL)) || (_local4 >= maxCol)) {
break;
}
}
}
}
return(_local4);
}
function checkCollision(obj) {
return(false);
}
function moveTo(x, y, z) {
moveBy(x - this.x, y - this.y, z - this.z);
}
function moveBy(x, y, z) {
if ((x || (y)) || (z)) {
this.x = this.x + x;
this.y = this.y + y;
this.z = this.z + z;
positionChanged(x, y, z);
}
}
function moveToGlobally(x, y, z) {
}
function positionChanged(xShift, yShift, zShift) {
world.onObjectMoved(this);
onMove(xShift, yShift, zShift);
queueForDisplay();
}
function pv_positionChanged(xShift, yShift, zShift) {
var _local2 = children.length;
while (_local2-- , _local2 > -1) {
children[_local2].moveBy(xShift, yShift, zShift);
}
queueForDisplay();
}
function display() {
setDisplay.apply(this, arguments);
delete queueForDisplay;
}
function setDisplay() {
target._x = x;
target._y = y;
}
function getUpdates() {
world.updateList.addMember(this);
}
function cancelUpdates() {
world.updateList.removeMember(this);
}
function onBeginParent() {
if (!affectChildren) {
return(undefined);
}
positionChanged = pv_positionChanged;
}
function onEndParent() {
delete positionChanged;
}
function timelineUpdate() {
queueForDisplay();
}
static var COLLISION_OK = 1;
static var COLLISION_CANCEL = 2;
static var COLLISION_SKIP_EVENT = 4;
static var collisionID = 0;
var className = "Node";
var renderable = true;
var x = 0;
var y = 0;
var z = 0;
var collisionMask = 0;
}
Symbol 690 MovieClip [__Packages.SSObject] Frame 0
class SSObject extends GDK.Node
{
var velocity, z, screenX, x, screenY, y, world, target, depth, uniqueID, onDisplay, sectors, onMove, queueForDisplay, localSounds, sndTransform;
function SSObject () {
super();
velocity = new Vector();
}
function addToScene() {
oz = null;
gdkAddToScene();
}
function removeFromScene() {
oz = null;
gdkRemoveFromScene();
}
function setDisplay(viewport, elapsed, vdr, vl, vr) {
if ((z - viewport.z) != viewport.wTan) {
var _local5 = (screenX = ((viewport.wTan * (x - viewport.x)) / (z - viewport.z)) + viewport.halfWidth);
var _local4 = (screenY = ((viewport.wTan * (y - viewport.y)) / (z - viewport.z)) + viewport.halfHeight);
} else {
var _local5 = (screenX = Math.round((vdr * (viewport.x - x)) + viewport.halfWidth));
var _local4 = (screenY = Math.round((vdr * (viewport.y - y)) + viewport.halfHeight));
}
target._x = (-world.target._x) + _local5;
target._y = (-world.target._y) + _local4;
if (oz != ((oz = z - viewport.z))) {
target.swapDepths((depth = ((Math.floor((20000 - z) - viewport.z) * 32768) + (depthLayer * 4096)) + uniqueID));
target._xscale = (target._yscale = ((viewport.wTan * 1) / (z - viewport.z)) * 100);
}
onDisplay(viewport, elapsed, vdr, vl, vr);
}
function removeFromSectorGrid() {
var _local3;
var _local2;
var _local4 = sectors.length;
while (_local4-- , _local4 > -1) {
_local3 = sectors[_local4];
_local2 = _local3.length;
while (_local2-- , _local2 > -1) {
if (_local3[_local2] == this) {
_local3.splice(_local2, 1);
break;
}
}
}
sectors = [];
}
function addToSectorGrid() {
if (sectors.length > 0) {
removeFromSectorGrid();
}
var _local3 = world.sectors;
var _local6;
var _local2;
var _local4;
_local6 = (rightSector - leftSector) + 1;
var _local5 = _local6 * ((bottomSector - topSector) + 1);
while (_local5-- , _local5 > -1) {
_local2 = leftSector + (_local5 % _local6);
_local4 = topSector + Math.floor(_local5 / _local6);
if (_local3[_local2]) {
if (_local3[_local2][_local4]) {
_local3[_local2][_local4].push(this);
} else {
_local3[_local2][_local4] = [this];
}
} else {
_local3[_local2] = {};
_local3[_local2][_local4] = [this];
}
sectors.push(_local3[_local2][_local4]);
}
}
function updateBounds() {
var _local2 = leftSector != ((leftSector = Math.floor(((left = x - radius)) / SSGlobal.GRID_SIZE)));
var _local3 = topSector != ((topSector = Math.floor(((top = y - radius)) / SSGlobal.GRID_SIZE)));
var _local4 = rightSector != ((rightSector = Math.floor(((right = x + radius)) / SSGlobal.GRID_SIZE)));
var _local5 = bottomSector != ((bottomSector = Math.floor(((bottom = y + radius)) / SSGlobal.GRID_SIZE)));
if (((_local2 || (_local3)) || (_local4)) || (_local5)) {
removeFromSectorGrid();
addToSectorGrid();
}
}
function positionChanged(xShift, yShift, zShift) {
world.onObjectMoved(this);
onMove(xShift, yShift, zShift);
if (trackInSectorGrid) {
updateBounds();
}
queueForDisplay();
}
function createSound(id, linkageID) {
var _local2 = world.createSound(id, linkageID);
if (!localSounds) {
localSounds = [];
}
localSounds[id] = _local2;
localSounds.push(_local2);
return(_local2);
}
function deleteSound(id) {
world.deleteSound(id);
var _local3 = localSounds[id];
var _local2 = localSounds.length;
while (_local2-- , _local2 > -1) {
if (localSounds[_local2] == _local3) {
localSounds.splice(_local2, 1);
break;
}
}
delete localSounds[id];
}
function setupSound(sndObj) {
sndObj.playing = false;
}
function positionSound(sndObj, x, y, bubbleX, bubbleY) {
var _local4 = world.viewport;
var _local3 = Math.max(0, 1 - Math.abs((_local4.y - y) / bubbleY));
if (_local3 == 0) {
sndObj.stop();
sndObj.playing = false;
return(undefined);
}
var _local5 = Math.max(0, 1 - Math.abs((_local4.left - x) / bubbleX));
var _local6 = Math.max(0, 1 - Math.abs((_local4.right - x) / bubbleX));
if ((_local5 == 0) && (_local6 == 0)) {
sndObj.stop();
sndObj.playing = false;
return(undefined);
}
sndTransform.ll = (_local5 * _local3) * 100;
sndTransform.rr = (_local6 * _local3) * 100;
sndObj.setTransform(sndTransform);
if (!sndObj.playing) {
sndObj.start(0, 1048575);
sndObj.playing = true;
}
}
function editor_onAddToDocument(doc, cn, args) {
}
static var ArgTypes = [Function, Number, Number, Number];
static var DefaultArgType = Number;
var assetID = "circle";
var mapIconID = null;
var left = 0;
var top = 0;
var right = 0;
var bottom = 0;
var trackInSectorGrid = true;
var leftSector = 0;
var topSector = 0;
var rightSector = 0;
var bottomSector = 0;
var radius = 25;
var depthLayer = 1;
var autoAddToScene = true;
var gdkAddToScene = GDK.Generic.prototype.addToScene;
var gdkRemoveFromScene = GDK.Generic.prototype.removeFromScene;
var oz = null;
var editor_canRotate = false;
var editor_defaultValues = [];
var editor_defaultTypes = [];
var editor_options = [];
var editor_argNames = [];
var editor_component = [];
}
Symbol 691 MovieClip [__Packages.SSGlobal] Frame 0
class SSGlobal
{
function SSGlobal () {
}
static function ClassID(group, subgroup) {
return(group << (8 + subgroup));
}
static var GRID_SIZE = 300;
static var ASSET_VENT = "AirVent";
static var ASSET_GLIDER = "HangGlider";
static var ASSET_POINT = "gamePoint";
static var ASSET_HEALTH = "gameHealth";
static var ASSET_FLAG_POLE = "flagPole";
static var ASSET_ICON_HOVER = "itemRocket";
static var HOVER_CRAFT_FUEL = 20;
static var CLSID_ZONE = 65536;
static var CLSID_MAINCHAR = 1048576;
static var CLSID_GLIDER = 1048832;
static var CLSID_SHAPE = 2097152;
static var CLSID_COLLECTABLE = 8388608;
static var CLSID_POINT = 8388624;
static var CLSID_HEALTH = 8388640;
static var CLSID_FLAG = 8388672;
static var CLSID_SHIELD = 8388736;
static var CLSID_MULTIPLIER = 8388864;
static var CLSID_HOVERCRAFT = 8389120;
static var CLSID_FUEL = 8389632;
static var CLSID_OBSTACLE = 16777216;
static var CLSID_FLYING = 16777217;
static var CLSID_FLOATING = 16777218;
static var CLSID_OBJECT = 4194304;
static var CLSID_VENT = 4194320;
static var CLSID_WARP = 4194336;
static var CLSID_WIND = 4194368;
static var EDGE_SYSTEM_PROPS = 65535;
static var EDGE_USER_PROPS = 4294901760;
static var EDGE_DEFAULT = 0;
static var EDGE_OFF = EDGE_DEFAULT;
static var EDGE_COLLISION = 1;
static var EDGE_CAN_STAND = 65537;
static var editor_DrawStyles = ["DSGeneric"];
}
Symbol 692 MovieClip [__Packages.FlyingObstacle] Frame 0
class FlyingObstacle extends SSObject
{
var getUpdates, reset, sndTar, createSound, uniqueID, sndObj, soundID, trackInSectorGrid, cancelUpdates, particleVelocity, world, x, y, z, screenX;
function FlyingObstacle () {
super();
}
function hitObject(obj) {
obj.shiftHealth(value);
}
function onAddToScene() {
getUpdates();
reset();
if (!sndTar) {
sndTar = createSound("flying" + uniqueID);
((sndObj = sndTar.sound)).attachSound(soundID);
}
}
function onRemoveFromScene() {
trackInSectorGrid = true;
cancelUpdates();
}
function updateParticleTrail(elapsed) {
if (useParticles && (!(--particleDrop))) {
delete particleDrop;
var _local2;
_local2 = new SSParticle(particleID, particleTime, particleVelocity, spin, 0);
world.addObject(_local2);
_local2.moveTo(x, y, z);
_local2.scale = particleScale;
}
}
function playSound(vp) {
sndObj.setPan(Math.min(100, Math.max(-100, screenX * 0.3)));
var _local4 = vp.x - x;
var _local3 = vp.y - y;
var _local2 = vp.z - z;
var _local5 = Math.max(1 - (Math.sqrt(((_local4 * _local4) + (_local3 * _local3)) + (_local2 * _local2)) / 2000), 0);
sndObj.setVolume(_local5 * 100);
sndObj.start(0, 0);
}
function updateSound(vp) {
if ((oldz > soundPlane) && (z <= soundPlane)) {
playSound(vp);
}
}
function onDisplay(vp) {
updateSound(vp);
}
var className = "Flying";
var collisionMask = SSGlobal.CLSID_FLYING;
var value = -0.33333;
var removeZ = -400;
var crossedZero = false;
var spin = 80;
var particleID = "meteorSmoke";
var useParticles = true;
var particleDrop = 3;
var particleTime = 1.5;
var particleScale = 100;
var oldz = 0;
var soundPlane = 400;
}
Symbol 693 MovieClip [__Packages.SSParticle] Frame 0
class SSParticle extends SSObject
{
var assetID, lifeSpan, life, velocity, world, addToScene, getUpdates, z, target, moveBy;
function SSParticle (asset, life, velocity, rot, grav) {
super();
assetID = asset;
lifeSpan = (this.life = life);
this.velocity = (velocity ? (velocity) : (new Vector(0, 0, 0)));
if (rot != null) {
spin = rot;
}
if (grav != null) {
gravity = grav;
}
}
function onRemoveFromScene() {
world.removeObject(this);
}
function onAddToWorld() {
addToScene();
}
function onAddToScene() {
getUpdates();
}
function update(elapsed) {
if ((((life = life - elapsed)) < 0) || (z < (world.viewport.z + 50))) {
target.swapDepths(0);
target.removeMovieClip();
world.removeObject(this);
return(undefined);
}
velocity.y = velocity.y + (gravity * elapsed);
moveBy(velocity.x * elapsed, velocity.y * elapsed, velocity.z * elapsed);
}
function onDisplay(viewport, elapsed) {
var _local2;
_local2 = life / lifeSpan;
target._alpha = _local2 * 100;
target._rotation = target._rotation + (spin * elapsed);
if (scale) {
target._xscale = (target._yscale = target._xscale + (((1 - _local2) * scale) * (target._xscale / 100)));
}
}
var trackInSectorGrid = false;
var rogueNode = true;
var gravity = 0;
var spin = 0;
var alpha = true;
var scale = 0;
}
Symbol 694 MovieClip [__Packages.Meteor] Frame 0
class Meteor extends FlyingObstacle
{
var origin, x, y, z, trackInSectorGrid, velocity, particleVelocity, moveTo, target, updateSound, updateParticleTrail, oldz, moveBy, removeZ;
function Meteor () {
super();
}
function onAddToWorld() {
origin = new Vector(x, y, z);
}
function reset() {
trackInSectorGrid = false;
velocity = defaultVelocity.copy();
velocity.__set__length((velocity.__get__length() * 0.9) + (Math.random() * 0.1));
particleVelocity = new Vector(velocity.x * 0.25, velocity.y * 0.25, velocity.z * 0.25);
moveTo(origin.x - (velocity.x * timeToTarget), origin.y - (velocity.y * timeToTarget), origin.z - (velocity.z * timeToTarget));
}
function onDisplay(viewport, elapsed) {
target._rotation = target._rotation + (spin * elapsed);
updateSound(viewport);
}
function update(elapsed) {
updateParticleTrail(elapsed);
oldz = z;
moveBy(velocity.x * elapsed, velocity.y * elapsed, velocity.z * elapsed);
crossedZero = (oldz > 0) && (z <= 0);
if (z < removeZ) {
reset();
}
}
var assetID = "Meteor";
var soundID = "MeteorSound";
var radius = 80;
var spin = 80;
var particleID = "meteorSmoke";
var useParticles = true;
var particleDrop = 3;
var particleTime = 1.5;
var particleScale = 100;
var timeToTarget = 4;
static var defaultVelocity = new Vector(0, 400, -1000);
var crossedZero = false;
}
Symbol 695 MovieClip [__Packages.Satellite] Frame 0
class Satellite extends Meteor
{
function Satellite (x, y, z) {
super();
}
}
Symbol 696 MovieClip [__Packages.GameInterface] Frame 0
class GameInterface extends MovieClip
{
var base, character, world, gotoAndStop, mcHealth;
function GameInterface () {
super();
}
function init(base, character) {
this.base = base;
Key.addListener(this);
this.character = character;
character.setInterface(this);
world = character.world;
setScore(character.score);
setHealth(character.health);
setFlags(character.flags);
setLives(character.lives);
}
function showMap() {
pauseGame();
(gotoAndStop("Map"));// not popped
}
function showMenu() {
pauseGame();
(gotoAndStop("Menu"));// not popped
}
function showHelp() {
pauseGame();
(gotoAndStop("Help"));// not popped
}
function pauseGame() {
base.activeWorld.muteSounds();
base.pause();
}
function resumeGame() {
base.activeWorld.unmuteSounds();
base.resume();
(gotoAndStop(1));// not popped
}
function setScore(v) {
if (score == v) {
return(undefined);
}
vScore = (score = v);
}
function setLives(v) {
if (lives == v) {
return(undefined);
}
vLives = (lives = v);
}
function setFlags(v) {
if (flags == v) {
return(undefined);
}
vFlags = (((flags = v)) + "/") + world.flagCount;
}
function setHealth(v) {
if (health == v) {
return(undefined);
}
health = v;
mcHealth.setValue(1 - v);
}
function quitGame() {
_root.quitGame();
}
function onKeyUp() {
if (!base.running) {
return(undefined);
}
if (Key.getCode() == 77) {
if (!base.paused) {
showMap();
} else {
resumeGame();
}
}
}
var score = 0;
var flags = 0;
var lives = 0;
var health = 0;
var vScore = 0;
var vLives = 0;
var vFlags = "0/6";
}
Symbol 697 MovieClip [__Packages.ColorTransformRGB] Frame 0
class ColorTransformRGB
{
function ColorTransformRGB (ra, ga, ba, rb, gb, bb) {
if (arguments.length) {
this.ra = ra;
this.ga = ga;
this.ba = ba;
this.rb = rb;
this.gb = gb;
this.bb = bb;
}
}
var ra = 100;
var ga = 100;
var ba = 100;
var aa = 100;
var rb = 0;
var gb = 0;
var bb = 0;
var ab = 0;
}
Symbol 698 MovieClip [__Packages.HangGlider] Frame 0
class HangGlider extends SSObject
{
var velocity, world, direction, destDir, getUpdates, charSounds, createSound, externalForces, queueForDisplay, standingEdge, moveBy, mcCharacter, target, frontBar, centerBar, backBar, drawFront, drawRear, drawTarget, tint, colorObj, hoverObject, dispFront, hoverTargetFront, hoverTargetTailR, hoverTargetTailF, y, x, motionTime, motionVec, motionDist, motionDir, motionLeft, left, motionRight, right, motionTop, top, motionBottom, bottom, checkCollisionList, moveTo, z, inScene, addToScene, userDisplay;
function HangGlider () {
super();
}
function onRemoveFromScene() {
}
function onAddToWorld() {
velocity.x = 0;
velocity.y = 0;
world.character = this;
world.viewport.watch = this;
direction = new Vector(1, 0, 0);
destDir = new Vector(1, 0, 0);
}
function onAddToScene() {
getUpdates();
if (!charSounds) {
charSounds = createSound("CharSounds", soundClipID);
}
}
function update(elapsed) {
externalForces = new Vector();
queueForDisplay();
shapeCollision = false;
updatePosition(elapsed, Key.isDown(39) - Key.isDown(37), Key.isDown(40) - Key.isDown(38), Key.isDown(32));
checkCollisions(elapsed);
if ((!shapeCollision) && (!standingEdge)) {
moveBy(velocity.x * elapsed, velocity.y * elapsed, 0);
}
if (standingEdge) {
if ((standingTime < standingTimePop) && (((standingTime = standingTime + elapsed)) >= standingTimePop)) {
world.showPopup(GameGlobal.MSG_STANDING);
}
} else if (standingTime) {
world.hidePopup();
standingTime = 0;
}
}
function onRemoveFromWorld() {
}
function onAddDisplay() {
mcCharacter = target.mcCharacter;
mcCharacter.swapDepths(20);
frontBar = target.attachMovie("HangGlideBar", "FrontBar", 39);
centerBar = target.attachMovie("HangGlideBar", "CenterBar", 21);
backBar = target.attachMovie("HangGlideBar", "BackBar", 9);
drawFront = target.createEmptyMovieClip("DrawFront", 30);
drawRear = (drawTarget = target.createEmptyMovieClip("DrawRear", 10));
tint = new ColorTransformRGB();
colorObj = new Color(target);
if (hoverObject) {
addHoverDisplay();
}
}
function displayColors(viewport, elapsed) {
if (shield) {
shield = Math.max((shield = shield - elapsed), 0);
var _local2 = Math.abs(Math.sin(Math.sqrt(shield * 300)));
tint.ra = 100 + (shieldTintOffset.ra * _local2);
tint.ga = 100 + (shieldTintOffset.ga * _local2);
tint.ba = 100 + (shieldTintOffset.ba * _local2);
tint.rb = shieldTintOffset.rb * _local2;
tint.gb = shieldTintOffset.gb * _local2;
tint.bb = shieldTintOffset.bb * _local2;
colorObj.setTransform(tint);
} else if (hurtOffset) {
hurtOffset = Math.max(hurtOffset - elapsed, 0);
tint.ra = 100 + (hurtTintOffset.ra * hurtOffset);
tint.ga = 100 + (hurtTintOffset.ga * hurtOffset);
tint.ba = 100 + (hurtTintOffset.ba * hurtOffset);
tint.rb = hurtTintOffset.rb * hurtOffset;
tint.gb = hurtTintOffset.gb * hurtOffset;
tint.bb = hurtTintOffset.bb * hurtOffset;
colorObj.setTransform(tint);
}
}
function onDisplay(viewport, elapsed) {
displayColors(viewport, elapsed);
drawGlider(viewport, elapsed);
updateSound();
}
function updateSound() {
var _local2 = oAirAccel - airAccel;
if ((_local2 > 20) && (oAirAccel < 20)) {
world.playEventSound(charSounds, "gliderRustle");
}
oAirAccel = airAccel;
}
function drawGlider(viewport, elapsed) {
var _local34 = velocity.getNormalized();
yDir = yDir + (((direction.y - yDir) * elapsed) * 8);
if (((oldDX > 0) && (direction.x < 0)) || ((oldDX < 0) && (direction.x > 0))) {
var _local31 = true;
if (direction.x < 0) {
xDir = -1;
} else {
xDir = 1;
}
if ((zDir > 0) && (zDir < Math.PI)) {
} else {
zDir = ((xDir < 0) ? 0 : Math.PI);
}
}
if (_local31 || ((zDir > 0) && (zDir < Math.PI))) {
if (xDir < 0) {
zDir = Math.min(zDir + ((Math.PI * elapsed) * 2), Math.PI);
} else {
zDir = Math.max(zDir - ((Math.PI * elapsed) * 2), 0);
}
}
((dispFront = new Vector(Math.cos(zDir), yDir * 0.5, Math.sin(zDir)))).normalize();
var _local20 = dispFront.cross(Vector.VECPY);
var _local15 = dispFront.cross(_local20);
var _local23;
var _local33 = new Vector(velocity.x - (externalForces.x * 0.4), velocity.y - (externalForces.y * 0.4), 0);
_local23 = (air = Math.min(Math.max(air + ((((airAccel = ((_local33.dot(_local15) * 0.2) - 10) - air)) * elapsed) * 4), -50), 20));
var _local21 = new Vector((_local15.x * 40) + (dispFront.x * 25), _local15.y * 40, _local15.z * 40);
var _local25 = new Vector(_local21.x + (dispFront.x * 55), _local21.y + (dispFront.y * 55), _local21.z + (dispFront.z * 55));
var _local12 = new Vector(_local21.x - (dispFront.x * 80), _local21.y - (dispFront.y * 80), _local21.z - (dispFront.z * 80));
var _local5 = new Vector((_local12.x - (_local20.x * 150)) - (dispFront.x * 20), (_local12.y - (_local20.y * 150)) - (dispFront.y * 20), (_local12.z - (_local20.z * 150)) - (dispFront.z * 20));
var _local4 = new Vector((_local12.x + (_local20.x * 150)) - (dispFront.x * 20), (_local12.y + (_local20.y * 150)) - (dispFront.y * 20), (_local12.z + (_local20.z * 150)) - (dispFront.z * 20));
var _local3 = new Vector((_local12.x - _local5.x) * 0.5, (_local12.y - _local5.y) * 0.5, (_local12.z - _local5.z) * 0.5);
var _local27 = new Vector((_local5.x + _local3.x) - (_local15.x * _local23), (_local5.y + _local3.y) - (_local15.y * _local23), (_local5.z + _local3.z) - (_local15.z * _local23));
var _local2 = new Vector((_local12.x - _local4.x) * 0.5, (_local12.y - _local4.y) * 0.5, (_local12.z - _local4.z) * 0.5);
var _local26 = new Vector((_local4.x + _local2.x) - (_local15.x * _local23), (_local4.y + _local2.y) - (_local15.y * _local23), (_local4.z + _local2.z) - (_local15.z * _local23));
var _local6 = _local25.x - (_local25.z * 0.1);
var _local7 = _local25.y + (_local25.z * 0.1);
var _local10 = _local27.x - (_local27.z * 0.1);
var _local8 = _local27.y + (_local27.z * 0.1);
var _local9 = _local26.x - (_local26.z * 0.1);
var _local11 = _local26.y + (_local26.z * 0.1);
var _local14 = _local12.x - (_local12.z * 0.1);
var _local13 = _local12.y + (_local12.z * 0.1);
var _local19;
var _local17;
var _local18;
var _local16;
var _local24 = 4;
var _local22 = ((dispFront.x < 0) ? 3 : 0);
drawFront.clear();
drawRear.clear();
while (_local24-- , _local24 > -1) {
switch (Math.abs(_local22--)) {
case 0 :
((drawTarget = (((_local5.z > 0) || (dispFront.y > -0.1)) ? (drawFront) : (drawRear)))).beginFill((204 - (51 * dispFront.x)) << 16);
drawTarget.moveTo(_local6, _local7);
_local17 = _local5.y + (_local5.z * 0.1);
_local19 = _local5.x - (_local5.z * 0.1);
drawTarget.lineTo(_local19, _local17);
drawTarget.curveTo(_local10 - ((_local3.x * 0.5) - (_local3.z * 0.05)), _local8 - ((_local3.y * 0.5) + (_local3.z * 0.05)), _local10, _local8);
drawTarget.endFill();
break;
case 1 :
((drawTarget = (((_local5.z > 0) || (dispFront.y > -0.1)) ? (drawFront) : (drawRear)))).beginFill(((238 + (17 * dispFront.x)) << 16) + ((187 + (17 * dispFront.x)) << 8));
drawTarget.moveTo(_local6, _local7);
drawTarget.lineTo(_local14, _local13);
drawTarget.curveTo(_local10 + ((_local3.x * 0.5) - (_local3.z * 0.05)), _local8 + ((_local3.y * 0.5) + (_local3.z * 0.05)), _local10, _local8);
drawTarget.endFill();
break;
case 2 :
((drawTarget = (((_local4.z > 0) || (dispFront.y > -0.1)) ? (drawFront) : (drawRear)))).beginFill(((238 - (17 * dispFront.x)) << 16) + ((187 - (17 * dispFront.x)) << 8));
drawTarget.moveTo(_local6, _local7);
drawTarget.lineTo(_local14, _local13);
drawTarget.curveTo(_local9 + ((_local2.x * 0.5) - (_local2.z * 0.05)), _local11 + ((_local2.y * 0.5) + (_local2.z * 0.05)), _local9, _local11);
drawTarget.endFill();
break;
case 3 :
((drawTarget = (((_local4.z > 0) || (dispFront.y > -0.1)) ? (drawFront) : (drawRear)))).beginFill((204 + (51 * dispFront.x)) << 16);
drawTarget.moveTo(_local6, _local7);
_local16 = _local4.y + (_local4.z * 0.1);
_local18 = _local4.x - (_local4.z * 0.1);
drawTarget.lineTo(_local18, _local16);
drawTarget.curveTo(_local9 - ((_local2.x * 0.5) - (_local2.z * 0.05)), _local11 - ((_local2.y * 0.5) + (_local2.z * 0.05)), _local9, _local11);
drawTarget.endFill();
}
}
frontBar._x = (centerBar._x = (backBar._x = _local6));
frontBar._y = (backBar._y = (centerBar._y = _local7));
var _local29 = _local14 - _local6;
var _local28 = _local13 - _local7;
centerBar._rotation = Math.atan2(_local28, _local29) * 57.2957795;
centerBar._xscale = Math.max(1, Math.sqrt((_local29 * _local29) + (_local28 * _local28)));
if (hoverTargetFront) {
hoverTargetFront._x = _local6;
hoverTargetFront._y = _local7;
var _local32 = Math.round((fuel / maxFuel) * 10) * 10;
if (_local32 != hoverTargetFront.guage.bar._yscale) {
hoverTargetFront.guage.bar._yscale = (hoverTargetTailF.guage.bar._yscale = (hoverTargetTailR.guage.bar._yscale = (fuel / maxFuel) * 100));
}
}
if (dispFront.x < 0) {
_local29 = _local18 - _local6;
_local28 = _local16 - _local7;
backBar._rotation = Math.atan2(_local28, _local29) * 57.2957795;
backBar._xscale = Math.max(1, Math.sqrt((_local29 * _local29) + (_local28 * _local28)));
_local29 = _local19 - _local6;
_local28 = _local17 - _local7;
frontBar._rotation = Math.atan2(_local28, _local29) * 57.2957795;
frontBar._xscale = Math.max(1, Math.sqrt((_local29 * _local29) + (_local28 * _local28)));
if (hoverTargetTailF) {
hoverTargetTailF._x = _local19;
hoverTargetTailF._y = _local17;
hoverTargetTailR._x = _local18;
hoverTargetTailR._y = _local16;
}
} else {
_local29 = _local18 - _local6;
_local28 = _local16 - _local7;
frontBar._rotation = Math.atan2(_local28, _local29) * 57.2957795;
frontBar._xscale = Math.max(1, Math.sqrt((_local29 * _local29) + (_local28 * _local28)));
_local29 = _local19 - _local6;
_local28 = _local17 - _local7;
backBar._rotation = Math.atan2(_local28, _local29) * 57.2957795;
backBar._xscale = Math.max(1, Math.sqrt((_local29 * _local29) + (_local28 * _local28)));
if (hoverTargetTailF) {
hoverTargetTailF._x = _local18;
hoverTargetTailF._y = _local16;
hoverTargetTailR._x = _local19;
hoverTargetTailR._y = _local17;
}
}
if (!standingEdge) {
if (dispFront.z > 0.01) {
mcCharacter.gotoAndStop(CENTER_VIEW + Math.round(NUMBER_OF_VIEWS * dispFront.x));
} else {
mcCharacter.gotoAndStop(((dispFront.x < 0) ? 1 : 9));
}
mcCharacter._y = dispFront.y * -18.75;
mcCharacter._rotation = ((Math.atan2(_local15.x, -_local15.y) * 180) / Math.PI) * 0.75;
} else {
mcCharacter._rotation = 0;
if (dispFront.z > 0.01) {
mcCharacter.gotoAndStop(10 + (CENTER_VIEW + Math.round(NUMBER_OF_VIEWS * dispFront.x)));
} else {
mcCharacter.gotoAndStop(10 + ((dispFront.x < 0) ? 1 : 9));
}
mcCharacter._y = 0;
}
oldDX = direction.x;
}
function updatePosition(elapsed, x, y, space) {
if ((keyX != x) || (keyY != y)) {
if (x) {
direction.x = x;
}
direction.y = y;
direction.normalize();
keyX = x;
keyY = y;
}
if (standingEdge) {
if (space) {
velocity.x = standingEdge.normal.x * pushOffStrength;
velocity.y = standingEdge.normal.y * pushOffStrength;
standingEdge = null;
} else {
velocity.x = 0;
velocity.y = 0;
}
return(undefined);
}
if (this.y > -50) {
var _local6;
_local6 = -300 * elapsed;
velocity.y = velocity.y + _local6;
externalForces.y = externalForces.y + (_local6 * 20);
}
if (this.x < 0) {
var _local7;
direction.x = 1;
_local7 = 300 * elapsed;
velocity.x = velocity.x + _local7;
externalForces.x = externalForces.x - (_local7 * 20);
}
approach = approach + ((((Math.atan2(direction.x, -direction.y) / 1.5707963267949 /* Math.PI/2 */) - approach) * elapsed) * 4);
lift = lift + ((Math.abs(approach) - lift) * elapsed);
var _local9 = velocity.__get__length();
var _local3 = 190;
var _local4 = new Vector(((_local3 * Math.abs(approach)) * direction.x) - velocity.x, (((lift * (-_local3)) + ((_local3 * Math.abs(approach)) * direction.y)) + 200) - velocity.y, 0);
velocity.x = velocity.x + ((_local4.x * elapsed) * 2);
velocity.y = velocity.y + ((_local4.y * elapsed) * 2);
}
function checkCollisions(elapsed) {
var _local7 = getTimer();
motionTime = elapsed;
if (velocity.__get__length() < 0.01) {
velocity.x = 0;
velocity.y = 0;
return(undefined);
}
motionVec = new Vector(velocity.x * elapsed, velocity.y * elapsed, velocity.z);
motionDist = motionVec.length;
motionDir = motionVec.getNormalized();
if (motionVec.x > 0) {
motionLeft = left;
motionRight = right + motionVec.x;
} else {
motionLeft = left + motionVec.x;
motionRight = right;
}
if (motionVec.y > 0) {
motionTop = top;
motionBottom = bottom + motionVec.y;
} else {
motionTop = top + motionVec.y;
motionBottom = bottom;
}
var _local4 = world.getSectors(Math.floor(motionLeft / SSGlobal.GRID_SIZE), Math.floor(motionTop / SSGlobal.GRID_SIZE), Math.floor(motionRight / SSGlobal.GRID_SIZE), Math.floor(motionBottom / SSGlobal.GRID_SIZE));
if (_local4.length == 1) {
var _local2 = _local4[0];
} else {
var _local2 = [];
var _local3 = _local4.length;
while (_local3-- , _local3 > -1) {
_local2.push.apply(_local2, _local4[_local3]);
}
}
var _local5 = checkCollisionList(_local2, 4294967295);
return(_local5);
}
function checkCollision(obj, flag, options) {
var _local2;
switch (obj.collisionMask & 4294901760) {
case SSGlobal.CLSID_SHAPE :
_local2 = SSCollision.sweepSphereToStaticShape(this, obj);
if (_local2) {
shapeCollision = true;
var _local4 = velocity.__get__length() * 0.8;
if ((((!hoverObject) && (_local2.edge.props & 65536)) && (_local2.normal.dot(Vector.VECNY) > 0.6)) && (_local4 < 100)) {
standingEdge = _local2.edge;
velocity.x = 0;
velocity.y = 0;
world.playEventSound(world.globalSounds, "thud");
} else {
if (_local4 > 100) {
world.playEventSound(world.globalSounds, "hardhit");
} else {
world.playEventSound(world.globalSounds, "thud");
}
var _local5 = motionDir.dot(_local2.normal);
velocity.x = (motionDir.x - ((_local2.normal.x * _local5) * 2)) * _local4;
velocity.y = (motionDir.y - ((_local2.normal.y * _local5) * 2)) * _local4;
}
moveTo(_local2.point.x, _local2.point.y, _local2.point.z);
return(true);
}
return(false);
case SSGlobal.CLSID_OBJECT :
if (checkObjectCollision(obj)) {
return(true);
}
return(false);
case SSGlobal.CLSID_COLLECTABLE :
if (obj.collected) {
return(false);
}
return(checkObjectCollectable(obj));
case SSGlobal.CLSID_OBSTACLE :
return(checkObjectObstacle(obj));
case SSGlobal.CLSID_ZONE :
if (!SSCollision.sweepSphereToSphere(this, obj, true)) {
break;
}
return(obj.onCollision(this));
}
}
function onSpring() {
world.playEventSound(charSounds, "spring");
}
function onTeleport() {
world.playEventSound(charSounds, "teleport");
}
function transportEffect(elapsed) {
target._visible = false;
update = updateTransEffect;
onDisplay = null;
}
function updateTransEffect(elapsed) {
var _local2;
_local2 = new SSParticle("shield", 0.2, new Vector(0, 0, -10), 0, 0);
world.addObject(_local2);
_local2.moveBy(x, y, z);
}
function endTransportEffect(elasped) {
delete onDisplay;
if (!inScene) {
addToScene();
}
var _local2;
_local2 = new SSParticle("largepuff", 1, new Vector(0, -40, -10), 0, 0);
world.addObject(_local2);
_local2.moveBy(x, y, z);
target._visible = true;
target._xscale = (target._yscale = 100);
}
function endLevel() {
}
function setTimelineMode(timeline) {
update = update_timeline;
}
function update_timeline(elapsed) {
}
function restoreDefaultMode() {
target._visible = true;
delete update;
}
function checkObjectObstacle(obj) {
switch (obj.collisionMask) {
case SSGlobal.CLSID_FLYING :
if (!obj.crossedZero) {
return(false);
}
var _local3 = new Vector(obj.x - x, obj.y - y, 0);
if (_local3.length < (radius + obj.radius)) {
obj.hitObject(this);
}
break;
case SSGlobal.CLSID_FLOATING :
if (!SSCollision.sweepSphereToSphere(this, obj, true)) {
break;
}
obj.hitObject(this);
}
}
function checkObjectCollectable(obj) {
if (SSCollision.sweepSphereToSphere(this, obj, true)) {
obj.setCollected(this);
}
}
function setInterface(ui) {
userDisplay = ui;
}
function shiftScore(value) {
score = score + (value * gamePointMultiplier);
userDisplay.setScore(score);
}
function onAllPointsCollected(obj) {
shiftScore(GameGlobal.ALL_POINTS_VALUE);
world.showPopup((GameGlobal.MSG_ALL_POINTS + (GameGlobal.ALL_POINTS_VALUE * gamePointMultiplier)) + " Points", 3);
}
function collectFlag() {
var _local2 = flags;
userDisplay.setFlags(++flags);
if ((_local2 < world.requiredFlags) && (flags >= world.requiredFlags)) {
world.openExit();
world.showPopup(GameGlobal.MSG_EXIT_OPEN, 3);
} else if (_local2 < world.requiredFlags) {
var _local4 = world.requiredFlags - flags;
var _local3 = ((_local4 > 1) ? "s" : "");
world.showPopup(((("You need " + (world.requiredFlags - flags)) + " more flag") + _local3) + " to open the exit!", 3);
} else if (flags == world.flagCount) {
shiftScore(GameGlobal.ALL_FLAGS_VALUE);
world.showPopup((GameGlobal.MSG_ALL_FLAGS + (GameGlobal.ALL_FLAGS_VALUE * gamePointMultiplier)) + " Points", 3);
}
}
function enableShield(value) {
hurtOffset = 0;
shield = value;
}
function shiftHealth(value) {
if (value < 0) {
if (shield > 0) {
} else {
hurtOffset = 1;
world.playEventSound(charSounds, "hurt");
health = Math.min(health + value, 1);
if (health <= 0) {
health = 0;
disableHoverCraft();
world.onLoseLife(this);
}
}
} else {
health = Math.min(health + value, 1);
}
userDisplay.setHealth(health);
}
function resetAfterLoseLife() {
userDisplay.setHealth((health = 1));
velocity.x = 0;
velocity.y = 0;
}
function shiftFuel(value) {
fuel = Math.max(Math.min(fuel + value, maxFuel), 0);
}
function checkObjectCollision(obj) {
if (!(obj.collisionMask === SSGlobal.CLSID_WIND)) {
} else {
var _local7 = new Vector(x - obj.x, y - obj.y, z - obj.z);
var _local5 = obj.direction.dot(_local7);
if ((_local5 < 0) || (_local5 > obj.strength)) {
return(false);
}
var _local6 = obj.direction.copy();
_local6.__set__length(_local5);
var _local4 = _local7.x - _local6.x;
var _local3 = _local7.y - _local6.y;
if (Math.sqrt((_local4 * _local4) + (_local3 * _local3)) > obj.halfWidth) {
return(false);
}
_local4 = obj.direction.x * obj.strength;
externalForces.x = externalForces.x + _local4;
_local3 = obj.direction.y * obj.strength;
externalForces.y = externalForces.y + _local3;
velocity.x = velocity.x + (_local4 * world.frameTime);
velocity.y = velocity.y + (_local3 * world.frameTime);
}
}
function enableHoverCraft(obj) {
if (hoverObject) {
hoverObject.reset();
}
direction.y = 0;
yDir = 0;
zDir = ((xDir < 0) ? Math.PI : 0);
drawGlider(world.viewport, 0.001);
fuel = obj.value;
updatePosition = updateHoverCraft;
onDisplay = hoverDisplay;
hoverObject = obj;
addHoverDisplay();
}
function disableHoverCraft() {
hoverObject.reset();
var _local2;
_local2 = new SSParticle("HoverRocket", 5, new Vector(velocity.x * 1.2, velocity.y * 1.2, 0), direction.x * 20, 400);
world.addObject(_local2);
_local2.alpha = false;
_local2.moveBy(x + hoverTargetFront._x, y + hoverTargetFront._y, 0);
_local2 = new SSParticle("HoverRocket", 5, new Vector(velocity.x * 0.5, velocity.y * 0.5, -80), direction.x * -20, 400);
world.addObject(_local2);
_local2.alpha = false;
_local2.moveBy(x + hoverTargetTailF._x, y + hoverTargetTailF._y, 0);
_local2 = new SSParticle("HoverRocket", 5, new Vector(velocity.x * 0.5, velocity.y * 0.5, 80), direction.x * -20, 400);
world.addObject(_local2);
_local2.alpha = false;
_local2.moveBy(x + hoverTargetTailR._x, y + hoverTargetTailR._y, z);
hoverTargetFront.removeMovieClip();
hoverTargetTailF.removeMovieClip();
hoverTargetTailR.removeMovieClip();
delete onDisplay;
delete updatePosition;
delete hoverObject;
}
function updateHoverCraft(elapsed, x, y, space) {
if (x) {
direction.x = x;
}
if (!((fuel = Math.max(fuel - elapsed, 0)))) {
disableHoverCraft();
}
var _local2;
if (x || (y)) {
_local2 = new Vector(x, y, 0);
_local2.normalize();
} else {
_local2 = Vector.ZERO;
}
var _local3 = new Vector((_local2.x * hoverSpeed) - velocity.x, (_local2.y * hoverSpeed) - velocity.y, 0);
velocity.x = velocity.x + (_local3.x * elapsed);
velocity.y = velocity.y + (_local3.y * elapsed);
}
function addHoverDisplay() {
hoverTargetFront = target.attachMovie("HoverRocket", "hdispf", 2001);
hoverTargetTailF = target.attachMovie("HoverRocket", "hdispns", 2000);
hoverTargetTailR = target.attachMovie("HoverRocket", "hdispfs", 1);
}
function hoverDisplay(viewport, elapsed) {
displayColors(viewport, elapsed);
drawGlider(viewport, elapsed);
}
var assetID = "HangGlider";
var mapIconID = "MapHangGlider";
var soundClipID = "CraverSounds";
var radius = 25;
var depthLayer = 4;
var collisionMask = SSGlobal.CLSID_GLIDER;
static var NUMBER_OF_VIEWS = 4;
static var CENTER_VIEW = 5;
var shapeCollision = false;
var standingTime = 0;
var standingTimePop = 5;
var keyX = 0;
var keyY = 0;
var normalSpeed = 1.5707963267949 /* Math.PI/2 */;
var approach = 1;
var lift = 1;
var pushOffStrength = 300;
var oldDX = 1;
var xDir = 1;
var yDir = 0;
var zDir = 0;
var air = 0;
var airAccel = 0;
var hurtOffset = 0;
static var normalTintOffset = new ColorTransformRGB(100, 100, 100, 0, 0, 0);
static var shieldTintOffset = new ColorTransformRGB(40, 40, 100, 60, 60, 255);
static var hurtTintOffset = new ColorTransformRGB(0, 0, 0, 255, 150, 100);
var oAirAccel = 0;
var transportAssetID = "GreenGlow";
var flags = 0;
var fuel = 0;
var maxFuel = SSGlobal.HOVER_CRAFT_FUEL;
var gameFlags = 0;
var health = 1;
var shield = 0;
var score = 0;
var gamePointMultiplier = 1;
var hoverSpeed = 200;
}
Symbol 699 MovieClip [__Packages.GameGlobal] Frame 0
class GameGlobal
{
function GameGlobal () {
}
static var MSG_STANDING = "Use Space Bar to jump!";
static var MSG_EXIT_OPEN = "Exit open! Reach it to finish the level!";
static var MSG_ALL_FLAGS = "You have collected all the flags in this area!\n";
static var MSG_ALL_POINTS = "You have collected all the Strawberry Blasted HoneyComb in this area!\n";
static var ALL_FLAGS_VALUE = 500;
static var ALL_POINTS_VALUE = 5000;
}
Symbol 700 MovieClip [__Packages.SSShapeEdge] Frame 0
class SSShapeEdge
{
var a, b;
function SSShapeEdge (a, b) {
this.a = a;
this.b = b;
}
function toString() {
return((a + " -> ") + b);
}
var radius = 0;
var props = SSGlobal.EDGE_DEFAULT;
var length = 0;
var angle = 0;
}
Symbol 701 MovieClip [__Packages.SSShapeVertex] Frame 0
class SSShapeVertex extends Vector
{
var x, y, z;
function SSShapeVertex (x, y, props) {
super();
this.x = x;
this.y = y;
this.props = props;
}
function toString() {
return(((((("ShapeVert (" + x) + ",") + y) + ",") + z) + ")");
}
var props = SSGlobal.EDGE_DEFAULT;
var scale = 0;
}
Symbol 702 MovieClip [__Packages.SSCollision] Frame 0
class SSCollision
{
var point, normal, edge, time;
function SSCollision (point, normal, time, edge) {
this.point = point;
this.normal = normal;
this.edge = edge;
this.time = time;
}
static function sweepSphereToStaticShape(sphere, shape, noData) {
if ((((sphere.motionLeft > shape.right) || (sphere.motionRight < shape.left)) || (sphere.motionTop > shape.bottom)) || (sphere.motionBottom < shape.top)) {
return(undefined);
}
var _local25 = shape.edges;
var _local22 = _local25.length;
var _local15 = sphere.motionVec;
var _local14 = sphere.motionDir;
var _local4 = sphere.motionDist;
var _local5 = sphere.radius;
var _local21;
var _local12;
var _local20;
var _local7 = Number.MAX_VALUE;
var _local13 = new Vector(sphere.x - shape.x, sphere.y - shape.y);
var _local1;
var _local8;
var _local23;
while (_local22-- , _local22 > -1) {
_local1 = _local25[_local22];
if (!(_local1.props & 1)) {
continue;
}
if (_local14.dot(_local1.normal) >= 0) {
continue;
}
var _local16 = _local1.a;
_local8 = new Vector(_local1.center.x - _local13.x, _local1.center.y - _local13.y, 0);
if (((_local8.length - _local5) - _local4) > _local1.radius) {
continue;
}
var _local3 = new Vector(_local13.x - _local16.x, _local13.y - _local16.y);
var _local18 = _local3.dot(_local1.normal);
if ((_local18 < 0) || ((_local18 - _local4) > _local5)) {
continue;
}
var _local17 = new Vector(_local3.x - (_local1.normal.x * _local5), _local3.y - (_local1.normal.y * _local5));
var _local9 = _local1.span;
var _local6 = ((_local15.x * (-_local17.y)) - (_local15.y * (-_local17.x))) / ((_local15.y * _local9.x) - (_local15.x * _local9.y));
var _local2;
if ((_local6 >= 0) && (_local6 <= 1)) {
var _local10 = new Vector((_local9.x * _local6) + (_local1.normal.x * _local5), (_local9.y * _local6) + (_local1.normal.y * _local5));
var _local19 = new Vector(_local10.x - _local3.x, _local10.y - _local3.y);
_local2 = _local19.length;
if (_local2 <= _local4) {
if (_local7 < (_local2 / _local4)) {
continue;
}
_local12 = _local10;
_local7 = _local2 / _local4;
if (_local7 < 0.001) {
_local7 = 0;
_local10.x = _local3.x;
_local10.y = _local3.y;
}
_local21 = _local1.normal;
_local20 = _local1;
}
} else {
var _local10 = ((_local6 > 1) ? (_local1.span) : (Vector.ZERO));
_local23 = new Vector(_local10.x - _local3.x, _local10.y - _local3.y);
_local8 = _local23.length;
var _local11 = _local23.dot(_local14);
_local2 = (_local5 * _local5) - ((_local8 * _local8) - (_local11 * _local11));
if ((_local2 > 0) && ((_local2 = _local11 - Math.sqrt(_local2)) < _local4)) {
if ((_local7 < (_local2 / _local4)) || ((_local2 / _local4) < 0)) {
continue;
}
_local7 = _local2 / _local4;
_local20 = _local1;
_local12 = new Vector(_local3.x + (_local2 * _local14.x), _local3.y + (_local2 * _local14.y), 0);
_local21 = new Vector(_local12.x - _local10.x, _local12.y - _local10.y, 0);
_local21.normalize();
}
}
}
if (_local20) {
_local12.x = _local12.x + (shape.x + _local20.a.x);
_local12.y = _local12.y + (shape.y + _local20.a.y);
return(new SSCollision(_local12, _local21, _local7, _local20));
}
return(null);
}
static function sweepSphereToSphere(obj, sphObj, noData) {
var _local5 = obj.radius + sphObj.radius;
var _local7;
var _local4;
var _local2;
var _local3;
_local7 = new Vector(sphObj.x - obj.x, sphObj.y - obj.y, 0);
_local4 = _local7.length;
if (obj.motionDist < (_local4 - _local5)) {
return(false);
}
_local2 = _local7.dot(obj.motionDir);
if (_local2 < 0) {
return(false);
}
_local3 = (_local5 * _local5) - ((_local4 * _local4) - (_local2 * _local2));
if (((_local3 <= 0) || ((_local3 = _local2 - Math.sqrt(_local3)) > obj.motionDist)) || (_local3 < 0)) {
return(undefined);
}
if (noData) {
return(true);
}
return(false);
}
}
Symbol 703 MovieClip [__Packages.SSShape] Frame 0
class SSShape extends SSObject
{
var name, style, points, world, leftSector, left, leftShape, x, topSector, top, topShape, y, rightSector, right, rightShape, bottomSector, bottom, bottomShape, removeFromSectorGrid, addToSectorGrid, edges, drawStyle, inScene, removeDisplay, addDisplay, target, instances, normals;
function SSShape (name, style) {
super();
if (isInstance || (arguments.length < 1)) {
return;
}
if (name != null) {
this.name = name;
}
this.style = style;
var _local5 = arguments.splice(2);
points = [];
var _local4 = _local5.length;
while (_local4-- , _local4 > -1) {
_local4--;
_local4--;
points.push(new SSShapeVertex(_local5[_local4], _local5[_local4], _local5[_local4]));
}
build();
}
function onAddToWorld() {
if (name != null) {
if (!world.shapes[name]) {
world.shapes[name] = this;
} else if (!isInstance) {
}
}
}
function updateBounds() {
var _local2 = leftSector != ((leftSector = Math.floor(((left = x + leftShape)) / SSGlobal.GRID_SIZE)));
var _local3 = topSector != ((topSector = Math.floor(((top = y + topShape)) / SSGlobal.GRID_SIZE)));
var _local4 = rightSector != ((rightSector = Math.floor(((right = x + rightShape)) / SSGlobal.GRID_SIZE)));
var _local5 = bottomSector != ((bottomSector = Math.floor(((bottom = y + bottomShape)) / SSGlobal.GRID_SIZE)));
if (((_local2 || (_local3)) || (_local4)) || (_local5)) {
removeFromSectorGrid();
addToSectorGrid();
}
}
function build() {
var _local9 = points.length;
var _local2;
var _local3;
var _local4;
var _local8;
var _local6;
var _local7;
var _local5;
_local6 = points[0].x;
_local8 = _local6;
_local5 = points[0].y;
_local7 = _local5;
edges = [new SSShapeEdge(points[0], points[_local9 - 1])];
while (_local9-- , _local9 > 0) {
edges[_local9] = new SSShapeEdge(points[_local9], points[_local9 - 1]);
edges[_local9].next = edges[_local9 + 1];
edges[_local9 + 1].prev = edges[_local9];
_local8 = Math.min(points[_local9].x, _local8);
_local6 = Math.max(points[_local9].x, _local6);
_local7 = Math.min(points[_local9].y, _local7);
_local5 = Math.max(points[_local9].y, _local5);
}
leftShape = _local8;
rightShape = _local6;
topShape = _local7;
bottomShape = _local5;
edges[0].prev = edges[edges.length - 1];
edges[0].next = edges[1];
edges[edges.length - 1].next = (edges[1].prev = edges[0]);
_local9 = edges.length;
while (_local9-- , _local9 > -1) {
_local2 = edges[_local9];
_local3 = _local2.a;
_local4 = _local2.b;
_local2.center = new Vector(_local3.x + ((_local4.x - _local3.x) * 0.5), _local3.y + ((_local4.y - _local3.y) * 0.5));
_local2.radius = 0.5 * ((_local2.length = ((_local2.span = new Vector(_local4.x - _local3.x, _local4.y - _local3.y))).length));
_local2.direction = _local2.span.getNormalized();
_local2.normal = _local2.direction.cross();
_local2.angle = Math.atan2(_local2.direction.y, _local2.direction.x);
_local2.props = _local4.props;
}
_local9 = edges.length;
while (_local9-- , _local9 > -1) {
_local2 = edges[_local9];
((_local2.a.normal = new Vector(_local2.next.normal.x + _local2.normal.x, _local2.next.normal.y + _local2.normal.y))).normalize();
_local2.a.scale = 1 / _local2.a.normal.dot(_local2.normal);
}
drawStyle = new this.style(points, edges);
if (inScene) {
redraw();
}
}
function redraw() {
removeDisplay();
addDisplay();
}
function onAddToScene() {
}
function onAddDisplay() {
drawStyle.draw(target);
}
function editor_onExport(obj, out) {
var _local2 = obj.props.values;
out.push(_local2[0], _local2[1]);
_local2 = obj.points;
var _local1 = _local2.length;
while (_local1-- , _local1 > -1) {
out.push(_local2[_local1].x, _local2[_local1].y, _local2[_local1].props);
}
}
function editor_onAddToDocument(doc, cn, args) {
name = args[0];
drawStyle = args[1];
var _local3 = args.splice(2);
var _local2 = _local3.length;
instances = [];
points = [];
while (_local2-- , _local2 > -1) {
_local2--;
_local2--;
points.push(new SSShapeVertex(_local3[_local2], _local3[_local2], _local3[_local2]));
}
_local2 = points.length - 1;
var _local4;
_local4 = new Vector(points[_local2].x - points[0].x, points[_local2].y - points[0].y).cross();
normals = [_local4];
_local4.normalize();
while (_local2-- , _local2 > -1) {
_local4 = new Vector(points[_local2].x - points[_local2 + 1].x, points[_local2].y - points[_local2 + 1].y).cross();
_local4.normalize();
normals.push(_local4);
}
normals.reverse();
}
function editor_display() {
target.clear();
target.beginFill(10066329, 20);
target.moveTo(points[0].x, points[0].y);
var _local2 = points.length;
while (_local2-- , _local2 > -1) {
target.lineStyle(0, (points[_local2].props ? 16711680 : 8947848));
target.lineTo(points[_local2].x, points[_local2].y);
}
target.endFill();
target.lineStyle(0, 3368703);
_local2 = points.length;
while (_local2-- , _local2 > -1) {
target.moveTo(points[_local2].x, points[_local2].y);
target.lineTo(points[_local2].x + (normals[_local2].x * 50), points[_local2].y + (normals[_local2].y * 50));
}
_local2 = instances.length;
while (_local2-- , _local2 > -1) {
instances.display();
}
}
function editor_onPropsShow(target, obj, props) {
var _local3 = obj.points;
var _local1 = -1;
var _local4 = _local3.length;
while (_local1++ , _local1 < _local4) {
props.propIndex++;
props.values[props.propIndex] = _local3[_local1].props > 0;
props.addItem(target, "CheckBox", ("Edge #" + _local1) + " Visible", "boolean", _local3[_local1].props > 0, null, true);
}
}
function editor_onPropsChange(obj, props) {
var _local3 = obj.props.values;
var _local2 = _local3.length;
while (_local2-- , _local2 > 1) {
obj.points[_local2 - 2].props = (_local3[_local2] ? 65537 : 0);
}
obj.display();
}
var isInstance = false;
var assetID = null;
var depthLayer = 0;
var className = "Shape";
var setShape = Object.prototype.constructor;
var collisionMask = SSGlobal.CLSID_SHAPE;
var editor_defaultValues = ["name", "DSGeneric"];
var editor_argNames = ["#name", "drawStyle"];
var editor_defaultTypes = ["string", "string"];
var editor_options = [null, SSGlobal.editor_DrawStyles];
var editor_component = ["TextInput", "ComboBox"];
}
Symbol 704 MovieClip [__Packages.Collectable] Frame 0
class Collectable extends SSObject
{
var setAssetID, award, assetID, inScene, removeDisplay, addDisplay, onReset;
function Collectable () {
super();
}
function setCollected(obj) {
if (collected) {
return(undefined);
}
collected = true;
setAssetID(null);
award(obj);
}
function reset() {
collected = false;
delete assetID;
if (inScene) {
removeDisplay();
addDisplay();
}
onReset();
}
var collected = false;
var collisionMask = SSGlobal.CLSID_COLLECTABLE;
var radius = 20;
var value = 0;
}
Symbol 705 MovieClip [__Packages.GDK.World] Frame 0
class GDK.World extends GDK.Generic
{
var uniqueID, children, objects, updateList, displayQueue, name, viewport, world, engine, target, onUpdate, inScene, addDisplay, onAddToScene, removeChild;
function World (name, viewPort) {
super();
uniqueID = ++worldsCreated;
children = null;
objects = [];
updateList = new GDK.Collection();
displayQueue = [];
this.name = ((name != null) ? (name) : ("World " + uniqueID));
if (viewport) {
addObject(viewport);
} else if (useDefaultCamera) {
addObject((viewport = new GDK.Viewport()));
}
world = this;
}
function addToUpdateList(obj) {
return(updateList.addMember(obj));
}
function removeFromUpdateList(obj) {
return(updateList.removeMember(obj));
}
function sendUpdates(elapsed) {
updateList.update(elapsed);
}
function render(elapsed) {
var _local2;
_local2 = displayQueue.length;
if (!_local2) {
return(undefined);
}
while (_local2-- , _local2 > -1) {
displayQueue[_local2].setDisplay(elapsed);
delete displayQueue[_local2].queueForDisplay;
}
displayQueue = [];
updateAfterEvent();
}
function centerViewport(vertical, horizontal) {
viewport.halfWidth = (target._x = ((viewport.screenWidth = engine.width)) * 0.5);
viewport.halfHeight = (target._y = ((viewport.screenHeight = engine.height)) * 0.5);
}
function queueForDisplay(obj) {
if (!obj.queueForDisplay) {
return(undefined);
}
obj.queueForDisplay = null;
displayQueue.push(obj);
}
function update(elapsed) {
sendUpdates(elapsed);
onUpdate(elapsed);
render(elapsed);
}
function addObject(obj, isolated) {
if (obj.world == this) {
return(false);
}
if (obj.world) {
obj.world.removeObject(obj);
}
obj.world = this;
obj.uniqueID = objectsAdded++;
if (obj.children.length) {
var _local4 = obj.children.length;
while (_local4-- , _local4 > -1) {
addObject(obj.children[_local4], true);
}
}
if ((!obj.rogueNode) && (!isolated)) {
super.addChild(obj, true);
}
obj.positionChanged(0, 0, 0);
obj.onAddToWorld();
return(true);
}
function addToScene() {
if (inScene) {
return(undefined);
}
inScene = true;
addDisplay();
target.swapDepths(uniqueID + 1);
onAddToScene();
if (children) {
var _local2 = children.length;
while (_local2-- , _local2 > -1) {
if (children[_local2].inScene) {
children[_local2].removeFromScene();
children[_local2].addToScene();
}
}
}
}
function removeObject(obj) {
obj.removeFromScene();
removeChild(obj);
GDK.Collection.removeFromAll(obj);
removeFromUpdateList(obj);
obj.onRemoveFromWorld();
obj.__proto__ = null;
}
function addChild(obj, isolated) {
super.addChild(obj, true);
}
function timelineUpdate(elapsed) {
render(elapsed);
}
static var worldsCreated = -1;
var assetID = null;
var className = "World";
var useDefaultCamera = true;
var isDisplayNode = true;
var renderable = true;
var affectChildren = false;
var objectsAdded = 0;
}
Symbol 706 MovieClip [__Packages.GDK.Collection] Frame 0
class GDK.Collection extends Array
{
var id, push, length, splice;
function Collection () {
super();
Collections[(id = ++created)] = this;
}
static function removeFromAll(obj) {
var _local1;
_local1 = obj.__col;
if (!_local1) {
return(undefined);
}
for (var _local3 in _local1) {
Collections[_local3].removeMember(obj);
}
}
static function removeAll() {
}
function addMember(obj) {
if (obj.__col[id]) {
return(false);
}
push(obj);
if (!obj.__col) {
obj.__col = {count:0};
}
obj.__col[id] = true;
obj.__col.count++;
return(true);
}
function removeMember(obj) {
if (!obj.__col[id]) {
return(false);
}
var _local2 = length;
while (_local2-- , _local2 > -1) {
if (this[_local2] == obj) {
splice(_local2, 1);
break;
}
}
if (!(--obj.__col.count)) {
delete obj.__col;
} else {
delete obj.__col[id];
}
delete this[length];
return(true);
}
function update(elapsed) {
var _local2 = length;
while (_local2-- , _local2 > -1) {
this[_local2].update(elapsed);
}
}
function send(sID) {
var _local4 = arguments.splice(1);
var _local3 = length;
while (_local3-- , _local3 > -1) {
this[_local3][sID].apply(this[_local3], _local4);
}
}
static var Collections = [];
static var created = 0;
}
Symbol 707 MovieClip [__Packages.GDK.Group] Frame 0
class GDK.Group extends GDK.Node
{
function Group () {
super();
}
var className = "Group";
var renderable = false;
var setDisplay = null;
}
Symbol 708 MovieClip [__Packages.GDK.Viewport] Frame 0
class GDK.Viewport extends GDK.Group
{
function Viewport () {
super();
}
var screenWidth = 0;
var screenHeight = 0;
var halfWidth = 0;
var halfHeight = 0;
var changed = false;
var className = "Camera";
var renderable = false;
}
Symbol 709 MovieClip [__Packages.SSWorld] Frame 0
class SSWorld extends GDK.World
{
var sectors, name, viewport, backgrounds, shapes, target, objectsAdded, sendUpdates, onUpdate, displayQueue, engine, onSSAddToScene, soundContainer, soundObject, initSound, inScene;
function SSWorld (name) {
super();
sectors = {};
if (name) {
this.name = name;
}
viewport = new SSViewport();
backgrounds = new GDK.Collection();
shapes = {};
}
function addBackground(bg) {
bg.world = (bg.parent = this);
bg.displayNode = target;
bg.uniqueID = objectsAdded++;
backgrounds.addMember(bg);
}
function update(elapsed) {
time = time + elapsed;
sendUpdates(elapsed);
onUpdate(elapsed);
updateViewport(elapsed);
if (viewport.sectorChanged) {
cleanScene();
}
render(elapsed);
}
function cleanScene() {
var _local6 = [];
viewport.sectorChanged = false;
var _local7 = sectorsWide;
var _local3;
var _local10 = sectorsTotal;
while (_local10-- , _local10 > -1) {
_local3 = sectors[leftSector + (_local10 % _local7)][topSector + Math.floor(_local10 / _local7)];
if (_local3) {
_local3._s = -1;
_local6.push(_local3);
}
}
_local7 = (sectorsWide = ((rightSector = viewport.rightSector)) - ((leftSector = viewport.leftSector)));
_local10 = (sectorsTotal = _local7 * (((bottomSector = viewport.bottomSector)) - ((topSector = viewport.topSector))));
while (_local10-- , _local10 > -1) {
_local3 = sectors[leftSector + (_local10 % _local7)][topSector + Math.floor(_local10 / _local7)];
if (_local3) {
if (!_local3._s) {
_local3._s = 1;
_local6.push(_local3);
} else {
_local3._s = 0;
}
}
}
_local10 = _local6.length;
var _local9 = [];
var _local4;
var _local2;
var _local8;
var _local5;
while (_local10-- , _local10 > -1) {
_local8 = _local6[_local10];
_local5 = _local8.length;
_local4 = _local8._s;
while (_local5-- , _local5 > -1) {
_local2 = _local8[_local5];
if (_local2._s == null) {
_local2._s = _local4;
_local9.push(_local2);
} else if (_local4 > _local2._s) {
_local2._s = _local4;
}
}
delete _local6[_local10]._s;
}
_local10 = _local9.length;
while (_local10-- , _local10 > -1) {
_local2 = _local9[_local10];
if (_local2._s < 0) {
_local2.removeFromScene();
} else if (_local2._s > 0) {
_local2.addToScene();
}
delete _local2._s;
}
}
function render(elapsed) {
if (!displayQueue.length) {
return(undefined);
}
if (viewport.changed) {
target._x = Math.round(-viewport.x);
target._y = Math.round(-viewport.y);
var _local2 = backgrounds.length;
while (_local2-- , _local2 > -1) {
backgrounds[_local2].setDisplay(viewport);
}
}
var _local3 = (viewport.wTan * 1) / viewport.focusDepth;
var _local2 = displayQueue.length;
while (_local2-- , _local2 > -1) {
displayQueue[_local2].setDisplay(viewport, elapsed, _local3);
delete displayQueue[_local2].queueForDisplay;
}
displayQueue = [];
viewport.changed = false;
updateAfterEvent();
}
function getSectors(l, t, r, b) {
var _local6 = sectors;
var _local3;
_local3 = (r - l) + 1;
var _local2 = _local3 * ((b - t) + 1);
var _local4;
r = [];
while (_local2-- , _local2 > -1) {
_local4 = _local6[l + (_local2 % _local3)][t + Math.floor(_local2 / _local3)];
if (_local4) {
r.push(_local4);
}
}
return(r);
}
function updateViewport(elapsed) {
viewport.update(elapsed);
}
function onAddToScene() {
target._visible = true;
viewport.screenWidth = engine.width;
viewport.screenHeight = engine.height;
viewport.world = this;
viewport.onAddToWorld();
var _local2 = backgrounds.length;
while (_local2-- , _local2 > -1) {
backgrounds[_local2].addDisplay();
backgrounds[_local2].setDisplay(viewport);
}
onSSAddToScene();
}
function onAddDisplay() {
soundContainer = target.createEmptyMovieClip("SoundContainer", -1200);
soundObject = new Sound(soundContainer);
initSound();
}
function removeFromScene() {
target._visible = false;
inScene = false;
for (var _local2 in soundContainer) {
soundContainer[_local2].sound.stop();
}
}
function createSound(id, linkageID) {
if (linkageID != null) {
var _local2 = soundContainer.attachMovie(linkageID, id, ++soundsCreated);
} else {
var _local2 = soundContainer.createEmptyMovieClip(id, ++soundsCreated);
}
var _local3 = new Sound(_local2);
_local2.sound = _local3;
return(_local2);
}
function muteSounds() {
soundObject.setVolume(muteVolume);
}
function unmuteSounds() {
soundObject.setVolume(normalVolume);
}
function deleteSound(id) {
soundContainer[id].sound.stop();
soundContainer[id].removeMovieClip();
}
function playEventSound(id, name) {
if (id.sound) {
var _local2 = id;
} else {
var _local2 = soundContainer[id];
}
_local2.gotoAndStop(name);
_local2.nextFrame();
}
var useDefaultCamera = false;
var updateID = 0;
var time = 0;
var levelLeft = 0;
var levelTop = 0;
var levelRight = 0;
var levelBottom = 0;
var leftSector = 0;
var rightSector = 0;
var topSector = 0;
var bottomSector = 0;
var sectorsWide = 0;
var sectorsTotal = 0;
var soundsCreated = 0;
var normalVolume = 100;
var muteVolume = 0;
}
Symbol 710 MovieClip [__Packages.SSViewport] Frame 0
class SSViewport extends GDK.Viewport
{
var camOffset, focusDepth, wTan, hTan, changed, x, y, watch, moveTo;
function SSViewport () {
super();
}
function onAddToWorld() {
halfWidth = screenWidth * 0.5;
halfHeight = screenHeight * 0.5;
camOffset = new Vector();
setFieldOfView(FOV);
focusDepth = -((wTan = halfWidth / tanFOV));
hTan = halfHeight / tanFOV;
}
function onMove() {
changed = true;
right = ((left = x - halfWidth)) + screenWidth;
bottom = ((top = y - halfHeight)) + screenHeight;
var _local2 = leftSector != ((leftSector = Math.floor((left / SSGlobal.GRID_SIZE) - 0.5)));
var _local3 = topSector != ((topSector = Math.floor((top / SSGlobal.GRID_SIZE) - 0.5)));
var _local4 = rightSector != ((rightSector = Math.ceil((right / SSGlobal.GRID_SIZE) + 0.5)));
var _local5 = bottomSector != ((bottomSector = Math.ceil((bottom / SSGlobal.GRID_SIZE) + 0.5)));
if (((_local2 || (_local3)) || (_local4)) || (_local5)) {
sectorChanged = true;
}
}
function setFieldOfView(angle) {
if (FOV - angle) {
tanFOV = Math.tan(((FOV = angle)) * 0.008726646);
focusDepth = -((wTan = halfWidth / tanFOV));
hTan = halfHeight / tanFOV;
}
}
function update(elapsed) {
if (!watch) {
return(undefined);
}
var _local2 = watch.velocity.getNormalized();
camOffset.x = camOffset.x + ((((_local2.x * 125) - camOffset.x) * elapsed) * 0.5);
camOffset.y = camOffset.y + ((((_local2.y * 50) - camOffset.y) * elapsed) * 0.5);
moveTo(watch.x + camOffset.x, watch.y + camOffset.y, focusDepth);
}
var leftSector = 0;
var rightSector = 0;
var topSector = 0;
var bottomSector = 0;
var left = 0;
var right = 0;
var top = 0;
var bottom = 0;
var screenWidth = 0;
var screenHeight = 0;
var halfWidth = 0;
var halfHeight = 0;
var FOV = 30;
var tanFOV = 0.577350269189626;
var viewDistance = 100;
var sectorChanged = false;
var assetID = null;
}
Symbol 711 MovieClip [__Packages.SSBackground] Frame 0
class SSBackground extends SSObject
{
var tileID, z, pattern, target, oz, depth, uniqueID, depthLayer, world, leftGrid, rightGrid, topGrid, bottomGrid, tiles;
function SSBackground (tileID, depth, tileWidth, tileHeight, scrollMultiplier) {
super();
if (tileID != null) {
this.tileID = tileID;
}
z = (depth ? (depth) : 20);
this.tileWidth = tileWidth;
this.tileHeight = tileHeight;
this.scrollMultiplier = (scrollMultiplier ? (scrollMultiplier) : 1);
}
function queueForDisplay() {
}
function setPattern(g) {
pattern = g;
}
function onAddDisplay() {
if (stationary) {
target.attachMovie(tileID, "bg0", 0);
}
}
function setDisplay(viewport) {
if (oz != ((oz = Math.floor(z - viewport.z)))) {
target.swapDepths((depth = ((Math.floor((20000 - z) - viewport.z) * 32768) + (depthLayer * 4096)) + uniqueID));
}
if (stationary) {
target._x = -world.target._x;
target._y = -world.target._y;
return(undefined);
}
var _local11 = Math.round((-world.target._x) - ((x = ((viewport.wTan * (viewport.x * scrollMultiplier)) / (z - viewport.z)) + offsetX)));
var _local9 = Math.round((-world.target._y) - ((y = ((viewport.wTan * (viewport.y * scrollMultiplier)) / (z - viewport.z)) + offsetY)));
target._x = _local11;
target._y = _local9;
left = x;
right = x + viewport.screenWidth;
top = y;
bottom = y + viewport.screenHeight;
var _local7 = leftGrid != ((leftGrid = Math.floor(left / tileWidth)));
var _local10 = rightGrid != ((rightGrid = Math.ceil(right / tileWidth)));
var _local8 = topGrid != ((topGrid = Math.floor(top / tileHeight)));
var _local12 = bottomGrid != ((bottomGrid = Math.ceil(bottom / tileHeight)));
if ((((!_local7) && (!_local10)) && (!_local8)) && (!_local12)) {
return(undefined);
}
var _local2 = tiles.length;
while (_local2-- , _local2 > -1) {
tiles[_local2].removeMovieClip();
}
tiles = [];
var _local3;
var _local5 = rightGrid - leftGrid;
_local2 = _local5 * (bottomGrid - topGrid);
var x;
var y;
var _local4;
while (_local2-- , _local2 > -1) {
if (pattern && (!(_local4 = pattern.getCell((x = leftGrid + (_local2 % _local5)), -((y = topGrid + Math.floor(_local2 / _local5))))))) {
continue;
}
_local3 = target.attachMovie(tileID, "t" + _local2, _local2);
tiles.push(_local3);
_local3._x = x * tileWidth;
_local3._y = y * tileHeight;
_local3._debugInfo = (((("Frame: " + _local4) + "\nX: ") + x) + " Y: ") + y;
if (pattern) {
_local3.gotoAndStop(_local4);
}
}
}
function toString() {
return("Background " + uniqueID);
}
var autoAddToScene = false;
var scrollMultiplier = 1;
var stationary = false;
var assetID = null;
var tileWidth = 300;
var tileHeight = 300;
var className = "BG";
var left = 0;
var right = 0;
var top = 0;
var bottom = 0;
var offsetX = 0;
var offsetY = 0;
}
Symbol 712 MovieClip [__Packages.GDK.Grid] Frame 0
class GDK.Grid extends Array
{
var length;
function Grid (w, h, defaultValue) {
super();
setSize(((w == null) ? 0 : (w)), ((h == null) ? 0 : (h)), true);
if (defaultValue != null) {
this.defaultValue = defaultValue;
}
}
function get width() {
return(_width);
}
function set width(x) {
setSize(x, _height);
//return(width);
}
function get height() {
return(_height);
}
function set height(x) {
setSize(_width, x);
//return(height);
}
function setSize(w, h, noRebuild) {
if ((w == _width) && (h == _height)) {
return(false);
}
if ((h != null) && (h > 0)) {
_overflow = false;
setCell = setCell2D_Fixed;
getCell = getCell2D_Fixed;
_area = w * h;
if ((!noRebuild) && (_mode == 0)) {
}
_mode = 3;
} else {
_overflow = true;
if (x <= 0) {
setCell = setCell2D;
getCell = getCell2D;
if ((!noRebuild) && (_mode == 0)) {
}
_mode = 1;
} else {
delete setCell;
delete getCell;
if ((!noRebuild) && (_mode != 0)) {
}
_mode = 0;
}
}
_width = ((w <= 0) ? 0 : (w));
_height = ((h <= 0) ? 0 : (h));
return(true);
}
function setCell(w, v) {
this[w] = v;
}
function __resolve(v) {
return(defaultValue);
}
function getCell(w) {
return(((((value = this[w])) != null) ? (value) : (defaultValue)));
}
function setCell2D(w, h, val) {
if ((h != null) && (h < 0)) {
h = Math.floor(w / _width);
} else {
w = w + (h * _width);
}
if (h >= _height) {
_height = h + 1;
}
this[w] = val;
}
function getCell2D(w, h) {
if (h != null) {
return(this[w + (((h < 0) ? (_height + (h % _height)) : (h)) * _width)]);
}
return(this[w] % _width);
}
function setCell2D_Fixed(w, h, val) {
var _local3;
var _local2;
_local3 = w % _width;
_local2 = h % _height;
this[((_local3 < 0) ? (_width + _local3) : (_local3)) + (((_local2 < 0) ? (_height + _local2) : (_local2)) * _width)] = val;
}
function getCell2D_Fixed(x, y) {
if (((!repeatX) && (!((x > -1) && (x < _width)))) || ((!repeatY) && (!((y > -1) && (y < _height))))) {
return(defaultValue);
}
var _local3;
var _local2;
_local3 = x % _width;
_local2 = y % _height;
return(this[((_local3 < 0) ? (_width + _local3) : (_local3)) + (((_local2 < 0) ? (_height + _local2) : (_local2)) * _width)]);
}
function toString() {
var _local3 = "";
var _local2 = length;
_local2 = length;
while (_local2-- , _local2 > 0) {
_local3 = this[_local2] + _local3;
_local3 = (((_local2 % width) == 0) ? ",\n" : ",") + _local3;
}
if (length > 0) {
_local3 = this[0] + _local3;
}
return(_local3);
}
function copyFromArray(a) {
var _local2 = a.length;
while (_local2-- , _local2 > -1) {
this[_local2] = a[_local2];
}
}
var _overflow = true;
var defaultValue = null;
var _width = 0;
var _height = 0;
var _area = 0;
var repeatX = true;
var repeatY = true;
var _mode = 0;
}
Symbol 713 MovieClip [__Packages.GameWorld] Frame 0
class GameWorld extends SSWorld
{
var name, fuel, gamePoints, endObject, popup, onEndLevel, engine, globalSounds, createSound, musicClip, world;
function GameWorld (name) {
super();
if (name) {
this.name = name;
}
fuel = new GDK.Collection();
gamePoints = new GDK.Collection();
}
function openExit() {
endObject.setOpen();
}
function onUpdate(elapsed) {
if (popup) {
popup.update(elapsed);
}
}
function endLevel() {
onEndLevel();
engine.pause();
}
function onLoseLife(obj) {
engine.pause();
var _local3 = new CallStack();
_local3.call(_root, _root.fadeOut);
_local3.wait(1);
if ((--obj.lives) > 0) {
_local3.call(obj, obj.moveTo, obj.startX, obj.startY, 0);
_local3.call(obj, obj.resetAfterLoseLife);
_local3.wait(1);
_local3.call(engine, engine.resume);
_local3.call(_root, _root.fadeIn);
obj.userDisplay.setLives(obj.lives);
} else {
_local3.call(_root, _root.loseGame);
}
_local3.start();
}
function initSound() {
globalSounds = createSound("globalSounds", "globalSounds");
musicClip = createSound("music");
musicClip.sound.attachSound(musicID);
musicClip.sound.start(0, 1048575);
}
function gotoBonusRoom(obj) {
_root.gotoBonusRoom(obj);
}
function onSSAddToScene() {
if (startPopShown) {
return(undefined);
}
world.showPopup(((("Strawberry Blasted Honeycomb flags = " + flagCount) + ". Collect ") + requiredFlags) + " to open the exit! Collect them all for bonus points! Good Luck!", 5);
startPopShown = true;
}
function showPopup(text, time) {
if (popup) {
hidePopup();
}
var _local2 = (popup = new MessageDialog(engine, text, time));
_local2.target._x = engine.halfWidth - (_local2.width * 0.5);
_local2.target._y = engine.halfHeight * 0.25;
}
function hidePopup() {
popup.destroy();
popup = null;
}
var requiredFlags = 3;
var flagCount = 0;
var pointCount = 0;
var pointsCollected = 0;
var musicID = "music1";
var startPopShown = false;
}
Symbol 714 MovieClip [__Packages.LevelEnd] Frame 0
class LevelEnd extends SSObject
{
var world, zone, getUpdates, otherObj, timeline, target, x, y, z;
function LevelEnd () {
super();
}
function onAddToWorld() {
world.endObject = this;
world.addObject((zone = new SSZone(40, zone_onCollision, this)));
onMove();
}
function zone_onCollision(obj, zone) {
if (!isOpen) {
return(undefined);
}
getUpdates();
otherObj = obj;
obj.setTimelineMode();
var _local5 = (timeline = new Timeline.Timeline());
_local5.owner = this;
_local5.onStop = function () {
this.owner.cancelUpdates();
this.owner.world.endLevel();
delete this.owner.timeline;
};
var _local2;
var _local3 = _local5.newTrack(obj);
_local3.onUpdate = obj.timelineUpdate;
_local3.addScript(1, hideCharacter);
_local2 = _local3.prop("x");
_local2.kf(0, obj.x);
_local2.kf(1, zone.x);
_local2 = _local3.prop("y");
_local2.kf(0, obj.y);
_local2.kf(1, zone.y);
_local3 = _local5.newTrack(obj.target);
_local2 = _local3.prop("_yscale");
_local2.kf(0, 100, 1);
_local2.kf(1, 1);
_local2 = _local3.prop("_xscale");
_local2.kf(0, 100, 1);
_local2.kf(1, 1);
}
function hideCharacter() {
target._visible = false;
var _local2;
_local2 = new SSParticle("largepuff", 1, new Vector(0, -40, -10), 0, 0);
world.addObject(_local2);
_local2.moveBy(x, y, z);
}
function setOpen() {
isOpen = true;
onAddDisplay();
}
function onAddDisplay() {
target.gotoAndStop((isOpen ? 2 : 1));
}
function endLevel() {
world.endLevel();
}
function update(elapsed) {
timeline.update(elapsed);
}
function onMove() {
zone.moveTo(x, y - 100, z);
}
var isOpen = false;
var assetID = "Exit";
}
Symbol 715 MovieClip [__Packages.SSZone] Frame 0
class SSZone extends SSObject
{
var radius, collideEvent, owner, args;
function SSZone (radius, onCollision, ownerObject) {
super();
if (radius) {
this.radius = radius;
}
collideEvent = onCollision;
owner = ownerObject;
args = arguments.splice(3);
}
function onCollision(obj) {
collideEvent.call(owner, obj, this);
}
var collisionMask = SSGlobal.CLSID_ZONE;
var assetID = null;
}
Symbol 716 MovieClip [__Packages.Timeline.Shared] Frame 0
class Timeline.Shared extends Array
{
var length, parent, push, top, script;
function Shared () {
super();
}
function onDurationChange(newDur, oldDur) {
if ((oldDur == duration) || (newDur > duration)) {
if ((newDur > oldDur) || (length == 1)) {
parent.onDurationChange((duration = newDur), duration);
} else {
oldDur = duration;
var _local2 = length;
while (_local2-- , _local2 > -1) {
if (this[_local2].duration > duration) {
duration = this[_local2].duration;
}
}
if (oldDur != duration) {
parent.onDurationChange((duration = newDur), duration);
}
}
}
}
function newProperty(propname, type, min, max) {
var _local2 = new Timeline.Property(this, propname, type, min, max);
push(_local2);
this[propname] = _local2;
_local2.top = top;
return(_local2);
}
function removeProperty(propName) {
}
function addScript(time, method) {
if (!script) {
newProperty("script", Timeline.Property.SCRIPT);
}
var _local3 = script.newKeyFrame(time, method);
_local3.args = arguments.splice(2);
}
function removeScript(fromTime, toTime) {
}
var duration = 0;
var prop = Timeline.Shared.prototype.newProperty;
}
Symbol 717 MovieClip [__Packages.Timeline.Property] Frame 0
class Timeline.Property extends Array
{
var parent, name, type, applyValue, cxform, colorObj, valueRange, __proto__, length, splice, startKeyFrame, endKeyFrame, startValue, endValue, timeRange;
function Property (parent, name, type, min, max, setMethod, validateMethod) {
super();
this.parent = parent;
this.name = name;
if (typeof(type) == Function) {
this.type = CUSTOM;
applyValue = type;
} else {
switch (type) {
case BOOLEAN :
break;
case SCRIPT :
applyValue = CallScripts;
break;
case STRING :
break;
case COLORTINT :
cxform = new RGB();
colorObj = new Color(parent.target);
applyValue = ColorTransformValue;
break;
case COLORTRANSFORM :
valueRange = {};
cxform = {};
colorObj = new Color(parent.target);
applyValue = ColorTransformValue;
validateKeyframeValue = ColorTransformValidate;
break;
default :
if (min || (max)) {
if (min) {
this.min = min;
}
if (max) {
this.max = max;
}
applyValue = ClampedNumericValue;
} else {
applyValue = NumericValue;
}
}
}
}
function validateKeyframeValue(value) {
return(value);
}
function linkTo(otherProp) {
__proto__ = otherProp;
newKeyFrame = null;
}
function onKeyTimeChanged() {
}
function placeKeyFrame(kf) {
var _local3 = kf.time;
var _local2 = length;
do {
_local2--;
if (_local2 <= -1) {
break;
}
} while (this[_local2]._time >= _local3);
splice(_local2 + 1, 0, kf);
if ((_local2 + 2) == length) {
parent.onDurationChange((duration = this[length - 1]._time), duration);
}
}
function newKeyFrame(time, value, entry, exit) {
value = validateKeyframeValue(value);
var _local2 = new Timeline.KeyFrame(this, time, value, entry, exit);
placeKeyFrame(_local2);
return(_local2);
}
function seekTime(time) {
var _local2 = false;
while (startFrame < length) {
if (time >= this[startFrame + 1]._time) {
startFrame++;
_local2 = true;
} else {
break;
}
}
while (startFrame > -1) {
if (time < this[startFrame]._time) {
startFrame--;
_local2 = true;
} else {
break;
}
}
if (_local2) {
endFrame = startFrame + 1;
startKeyFrame = this[startFrame];
endKeyFrame = this[endFrame];
startValue = this[startFrame].value;
endValue = this[endFrame].value;
startTime = this[startFrame]._time;
timeRange = this[endFrame]._time - startTime;
return(true);
}
if (startValue == null) {
startValue = 0;
return(true);
}
return(false);
}
function ClampedNumericValue(time) {
return(Math.min(max, Math.max(100, min)));
}
function getTimeRatio(time) {
var _local2 = (time - startTime) / timeRange;
if (startKeyFrame.entry == 0) {
return(_local2);
}
var _local3 = startKeyFrame.entry;
return(((1 - _local3) * _local2) + ((_local3 * _local2) * _local2));
}
function NumericValue(target, time, elapsed) {
var _local2 = seekTime(time);
if (endFrame <= 0) {
if (_local2) {
_local2 = this[0].value;
target[name] = _local2;
}
} else if (endFrame >= length) {
if (_local2) {
_local2 = this[length - 1].value;
target[name] = _local2;
}
} else {
var _local3 = getTimeRatio(time);
if (!_local2) {
_local2 = startValue + (valueRange * _local3);
} else {
_local2 = startValue + (((valueRange = endValue - startValue)) * _local3);
}
target[name] = _local2;
}
}
function ColorTransformValue(target, time, elapsed) {
var _local3 = seekTime(time);
if (endFrame <= 0) {
_local3 = this[0].value;
} else if (endFrame >= length) {
_local3 = this[length - 1].value;
} else {
var _local2 = getTimeRatio(time);
if (!_local3) {
cxform.ra = startValue.ra + (valueRange.ra * _local2);
cxform.ga = startValue.ga + (valueRange.ga * _local2);
cxform.ba = startValue.ba + (valueRange.ba * _local2);
cxform.aa = startValue.aa + (valueRange.aa * _local2);
cxform.rb = startValue.rb + (valueRange.rb * _local2);
cxform.gb = startValue.gb + (valueRange.gb * _local2);
cxform.bb = startValue.bb + (valueRange.bb * _local2);
cxform.ab = startValue.ab + (valueRange.ab * _local2);
} else {
cxform.ra = startValue.ra + (((valueRange.ra = endValue.ra - startValue.ra)) * _local2);
cxform.ga = startValue.ga + (((valueRange.ga = endValue.ga - startValue.ga)) * _local2);
cxform.ba = startValue.ba + (((valueRange.ba = endValue.ba - startValue.ba)) * _local2);
cxform.aa = startValue.aa + (((valueRange.aa = endValue.aa - startValue.aa)) * _local2);
cxform.rb = startValue.rb + (((valueRange.rb = endValue.rb - startValue.rb)) * _local2);
cxform.gb = startValue.gb + (((valueRange.gb = endValue.gb - startValue.gb)) * _local2);
cxform.bb = startValue.bb + (((valueRange.bb = endValue.bb - startValue.bb)) * _local2);
cxform.ab = startValue.ab + (((valueRange.ab = endValue.ab - startValue.ab)) * _local2);
}
_local3 = cxform;
}
colorObj.setTransform(_local3);
}
function ColorTransformValidate(value) {
if (!value) {
return({ra:100, ga:100, ba:100, aa:100, rb:0, gb:0, bb:0, ab:0});
}
if (value.ra == null) {
value.ra = 100;
}
if (value.rb == null) {
value.rb = 0;
}
if (value.ga == null) {
value.ga = 100;
}
if (value.gb == null) {
value.gb = 0;
}
if (value.ba == null) {
value.ba = 100;
}
if (value.bb == null) {
value.bb = 0;
}
if (value.aa == null) {
value.aa = 100;
}
if (value.ab == null) {
value.ab = 0;
}
return(value);
}
function CallScripts(target, time, elapsed) {
var _local3 = endFrame;
var _local5 = startFrame;
seekTime(time);
if (_local5 != startFrame) {
if (endFrame > _local3) {
var _local2 = _local3;
while (_local2 < endFrame) {
this[_local2].value.apply(target, this[_local2].args);
_local2++;
}
} else {
while (_local3-- , _local3 >= endFrame) {
this[_local3].value.apply(target, this[_local2].args);
}
}
}
}
function toString() {
return("Property " + name);
}
function update(position, elapsed) {
}
static var CUSTOM = 0;
static var BOOLEAN = 1;
static var STRING = 2;
static var COLORTINT = 3;
static var COLORTRANSFORM = 4;
static var NUMBER = 5;
static var SCRIPT = 7;
static var FLASH_FRAME = 8;
static var SOUND = 9;
var max = Number.MAX_VALUE;
var min = Number.MIN_VALUE;
var duration = 0;
var kf = Timeline.Property.prototype.newKeyFrame;
var startFrame = -1;
var endFrame = 0;
var startTime = 0;
var endTime = 0;
var lastKnownTime = 0;
}
Symbol 718 MovieClip [__Packages.Timeline.KeyFrame] Frame 0
class Timeline.KeyFrame
{
var track, value;
function KeyFrame (track, time, value, entry, exit) {
this.track = track;
_time = time;
this.value = value;
if (entry) {
this.entry = entry;
}
if (exit) {
this.exit = exit;
}
}
function get time() {
return(_time);
}
function set time(v) {
_time = v;
track.onChanged();
//return(time);
}
function toString() {
return((("\nKey " + time) + " ") + value);
}
static var LINEAR = 0;
static var SMOOTH = 2;
static var CURVE = 3;
var _time = 0;
var entry = LINEAR;
var exit = LINEAR;
}
Symbol 719 MovieClip [__Packages.Timeline.Timeline] Frame 0
class Timeline.Timeline extends Timeline.Shared
{
var top, duration, lastTime, intervalID, callStack, onStop, push, length, onUpdate;
function Timeline () {
super();
top = this;
}
function play(checkChanges) {
if (playing) {
return(undefined);
}
if (position == duration) {
position = 0;
}
lastTime = getTimer() * 0.001;
playing = true;
intervalID = setInterval((callStack ? (callStackUpdate) : (intervalUpdate)), 0, this);
}
function stop() {
clearInterval(intervalID);
playing = false;
delete intervalID;
onStop();
}
function pause() {
paused = true;
}
function unpause() {
paused = false;
}
function gotoTime(newPos) {
time = newPos;
updateAfterEvent();
}
function addTrack(track) {
push(track);
track.parent = this;
track.top = top;
}
function newTrack(target) {
var _local2 = new Timeline.Track(target);
addTrack(_local2);
return(_local2);
}
function update(elapsed) {
var _local4 = time;
position = ((time = time + (elapsed * playSpeed))) % duration;
if (time >= duration) {
time = duration;
position = duration;
var _local3 = length;
while (_local3-- , _local3 > -1) {
this[_local3].update(position, elapsed);
}
stop();
} else {
var _local3 = length;
while (_local3-- , _local3 > -1) {
this[_local3].update(position, elapsed);
}
}
onUpdate(elapsed);
updateAfterEvent();
}
function callStackUpdate(tl) {
var _local2 = (-tl.lastTime) + ((tl.lastTime = getTimer() * 0.001));
if (tl.callStack.paused || (tl.paused)) {
return(false);
}
tl.update(_local2);
}
function intervalUpdate(tl) {
var _local2 = (-tl.lastTime) + ((tl.lastTime = getTimer() * 0.001));
if (tl.paused) {
return(false);
}
tl.update(_local2);
}
function addToCallStack(cs) {
callStack = cs;
cs.call(this, play);
cs.waitUntilEqual(this, "playing", false);
}
function toString() {
return("Timeline");
}
static var ONCE = 0;
static var FOREVER = Number.MAX_VALUE;
var playMode = ONCE;
var playSpeed = 1;
var playing = false;
var paused = false;
var time = 0;
var position = 0;
var changed = true;
}
Symbol 720 MovieClip [__Packages.Timeline.Track] Frame 0
class Timeline.Track extends Timeline.Shared
{
var target, name, targetProfile, length, onUpdate;
function Track (target, assetID) {
super();
this.target = target;
name = "Track " + (created++);
targetProfile = {};
}
function update(time, elapsed) {
var _local2 = length;
while (_local2-- , _local2 > -1) {
this[_local2].applyValue(target, time, elapsed);
}
onUpdate.apply(target);
}
function toString() {
return("Track for " + target);
}
static var created = 0;
}
Symbol 721 MovieClip [__Packages.CallStack] Frame 0
class CallStack extends Array
{
var push, lastTime, countdowntime, intervalID, splice, length;
function CallStack () {
super();
}
static function pauseAll() {
var _local1 = runningStacks.length;
while (_local1-- , _local1 > -1) {
runningStacks[_local1].pause();
}
return(false);
}
static function unpauseAll() {
var _local1 = runningStacks.length;
while (_local1-- , _local1 > -1) {
runningStacks[_local1].unpause();
}
}
static function stopAll() {
var _local1 = runningStacks.length;
while (_local1-- , _local1 > -1) {
runningStacks[_local1].stop();
}
return(false);
}
static function buildCall(target, method) {
var _local2 = arguments.splice(2);
_local2.target = target;
_local2.method = method;
return(_local2);
}
function call(target, method) {
push(buildCall.apply(this, arguments));
}
function wait(seconds) {
call(this, startCountDown, seconds);
}
function startCountDown(seconds) {
lastTime = getTimer() * 0.001;
countdowntime = seconds;
return(countdown);
}
function countdown() {
countdowntime = countdowntime + (lastTime - ((lastTime = getTimer() * 0.001)));
return(countdowntime <= 0);
}
function waitUntilEqual(target, property, targetValue) {
call(target, untilEqual, property, targetValue);
}
function untilEqual(property, targetValue) {
return(this[property] == targetValue);
}
function start() {
if (running) {
return(undefined);
}
running = true;
runningStacks.push(this);
index = 0;
intervalID = setInterval(function (o) {
o.update();
}, updateInterval, this);
}
function stop() {
clearInterval(intervalID);
var _local2 = runningStacks.length;
while (_local2-- , _local2 > -1) {
if (runningStacks[_local2] == this) {
runningStacks.splice(_local2, 1);
}
}
return(false);
}
function finish() {
stop();
}
function pause() {
paused = true;
return(false);
}
function unpause() {
paused = false;
}
function update() {
if (paused) {
return(false);
}
var _local3 = this[index];
var _local2 = _local3.method.apply(_local3.target, _local3);
switch (typeof(_local2)) {
case "function" :
_local3.method = _local2;
break;
case "object" :
if (_local2.className == "CallStack") {
splice(index, 1, buildCall(_local2, _local2.update));
} else if (_local2.length != null) {
splice(index, 1, _local2);
}
break;
default :
if (!(_local2 || (_local2 == null))) {
break;
}
if ((++index) > length) {
finish();
return(true);
}
break;
}
return(false);
}
function toString() {
return("Call Stack");
}
static var runningStacks = [];
var className = "CallStack";
var updateInterval = 0;
var paused = false;
var running = false;
var index = 0;
}
Symbol 722 MovieClip [__Packages.MessageDialog] Frame 0
class MessageDialog
{
var target, tfText, mcTL, mcT, mcTR, mcL, mcC, mcR, mcBL, mcB, mcBR;
function MessageDialog (owner, text, time) {
create(owner, text, time);
}
function create(owner, text, time) {
target = owner.attachMovie("MessageDialog", "MessageDialog" + (++created), 268435200 + created);
if (time) {
this.time = time;
}
tfText = target.tfText;
tfText.autoSize = "left";
mcTL = target.mcTL;
mcT = target.mcT;
mcTR = target.mcTR;
mcL = target.mcL;
mcC = target.mcC;
mcR = target.mcR;
mcBL = target.mcBL;
mcB = target.mcB;
mcBR = target.mcBR;
setText(text);
}
function setText(text) {
tfText.text = text;
setSize(tfText.textWidth, tfText.textHeight);
}
function destroy() {
target.swapDepths(1048575);
target.removeMovieClip();
}
function update(elapsed) {
if ((time > 0) && (((time = time - elapsed)) <= 0)) {
destroy();
}
}
function setSize(w, h) {
width = w;
height = h;
tfText._x = ((tfText.textWidth - tfText._width) * 0.5) + 1;
tfText._y = ((tfText.textHeight - tfText._height) * 0.5) + 1;
mcR._y = (mcB._x = (mcL._x = (mcTL._x = (mcBL._x = (mcT._x = (mcC._x = (mcC._y = (mcL._y = (mcTL._y = (mcTR._y = (mcT._y = 0)))))))))));
mcR._x = (mcBR._x = (mcTR._x = (mcT._xscale = (mcB._xscale = (mcC._xscale = w + padding)))));
mcB._y = (mcBR._y = (mcBL._y = (mcR._yscale = (mcL._yscale = (mcC._yscale = h + padding)))));
}
var time = 0;
static var created = 0;
var padding = 2;
var width = 0;
var height = 0;
}
Symbol 723 MovieClip [__Packages.GameFlag] Frame 0
class GameFlag extends Collectable
{
var attachedTo, world, target;
function GameFlag (attachedTo, flagNumber, canCollect) {
super();
this.attachedTo = attachedTo;
if (flagNumber) {
}
if (canCollect != null) {
this.canCollect = canCollect != null;
}
}
function onAddToWorld() {
world.gamePoints.addMember(this);
}
function doubleValue() {
multiplier = multiplier * 2;
}
function onAddDisplay() {
target.gotoAndStop(flagNumber);
}
function award(obj) {
obj.shiftScore(value * multiplier);
world.playEventSound(world.globalSounds, "flag");
attachedTo.target.play();
obj.collectFlag();
}
var flagNumber = 1;
var radius = 40;
var assetID = "Flags";
var className = "Flag";
var canCollect = true;
var value = 50;
var multiplier = 1;
}
Symbol 724 MovieClip [__Packages.GameFuel] Frame 0
class GameFuel extends Collectable
{
var world, setCollected;
function GameFuel () {
super();
}
function onAddToWorld() {
world.fuel.addMember(this);
setCollected(null);
}
function award(obj) {
obj.shiftFuel(value);
world.playEventSound(world.globalSounds, "fuel");
}
var assetID = "itemRocketFuel";
var value = SSGlobal.HOVER_CRAFT_FUEL;
}
Symbol 725 MovieClip [__Packages.FloatingObstacle] Frame 0
class FloatingObstacle extends SSObject
{
var velocity, origin, x, y, z, getUpdates, target, cancelUpdates, moveTo, inScene, moveBy;
function FloatingObstacle (driftX, driftY) {
super();
}
function init(driftX, driftY) {
if (driftX || (driftY)) {
velocity = new Vector(driftX, driftY, 0);
}
}
function onAddToWorld() {
origin = new Vector(x, y, z);
}
function onAddToScene() {
getUpdates();
}
function onAddDisplay() {
target.clip._xscale = ((velocity.x < 0) ? -100 : 100);
}
function onRemoveFromScene() {
cancelUpdates();
moveTo(origin.x, origin.y, origin.z);
}
function hitObject(obj) {
if (!inScene) {
return(undefined);
}
obj.shiftHealth(value);
}
function update(elapsed) {
moveBy(velocity.x * elapsed, velocity.y * elapsed, velocity.z * elapsed);
}
function editor_onPropsChange() {
}
var collisionMask = SSGlobal.CLSID_FLOATING;
var value = -0.333;
var depthLayer = 3;
var driftX = 0;
var driftY = 0;
var radius = 50;
var editor_defaultValues = [0, 0];
var editor_argNames = ["driftX", "driftY"];
var editor_defaultTypes = ["number", "number"];
var editor_options = [[-500, 500], [-500, 500]];
var editor_component = ["NumericStepper", "NumericStepper"];
}
Symbol 726 MovieClip [__Packages.ElectricCloud] Frame 0
class ElectricCloud extends FloatingObstacle
{
var init;
function ElectricCloud () {
super();
init.apply(this, arguments);
}
var assetID = "ElectricCloud";
}
Symbol 727 MovieClip [__Packages.WindColumn] Frame 0
class WindColumn extends SSObject
{
var pattern, sndTransform, p0, direction, p1, p2, p3, leftSector, left, x, topSector, top, y, rightSector, right, bottomSector, bottom, removeFromSectorGrid, addToSectorGrid, positionSound, ventSound, particles, target, getUpdates, ventSndTar, createSound, uniqueID, cancelUpdates, span;
function WindColumn (particleID, strength, width, angle, pattern) {
super();
if (particleID != null) {
this.particleID = particleID;
}
if (strength) {
this.strength = strength;
}
halfWidth = ((columnWidth = width)) * 0.5;
setAngle((angle ? (angle) : (this.angle)), true);
if (pattern) {
this.pattern = pattern;
}
sndTransform = {ll:0, lr:0, rr:0, lr:0};
}
function onAddToWorld() {
}
function updateLocalBounds() {
p0 = new Vector(direction.y * halfWidth, direction.x * (-halfWidth), 0);
p1 = new Vector(-p0.x, -p0.y, 0);
p2 = new Vector((direction.x * strength) + p0.x, (direction.y * strength) + p0.y, 0);
p3 = new Vector((direction.x * strength) + p1.x, (direction.y * strength) + p1.y, 0);
if (direction.x < 0) {
if (direction.y < 0) {
localLeft = p2.x;
localTop = p3.y;
localRight = p1.x;
localBottom = p0.y;
} else {
localLeft = p3.x;
localTop = p1.y;
localRight = p0.x;
localBottom = p2.y;
}
} else if (direction.y < 0) {
localLeft = p0.x;
localTop = p2.y;
localRight = p3.x;
localBottom = p1.y;
} else {
localLeft = p1.x;
localTop = p0.y;
localRight = p2.x;
localBottom = p3.y;
}
}
function updateBounds() {
var _local2 = leftSector != ((leftSector = Math.floor(((left = x + localLeft)) / SSGlobal.GRID_SIZE)));
var _local3 = topSector != ((topSector = Math.floor(((top = y + localTop)) / SSGlobal.GRID_SIZE)));
var _local4 = rightSector != ((rightSector = Math.floor(((right = x + localRight)) / SSGlobal.GRID_SIZE)));
var _local5 = bottomSector != ((bottomSector = Math.floor(((bottom = y + localBottom)) / SSGlobal.GRID_SIZE)));
if (((_local2 || (_local3)) || (_local4)) || (_local5)) {
removeFromSectorGrid();
addToSectorGrid();
}
}
function update(elapsed) {
onDisplay(null, elapsed);
positionSound(ventSound, x, y, 400, 400);
}
function onAddDisplay() {
particles = [];
particleCount = 0;
target._rotation = angle;
}
function onDisplay(viewport, elapsed) {
var _local4;
var _local2 = particles.length;
while (_local2-- , _local2 > -1) {
_local4 = particles[_local2];
_local4 = particles[_local2];
_local4._y = _local4._y - (strength * elapsed);
_local4._alpha = Math.abs(1 + (_local4._y / strength)) * 100;
_local4._rotation = _local4._rotation + ((elapsed * _local4.spin) * 100);
if (_local4._y < (-strength)) {
_local4.removeMovieClip();
particles.splice(_local2, 1);
}
}
particleTime = particleTime - elapsed;
if (particleTime > 0) {
return(undefined);
}
delete particleTime;
_local4 = target.attachMovie(particleID, "p" + particleCount, particleCount++);
particles.push(_local4);
_local4._x = halfWidth * ((_local4.spin = (Math.random() * 2) - 1));
}
function onAddToScene() {
getUpdates();
if (pattern) {
}
if (!ventSndTar) {
ventSndTar = createSound("vent" + uniqueID);
((ventSound = ventSndTar.sound)).attachSound(ventSoundID);
}
update(0.001);
}
function onRemoveFromScene() {
cancelUpdates();
ventSound.stop();
ventSound.playing = false;
}
function setAngle(angle, noUpdate) {
this.angle = angle;
var _local2 = (angle / 180) * Math.PI;
direction = new Vector(Math.sin(_local2), -Math.cos(_local2), 0);
span = new Vector(direction.x * strength, direction.y * strength, direction.z * strength);
updateLocalBounds();
if (!noUpdate) {
updateBounds();
}
}
function setStrength() {
}
var angle = 0;
var strength = 0;
var columnWidth = 0;
var halfWidth = 0;
var depthLayer = 0;
var collisionMask = SSGlobal.CLSID_WIND;
var assetID = null;
var particleID = "puff";
var localLeft = 0;
var localRight = 0;
var localTop = 0;
var localBottom = 0;
var particleCount = 0;
var particleTime = 0.5;
var ventSoundID = "AirVentSound";
}
Symbol 728 MovieClip [__Packages.GamePointMultiplier] Frame 0
class GamePointMultiplier extends Collectable
{
var world;
function GamePointMultiplier () {
super();
}
function onAddToWorld() {
if (!_global.VR_MULTIPLIER) {
world.removeObject(this);
return(false);
}
}
function award(obj) {
var _local3 = world.gamePoints;
var _local2 = _local3.length;
while (_local2-- , _local2 > -1) {
_local3[_local2].doubleValue();
}
world.playEventSound(world.globalSounds, "2x");
}
var assetID = "iconBonus";
}
Symbol 729 MovieClip [__Packages.BonusTeleport] Frame 0
class BonusTeleport extends SSObject
{
var world, zone, getUpdates, otherObj, timeline, target, x, y, z;
function BonusTeleport () {
super();
}
function onAddToWorld() {
if (!_global.VR_BONUS) {
world.removeObject(this);
return(false);
}
world.addObject((zone = new SSZone(40, zone_onCollision, this)));
onMove();
}
function zone_onCollision(obj, zone) {
getUpdates();
obj.onTeleport();
otherObj = obj;
obj.setTimelineMode();
var _local5 = (timeline = new Timeline.Timeline());
_local5.owner = this;
_local5.onStop = function () {
this.owner.cancelUpdates();
this.owner.world.gotoBonusRoom(this.owner.otherObj);
delete this.owner.timeline;
delete this.owner.otherObj.update;
};
var _local2;
var _local3 = _local5.newTrack(obj);
_local3.onUpdate = obj.timelineUpdate;
_local3.addScript(1, hideCharacter);
_local2 = _local3.prop("x");
_local2.kf(0, obj.x);
_local2.kf(1, zone.x);
_local2 = _local3.prop("y");
_local2.kf(0, obj.y);
_local2.kf(1, zone.y);
_local3 = _local5.newTrack(obj.target);
_local2 = _local3.prop("_yscale");
_local2.kf(0, 100, 1);
_local2.kf(1, 1);
_local2 = _local3.prop("_xscale");
_local2.kf(0, 100, 1);
_local2.kf(1, 1);
_local2.kf(1, 3);
}
function hideCharacter() {
target._visible = false;
var _local2;
_local2 = new SSParticle("largepuff", 1, new Vector(0, -40, -10), 0, 0);
world.addObject(_local2);
_local2.moveBy(x, y, z);
}
function endLevel() {
world.endLevel();
}
function update(elapsed) {
timeline.update(elapsed);
}
function onMove() {
zone.moveTo(x, y - 100, z);
}
var assetID = "BonusTransport";
var editor_defaultValues = ["BonusRoom"];
var editor_argNames = ["destination"];
var editor_defaultTypes = ["string"];
var editor_options = [null];
var editor_component = ["TextInput"];
}
Symbol 730 MovieClip [__Packages.SSShapeInstance] Frame 0
class SSShapeInstance extends SSObject
{
var world, parent, target, inScene, __proto__;
function SSShapeInstance (obj) {
super();
world = null;
parent = null;
target = null;
isInstance = true;
inScene = false;
__proto__ = {__proto__:obj};
__proto__.queueForDisplay = SSShape.prototype.queueForDisplay;
}
function editor_onAddToDocument(doc, cn, args) {
var _local5 = args[0];
var _local3 = doc.objects;
var _local2 = _local3.length;
var _local4;
while (_local2-- , _local2 > -1) {
if (_local3[_local2].name == _local5) {
_local4 = _local3[_local2];
break;
}
}
points = _local4.points;
if (!_local4.instances) {
_local4.instances = [];
}
_local4.instances.push(this);
}
function editor_display() {
target.clear();
target.beginFill(13408767, 20);
target.moveTo(points[0].x, points[0].y);
var _local2 = points.length;
while (_local2-- , _local2 > -1) {
target.lineStyle(0, (points[_local2].props ? 16711680 : 8947848));
target.lineTo(points[_local2].x, points[_local2].y);
}
target.endFill();
}
var isInstance = true;
var assetID = null;
}
Symbol 731 MovieClip [__Packages.GameSpring] Frame 0
class GameSpring extends SSObject
{
var direction, zone, world, target, x, y, z;
function GameSpring (angle, strength) {
super();
var _local3 = ((angle ? ((this.angle = angle)) : (this.angle)) / 180) * Math.PI;
if (strength) {
this.strength = strength;
}
direction = new Vector(Math.sin(_local3), -Math.cos(_local3), 0);
}
function onAddToWorld() {
var _local2;
_local2 = (zone = new SSZone(25, zone_onCollision, this));
world.addObject(_local2);
onMove();
}
function onAddDisplay() {
target._rotation = angle;
}
function onMove() {
zone.moveTo(x + (direction.x * 50), y + (direction.y * 50), z);
}
function zone_onCollision(obj, zone) {
obj.velocity.reverse();
obj.velocity.x = direction.x * strength;
obj.velocity.y = direction.y * strength;
obj.onSpring();
world.playEventSound(world.globalSounds, "spring");
target.play();
}
function onRemoveFromWorld() {
}
function editor_onPropsChange() {
target._rotation = (angle = angle % 360);
var _local2 = angle / 565.486677646163;
target.clear();
target.lineStyle(0, 13408716);
target.lineTo(0, strength * -0.5);
}
var angle = 0;
var strength = 1500;
var assetID = "Spring";
var editor_defaultValues = [0, 1500];
var editor_argNames = ["angle", "strength"];
var editor_defaultTypes = ["number", "number"];
var editor_options = [[-360, 360], [0, 3000]];
var editor_component = ["NumericStepper", "NumericStepper"];
}
Symbol 732 MovieClip [__Packages.Teleport] Frame 0
class Teleport extends SSObject
{
var destination, world, zone, getUpdates, otherObj, timeline, x, y, z, target, destX, destY;
function Teleport (destX, destY, destZ) {
super();
destination = new Vector(destX, destY, destZ);
}
function onAddToWorld() {
world.addObject((zone = new SSZone(20, zone_onCollision, this)));
onMove();
}
function zone_onCollision(obj, zone) {
getUpdates();
otherObj = obj;
obj.setTimelineMode();
var _local5 = (timeline = new Timeline.Timeline());
_local5.owner = this;
_local5.onStop = function () {
this.owner.cancelUpdates();
this.owner.otherObj.restoreDefaultMode();
delete this.owner.timeline;
};
world.playEventSound(world.globalSounds, "teleport");
obj.onTeleport();
var _local8 = new Vector(zone.x - destination.x, zone.y - destination.y, 0);
var _local9 = _local8.length;
var _local6 = Math.min(_local9 / transSpeed, transTime);
var _local2;
var _local3 = _local5.newTrack(obj);
_local3.onUpdate = obj.timelineUpdate;
_local3.addScript(1, obj.transportEffect);
_local3.addScript(1 + _local6, obj.endTransportEffect);
_local2 = _local3.prop("x");
_local2.kf(0, obj.x);
_local2.kf(1, zone.x);
_local2.kf(1 + _local6, destination.x);
_local2 = _local3.prop("y");
_local2.kf(0, obj.y);
_local2.kf(1, zone.y);
_local2.kf(1 + _local6, destination.y);
_local3 = _local5.newTrack(obj.target);
_local2 = _local3.prop("_yscale");
_local2.kf(0, 100, 1);
_local2.kf(1, 1);
_local2 = _local3.prop("_xscale");
_local2.kf(0, 100, 1);
_local2.kf(1, 1);
}
function update(elapsed) {
timeline.update(elapsed);
}
function onMove() {
zone.moveTo(x, y - 50, z);
}
function editor_onPropsChange() {
target.clear();
target.lineStyle(0, 65535);
target.lineTo(destX - x, destY - y);
}
var assetID = "Teleporter";
var transSpeed = 800;
var transTime = 3;
var editor_defaultValues = [0, 0, 0];
var editor_argNames = ["destX", "destY", "destZ"];
var editor_defaultTypes = ["number", "number", "number"];
var editor_options = [[0, 20000], [-20000, 0], [0, 0]];
var editor_component = ["NumericStepper", "NumericStepper", "NumericStepper"];
}
Symbol 733 MovieClip [__Packages.GamePoint] Frame 0
class GamePoint extends Collectable
{
var world, inScene, target;
function GamePoint () {
super();
}
function award(obj) {
obj.shiftScore(value * multiplier);
obj.shiftHealth(healthValue);
world.pointsCollected++;
if (world.pointsCollected == world.pointCount) {
obj.onAllPointsCollected(this);
}
world.playEventSound(world.globalSounds, "point");
}
function doubleValue() {
multiplier = multiplier * 2;
assetFrame = assetFrame + 1;
if (inScene) {
onAddDisplay();
}
}
function onAddDisplay() {
target.gotoAndStop(assetFrame);
}
function onAddToWorld() {
world.gamePoints.addMember(this);
world.pointCount++;
}
var assetID = SSGlobal.ASSET_POINT;
var value = 5;
var healthValue = 0.005;
var multiplier = 1;
var assetFrame = 1;
}
Symbol 734 MovieClip [__Packages.DSGeneric] Frame 0
class DSGeneric extends SSDrawStyle
{
var points, edges, setup, makeTarget, setTarget, goRoot, groups, instruction, attachAndPlaceMovie, target, calculateLighting, goRootTarget, push;
function DSGeneric (points, edges) {
super();
this.points = points;
this.edges = edges;
setup(points, edges);
makeTarget("Surface", 2000);
makeTarget("Top", 4000);
makeTarget("Bottom", 1000);
makeTarget("Rails", 2500);
makeTarget("Sides", 3000);
setTarget("Surface");
goRoot();
var _local5 = groups.length;
var _local7;
var _local3;
var _local6;
while (_local5-- , _local5 > -1) {
_local7 = groups[_local5];
if (_local7[0].props & 1) {
drawExtrudedRigid(groups[_local5], viewSlope, 10, 10, diffuseColor, ambientColor, sideColor, true);
goRoot();
var _local4 = _local7.length;
while (_local4-- , _local4 > -1) {
_local6 = _local7[_local4];
_local3 = _local6.b;
setTarget("Rails");
instruction(createSideRail, _local6, (_local5 * 100) + _local4, sideAssetID, sideAssetWidth, sideAssetHeight);
goRoot();
if (_local3.normal.y < 0) {
attachAndPlaceMovie("rocket", (10000 + (_local5 * 10)) + _local4, _local3.x - viewSlope.x, _local3.y - viewSlope.y);
attachAndPlaceMovie("rocket", (0 + (_local5 * 10)) + _local4, _local3.x + viewSlope.x, _local3.y + viewSlope.y);
}
}
_local3 = _local6.a;
attachAndPlaceMovie("rocket", (10000 + (_local5 * 10)) + _local4, _local3.x - viewSlope.x, _local3.y - viewSlope.y);
attachAndPlaceMovie("rocket", (0 + (_local5 * 10)) + _local4, _local3.x + viewSlope.x, _local3.y + viewSlope.y);
}
}
}
function createSideRail(edge, depth, assetID, assetWidth, assetHeight) {
var _local4 = target.createEmptyMovieClip("r" + ((depth * 2) + 1), (depth * 2) + 1);
var _local2 = Math.round(edge.length / assetWidth);
_local4._x = (edge.a.x - viewSlope.x) - (edge.normal.x * 10);
_local4._y = (edge.a.y - viewSlope.y) - (edge.normal.y * 10);
_local4._rotation = (edge.angle / Math.PI) * 180;
_local4._xscale = (edge.length / (_local2 * assetWidth)) * 100;
var _local3 = _local4.attachMovie("Pipe", "p", _local2);
_local3._x = (assetWidth * 0.5) - 10;
_local3._y = assetHeight;
_local3._xscale = ((_local2 - 1) * assetWidth) + 20;
while (_local2-- , _local2 > -1) {
_local3 = _local4.attachMovie(assetID, "mc" + _local2, _local2);
_local3._x = assetWidth * _local2;
}
}
function drawExtrudedRigid(group, view, depth, thickness, diffuseColor, ambientColor, sideColor, drawBottom) {
var _local9;
var _local4;
var _local3;
var _local13;
var _local12;
var _local6;
var _local5;
var _local8;
var _local7;
var _local20 = new SSDrawStyle();
var _local18 = new SSDrawStyle();
var _local19 = new SSDrawStyle();
var _local24 = Math.atan2(view.y, view.x) / Math.PI;
var _local15 = group.length;
while (_local15-- , _local15 > -1) {
_local9 = group[_local15];
_local4 = _local9.a;
_local3 = _local9.b;
_local13 = new Vector(_local4.x + view.x, _local4.y + view.y);
_local12 = new Vector(_local3.x + view.x, _local3.y + view.y);
_local6 = new Vector(_local3.x - view.x, _local3.y - view.y);
_local5 = new Vector(_local4.x - view.x, _local4.y - view.y);
var _local11 = _local4.scale * thickness;
var _local10 = _local3.scale * thickness;
_local8 = new Vector(_local5.x - (_local4.normal.x * _local11), _local5.y - (_local4.normal.y * _local11));
_local7 = new Vector(_local6.x - (_local3.normal.x * _local10), _local6.y - (_local3.normal.y * _local10));
if (thickness) {
_local20.solidShape(sideColor, [_local6, _local5, _local8, _local7]);
}
if (_local9.normal.dot(view) > 0) {
_local19.solidShape(calculateLighting(_local9.normal, ambientColor, diffuseColor, specularColor), [_local13, _local12, _local6, _local5]);
} else if (drawBottom) {
_local18.solidShape(calculateLighting(_local9.normal.getReversed(), ambientColor, diffuseColor, specularColor), [_local8, _local7, new Vector(_local7.x + (view.x * 2), _local7.y + (view.y * 2)), new Vector(_local8.x + (view.x * 2), _local8.y + (view.y * 2))]);
}
}
goRootTarget("Top");
push.apply(this, _local19);
goRootTarget("Sides");
push.apply(this, _local20);
goRootTarget("Bottom");
push.apply(this, _local18);
}
function fillEdges(list) {
target.lineStyle(3, random(16777215));
var _local2 = list.length;
while (_local2-- , _local2 > -1) {
var _local4 = list[_local2].a;
var _local3 = list[_local2].b;
target.moveTo(_local4.x, _local4.y);
target.lineTo(_local3.x, _local3.y);
}
}
function showInfo() {
var _local4 = edges.length;
var _local3 = target.createEmptyMovieClip("info", 65535);
var _local2;
while (_local4-- , _local4 > -1) {
_local2 = edges[_local4];
_local3.lineStyle(3, 65535);
_local3.moveTo(_local2.a.x + _local2.span.x, _local2.a.y + _local2.span.y);
_local3.lineTo(_local2.a.x, _local2.a.y);
_local3.lineStyle(3, 255);
_local3.lineTo(_local2.a.x + (_local2.normal.x * 30), _local2.a.y + (_local2.normal.y * 30));
_local3.lineStyle(3, 65280);
_local3.moveTo(_local2.a.x, _local2.a.y);
_local3.lineTo(_local2.a.x + (_local2.a.normal.x * 30), _local2.a.y + (_local2.a.normal.y * 30));
}
}
static var mainColor = 16763904;
static var gradientType = "linear";
static var gradientColors = [0, 100];
static var gradientAlpha = [0, 100];
static var gradientRatios = [0, 100];
static var ambientColor = new RGB(7901096);
static var diffuseColor = new RGB(10529723);
static var specularColor = new RGB(15724527);
static var sideColor = new RGB(10066346);
static var viewSlope = new Vector(4, -15);
static var sideAssetID = "girderRail";
static var sideAssetWidth = 50;
static var sideAssetHeight = 20;
}
Symbol 735 MovieClip [__Packages.ElectricBlimp] Frame 0
class ElectricBlimp extends FloatingObstacle
{
var init;
function ElectricBlimp () {
super();
init.apply(this, arguments);
}
var assetID = "Blimp";
}
Symbol 736 MovieClip [__Packages.SSLevel] Frame 0
class SSLevel
{
var name, objects, preProcess, createBackground, lastTime, intervalID, onComplete;
function SSLevel (name) {
this.name = name;
objects = [];
}
function addObject() {
objects.push(arguments);
}
function build(base, worldCN) {
var _local2 = new worldCN[undefined](name);
_local2.name = name;
base.addWorld(_local2);
levelLeft = Number.MAX_VALUE;
levelTop = Number.MAX_VALUE;
levelRight = -16777215;
levelBottom = -16777215;
preProcess(_local2);
createBackground(_local2);
processObjects(base, _local2);
return(_local2);
}
function processObjects(base, ssw) {
lastTime = getTimer();
current = -1;
total = objects.length;
intervalID = setInterval(function (o, base, ssw) {
o.objectsStep(base, ssw);
}, 0, this, base, ssw);
}
function objectsStep(base, ssw) {
var _local4 = Math.abs(getTimer() - ((lastTime = getTimer())));
while ((++current) < total) {
var _local2 = objects[current];
processObject(ssw, _local2);
}
if (current == total) {
complete(base, ssw);
clearInterval(intervalID);
}
updateAfterEvent();
}
function processObject(ssw, aData) {
var _local8 = aData[1];
var _local7 = aData[2];
var _local6 = aData[3];
var _local3 = aData[0];
var _local5 = aData.slice(4);
if (_local3 == null) {
return(false);
}
var _local2 = {};
_local2.__proto__ = _local3.prototype;
if (_local3 == SSShapeInstance) {
_local3.call(_local2, ssw.shapes[_local5[0]]);
} else {
_local3.apply(_local2, _local5);
}
_local2.x = _local8;
_local2.y = _local7;
_local2.z = _local6;
ssw.addObject(_local2);
levelLeft = Math.min(levelLeft, _local2.left);
levelTop = Math.min(levelTop, _local2.top);
levelRight = Math.max(levelRight, _local2.right);
levelBottom = Math.max(levelBottom, _local2.bottom);
}
function complete(base, ssw) {
ssw.levelLeft = levelLeft;
ssw.levelTop = levelTop;
ssw.levelRight = levelRight;
ssw.levelBottom = levelBottom;
onComplete(base, ssw);
}
function onStatus() {
}
var levelLeft = 0;
var levelRight = 0;
var levelTop = 0;
var levelBottom = 0;
var current = 0;
var total = 0;
var pauseTime = 20;
var editor_defaultValues = ["WorldName", "preProcess", "createBackground", 400, -400];
var editor_argNames = ["name", "preProcess", "createBackground", "startX", "startY"];
var editor_defaultTypes = ["string", "string", "string", "number", "number"];
var editor_options = [null, null, null, [0, 20000], [-20000, 0]];
var editor_component = ["TextInput", "TextInput", "TextInput", "NumericStepper", "NumericStepper"];
}
Symbol 737 MovieClip [__Packages.GDK.Base] Frame 0
class GDK.Base extends MovieClip
{
var worlds, useMask, setMask, attachMovie, _xscale, _yscale, onResize, mcMask, engineIntervalID, lastUpdate, onStart, onPause, onResume, onStop, activeWorld, onUpdate;
function Base () {
super();
worlds = new GDK.Collection();
if (useMask) {
setMask(attachMovie("Square", "mcMask", 13421568));
}
setSize(Math.round(_xscale), Math.round(_yscale));
_yscale = (_xscale = 100);
for (var _local3 in this) {
if (_local3.indexOf("mcDead") != -1) {
this[_local3].swapDepths(1048575);
this[_local3].removeMovieClip();
}
}
}
function setSize(w, h, noEvent) {
if ((w == width) && (h == height)) {
return(undefined);
}
halfWidth = w * 0.5;
halfHeight = h * 0.5;
if (noEvent) {
width = w;
height = h;
} else {
onResize((width = w), (height = h), width, height);
}
if (useMask) {
mcMask._xscale = w;
mcMask._yscale = h;
}
}
function start() {
if (engineIntervalID) {
return(undefined);
}
lastUpdate = getTimer();
engineIntervalID = setInterval(function (o) {
o.update();
}, 0, this);
onStart();
running = true;
update();
}
function pause() {
paused = true;
onPause();
update();
}
function resume() {
paused = false;
onResume();
update();
}
function stop() {
onStop();
running = false;
clearInterval(engineIntervalID);
delete engineIntervalID;
}
function update() {
var _local2;
if (paused) {
lastUpdate = getTimer();
return(undefined);
}
_local2 = Math.min(maxFrameTime, (lastUpdate - ((lastUpdate = getTimer()))) * -0.001);
activeWorld.update((activeWorld.frameTime = _local2));
onUpdate(_local2);
}
function getWorld(name) {
var _local2 = worlds.length;
while (_local2-- , _local2 > -1) {
if (worlds[_local2].name == name) {
return(worlds[_local2]);
}
}
return(null);
}
function addWorld(worldObj) {
if (!worlds.addMember(worldObj)) {
return(undefined);
}
worldObj.displayNode = this;
worldObj.engine = this;
}
function removeWorld(worldObj) {
if (!worlds[worldObj]) {
return(undefined);
}
var _local2 = worlds.length;
while (_local2-- , _local2 > -1) {
if (worlds[_local2] == worldObj) {
worlds.splice(_local2, 1);
}
}
delete worlds[worldObj];
worldObj.removeFromScene();
}
function setActiveWorld(worldObj) {
if (activeWorld == worldObj) {
return(undefined);
}
activeWorld.removeFromScene();
activeWorld = worldObj;
worldObj.addToScene();
worldObj.render(0.0001);
}
function onUnload() {
stop();
setActiveWorld(null);
}
var paused = false;
var width = 100;
var height = 100;
var halfWidth = 50;
var halfHeight = 50;
var version = "GDK 1,1,10,0";
var running = false;
var maxFrameTime = 0.1;
}
Symbol 738 MovieClip [__Packages.GameHoverCraft] Frame 0
class GameHoverCraft extends Collectable
{
var world;
function GameHoverCraft () {
super();
}
function onAddToWorld() {
if (!_global.VR_JETPACK) {
world.removeObject(this);
return(false);
}
}
function award(obj) {
obj.enableHoverCraft(this);
var _local3 = world.fuel;
var _local2 = _local3.length;
while (_local2-- , _local2 > -1) {
_local3[_local2].reset();
}
world.playEventSound(world.globalSounds, "hovercraft");
}
function onReset() {
var _local3 = world.fuel;
var _local2 = _local3.length;
while (_local2-- , _local2 > -1) {
_local3[_local2].setCollected(null);
}
}
var assetID = SSGlobal.ASSET_ICON_HOVER;
var value = SSGlobal.HOVER_CRAFT_FUEL;
}
Symbol 739 MovieClip [__Packages.AirVent] Frame 0
class AirVent extends SSObject
{
var pattern, target, world, windColumn, x, y, z, getUpdates, cancelUpdates;
function AirVent (strength, angle, pattern) {
super();
if (strength) {
strengthTotal = ((this.strength = strength)) * strengthUnitSize;
}
if (angle) {
this.angle = angle;
}
if (pattern != null) {
if (pattern.type == "string") {
pattern = pattern.split(",");
}
if (pattern.length > 0) {
this.pattern = pattern;
}
}
}
function onAddDisplay() {
target._rotation = angle;
target.gotoAndStop(strength + 1);
}
function onAddToWorld() {
world.addObject((windColumn = new WindColumn(null, strengthTotal, columnWidth, angle, pattern)));
windColumn.moveTo(x, y, z);
}
function update(elapsed) {
onDisplay(null, elapsed);
}
function onDisplay(viewport, elapsed) {
target.blade.blade._rotation = target.blade.blade._rotation + (elapsed * 360);
}
function onRemoveFromWorld() {
world.removeObject(windColumn);
}
function onMove(x, y, z) {
windColumn.moveBy(x, y, z);
}
function onAddToScene() {
getUpdates();
}
function onRemoveFromScene() {
cancelUpdates();
}
function editor_onPropsChange() {
target._rotation = (angle = angle % 360);
var _local2 = angle / 565.486677646163;
target.clear();
target.lineStyle(0, 10066380);
target.lineTo(0, (-strength) * 400);
}
var size = 65;
var angle = 0;
var radius = 0;
var strength = 1;
var strengthUnitSize = 400;
var strengthTotal = AirVent.prototype.strength * AirVent.prototype.strengthUnitSize;
var columnWidth = 120;
var collisionMask = SSGlobal.CLSID_VENT;
var assetID = SSGlobal.ASSET_VENT;
var editor_defaultValues = [1, 0, ""];
var editor_argNames = ["strength", "angle", "pattern"];
var editor_defaultTypes = ["number", "number", "numberArray"];
var editor_options = [[1, 3], [-360, 360], null];
var editor_component = ["NumericStepper", "NumericStepper", "TextInput"];
}
Symbol 740 MovieClip [__Packages.FallingRock] Frame 0
class FallingRock extends FlyingObstacle
{
var impact, origin, x, y, z, trackInSectorGrid, moveTo, cancelUpdates, freeFallVel, flyForwardVel, moveBy, crossedZero, removeZ;
function FallingRock (impactX, impactY, impactZ) {
super();
impact = new Vector(impactX, impactY, impactZ);
}
function onAddToWorld() {
origin = new Vector(x, y, z);
}
function onRemoveFromScene() {
delete freeFallTime;
delete time;
trackInSectorGrid = true;
moveTo(origin.x, origin.y, origin.z);
cancelUpdates();
}
function reset() {
delete freeFallTime;
delete flyForwardTime;
time = 0;
trackInSectorGrid = false;
freeFallVel = new Vector(0, freeFallTime * 500, 0);
flyForwardVel = new Vector((origin.x - impact.x) / flyForwardTime, (origin.y - impact.y) / flyForwardTime, (origin.z - impact.z) / flyForwardTime);
moveTo(impact.x - (freeFallVel.x * freeFallTime), impact.y - (freeFallVel.y * freeFallTime), impact.z - (freeFallVel.z * freeFallTime));
}
function update(elapsed) {
if (freeFallTime) {
if (!((freeFallTime = Math.max(freeFallTime - elapsed, 0)))) {
}
moveBy(freeFallVel.x * elapsed, freeFallVel.y * elapsed, freeFallVel.z * elapsed);
return(undefined);
}
var _local3 = ((time = time + elapsed)) / flyForwardTime;
var _local4 = z;
y = (impact.y + (flyForwardVel.y * time)) + ((flyForwardVel.y - 400) * Math.sin(_local3 * Math.PI));
moveBy(flyForwardVel.x * elapsed, 0, flyForwardVel.z * elapsed);
crossedZero = (_local4 > 0) && (z <= 0);
if (z < removeZ) {
reset();
}
}
function editor_onPropsChange() {
}
var assetID = "FallingRock";
var freeFallTime = 2;
var time = 2;
var flyForwardTime = 2;
var spin = 80;
static var yArcM = Math.SQRT2;
var editor_defaultValues = [0, 0, 2000];
var editor_argNames = ["impactX", "impactY", "impactZ"];
var editor_defaultTypes = ["number", "number", "number"];
var editor_options = [null, null, null];
var editor_component = ["TextInput", "TextInput", "TextInput"];
}
Symbol 741 MovieClip [__Packages.Bird] Frame 0
class Bird extends FlyingObstacle
{
var origin, x, y, z, trackInSectorGrid, arc, moveTo, particleVelocity, updateParticleTrail, oldz, crossedZero, target, updateSound;
function Bird (x, y, z) {
super();
}
function onAddToWorld() {
origin = new Vector(x, y, z);
}
function reset() {
time = (Math.PI/2);
trackInSectorGrid = false;
arc = new Vector(0, Math.cos(time), Math.sin(time));
moveTo(origin.x, (origin.y - dist) + (arc.y * dist), arc.z * dist);
}
function update(elapsed) {
time = time - (elapsed * 0.25);
arc = new Vector(0, Math.cos(time), Math.sin(time));
((particleVelocity = arc.copy())).length = 200;
updateParticleTrail(elapsed);
oldz = z;
moveTo(origin.x, (origin.y - dist) + (arc.y * dist), arc.z * dist);
crossedZero = (oldz > 0) && (z <= 0);
if (z < removeZ) {
reset();
}
}
function onDisplay(vp) {
target.gotoAndStop(Math.ceil(arc.y * 5));
updateSound(vp);
}
var assetID = "Bird";
var soundID = "BirdSound";
var dist = 2000;
var radius = 50;
var flightTime = (Math.PI*2);
var time = 0;
var removeZ = -400;
var particleTime = 0.5;
}
Symbol 742 MovieClip [__Packages.GameShield] Frame 0
class GameShield extends Collectable
{
var world;
function GameShield () {
super();
}
function onAddToWorld() {
if (!_global.VR_SHIELD) {
world.removeObject(this);
return(false);
}
}
function award(obj) {
obj.enableShield(value);
world.playEventSound(world.globalSounds, "shield");
}
var assetID = "iconShield";
var value = 20;
}
Symbol 743 MovieClip [__Packages.FlagPole] Frame 0
class FlagPole extends SSObject
{
var collected, target, world, flag, x, y, z;
function FlagPole () {
super();
}
function onAddDisplay() {
if (collected) {
target.gotoAndStop("collected");
}
}
function onAddToWorld() {
world.addObject((flag = new GameFlag(this)));
flag.moveTo(x + 50, y - 100, z);
world.flagCount++;
}
function onMove() {
flag.moveTo(x + 50, y - 100, z);
}
function onCollected() {
target.gotoAndPlay("Collect");
}
function setCollected(obj) {
}
var assetID = SSGlobal.ASSET_FLAG_POLE;
var flagConstructor = 1;
}
Symbol 744 MovieClip [__Packages.SSMap] Frame 0
class SSMap extends MovieClip
{
var _width, _height, _xscale, _yscale, mcDead, world, objects, icons, target, createEmptyMovieClip;
function SSMap () {
super();
width = _width;
height = _height;
_xscale = 100;
_yscale = 100;
mcDead.swapDepths(1048575);
mcDead.removeMovieClip();
}
function init(world, visibleEdges, objects, icons) {
this.world = world;
this.visibleEdges = visibleEdges;
this.objects = objects;
this.icons = icons;
drawMap();
}
function drawMap() {
var _local9 = world.children;
target.removeMovieClip();
var _local8 = (target = createEmptyMovieClip("map", 0));
_local8.clear();
var _local11 = world.levelRight - world.levelLeft;
var _local10 = world.levelBottom - world.levelTop;
var _local13 = world.levelLeft;
var _local12 = world.levelTop;
var _local3 = Math.min(width / _local11, height / _local10);
_local8._x = ((width - (_local11 * _local3)) * 0.5) - (_local13 * _local3);
_local8._y = ((height - (_local10 * _local3)) * 0.5) - (_local12 * _local3);
var _local6 = _local9.length;
var _local2;
while (_local6-- , _local6 > -1) {
_local2 = _local9[_local6];
if (_local2.collisionMask == 0) {
continue;
}
if ((_local2.collisionMask & SSGlobal.CLSID_SHAPE) == SSGlobal.CLSID_SHAPE) {
var _local5 = _local8.createEmptyMovieClip("mc" + _local6, _local6);
_local5._x = _local2.x * _local3;
_local5._y = _local2.y * _local3;
_local5.lineStyle(0, SHAPE_EDGE_COLOR);
var _local4 = _local2.edges;
var _local7 = _local4.length;
while (_local7-- , _local7 > -1) {
if ((_local4[_local7].props & visibleEdges) == visibleEdges) {
_local5.moveTo(_local4[_local7].a.x * _local3, _local4[_local7].a.y * _local3);
_local5.lineTo(_local4[_local7].b.x * _local3, _local4[_local7].b.y * _local3);
}
}
} else {
var _local7 = objects.length;
while (_local7-- , _local7 > -1) {
if (((objects[_local7].prototype.collisionMask & _local2.collisionMask) == _local2.collisionMask) && (_local2.mapIconID != null)) {
var _local5 = _local8.attachMovie(_local2.mapIconID, "mc" + _local6, _local6 + 65535);
_local5._x = _local2.x * _local3;
_local5._y = _local2.y * _local3;
if (_local2.direction && (_local2.direction.x < 0)) {
_local5._xscale = _local5._xscale * -1;
}
}
}
}
}
}
var width = 100;
var height = 100;
var visibleEdges = 1;
static var SHAPE_EDGE_COLOR = 22965;
}
Symbol 193 MovieClip Frame 1
stop();
Symbol 203 MovieClip [AirVent] Frame 1
stop();
Symbol 212 MovieClip [girderRail] Frame 1
stop();
Symbol 241 MovieClip [gamePoint] Frame 1
stop();
Symbol 257 MovieClip [FlagPole] Frame 1
stop();
Symbol 304 MovieClip [Spring] Frame 1
stop();
Symbol 317 MovieClip Frame 18
stop();
Symbol 325 MovieClip Frame 1
stop();
Symbol 325 MovieClip Frame 11
play();
Symbol 325 MovieClip Frame 110
gotoAndStop ("default");
Symbol 327 MovieClip Frame 28
stop();
Symbol 329 MovieClip [Teleporter] Frame 1
stop();
Symbol 329 MovieClip [Teleporter] Frame 2
stop();
Symbol 342 MovieClip [Exit] Frame 1
stop();
Symbol 342 MovieClip [Exit] Frame 2
stop();
Symbol 349 MovieClip [BonusTransport] Frame 1
stop();
Symbol 349 MovieClip [BonusTransport] Frame 2
stop();
Symbol 354 MovieClip [Flags] Frame 1
stop();
Symbol 371 MovieClip [CraverSounds] Frame 1
nextFrame();
Symbol 381 MovieClip [globalSounds] Frame 1
stop();
Symbol 388 MovieClip [LinkedSounds] Frame 1
stop();
Symbol 443 Button
on (release) {
mcFade.gotoAndPlay(2);
play();
}
Symbol 445 MovieClip Frame 1
enabled = true;
onPress = function () {
};
this.useHandCursor = false;
Symbol 446 MovieClip Frame 1
stop();
Symbol 446 MovieClip Frame 7
stop();
Symbol 450 MovieClip [GDK] Frame 1
#initclip 64
Object.registerClass("GDK", GDK.Base);
#endinitclip
Symbol 472 MovieClip Frame 16
gotoAndPlay ("loop");
Symbol 473 Button
on (release) {
showMenu();
}
Symbol 479 MovieClip Frame 1
function setValue(r) {
valueBar._xscale = Math.max(1, r * 100);
}
Symbol 482 MovieClip Frame 14
play();
Symbol 482 MovieClip Frame 17
gotoAndPlay ("loop");
Symbol 483 Button
on (release) {
showMap();
}
Symbol 485 MovieClip Frame 1
btn.useHandCursor = false;
Symbol 503 Button
on (release) {
_parent.showHelp();
}
Symbol 507 Button
on (release) {
_parent.quitGame();
}
Symbol 511 Button
on (release) {
_parent.resumeGame();
}
Symbol 515 Button
on (release) {
_parent.showMap();
}
Symbol 527 MovieClip [SSMap] Frame 1
#initclip 62
Object.registerClass("SSMap", SSMap);
#endinitclip
Symbol 528 MovieClip Frame 1
mcMap.init(_parent.world, 1, [HangGlider, GameFlag], ["HangGlidIcon", "GameFlag"]);
Symbol 561 MovieClip Frame 1
stop();
Symbol 561 MovieClip Frame 2
stop();
Symbol 561 MovieClip Frame 3
stop();
Symbol 561 MovieClip Frame 4
stop();
Symbol 561 MovieClip Frame 5
stop();
Symbol 565 MovieClip [GameInterface] Frame 1
#initclip 63
Object.registerClass("GameInterface", GameInterface);
#endinitclip
stop();
_quality = ((_parent.GameQuality > 100) ? "HIGH" : "MEDIUM");
Symbol 565 MovieClip [GameInterface] Frame 5
_quality = "HIGH";
Symbol 575 Button
on (release) {
_parent.quitGame();
}
Symbol 579 Button
on (release) {
_parent.startNewGame();
}
Symbol 632 MovieClip Frame 1
stop();
Symbol 645 MovieClip Frame 1
stop();
Symbol 667 Button
on (release) {
_parent.gotoNextLevel();
}
Symbol 672 MovieClip Frame 1
stop();
Symbol 675 MovieClip Frame 1
mcPrev.gotoAndStop(_parent.GameLevel + 1);
mcNext.gotoAndStop(_parent.GameLevel + 2);
prevNum.gotoAndStop(_parent.GameLevel + 1);
nextNum.gotoAndStop(_parent.GameLevel + 2);