Frame 1
function quitGame() {
_root.gotoAndStop("quit");
}
function getScores() {
if (gProxyObj == undefined) {
setText("Oops! The high score list isn't available right now!");
} else {
gProxyObj.getScores(myCB);
}
}
function submitScore(theScore) {
gProxyObj.submitScore(theScore, myCB);
}
function initHiScores() {
if (gProxyObj != undefined) {
var _local1 = "sb_bubble_bust";
gProxyObj.setGame_Id(_local1);
}
}
function detectProxyObj() {
if (gProxyObj == undefined) {
return(false);
}
return(gProxyObj.getIsLoggedIn());
}
function getScoreString() {
var errStr = "Oops! The high score list is empty.";
if (gProxyObj == undefined) {
return(errStr);
}
var numScores = gProxyObj.getScoreCount();
if (numScores == 0) {
return(errStr);
}
var _local1;
var _local2;
var _local3;
var thisScore;
var str = "";
_local1 = 0;
while (_local1 < numScores) {
_local2 = gProxyObj.getScoreItem(_local1);
_local3 = _local2[0];
thisScore = _local2[1];
str = str + ((((((_local1 + 1) + " : ") + _local3) + "\t...\t") + thisScore) + newline);
_local1++;
}
return(str);
}
function listScores() {
setText(getScoreString());
}
function setText(str) {
scores_txt.text = str;
}
function myCB(thisBool) {
if (thisBool) {
listScores();
} else {
setText("Oops! The high score list isn't available right now!");
}
}
keyList = new Object();
Key.addListener(keyList);
keyList.onKeyUp = function () {
if (Key.getCode() == 27) {
}
if (Key.getCode() == Key.getAscii(33)) {
_root.debug_mc.gotoAndStop(2);
}
};
hiScoreEnabled = detectProxyObj();
initHiScores();
play();
Frame 2
stop();
Frame 3
stopAllSounds();
stop();
Frame 4
getScores();
stopAllSounds();
stop();
Instance of Symbol 72 MovieClip [FScrollBarSymbol] in Frame 4
//component parameters
onClipEvent (initialize) {
_targetInstanceName = "scores_txt";
horizontal = false;
}
Frame 5
function initGame() {
var _local1 = _root;
_local1.scoreBubb = 0;
_local1.missedBubb = 0;
_local1.xRand = 400;
_local1.totalBubb = 0;
_local1.aliveBubb = 0;
_local1.totalScore = 0;
_local1.poppedBubb = 0;
_local1.deadBubb = 0;
_local1.poppedPercent = 0;
_local1.totalFreaks = 0;
_local1.scoreX = 0;
_local1.stage = 2;
_local1.totalScoreBox._visible = false;
_local1.stageDisplay = _local1.stage - 1;
_local1.maxStage = 13;
_local1.generationRound = 0;
_local1.cycleCheck = 30;
_local1.freakCycle = 30;
_local1.rate = 6;
_local1.bubble0._visible = false;
_local1.maxBubb = 5 * _local1.stage;
_local1.rateBubb = 2.5 * _local1.stage;
}
function nextLevel() {
var _local1 = _root;
stopAllSounds();
_local1.stage++;
_local1.stageDisplay = _local1.stage - 1;
_local1.rate++;
_local1.cycleCheck = _local1.stageDisplay * 10;
_local1.freakCycle = 30 - _local1.stage;
_local1.poppedBubb = 0;
_local1.deadBubb = 0;
_local1.aliveBubb = 0;
_local1.totalBubb = 0;
_local1.missedBubb = 0;
_local1.poppedPercent = 0;
_local1.maxBubb = 10 * _local1.stageDisplay;
_local1.generationRound = 0;
_local1.bGenerator.gotoAndPlay(1);
_local1.megaBomb_mc._visible = true;
_local1.totalScoreBox._visible = true;
_local1.laughOn = false;
_local1.specialMax = Math.floor(_local1.stage / 2);
_local1.specialRound = new Array();
x = 1;
while (x <= _local1.specialMax) {
_local1.specialBubble_mc.duplicateMovieClip("specialBubble_mc" + x, 444 + x);
_local1.roundNum = random(_local1.cycleCheck);
_local1.specialRound.push(_local1.roundNum);
trace("specialRound[x] =" + _local1.specialRound[x]);
x++;
}
_local1.bg.gotoAndStop(_local1.stageDisplay);
}
function generateBubbles(stage, rate) {
x = 1;
while (x <= (random(rate) + (rate / 2))) {
if ((_root.totalBubb <= _root.maxBubb) && (_root.cycleCheck >= 2)) {
_root.bubble0.duplicateMovieClip("bubble" + _root.totalBubb, _root.totalBubb);
var BubbTarget = eval ("bubble" + _root.totalBubb);
BubbTarget._x = random(_root.xRand) + 100;
BubbTarget._y = random(100) + 400;
BubbTarget._xscale = random(50) + 80;
BubbTarget._yscale = BubbTarget._xscale;
BubbTarget.bubbleArt._rotation = random(360);
BubbTarget.moveUpTest = true;
_root.totalBubb++;
_root.aliveBubb++;
_root.scoreBubb = _root.poppedBubb;
_root.generationRound++;
}
x++;
}
}
function spongeCheck() {
_root.unPoppedPercent = Math.floor((_root.missedBubb / _root.totalBubb) * 100);
_root.poppedPercent = 100 - _root.unPoppedPercent;
if (_root.unPoppedPercent == 0) {
_root.freakmeter.gotoAndStop(1);
_root.SpongeBob.gotoAndStop(1);
} else {
_root.freakmeter.gotoAndStop(_root.unPoppedPercent / 2);
_root.SpongeBob.gotoAndStop(_root.unPoppedPercent / 2);
}
x = 1;
while (x < _root.specialMax) {
trace((("SpecialRound " + x) + " = ") + _root.specialRound[x]);
if (_root.specialRound[x] == _root.cycleCheck) {
eval ("_root.specialBubble_mc" + x)._y = 450;
eval ("_root.specialBubble_mc" + x)._x = random(_root.xRand) + 60;
eval ("_root.specialBubble_mc" + x).bombMove = true;
var specialType = (random(2) + 2);
eval ("_root.specialBubble_mc" + x).gotoAndStop(specialType);
}
x++;
}
if (_root.deadBubb >= _root.maxBubb) {
bGenerator.gotoAndStop("pause");
levelUp.gotoAndPlay(2);
stop();
}
}
function moveUp(mtarget, mrate) {
var _local1 = mtarget;
_local1._y = _local1._y - ((Math.abs(_root.rateBubb - (_local1._y * 0.01)) * mrate) * (_root.stage / 2));
}
function popBubble(ptarget) {
_root.aliveBubb--;
_root.deadBubb++;
ptarget.gotoAndPlay(2);
}
function clearScreen(style) {
if (style eq "score") {
y = 1;
while (y < _root.maxBubb) {
eval ("bubble" + y).gotoAndPlay(2);
y++;
}
} else {
y = 1;
while (y < _root.maxBubb) {
eval ("bubble" + y).gotoAndPlay(3);
y++;
}
}
y = 1;
while (y < _root.specialMax) {
eval ("_root.specialBubble_mc" + y)._visible = false;
y++;
}
}
function freezeBomb() {
trace("FREEZEBOMB!");
y = 0;
while (y < _root.maxBubb) {
eval ("_root.bubble" + y).freezeY = random(40);
eval ("_root.bubble" + y).gotoAndStop("freeze");
eval ("_root.bubble" + y).moveUpTest = false;
y++;
}
}
function megaBomb() {
var _local1 = _root;
trace("MEGABOMB!");
_local1.bubbMade = _local1.aliveBubb + _local1.deadBubb;
x = _local1.deadBubb;
while (x < _local1.bubbMade) {
_local1.deadBubb++;
x++;
}
_local1.clearScreen("score");
}
function laughCheck() {
if (_root.laughOn) {
this.play();
} else {
stop();
}
}
_root.initGame();
stop();
Instance of Symbol 404 MovieClip "bubble0" in Frame 5
onClipEvent (enterFrame) {
if (this._name eq "bubble0") {
this._y = 500;
}
if (this.moveUpTest eq false) {
if (this._y > (396 - this.freezeY)) {
_root.moveUp(this, 2);
}
} else if (this.moveUpTest eq true) {
_root.moveUp(this, 1.8);
}
if (this._y < -5) {
_root.missedBubb++;
_root.deadBubb++;
this.removeMovieClip();
}
}
Instance of Symbol 448 MovieClip "bGenerator" in Frame 5
onClipEvent (load) {
this.stage = _root.stage;
this.rate = _root.rate;
}
Instance of Symbol 221 MovieClip "specialBubble_mc" in Frame 5
onClipEvent (enterFrame) {
if (this.bombMove) {
_root.moveUp(this, 1);
}
if (this._y < -50) {
this._y = 450;
this.bombMove = false;
}
}
Frame 6
stopAllSounds();
stop();
Frame 7
submitScore(_root.totalScore);
stop();
Frame 8
_root.clearScreen();
stopAllSounds();
stop();
Symbol 17 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "arrow");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 18 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "arrow");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 31 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "foregroundDisabled");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 32 MovieClip [UpArrow] Frame 1
stop();
Symbol 32 MovieClip [UpArrow] Frame 2
stop();
Symbol 32 MovieClip [UpArrow] Frame 3
stop();
Symbol 39 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 46 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 51 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(highlight3D_mc, "highlight3D");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
Symbol 52 MovieClip [ScrollThumb] Frame 1
stop();
Symbol 53 MovieClip [FUIComponentSymbol] Frame 1
#initclip 1
function FUIComponentClass() {
this.init();
}
FUIComponentClass.prototype = new MovieClip();
FUIComponentClass.prototype.init = function () {
var _local1 = this;
var _local3 = _global;
_local1.enable = true;
_local1.focused = false;
_local1.useHandCursor = false;
_local1._accImpl = new Object();
_local1._accImpl.stub = true;
_local1.styleTable = new Array();
if (_local3.globalStyleFormat == undefined) {
_local3.globalStyleFormat = new FStyleFormat();
globalStyleFormat.isGlobal = true;
_local3._focusControl = new Object();
_local3._focusControl.onSetFocus = function (oldFocus, newFocus) {
oldFocus.myOnKillFocus();
newFocus.myOnSetFocus();
};
Selection.addListener(_local3._focusControl);
}
if (_local1._name != undefined) {
_local1._focusrect = false;
_local1.tabEnabled = true;
_local1.focusEnabled = true;
_local1.tabChildren = false;
_local1.tabFocused = true;
if (_local1.hostStyle == undefined) {
globalStyleFormat.addListener(_local1);
} else {
_local1.styleTable = _local1.hostStyle;
}
_local1.deadPreview._visible = false;
_local1.deadPreview._width = (_local1.deadPreview._height = 1);
_local1.methodTable = new Object();
_local1.keyListener = new Object();
_local1.keyListener.controller = _local1;
_local1.keyListener.onKeyDown = function () {
this.controller.myOnKeyDown();
};
_local1.keyListener.onKeyUp = function () {
this.controller.myOnKeyUp();
};
for (var _local2 in _local1.styleFormat_prm) {
_local1.setStyleProperty(_local2, _local1.styleFormat_prm[_local2]);
}
}
};
FUIComponentClass.prototype.setEnabled = function (enabledFlag) {
var _local1 = this;
_local1.enable = ((arguments.length > 0) ? (enabledFlag) : true);
_local1.tabEnabled = (_local1.focusEnabled = enabledFlag);
if ((!_local1.enable) && (_local1.focused)) {
Selection.setFocus(undefined);
}
};
FUIComponentClass.prototype.getEnabled = function () {
return(this.enable);
};
FUIComponentClass.prototype.setSize = function (w, h) {
var _local1 = this;
_local1.width = w;
_local1.height = h;
_local1.focusRect.removeMovieClip();
};
FUIComponentClass.prototype.setChangeHandler = function (chng, obj) {
var _local1 = this;
_local1.handlerObj = ((obj == undefined) ? (_local1._parent) : (obj));
_local1.changeHandler = chng;
};
FUIComponentClass.prototype.invalidate = function (methodName) {
var _local1 = this;
_local1.methodTable[methodName] = true;
_local1.onEnterFrame = _local1.cleanUI;
};
FUIComponentClass.prototype.cleanUI = function () {
var _local1 = this;
if (_local1.methodTable.setSize) {
_local1.setSize(_local1.width, _local1.height);
} else {
_local1.cleanUINotSize();
}
_local1.methodTable = new Object();
delete _local1.onEnterFrame;
};
FUIComponentClass.prototype.cleanUINotSize = function () {
var _local1 = this;
for (var _local2 in _local1.methodTable) {
_local1[_local2]();
}
};
FUIComponentClass.prototype.drawRect = function (x, y, w, h) {
var _local1 = this;
var _local2 = y;
var _local3 = x;
var inner = _local1.styleTable.focusRectInner.value;
var outer = _local1.styleTable.focusRectOuter.value;
if (inner == undefined) {
inner = 16777215 /* 0xFFFFFF */;
}
if (outer == undefined) {
outer = 0;
}
_local1.createEmptyMovieClip("focusRect", 1000);
_local1.focusRect.controller = _local1;
_local1.focusRect.lineStyle(1, outer);
_local1.focusRect.moveTo(_local3, _local2);
_local1.focusRect.lineTo(_local3 + w, _local2);
_local1.focusRect.lineTo(_local3 + w, _local2 + h);
_local1.focusRect.lineTo(_local3, _local2 + h);
_local1.focusRect.lineTo(_local3, _local2);
_local1.focusRect.lineStyle(1, inner);
_local1.focusRect.moveTo(_local3 + 1, _local2 + 1);
_local1.focusRect.lineTo((_local3 + w) - 1, _local2 + 1);
_local1.focusRect.lineTo((_local3 + w) - 1, (_local2 + h) - 1);
_local1.focusRect.lineTo(_local3 + 1, (_local2 + h) - 1);
_local1.focusRect.lineTo(_local3 + 1, _local2 + 1);
};
FUIComponentClass.prototype.pressFocus = function () {
var _local1 = this;
_local1.tabFocused = false;
_local1.focusRect.removeMovieClip();
Selection.setFocus(_local1);
};
FUIComponentClass.prototype.drawFocusRect = function () {
var _local1 = this;
_local1.drawRect(-2, -2, _local1.width + 4, _local1.height + 4);
};
FUIComponentClass.prototype.myOnSetFocus = function () {
var _local1 = this;
_local1.focused = true;
Key.addListener(_local1.keyListener);
if (_local1.tabFocused) {
_local1.drawFocusRect();
}
};
FUIComponentClass.prototype.myOnKillFocus = function () {
var _local1 = this;
_local1.tabFocused = true;
_local1.focused = false;
_local1.focusRect.removeMovieClip();
Key.removeListener(_local1.keyListener);
};
FUIComponentClass.prototype.executeCallBack = function () {
var _local1 = this;
_local1.handlerObj[_local1.changeHandler](_local1);
};
FUIComponentClass.prototype.updateStyleProperty = function (styleFormat, propName) {
this.setStyleProperty(propName, styleFormat[propName], styleFormat.isGlobal);
};
FUIComponentClass.prototype.setStyleProperty = function (propName, value, isGlobal) {
var _local1 = this;
var _local2 = propName;
if (value == "") {
} else {
var tmpValue = parseInt(value);
if (!isNaN(tmpValue)) {
value = tmpValue;
}
var global = ((arguments.length > 2) ? (isGlobal) : false);
if (_local1.styleTable[_local2] == undefined) {
_local1.styleTable[_local2] = new Object();
_local1.styleTable[_local2].useGlobal = true;
}
if (_local1.styleTable[_local2].useGlobal || (!global)) {
_local1.styleTable[_local2].value = value;
if (_local1.setCustomStyleProperty(_local2, value)) {
} else if (_local2 == "embedFonts") {
_local1.invalidate("setSize");
} else if (_local2.subString(0, 4) == "text") {
if (_local1.textStyle == undefined) {
_local1.textStyle = new TextFormat();
}
var textProp = _local2.subString(4, _local2.length);
_local1.textStyle[textProp] = value;
_local1.invalidate("setSize");
} else {
for (var j in _local1.styleTable[_local2].coloredMCs) {
var _local3 = new Color(_local1.styleTable[_local2].coloredMCs[j]);
if (_local1.styleTable[_local2].value == undefined) {
var myTObj = {ra:"100", rb:"0", ga:"100", gb:"0", ba:"100", bb:"0", aa:"100", ab:"0"};
_local3.setTransform(myTObj);
} else {
_local3.setRGB(value);
}
}
}
_local1.styleTable[_local2].useGlobal = global;
}
}
};
FUIComponentClass.prototype.registerSkinElement = function (skinMCRef, propName) {
var _local1 = this;
var _local2 = propName;
if (_local1.styleTable[_local2] == undefined) {
_local1.styleTable[_local2] = new Object();
_local1.styleTable[_local2].useGlobal = true;
}
if (_local1.styleTable[_local2].coloredMCs == undefined) {
_local1.styleTable[_local2].coloredMCs = new Object();
}
_local1.styleTable[_local2].coloredMCs[skinMCRef] = skinMCRef;
if (_local1.styleTable[_local2].value != undefined) {
var _local3 = new Color(skinMCRef);
_local3.setRGB(_local1.styleTable[_local2].value);
}
};
_global.FStyleFormat = function () {
var _local1 = arguments;
var _local2 = this;
_local2.nonStyles = {listeners:true, isGlobal:true, isAStyle:true, addListener:true, removeListener:true, nonStyles:true, applyChanges:true};
_local2.listeners = new Object();
_local2.isGlobal = false;
if (_local1.length > 0) {
for (var _local3 in _local1[0]) {
_local2[_local3] = _local1[0][_local3];
}
}
};
_global.FStyleFormat.prototype = new Object();
FStyleFormat.prototype.addListener = function () {
var _local1 = this;
var _local2 = 0;
while (_local2 < arguments.length) {
var _local3 = arguments[_local2];
_local1.listeners[arguments[_local2]] = _local3;
for (var i in _local1) {
if (_local1.isAStyle(i)) {
_local3.updateStyleProperty(_local1, i.toString());
}
}
_local2++;
}
};
FStyleFormat.prototype.removeListener = function (component) {
var _local1 = this;
var _local2 = component;
_local1.listeners[_local2] = undefined;
for (var prop in _local1) {
if (_local1.isAStyle(prop)) {
if (_local2.styleTable[prop].useGlobal == _local1.isGlobal) {
_local2.styleTable[prop].useGlobal = true;
var _local3 = (_local1.isGlobal ? undefined : (globalStyleFormat[prop]));
_local2.setStyleProperty(prop, _local3, true);
}
}
}
};
FStyleFormat.prototype.applyChanges = function () {
var _local1 = this;
var _local2 = arguments;
var count = 0;
for (var i in _local1.listeners) {
var _local3 = _local1.listeners[i];
if (_local2.length > 0) {
var j = 0;
while (j < _local2.length) {
if (_local1.isAStyle(_local2[j])) {
_local3.updateStyleProperty(_local1, _local2[j]);
}
j++;
}
} else {
for (var j in _local1) {
if (_local1.isAStyle(j)) {
_local3.updateStyleProperty(_local1, j.toString());
}
}
}
}
};
FStyleFormat.prototype.isAStyle = function (name) {
return((this.nonStyles[name] ? false : true));
};
#endinitclip
Symbol 59 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "arrow");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 60 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "arrow");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 68 MovieClip Frame 1
var component = _parent._parent;
component.registerSkinElement(arrow_mc, "foregroundDisabled");
component.registerSkinElement(face_mc, "face");
component.registerSkinElement(shadow_mc, "shadow");
component.registerSkinElement(darkshadow_mc, "darkshadow");
component.registerSkinElement(highlight_mc, "highlight");
component.registerSkinElement(highlight3D_mc, "highlight3D");
Symbol 69 MovieClip [DownArrow] Frame 1
stop();
Symbol 69 MovieClip [DownArrow] Frame 2
stop();
Symbol 69 MovieClip [DownArrow] Frame 3
stop();
Symbol 71 MovieClip Frame 1
var component = _parent;
component.registerSkinElement(track_mc, "scrollTrack");
Symbol 72 MovieClip [FScrollBarSymbol] Frame 1
#initclip 2
FScrollBarClass = function () {
var _local1 = this;
if (_local1._height == 4) {
} else {
_local1.init();
_local1.minPos = (_local1.maxPos = (_local1.pageSize = (_local1.largeScroll = 0)));
_local1.smallScroll = 1;
_local1.width = (_local1.horizontal ? (_local1._width) : (_local1._height));
_local1._xscale = (_local1._yscale = 100);
_local1.setScrollPosition(0);
_local1.tabEnabled = false;
if (_local1._targetInstanceName.length > 0) {
_local1.setScrollTarget(_local1._parent[_local1._targetInstanceName]);
}
_local1.tabChildren = false;
_local1.setSize(_local1.width);
}
};
FScrollBarClass.prototype = new FUIComponentClass();
FScrollBarClass.prototype.setHorizontal = function (flag) {
var _local1 = this;
var _local2 = flag;
if (_local1.horizontal && (!_local2)) {
_local1._xscale = 100;
_local1._rotation = 0;
} else if (_local2 && (!_local1.horizontal)) {
_local1._xscale = -100;
_local1._rotation = -90;
}
_local1.horizontal = _local2;
};
FScrollBarClass.prototype.setScrollProperties = function (pSize, mnPos, mxPos) {
var _local1 = this;
if (!_local1.enable) {
} else {
_local1.pageSize = pSize;
_local1.minPos = Math.max(mnPos, 0);
_local1.maxPos = Math.max(mxPos, 0);
_local1.scrollPosition = Math.max(_local1.minPos, _local1.scrollPosition);
_local1.scrollPosition = Math.min(_local1.maxPos, _local1.scrollPosition);
if ((_local1.maxPos - _local1.minPos) <= 0) {
_local1.scrollThumb_mc.removeMovieClip();
_local1.upArrow_mc.gotoAndStop(3);
_local1.downArrow_mc.gotoAndStop(3);
_local1.downArrow_mc.onPress = (_local1.downArrow_mc.onRelease = (_local1.downArrow_mc.onDragOut = null));
_local1.upArrow_mc.onPress = (_local1.upArrow_mc.onRelease = (_local1.upArrow_mc.onDragOut = null));
_local1.scrollTrack_mc.onPress = (_local1.scrollTrack_mc.onRelease = null);
_local1.scrollTrack_mc.onDragOut = (_local1.scrollTrack_mc.onRollOut = null);
_local1.scrollTrack_mc.useHandCursor = false;
} else {
var _local2 = _local1.getScrollPosition();
_local1.upArrow_mc.gotoAndStop(1);
_local1.downArrow_mc.gotoAndStop(1);
_local1.upArrow_mc.onPress = (_local1.upArrow_mc.onDragOver = _local1.startUpScroller);
_local1.upArrow_mc.onRelease = (_local1.upArrow_mc.onDragOut = _local1.stopScrolling);
_local1.downArrow_mc.onPress = (_local1.downArrow_mc.onDragOver = _local1.startDownScroller);
_local1.downArrow_mc.onRelease = (_local1.downArrow_mc.onDragOut = _local1.stopScrolling);
_local1.scrollTrack_mc.onPress = (_local1.scrollTrack_mc.onDragOver = _local1.startTrackScroller);
_local1.scrollTrack_mc.onRelease = _local1.stopScrolling;
_local1.scrollTrack_mc.onDragOut = _local1.stopScrolling;
_local1.scrollTrack_mc.onRollOut = _local1.stopScrolling;
_local1.scrollTrack_mc.useHandCursor = false;
_local1.attachMovie("ScrollThumb", "scrollThumb_mc", 3);
_local1.scrollThumb_mc._x = 0;
_local1.scrollThumb_mc._y = _local1.upArrow_mc._height;
_local1.scrollThumb_mc.onPress = _local1.startDragThumb;
_local1.scrollThumb_mc.controller = _local1;
_local1.scrollThumb_mc.onRelease = (_local1.scrollThumb_mc.onReleaseOutside = _local1.stopDragThumb);
_local1.scrollThumb_mc.useHandCursor = false;
_local1.thumbHeight = (_local1.pageSize / ((_local1.maxPos - _local1.minPos) + _local1.pageSize)) * _local1.trackSize;
_local1.thumbMid_mc = _local1.scrollThumb_mc.mc_sliderMid;
_local1.thumbTop_mc = _local1.scrollThumb_mc.mc_sliderTop;
_local1.thumbBot_mc = _local1.scrollThumb_mc.mc_sliderBot;
_local1.thumbHeight = Math.max(_local1.thumbHeight, 6);
_local1.midHeight = (_local1.thumbHeight - _local1.thumbTop_mc._height) - _local1.thumbBot_mc._height;
_local1.thumbMid_mc._yScale = (_local1.midHeight * 100) / _local1.thumbMid_mc._height;
_local1.thumbMid_mc._y = _local1.thumbTop_mc._height;
_local1.thumbBot_mc._y = _local1.thumbTop_mc._height + _local1.midHeight;
_local1.scrollTop = _local1.scrollThumb_mc._y;
_local1.trackHeight = _local1.trackSize - _local1.thumbHeight;
_local1.scrollBot = _local1.trackHeight + _local1.scrollTop;
_local2 = Math.min(_local2, _local1.maxPos);
_local1.setScrollPosition(Math.max(_local2, _local1.minPos));
}
}
};
FScrollBarClass.prototype.getScrollPosition = function () {
return(this.scrollPosition);
};
FScrollBarClass.prototype.setScrollPosition = function (pos) {
var _local1 = this;
var _local2 = pos;
_local1.scrollPosition = _local2;
if (_local1.scrollThumb_mc != undefined) {
_local2 = Math.min(_local2, _local1.maxPos);
_local2 = Math.max(_local2, _local1.minPos);
}
_local1.scrollThumb_mc._y = (((_local2 - _local1.minPos) * _local1.trackHeight) / (_local1.maxPos - _local1.minPos)) + _local1.scrollTop;
_local1.executeCallBack();
};
FScrollBarClass.prototype.setLargeScroll = function (lScroll) {
this.largeScroll = lScroll;
};
FScrollBarClass.prototype.setSmallScroll = function (sScroll) {
this.smallScroll = sScroll;
};
FScrollBarClass.prototype.setEnabled = function (enabledFlag) {
var _local1 = this;
var _local2 = enabledFlag;
var _local3 = _local1.enable;
if (_local2 && (!_local3)) {
_local1.enable = _local2;
if (_local1.textField != undefined) {
_local1.setScrollTarget(_local1.textField);
} else {
_local1.setScrollProperties(_local1.pageSize, _local1.cachedMinPos, _local1.cachedMaxPos);
_local1.setScrollPosition(_local1.cachedPos);
}
_local1.clickFilter = undefined;
} else if ((!_local2) && (_local3)) {
_local1.textField.removeListener(_local1);
_local1.cachedPos = _local1.getScrollPosition();
_local1.cachedMinPos = _local1.minPos;
_local1.cachedMaxPos = _local1.maxPos;
if (_local1.clickFilter == undefined) {
_local1.setScrollProperties(_local1.pageSize, 0, 0);
} else {
_local1.clickFilter = true;
}
_local1.enable = _local2;
}
};
FScrollBarClass.prototype.setSize = function (hgt) {
var _local1 = this;
if (_local1._height == 1) {
} else {
_local1.width = hgt;
_local1.scrollTrack_mc._yscale = 100;
_local1.scrollTrack_mc._yscale = (100 * _local1.width) / _local1.scrollTrack_mc._height;
if (_local1.upArrow_mc == undefined) {
_local1.attachMovie("UpArrow", "upArrow_mc", 1);
_local1.attachMovie("DownArrow", "downArrow_mc", 2);
_local1.downArrow_mc.controller = (_local1.upArrow_mc.controller = _local1);
_local1.upArrow_mc.useHandCursor = (_local1.downArrow_mc.useHandCursor = false);
_local1.upArrow_mc._x = (_local1.upArrow_mc._y = 0);
_local1.downArrow_mc._x = 0;
}
_local1.scrollTrack_mc.controller = _local1;
_local1.downArrow_mc._y = _local1.width - _local1.downArrow_mc._height;
_local1.trackSize = _local1.width - (2 * _local1.downArrow_mc._height);
if (_local1.textField != undefined) {
_local1.onTextChanged();
} else {
_local1.setScrollProperties(_local1.pageSize, _local1.minPos, _local1.maxPos);
}
}
};
FScrollBarClass.prototype.scrollIt = function (inc, mode) {
var _local1 = this;
var _local3 = _local1.smallScroll;
if (inc != "one") {
_local3 = ((_local1.largeScroll == 0) ? (_local1.pageSize) : (_local1.largeScroll));
}
var _local2 = _local1.getScrollPosition() + (mode * _local3);
if (_local2 > _local1.maxPos) {
_local2 = _local1.maxPos;
} else if (_local2 < _local1.minPos) {
_local2 = _local1.minPos;
}
_local1.setScrollPosition(_local2);
};
FScrollBarClass.prototype.startDragThumb = function () {
var _local1 = this;
_local1.lastY = _local1._ymouse;
_local1.onMouseMove = _local1.controller.dragThumb;
};
FScrollBarClass.prototype.dragThumb = function () {
var _local1 = this;
_local1.scrollMove = _local1._ymouse - _local1.lastY;
_local1.scrollMove = _local1.scrollMove + _local1._y;
if (_local1.scrollMove < _local1.controller.scrollTop) {
_local1.scrollMove = _local1.controller.scrollTop;
} else if (_local1.scrollMove > _local1.controller.scrollBot) {
_local1.scrollMove = _local1.controller.scrollBot;
}
_local1._y = _local1.scrollMove;
var _local2 = _local1.controller;
_local2.scrollPosition = Math.round(((_local2.maxPos - _local2.minPos) * (_local1._y - _local2.scrollTop)) / _local2.trackHeight) + _local2.minPos;
_local1.controller.isScrolling = true;
updateAfterEvent();
_local1.controller.executeCallBack();
};
FScrollBarClass.prototype.stopDragThumb = function () {
this.controller.isScrolling = false;
this.onMouseMove = null;
};
FScrollBarClass.prototype.startTrackScroller = function () {
var _local1 = this;
_local1.controller.trackScroller();
_local1.controller.scrolling = setInterval(_local1.controller, "scrollInterval", 500, "page", -1);
};
FScrollBarClass.prototype.scrollInterval = function (inc, mode) {
var _local1 = this;
var _local2 = inc;
clearInterval(_local1.scrolling);
if (_local2 == "page") {
_local1.trackScroller();
} else {
_local1.scrollIt(_local2, mode);
}
_local1.scrolling = setInterval(_local1, "scrollInterval", 35, _local2, mode);
};
FScrollBarClass.prototype.trackScroller = function () {
var _local1 = this;
if ((_local1.scrollThumb_mc._y + _local1.thumbHeight) < _local1._ymouse) {
_local1.scrollIt("page", 1);
} else if (_local1.scrollThumb_mc._y > _local1._ymouse) {
_local1.scrollIt("page", -1);
}
};
FScrollBarClass.prototype.stopScrolling = function () {
var _local1 = this;
_local1.controller.downArrow_mc.gotoAndStop(1);
_local1.controller.upArrow_mc.gotoAndStop(1);
clearInterval(_local1.controller.scrolling);
};
FScrollBarClass.prototype.startUpScroller = function () {
var _local1 = this;
_local1.controller.upArrow_mc.gotoAndStop(2);
_local1.controller.scrollIt("one", -1);
_local1.controller.scrolling = setInterval(_local1.controller, "scrollInterval", 500, "one", -1);
};
FScrollBarClass.prototype.startDownScroller = function () {
var _local1 = this;
_local1.controller.downArrow_mc.gotoAndStop(2);
_local1.controller.scrollIt("one", 1);
_local1.controller.scrolling = setInterval(_local1.controller, "scrollInterval", 500, "one", 1);
};
FScrollBarClass.prototype.setScrollTarget = function (tF) {
var _local1 = this;
var _local2 = tF;
if (_local2 == undefined) {
_local1.textField.removeListener(_local1);
delete _local1.textField[(_local1.horizontal ? "hScroller" : "vScroller")];
if ((_local1.textField.hScroller != undefined) && (_local1.textField.vScroller != undefined)) {
_local1.textField.unwatch("text");
_local1.textField.unwatch("htmltext");
}
}
_local1.textField = undefined;
if (!(_local2 instanceof TextField)) {
} else {
_local1.textField = _local2;
_local1.textField[(_local1.horizontal ? "hScroller" : "vScroller")] = _local1;
_local1.onTextChanged();
_local1.onChanged = function () {
this.onTextChanged();
};
_local1.onScroller = function () {
var _local1 = this;
if (!_local1.isScrolling) {
if (!_local1.horizontal) {
_local1.setScrollPosition(_local1.textField.scroll);
} else {
_local1.setScrollPosition(_local1.textField.hscroll);
}
}
};
_local1.textField.addListener(_local1);
_local1.textField.watch("text", _local1.callback);
_local1.textField.watch("htmlText", _local1.callback);
}
};
FScrollBarClass.prototype.callback = function (prop, oldVal, newVal) {
var _local1 = this;
clearInterval(_local1.hScroller.synchScroll);
clearInterval(_local1.vScroller.synchScroll);
_local1.hScroller.synchScroll = setInterval(_local1.hScroller, "onTextChanged", 50);
_local1.vScroller.synchScroll = setInterval(_local1.vScroller, "onTextChanged", 50);
return(newVal);
};
FScrollBarClass.prototype.onTextChanged = function () {
var _local1 = this;
if ((!_local1.enable) || (_local1.textField == undefined)) {
} else {
clearInterval(_local1.synchScroll);
if (_local1.horizontal) {
var _local2 = _local1.textField.hscroll;
_local1.setScrollProperties(_local1.textField._width, 0, _local1.textField.maxhscroll);
_local1.setScrollPosition(Math.min(_local2, _local1.textField.maxhscroll));
} else {
var _local2 = _local1.textField.scroll;
var _local3 = _local1.textField.bottomScroll - _local1.textField.scroll;
_local1.setScrollProperties(_local3, 1, _local1.textField.maxscroll);
_local1.setScrollPosition(Math.min(_local2, _local1.textField.maxscroll));
}
}
};
FScrollBarClass.prototype.executeCallBack = function () {
var _local1 = this;
if (_local1.textField == undefined) {
super.executeCallBack();
} else if (_local1.horizontal) {
_local1.textField.hscroll = _local1.getScrollPosition();
} else {
_local1.textField.scroll = _local1.getScrollPosition();
}
};
Object.registerClass("FScrollBarSymbol", FScrollBarClass);
#endinitclip
Symbol 100 MovieClip Frame 1
stop();
Symbol 117 MovieClip Frame 78
stop();
Symbol 150 Button
on (release) {
_root.gotoAndPlay("game");
}
Symbol 155 Button
on (release) {
_root.gotoAndPlay("intro");
}
Symbol 158 Button
on (release) {
_root.gotoAndPlay("scores");
}
Symbol 161 Button
on (release) {
_root.quitGame();
}
Symbol 162 MovieClip Frame 31
stop();
Symbol 165 MovieClip Frame 70
stop();
Symbol 180 Button
on (release) {
this.nextFrame();
}
Symbol 208 Button
on (release) {
this.gotoAndPlay("megaPop");
}
Symbol 212 Button
on (release) {
this.gotoAndPlay("freezePop");
}
Symbol 214 MovieClip Frame 1
_root.bg._y = _root.bg._y + 4;
_root.bg._x = _root.bg._x + 4;
Symbol 214 MovieClip Frame 2
_root.SpongeBob._y = _root.SpongeBob._y + 2;
_root.bg._y = _root.bg._y - 4;
_root.SpongeBob._x = _root.SpongeBob._x + 2;
_root.bg._x = _root.bg._x - 4;
Symbol 214 MovieClip Frame 3
_root.SpongeBob._y = _root.SpongeBob._y - 2;
_root.SpongeBob._x = _root.SpongeBob._x - 2;
Symbol 214 MovieClip Frame 4
_root.bg._y = _root.bg._y + 3;
Symbol 214 MovieClip Frame 5
_root.SpongeBob._y = _root.SpongeBob._y + 1;
_root.bg._y = _root.bg._y - 3;
Symbol 214 MovieClip Frame 6
_root.SpongeBob._y = _root.SpongeBob._y - 1;
Symbol 221 MovieClip Frame 1
stop();
Symbol 221 MovieClip Frame 2
stop();
Symbol 221 MovieClip Frame 3
stop();
Symbol 221 MovieClip Frame 12
_root.megaBomb();
Symbol 221 MovieClip Frame 17
this.removeMovieClip();
stop();
Symbol 221 MovieClip Frame 18
_root.freezeBomb();
Symbol 221 MovieClip Frame 26
this.removeMovieClip();
stop();
Symbol 229 MovieClip Frame 2
stop();
Symbol 229 MovieClip Frame 3
stop();
Symbol 229 MovieClip Frame 4
stop();
Instance of Symbol 221 MovieClip in Symbol 229 MovieClip Frame 4
onClipEvent (load) {
this.gotoAndStop(2);
}
Instance of Symbol 221 MovieClip in Symbol 229 MovieClip Frame 4
onClipEvent (load) {
this.gotoAndStop(3);
}
Symbol 250 MovieClip Frame 1
stop();
Symbol 250 MovieClip Frame 2
stop();
Symbol 250 MovieClip Frame 3
stop();
Symbol 250 MovieClip Frame 4
stop();
Symbol 250 MovieClip Frame 5
stop();
Symbol 250 MovieClip Frame 6
stop();
Symbol 250 MovieClip Frame 7
stop();
Symbol 250 MovieClip Frame 8
stop();
Symbol 250 MovieClip Frame 9
stop();
Symbol 250 MovieClip Frame 10
stop();
Symbol 250 MovieClip Frame 11
stop();
Symbol 250 MovieClip Frame 12
stop();
Symbol 250 MovieClip Frame 13
stop();
Symbol 299 MovieClip Frame 1
this.laughCheck();
Symbol 299 MovieClip Frame 3
_root.laughOn = true;
Symbol 299 MovieClip Frame 25
_root.laughOn = false;
Symbol 307 MovieClip Frame 1
this.laughCheck();
Symbol 307 MovieClip Frame 3
_root.laughOn = true;
Symbol 307 MovieClip Frame 36
_root.laughOn = false;
Symbol 347 MovieClip Frame 1
this.laughCheck();
Symbol 347 MovieClip Frame 3
_root.laughOn = true;
Symbol 347 MovieClip Frame 17
_root.laughOn = false;
Symbol 350 MovieClip Frame 1
this.laughCheck();
Symbol 350 MovieClip Frame 3
_root.laughOn = true;
Symbol 350 MovieClip Frame 20
_root.laughOn = false;
Symbol 354 MovieClip Frame 1
this.laughCheck();
Symbol 354 MovieClip Frame 3
_root.laughOn = true;
Symbol 354 MovieClip Frame 38
_root.laughOn = false;
Symbol 363 MovieClip Frame 1
this.laughCheck();
Symbol 363 MovieClip Frame 3
_root.laughOn = true;
Symbol 363 MovieClip Frame 37
_root.laughOn = false;
Symbol 365 MovieClip Frame 1
this.laughCheck();
Symbol 365 MovieClip Frame 3
_root.laughOn = true;
Symbol 365 MovieClip Frame 21
_root.laughOn = false;
Symbol 389 MovieClip Frame 1
this.laughCheck();
Symbol 389 MovieClip Frame 3
_root.laughOn = true;
Symbol 389 MovieClip Frame 34
_root.laughOn = false;
Symbol 390 MovieClip Frame 1
stop();
Instance of Symbol 286 MovieClip in Symbol 390 MovieClip Frame 15
/* no clip actions */
Symbol 391 MovieClip Frame 46
_root.totalFreaks++;
if (_root.totalFreaks > 0) {
_root.bGenerator.gotoAndStop("end");
_root.clearScreen();
_root.gotoAndStop("lose");
}
Symbol 391 MovieClip Frame 47
_root.totalFreaks++;
if (_root.totalFreaks > 0) {
_root.bGenerator.gotoAndStop("end");
_root.clearScreen();
_root.gotoAndStop("lose");
}
Symbol 391 MovieClip Frame 48
_root.totalFreaks++;
if (_root.totalFreaks > 0) {
_root.bGenerator.gotoAndStop("end");
_root.clearScreen();
_root.gotoAndStop("lose");
}
Symbol 391 MovieClip Frame 49
_root.bGenerator.gotoAndStop("end");
_root.clearScreen();
_root.gotoAndStop("lose");
Symbol 391 MovieClip Frame 50
_root.bGenerator.gotoAndStop("end");
_root.clearScreen();
_root.gotoAndStop("lose");
Symbol 393 Button
on (release) {
_root.popBubble(this);
sfx_pops.gotoAndStop(random(3) + 2);
}
Symbol 395 MovieClip Frame 1
stop();
Symbol 395 MovieClip Frame 2
stop();
Symbol 395 MovieClip Frame 3
stop();
Symbol 395 MovieClip Frame 4
stop();
Symbol 395 MovieClip Frame 5
stop();
Symbol 402 MovieClip Frame 5
stop();
Symbol 403 Button
on (release) {
_root.sfx_icePop.gotoAndPlay(2);
_root.popBubble(this);
}
Symbol 404 MovieClip Frame 1
BubButt.tabEnabled = false;
stop();
Symbol 404 MovieClip Frame 2
_root.poppedBubb++;
_root.scoreBubb = _root.poppedBubb;
Symbol 404 MovieClip Frame 7
this.removeMovieClip();
Symbol 404 MovieClip Frame 8
stop();
Symbol 423 Button
on (release) {
_root.SpongeBob.gotoAndStop(1);
_root.fade.gotoAndPlay(1);
_root.nextLevel();
this.gotoandStop(1);
}
Symbol 441 MovieClip Frame 1
stop();
Instance of Symbol 429 MovieClip in Symbol 441 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_root.roundScoreCount < _root.scoreBubb) {
_root.roundScoreCount = Number(_root.roundScoreCount + 1);
} else {
_parent.play();
}
}
Symbol 441 MovieClip Frame 3
stop();
Instance of Symbol 429 MovieClip in Symbol 441 MovieClip Frame 3
onClipEvent (enterFrame) {
if (_root.roundBonusCount == _root.poppedPercent) {
_parent.play();
} else if (_root.roundBonusCount < (_root.poppedPercent - 10)) {
_root.roundBonusCount = Number(_root.roundBonusCount + 4);
} else if (_root.roundBonusCount >= (_root.poppedPercent - 10)) {
_root.roundBonusCount = Number(_root.roundBonusCount + 1);
}
}
Symbol 441 MovieClip Frame 7
stop();
Symbol 442 Button
on (release) {
_root.gotoAndStop("win");
}
Symbol 443 MovieClip Frame 1
stop();
Symbol 443 MovieClip Frame 2
_root.bGenerator.gotoAndStop("end");
_root.roundScoreCount = 0;
_root.roundBonusCount = 0;
if (_root.stage == _root.maxStage) {
this.gotoAndPlay("endGame");
}
Symbol 443 MovieClip Frame 17
_root.clearScreen();
Symbol 443 MovieClip Frame 24
_root.spongeBob.sfx_laugh.gotoAndStop(1);
Symbol 443 MovieClip Frame 29
_root.clearScreen();
if (_root.missedBubb == 0) {
_root.poppedPercent = 100;
} else if (_root.scoreBubb == 0) {
_root.poppedPercent = 0;
}
_root.roundScore = _root.scoreBubb * _root.poppedPercent;
_root.totalScore = _root.totalScore + _root.roundScore;
endRound.startLevel = ("Get ready for level " + Number(_root.stage)) + "!";
stopAllSounds();
Symbol 443 MovieClip Frame 33
stop();
Symbol 443 MovieClip Frame 41
_root.clearScreen();
Symbol 443 MovieClip Frame 48
_root.spongeBob.sfx_laugh.gotoAndStop(1);
Symbol 443 MovieClip Frame 53
_root.clearScreen();
if (_root.missedBubb == 0) {
_root.poppedPercent = 100;
}
_root.roundScore = _root.scoreBubb * _root.poppedPercent;
_root.totalScore = _root.totalScore + _root.roundScore;
endRound.startLevel = "You did it!";
Symbol 443 MovieClip Frame 58
stop();
Symbol 444 MovieClip Frame 5
stop();
Symbol 446 MovieClip Frame 1
stop();
Symbol 446 MovieClip Frame 2
play();
Symbol 446 MovieClip Frame 4
sfx_pops.gotoAndStop(random(3) + 2);
Symbol 446 MovieClip Frame 11
stop();
Symbol 448 MovieClip Frame 1
_root.GenerateBubbles(this.stage, this.rate);
_level0.bubble0._visible = false;
play();
Symbol 448 MovieClip Frame 3
_root.spongeCheck();
if (_root.cycleCheck > 2) {
_root.cycleCheck--;
}
if (_root.freakCycle > 2) {
_root.freakCycle--;
}
Symbol 448 MovieClip Frame 6
_root.spongeCheck();
Symbol 448 MovieClip Frame 8
_root.spongeCheck();
Symbol 448 MovieClip Frame 11
_root.spongeCheck();
Symbol 448 MovieClip Frame 13
_root.spongeCheck();
if (_root.cycleCheck > 3) {
_root.cycleCheck--;
}
if (_root.freakCycle > 2) {
_root.freakCycle--;
}
Symbol 448 MovieClip Frame 15
_root.spongeCheck();
Symbol 448 MovieClip Frame 16
if (_root.cycleCheck > 3) {
_root.cycleCheck--;
}
if (_root.freakCycle > 2) {
_root.freakCycle--;
}
gotoAndPlay (1);
Symbol 448 MovieClip Frame 17
stop();
Symbol 451 Button
on (release) {
_root.rateBubb = 5;
}
Symbol 495 MovieClip Frame 52
stop();
Symbol 496 MovieClip Frame 44
stop();
Symbol 519 MovieClip Frame 30
stop();