Frame 2
if (_framesloaded < _totalframes) {
gotoAndPlay(_currentframe - 1);
} else {
play();
}
Frame 3
hiscore._visible = false;
Instance of Symbol 43 MovieClip in Frame 4
//component parameters
onClipEvent (initialize) {
scoreLocation = "_root.score";
}
Frame 5
var lives = 3;
var level = 1;
setScore(0);
globalSound = new Sound();
var music = new Sound();
music.attachSound("music");
music.start(0, 0);
stop();
Frame 13
function init(n, x, y) {
var _local2 = _root;
var _local1 = 0;
while (_local1 < n) {
_local2.attachMovie("partic", "partic" + _local1, _local1 + 200);
_local2["partic" + _local1]._x = x;
_local2["partic" + _local1]._y = y;
var _local3 = Math.random() * 50;
_local2["partic" + _local1]._xscale = _local2["partic" + _local1]._xscale + _local3;
_local2["partic" + _local1]._yscale = _local2["partic" + _local1]._yscale + _local3;
_local2["partic" + _local1].freeFall();
_local1++;
}
}
function runparticles(x, y) {
init(10, x, y);
}
function killMC(which) {
which.removeMovieClip();
}
var gameOn = false;
hole._visible = false;
txtLvl.text = level;
if (level == 1) {
brick1._visible = false;
brick2._visible = false;
brick3._visible = false;
} else if (level == 2) {
brick1._visible = false;
brick2._visible = true;
brick3._visible = false;
} else if (level == 3) {
brick1._visible = false;
brick2._visible = true;
brick3._visible = true;
} else {
brick1._visible = true;
brick2._visible = true;
brick3._visible = true;
}
var i = 0;
while (i < 10) {
if (i == 0) {
cube = cube0;
} else {
cube = cube0.duplicateMovieClip("cube" + i, i);
}
cube.gotoAndStop(i + 1);
cube._x = cube0._x + (i * 50);
cube._visible = true;
i++;
}
var i = 0;
while (i < 10) {
cube = cube0.duplicateMovieClip("cube" + (10 + i), i + 10);
cube._alpha = 100;
cube._y = cube0._y + 25;
cube.gotoAndStop(i + 1);
cube._x = cube0._x + (i * 50);
cube._visible = true;
i++;
}
MovieClip.prototype.freeFall = function () {
var _local1 = this;
_local1.onEnterFrame = function () {
var _local1 = this;
if (typeof(_local1.mode) == "undefined") {
dir = ((Math.random() > 0.5) ? 1 : -1);
_local1.mode = 1;
_local1.speedx = (2.5 * Math.random()) * dir;
_local1.accel = 2.5 * Math.random();
_local1.factor = Math.random();
if (_local1.factor < 0.2) {
_local1.factor = _local1.factor + 0.2;
}
_local1.count = 2;
}
if (_local1.mode == 1) {
if (_local1.accel > 0) {
_local1._x = _local1._x - _local1.speedx;
_local1._y = _local1._y - _local1.accel;
_local1._rotation = _local1._rotation - _local1.accel;
if ((--_local1.count) < 0) {
_local1.accel = _local1.accel - _local1.factor;
_local1.count = 2;
}
} else {
_local1.mode = 2;
}
}
if (_local1.mode == 2) {
_local1._x = _local1._x - _local1.speedx;
_local1._y = _local1._y + _local1.accel;
_local1._rotation = _local1._rotation - _local1.accel;
if ((--_local1.count) < 0) {
_local1.accel = _local1.accel + _local1.factor;
_local1.count = 2;
}
if (_local1._y > 370) {
killMC(_local1);
}
}
};
};
Frame 14
var dx = 4;
var dy = -4;
hole._visible = false;
lives_mc.gotoAndStop(lives + 1);
Instance of Symbol 113 MovieClip in Frame 38
onClipEvent (enterFrame) {
if (Key.isDown(37)) {
_parent.lever._x = _parent.lever._x - 5;
if (_parent.lever._x < 55) {
_parent.lever._x = 55;
}
}
if (Key.isDown(39)) {
_parent.lever._x = _parent.lever._x + 5;
if (_parent.lever._x > 495) {
_parent.lever._x = 495;
}
}
if (_parent.gameOn == true) {
_parent.x = _parent.lever._x;
if (_parent.dx > 0) {
_parent.pingu._xscale = 100;
} else {
_parent.pingu._xscale = -100;
}
if (_parent.pingu._x <= 10) {
_parent.dx = _parent.dx * -1;
}
if (_parent.pingu._x >= 540) {
_parent.dx = _parent.dx * -1;
}
_parent.pingu._y = _parent.pingu._y + _parent.dy;
if ((_parent.dy < 0) && (_parent.pingu._y >= 350)) {
_parent.pingu._y = 345;
}
_parent.pingu._x = _parent.pingu._x + _parent.dx;
if (_parent.dy < 8) {
_parent.dy = _parent.dy + 0.18;
}
if (_parent.dy > 0) {
if (Math.abs(_parent.dx) > 1) {
if (_parent.dx < 0) {
_parent.dx = _parent.dx + 0.01;
} else {
_parent.dx = _parent.dx - 0.01;
}
}
}
if (_parent.pingu._y < 200) {
var i = 0;
while (i < 20) {
thecube = _parent["cube" + i];
if (thecube._visible == true) {
if (thecube.hitTest(_parent.pingu)) {
thecube._visible = false;
_parent.ice_sound.start();
setScore(_parent.score + 10);
_parent.txtScr.text = _parent.score;
_parent.runparticles(thecube._x, thecube._y);
pandcdiff = _parent.pingu._x - thecube._x;
_parent.dx = (2 * pandcdiff) / 35;
_parent.dy = 3;
blocksflag = false;
var i = 0;
while (i < 20) {
thecube = _parent["cube" + i];
if (thecube._visible == true) {
blocksflag = true;
}
i++;
}
if (blocksflag == false) {
_parent.gameOn = false;
_parent.gotoAndPlay("nextLevel");
}
}
}
i++;
}
}
brickflag = false;
if (_parent.level == 1) {
} else if (_parent.level == 2) {
if (_parent.pingu.hitTest(_parent.brick2)) {
brickflag = true;
}
} else if (_parent.level == 3) {
if (_parent.pingu.hitTest(_parent.brick2) || (_parent.pingu.hitTest(_parent.brick3))) {
brickflag = true;
}
} else if ((_parent.pingu.hitTest(_parent.brick1) || (_parent.pingu.hitTest(_parent.brick2))) || (_parent.pingu.hitTest(_parent.brick3))) {
brickflag = true;
}
if (brickflag) {
_parent.dx = _parent.dx * -1;
_parent.dy = _parent.dy * -1;
_parent.pingu._x = _parent.pingu._x + _parent.dx;
_parent.pingu._y = _parent.pingu._y + _parent.dy;
}
if (_parent.pingu._y >= 350) {
px = _parent.pingu._x;
lx = _parent.lever._x;
flag = false;
if (_parent.lever._xscale > 0) {
if ((px > lx) && (px < (lx + 50))) {
flag = true;
diff = px - lx;
}
} else if ((px < lx) && (px > (lx - 50))) {
flag = true;
diff = lx - px;
}
if (flag == true) {
_parent.boing_sound.start();
if (diff > 30) {
diff = 30;
}
diffraction = diff / 30;
if (diff == 1) {
diff = 2;
}
_parent.dy = -(6 + (diffraction * 3));
if (_parent.lever._xscale > 0) {
_parent.pingu._x = _parent.lever._x - 44;
} else {
_parent.pingu._x = _parent.lever._x + 44;
}
_parent.dx = _parent.dx * -1;
if (diffraction != 1) {
if (_parent.dx < 0) {
_parent.dx = -4 * diffraction;
} else {
_parent.dx = 4 * diffraction;
}
} else {
_parent.dx = _parent.dx * 0.1;
}
_parent.lever._xscale = _parent.lever._xscale * -1;
} else if (_parent.pingu._y >= 370) {
_parent.pingu._visible = false;
_parent.fall_sound.start();
_parent.fall2_sound.start();
_parent.hole._x = _parent.pingu._x;
_parent.hole._visible = true;
_parent.lives--;
_parent.lives_mc.gotoAndStop(_parent.lives + 1);
_parent.hole.gotoAndPlay(1);
_parent.gameOn = false;
}
}
}
}
Frame 59
gameOn = true;
var boing_sound = new Sound();
boing_sound.attachSound("boing");
var fall_sound = new Sound();
fall_sound.attachSound("splash");
var ice_sound = new Sound();
ice_sound.attachSound("ice");
Frame 78
stop();
Frame 87
if (lives <= 0) {
gotoAndPlay ("gameOver");
} else {
gotoAndPlay ("start3");
}
Instance of Symbol 150 MovieClip "hiscore" in Frame 88
onClipEvent (load) {
this._visible = true;
}
Frame 97
var i = 0;
while (i < 20) {
removeMovieClip(this["cube" + i]);
i++;
}
stop();
Instance of Symbol 150 MovieClip "hiscore" in Frame 97
onClipEvent (load) {
}
Frame 104
gotoAndPlay ("start1");
Instance of Symbol 150 MovieClip in Frame 104
onClipEvent (load) {
}
Frame 107
level++;
if (((level + 1) % 2) == 0) {
if (lives < 3) {
lives++;
}
}
txtLvl.text = level;
lvl.lvl.text = level;
Frame 115
stop();
Frame 123
gotoAndPlay ("start2");
Symbol 42 MovieClip Frame 1
this._visible = false;
Symbol 43 MovieClip Frame 1
_global.SSscoreLocation = scoreLocation;
if (_global.dif == undefined) {
_global.dif = random(100000);
}
_global.lockVariable = function (varName, varValue, newScore) {
var _local1 = _global;
var _local2 = varValue;
if (newScore == undefined) {
if (_local1.lockedVar == undefined) {
_local1.lockedVar = _local2 + _local1.dif;
} else {
_local2 = _local1.lockedVar;
}
} else {
_local1.lockedVar = newScore + _local1.dif;
}
var setVar = int(_local2 - _local1.dif);
Set(varName, _local1.lockedVar - _local1.dif);
};
_global.setScore = function (varValue) {
var _local1 = varValue;
trace("Safe Score Set: " + _local1);
lockVariable(_global.SSscoreLocation, _local1, _local1);
};
ivLockVariable = setInterval(lockVariable, 10, _global.SSscoreLocation, varValue);
stop();
Instance of Symbol 42 MovieClip in Symbol 43 MovieClip Frame 1
onClipEvent (load) {
_visible = false;
}
Symbol 46 Button
on (release, keyPress "<Enter>") {
gotoAndPlay ("start2");
}
Symbol 47 Button
on (release) {
getURL ("http://www.miniclip.com", "_blank");
}
Symbol 55 MovieClip Frame 1
stop();
Symbol 58 Button
on (release) {
if (globalSound.getVolume() > 0) {
globalSound.setVolume(0);
} else {
globalSound.setVolume(100);
}
}
Symbol 66 MovieClip Frame 1
if (!init) {
init = 1;
}
Symbol 71 MovieClip Frame 1
if (!init) {
init = 1;
var size = random(100);
_xscale = (_xscale + size);
_yscale = (_yscale + size);
_rotation = random(360);
gotoAndStop(random(_totalframes) + 1);
}
Symbol 100 MovieClip Frame 49
_parent.play();
stop();
Symbol 103 MovieClip Frame 1
stop();
Symbol 118 Button
on (keyPress "<Space>") {
lever._xscale = lever._xscale * -1;
}
Symbol 120 Button
on (release) {
_visible = false;
_parent.play();
}
Symbol 126 MovieClip Frame 1
this._visible = false;
Symbol 143 Button
on (release) {
gameURL = ("http://www.miniclip.com/" + gamename) + ".htm";
getURL (gameURL, "_blank");
}
Instance of Symbol 126 MovieClip "mcHighscores" in Symbol 149 MovieClip Frame 1
onClipEvent (load) {
_visible = false;
}
Symbol 149 MovieClip Frame 2
if (_url.indexOf("miniclip.com") == -1) {
gotoAndStop(_currentframe + 1);
} else {
var noCache = (getTimer() + random(100000));
mcTarget.loadMovie("http://www.miniclip.com/swfcontent/highscore.swf?" + noCache);
stop();
}
Symbol 149 MovieClip Frame 3
stop();
Instance of Symbol 149 MovieClip "comHighscores" in Symbol 150 MovieClip Frame 1
//component parameters
onClipEvent (initialize) {
scoreLocation = "_root.score";
gamename = "icebreakout";
saveScore = true;
scoreIsTime = false;
scoreReversed = false;
negativeScoreAllowed = false;
}
Symbol 155 Button
on (release, keyPress "<Enter>") {
_parent.play();
}