Frame 1
function gotoURL() {
getURL ("http://www.amoebastudios.com");
}
function randomRange(min, max) {
var _local1 = Math.floor(Math.random() * ((max - min) + 1)) + min;
return(_local1);
}
var newMenu = new ContextMenu();
newMenu.hideBuiltInItems();
this.menu = newMenu;
_root.playIntro = true;
_root.allSounds = new Sound();
_root.score = 0;
_root.timeScore = 0;
_root.levelScore = 0;
_root.isPause = false;
_root.levelArray = ["lblgame", "level2", "level3", "level4", "win"];
_root.level = 1;
_root.isEasy = false;
_root.playIntroSound = true;
_root.playerId = 1;
_root.isOver = false;
Frame 2
Frame 3
function displayScores(mc) {
names = _root.topnickname.split(",");
scores = _root.topscore.split(",");
i = 0;
while (i <= 19) {
if (names[i] == undefined) {
names[i] = "";
}
if (scores[i] == undefined) {
scores[i] = "";
}
eval ((mc + ".n") + (i + 1)).text = names[i];
eval ((mc + ".p") + (i + 1)).text = scores[i];
i++;
}
}
function cancelSubmit(mc, useridframe) {
trace("cancelSubmit");
delete _root.send_lv.onLoad;
_root.skipsubmit = true;
mc.gotoAndStop(useridframe);
}
function _newUser() {
getURL (_root._registerurl, "_blank");
}
function _trackClickThru(mc) {
if (_root._allowclick) {
mc.hit_area.onRelease = function () {
getURL (_root._clickthru, "_blank");
};
} else {
mc.hit_area.useHandCursor = false;
}
}
function _resetUsername(txt) {
txt.onSetFocus = function () {
if ((this.text == _root._msgValid) or (this.text == "Connecting Error!")) {
this.text = "";
}
};
}
function _readSharedData() {
_root.so_uname = ((_root._sostatus.data.so_uname == undefined) ? "" : (_root._sostatus.data.so_uname));
_root.so_jumpframe = ((_root._sostatus.data.so_jumpframe == undefined) ? "" : (_root._sostatus.data.so_jumpframe));
_root.so_sound = ((_root._sostatus.data.so_sound == undefined) ? 1 : (_root._sostatus.data.so_sound));
_resetString = _root._sostatus.data.so_resetString;
trace("==========================");
trace((("_root.so_jumpframe : " + _root._sostatus.data.so_jumpframe) + " : ") + _root.so_uname);
if (_root.so_jumpframe != "") {
_assignValue(_resetString);
_root.createEmptyMovieClip("eye", _root.getNextHighestDepth());
_root.eye.onEnterFrame = function () {
if ((_root.getBytesTotal() == _root.getBytesLoaded()) and (_root.getBytesLoaded() > 50000)) {
_root.intro = 0;
_root._sostatus.data.so_jumpframe = "";
_root._sostatus.flush();
this.onEnterFrame = null;
_root.gotoAndStop(_root.so_jumpframe);
}
};
} else {
_root.intro = 1;
play();
}
_root.uname = _root.so_uname;
_root.gamesound = _root.so_sound;
}
function _writeSharedData(jumpframe, jumpurl, _resetString) {
_root._sostatus.data.so_uname = ((_root.so_uname == undefined) ? "" : (_root.so_uname));
_root._sostatus.data.so_sound = _root.so_sound;
_root._sostatus.data.so_resetString = _resetString;
_root._sostatus.data.so_jumpframe = jumpframe;
_root._sostatus.flush();
if (jumpurl != "") {
getURL (jumpurl);
} else {
gotoAndPlay (1);
}
}
function _assignValue(_val) {
_arr = new Array();
_arr = _val.split("|");
i = 0;
while (i < (_arr.length / 2)) {
_var2 = ((i * 2) + 1) - 1;
_var3 = _var2 + 1;
_root[_arr[_var2]] = _arr[_var3];
i++;
}
}
function _playAgain(mc, jumpframe, _resetString) {
_root.so_uname = _root.uname;
if ((_root.gurl != undefined) and (_root.gurl != "")) {
_writeSharedData(jumpframe, _root.gurl, _resetString);
} else {
_root.intro = 0;
_assignValue(_resetString);
mc.gotoAndStop(jumpframe);
}
}
_root._google_txt.text = "Gully Cricket";
_root._gameid = "1043";
_root._clickthru = "http://www.games2win.com";
_root._customer_id = "games2win";
_root.uname = "";
_root.submiturl = "/gamesubmit.asp";
_root.topnickname = [];
_root.topscore = [];
dataSubmit = function (myname, myscore, mygameid, destmc, useridframe, connframe, top10frame, _ord) {
trace("dataSubmit");
_root.skipsubmit = false;
myname = myname.trim();
_loc = eval (destmc);
if (((myname.length == 0) or (myname == "Invalid Nickname!")) or (myname == "Connecting Error!")) {
_root.uname = "Invalid Nickname!";
} else {
_root.send_lv = new LoadVars();
_root.send_lv.onLoad = function (success) {
if (success and (!_root.skipsubmit)) {
if (_root.send_lv.isreg == 0) {
_root.uname = "Invalid Nickname!";
_loc.gotoAndStop(useridframe);
} else if (_root.send_lv.isreg == 1) {
_root.topnickname = send_lv.topnicknames;
_root.topscore = send_lv.topscores;
_loc.gotoAndPlay(top10frame);
}
}
};
_root.send_lv.nickname = myname;
_root.send_lv.points = myscore;
_root.send_lv.gameid = mygameid;
_root.send_lv.order = _ord;
_root.send_lv.sendAndLoad(submiturl, _root.send_lv, "POST");
_loc.gotoAndPlay(connframe);
}
};
String.prototype.trim = function () {
var _local3 = 0;
var _local2 = this.length;
white = new Object();
white._32 = 1;
_local2--;
while (white["_" + ord(this.charAt(_local2))]) {
}
while (white["_" + ord(this.charAt(_local3++))]) {
}
return(this.slice(_local3 - 1, _local2 + 1));
};
_root._registerurl = "http://www.games2win.com/register.asp";
_root._allowclick = true;
var _sostatus = SharedObject.getLocal("gamestatus", "/");
_readSharedData();
Frame 4
Frame 5
Frame 6
stop();
Frame 7
stop();
stopAllSounds();
Frame 8
stopAllSounds();
Frame 9
stop();
Instance of Symbol 115 MovieClip in Frame 9
on (release) {
this.gotoAndPlay(_currentframe + 1);
}
Frame 10
stop();
Frame 11
stop();
Frame 12
Frame 13
stop();
stopAllSounds();
_root.level = 1;
_root.hud_mc._visible = true;
_root.carsKissed = 0;
_root.RhitLady = 0;
Frame 14
stop();
stopAllSounds();
_root.level = 2;
_root.hud_mc._visible = true;
_root.carsKissed = 0;
_root.RhitLady = 0;
Frame 15
stop();
stopAllSounds();
_root.level = 3;
_root.hud_mc._visible = true;
_root.carsKissed = 0;
_root.RhitLady = 0;
Frame 16
stop();
stopAllSounds();
_root.level = 4;
_root.hud_mc._visible = true;
_root.carsKissed = 0;
_root.RhitLady = 0;
Frame 17
stop();
_root._win = true;
Frame 18
stop();
stopAllSounds();
_root._win = false;
Frame 19
stop();
Frame 20
stop();
Frame 21
stop();
Symbol 591 MovieClip [__Packages.classes.CollisionDetection] Frame 0
class classes.CollisionDetection
{
function CollisionDetection () {
}
static function checkForCollision(p_clip1, p_clip2, p_alphaTolerance, p_scope) {
if (p_alphaTolerance == undefined) {
p_alphaTolerance = 255;
}
if (p_scope == undefined) {
p_scope = p_clip2._parent;
}
var _local3 = p_clip1.getBounds(p_scope);
var _local2 = p_clip2.getBounds(p_scope);
if (((_local3.xMax < _local2.xMin) || (_local2.xMax < _local3.xMin)) || ((_local3.yMax < _local2.yMin) || (_local2.yMax < _local3.yMin))) {
return(null);
}
var _local1 = {};
_local1.xMin = Math.max(_local3.xMin, _local2.xMin);
_local1.xMax = Math.min(_local3.xMax, _local2.xMax);
_local1.yMin = Math.max(_local3.yMin, _local2.yMin);
_local1.yMax = Math.min(_local3.yMax, _local2.yMax);
var _local8 = new flash.display.BitmapData(_local1.xMax - _local1.xMin, _local1.yMax - _local1.yMin, false);
var _local4 = p_clip1.transform.matrix;
_local4.tx = p_clip1._x - _local1.xMin;
_local4.ty = p_clip1._y - _local1.yMin;
_local8.draw(p_clip1, _local4, new flash.geom.ColorTransform(1, 1, 1, 1, 255, -255, -255, p_alphaTolerance));
_local4 = p_clip2.transform.matrix;
_local4.tx = p_clip2._x - _local1.xMin;
_local4.ty = p_clip2._y - _local1.yMin;
_local8.draw(p_clip2, _local4, new flash.geom.ColorTransform(1, 1, 1, 1, 255, 255, 255, p_alphaTolerance), "difference");
var _local6 = _local8.getColorBoundsRect(4294967295, 4278255615);
if (_local6.width == 0) {
return(null);
}
_local6.x = _local6.x + _local1.xMin;
_local6.y = _local6.y + _local1.yMin;
return(_local6);
}
}
Symbol 5 MovieClip Frame 1
_root._trackClickThru(this);
Symbol 10 MovieClip Frame 100
stop();
_root.gotoAndStop("lblloader");
Symbol 49 MovieClip Frame 1
var total = _root.getBytesTotal();
var loaded = 0;
var percent = 0;
var percent99;
onEnterFrame = function () {
if (percent <= 100) {
loaded = _root.getBytesLoaded();
percent = Math.ceil((loaded / total) * 100);
percent99 = percent + "%";
if (loaded == total) {
_root.gotoAndStop("lblgameintro");
}
}
};
Symbol 77 MovieClip Frame 20
stop();
Symbol 87 MovieClip Frame 1
stop();
Symbol 87 MovieClip Frame 2
stop();
Symbol 90 MovieClip Frame 32
stop();
Symbol 93 MovieClip Frame 3
stop();
Symbol 111 MovieClip Frame 1
if (!_root.playIntro) {
gotoAndStop(_totalframes);
}
if (_root.playIntroSound) {
stopAllSounds();
sound_mc.gotoAndStop(2);
}
_root.playIntroSound = false;
_root.playIntro = false;
Symbol 111 MovieClip Frame 35
stop();
story_btn.onRelease = function () {
_root.gotoAndStop("story");
};
instructions_btn.onRelease = function () {
_root.gotoAndStop("instructions");
};
start_btn.onRelease = function () {
_root.gotoAndStop("lblgame");
};
Symbol 115 MovieClip Frame 1
stop();
_root.allSounds.setVolume(100);
Symbol 115 MovieClip Frame 2
stop();
_root.allSounds.setVolume(0);
Symbol 150 MovieClip Frame 55
stop();
start_btn.onRelease = function () {
_root.gotoAndStop("lblgame");
};
back_btn.onRelease = function () {
_root.gotoAndStop("lblgameintro");
};
Symbol 151 MovieClip Frame 11
stop();
Symbol 161 MovieClip Frame 10
stop();
Symbol 170 MovieClip Frame 30
stop();
start_btn.onRelease = function () {
_root.gotoAndStop("lblgame");
};
back_btn.onRelease = function () {
_root.gotoAndStop("lblgameintro");
};
Symbol 173 MovieClip Frame 37
stop();
Symbol 182 MovieClip Frame 1
var xpos = this._x;
var ypos = this._y;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 30) {
_y = ypos;
_x = xpos;
}
}
};
Symbol 184 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
}
}
};
Symbol 185 MovieClip Frame 1
var xpos = this._x;
var ypos = this._y;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 30) {
_y = ypos;
_x = xpos;
}
}
};
Symbol 188 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
}
}
};
Symbol 190 MovieClip Frame 1
Symbol 191 MovieClip Frame 1
var xpos = this._x;
var ypos = -500;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 600) {
_y = ypos;
gotoAndStop(_root.randomRange(1, this._totalframes));
}
}
};
stop();
Symbol 191 MovieClip Frame 2
stop();
Symbol 193 MovieClip Frame 1
var xpos = this._x;
var ypos = this._y;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 30) {
_y = ypos;
}
}
};
Symbol 198 MovieClip Frame 1
var xpos = this._x;
var ypos = -600;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
}
}
};
Symbol 200 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 350) {
_y = ypos;
}
}
};
Symbol 205 MovieClip Frame 1
var xpos = this._x;
var ypos = -600;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 800) {
_y = ypos;
gotoAndStop(_root.randomRange(1, this._totalframes));
}
}
};
stop();
Symbol 205 MovieClip Frame 2
stop();
Symbol 235 MovieClip Frame 1
if (_root.increaseMetr >= 1) {
_root.increaseMetr--;
}
onEnterFrame = function () {
this._y = this._y + _root.speed;
};
Symbol 235 MovieClip Frame 40
_parent.reset();
stop();
Symbol 236 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
function reset() {
leftHit = false;
rightHit = false;
this._visible = true;
if (_y > -400) {
this._y = ymin;
gotoAndStop(_parent._parent.randomRange(1, this._totalframes - 1));
randomNo = _parent._parent.randomRange(0, 1);
if (randomNo == 0) {
this._visible = true;
this._y = ymin;
this._x = xpos;
speed = _parent._parent.randomRange(6, 9);
} else {
this._visible = true;
this._y = ymax;
this._x = xpos;
speed = _parent._parent.randomRange(3, 7);
}
}
}
var ymin = _parent._parent.randomRange(-649.8, -600.8);
var speed = _parent._parent.randomRange(7, 13);
var ymax = _parent._parent.randomRange(420, 440);
this._visible = true;
randomNo = 0;
var xpos = this._x;
var leftHit = false;
var rightHit = false;
reset();
onEnterFrame = function () {
if (_root.isPause == false) {
if ((leftHit && (this._y <= Dlimit)) && (this._y >= Ulimit)) {
_x = (_x - 15);
} else if ((rightHit && (this._y <= Dlimit)) && (this._y >= Ulimit)) {
_x = (_x + 15);
}
if (this.hitTest(_parent.loveStopL_mc) && (_currentframe != 4)) {
if (checkCollision(this, _parent.loveStopL_mc != undefined) || (checkCollision(this, _parent.loveStopL_mc) != null)) {
_root.score = _root.score + 100;
_root.count++;
_root.carsKissed++;
_root.increaseMetr++;
_parent.movinHeartL_mc.gotoAndPlay(2);
if ((_parent.yellowCut_mc._currentframe == 1) && (_root.count > 9)) {
_root.isPause = true;
_parent.yellowCut_mc.gotoAndPlay(7);
}
reset();
}
}
if (this.hitTest(_parent.loveStopR_mc) && (_currentframe != 4)) {
if (checkCollision(this, _parent.loveStopR_mc != undefined) || (checkCollision(this, _parent.loveStopR_mc) != null)) {
_root.score = _root.score + 100;
_root.count++;
_root.carsKissed++;
_root.increaseMetr++;
_parent.movinHeartR_mc.gotoAndPlay(2);
if ((_parent.yellowCut_mc._currentframe == 1) && (_root.count > 9)) {
_root.isPause = true;
_parent.yellowCut_mc.gotoAndPlay(7);
}
reset();
}
}
if (this._x <= (_parent.Llimit - 50)) {
this._x = _parent.Llimit - 50;
this._y = this._y + _root.speed;
gotoAndStop (4);
if (randomNo != 0) {
this._y = this._y + _root.speed;
}
}
if (this._x >= (_parent.Rlimit + 50)) {
this._x = _parent.Rlimit + 50;
this._y = this._y + _root.speed;
gotoAndStop (4);
if (randomNo != 0) {
this._y = this._y + _root.speed;
}
}
if (randomNo == 0) {
this._y = this._y + speed;
if ((this._y > ymax) && (_currentframe != 4)) {
reset();
this._visible = true;
this._x = xpos;
gotoAndStop(_parent._parent.randomRange(1, this._totalframes - 1));
}
} else {
this._y = this._y - speed;
if ((this._y < ymin) && (_currentframe != 4)) {
reset();
this._visible = true;
this._x = xpos;
gotoAndStop(_parent._parent.randomRange(1, this._totalframes - 1));
}
}
if (this.hitTest(_parent.hero_mc)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
if (randomNo == 0) {
this._y = this._y - 15;
this._x = this._x - 5;
_root.RhitLady++;
} else {
this._y = this._y + 15;
this._x = this._x - 5;
_root.RhitLady++;
}
if ((_parent.hero_mc._x < this._x) && (_parent.hero_mc._x > _parent.Llimit)) {
this._x = this._x + 5;
}
if ((_parent.hero_mc._x > this._x) && (_parent.hero_mc._x < _parent.Rlimit)) {
this._x = this._x - 5;
}
}
}
if (_parent.xbf_mc.hitTest(this)) {
if ((checkCollision(_parent.xbf_mc, this) != undefined) || (checkCollision(_parent.xbf_mc, this) != null)) {
if (this._y >= ymin) {
if (this.hitTest(_parent.hero_mc)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
_parent.hero_mc._y = _parent.hero_mc._y - 10;
this._y = this._y + 8;
}
}
if ((_parent.xbf_mc._x > this._x) && (_parent.xbf_mc._x < _parent.Rlimit)) {
_parent.xbf_mc._y = _parent.xbf_mc._y + 15;
_parent.xbf_mc._x = _parent.xbf_mc._x + 5;
this._y = this._y - 20;
this._x = this._x - 8;
} else if ((_parent.xbf_mc._x < this._x) && (_parent.xbf_mc._x > _parent.Llimit)) {
_parent.xbf_mc._y = _parent.xbf_mc._y + 15;
_parent.xbf_mc._x = _parent.xbf_mc._x - 5;
this._y = this._y - 20;
this._x = this._x + 8;
}
if (_x <= (_parent.Llimit - 50)) {
_x = (_parent.Llimit - 50);
reset();
} else if (_x >= (_parent.Rlimit + 50)) {
_x = (_parent.Rlimit + 50);
reset();
}
} else if (this._y <= ymax) {
if (this.hitTest(_parent.hero_mc)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
_parent.hero_mc._y = _parent.hero_mc._y - 10;
this._y = this._y + 8;
}
}
if ((_parent.xbf_mc._x > this._x) && (_parent.xbf_mc._x < _parent.Rlimit)) {
_parent.xbf_mc._y = _parent.xbf_mc._y + 15;
_parent.xbf_mc._x = _parent.xbf_mc._x + 5;
this._y = this._y + 20;
this._x = this._x - 8;
} else if ((_parent.xbf_mc._x < this._x) && (_parent.xbf_mc._x > _parent.Llimit)) {
_parent.xbf_mc._y = _parent.xbf_mc._y + 15;
_parent.xbf_mc._x = _parent.xbf_mc._x - 5;
this._y = this._y + 20;
this._x = this._x + 8;
}
if (_x <= (_parent.Llimit - 50)) {
_x = (_parent.Llimit - 50);
reset();
} else if (_x >= (_parent.Rlimit + 50)) {
_x = (_parent.Rlimit + 50);
reset();
}
}
}
}
if ((this._y + 15) < _parent.xbf_mc._y) {
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
this._y = this._y - 10;
_parent.xbf_mc._y = _parent.xbf_mc._y + 10;
}
}
}
if ((this._y + 15) > _parent.xbf_mc._y) {
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
this._y = this._y + 10;
_parent.xbf_mc._y = _parent.xbf_mc._y - 10;
}
}
}
}
};
stop();
Symbol 236 MovieClip Frame 2
stop();
Symbol 236 MovieClip Frame 3
stop();
Symbol 236 MovieClip Frame 4
stop();
Symbol 241 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
var xpos = this._x;
var ypos = -450;
onEnterFrame = function () {
this._visible = true;
if (_root.isPause == false) {
if (this.hitTest(_parent.mainCabt_mc.cabinetL_mc)) {
_parent.mainCabt_mc.cabinetL_mc._visible = false;
}
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
_parent.mainCabt_mc.cabinetL_mc._visible = true;
}
if ((checkCollision(this, _parent.C1_mc) || (checkCollision(this, _parent.C2_mc))) || (checkCollision(this, _parent.C3_mc))) {
no = 1;
while (no < 4) {
no++;
}
}
}
};
Symbol 244 MovieClip Frame 1
var xpos = this._x;
var ypos = -450;
onEnterFrame = function () {
this._visible = true;
if (_root.isPause == false) {
if (this.hitTest(_parent.mainCabt_mc.cabinetR_mc)) {
_parent.mainCabt_mc.cabinetR_mc._visible = false;
}
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
_parent.mainCabt_mc.cabinetR_mc._visible = true;
}
}
};
Symbol 259 MovieClip Frame 1
stop();
Symbol 261 MovieClip Frame 1
stop();
Symbol 261 MovieClip Frame 34
Symbol 262 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
var hitLeft = false;
var hitRight = false;
var hitUp = false;
var hitDown = false;
var counterR = 0;
var counterL = 0;
var counterU = 0;
onEnterFrame = function () {
if (!_root.isPause) {
if (Key.isDown(39) && (this._x < _parent.Rlimit)) {
this._x = this._x + 10;
if (counterR < 10) {
no = 1;
while (no < 4) {
if (this.hitTest(_parent[("C" + no) + "_mc"]) && (_parent[("C" + no) + "_mc"]._currentframe != 4)) {
if ((checkCollision(this, _parent[("C" + no) + "_mc"]) != undefined) || (checkCollision(this, _parent[("C" + no) + "_mc"]) != null)) {
if (_parent[("C" + no) + "_mc"]._x != _parent.Rbound) {
if (_parent[("C" + no) + "_mc"].randomNo == 0) {
if (flyHeartsR_mc._currentframe == 1) {
flyHeartsR_mc.gotoAndPlay(2);
}
_parent[("C" + no) + "_mc"].speed = 10;
if (_parent.xbf_mc.hitTest(_parent[("C" + no) + "_mc"])) {
_parent[("C" + no) + "_mc"]._x = _parent[("C" + no) + "_mc"]._x - 10;
_parent.xbf_mc._x = _parent.xbf_mc._x + 5;
}
_parent[("C" + no) + "_mc"].randomNo = 1;
} else {
_parent[("C" + no) + "_mc"].speed = -10;
if (_parent.xbf_mc.hitTest(_parent[("C" + no) + "_mc"])) {
_parent[("C" + no) + "_mc"]._x = _parent[("C" + no) + "_mc"]._x - 10;
_parent.xbf_mc._x = _parent.xbf_mc._x + 5;
}
}
_parent[("C" + no) + "_mc"].rightHit = true;
}
}
}
no++;
}
counterR++;
} else {
counterR = 0;
}
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
if (scratchR_mc._currentframe == 1) {
scratchR_mc.gotoAndPlay(2);
}
this._x = this._x - 20;
}
}
} else if (Key.isDown(37) && (this._x > _parent.Llimit)) {
this._x = this._x - 10;
if (counterL < 10) {
no = 1;
while (no < 4) {
if (this.hitTest(_parent[("C" + no) + "_mc"]) && (_parent[("C" + no) + "_mc"]._currentframe != 4)) {
if ((checkCollision(this, _parent[("C" + no) + "_mc"]) != undefined) || (checkCollision(this, _parent[("C" + no) + "_mc"]) != null)) {
if (_parent[("C" + no) + "_mc"]._x != _parent.Lbound) {
if (flyHeartsL_mc._currentframe == 1) {
flyHeartsL_mc.gotoAndPlay(2);
}
if (_parent[("C" + no) + "_mc"].randomNo == 0) {
_parent[("C" + no) + "_mc"].speed = 10;
if (_parent[("C" + no) + "_mc"].hitTest(_parent.xbf_mc)) {
_parent[("C" + no) + "_mc"]._x = _parent[("C" + no) + "_mc"]._x + 15;
_parent[("C" + no) + "_mc"]._y = _parent[("C" + no) + "_mc"]._y + 100;
_parent.xbf_mc._x = _parent.xbf_mc._x - 15;
}
_parent[("C" + no) + "_mc"].randomNo = 1;
} else {
_parent[("C" + no) + "_mc"].speed = -10;
if (_parent[("C" + no) + "_mc"].hitTest(_parent.xbf_mc)) {
_parent[("C" + no) + "_mc"]._x = _parent[("C" + no) + "_mc"]._x + 15;
_parent[("C" + no) + "_mc"]._y = _parent[("C" + no) + "_mc"]._y + 100;
_parent.xbf_mc._x = _parent.xbf_mc._x - 15;
}
}
_parent[("C" + no) + "_mc"].leftHit = true;
}
}
}
no++;
}
counterL++;
} else {
counterL = 0;
}
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
if (scratchL_mc._currentframe == 1) {
scratchL_mc.gotoAndPlay(2);
}
this._x = this._x + 20;
}
}
} else if (Key.isDown(38) && (this._y > _parent.Ulimit)) {
this._y = this._y - _root.speed;
if (counterU < 10) {
no = 1;
while (no < 4) {
if (this.hitTest(_parent[("C" + no) + "_mc"]) && (_parent[("C" + no) + "_mc"]._currentframe != 4)) {
if ((checkCollision(this, _parent[("C" + no) + "_mc"]) != undefined) || (checkCollision(this, _parent[("C" + no) + "_mc"]) != null)) {
if (flyHeartsU_mc._currentframe == 1) {
flyHeartsU_mc.gotoAndPlay(2);
}
_parent[("C" + no) + "_mc"]._y = _parent[("C" + no) + "_mc"]._y - 5;
}
}
no++;
}
counterU++;
} else {
counterU = 0;
}
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
if (scratchU_mc._currentframe == 1) {
scratchU_mc.gotoAndPlay(2);
}
this._y = this._y + 13;
}
}
} else if (Key.isDown(40) && (this._y < _parent.Dlimit)) {
this._y = this._y + _root.speed;
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
if (scratchD_mc._currentframe == 1) {
scratchD_mc.gotoAndPlay(2);
}
this._y = this._y - 13;
}
}
if (counterD < 10) {
no = 1;
while (no < 4) {
if (this.hitTest(_parent[("C" + no) + "_mc"]) && (_parent[("C" + no) + "_mc"]._currentframe != 4)) {
if ((checkCollision(this, _parent[("C" + no) + "_mc"]) != undefined) || (checkCollision(this, _parent[("C" + no) + "_mc"]) != null)) {
if (flyHeartsD_mc._currentframe == 1) {
flyHeartsD_mc.gotoAndPlay(2);
}
_parent[("C" + no) + "_mc"]._y = _parent[("C" + no) + "_mc"]._y + 5;
}
}
no++;
}
counterD++;
} else {
counterD = 0;
}
}
}
};
Symbol 264 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
}
}
};
Symbol 297 MovieClip Frame 1
stop();
Symbol 297 MovieClip Frame 2
stop();
Symbol 297 MovieClip Frame 3
stop();
Symbol 301 MovieClip Frame 1
stop();
Symbol 301 MovieClip Frame 2
stop();
Symbol 301 MovieClip Frame 3
stop();
Symbol 305 MovieClip Frame 1
stop();
Symbol 305 MovieClip Frame 2
stop();
Symbol 305 MovieClip Frame 3
stop();
Symbol 308 MovieClip Frame 1
stop();
Symbol 308 MovieClip Frame 2
stop();
Symbol 308 MovieClip Frame 3
stop();
Symbol 309 MovieClip Frame 1
stop();
Symbol 309 MovieClip Frame 2
stop();
Symbol 309 MovieClip Frame 3
stop();
Symbol 309 MovieClip Frame 4
stop();
Symbol 314 MovieClip Frame 1
stop();
Symbol 314 MovieClip Frame 67
function checkMove() {
if (userArray[count] == codeArray[count]) {
this[movieArray[count]].target_mc.gotoAndStop(3);
} else {
this[movieArray[count]].target_mc.gotoAndStop(2);
}
}
function checkCode() {
up_btn.enabled = false;
down_btn.enabled = false;
left_btn.enabled = false;
right_btn.enabled = false;
k = 0;
while (k < codeArray.length) {
if (userArray[k] != codeArray[k]) {
block = true;
onEnterFrame = null;
_root.isPause = false;
gotoAndStop (1);
}
k++;
}
if (!block) {
onEnterFrame = null;
block = undefined;
gotoAndPlay (68);
}
}
stop();
var codeArray = new Array(5);
var userArray = [0, 0, 0, 0, 0];
var time = 250;
var count = 0;
i = 0;
while (i < 5) {
codeArray[i] = _root.randomRange(1, 4);
i++;
}
time_txt.text = Math.round(time / 25);
var timer = 0;
var done = false;
var block = undefined;
_root.miniGame = false;
_root.count = 0;
var kb_Snd = new Sound();
kb_Snd.attachSound("kb");
a_mc.gotoAndStop(codeArray[0]);
b_mc.gotoAndStop(codeArray[1]);
c_mc.gotoAndStop(codeArray[2]);
d_mc.gotoAndStop(codeArray[3]);
e_mc.gotoAndStop(codeArray[4]);
var movieArray = ["a_mc", "b_mc", "c_mc", "d_mc", "e_mc"];
onEnterFrame = function () {
if (count == codeArray.length) {
checkCode();
count++;
_root.miniGame = true;
}
time_txt.text = Math.round((time - timer) / 25);
if (timer >= time) {
stopAllSounds();
count = codeArray.length + 1;
onEnterFrame = null;
_root.isPause = false;
gotoAndStop (1);
}
timer++;
if (!done) {
if (Key.isDown(38)) {
kb_Snd.start();
userArray[count] = 3;
checkMove();
count++;
done = true;
} else if (Key.isDown(40)) {
kb_Snd.start();
userArray[count] = 2;
checkMove();
count++;
done = true;
} else if (Key.isDown(37)) {
kb_Snd.start();
userArray[count] = 1;
checkMove();
count++;
done = true;
} else if (Key.isDown(39)) {
kb_Snd.start();
userArray[count] = 4;
checkMove();
count++;
done = true;
}
} else if ((((!Key.isDown(38)) && (!Key.isDown(40))) && (!Key.isDown(37))) && (!Key.isDown(39))) {
done = false;
}
};
Symbol 314 MovieClip Frame 81
_root.score = _root.score + 500;
_root.increaseMetr = _root.increaseMetr + 4;
_root.isPause = false;
gotoAndStop (1);
Symbol 317 MovieClip Frame 1
stop();
Symbol 317 MovieClip Frame 15
gotoAndStop (1);
Symbol 319 MovieClip Frame 1
stop();
Symbol 319 MovieClip Frame 15
gotoAndStop (1);
Symbol 320 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
_root.speed = 10;
_root.isPause = false;
_root.increaseMetr = 0;
_root.decreaseMetr = 0;
var Rlimit = ((divRT_mc._x - (divRT_mc._width / 2)) - (hero_mc._width / 2));
var Llimit = ((divLT_mc._x + (divLT_mc._width / 2)) + (hero_mc._width / 2));
var Dlimit = (290 - (hero_mc._height / 2));
var Ulimit = (-290 + (hero_mc._height / 2));
var Rbound = ((divRT_mc._x - divRT_mc._width) - (C3_mc._width / 2));
var Lbound = ((divLT_mc._x + divLT_mc._width) + (C3_mc._width / 2));
var laneArray = [1, 2, 3, 4, 5, 6];
var tArray = [1, 2];
onEnterFrame = function () {
if (_root.isPause == false) {
if (C1_mc.hitTest(C2_mc)) {
if ((checkCollision(C1_mc, C2_mc) != undefined) || (checkCollision(C1_mc, C2_mc) != null)) {
if ((C1_mc._y >= ymin) && (C2_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C2_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y >= ymin) && (C2_mc._y >= ymin)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C2_mc._y >= ymin)) {
C1_mc._y = C1_mc._y + 10;
C2_mc._y = C2_mc._y - 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
}
}
}
if (C2_mc.hitTest(C3_mc)) {
if ((checkCollision(C2_mc, C3_mc) != undefined) || (checkCollision(C2_mc, C3_mc) != null)) {
if ((C2_mc._y >= ymin) && (C3_mc._y <= ymax)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y <= ymax) && (C3_mc._y <= ymax)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y >= ymin) && (C3_mc._y >= ymin)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y <= ymax) && (C3_mc._y >= ymin)) {
C2_mc._y = C2_mc._y + 10;
C3_mc._y = C3_mc._y - 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
}
}
}
if (C1_mc.hitTest(C3_mc)) {
if ((checkCollision(C1_mc, C3_mc) != undefined) || (checkCollision(C1_mc, C3_mc) != null)) {
if ((C1_mc._y >= ymin) && (C3_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C3_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y >= ymin) && (C3_mc._y >= ymin)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C3_mc._y >= ymin)) {
C1_mc._y = C1_mc._y + 10;
C3_mc._y = C3_mc._y - 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
}
}
}
}
};
Instance of Symbol 236 MovieClip "C3_mc" in Symbol 320 MovieClip Frame 1
onClipEvent (load) {
_root.count = 0;
_root.carsKissed = 0;
}
Symbol 327 MovieClip Frame 1
var lifeArray = [50, 75, 100, 150];
var total = lifeArray[_root.level - 1];
fill_mc._xscale = 100;
onEnterFrame = function () {
if (percent <= 100) {
loaded = _root.RhitLady;
percent = Math.ceil((loaded / total) * 100);
fill_mc._xscale = 100 - percent;
if (percent >= 100) {
_root.gotoAndStop("gameOver");
}
}
};
Symbol 342 MovieClip Frame 1
var fillArray = [10, 15, 20, 30];
var total = fillArray[_root.level - 1];
meterFill_mc._yscale = 0;
onEnterFrame = function () {
if (percent <= 100) {
loaded = _root.increaseMetr;
percent = Math.ceil((loaded / total) * 100);
meterFill_mc._yscale = percent;
}
if (percent >= 100) {
trace("heart fill");
_root.levelScore = 10000 + (5000 * (_root.level - 1));
_root.score = _root.score + _root.levelScore;
_root.gotoAndStop("levelComplete");
trace("levelComplete");
}
};
Symbol 348 MovieClip Frame 1
Symbol 348 MovieClip Frame 2
stop();
Symbol 351 MovieClip Frame 1
var xpos = this._x;
var ypos = -500;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 600) {
_y = ypos;
gotoAndStop(_root.randomRange(1, this._totalframes));
}
}
};
stop();
Symbol 351 MovieClip Frame 2
stop();
Symbol 353 MovieClip Frame 1
var xpos = this._x;
var ypos = -500;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 600) {
_y = ypos;
gotoAndStop(_root.randomRange(1, this._totalframes));
}
}
};
stop();
Symbol 353 MovieClip Frame 2
stop();
Symbol 356 MovieClip Frame 1
var xpos = this._x;
var ypos = -500;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 600) {
_y = ypos;
gotoAndStop(_root.randomRange(1, this._totalframes));
}
}
};
stop();
Symbol 356 MovieClip Frame 2
stop();
Symbol 360 MovieClip Frame 1
var xpos = this._x;
var ypos = this._y;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 30) {
_y = ypos;
}
}
};
Symbol 364 MovieClip Frame 1
var xpos = this._x;
var ypos = -600;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 800) {
_y = ypos;
gotoAndStop(_root.randomRange(1, this._totalframes));
}
}
};
stop();
Symbol 364 MovieClip Frame 2
stop();
Symbol 366 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 350) {
_y = ypos;
}
}
};
Symbol 374 MovieClip Frame 1
Symbol 378 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
var monsterCar = false;
var xpos = this._x;
var ypos = this._y;
onEnterFrame = function () {
if (!_root.isPause) {
var _local4 = _parent._parent.randomRange(0, 60);
if (_local4 == 1) {
monsterCar = true;
} else if (monsterCar == true) {
this._y = this._y - 15;
if (_y <= -700) {
this._x = xpos;
this._y = ypos + 1100;
gotoAndStop(_root.randomRange(1, this._totalframes));
monsterCar = false;
}
distance = 200;
hx = _parent.hero_mc._x;
hy = _parent.hero_mc._y;
erx = this._x;
ery = this._y;
if (Math.sqrt(((hx - erx) * (hx - erx)) + ((hy - ery) * (hy - ery))) < distance) {
if (hx < (erx - 50)) {
this._x = this._x - 2;
}
if (hx > (erx + 50)) {
this._x = this._x + 2;
}
}
if (this._y > (_parent.hero_mc._y + 40)) {
if ((this._x > (_parent.hero_mc._x + 10)) && (random(100) == 1)) {
if (_parent.hero_mc.hitTest(this) && (_parent.hero_mc._x < _parent.Rlimit)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
_parent.hero_mc._x = _parent.hero_mc._x + 10;
this._x = this._x - 10;
}
}
}
if ((this._x < (_parent.hero_mc._x + 10)) && (random(100) == 1)) {
if (_parent.hero_mc.hitTest(this) && (_parent.hero_mc._x > _parent.Llimit)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
_parent.hero_mc._x = _parent.hero_mc._x - 10;
this._x = this._x + 10;
}
}
}
if (_parent.hero_mc.hitTest(this)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
_root.RhitLady++;
this._y = this._y + 20;
}
}
}
}
}
};
stop();
Symbol 378 MovieClip Frame 2
stop();
Symbol 379 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
_root.speed = 10;
_root.isPause = false;
_root.increaseMetr = 0;
_root.decreaseMetr = 0;
var Rlimit = ((divRT_mc._x - (divRT_mc._width / 2)) - (hero_mc._width / 2));
var Llimit = ((divLT_mc._x + (divLT_mc._width / 2)) + (hero_mc._width / 2));
var Dlimit = (290 - (hero_mc._height / 2));
var Ulimit = (-290 + (hero_mc._height / 2));
var Rbound = ((divRT_mc._x - divRT_mc._width) - (C3_mc._width / 2));
var Lbound = ((divLT_mc._x + divLT_mc._width) + (C3_mc._width / 2));
var laneArray = [1, 2, 3, 4, 5, 6];
var tArray = [1, 2];
onEnterFrame = function () {
if (_root.isPause == false) {
if (C1_mc.hitTest(C2_mc)) {
if ((checkCollision(C1_mc, C2_mc) != undefined) || (checkCollision(C1_mc, C2_mc) != null)) {
if ((C1_mc._y >= ymin) && (C2_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C2_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y >= ymin) && (C2_mc._y >= ymin)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C2_mc._y >= ymin)) {
C1_mc._y = C1_mc._y + 10;
C2_mc._y = C2_mc._y - 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
}
}
}
if (C2_mc.hitTest(C3_mc)) {
if ((checkCollision(C2_mc, C3_mc) != undefined) || (checkCollision(C2_mc, C3_mc) != null)) {
if ((C2_mc._y >= ymin) && (C3_mc._y <= ymax)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y <= ymax) && (C3_mc._y <= ymax)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y >= ymin) && (C3_mc._y >= ymin)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y <= ymax) && (C3_mc._y >= ymin)) {
C2_mc._y = C2_mc._y + 10;
C3_mc._y = C3_mc._y - 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
}
}
}
if (C1_mc.hitTest(C3_mc)) {
if ((checkCollision(C1_mc, C3_mc) != undefined) || (checkCollision(C1_mc, C3_mc) != null)) {
if ((C1_mc._y >= ymin) && (C3_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C3_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y >= ymin) && (C3_mc._y >= ymin)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C3_mc._y >= ymin)) {
C1_mc._y = C1_mc._y + 10;
C3_mc._y = C3_mc._y - 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
}
}
}
}
};
Instance of Symbol 236 MovieClip "C3_mc" in Symbol 379 MovieClip Frame 1
onClipEvent (load) {
_root.count = 0;
}
Symbol 381 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 350) {
_y = ypos;
}
}
};
Symbol 383 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 350) {
_y = ypos;
}
}
};
Symbol 385 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 350) {
_y = ypos;
}
}
};
Symbol 387 MovieClip Frame 1
var xpos = this._x;
var ypos = -500;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 600) {
_y = ypos;
gotoAndStop(_root.randomRange(1, this._totalframes));
}
}
};
stop();
Symbol 387 MovieClip Frame 2
stop();
Symbol 395 MovieClip Frame 1
Symbol 396 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
function reset() {
this._x = _parent._parent.randomRange(_parent.Llimit + this._width, _parent.Rlimit - this._width);
this._y = ypos;
}
var spikes = false;
var ypos = this._y;
onEnterFrame = function () {
scratchU1_mc._visible = false;
if (!_root.isPause) {
if (spikes == true) {
this._y = this._y + _root.speed;
if (this._y > 500) {
spikes = false;
reset();
}
} else if (random(100) == 1) {
spikes = true;
}
if (this.hitTest(_parent.hero_mc)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
trace("spik");
scratchU1_mc._visible = true;
_root.RhitLady++;
}
}
}
};
Symbol 397 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
function reset() {
leftHit = false;
rightHit = false;
this._visible = true;
if (_y > -400) {
this._y = ymin;
gotoAndStop(_parent._parent.randomRange(1, this._totalframes - 1));
randomNo = _parent._parent.randomRange(0, 1);
if (randomNo == 0) {
this._visible = true;
this._y = ymin;
this._x = xpos;
speed = _parent._parent.randomRange(6, 9);
} else {
this._visible = true;
this._y = ymax;
this._x = xpos;
speed = _parent._parent.randomRange(3, 7);
}
}
}
var ymin = _parent._parent.randomRange(-649.8, -600.8);
var speed = _parent._parent.randomRange(7, 13);
var ymax = _parent._parent.randomRange(420, 440);
this._visible = true;
randomNo = 0;
var xpos = this._x;
var leftHit = false;
var rightHit = false;
reset();
onEnterFrame = function () {
if (_root.isPause == false) {
if ((leftHit && (this._y <= Dlimit)) && (this._y >= Ulimit)) {
_x = (_x - 15);
if (this.hitTest(_parent.loveStopL_mc) && (_currentframe != 4)) {
if (checkCollision(this, _parent.loveStopL_mc != undefined) || (checkCollision(this, _parent.loveStopL_mc) != null)) {
_root.score = _root.score + 100;
_root.count++;
_root.carsKissed++;
_root.increaseMetr++;
_parent.movinHeartL_mc.gotoAndPlay(2);
if ((_parent.yellowCut_mc._currentframe == 1) && (_root.count > 9)) {
_root.isPause = true;
_parent.yellowCut_mc.gotoAndPlay(7);
}
reset();
}
}
} else if ((rightHit && (this._y <= Dlimit)) && (this._y >= Ulimit)) {
_x = (_x + 15);
if (this.hitTest(_parent.loveStopR_mc) && (_currentframe != 4)) {
if (checkCollision(this, _parent.loveStopR_mc != undefined) || (checkCollision(this, _parent.loveStopR_mc) != null)) {
_root.score = _root.score + 100;
_root.count++;
_root.carsKissed++;
_root.increaseMetr++;
_parent.movinHeartR_mc.gotoAndPlay(2);
if ((_parent.yellowCut_mc._currentframe == 1) && (_root.count > 9)) {
_root.isPause = true;
_parent.yellowCut_mc.gotoAndPlay(7);
}
reset();
}
}
}
if (this._x <= (_parent.Llimit - 50)) {
this._x = _parent.Llimit - 50;
this._y = this._y + _root.speed;
gotoAndStop (4);
if (randomNo != 0) {
this._y = this._y + _root.speed;
}
}
if (this._x >= (_parent.Rlimit + 50)) {
this._x = _parent.Rlimit + 50;
this._y = this._y + _root.speed;
gotoAndStop (4);
if (randomNo != 0) {
this._y = this._y + _root.speed;
}
}
if (randomNo == 0) {
this._y = this._y + speed;
if ((this._y > ymax) && (_currentframe != 4)) {
reset();
this._visible = true;
this._x = xpos;
gotoAndStop(_parent._parent.randomRange(1, this._totalframes - 1));
}
} else {
this._y = this._y - speed;
if ((this._y < ymin) && (_currentframe != 4)) {
reset();
this._visible = true;
this._x = xpos;
gotoAndStop(_parent._parent.randomRange(1, this._totalframes - 1));
}
}
if (this.hitTest(_parent.hero_mc)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
if (randomNo == 0) {
this._y = this._y - 15;
this._x = this._x + 5;
_root.RhitLady++;
} else {
this._y = this._y + 15;
_root.RhitLady++;
}
if ((_parent.hero_mc._x < this._x) && (_parent.hero_mc._x > _parent.Llimit)) {
this._x = this._x + 5;
}
if ((_parent.hero_mc._x > this._x) && (_parent.hero_mc._x < _parent.Rlimit)) {
this._x = this._x - 5;
}
}
}
if (_parent.xbf_mc.hitTest(this)) {
if ((checkCollision(_parent.xbf_mc, this) != undefined) || (checkCollision(_parent.xbf_mc, this) != null)) {
if (this._y >= ymin) {
if (this.hitTest(_parent.hero_mc)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
_parent.hero_mc._y = _parent.hero_mc._y - 10;
this._y = this._y + 8;
}
}
if ((_parent.xbf_mc._x > this._x) && (_parent.xbf_mc._x < _parent.Rlimit)) {
_parent.xbf_mc._y = _parent.xbf_mc._y + 15;
_parent.xbf_mc._x = _parent.xbf_mc._x + 5;
this._y = this._y - 20;
this._x = this._x - 8;
} else if ((_parent.xbf_mc._x < this._x) && (_parent.xbf_mc._x > _parent.Llimit)) {
_parent.xbf_mc._y = _parent.xbf_mc._y + 15;
_parent.xbf_mc._x = _parent.xbf_mc._x - 5;
this._y = this._y - 20;
this._x = this._x + 8;
}
if (_x <= (_parent.Llimit - 50)) {
_x = (_parent.Llimit - 50);
reset();
} else if (_x >= (_parent.Rlimit + 50)) {
_x = (_parent.Rlimit + 50);
reset();
}
} else if (this._y <= ymax) {
if (this.hitTest(_parent.hero_mc)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
_parent.hero_mc._y = _parent.hero_mc._y - 10;
this._y = this._y + 8;
}
}
if ((_parent.xbf_mc._x > this._x) && (_parent.xbf_mc._x < _parent.Rlimit)) {
_parent.xbf_mc._y = _parent.xbf_mc._y + 15;
_parent.xbf_mc._x = _parent.xbf_mc._x + 5;
this._y = this._y + 20;
this._x = this._x - 8;
} else if ((_parent.xbf_mc._x < this._x) && (_parent.xbf_mc._x > _parent.Llimit)) {
_parent.xbf_mc._y = _parent.xbf_mc._y + 15;
_parent.xbf_mc._x = _parent.xbf_mc._x - 5;
this._y = this._y + 20;
this._x = this._x + 8;
}
if (_x <= (_parent.Llimit - 50)) {
_x = (_parent.Llimit - 50);
reset();
} else if (_x >= (_parent.Rlimit + 50)) {
_x = (_parent.Rlimit + 50);
reset();
}
}
}
}
if ((this._y + 15) < _parent.xbf_mc._y) {
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
this._y = this._y - 10;
_parent.xbf_mc._y = _parent.xbf_mc._y + 10;
}
}
}
if ((this._y + 15) > _parent.xbf_mc._y) {
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
this._y = this._y + 10;
_parent.xbf_mc._y = _parent.xbf_mc._y - 10;
}
}
}
}
};
stop();
Symbol 397 MovieClip Frame 2
stop();
Symbol 397 MovieClip Frame 3
stop();
Symbol 397 MovieClip Frame 4
stop();
Symbol 400 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
var xpos = this._x;
var ypos = -450;
onEnterFrame = function () {
this._visible = true;
if (_root.isPause == false) {
if (this.hitTest(_parent.mainCabt_mc.cabinetL_mc)) {
_parent.mainCabt_mc.cabinetL_mc._visible = false;
}
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
_parent.mainCabt_mc.cabinetL_mc._visible = true;
}
if ((checkCollision(this, _parent.C1_mc) || (checkCollision(this, _parent.C2_mc))) || (checkCollision(this, _parent.C3_mc))) {
no = 1;
while (no < 4) {
no++;
}
}
}
};
Symbol 403 MovieClip Frame 1
var xpos = this._x;
var ypos = -450;
onEnterFrame = function () {
this._visible = true;
if (_root.isPause == false) {
if (this.hitTest(_parent.mainCabt_mc.cabinetR_mc)) {
_parent.mainCabt_mc.cabinetR_mc._visible = false;
}
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
_parent.mainCabt_mc.cabinetR_mc._visible = true;
}
}
};
Symbol 404 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
var hitLeft = false;
var hitRight = false;
var hitUp = false;
var hitDown = false;
var counterR = 0;
var counterL = 0;
var counterU = 0;
scratchL_mc._visible = false;
scratchR_mc._visible = false;
scratchU_mc._visible = false;
scratchD_mc._visible = false;
flyHeartsL_mc._visible = false;
flyHeartsR_mc._visible = false;
flyHeartsD_mc._visible = false;
flyHeartsU_mc._visible = false;
var blowKiss_Snd = new Sound();
blowKiss_Snd.attachSound("blowkiss");
onEnterFrame = function () {
if (!_root.isPause) {
if (Key.isDown(37) && (this._x < _parent.Rlimit)) {
this._x = this._x + 10;
if (counterL < 10) {
no = 1;
while (no < 4) {
if (this.hitTest(_parent[("C" + no) + "_mc"]) && (_parent[("C" + no) + "_mc"]._currentframe != 4)) {
if ((checkCollision(this, _parent[("C" + no) + "_mc"]) != undefined) || (checkCollision(this, _parent[("C" + no) + "_mc"]) != null)) {
if (_parent[("C" + no) + "_mc"]._x != _parent.Rbound) {
if (_parent[("C" + no) + "_mc"].randomNo == 0) {
blowKiss_Snd.start();
if (flyHeartsR_mc._currentframe == 1) {
flyHeartsR_mc.gotoAndPlay(2);
}
_parent[("C" + no) + "_mc"].speed = 10;
if (_parent[("C" + no) + "_mc"].hitTest(_parent.xbf_mc)) {
_parent[("C" + no) + "_mc"]._x = _parent[("C" + no) + "_mc"]._x + 15;
_parent[("C" + no) + "_mc"]._y = _parent[("C" + no) + "_mc"]._y - 100;
_parent.xbf_mc._x = _parent.xbf_mc._x - 15;
}
_parent[("C" + no) + "_mc"].randomNo = 1;
} else {
_parent[("C" + no) + "_mc"].speed = -10;
if (_parent[("C" + no) + "_mc"].hitTest(_parent.xbf_mc)) {
_parent[("C" + no) + "_mc"]._x = _parent[("C" + no) + "_mc"]._x + 15;
_parent[("C" + no) + "_mc"]._y = _parent[("C" + no) + "_mc"]._y - 100;
_parent.xbf_mc._x = _parent.xbf_mc._x - 15;
}
}
_parent[("C" + no) + "_mc"].rightHit = true;
}
}
}
no++;
}
counterL++;
} else {
counterL = 0;
}
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
if (scratchR_mc._currentframe == 1) {
scratchR_mc.gotoAndPlay(2);
}
this._x = this._x - 20;
}
}
} else if (Key.isDown(39) && (this._x > _parent.Llimit)) {
this._x = this._x - 10;
if (counterR < 10) {
no = 1;
while (no < 4) {
if (this.hitTest(_parent[("C" + no) + "_mc"]) && (_parent[("C" + no) + "_mc"]._currentframe != 4)) {
if ((checkCollision(this, _parent[("C" + no) + "_mc"]) != undefined) || (checkCollision(this, _parent[("C" + no) + "_mc"]) != null)) {
if (_parent[("C" + no) + "_mc"]._x != _parent.Rbound) {
blowKiss_Snd.start();
if (flyHeartsL_mc._currentframe == 1) {
flyHeartsL_mc.gotoAndPlay(2);
}
if (_parent[("C" + no) + "_mc"].randomNo == 0) {
_parent[("C" + no) + "_mc"].speed = 10;
if (_parent.xbf_mc.hitTest(_parent[("C" + no) + "_mc"])) {
_parent[("C" + no) + "_mc"]._x = _parent[("C" + no) + "_mc"]._x - 10;
_parent.xbf_mc._x = _parent.xbf_mc._x + 5;
}
_parent[("C" + no) + "_mc"].randomNo = 1;
} else {
_parent[("C" + no) + "_mc"].speed = -10;
if (_parent.xbf_mc.hitTest(_parent[("C" + no) + "_mc"])) {
_parent[("C" + no) + "_mc"]._x = _parent[("C" + no) + "_mc"]._x - 10;
_parent.xbf_mc._x = _parent.xbf_mc._x + 5;
}
}
_parent[("C" + no) + "_mc"].leftHit = true;
}
}
}
no++;
}
counterR++;
} else {
counterR = 0;
}
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
if (scratchL_mc._currentframe == 1) {
scratchL_mc.gotoAndPlay(2);
}
this._x = this._x + 20;
}
}
} else if (Key.isDown(40) && (this._y > _parent.Ulimit)) {
this._y = this._y - _root.speed;
if (counterD < 10) {
no = 1;
while (no < 4) {
if (this.hitTest(_parent[("C" + no) + "_mc"]) && (_parent[("C" + no) + "_mc"]._currentframe != 4)) {
if ((checkCollision(this, _parent[("C" + no) + "_mc"]) != undefined) || (checkCollision(this, _parent[("C" + no) + "_mc"]) != null)) {
blowKiss_Snd.start();
if (flyHeartsU_mc._currentframe == 1) {
flyHeartsU_mc.gotoAndPlay(2);
}
_parent[("C" + no) + "_mc"]._y = _parent[("C" + no) + "_mc"]._y - 5;
}
}
no++;
}
counterD++;
} else {
counterD = 0;
}
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
if (scratchU_mc._currentframe == 1) {
scratchU_mc.gotoAndPlay(2);
}
this._y = this._y + 13;
}
}
} else if (Key.isDown(38) && (this._y < _parent.Dlimit)) {
this._y = this._y + _root.speed;
if (this.hitTest(_parent.xbf_mc)) {
if ((checkCollision(this, _parent.xbf_mc) != undefined) || (checkCollision(this, _parent.xbf_mc) != null)) {
if (scratchD_mc._currentframe == 1) {
scratchD_mc.gotoAndPlay(2);
}
this._y = this._y - 13;
}
}
if (counterU < 10) {
no = 1;
while (no < 4) {
if (this.hitTest(_parent[("C" + no) + "_mc"]) && (_parent[("C" + no) + "_mc"]._currentframe != 4)) {
if ((checkCollision(this, _parent[("C" + no) + "_mc"]) != undefined) || (checkCollision(this, _parent[("C" + no) + "_mc"]) != null)) {
blowKiss_Snd.start();
if (flyHeartsD_mc._currentframe == 1) {
flyHeartsD_mc.gotoAndPlay(2);
}
_parent[("C" + no) + "_mc"]._y = _parent[("C" + no) + "_mc"]._y + 5;
}
}
no++;
}
counterU++;
} else {
counterU = 0;
}
}
}
};
Symbol 405 MovieClip Frame 1
stop();
Symbol 405 MovieClip Frame 15
gotoAndStop (1);
Symbol 406 MovieClip Frame 1
stop();
Symbol 406 MovieClip Frame 15
gotoAndStop (1);
Symbol 410 MovieClip Frame 1
var ypos = (-400 + this._width);
trace("y" + this._y);
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > (500 + this._width)) {
_y = -619.8;
}
}
};
Symbol 411 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
_root.speed = 10;
_root.isPause = false;
_root.increaseMetr = 0;
_root.decreaseMetr = 0;
var Rlimit = ((divRT_mc._x - (divRT_mc._width / 2)) - (hero_mc._width / 2));
var Llimit = ((divLT_mc._x + (divLT_mc._width / 2)) + (hero_mc._width / 2));
var Dlimit = (290 - (hero_mc._height / 2));
var Ulimit = (-290 + (hero_mc._height / 2));
var Rbound = ((divRT_mc._x - divRT_mc._width) - (C3_mc._width / 2));
var Lbound = ((divLT_mc._x + divLT_mc._width) + (C3_mc._width / 2));
var laneArray = [1, 2, 3, 4, 5, 6];
var tArray = [1, 2];
onEnterFrame = function () {
if (_root.isPause == false) {
if (C1_mc.hitTest(C2_mc)) {
if ((checkCollision(C1_mc, C2_mc) != undefined) || (checkCollision(C1_mc, C2_mc) != null)) {
if ((C1_mc._y >= ymin) && (C2_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C2_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y >= ymin) && (C2_mc._y >= ymin)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C2_mc._y >= ymin)) {
C1_mc._y = C1_mc._y + 10;
C2_mc._y = C2_mc._y - 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
}
}
}
if (C2_mc.hitTest(C3_mc)) {
if ((checkCollision(C2_mc, C3_mc) != undefined) || (checkCollision(C2_mc, C3_mc) != null)) {
if ((C2_mc._y >= ymin) && (C3_mc._y <= ymax)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y <= ymax) && (C3_mc._y <= ymax)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y >= ymin) && (C3_mc._y >= ymin)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y <= ymax) && (C3_mc._y >= ymin)) {
C2_mc._y = C2_mc._y + 10;
C3_mc._y = C3_mc._y - 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
}
}
}
if (C1_mc.hitTest(C3_mc)) {
if ((checkCollision(C1_mc, C3_mc) != undefined) || (checkCollision(C1_mc, C3_mc) != null)) {
if ((C1_mc._y >= ymin) && (C3_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C3_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y >= ymin) && (C3_mc._y >= ymin)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C3_mc._y >= ymin)) {
C1_mc._y = C1_mc._y + 10;
C3_mc._y = C3_mc._y - 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
}
}
}
}
};
Instance of Symbol 397 MovieClip "C3_mc" in Symbol 411 MovieClip Frame 1
onClipEvent (load) {
_root.count = 0;
}
Instance of Symbol 397 MovieClip "C2_mc" in Symbol 411 MovieClip Frame 1
onClipEvent (load) {
_root.count = 0;
}
Instance of Symbol 397 MovieClip "C1_mc" in Symbol 411 MovieClip Frame 1
onClipEvent (load) {
_root.count = 0;
}
Symbol 414 MovieClip Frame 1
var xpos = this._x;
var ypos = this._y;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 30) {
_y = ypos;
_x = xpos;
}
}
};
Symbol 416 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
}
}
};
Symbol 425 MovieClip Frame 1
var xpos = this._x;
var ypos = -800;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 700) {
_y = ypos;
}
}
};
Symbol 427 MovieClip Frame 1
var xpos = this._x;
var ypos = -800;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 700) {
this._y = ypos;
}
}
};
Symbol 429 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
}
}
};
Symbol 431 MovieClip Frame 1
var xpos = this._x;
var ypos = -300;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 500) {
_y = ypos;
}
}
};
Symbol 432 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
function reset() {
this._x = _parent._parent.randomRange(_parent.Llimit + this._width, _parent.Rlimit - this._width);
this._y = ypos;
}
var spikes = false;
var ypos = this._y;
onEnterFrame = function () {
scratchU1_mc._visible = false;
if (!_root.isPause) {
if (spikes == true) {
this._y = this._y + _root.speed;
if (this._y > 500) {
spikes = false;
reset();
}
} else if (random(75) == 1) {
spikes = true;
}
if (this.hitTest(_parent.hero_mc)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
trace("spik");
if (scratchU1_mc._currentframe == 1) {
scratchU1_mc.gotoAndPlay(2);
}
_root.RhitLady++;
}
}
}
};
Symbol 433 MovieClip Frame 1
var xpos = this._x;
var ypos = -400;
onEnterFrame = function () {
if (_root.isPause == false) {
this._y = this._y + _root.speed;
if (this._y > 600) {
_y = ypos;
}
}
};
Symbol 435 MovieClip Frame 1
Symbol 438 MovieClip Frame 1
Symbol 439 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
var monsterCar = false;
var xpos = this._x;
var ypos = this._y;
onEnterFrame = function () {
if (!_root.isPause) {
var _local4 = _parent._parent.randomRange(0, 50);
if (_local4 == 1) {
monsterCar = true;
} else if (monsterCar == true) {
this._y = this._y - 15;
if (_y <= -700) {
this._x = xpos;
this._y = ypos + 1100;
gotoAndStop(_root.randomRange(1, this._totalframes));
monsterCar = false;
}
distance = 200;
hx = _parent.hero_mc._x;
hy = _parent.hero_mc._y;
Monsx = this._x;
Monsy = this._y;
if (Math.sqrt(((hx - Monsx) * (hx - Monsx)) + ((hy - Monsy) * (hy - Monsy))) < distance) {
if (hx < (Monsx - 50)) {
this._x = this._x - 2;
} else if (hx > (Monsx + 50)) {
this._x = this._x + 2;
}
}
if (this._y > _parent.hero_mc._y) {
if (_parent.hero_mc.hitTest(this) && (_parent.hero_mc._y > _parent.Ulimit)) {
if ((checkCollision(this, _parent.hero_mc) != undefined) || (checkCollision(this, _parent.hero_mc) != null)) {
trace("hit");
_root.RhitLady++;
this._y = this._y + 20;
}
}
}
}
}
};
stop();
Symbol 439 MovieClip Frame 2
stop();
Symbol 439 MovieClip Frame 3
stop();
Symbol 439 MovieClip Frame 4
stop();
Symbol 441 MovieClip Frame 1
var xpos = this._x;
var ypos = -500;
onEnterFrame = function () {
if (_root.isPause == false) {
this._visible = true;
this._y = this._y + _root.speed;
if (this._y > 700) {
_y = ypos;
}
}
if (this.hitTest(_parent.loveStopL_mc)) {
this._visible = false;
}
if (this.hitTest(_parent.loveStopR_mc)) {
this._visible = false;
}
};
Symbol 442 MovieClip Frame 1
function checkCollision(mc2, mc1) {
var _local1 = classes.CollisionDetection.checkForCollision(mc1, mc2, 120);
return(_local1);
}
_root.speed = 10;
_root.isPause = false;
_root.increaseMetr = 0;
_root.decreaseMetr = 0;
var Rlimit = ((divRT_mc._x - (divRT_mc._width / 2)) - (hero_mc._width / 2));
var Llimit = ((divLT_mc._x + (divLT_mc._width / 2)) + (hero_mc._width / 2));
var Dlimit = (290 - (hero_mc._height / 2));
var Ulimit = (-290 + (hero_mc._height / 2));
var Rbound = ((divRT_mc._x - divRT_mc._width) - (C3_mc._width / 2));
var Lbound = ((divLT_mc._x + divLT_mc._width) + (C3_mc._width / 2));
var laneArray = [1, 2, 3, 4, 5, 6];
var tArray = [1, 2];
onEnterFrame = function () {
if (_root.isPause == false) {
if (C1_mc.hitTest(C2_mc)) {
if ((checkCollision(C1_mc, C2_mc) != undefined) || (checkCollision(C1_mc, C2_mc) != null)) {
if ((C1_mc._y >= ymin) && (C2_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C2_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y >= ymin) && (C2_mc._y >= ymin)) {
C1_mc._y = C1_mc._y - 10;
C2_mc._y = C2_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C2_mc._y >= ymin)) {
C1_mc._y = C1_mc._y + 10;
C2_mc._y = C2_mc._y - 10;
C1_mc._x = C1_mc._x - 10;
C2_mc._x = C2_mc._x + 10;
}
}
}
if (C2_mc.hitTest(C3_mc)) {
if ((checkCollision(C2_mc, C3_mc) != undefined) || (checkCollision(C2_mc, C3_mc) != null)) {
if ((C2_mc._y >= ymin) && (C3_mc._y <= ymax)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y <= ymax) && (C3_mc._y <= ymax)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y >= ymin) && (C3_mc._y >= ymin)) {
C2_mc._y = C2_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C2_mc._y <= ymax) && (C3_mc._y >= ymin)) {
C2_mc._y = C2_mc._y + 10;
C3_mc._y = C3_mc._y - 10;
C2_mc._x = C2_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
}
}
}
if (C1_mc.hitTest(C3_mc)) {
if ((checkCollision(C1_mc, C3_mc) != undefined) || (checkCollision(C1_mc, C3_mc) != null)) {
if ((C1_mc._y >= ymin) && (C3_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C3_mc._y <= ymax)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y >= ymin) && (C3_mc._y >= ymin)) {
C1_mc._y = C1_mc._y - 10;
C3_mc._y = C3_mc._y + 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
} else if ((C1_mc._y <= ymax) && (C3_mc._y >= ymin)) {
C1_mc._y = C1_mc._y + 10;
C3_mc._y = C3_mc._y - 10;
C1_mc._x = C1_mc._x - 10;
C3_mc._x = C3_mc._x + 10;
}
}
}
}
};
Instance of Symbol 397 MovieClip "C3_mc" in Symbol 442 MovieClip Frame 1
onClipEvent (load) {
_root.count = 0;
}
Instance of Symbol 397 MovieClip "C2_mc" in Symbol 442 MovieClip Frame 1
onClipEvent (load) {
_root.count = 0;
}
Instance of Symbol 397 MovieClip "C1_mc" in Symbol 442 MovieClip Frame 1
onClipEvent (load) {
_root.count = 0;
}
Symbol 461 Button
on (release) {
_root._newUser();
}
Symbol 470 MovieClip Frame 1
if (_root.cancelCon) {
_root.cancelCon = false;
gotoAndStop(this._totalframes);
}
Symbol 470 MovieClip Frame 25
stop();
stop();
playAgain_btn.onRelease = function () {
_root.score = 0;
_root._playAgain(_root, "lblgameintro");
};
submit_btn.onRelease = function () {
trace((((_root.score + " ") + _root._gameid) + " ") + _root.uname);
_root.dataSubmit(_root.uname, _root.score, _root._gameid, _root, "gameOver", "connecting", "highScores");
};
username_txt.onSetFocus = function () {
if (username_txt.text == "Invalid Nickname!") {
username_txt.text = "";
}
};
Selection.setFocus("username_txt");
Symbol 483 MovieClip Frame 6
stop();
Symbol 492 MovieClip Frame 9
stop();
Symbol 502 MovieClip Frame 1
if (_root.cancelCon) {
_root.cancelCon = false;
gotoAndStop(this._totalframes);
}
Symbol 502 MovieClip Frame 28
stop();
Symbol 506 MovieClip Frame 1
stop();
Symbol 510 MovieClip Frame 3
stop();
Symbol 512 MovieClip Frame 1
if (_root.cancelCon) {
_root.cancelCon = false;
gotoAndStop(this._totalframes);
}
Symbol 512 MovieClip Frame 33
stop();
playAgain_btn.onRelease = function () {
_root.score = 0;
mystr = _root.levelArray[int(_root.level - 1)];
_root._playAgain(_root, mystr);
};
submit_btn.onRelease = function () {
trace((((_root.score + " ") + _root._gameid) + " ") + _root.uname);
_root.dataSubmit(_root.uname, _root.score, _root._gameid, _root, "gameOver", "connecting", "highScores");
};
username_txt.onSetFocus = function () {
if (username_txt.text == "Invalid Nickname!") {
username_txt.text = "";
}
};
Selection.setFocus("username_txt");
Symbol 533 Button
on (release) {
if (!_root._win) {
_root.cancelCon = true;
_root.cancelSubmit(_root, "gameOver");
} else {
_root.cancelCon = true;
_root.cancelSubmit(_root, "win");
}
}
Symbol 539 MovieClip Frame 37
stop();
Symbol 572 MovieClip Frame 1
_root.displayScores(this);
Symbol 574 MovieClip Frame 40
stop();
playAgain_btn.onRelease = function () {
_root.score = 0;
_root.playIntro = true;
_root.playIntroSound = true;
_root.level = 1;
_root._playAgain(_root, "lblgameintro");
};
Symbol 590 MovieClip Frame 145
stop();
next_btn.onRelease = function () {
_root.gotoAndStop(_root.levelArray[int(_root.level)]);
};