Frame 1
var _mochiads_game_id = "198a0028ffbef1e2";
Instance of Symbol 73 MovieClip "circle" in Frame 1
onClipEvent (enterFrame) {
if (random(300) == 0) {
removeMovieClip(this);
}
}
Frame 100
gotoAndPlay (101);
Instance of Symbol 73 MovieClip "circle" in Frame 101
onClipEvent (enterFrame) {
if (random(300) == 0) {
removeMovieClip(this);
}
}
Frame 130
girlz_m.setMask(emask);
girlz_m.cacheAsBitmap = true;
emask.cacheAsBitmap = true;
Frame 229
stop();
Frame 230
stop();
var scorecard = 0;
var scorecard2 = 0;
var levelscore = 0;
var lifee = 3;
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Frame 231
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Frame 239
stop();
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Frame 240
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Frame 241
stop();
var lvls = 1;
var scores = 0;
var lifee = 3;
var totascores = 0;
ms.setVolume(50);
sou.setVolume(50);
if (_root.soundss == 0) {
_root.mc_but.gotoAndStop(2);
} else {
_root.mc_but.gotoAndStop(1);
}
var playerDetails = SharedObject.getLocal("ride");
if (playerDetails.data.lev == undefined) {
playerDetails.data.lev = _root.lvls;
} else {
_root.lvls = playerDetails.data.lev;
}
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Frame 242
stopAllSounds();
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Frame 243
stopAllSounds();
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Frame 244
this.stop();
_root.scoress = 0;
if (lifee == 0) {
_root.gotoAndStop("gameover");
}
if (lvls == 1) {
level = 1;
}
if (lvls == 2) {
level = 2;
}
if (lvls == 3) {
level = 3;
}
if (lvls == 3) {
level = 3;
}
if (lvls == 4) {
level = 4;
}
if (lvls == 5) {
level = 5;
}
if (lvls == 6) {
level = 6;
}
if (lvls == 7) {
level = 7;
}
if (lvls == 8) {
level = 8;
}
if (lvls == 9) {
level = 9;
}
if (lvls == 10) {
level = 10;
}
if (lvls == 11) {
level = 11;
}
if (lvls == 12) {
level = 12;
}
if (lvls == 13) {
level = 13;
}
if (lvls == 14) {
level = 14;
}
if (lvls == 15) {
level = 15;
}
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Instance of Symbol 193 MovieClip "mc_control" in Frame 244
onClipEvent (load) {
this._parent.initLevel();
}
onClipEvent (keyDown) {
this._parent.keyPressed();
updateAfterEvent();
}
onClipEvent (enterFrame) {
this._parent.processGame();
}
Frame 246
stop();
stopAllSounds();
lvls++;
_root.playerDetails.data.lev = _root.lvls;
_root.scorecard = Number(_root.scorecard) + Number(100);
txtlevel.text = _root.scorecard;
txtscore.text = Number(_root.levelscore) + Number(_root.scorecard);
_root.levelscore = txtscore.text;
if (_root.lvls == 11) {
gotoAndStop ("gamewin");
}
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Frame 247
stop();
stopAllSounds();
onEnterFrame = function () {
if (_root.lvls >= 1) {
_root.le1.gotoAndStop(2);
_root.le1.onRelease = function () {
_root.lvls = 1;
gameStart();
};
}
if (_root.lvls >= 2) {
_root.le2.gotoAndStop(2);
_root.le2.onRelease = function () {
_root.lvls = 2;
gameStart();
};
}
if (_root.lvls >= 3) {
_root.le3.gotoAndStop(2);
_root.le3.onRelease = function () {
_root.lvls = 3;
gameStart();
};
}
if (_root.lvls >= 4) {
_root.le4.gotoAndStop(2);
_root.le4.onRelease = function () {
_root.lvls = 4;
gameStart();
};
}
if (_root.lvls >= 5) {
_root.le5.gotoAndStop(2);
_root.le5.onRelease = function () {
_root.lvls = 5;
gameStart();
};
}
if (_root.lvls >= 6) {
_root.le6.gotoAndStop(2);
_root.le6.onRelease = function () {
_root.lvls = 6;
gameStart();
};
}
if (_root.lvls >= 7) {
_root.le7.gotoAndStop(2);
_root.le7.onRelease = function () {
_root.lvls = 7;
gameStart();
};
}
if (_root.lvls >= 8) {
_root.le8.gotoAndStop(2);
_root.le8.onRelease = function () {
_root.lvls = 8;
gameStart();
};
}
if (_root.lvls >= 9) {
_root.le9.gotoAndStop(2);
_root.le9.onRelease = function () {
_root.lvls = 9;
gameStart();
};
}
if (_root.lvls >= 10) {
_root.le10.gotoAndStop(2);
_root.le10.onRelease = function () {
_root.lvls = 10;
gameStart();
};
}
if (_root.lvls >= 11) {
_root.le11.gotoAndStop(2);
_root.le11.onRelease = function () {
_root.lvls = 11;
gameStart();
};
}
if (_root.lvls >= 12) {
_root.le12.gotoAndStop(2);
_root.le12.onRelease = function () {
_root.lvls = 12;
gameStart();
};
}
if (_root.lvls >= 13) {
_root.le13.gotoAndStop(2);
_root.le13.onRelease = function () {
_root.lvls = 13;
gameStart();
};
}
if (_root.lvls >= 14) {
_root.le14.gotoAndStop(2);
_root.le14.onRelease = function () {
_root.lvls = 14;
gameStart();
};
}
if (_root.lvls >= 15) {
_root.le15.gotoAndStop(2);
_root.le15.onRelease = function () {
_root.lvls = 15;
gameStart();
};
}
};
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Frame 248
stop();
stopAllSounds();
_root.scorecard = Number(_root.scorecard) + Number(100);
txtlevel.text = _root.scorecard;
txtscore.text = Number(_root.levelscore) + Number(_root.scorecard);
_root.levelscore = txtscore.text;
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
Frame 249
stop();
stopAllSounds();
btnmoregames.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
logo22.onRelease = function () {
getURL ("http://www.gamesforgirlz.net/", "_blank");
};
_root.scorecard = Number(_root.scorecard) + Number(100);
txtlevel.text = _root.scorecard;
txtscore.text = Number(_root.levelscore) + Number(_root.scorecard);
_root.levelscore = txtscore.text;
Symbol 3 MovieClip [flower] Frame 1
stop();
Symbol 3 MovieClip [flower] Frame 2
play();
Symbol 3 MovieClip [flower] Frame 101
stop();
Symbol 41 Button
on (press) {
getURL ("http://www.xjocuridegatit.com", "_blank");
}
Symbol 42 Button
on (press) {
getURL ("http://www.xjocuripentrucopii.com", "_blank");
}
Symbol 43 Button
on (press) {
getURL ("http://www.xjocuribarbi.com", "_blank");
}
Symbol 44 Button
on (press) {
getURL ("http://www.xjocurinoi.com", "_blank");
}
Symbol 45 Button
on (press) {
getURL ("http://www.xjocuribiliard.com", "_blank");
}
Symbol 46 Button
on (press) {
getURL ("http://www.jocurionlain.com", "_blank");
}
Symbol 47 Button
on (press) {
getURL ("http://www.xjocurigratis.com", "_blank");
}
Symbol 48 Button
on (press) {
getURL ("http://www.xjocuricopii.com", "_blank");
}
Symbol 49 Button
on (press) {
getURL ("http://www.xjocuritari.com", "_blank");
}
Symbol 50 Button
on (press) {
getURL ("http://www.xjocuriminiclip.com", "_blank");
}
Symbol 51 Button
on (press) {
getURL ("http://www.cookingforgirlz.com", "_blank");
}
Symbol 73 MovieClip Frame 31
stop();
Symbol 92 MovieClip Frame 1
i = 0;
this.onEnterFrame = function () {
i++;
circle.duplicateMovieClip(_root.circle + i, i, {_alpha:100, _rotation:random(360)});
};
Instance of Symbol 73 MovieClip "circle" in Symbol 92 MovieClip Frame 1
onClipEvent (enterFrame) {
if (random(300) == 0) {
removeMovieClip(this);
}
}
Symbol 92 MovieClip Frame 100
stop();
i = 0;
this.onEnterFrame = function () {
i++;
circle.duplicateMovieClip(_root.circle + i, i, {_alpha:100, _rotation:random(360)});
};
Symbol 94 Button
on (release) {
getURL ("http://www.gamesforgirlz.net/", "_blank");
}
Symbol 372 MovieClip [__Packages.CWheel] Frame 0
class CWheel extends MovieClip
{
function CWheel () {
super();
}
function init(particle_, maxAccSpeed_, rad_) {
var _local2 = this;
_local2.particle = particle_;
_local2.rad = rad_;
_local2.maxAccSpeed = maxAccSpeed_ * 4;
_local2.speed = 0;
_local2.accSpeed = 0;
_local2.rot = new CVector2D(1, 0);
_local2.addedAcc = new CVector2D(0, 0);
_local2.intersectionFlag = false;
_local2.lastIntersPoint = new CVector2D(0, 0);
_local2.lastN = new CVector2D(0, 0);
var _local3;
var _local5;
var _local4 = 6.283185 / _local2.hitCount;
_local2.hitPointArray = new Array(_local2.hitCount);
_local2.normalArray = new Array(_local2.hitCount);
_local2.hitArray = new Array(_local2.hitCount);
_local2.intersArray = new Array();
_local3 = 0;
while (_local3 < _local2.hitCount) {
_local2.hitPointArray[_local3] = new CVector2D(Math.sin(_local4 * _local3) * _local2.rad, (-Math.cos(_local4 * _local3)) * _local2.rad);
_local2.normalArray[_local3] = _local2.hitPointArray[_local3].multNew(-1);
_local2.normalArray[_local3].normalize();
_local3++;
}
}
function process(dTime, acc, koeffDamp) {
var _local2 = this;
var _local3 = dTime;
_local2.accSpeed = Math.max(-_local2.maxAccSpeed, Math.min(_local2.maxAccSpeed, _local2.accSpeed + (acc * _local3)));
_local2.speed = Math.max((-_local2.maxSpeed) * _local3, Math.min((_local2.speed * koeffDamp) + _local2.accSpeed, _local2.maxSpeed * _local3));
_local2.rot.rotate(_local2.speed / _local2.rad);
_local2.mc.mc_rim._rotation = (Math.atan2(_local2.rot.y, _local2.rot.x) * 180) / 3.141593;
}
function checkCollision(hit_mc) {
var _local2 = this;
var _local10;
var _local7;
var _local8 = new CVector2D(0, 0);
var _local15 = false;
var _local3;
var _local4;
var _local17;
var _local18 = new CVector2D(_local2.particle.prevPos.x, _local2.particle.prevPos.y);
var _local5 = new CVector2D(0, 0);
var _local16;
_local2._x = _local2.particle.pos.x;
_local2._y = _local2.particle.pos.y;
_local16 = 0;
_local10 = 0;
while (_local10 < _local2.hitCount) {
_local2.hitPointArray[_local10].copyTo(_local8);
_local2.localToGlobal(_local8);
if ((_local2.hitArray[_local10] = hit_mc.hitTest(_local8.x, _local8.y, true))) {
_local15 = true;
_local3 = _local10;
_local16++;
}
_local10++;
}
if (_local16 == _local2.hitCount) {
_local2.particle.pos.x = _local2.particle.prevPos.x + ((_local2.particle.pos.x - _local2.particle.prevPos.x) * 0.3);
_local2.particle.pos.y = _local2.particle.prevPos.y + ((_local2.particle.pos.y - _local2.particle.prevPos.y) * 0.3);
_local2._x = _local2.particle.pos.x;
_local2._y = _local2.particle.pos.y;
return(undefined);
}
_local10 = 0;
if (_local15) {
while (true) {
_local10++;
if (_local10 == _local2.hitCount) {
_local10 = 0;
}
if (!_local2.hitArray[_local10]) {
_local3 = -1;
_local7 = 0;
while (_local7 < _local2.hitCount) {
_local10++;
if (_local10 == _local2.hitCount) {
_local10 = 0;
}
if (_local3 == -1) {
if (_local2.hitArray[_local10]) {
_local3 = _local10;
_local5.plus(_local2.normalArray[_local10]);
}
} else if (!_local2.hitArray[_local10]) {
_local4 = _local10 - 1;
if (_local4 < 0) {
_local4 = _local2.hitCount - 1;
}
_local2.intersArray.push({k1:_local3, k2:_local4});
_local3 = -1;
} else {
_local5.plus(_local2.normalArray[_local10]);
}
_local7++;
}
break;
}
}
var _local6 = new CVector2D(0, 0);
if (_local2.intersArray.length > 0) {
_local5.normalize();
if (_local2.intersectionFlag) {
_local5.x = _local5.x + _local2.lastN.x;
_local5.y = _local5.y + _local2.lastN.y;
_local5.x = _local5.x / 2;
_local5.y = _local5.y / 2;
}
var _local12;
var _local13;
_local17 = _local2.intersArray.length;
_local10 = 0;
while (_local10 < _local17) {
_local12 = _local2.intersArray.pop();
_local3 = _local12.k1;
_local4 = _local12.k2;
_local2.particle.pos.minusNew(_local2.particle.prevPos).copyTo(_local6);
if (_local5.scalar(_local6) < 0) {
_local13 = Math.atan2(_local5.y, _local5.x);
_local6.rotate(-_local13);
_local6.x = (-_local6.x) * _local2.koeffSpring;
_local6.rotate(_local13);
_local2.pushOut(_local3, _local4, hit_mc);
_local2.particle.prevPos.x = _local2.particle.pos.x - _local6.x;
_local2.particle.prevPos.y = _local2.particle.pos.y - _local6.y;
} else {
_local2.pushOut(_local3, _local4, hit_mc);
}
_local10++;
}
_local2.validateRotation(_local5, _local18);
_local2.intersectionFlag = true;
_local2.particle.pos.copyTo(_local2.lastIntersPoint);
_local5.copyTo(_local2.lastN);
}
} else if (_local2.intersectionFlag) {
_local2.validateRotation(_local2.lastN, _local18);
_local2.intersectionFlag = false;
}
_local2._x = _local2.particle.pos.x;
_local2._y = _local2.particle.pos.y;
}
function pushOut(k1, k2, hit_mc) {
var _local2 = this;
var _local3;
if (k1 != k2) {
_local3 = _local2.normalArray[k1].plusNew(_local2.normalArray[k2]);
_local3.normalize();
var _local8 = new CVector2D(0, 0).getDistanceTo(_local2.hitPointArray[k1], _local2.hitPointArray[k2]);
_local8 = _local2.rad - Math.abs(_local8);
_local2.particle.pos.plus(_local3.multNew(_local8));
_local2.particle.prevPos.plus(_local3.multNew(_local8));
return(undefined);
}
_local3 = _local2.normalArray[k1];
var _local7 = _local3.multNew(-_local2.rad);
var _local5 = new CVector2D(0, 0);
var _local6 = 0;
var _local4 = 0.03;
_local7.copyTo(_local5);
_local2.localToGlobal(_local5);
if (hit_mc.hitTest(_local5.x, _local5.y, true)) {
_local6++;
_local2._x = (_local2.particle.pos.x = _local2.particle.pos.x + (_local3.x * _local4));
_local2._y = (_local2.particle.pos.y = _local2.particle.pos.y + (_local3.y * _local4));
// unexpected jump
}
_local6--;
_local2.particle.pos.x = _local2.particle.pos.x - (_local3.x * _local4);
_local2.particle.pos.y = _local2.particle.pos.y - (_local3.y * _local4);
_local2.particle.prevPos.plus(_local3.multNew(_local4 * _local6));
return(undefined);
}
function validateRotation(n, oldPos) {
var _local2 = this;
if ((!_local2.intersectionFlag) && (Math.abs(_local2.accSpeed) > 0.01)) {
if (Math.abs(_local2.accSpeed) < ((_local2.maxAccSpeed * 0.02) / 2)) {
_local2.accSpeed = 0;
} else if (_local2.accSpeed > 0) {
_local2.accSpeed = _local2.maxAccSpeed * 0.02;
} else {
_local2.accSpeed = (-_local2.maxAccSpeed) * 0.02;
}
}
var _local4 = new CVector2D(-n.y, n.x);
var _local7 = _local2.particle.pos.minusNew(oldPos);
var _local5 = Math.atan2(_local4.y, _local4.x);
var _local3 = _local7.rotateNew(-_local5);
_local2.speed = _local3.x + _local2.accSpeed;
_local3.y = 0;
_local3.rotate(_local5);
var _local6 = 1 - _local2.koeffSlip;
_local2.particle.pos.x = (_local2.particle.pos.x + ((_local4.x * _local2.accSpeed) * _local6)) - ((1 - _local2.koeffFriction) * _local3.x);
_local2.particle.pos.y = (_local2.particle.pos.y + ((_local4.y * _local2.accSpeed) * _local6)) - ((1 - _local2.koeffFriction) * _local3.y);
_local2.accSpeed = _local2.accSpeed * _local2.koeffSlip;
}
function applyAddedAcc() {
var _local2 = this;
_local2.particle.acc.x = _local2.particle.acc.x + (_local2.addedAcc.x * _local2.particle.mass);
_local2.particle.acc.y = _local2.particle.acc.y + (_local2.addedAcc.y * _local2.particle.mass);
}
var maxSpeed = 180;
var koeffSpring = 0.05;
var koeffSlip = 0.15;
var koeffFriction = 0.97;
var hitCount = 32;
}
Symbol 373 MovieClip [__Packages.CVector2D] Frame 0
class CVector2D
{
var x, y;
function CVector2D (x_, y_) {
x = x_;
y = y_;
}
function reinit(x_, y_) {
x = x_;
y = y_;
}
function getUgol() {
return(Math.atan2(y, x));
}
function duplicate() {
return(new CVector2D(x, y));
}
function copyTo(v) {
v.x = x;
v.y = y;
}
function minus(v) {
x = x - v.x;
y = y - v.y;
}
function minusNew(v) {
return(new CVector2D(x - v.x, y - v.y));
}
function normalize() {
var _local2 = this;
var _local3 = Math.sqrt((_local2.x * _local2.x) + (_local2.y * _local2.y));
_local2.x = _local2.x / _local3;
_local2.y = _local2.y / _local3;
}
function reverseNew() {
return(new CVector2D(-x, -y));
}
function scalar(v) {
return((x * v.x) + (y * v.y));
}
function modul() {
var _local2 = this;
Math.sqrt((_local2.x * _local2.x) + (_local2.y * _local2.y));
return(Math.sqrt((_local2.x * _local2.x) + (_local2.y * _local2.y)));
}
function reflectFromNormal(n) {
var _local2 = this;
var _local3 = Math.atan2(n.y, n.x);
_local2.rotate(-_local3);
_local2.x = -_local2.x;
_local2.rotate(_local3);
}
function rotate(u) {
var _local2 = u;
var _local3 = this;
var _local4 = _local3.x;
var _local5 = _local3.y;
_local3.x = (_local4 * Math.cos(_local2)) - (_local5 * Math.sin(_local2));
_local3.y = (_local4 * Math.sin(_local2)) + (_local5 * Math.cos(_local2));
}
function rotateNew(u) {
var _local2 = u;
var _local3 = this;
new CVector2D((_local3.x * Math.cos(_local2)) - (_local3.y * Math.sin(_local2)), (_local3.x * Math.sin(_local2)) + (_local3.y * Math.cos(_local2)));
return(new CVector2D((_local3.x * Math.cos(_local2)) - (_local3.y * Math.sin(_local2)), (_local3.x * Math.sin(_local2)) + (_local3.y * Math.cos(_local2))));
}
function mult(k) {
x = x * k;
y = y * k;
}
function multNew(k) {
return(new CVector2D(x * k, y * k));
}
function plus(v) {
x = x + v.x;
y = y + v.y;
}
function plusNew(v) {
return(new CVector2D(x + v.x, y + v.y));
}
function getDistanceTo(p1, p2) {
var _local4 = p1;
var _local3 = _local4.y - p2.y;
var _local2 = p2.x - _local4.x;
var _local5 = (_local4.x * (p2.y - _local4.y)) - (_local4.y * (p2.x - _local4.x));
var _local6 = Math.sqrt((_local3 * _local3) + (_local2 * _local2));
_local3 = _local3 / _local6;
_local2 = _local2 / _local6;
_local5 = _local5 / _local6;
((_local3 * x) + (_local2 * y)) + _local5;
return(((_local3 * x) + (_local2 * y)) + _local5);
}
}
Symbol 374 MovieClip [__Packages.CMan] Frame 0
class CMan extends MovieClip
{
var stopFlag, state, mc;
function CMan () {
super();
stopFlag = false;
state = 0;
}
function stopAnim() {
stopFlag = true;
}
function stopMCAnim() {
mc.stop();
}
function startAnim() {
stopFlag = false;
}
function onEnterFrame() {
var _local2 = this;
if (_local2.stopFlag) {
return(undefined);
}
if (Key.isDown(LEFT_BUTTON)) {
_local2.toLeft();
return(undefined);
}
if (Key.isDown(RIGHT_BUTTON)) {
_local2.toRight();
return(undefined);
}
if ((_local2.state == 1) || (_local2.state == 2)) {
_local2.fromLeft();
return(undefined);
}
if ((_local2.state == 4) || (_local2.state == 5)) {
_local2.fromRight();
}
}
function toLeft() {
var _local2 = this;
var _local3;
if (_local2.state == 0) {
_local2.state = 1;
_local2.gotoAndStop("toLeft");
_local2.state = 1;
return(undefined);
}
if (_local2.state == 3) {
_local3 = _local2.mc._currentframe;
_local2.gotoAndStop("toLeft");
_local2.mc.gotoAndPlay((ANIM_FRAMES - _local3) + 1);
_local2.state = 1;
return(undefined);
}
if ((_local2.state == 4) || (_local2.state == 5)) {
_local2.fromRight();
_local2.state = 6;
}
}
function toRight() {
var _local2 = this;
var _local3;
if (_local2.state == 0) {
_local2.state = 1;
_local2.gotoAndStop("toRight");
_local2.state = 4;
return(undefined);
}
if (_local2.state == 6) {
_local3 = _local2.mc._currentframe;
_local2.gotoAndStop("toRight");
_local2.mc.gotoAndPlay((ANIM_FRAMES - _local3) + 1);
_local2.state = 4;
return(undefined);
}
if ((_local2.state == 1) || (_local2.state == 2)) {
_local2.fromLeft();
_local2.state = 3;
}
}
function fromLeft() {
var _local2 = this;
var _local3;
if (_local2.state == 1) {
_local3 = _local2.mc._currentframe;
_local2.gotoAndStop("fromLeft");
_local2.mc.gotoAndPlay((ANIM_FRAMES - _local3) + 1);
_local2.state = 3;
return(undefined);
}
if (_local2.state == 2) {
_local2.gotoAndStop("fromLeft");
_local2.state = 3;
}
}
function fromRight() {
var _local2 = this;
var _local3;
if (_local2.state == 4) {
_local3 = _local2.mc._currentframe;
_local2.gotoAndStop("fromRight");
_local2.mc.gotoAndPlay((ANIM_FRAMES - _local3) + 1);
_local2.state = 6;
return(undefined);
}
if (_local2.state == 5) {
_local2.gotoAndStop("fromRight");
_local2.state = 6;
}
}
function endMove() {
var _local2 = this;
if (_local2.state == 1) {
_local2.gotoAndStop("left");
_local2.state = 2;
return(undefined);
}
if (_local2.state == 3) {
_local2.state = 0;
_local2.gotoAndStop("stay");
return(undefined);
}
if (_local2.state == 4) {
_local2.state = 5;
_local2.gotoAndStop("right");
return(undefined);
}
if (_local2.state == 6) {
_local2.state = 0;
_local2.gotoAndStop("stay");
}
}
static var LEFT_BUTTON = 37;
static var RIGHT_BUTTON = 39;
static var ANIM_FRAMES = 7;
}
Symbol 375 MovieClip [__Packages.CParticleEngine] Frame 0
class CParticleEngine
{
var hit_mc, prevTime;
function CParticleEngine () {
}
function clear() {
var _local2 = this;
while (_local2.p_array.pop() != undefined) {
}
while (_local2.w_array.pop() != undefined) {
}
while (_local2.c_array.pop() != undefined) {
}
}
function setHitMovie(hit_mc_) {
hit_mc = hit_mc_;
}
function addParticle(p) {
p_array.push(p);
}
function addWheel(wheel, p, maxSpeed, radius) {
wheel.init(p, maxSpeed, radius);
w_array.push(wheel);
}
function addSpringConstraint(p1, p2, koeffStiff1, koeffStiff2) {
var _local2 = new CSpringConstraint(p1, p2, koeffStiff1, koeffStiff2);
c_array.push(_local2);
}
function start() {
prevTime = getTimer();
}
function computeForces() {
var _local3 = this;
var _local2;
var _local4 = _local3.p_array.length;
_local2 = 0;
while (_local2 < _local4) {
_local3.p_array[_local2].acc.x = 0;
_local3.p_array[_local2].acc.y = _local3.gravity * _local3.p_array[_local2].mass;
_local2++;
}
}
function clearForces() {
var _local4 = w_array.length;
var _local2;
var _local3;
_local2 = 0;
while (_local2 < _local4) {
_local3 = w_array[_local2];
_local3.addedAcc.x = (_local3.addedAcc.y = 0);
_local2++;
}
}
function applyManFrictions() {
var _local3 = this;
var _local4 = _local3.w_array.length;
var _local2;
_local2 = 0;
while (_local2 < _local4) {
_local3.w_array[_local2].applyAddedAcc();
_local2++;
}
}
function verlet(dTime) {
var _local3 = this;
var _local7 = 0.995;
var _local2;
var _local4 = _local3.p_array.length;
_local2 = 0;
while (_local2 < _local4) {
_local3.p_array[_local2].verlet(dTime, _local7);
_local2++;
}
_local4 = _local3.w_array.length;
var _local6 = 0;
if (Key.isDown(40)) {
_local6 = -0.6;
} else if (Key.isDown(38)) {
_local6 = 1;
}
_local2 = 0;
while (_local2 < _local4) {
_local3.w_array[_local2].process(dTime, (_local3.w_array[_local2].maxAccSpeed * _local6) / 3.2, 0.99);
_local2++;
}
}
function checkCollisions() {
var _local3 = this;
var _local2;
var _local4 = _local3.w_array.length;
_local2 = 0;
while (_local2 < _local4) {
_local3.w_array[_local2].checkCollision(_local3.hit_mc);
_local2++;
}
}
function checkConstraints(dTime) {
var _local3 = this;
var _local2;
var _local4 = _local3.c_array.length;
_local2 = 0;
while (_local2 < _local4) {
_local3.c_array[_local2].resolve(dTime);
_local2++;
}
}
function process() {
var _local2 = this;
var _local5 = getTimer();
var _local6 = (_local5 - _local2.prevTime) / 1000;
_local2.prevTime = _local5;
var _local3;
var _local4 = Math.min(Math.round(_local6 / _local2.t), _local2.maxSteps);
_local3 = 0;
while (_local3 < _local4) {
_local2.computeForces();
_local2.applyManFrictions();
_local2.verlet(_local2.t);
_local2.checkConstraints(_local2.t);
_local2.checkCollisions();
_local3++;
}
_local2.clearForces();
}
var p_array = new Array();
var w_array = new Array();
var c_array = new Array();
var t = 0.02;
var maxSteps = 2;
var gravity = 3.15;
}
Symbol 376 MovieClip [__Packages.CSpringConstraint] Frame 0
class CSpringConstraint
{
function CSpringConstraint (p1_, p2_, koeffStiffPress_, koeffStiffStretch_) {
var _local2 = this;
_local2.p1 = p1_;
_local2.p2 = p2_;
_local2.koeffStiffPress = koeffStiffPress_;
_local2.koeffStiffStretch = koeffStiffStretch_;
var _local3 = new CVector2D(_local2.p1.pos.x - _local2.p2.pos.x, _local2.p1.pos.y - _local2.p2.pos.y);
_local2.relaxLen = _local3.modul();
}
function resolve(dTime) {
var _local2 = this;
var _local3 = new CVector2D(_local2.p1.pos.x - _local2.p2.pos.x, _local2.p1.pos.y - _local2.p2.pos.y);
var _local5 = _local3.modul();
var _local6 = (_local2.relaxLen - _local5) / _local5;
_local3.mult(_local6);
var _local4;
if (_local5 > _local2.relaxLen) {
_local4 = _local2.koeffStiffStretch;
} else {
_local4 = _local2.koeffStiffPress;
}
_local2.p2.pos.x = _local2.p2.pos.x - (((_local3.x * ((_local2.p1.mass / (_local2.p1.mass + _local2.p2.mass)) + 1)) / 2) * _local4);
_local2.p2.pos.y = _local2.p2.pos.y - (((_local3.y * ((_local2.p1.mass / (_local2.p1.mass + _local2.p2.mass)) + 1)) / 2) * _local4);
_local2.p1.pos.x = _local2.p1.pos.x + (((_local3.x * ((_local2.p2.mass / (_local2.p1.mass + _local2.p2.mass)) + 1)) / 2) * _local4);
_local2.p1.pos.y = _local2.p1.pos.y + (((_local3.y * ((_local2.p2.mass / (_local2.p1.mass + _local2.p2.mass)) + 1)) / 2) * _local4);
}
}
Symbol 377 MovieClip [__Packages.CParticle] Frame 0
class CParticle
{
function CParticle (x_, y_, mass_) {
var _local2 = this;
_local2.pos = new CVector2D(x_, y_);
_local2.prevPos = _local2.pos.duplicate();
_local2.mass = mass_;
_local2.acc = new CVector2D(0, 0);
_local2.mc = null;
}
function verlet(dTime, koeffDamp) {
var _local2 = this;
var _local3 = _local2.pos.duplicate();
_local2.pos.x = _local2.pos.x + (((_local2.pos.x - _local2.prevPos.x) * koeffDamp) + (_local2.acc.x * dTime));
_local2.pos.y = _local2.pos.y + (((_local2.pos.y - _local2.prevPos.y) * koeffDamp) + (_local2.acc.y * dTime));
_local3.copyTo(_local2.prevPos);
if (_local2.mc != null) {
_local2.mc._x = _local2.pos.x;
_local2.mc._y = _local2.pos.y;
}
}
}
Symbol 378 MovieClip [__Packages.CCamera] Frame 0
class CCamera
{
function CCamera () {
}
function init(targetMovie_, levelMovie_) {
var _local2 = this;
_local2.targetMovie = targetMovie_;
_local2.levelMovie = levelMovie_;
_local2.process();
}
function process() {
var _local2 = this;
var _local3 = {x:_local2.targetMovie._x, y:_local2.targetMovie._y};
_local2.targetMovie._parent.localToGlobal(_local3);
_local2.levelMovie._parent.globalToLocal(_local3);
_local2.levelMovie._x = _local2.levelMovie._x + (SCREEN_WIDTH2 - _local3.x);
_local2.levelMovie._y = _local2.levelMovie._y + (SCREEN_HEIGHT2 - _local3.y);
_local2.levelMovie._x = Math.round(_local2.levelMovie._x);
_local2.levelMovie._y = Math.round(_local2.levelMovie._y);
if (_local2.levelMovie._x > 0) {
_local2.levelMovie._x = 0;
} else if ((_local2.levelMovie._x + _local2.levelMovie._width) < SCREEN_WIDTH) {
_local2.levelMovie._x = SCREEN_WIDTH - _local2.levelMovie._width;
}
if (_local2.levelMovie._y < 0) {
_local2.levelMovie._y = 0;
}
}
static var SCREEN_WIDTH = 500;
static var SCREEN_HEIGHT = 400;
static var SCREEN_WIDTH2 = SCREEN_WIDTH / 2;
static var SCREEN_HEIGHT2 = SCREEN_HEIGHT / 2;
}
Symbol 379 MovieClip [__Packages.CBack] Frame 0
class CBack
{
function CBack () {
}
function init(mc1_, mc2_, scaleFactor_) {
var _local2 = this;
_local2.mc1 = mc1_;
_local2.mc2 = mc2_;
_local2.scaleFactor = scaleFactor_;
}
function process(levelX) {
var _local2 = this;
var _local3 = levelX;
_local3 = Math.abs(Math.round(_local3) / _local2.scaleFactor) % _local2.mc1._width;
_local2.mc1._x = -_local3;
_local2.mc2._x = (_local2.mc1._x + _local2.mc1._width) - 1;
}
static var SCREEN_WIDTH = 500;
}
Symbol 380 MovieClip [__Packages.CBikeSynchronizer] Frame 0
class CBikeSynchronizer
{
function CBikeSynchronizer () {
var _local2 = this;
_local2.fdir = new CVector2D(0, 0);
_local2.fpos = new CVector2D(0, 0);
_local2.bdir = new CVector2D(0, 0);
_local2.bpos = new CVector2D(0, 0);
}
function init(mc_container, sX, sY) {
var _local2 = this;
var _local4 = mc_container;
var _local3 = {x:0, y:0};
_local2.mc_back_wheel = _local4.attachMovie("lib_back_wheel", "back_w", 2);
_local2.mc_forward_wheel = _local4.attachMovie("lib_forward_wheel", "forward_w", 1);
_local2.mc_bike = _local4.attachMovie("lib_bike_body", "body", 0);
_local2.mc_bike._x = sX;
_local2.mc_bike._y = sY;
_local3.x = _local2.mc_bike.mc.mc_s_wheel_back._x;
_local3.y = _local2.mc_bike.mc.mc_s_wheel_back._y;
_local2.mc_bike.mc.localToGlobal(_local3);
_local2.mc_bike._parent.globalToLocal(_local3);
_local2.mc_back_wheel._x = _local3.x;
_local2.mc_back_wheel._y = _local3.y;
_local3.x = _local2.mc_bike.mc.mc_s_wheel_forward._x;
_local3.y = _local2.mc_bike.mc.mc_s_wheel_forward._y;
_local2.mc_bike.mc.localToGlobal(_local3);
_local2.mc_bike._parent.globalToLocal(_local3);
_local2.mc_forward_wheel._x = _local3.x;
_local2.mc_forward_wheel._y = _local3.y;
}
function setParticles(pBody_, pBWheel_, pFWheel_) {
var _local2 = this;
_local2.pBody = pBody_;
_local2.pBWheel = pBWheel_;
_local2.pFWheel = pFWheel_;
_local2.fdir.reinit(_local2.mc_bike.mc.mc_f_point._x - _local2.mc_bike.mc.mc_s_wheel_forward._x, _local2.mc_bike.mc.mc_f_point._y - _local2.mc_bike.mc.mc_s_wheel_forward._y);
_local2.fdir.normalize();
_local2.fpos.x = _local2.mc_bike.mc.mc_f_spring._x + ((_local2.fdir.x * (-_local2.mc_bike.mc.mc_f_spring._y)) / _local2.fdir.y);
_local2.fpos.x = _local2.fpos.x - _local2.mc_bike.mc.mc_body_man._x;
_local2.bpos.reinit(_local2.mc_bike.mc.mc_b_spring.mc_top._x, _local2.mc_bike.mc.mc_b_spring.mc_top._y);
_local2.mc_bike.mc.mc_b_spring.localToGlobal(_local2.bpos);
_local2.bdir.reinit(_local2.bpos.x, _local2.bpos.y);
_local2.mc_bike.mc.mc_body_man.globalToLocal(_local2.bpos);
_local2.mc_bike.mc.globalToLocal(_local2.bdir);
_local2.bdir.x = _local2.bdir.x - _local2.mc_bike.mc.mc_b_spring._x;
_local2.bdir.y = _local2.bdir.y - _local2.mc_bike.mc.mc_b_spring._y;
}
function process() {
var _local2 = this;
var _local3 = {x:0, y:0};
var _local4;
_local2.mc_bike._x = _local2.pBody.pos.x;
_local2.mc_bike._y = _local2.pBody.pos.y;
_local4 = _local2.pFWheel.pos.minusNew(_local2.pBWheel.pos);
_local2.mc_bike._rotation = (Math.atan2(_local4.y, _local4.x) * 180) / 3.141593;
_local3.x = _local2.pFWheel.pos.x;
_local3.y = _local2.pFWheel.pos.y;
_local2.mc_bike._parent.localToGlobal(_local3);
_local2.mc_bike.mc.globalToLocal(_local3);
_local2.mc_bike.mc.mc_f_spring._x = _local3.x;
_local2.mc_bike.mc.mc_f_spring._y = _local3.y;
var _local5 = ((_local3.x + ((_local2.fdir.x * (-_local3.y)) / _local2.fdir.y)) - _local2.mc_bike.mc.mc_body_man._x) - _local2.fpos.x;
_local2.mc_bike.mc.mc_body_man._x = _local2.mc_bike.mc.mc_body_man._x + _local5;
_local3.x = _local2.mc_bike.mc.mc_f_spring.mc_spring._x;
_local3.y = _local2.mc_bike.mc.mc_f_spring.mc_spring._y;
_local2.mc_bike.mc.mc_f_spring.localToGlobal(_local3);
_local2.mc_bike.mc.globalToLocal(_local3);
_local3.x = _local2.pBWheel.pos.x;
_local3.y = _local2.pBWheel.pos.y;
_local2.mc_bike._parent.localToGlobal(_local3);
_local2.mc_bike.mc.globalToLocal(_local3);
_local2.mc_bike.mc.mc_b_spring._x = _local3.x;
_local2.mc_bike.mc.mc_b_spring._y = _local3.y;
_local4.reinit(_local2.bpos.x, _local2.bpos.y);
_local2.mc_bike.mc.mc_body_man.localToGlobal(_local4);
_local2.mc_bike.mc.globalToLocal(_local4);
_local4.x = _local4.x - _local2.mc_bike.mc.mc_b_spring._x;
_local4.y = _local4.y - _local2.mc_bike.mc.mc_b_spring._y;
_local2.mc_bike.mc.mc_b_spring._rotation = ((_local4.getUgol() - _local2.bdir.getUgol()) * 180) / 3.141593;
}
}
Symbol 95 MovieClip Frame 62
stop();
Symbol 98 MovieClip Frame 31
stop();
Symbol 100 MovieClip Frame 20
stop();
Symbol 103 MovieClip Frame 20
stop();
Symbol 128 MovieClip Frame 62
stop();
Symbol 146 MovieClip Frame 3
stop();
Symbol 155 Button
on (press) {
gotoAndPlay (230);
}
Symbol 158 MovieClip Frame 3
stop();
Symbol 159 Button
on (release) {
getURL ("http://www.gamesforgirlz.net/", "_blank");
}
Symbol 171 Button
on (release) {
gotoAndPlay (244);
_root.lvls = 1;
}
on (rollOver) {
sta.gotoAndPlay(2);
}
on (rollOut) {
sta.gotoAndPlay(11);
}
Symbol 174 Button
on (release) {
_root.gotoAndStop("help");
}
on (rollOver) {
hel.gotoAndPlay(2);
}
on (rollOut) {
hel.gotoAndPlay(11);
}
Symbol 180 MovieClip Frame 1
stop();
Symbol 188 MovieClip Frame 1
stop();
Symbol 189 MovieClip Frame 1
tyre.gotoAndStop(_root.jeepselection);
Symbol 191 MovieClip [lib_back_wheel] Frame 1
#initclip 12
Object.registerClass("lib_back_wheel", CWheel);
#endinitclip
Symbol 192 MovieClip [lib_forward_wheel] Frame 1
#initclip 10
Object.registerClass("lib_forward_wheel", CWheel);
#endinitclip
Symbol 227 MovieClip Frame 1
stop();
Symbol 228 MovieClip Frame 1
stop();
Symbol 236 MovieClip [lib_man] Frame 1
#initclip 11
Object.registerClass("lib_man", CMan);
#endinitclip
this.stop();
Symbol 238 MovieClip Frame 1
jeep.gotoAndStop(_root.jeepselection);
Symbol 240 MovieClip Frame 1
#initclip 13
function updateSoundLoop() {
if (!stopSoundFlag) {
if (zastSoundFlag) {
mc_sloop.gotoAndStop(3);
mc_sloop_zast.gotoAndStop(2);
} else {
mc_sloop.gotoAndStop(2);
mc_sloop_zast.gotoAndStop(3);
}
}
}
function soundOff() {
if (zastSoundFlag) {
mc_sloop_zast.gotoAndStop(3);
} else {
mc_sloop.gotoAndStop(3);
}
stopSoundFlag = true;
}
function soundOn() {
if (zastSoundFlag) {
mc_sloop_zast.gotoAndStop(2);
} else {
mc_sloop.gotoAndStop(2);
}
stopSoundFlag = false;
}
function gameStart() {
scores = 0;
timeCounter = 0;
stargeted = 0;
life = 10;
zastSoundFlag = false;
updateSoundLoop();
level = 0;
nextLevel();
}
function nextLevel() {
stargeted = 0;
levelTimeCounter = 0;
if (level == 10) {
newGame();
return(undefined);
}
level++;
this.gotoAndStop("reset");
this.gotoAndStop("game");
}
function replay() {
stargeted = 0;
this.gotoAndStop("reset");
this.gotoAndStop("game");
}
function newGame() {
stargeted = 0;
zastSoundFlag = true;
updateSoundLoop();
this.gotoAndStop("main");
}
function playSnd(lib_snd) {
s = new Sound(this);
s.attachSound(lib_snd);
s.start();
}
function initLevel() {
lastTimer = getTimer();
mc_level.mc_minimap._visible = true;
mc_level.mc_minimap.mc_stage.gotoAndStop(level);
if (level > 1) {
var _local1 = 1;
while (_local1 < level) {
mc_level.mc_minimap["s" + _local1].gotoAndStop(2);
_local1++;
}
}
mc_level.mc_minimap["s" + level].gotoAndStop(3);
mc_level.gotoAndStop(level);
mc_level.mc.mc_hit._visible = false;
if (bikeSync == null) {
bikeSync = new CBikeSynchronizer();
engine = new CParticleEngine();
objCamera = new CCamera();
back1 = new CBack();
back2 = new CBack();
} else {
engine.clear();
}
back1.init(mc_level.mc.mc_fon.mc_grass.mc1, mc_level.mc.mc_fon.mc_grass.mc2, 1);
back2.init(mc_level.mc.mc_fon.mc_hill.mc1, mc_level.mc.mc_fon.mc_hill.mc2, 2);
bikeSync.init(mc_level.mc.mc_bike, 0, 0);
var _local2 = new CParticle(bikeSync.mc_back_wheel._x, bikeSync.mc_back_wheel._y, 3);
engine.addParticle(_local2);
engine.addWheel(bikeSync.mc_back_wheel, _local2, 28.5, 17.5);
var _local4 = new CParticle(bikeSync.mc_forward_wheel._x, bikeSync.mc_forward_wheel._y, 3);
engine.addParticle(_local4);
engine.addWheel(bikeSync.mc_forward_wheel, _local4, 10.5, 17.5);
var _local3 = new CParticle(bikeSync.mc_bike._x, bikeSync.mc_bike._y, 3);
_local3.mc = mc_level.mc.mc_bike.mc_test;
engine.addParticle(_local3);
engine.addSpringConstraint(_local2, _local4, 0.45, 0.5);
engine.addSpringConstraint(_local2, _local3, 0.45, 0.55);
engine.addSpringConstraint(_local3, _local4, 0.45, 0.7);
bikeSync.setParticles(_local3, _local2, _local4);
objCamera.init(bikeSync.mc_bike, mc_level.mc);
engine.setHitMovie(mc_level.mc.mc_hit);
engine.start();
accFlag = false;
accCounter = 50;
if (!stopSoundFlag) {
mc_sloop.gotoAndStop(2);
}
mc_messageF.gotoAndStop(1);
mc_messageF.mc_message.gotoAndStop("empty");
gameState = 0;
var _local1 = 1;
while (_local1 <= 10) {
mc_level.mc["s" + _local1].gotoAndStop(Math.floor((Math.random() * 3) + 1));
_local1++;
}
}
function processGame() {
var _local7;
var _local6;
_local7 = getTimer();
_local6 = _local7 - lastTimer;
txtFps = 1 / (_local6 / 1000);
lastTimer = _local7;
if (gameState == 0) {
timeCounter = timeCounter + _local6;
levelTimeCounter = levelTimeCounter + _local6;
showTime();
var _local8 = 0;
var _local9 = 0;
var _local3;
var _local5;
accCounter++;
if (!accFlag) {
accFlag = Key.isDown(38);
if (accFlag && (accCounter > 10)) {
accCounter = 0;
if (!stopSoundFlag) {
mc_gas.gotoAndPlay(2);
}
}
} else {
accFlag = Key.isDown(38);
}
if (Key.isDown(CMan.LEFT_BUTTON)) {
_local3 = calcBikeNVector();
if (_local3.y > 0) {
_local5 = (Math.abs(_local3.y) * 0.2) + 0.8;
bikeSync.mc_forward_wheel.addedAcc.x = bikeSync.mc_forward_wheel.addedAcc.x - (((_local3.x * engine.gravity) / 1.1) * _local5);
bikeSync.mc_forward_wheel.addedAcc.y = bikeSync.mc_forward_wheel.addedAcc.y - (((_local3.y * engine.gravity) * 1.3) * _local5);
bikeSync.mc_back_wheel.addedAcc.x = bikeSync.mc_back_wheel.addedAcc.x + (((_local3.x * engine.gravity) / 1.5) * _local5);
bikeSync.mc_back_wheel.addedAcc.y = bikeSync.mc_back_wheel.addedAcc.y + ((_local3.y * engine.gravity) * _local5);
}
} else if (Key.isDown(CMan.RIGHT_BUTTON)) {
_local3 = calcBikeNVector();
if (_local3.y > 0) {
_local5 = (Math.abs(_local3.y) * 0.2) + 0.8;
bikeSync.mc_forward_wheel.addedAcc.x = bikeSync.mc_forward_wheel.addedAcc.x + (((_local3.x * engine.gravity) / 1.5) * _local5);
bikeSync.mc_forward_wheel.addedAcc.y = bikeSync.mc_forward_wheel.addedAcc.y + ((_local3.y * engine.gravity) * _local5);
bikeSync.mc_back_wheel.addedAcc.x = bikeSync.mc_back_wheel.addedAcc.x - (((_local3.x * engine.gravity) / 1.1) * _local5);
bikeSync.mc_back_wheel.addedAcc.y = bikeSync.mc_back_wheel.addedAcc.y - (((_local3.y * engine.gravity) * 1.3) * _local5);
}
}
engine.process();
bikeSync.process();
objCamera.process();
back1.process(mc_level.mc._x);
back2.process(mc_level.mc._x);
mc_level.mc.mc_fon._x = -mc_level.mc._x;
var _local1 = 1;
while (_local1 <= 20) {
if (((mc_level.mc["s" + _local1]._visible == true) && (bikeSync.mc_bike.hitTest(mc_level.mc["s" + _local1]))) && (!mc_level.mc["s" + _local1].bikehit)) {
mc_level.mc["s" + _local1].bikehit = true;
mc_level.mc["s" + _local1].pio.gotoAndPlay(2);
}
_local1++;
}
if (((bikeSync.mc_bike._x + mc_level.mc.mc_bike._x) >= mc_level.mc.mc_finish._x) && (stargeted >= 3)) {
if (!stopSoundFlag) {
mc_sloop.gotoAndStop(3);
}
if (level <= 10) {
gotoAndStop ("comple");
gameState = 2;
} else {
mc_messageF.mc_message.gotoAndStop("gamewin");
gameState = 3;
}
addLevelScores();
mc_messageF.mc_message.levelTime = getTimeString(levelTimeCounter);
mc_messageF.mc_message.commonTime = getTimeString(timeCounter);
mc_messageF.mc_message.scores = scores;
bikeSync.mc_bike.mc.mc_body_man.mc.stopAnim();
bikeSync.mc_bike.mc.mc_body_man.mc.stopMCAnim();
return(undefined);
}
var _local2 = {x:0, y:0};
var _local4 = bikeSync.mc_bike.mc.mc_body_man.mc.mc.h;
_local2.x = _local4.p._x;
_local2.y = _local4.p._y;
_local4.localToGlobal(_local2);
if (mc_level.mc.mc_hit.hitTest(_local2.x, _local2.y, true)) {
loose();
return(undefined);
}
_local4 = bikeSync.mc_bike.mc.mc_body_man.mc.mc.b;
_local2.x = _local4.p._x;
_local2.y = _local4.p._y;
_local4.localToGlobal(_local2);
if (mc_level.mc.mc_hit.hitTest(_local2.x, _local2.y, true)) {
loose();
return(undefined);
}
_local4 = bikeSync.mc_bike.mc.mc_body_man.mc.mc.l;
_local2.x = _local4.p._x;
_local2.y = _local4.p._y;
_local4.localToGlobal(_local2);
if (mc_level.mc.mc_hit.hitTest(_local2.x, _local2.y, true)) {
loose();
}
}
}
function showTime() {
txtTime = getTimeString(timeCounter);
}
function getTimeString(time) {
var _local1 = Math.round(time / 1000);
var _local2 = Math.floor(_local1 / 60);
_local1 = _local1 - (_local2 * 60);
var _local4;
var _local3;
if (_local1 < 10) {
_local3 = "0" + _local1;
} else {
_local3 = "" + _local1;
}
if (_local2 < 10) {
_local4 = "0" + _local2;
} else {
_local4 = "" + _local2;
}
(_local4 + ":") + _local3;
return((_local4 + ":") + _local3);
}
function resume() {
if (!stopSoundFlag) {
mc_sloop.gotoAndStop(2);
}
mc_messageF.gotoAndStop(1);
mc_messageF.mc_message.gotoAndStop("empty");
bikeSync.mc_bike.mc.mc_body_man.mc.startAnim();
gameState = 0;
}
function pauseGame() {
if (!stopSoundFlag) {
mc_sloop.gotoAndStop(3);
}
mc_messageF.mc_message.gotoAndStop("pause");
bikeSync.mc_bike.mc.mc_body_man.mc.stopAnim();
gameState = 4;
}
function loose() {
if (!stopSoundFlag) {
mc_sloop.gotoAndStop(3);
}
if (!stopSoundFlag) {
playSnd("lib_snd_fail");
}
mc_messageF.gotoAndPlay(2);
_root.life--;
bikeSync.mc_back_wheel._x = bikeSync.mc_back_wheel._x + 1000;
bikeSync.mc_forward_wheel._x = bikeSync.mc_forward_wheel._x + 1000;
_root.bikeSync.mc_bike.mc.jeep.car1.gotoAndPlay(2);
_root.bikeSync.mc_bike.mc.jeep.car2.gotoAndPlay(2);
_root.bikeSync.mc_bike.mc.jeep.car3.gotoAndPlay(2);
_root.crash.gotoAndPlay(2);
_root.scores = 0;
mc_messageF.mc_message.levelTime = getTimeString(levelTimeCounter);
mc_messageF.mc_message.commonTime = getTimeString(timeCounter);
mc_messageF.mc_message.scores = scores;
bikeSync.mc_bike.mc.mc_body_man.mc.stopAnim();
bikeSync.mc_bike.mc.mc_body_man.mc.stopMCAnim();
gameState = 1;
}
function calcBikeNVector() {
var _local1;
_local1 = bikeSync.mc_forward_wheel.particle.pos.minusNew(bikeSync.mc_back_wheel.particle.pos);
_local1.normalize();
var _local2;
_local2 = _local1.x;
_local1.x = -_local1.y;
_local1.y = _local2;
return(_local1);
}
var lastTimer;
var level;
var stopSoundFlag = false;
var bikeSync = null;
var engine = null;
var objCamera = null;
var back1 = null;
var back2 = null;
var gameState;
var zastSoundFlag = true;
var accFlag;
var accCounter;
var timeCounter;
var levelTimeCounter;
var scores;
var highQuality = true;
var life = 10;
var stargeted;
#endinitclip
Symbol 244 Button
on (release) {
gameStart();
_root.lvls = 1;
}
on (rollOver) {
sta.gotoAndPlay(2);
}
on (rollOut) {
sta.gotoAndPlay(11);
}
Symbol 253 MovieClip Frame 1
var bgss = (1 + random(5));
bg.gotoAndStop(bgss);
Symbol 271 MovieClip Frame 1
stop();
Symbol 271 MovieClip Frame 14
_root.stargeted++;
_root.scorecard = Number(_root.scorecard) + Number(100);
_root.scorecard2 = _root.scorecard;
Symbol 271 MovieClip Frame 29
stop();
Symbol 272 MovieClip Frame 1
stop();
Symbol 275 MovieClip Frame 1
stop();
Symbol 276 MovieClip Frame 1
var bgss = (1 + random(5));
bg.gotoAndStop(bgss);
Symbol 331 MovieClip Frame 1
stop();
Symbol 331 MovieClip Frame 2
stopAllSounds();
_root.cra.start(0, 1);
Symbol 331 MovieClip Frame 51
onEnterFrame = function () {
_root.lifee = _root.lifee - 1;
_root.replay();
};
Symbol 347 Button
on (release) {
gameStart();
}
on (rollOver) {
nex.gotoAndPlay(2);
}
on (rollOut) {
nex.gotoAndPlay(11);
}
Symbol 351 Button
on (release) {
gotoAndPlay (246);
}
Symbol 358 MovieClip Frame 1
stop();
Symbol 358 MovieClip Frame 2
stop();
Symbol 361 MovieClip Frame 1
stop();
Symbol 361 MovieClip Frame 10
stop();
Symbol 364 Button
on (release) {
_root.gotoAndStop("main");
}
on (rollOver) {
men.gotoAndPlay(1);
}
on (rollOut) {
men.gotoAndPlay(11);
}
Symbol 368 Button
on (release) {
gotoAndPlay (247);
}