Frame 1
stop();
btn_inGameMenu.btn.enabled = false;
var buyWebPage = "http://www.wildpulsegames.com/collinks.html";
Instance of Symbol 83 MovieClip "sfx" in Frame 1
onClipEvent (load) {
function enable(b) {
_root.sfxEnabled = b;
}
function setVol(v) {
if (v < 0) {
v = 0;
} else if (v > 100) {
v = 100;
}
special.setVolume(v);
_root.sfxVol = v;
}
var slide = new Sound(this);
var block_land = new Sound(this);
var block_pop = new Sound(this);
var block_popH1 = new Sound(this);
var block_popH2 = new Sound(this);
var block_popH3 = new Sound(this);
var block_popH4 = new Sound(this);
var combo = new Sound(this);
var level_up = new Sound(this);
var special = new Sound(this);
var loose = new Sound(this);
var pauseSnd = new Sound(this);
var new_HS = new Sound(this);
var btn_rollover = new Sound(this);
var game_select = new Sound(this);
var tick_warning = new Sound(this);
var go = new Sound(this);
var loose = new Sound(this);
slide.attachSound("sfx_slide");
block_land.attachSound("sfx_block_land");
block_pop.attachSound("sfx_block_pop");
block_popH1.attachSound("sfx_block_popH1");
block_popH2.attachSound("sfx_block_popH2");
block_popH3.attachSound("sfx_block_popH3");
block_popH4.attachSound("sfx_block_popH4");
combo.attachSound("sfx_combo");
level_up.attachSound("sfx_level_up");
special.attachSound("sfx_special");
loose.attachSound("sfx_loose");
pauseSnd.attachSound("sfx_pauseSnd");
new_HS.attachSound("sfx_new_HS");
btn_rollover.attachSound("sfx_btn_rollover");
game_select.attachSound("sfx_game_select");
tick_warning.attachSound("sfx_tick_warning");
go.attachSound("sfx_go");
loose.attachSound("sfx_loose");
_root.sfxEnabled = 1;
_root.sfxVol = 100;
}
Instance of Symbol 64 MovieClip "btn_inGameMenu" in Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
_root.menuBtn_hit();
};
btn.onRollOver = function () {
_parent.inGame_menuState.gotoAndStop(2);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.inGame_menuState.gotoAndStop(1);
});
}
Instance of Symbol 64 MovieClip "btn_inGameMenu" in Frame 1
onClipEvent (load) {
btn.onRelease = function () {
_root.play();
};
}
Frame 2
function storeRank(slot, name, points, level, bCleared, bCombo, tCombo, gmode, diff) {
var _local7 = _root["highScore_" + gmode]["rank" + slot];
var _local3;
var _local4;
var _local5 = 5;
while (_local5 > slot) {
_local4 = _root["highScore_" + gmode]["rank" + _local5];
_local3 = _root["highScore_" + gmode]["rank" + (_local5 - 1)];
_local4["name_" + diff] = _local3["name_" + diff];
_local4["points_" + diff] = _local3["points_" + diff];
_local4["level_" + diff] = _local3["level_" + diff];
_local4["blocksCleared_" + diff] = _local3["blocksCleared_" + diff];
_local4["bestCombo_" + diff] = _local3["bestCombo_" + diff];
_local4["totalCombo_" + diff] = _local3["totalCombo_" + diff];
_local5--;
}
_local7["name_" + diff] = name;
_local7["points_" + diff] = points;
_local7["level_" + diff] = level;
_local7["blocksCleared_" + diff] = bCleared;
_local7["bestCombo_" + diff] = bCombo;
_local7["totalCombo_" + diff] = tCombo;
}
function checkRank(points, gmode, diff) {
var _local2 = 1;
while (_local2 < 6) {
if (points > _root["highScore_" + gmode]["rank" + _local2]["points_" + diff]) {
return(_local2);
}
_local2++;
}
return(0);
}
function isAlphaNum(n) {
return(((((((n > 96) && (n < 123)) || ((n > 47) && (n < 58))) || ((n > 64) && (n < 91))) || (n == 32)) ? true : false));
}
function getLinearHS() {
var _local2 = "";
var _local4 = 0;
while (_local4 < 3) {
var _local3 = 1;
while (_local3 < 6) {
if (_local4 == 0) {
tmp = highScore_drop["rank" + _local3];
} else if (_local4 == 1) {
tmp = highScore_swap["rank" + _local3];
} else {
tmp = highScore_shift["rank" + _local3];
}
var _local1 = 0;
while (_local1 < 2) {
_local2 = _local2 + (tmp["name_" + _local1] + "~");
_local2 = _local2 + (tmp["points_" + _local1] + "~");
_local2 = _local2 + (tmp["level_" + _local1] + "~");
_local2 = _local2 + (tmp["blocksCleared_" + _local1] + "~");
_local2 = _local2 + (tmp["bestCombo_" + _local1] + "~");
_local2 = _local2 + (tmp["totalCombo_" + _local1] + ((_local1 < 3) ? ";" : ""));
_local1++;
}
_local2 = _local2 + ((_local3 < 5) ? "@" : "");
_local3++;
}
_local2 = _local2 + ((_local4 < 2) ? "&" : "");
_local4++;
}
return(_local2);
}
function restoreSavedHS(theData) {
loadData.load("http://www.wildpulsegames.com/games/puzzle/collinks/hs/highscores.txt");
var _local6 = theData.split("&");
if (_local6.length != 3) {
return(false);
}
var _local3 = 0;
while (_local3 < 3) {
this[("rawSave_mode" + _local3) + "_rank"] = _local6[_local3].split("@");
_local6[_local3] = null;
if (this[("rawSave_mode" + _local3) + "_rank"].length != 5) {
return(false);
}
var _local4 = 0;
while (_local4 < 5) {
this[(("rawSave_mode" + _local3) + "_rank") + _local4] = this[("rawSave_mode" + _local3) + "_rank"][_local4].split(";");
this[("rawSave_mode" + _local3) + "_rank"][_local4] = null;
if (this[(("rawSave_mode" + _local3) + "_rank") + _local4].length != 2) {
return(false);
}
var _local5 = 0;
while (_local5 < 2) {
this[(((("rawSave_mode" + _local3) + "_rank") + _local4) + "_diff") + _local5] = this[(("rawSave_mode" + _local3) + "_rank") + _local4][_local5].split("~");
this[(("rawSave_mode" + _local3) + "_rank") + _local4][_local5] = null;
if (this[(((("rawSave_mode" + _local3) + "_rank") + _local4) + "_diff") + _local5].length != 6) {
return(false);
}
_local5++;
}
_local4++;
}
_local3++;
}
var _local4 = 0;
while (_local4 < 7) {
_local3 = 1;
while (_local3 < 6) {
if (_local4 == 0) {
tmp = highScore_drop["rank" + _local3];
} else if (_local4 == 1) {
tmp = highScore_replace["rank" + _local3];
} else if (_local4 == 2) {
tmp = highScore_swap["rank" + _local3];
} else if (_local4 == 3) {
tmp = highScore_shift["rank" + _local3];
} else if (_local4 == 4) {
tmp = highScore_drag["rank" + _local3];
} else if (_local4 == 5) {
tmp = highScore_slide["rank" + _local3];
} else {
tmp = highScore_action["rank" + _local3];
}
var _local2 = 0;
while (_local2 < 4) {
tmp["name_" + _local2] = this[(((("rawSave_mode" + _local4) + "_rank") + (_local3 - 1)) + "_diff") + _local2][0];
tmp["points_" + _local2] = this[(((("rawSave_mode" + _local4) + "_rank") + (_local3 - 1)) + "_diff") + _local2][1];
tmp["level_" + _local2] = this[(((("rawSave_mode" + _local4) + "_rank") + (_local3 - 1)) + "_diff") + _local2][2];
tmp["blocksCleared_" + _local2] = this[(((("rawSave_mode" + _local4) + "_rank") + (_local3 - 1)) + "_diff") + _local2][3];
tmp["bestCombo_" + _local2] = this[(((("rawSave_mode" + _local4) + "_rank") + (_local3 - 1)) + "_diff") + _local2][4];
tmp["totalCombo_" + _local2] = this[(((("rawSave_mode" + _local4) + "_rank") + (_local3 - 1)) + "_diff") + _local2][5];
this[(((("rawSave_mode" + _local4) + "_rank") + (_local3 - 1)) + "_diff") + _local2] = null;
_local2++;
}
_local3++;
}
_local4++;
}
return(true);
}
stop();
btn_inGameMenu.btn.enabled = false;
var highScore_drop = new Object();
highScore_drop.rank1 = new Object();
highScore_drop.rank2 = new Object();
highScore_drop.rank3 = new Object();
highScore_drop.rank4 = new Object();
highScore_drop.rank5 = new Object();
var highScore_shift = new Object();
highScore_shift.rank1 = new Object();
highScore_shift.rank2 = new Object();
highScore_shift.rank3 = new Object();
highScore_shift.rank4 = new Object();
highScore_shift.rank5 = new Object();
var highScore_swap = new Object();
highScore_swap.rank1 = new Object();
highScore_swap.rank2 = new Object();
highScore_swap.rank3 = new Object();
highScore_swap.rank4 = new Object();
highScore_swap.rank5 = new Object();
var tmp;
var i2 = 0;
while (i2 < 3) {
var i = 5;
while (i > 0) {
if (i2 == 0) {
tmp = highScore_drop["rank" + i];
} else if (i2 == 1) {
tmp = highScore_swap["rank" + i];
} else {
tmp = highScore_shift["rank" + i];
}
var z = 0;
while (z < 2) {
tmp["name_" + z] = "CPU";
tmp["points_" + z] = (6 - i) * 200;
tmp["level_" + z] = 15 - i;
tmp["blocksCleared_" + z] = 0;
tmp["bestCombo_" + z] = 0;
tmp["totalCombo_" + z] = 0;
z++;
}
i--;
}
i2++;
}
Frame 3
var pushCnt = 0;
var pushDelay;
var pushGaps = 0;
var stunCnt = 0;
var xpBlockZ = 0;
var minBlockGoal = 3;
var gravity = 4;
var maxColors = 5;
var loser = false;
var transY = -1;
var transX = -1;
var transDelay = 4;
var transCnt = 0;
var hintMode = 0;
var points = 0;
var pts2SpcBlock = 125;
var spcAccPts = 0;
var maxSpc;
var curLevel = 1;
var blocksCleared = 0;
var blockGoalF;
var comboDelay;
var comboCnt = 0;
var comboNum = 0;
var stunN;
var maxStun;
var curMode = "drop";
var noGamePause = true;
var playingTime = 0;
var playingTimeCnt = 0;
var startGridLvl = 0;
var curDiff = 0;
var shift_box = new Object();
shift_box.gridX = null;
shift_box.gridY = null;
var levelSubtract;
var levelSubtractV2;
var levelSubtractV3;
var drag_circVis;
var drag_oldX;
var drag_oldY;
var shift_newLvl;
var shift_endGame;
var colorCnt = new Array(6);
var staticBlock = 34;
var slide_clearBlock;
var padLvl;
var shift_goal;
var action_wallLine;
var action_wallLvl;
var action_fallDelay;
var action_maxFallDelay;
var action_delAll;
var action_nEnm;
var lvlStart = 1;
var shift_lvlGoal;
var playPop_sfx = 0;
var playLand_sfx = 0;
var old_gaugeRot;
var new_gaugeRot;
var maxLvl;
Frame 4
function drop_reset() {
block_set.light.gridX = 0;
pGrid.reset();
block_set.light.gotoAndStop(pGrid.value[0]);
}
function shift_reset() {
shift_box.gridX = null;
shift_box.gridY = null;
shift_newLvl = false;
shift_endGame = false;
colorCnt[0] = (colorCnt[1] = (colorCnt[2] = (colorCnt[3] = (colorCnt[4] = (colorCnt[5] = 0)))));
}
function swap_reset() {
block_set.replace_circle.gridX = 0;
block_set.replace_circle.gridY = 0;
}
function resetState() {
staticText.panicState.gotoAndStop(1);
staticText.panicState2.gotoAndStop(1);
playingTime = 0;
playingTimeCnt = 0;
pushCnt = 0;
stunCnt = 0;
xpBlockZ = 0;
gravity = 4;
loser = false;
transY = -1;
transX = -1;
transDelay = 4;
transCnt = 0;
hintMode = 0;
points = 0;
points_txt = points;
spcAccPts = 0;
maxSpc = 24;
curLevel = 1;
level_txt = curLevel;
blocksCleared = 0;
blockGoalF = 3;
comboDelay = 20;
comboCnt = 0;
comboNum = 0;
stunN = 2;
maxStun = 12;
noGamePause = true;
spc_gauge.box._yscale = 0;
genCircle.hand._rotation = 0;
block_set.replace_circle._visible = false;
block_set.light._visible = false;
_root[curMode + "_reset"]();
grid.reset();
stat.reset();
color_set.gotoAndStop(1);
for (var _local2 in block_set.xplodeBlocks_set) {
tmp = block_set.xplodeBlocks_set[_local2];
tmp.removeMovieClip();
}
}
function setProp(a, b, c, d, e) {
pts2SpcBlock = a;
maxColors = b;
minBlockGoal = c;
pushGaps = d;
startGridLvl = e;
}
function setDiff(n) {
curDiff = n;
switch (curMode) {
case "drop" :
pushDelay = 288;
if (n == 0) {
setProp(150, 4, 3, 0, 3);
pushDelay = 324;
} else if (n == 1) {
setProp(150, 5, 3, 0, 4);
} else if (n == 2) {
setProp(180, 6, 3, 0, 5);
} else if (n == 3) {
setProp(220, 6, 3, 0, 7);
}
piece_set._visible = true;
spc_gauge._visible = true;
genCircle._visible = true;
levelSubtract = 18;
levelSubtractV2 = 5;
levelSubtractV3 = 2;
maxPushDelay = 36;
maxLvl = 15;
break;
case "shift" :
if (n == 0) {
setProp(100, 4, 5, 0, 6);
} else if (n == 1) {
setProp(100, 5, 5, 0, 8);
} else if (n == 2) {
setProp(100, 5, 6, 0, 10);
} else if (n == 3) {
setProp(100, 6, 6, 0, 12);
}
shift_lvlGoal = 10 * startGridLvl;
piece_set._visible = false;
spc_gauge._visible = false;
genCircle._visible = false;
levelSubtract = 0;
levelSubtractV2 = 0;
levelSubtractV3 = 0;
maxPushDelay = 18;
pushDelay = 18;
maxLvl = 500;
break;
case "swap" :
pushDelay = 144;
if (n == 0) {
setProp(180, 4, 3, 0, 4);
pushDelay = 180;
} else if (n == 1) {
setProp(200, 5, 3, 0, 6);
} else if (n == 2) {
setProp(250, 6, 3, 0, 6);
} else if (n == 3) {
setProp(300, 6, 3, 0, 8);
}
piece_set._visible = false;
spc_gauge._visible = true;
genCircle._visible = true;
levelSubtract = 6;
levelSubtractV2 = 2;
levelSubtractV3 = 1;
maxPushDelay = 18;
maxLvl = 15;
}
}
function newGame(m, d) {
curMode = m;
setDiff(d);
resetState();
grid.lvl(startGridLvl);
while (curLevel < lvlStart) {
curLevel++;
if (curLevel < 10) {
pushDelay = pushDelay - levelSubtract;
} else if (curLevel < 20) {
pushDelay = pushDelay - levelSubtractV2;
} else {
pushDelay = pushDelay - levelSubtractV3;
}
}
if (pushDelay < maxPushDelay) {
pushDelay = maxPushDelay;
}
blocksCleared_txt = "0 of " + ((curMode == "shift") ? (shift_lvlGoal) : ((curLevel * blockGoalF) + 15));
level_txt = curLevel;
_root.block_set.xplodeBlocks_set._visible = true;
_root.gotoAndStop("frame_empty");
if (_root.inGamePanel._currentframe != 2) {
_root.inGamePanel.gotoAndPlay(2);
} else {
var _local2 = _root.attachMovie("getreadyPopUp", "getreadyPopUp", 950);
_local2._x = 0;
_local2._y = 0;
}
stop();
}
function pauseGame() {
if (noGamePause) {
noGamePause = false;
var _local2 = _root.attachMovie("pauseMenu", "pauseMenu", 900);
_local2._x = 0;
_local2._y = 0;
} else {
noGamePause = true;
if (pauseMenu) {
pauseMenu.removeMovieClip();
}
}
}
function menuBtn_hit() {
_root.inGame_menuState.gotoAndStop(1);
if (_root.getreadyPopUp) {
_root.getreadyPopUp.stop();
} else if (_root.noGamePause && (!_root.statPopUp)) {
_root.pauseGame();
}
_root.enableGameInput(false);
var _local2 = _root.attachMovie("confirmPopUp", "confirmPopUp", 1100);
_local2._x = 0;
_local2._y = 0;
btn.enabled = false;
_root.block_set.xplodeBlocks_set._visible = false;
}
function convertSec(t) {
var _local4 = 3600;
var _local2 = 60;
var _local5;
var _local3;
var _local1;
_local5 = 0;
_local3 = ((t - (_local5 * _local4)) / _local2) << 0;
_local1 = t - ((_local5 * _local4) + (_local3 * _local2));
return(((_local3 + ":") + ((_local1 < 10) ? "0" : "")) + _local1);
}
Frame 5
function enableGameInput(b) {
if (b) {
Mouse.addListener(_root["mouseInput_" + curMode]);
Key.addListener(keyInput);
} else {
Mouse.removeListener(_root["mouseInput_" + curMode]);
Key.removeListener(keyInput);
}
}
keyInput = new Object();
keyInput.onKeyUp = function () {
if (Key.getCode() == 32) {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.pauseSnd.start();
}
pauseGame();
}
};
mouseInput_drop = new Object();
mouseInput_drop.onMouseDown = function () {
if (!noGamePause) {
return(undefined);
}
if ((block_set.light._visible && (grid.value[block_set.light.gridX][0] == 0)) && (!loser)) {
grid.addPiece(block_set.light.gridX, 0, pGrid.value[0]);
pGrid.makePiece();
if (_root.sfxEnabled) {
_root.sfx.slide.start();
}
}
};
mouseInput_shift = new Object();
mouseInput_shift.onMouseDown = function () {
var _local2 = Math.round((block_set._xmouse - 16) / gridSlice);
var _local1 = Math.round((block_set._ymouse - 16) / gridSlice);
if ((((((!noGamePause) || (loser)) || (_local2 < 0)) || (_local2 > 9)) || (_local1 < 0)) || (_local1 > 11)) {
shift_box.gridX = null;
shift_box.gridY = null;
} else {
shift_box.gridX = _local2;
shift_box.gridY = _local1;
}
};
mouseInput_shift.onMouseUp = function () {
shift_box.gridX = null;
shift_box.gridY = null;
};
mouseInput_swap = new Object();
mouseInput_swap.onMouseDown = function () {
if ((!noGamePause) || (loser)) {
return(undefined);
}
var _local3 = Math.round((block_set._xmouse - 16) / gridSlice);
var _local2 = Math.round((block_set._ymouse - 16) / gridSlice);
var _local4 = grid.value[_local3][_local2];
var _local5 = block_set.replace_circle._currentframe;
if ((_local4 > 0) && (_local4 < 7)) {
if (block_set.replace_circle._visible) {
if (_root.sfxEnabled) {
_root.sfx.slide.start();
}
block_set.replace_circle._visible = false;
grid.value[block_set.replace_circle.gridX][block_set.replace_circle.gridY] = grid.value[_local3][_local2];
grid.addPiece(_local3, _local2, _local5);
} else {
if (_root.sfxEnabled) {
_root.sfx.block_land.start();
}
block_set.replace_circle.gotoAndStop(_local4);
block_set.replace_circle._visible = true;
block_set.replace_circle._x = grid.block_set[_local3][_local2]._x;
block_set.replace_circle._y = grid.block_set[_local3][_local2]._y;
block_set.replace_circle.gridX = _local3;
block_set.replace_circle.gridY = _local2;
}
}
};
Frame 6
function addClearedBlocks(n) {
stat.clearedblocks = stat.clearedblocks + n;
spc_gauge.box._yscale = Math.round((spcAccPts / pts2SpcBlock) * 100);
stunCnt = stunCnt + (stunN * n);
stunCnt = ((stunCnt > maxStun) ? (maxStun) : (stunCnt));
if (loser) {
return(undefined);
}
blocksCleared = blocksCleared + n;
var _local1 = ((curMode == "shift") ? (shift_lvlGoal) : ((curLevel * blockGoalF) + 15));
if (blocksCleared >= _local1) {
if (curMode == "shift") {
blocksCleared = 0;
shift_newLvl = true;
} else {
blocksCleared = blocksCleared - _local1;
_local1 = ((curLevel + 1) * blockGoalF) + 15;
}
nextLevel();
}
blocksCleared_txt = (blocksCleared + " of ") + _local1;
}
function nextLevel() {
if (_root.sfxEnabled) {
_root.sfx.level_up.start();
}
curLevel++;
if (curLevel >= (maxLvl + 1)) {
endGame();
return(undefined);
}
level_txt = curLevel;
if (pushDelay > maxPushDelay) {
if (curLevel < 10) {
pushDelay = pushDelay - levelSubtract;
} else if (curLevel < 20) {
pushDelay = pushDelay - levelSubtractV2;
} else {
pushDelay = pushDelay - levelSubtractV3;
}
} else if (pushDelay < maxPushDelay) {
pushDelay = maxPushDelay;
}
}
function getSpc() {
var _local1 = random(10);
var _local2;
if ((_local1 > 0) && (_local1 < 4)) {
_local2 = random(maxColors);
return((10 + ((_local1 - 1) * 6)) + _local2);
}
if (_local1 == 0) {
return(9);
}
return(24 + _local1);
}
function addLooseBlock(x, y) {
var _local1;
var _local2;
_local2 = grid.value[x][y];
if ((_local2 < 1) || (_local2 > 6)) {
return(undefined);
}
_local1 = block_set.xplodeBlocks_set.attachMovie("block_" + _local2, "b" + xpBlockZ, xpBlockZ);
xpBlockZ = (xpBlockZ + 1) % 240;
_local1._x = grid.block_set[x][y]._x;
_local1._y = grid.block_set[x][y]._y;
_local1.xSpd = ((Math.random() < 0.5) ? (random(5) + 1) : (-(random(5) + 1)));
_local1.ySpd = -((random(8) + gravity) + 2);
if (!loser) {
addClearedBlocks(1);
}
}
function addPoints(nBlocks) {
if (nBlocks < 0) {
points = points + nBlocks;
} else {
var _local2 = nBlocks * Math.ceil(nBlocks / minBlockGoal);
points = points + _local2;
spcAccPts = spcAccPts + nBlocks;
}
points_txt = points;
}
function endGame() {
enableGameInput(false);
loser = true;
if (Math.random() < 0.5) {
transY = grid.height - 1;
} else {
transX = grid.width - 1;
}
transCnt = 0;
}
function removeVLine(x) {
playLand_sfx = 1;
playPop_sfx = 7;
grid.changed = true;
var _local1 = 0;
while (_local1 < grid.height) {
addLooseBlock(x, _local1);
grid.value[x][_local1] = 0;
_local1++;
}
}
function removeHLine(y) {
playLand_sfx = 1;
playPop_sfx = 7;
grid.changed = true;
var _local1 = 0;
while (_local1 < grid.width) {
addLooseBlock(_local1, y);
grid.value[_local1][y] = 0;
_local1++;
}
}
function sVFunc33(x, y) {
if (y == (grid.height - 1)) {
grid.value[x][y] = 0;
playLand_sfx = 1;
return(undefined);
}
if (grid.value[x][y + 1]) {
addPoints(1);
addLooseBlock(x, grid.height - 1);
grid.value[x][y] = 0;
grid.value[x][grid.height - 1] = 0;
playLand_sfx = 1;
playPop_sfx = 1;
return(true);
}
}
function sVFunc32(x, y) {
if (y == (grid.height - 1)) {
grid.value[x][y] = 0;
playLand_sfx = 1;
return(undefined);
}
if (grid.value[x][y + 1]) {
var _local3 = grid.value[0][y + 1];
grid.value[x][y] = 0;
var _local1 = 0;
while (_local1 < (grid.width - 1)) {
grid.value[_local1][y + 1] = grid.value[_local1 + 1][y + 1];
_local1++;
}
grid.value[grid.width - 1][y + 1] = _local3;
playLand_sfx = 1;
return(true);
}
}
function sVFunc31(x, y) {
if (y == (grid.height - 1)) {
grid.value[x][y] = 0;
playLand_sfx = 1;
return(undefined);
}
if (grid.value[x][y + 1]) {
var _local3 = grid.value[grid.width - 1][y + 1];
grid.value[x][y] = 0;
var _local1 = grid.width - 1;
while (_local1 > 0) {
grid.value[_local1][y + 1] = grid.value[_local1 - 1][y + 1];
_local1--;
}
grid.value[0][y + 1] = _local3;
playLand_sfx = 1;
return(true);
}
}
function sVFunc30(x, y) {
if ((y == (grid.height - 1)) || (grid.value[x][y + 1] > 6)) {
grid.value[x][y] = 0;
playLand_sfx = 1;
return(undefined);
}
if (grid.value[x][y + 1] > 0) {
var _local3 = grid.value[x][y + 1];
grid.value[x][y] = 0;
var _local2 = 0;
while (_local2 < grid.width) {
var _local1 = 0;
while (_local1 < grid.height) {
if (grid.value[_local2][_local1] == _local3) {
addPoints(1);
addLooseBlock(_local2, _local1);
grid.value[_local2][_local1] = 8;
}
_local1++;
}
_local2++;
}
playLand_sfx = 1;
playPop_sfx = 1;
return(true);
}
}
function sVFunc29(x, y) {
}
function sVFunc28(x, y) {
if (y == (grid.height - 1)) {
grid.value[x][y] = 0;
playLand_sfx = 1;
return(undefined);
}
if (grid.value[x][y + 1]) {
grid.value[x][y] = 0;
var _local1 = 0;
while (_local1 < grid.width) {
if (grid.value[_local1][y + 1]) {
addPoints(1);
addLooseBlock(_local1, y + 1);
grid.value[_local1][y + 1] = 8;
}
_local1++;
}
playLand_sfx = 1;
playPop_sfx = 1;
return(true);
}
}
function sVFunc22(x, y) {
if (y == (grid.height - 1)) {
grid.value[x][y] = 0;
playLand_sfx = 1;
return(undefined);
}
var _local5 = grid.value[x][y];
var _local4 = _local5 - 21;
if (grid.value[x][y + 1]) {
var _local1 = y + 1;
while (_local1 < grid.height) {
grid.value[x][_local1] = _local4;
_local1++;
}
grid.value[x][y] = 0;
playLand_sfx = 1;
return(true);
}
}
function sVFunc16(x, y) {
var _local5 = grid.value[x][y];
var _local4 = _local5 - 15;
var _local3 = false;
if ((x > 0) && (grid.value[x - 1][y])) {
grid.value[x - 1][y] = _local4;
_local3 = true;
}
if ((x < grid.width) && (grid.value[x + 1][y])) {
grid.value[x + 1][y] = _local4;
_local3 = true;
}
if ((y < (grid.height - 1)) && (grid.value[x][y + 1])) {
grid.value[x][y + 1] = _local4;
_local3 = true;
}
if (grid.value[x][y + 1] == 0) {
grid.value[x][y + 1] = _local5;
}
if ((y == (grid.height - 1)) || (grid.value[x][y + 1])) {
grid.value[x][y] = 0;
}
if (_local3) {
playLand_sfx = 1;
}
return(_local3);
}
function sVFunc10(x, y) {
var _local3 = grid.value[x][y];
var _local4 = _local3 - 9;
if ((y == (grid.height - 1)) || (grid.value[x][y + 1] == _local4)) {
grid.value[x][y] = _local4;
playLand_sfx = 1;
return(undefined);
}
if ((grid.value[x][y + 1] != _local3) && (grid.value[x][y + 1])) {
grid.value[x][y] = grid.value[x][y + 1];
grid.value[x][y + 1] = _local3;
playLand_sfx = 1;
}
}
function sVFunc9(x, y) {
if (y == (grid.height - 1)) {
grid.value[x][y] = 0;
playLand_sfx = 1;
return(undefined);
}
var _local3 = grid.value[x][y + 1];
if (((_local3 > 0) && (_local3 < 7)) || (_local3 == wildcard)) {
if (y > 1) {
grid.value[x][y - 2] = 9;
grid.value[x][y] = 0;
}
playLand_sfx = 1;
playPop_sfx = 1;
addPoints(1);
addLooseBlock(x, y + 1);
grid.value[x][y + 1] = 0;
return(true);
}
}
block_set.combo_set.gotoAndPlay(block_set.combo_set._totalframes);
var stat = new Object();
stat.reset = function () {
stat.bestCombo = 0;
stat.totalCombos = 0;
stat.clearedblocks = 0;
stat.points = 0;
stat.level = 0;
stat.rank = 0;
};
stat.reset();
var wildcard = 29;
var sVFunc23 = sVFunc22;
var sVFunc24 = sVFunc22;
var sVFunc25 = sVFunc22;
var sVFunc26 = sVFunc22;
var sVFunc27 = sVFunc22;
var sVFunc17 = sVFunc16;
var sVFunc18 = sVFunc16;
var sVFunc19 = sVFunc16;
var sVFunc20 = sVFunc16;
var sVFunc21 = sVFunc16;
var sVFunc11 = sVFunc10;
var sVFunc12 = sVFunc10;
var sVFunc13 = sVFunc10;
var sVFunc14 = sVFunc10;
var sVFunc15 = sVFunc10;
Frame 7
function removeBlocks() {
comboCnt = comboDelay;
comboNum++;
var _local4 = grid.delBuffer.length;
var _local3 = 0;
if (comboNum > 1) {
playPop_sfx = ((comboNum > 7) ? 7 : (comboNum));
if (comboNum > stat.bestCombo) {
stat.bestCombo = comboNum;
}
stat.totalCombos = stat.totalCombos + comboNum;
spcAccPts = spcAccPts + ((comboNum - 1) * 3);
block_set.combo_set._y = grid.delBuffer[0]._y;
block_set.combo_set._x = grid.delBuffer[0]._x;
block_set.combo_set.gotoAndPlay(1);
block_set.combo_set.txt = comboNum + "x";
} else {
playPop_sfx = 1;
}
grid.changed = true;
stunCnt = stunCnt + (stunN * grid.delBuffer.length);
stunCnt = ((stunCnt > maxStun) ? (maxStun) : (stunCnt));
var _local2 = 0;
while (_local2 < grid.delBuffer.length) {
tmpX = grid.delBuffer[_local2].gridX;
tmpY = grid.delBuffer[_local2].gridY;
t = grid.block_set[tmpX][tmpY]._currentframe;
if (t == 8) {
} else {
if ((_root.curMode != "action") || ((t != wildcard) && (tmpY < (action_wallLine - 1)))) {
_local3++;
} else if (tmpY >= action_wallLine) {
_local4 = 0;
}
newBlock = block_set.xplodeBlocks_set.attachMovie("block_" + t, "b" + xpBlockZ, xpBlockZ);
xpBlockZ = (xpBlockZ + 1) % 240;
newBlock._x = grid.block_set[tmpX][tmpY]._x;
newBlock._y = grid.block_set[tmpX][tmpY]._y;
newBlock.xSpd = ((Math.random() < 0.5) ? (random(5) + 1) : (-(random(5) + 1)));
newBlock.ySpd = -((random(8) + gravity) + 2);
grid.block_set[tmpX][tmpY].gotoAndStop(8);
}
_local2++;
}
addClearedBlocks(_local3);
addPoints(_local4);
}
var pGrid = new Object();
pGrid.height = 4;
pGrid.value = new Array(grid.height);
pGrid.piece_set = new Array(grid.height);
pGrid.reset = function () {
var _local1 = 0;
while (_local1 < pGrid.height) {
pGrid.value[_local1] = 1 + random(maxColors);
pGrid.piece_set[_local1] = piece_set["y" + _local1];
pGrid.piece_set[_local1].hint.gotoAndStop(2);
_local1++;
}
pGrid.updateDisplay();
};
pGrid.updateDisplay = function () {
var _local2;
var _local1 = 0;
while (_local1 < pGrid.height) {
_local2 = ((pGrid.value[_local1] == 0) ? 7 : (pGrid.value[_local1]));
pGrid.piece_set[_local1].gotoAndStop(_local2);
_local1++;
}
};
pGrid.makePiece = function () {
var _local1 = 0;
while (_local1 < (pGrid.height - 1)) {
pGrid.value[_local1] = pGrid.value[_local1 + 1];
_local1++;
}
pGrid.value[pGrid.height - 1] = 1 + random(maxColors);
block_set.light.gotoAndStop(pGrid.value[0]);
pGrid.updateDisplay();
};
pGrid.reset();
var grid = new Object();
grid.width = 10;
grid.height = 12;
grid.value = new Array(grid.width);
grid.block_set = new Array(grid.width);
grid.changed = true;
grid.delBuffer = new Array();
var hg = new Array(12);
var hNg = new Array(12);
var v;
var vN;
var gridSlice = 36;
var i = 0;
while (i < grid.width) {
grid.value[i] = new Array(grid.height);
grid.block_set[i] = new Array(grid.height);
i++;
}
grid.reset = function () {
grid.changed = true;
xpBlockZ = 0;
var _local2 = 0;
while (_local2 < grid.width) {
var _local1 = 0;
while (_local1 < grid.height) {
grid.value[_local2][_local1] = 0;
grid.block_set[_local2][_local1] = block_set[(("x" + _local2) + "y") + _local1];
grid.block_set[_local2][_local1].gridX = _local2;
grid.block_set[_local2][_local1].gridY = _local1;
_local1++;
}
_local2++;
}
for (var _local3 in block_set.xplodeBlocks_set) {
block_set.xplodeBlocks_set[_local3].removeMovieClip();
}
grid.updateDisplay();
};
grid.pushUp = function (noRepeat) {
var _local4;
var _local3;
grid.changed = true;
var _local1 = 0;
while (_local1 < grid.width) {
if (grid.value[_local1][0]) {
endGame();
return(undefined);
}
_local4 = 0;
do {
_local4++;
_local3 = ((random(100) < pushGaps) ? 0 : (1 + random(maxColors)));
} while ((noRepeat == true) && (((_local3 == grid.value[_local1 - 1][grid.height - 1]) || (_local3 == grid.value[_local1][grid.height - 2])) && (_local4 < 6)));
var _local2 = 0;
while (_local2 < (grid.height - 1)) {
if (_local3 != 0) {
grid.value[_local1][_local2] = grid.value[_local1][_local2 + 1];
}
_local2++;
}
if (_local3 != 0) {
grid.value[_local1][grid.height - 1] = _local3;
}
_local1++;
}
};
grid.updateDisplay = function () {
var _local2 = 0;
while (_local2 < grid.width) {
var _local1 = 0;
while (_local1 < grid.height) {
var _local3 = ((grid.value[_local2][_local1] == 0) ? 7 : (grid.value[_local2][_local1]));
if (grid.block_set[_local2][_local1]._currentframe != _local3) {
grid.block_set[_local2][_local1].gotoAndStop(_local3);
}
_local1++;
}
_local2++;
}
};
var curBlock;
var brBlock;
var isWild;
var t;
var blockMoved;
var oldLightX;
var newLightX;
var numTopSpc;
grid.check = function () {
oldLightX = null;
blockMoved = false;
numTopSpc = 0;
grid.delBuffer.length = 0;
hg[0] = (hg[1] = (hg[2] = (hg[3] = (hg[4] = (hg[5] = (hg[6] = (hg[7] = (hg[8] = (hg[9] = (hg[10] = (hg[11] = 0)))))))))));
hNg[0] = (hNg[1] = (hNg[2] = (hNg[3] = (hNg[4] = (hNg[5] = (hNg[6] = (hNg[7] = (hNg[8] = (hNg[9] = (hNg[10] = (hNg[11] = 1)))))))))));
var _local3 = 0;
while (_local3 < grid.width) {
v = 0;
vN = 1;
var _local2 = grid.height - 1;
for ( ; _local2 >= 0 ; _local2--) {
curBlock = grid.value[_local3][_local2];
isWild = curBlock == wildcard;
brBlock = (curBlock && (curBlock < 7)) || (isWild);
if (grid.changed) {
t = ((curBlock == 0) ? 7 : (curBlock));
if (grid.block_set[_local3][_local2]._currentframe != t) {
grid.block_set[_local3][_local2].gotoAndStop(t);
}
if (loser) {
continue;
}
if ((v && (((curBlock == v) || (isWild)) || (wildcard == v))) && (brBlock)) {
vN++;
} else {
vN = 1;
}
if ((curBlock != grid.value[_local3][_local2 - 1]) && (vN >= minBlockGoal)) {
var _local4 = (_local2 + vN) - 1;
while (_local4 >= _local2) {
grid.delBuffer.push(grid.block_set[_local3][_local4]);
grid.value[_local3][_local4] = 8;
_local4--;
}
}
v = curBlock;
if ((_local2 == (grid.height - 1)) || (grid.value[_local3][_local2 + 1])) {
if ((hg[_local2] && (((curBlock == hg[_local2]) || (isWild)) || (wildcard == hg[_local2]))) && (brBlock)) {
hNg[_local2]++;
} else {
hNg[_local2] = 1;
}
if ((curBlock != grid.value[_local3 + 1][_local2]) && (hNg[_local2] >= minBlockGoal)) {
var _local4 = (_local3 - hNg[_local2]) + 1;
while (_local4 <= _local3) {
grid.delBuffer.push(grid.block_set[_local4][_local2]);
grid.value[_local4][_local2] = 8;
_local4++;
}
}
hg[_local2] = curBlock;
} else {
hg[_local2] = null;
}
}
if (loser) {
} else {
if ((curBlock > 8) && (grid.value[_local3][_local2 + 1] != 8)) {
if (_root["sVFunc" + curBlock](_local3, _local2) == true) {
grid.changed = true;
blockMoved = true;
v = (hg[0] = (hg[1] = (hg[2] = (hg[3] = (hg[4] = (hg[5] = (hg[6] = (hg[7] = (hg[8] = (hg[9] = (hg[10] = (hg[11] = 0))))))))))));
vN = (hNg[0] = (hNg[1] = (hNg[2] = (hNg[3] = (hNg[4] = (hNg[5] = (hNg[6] = (hNg[7] = (hNg[8] = (hNg[9] = (hNg[10] = (hNg[11] = 1))))))))))));
continue;
}
curBlock = grid.value[_local3][_local2];
blockMoved = true;
}
if (curBlock && (grid.value[_local3][_local2 + 1] == 0)) {
grid.value[_local3][_local2 + 1] = curBlock;
grid.value[_local3][_local2] = 0;
if (brBlock && ((_local2 == (grid.height - 2)) || (grid.value[_local3][_local2 + 2] > 0))) {
playLand_sfx = -1;
}
blockMoved = true;
}
}
}
numTopSpc = numTopSpc + ((grid.value[_local3][0] && (grid.value[_local3][0] != 8)) ? 0 : 1);
if (((((numTopSpc == 0) && (_local3 == (grid.width - 1))) && (!blockMoved)) && (!grid.changed)) && (!loser)) {
endGame();
return(undefined);
}
_local3++;
}
oldLightX = block_set.light.gridX;
newLightX = (block_set.light.gridX = Math.round((block_set._xmouse - 16) / gridSlice));
if ((newLightX > -1) && (newLightX < 10)) {
if (!block_set.light._visible) {
block_set.light._visible = true;
}
if (oldLightX != newLightX) {
block_set.light._x = grid.block_set[newLightX][0]._x;
}
} else if (block_set.light._visible) {
block_set.light._visible = false;
}
grid.changed = blockMoved;
if (spcAccPts >= pts2SpcBlock) {
if (_root.sfxEnabled) {
_root.sfx.special.start();
}
spcAccPts = 0;
var _local5 = 0;
while (_local5 < pGrid.height) {
pGrid.value[_local5] = getSpc();
_local5++;
}
pGrid.updateDisplay();
block_set.light.gotoAndStop(pGrid.value[0]);
spc_gauge.box._yscale = 0;
}
if (grid.delBuffer.length) {
playLand_sfx = 0;
removeBlocks();
}
};
var newBlock;
var tmpX;
var tmpY;
grid.addPiece = function (x, y, t) {
grid.changed = true;
grid.value[x][y] = t;
};
grid.lvl = function (n) {
while (n > 0) {
n--;
grid.pushUp(true);
}
};
grid.pad = function (b, n) {
var _local1 = grid.width - n;
while (_local1 < grid.width) {
var _local2 = 0;
while (_local2 < grid.height) {
grid.value[_local1][_local2] = b;
_local2++;
}
_local1++;
}
_local1 = grid.width - 1;
while (_local1 > -1) {
var _local2 = grid.height - n;
while (_local2 < grid.height) {
grid.value[_local1][_local2] = b;
_local2++;
}
_local1--;
}
grid.changed = true;
};
Frame 9
function sMode_L(x, y) {
if (_root.sfxEnabled) {
_root.sfx.slide.start();
}
var _local4 = grid.value[0][y];
var _local2 = 0;
while (_local2 < (grid.width - 1)) {
grid.value[_local2][y] = grid.value[_local2 + 1][y];
_local2++;
}
grid.value[grid.width - 1][y] = _local4;
}
function sMode_R(x, y) {
if (_root.sfxEnabled) {
_root.sfx.slide.start();
}
var _local4 = grid.value[grid.width - 1][y];
var _local2 = grid.width - 1;
while (_local2 > 0) {
grid.value[_local2][y] = grid.value[_local2 - 1][y];
_local2--;
}
grid.value[0][y] = _local4;
}
function sMode_U(x, y) {
if (_root.sfxEnabled) {
_root.sfx.slide.start();
}
var _local4 = grid.value[x][0];
var _local2 = 0;
while (_local2 < (grid.height - 1)) {
grid.value[x][_local2] = grid.value[x][_local2 + 1];
_local2++;
}
grid.value[x][grid.height - 1] = _local4;
}
function sMode_D(x, y) {
if (_root.sfxEnabled) {
_root.sfx.slide.start();
}
var _local4 = grid.value[x][grid.height - 1];
var _local2 = grid.height - 1;
while (_local2 > 0) {
grid.value[x][_local2] = grid.value[x][_local2 - 1];
_local2--;
}
grid.value[x][0] = _local4;
}
var curBlock;
var brBlock;
var isWild;
var t;
var blockMoved;
var newSBoxX;
var newSBoxY;
var numTopSpc;
grid.check_shift = function () {
blockMoved = false;
numTopSpc = 0;
grid.delBuffer.length = 0;
hg[0] = (hg[1] = (hg[2] = (hg[3] = (hg[4] = (hg[5] = (hg[6] = (hg[7] = (hg[8] = (hg[9] = (hg[10] = (hg[11] = 0)))))))))));
hNg[0] = (hNg[1] = (hNg[2] = (hNg[3] = (hNg[4] = (hNg[5] = (hNg[6] = (hNg[7] = (hNg[8] = (hNg[9] = (hNg[10] = (hNg[11] = 1)))))))))));
if (shift_box.gridX != null) {
newSBoxX = Math.round((block_set._xmouse - 16) / gridSlice);
newSBoxY = Math.round((block_set._ymouse - 16) / gridSlice);
if ((((shift_box.gridX > -1) && (shift_box.gridX < 10)) && (shift_box.gridY > -1)) && (shift_box.gridY < 12)) {
xm_Offset = Math.abs(newSBoxX - shift_box.gridX);
ym_Offset = Math.abs(newSBoxY - shift_box.gridY);
if (xm_Offset && (!loser)) {
if (newSBoxX > shift_box.gridX) {
var _local5 = 0;
while (_local5 < xm_Offset) {
sMode_R(shift_box.gridX, shift_box.gridY);
_local5++;
}
} else {
var _local5 = 0;
while (_local5 < xm_Offset) {
sMode_L(shift_box.gridX, shift_box.gridY);
_local5++;
}
}
shift_box.gridX = newSBoxX;
shift_box.gridY = newSBoxY;
blockMoved = true;
} else if (ym_Offset && (!loser)) {
if (newSBoxY > shift_box.gridY) {
var _local5 = 0;
while (_local5 < ym_Offset) {
sMode_D(shift_box.gridX, shift_box.gridY);
_local5++;
}
} else {
var _local5 = 0;
while (_local5 < ym_Offset) {
sMode_U(shift_box.gridX, shift_box.gridY);
_local5++;
}
}
shift_box.gridX = newSBoxX;
shift_box.gridY = newSBoxY;
grid.changed = (blockMoved = true);
}
}
}
if (grid.changed) {
colorCnt[0] = (colorCnt[1] = (colorCnt[2] = (colorCnt[3] = (colorCnt[4] = (colorCnt[5] = 0)))));
}
var _local2 = 0;
while (_local2 < grid.width) {
v = 0;
vN = 1;
var _local1 = grid.height - 1;
for ( ; _local1 >= 0 ; _local1--) {
curBlock = grid.value[_local2][_local1];
brBlock = (curBlock && (curBlock < 7)) || (isWild);
if (grid.changed) {
if (brBlock) {
colorCnt[curBlock - 1]++;
}
t = ((curBlock == 0) ? 7 : (curBlock));
if (grid.block_set[_local2][_local1]._currentframe != t) {
grid.block_set[_local2][_local1].gotoAndStop(t);
}
if (loser) {
continue;
}
if ((v && (curBlock == v)) && (brBlock)) {
vN++;
} else {
vN = 1;
}
if ((curBlock != grid.value[_local2][_local1 - 1]) && (vN >= minBlockGoal)) {
var _local3 = (_local1 + vN) - 1;
while (_local3 >= _local1) {
grid.delBuffer.push(grid.block_set[_local2][_local3]);
grid.value[_local2][_local3] = 8;
_local3--;
}
}
v = curBlock;
if ((hg[_local1] && (curBlock == hg[_local1])) && (brBlock)) {
hNg[_local1]++;
} else {
hNg[_local1] = 1;
}
if ((curBlock != grid.value[_local2 + 1][_local1]) && (hNg[_local1] >= minBlockGoal)) {
var _local3 = (_local2 - hNg[_local1]) + 1;
while (_local3 <= _local2) {
grid.delBuffer.push(grid.block_set[_local3][_local1]);
grid.value[_local3][_local1] = 8;
_local3++;
}
}
hg[_local1] = curBlock;
}
if (loser) {
}
}
_local2++;
}
var _local4 = 0;
while (_local4 < maxColors) {
if ((colorCnt[_local4] < minBlockGoal) && (colorCnt[_local4] != 0)) {
shift_endGame = true;
}
_local4++;
}
grid.changed = blockMoved;
if (grid.delBuffer.length) {
removeBlocks();
}
};
Frame 10
block_set.replace_circle.gridX = 0;
block_set.replace_circle.gridY = 0;
block_set.replace_circle.gotoAndStop(0);
var curBlock;
var brBlock;
var isWild;
var t;
var blockMoved;
var oldRCircX;
var oldRCircY;
var newRCircX;
var newRCircY;
var numTopSpc;
grid.check_swap = function () {
oldRCircX = null;
oldRCircY = null;
blockMoved = false;
numTopSpc = 0;
grid.delBuffer.length = 0;
hg[0] = (hg[1] = (hg[2] = (hg[3] = (hg[4] = (hg[5] = (hg[6] = (hg[7] = (hg[8] = (hg[9] = (hg[10] = (hg[11] = 0)))))))))));
hNg[0] = (hNg[1] = (hNg[2] = (hNg[3] = (hNg[4] = (hNg[5] = (hNg[6] = (hNg[7] = (hNg[8] = (hNg[9] = (hNg[10] = (hNg[11] = 1)))))))))));
var _local3 = 0;
while (_local3 < grid.width) {
v = 0;
vN = 1;
var _local2 = grid.height - 1;
for ( ; _local2 >= 0 ; _local2--) {
curBlock = grid.value[_local3][_local2];
isWild = curBlock == wildcard;
brBlock = (curBlock && (curBlock < 7)) || (isWild);
if (grid.changed) {
t = ((curBlock == 0) ? 7 : (curBlock));
if (grid.block_set[_local3][_local2]._currentframe != t) {
grid.block_set[_local3][_local2].gotoAndStop(t);
}
if (loser) {
continue;
}
if ((v && (((curBlock == v) || (isWild)) || (wildcard == v))) && (brBlock)) {
vN++;
} else {
vN = 1;
}
if ((curBlock != grid.value[_local3][_local2 - 1]) && (vN >= minBlockGoal)) {
var _local4 = (_local2 + vN) - 1;
while (_local4 >= _local2) {
grid.delBuffer.push(grid.block_set[_local3][_local4]);
grid.value[_local3][_local4] = 8;
_local4--;
}
}
v = curBlock;
if ((_local2 == (grid.height - 1)) || (grid.value[_local3][_local2 + 1])) {
if ((hg[_local2] && (((curBlock == hg[_local2]) || (isWild)) || (wildcard == hg[_local2]))) && (brBlock)) {
hNg[_local2]++;
} else {
hNg[_local2] = 1;
}
if ((curBlock != grid.value[_local3 + 1][_local2]) && (hNg[_local2] >= minBlockGoal)) {
var _local4 = (_local3 - hNg[_local2]) + 1;
while (_local4 <= _local3) {
grid.delBuffer.push(grid.block_set[_local4][_local2]);
grid.value[_local4][_local2] = 8;
_local4++;
}
}
hg[_local2] = curBlock;
} else {
hg[_local2] = null;
}
}
if (loser) {
} else if (curBlock && (grid.value[_local3][_local2 + 1] == 0)) {
grid.value[_local3][_local2 + 1] = curBlock;
grid.value[_local3][_local2] = 0;
if (brBlock && ((_local2 == (grid.height - 2)) || (grid.value[_local3][_local2 + 2] > 0))) {
playLand_sfx = -1;
}
blockMoved = true;
}
}
numTopSpc = numTopSpc + ((grid.value[_local3][0] && (grid.value[_local3][0] != 8)) ? 0 : 1);
if (((((numTopSpc == 0) && (_local3 == (grid.width - 1))) && (!blockMoved)) && (!grid.changed)) && (!loser)) {
endGame();
return(undefined);
}
_local3++;
}
if (block_set.replace_circle._visible) {
block_set.replace_circle._y = grid.block_set[0][block_set.replace_circle.gridY]._y;
}
grid.changed = blockMoved;
if (spcAccPts >= pts2SpcBlock) {
if (_root.sfxEnabled) {
_root.sfx.special.start();
}
spcAccPts = 0;
var _local5 = 0;
while (_local5 < grid.width) {
grid.delBuffer.push(grid.block_set[_local5][grid.height - 1]);
grid.value[_local5][grid.height - 1] = 8;
grid.delBuffer.push(grid.block_set[_local5][grid.height - 2]);
grid.value[_local5][grid.height - 2] = 8;
_local5++;
}
spc_gauge.box._yscale = 0;
}
if (grid.delBuffer.length) {
playLand_sfx = 0;
removeBlocks();
}
};
Frame 13
sfx.enable(_root.sfxEnabled);
sfx.setVol(_root.sfxVol);
music.setVol(_root.musicVol);
Frame 14
if (_root.pauseMenu) {
_root.pauseMenu.removeMovieClip();
}
if (_root.statPopUp) {
_root.statPopUp.removeMovieClip();
}
if (_root.confirmPopUp) {
_root.confirmPopUp.removeMovieClip();
}
if (_root.getreadyPopUp) {
_root.getreadyPopUp.removeMovieClip();
}
enableGameInput(false);
btn_inGameMenu.btn.enabled = false;
staticText.btn_Panic.btn.enabled = false;
staticText.btn_Panic2.btn.enabled = false;
stop();
Frame 15
if (noGamePause) {
grid.check();
if (!loser) {
if (playingTimeCnt == 18) {
playingTimeCnt = 0;
playingTime++;
} else {
playingTimeCnt++;
}
if (stunCnt == 0) {
pushCnt++;
if (pushCnt >= pushDelay) {
pushCnt = 0;
stunCnt = 9;
if (_root.sfxEnabled) {
_root.sfx.block_land.start();
}
grid.pushUp();
}
} else if (stunCnt > 0) {
stunCnt--;
}
if (comboCnt > 0) {
comboCnt--;
} else {
comboNum = 0;
}
if ((pushCnt % (pushDelay / 18)) < 1) {
old_gaugeRot = genCircle.hand._rotation;
}
genCircle.hand._rotation = Math.round(360 * (pushCnt / pushDelay));
if ((pushCnt % (pushDelay / 18)) < 1) {
if ((((old_gaugeRot != new_gaugeRot) && (new_gaugeRot < -20)) && (new_gaugeRot > -100)) && (_root.sfxEnabled)) {
_root.sfx.tick_warning.start();
}
new_gaugeRot = genCircle.hand._rotation;
}
} else if (transCnt == 0) {
transCnt = transDelay;
if (transY > -1) {
removeHLine(transY);
transY--;
} else if (transX > -1) {
removeVLine(transX);
transX--;
}
} else if (transCnt > 0) {
transCnt--;
}
nXPBlocks = 0;
for (var obj in block_set.xplodeBlocks_set) {
nXPBlocks++;
var tmp = block_set.xplodeBlocks_set[obj];
tmp._x = tmp._x + tmp.xSpd;
tmp._y = tmp._y + tmp.ySpd;
tmp.ySpd = tmp.ySpd + gravity;
if (tmp._y > 480) {
tmp.removeMovieClip();
}
}
}
if ((loser && ((transX == -1) && (transY == -1))) && (nXPBlocks == 0)) {
tmp = _root.attachMovie("statPopUp", "statPopUp", 1000);
tmp._x = 0;
tmp._y = 0;
stop();
}
if (_root.sfxEnabled) {
if (playPop_sfx) {
switch (playPop_sfx) {
case 1 :
_root.sfx.block_pop.start();
break;
case 2 :
_root.sfx.block_popH1.start();
break;
case 3 :
_root.sfx.block_popH2.start();
break;
case 4 :
_root.sfx.block_popH3.start();
break;
case 5 :
_root.sfx.block_popH4.start();
break;
case 6 :
if (spc_gauge.box._yscale < 100) {
spcAccPts = pts2SpcBlock;
} else {
_root.sfx.block_popH4.start();
}
break;
case 7 :
_root.sfx.block_popH4.start();
}
playPop_sfx = 0;
}
if (playLand_sfx > 0) {
playLand_sfx = 0;
_root.sfx.block_land.start();
} else if (playLand_sfx == -1) {
playLand_sfx = 1;
}
}
Frame 16
gotoAndPlay(_currentframe - 1);
Frame 18
gotoAndPlay(_currentframe - 1);
Frame 19
if (noGamePause) {
grid.check_shift();
if (!loser) {
if (playingTimeCnt == 18) {
playingTimeCnt = 0;
playingTime++;
} else {
playingTimeCnt++;
}
if (comboCnt > 0) {
comboCnt--;
} else {
comboNum = 0;
}
} else if (transCnt == 0) {
transCnt = transDelay;
if (transY > -1) {
removeHLine(transY);
transY--;
} else if (transX > -1) {
removeVLine(transX);
transX--;
}
} else if (transCnt > 0) {
transCnt--;
}
nXPBlocks = 0;
for (var obj in block_set.xplodeBlocks_set) {
nXPBlocks++;
var tmp = block_set.xplodeBlocks_set[obj];
tmp._x = tmp._x + tmp.xSpd;
tmp._y = tmp._y + tmp.ySpd;
tmp.ySpd = tmp.ySpd + gravity;
if (tmp._y > 480) {
tmp.removeMovieClip();
}
}
if ((nXPBlocks == 0) && (!loser)) {
if (shift_newLvl) {
shift_newLvl = false;
grid.reset();
grid.lvl(startGridLvl);
}
if (shift_endGame) {
shift_endGame = false;
endGame();
}
}
}
if ((loser && ((transX == -1) && (transY == -1))) && (nXPBlocks == 0)) {
tmp = _root.attachMovie("statPopUp", "statPopUp", 1000);
tmp._x = 0;
tmp._y = 0;
stop();
}
if (_root.sfxEnabled) {
if (playPop_sfx) {
switch (playPop_sfx) {
case 1 :
_root.sfx.block_pop.start();
break;
case 2 :
_root.sfx.block_popH1.start();
break;
case 3 :
_root.sfx.block_popH2.start();
break;
case 4 :
_root.sfx.block_popH3.start();
break;
case 5 :
_root.sfx.block_popH4.start();
break;
case 6 :
_root.sfx.block_popH4.start();
break;
case 7 :
_root.sfx.block_popH4.start();
}
playPop_sfx = 0;
}
if (playLand_sfx > 0) {
playLand_sfx = 0;
_root.sfx.block_land.start();
} else if (playLand_sfx == -1) {
playLand_sfx = 1;
}
}
Frame 20
gotoAndPlay(_currentframe - 1);
Frame 21
if (noGamePause) {
grid.check_swap();
if (!loser) {
if (playingTimeCnt == 18) {
playingTimeCnt = 0;
playingTime++;
} else {
playingTimeCnt++;
}
if (stunCnt == 0) {
pushCnt++;
if (pushCnt >= pushDelay) {
pushCnt = 0;
stunCnt = 9;
if (_root.sfxEnabled) {
_root.sfx.block_land.start();
}
grid.pushUp(true);
if (block_set.replace_circle.gridY > 0) {
block_set.replace_circle.gridY--;
}
}
} else if (stunCnt > 0) {
stunCnt--;
}
if (comboCnt > 0) {
comboCnt--;
} else {
comboNum = 0;
}
if ((pushCnt % (pushDelay / 18)) < 1) {
old_gaugeRot = genCircle.hand._rotation;
}
genCircle.hand._rotation = Math.round(360 * (pushCnt / pushDelay));
if ((pushCnt % (pushDelay / 18)) < 1) {
if ((((old_gaugeRot != new_gaugeRot) && (new_gaugeRot < -20)) && (new_gaugeRot > -100)) && (_root.sfxEnabled)) {
_root.sfx.tick_warning.start();
}
new_gaugeRot = genCircle.hand._rotation;
}
} else if (transCnt == 0) {
transCnt = transDelay;
if (transY > -1) {
removeHLine(transY);
transY--;
} else if (transX > -1) {
removeVLine(transX);
transX--;
}
} else if (transCnt > 0) {
transCnt--;
}
nXPBlocks = 0;
for (var obj in block_set.xplodeBlocks_set) {
nXPBlocks++;
var tmp = block_set.xplodeBlocks_set[obj];
tmp._x = tmp._x + tmp.xSpd;
tmp._y = tmp._y + tmp.ySpd;
tmp.ySpd = tmp.ySpd + gravity;
if (tmp._y > 480) {
tmp.removeMovieClip();
}
}
}
if ((loser && ((transX == -1) && (transY == -1))) && (nXPBlocks == 0)) {
tmp = _root.attachMovie("statPopUp", "statPopUp", 1000);
tmp._x = 0;
tmp._y = 0;
stop();
}
if (_root.sfxEnabled) {
if (playPop_sfx) {
switch (playPop_sfx) {
case 1 :
_root.sfx.block_pop.start();
break;
case 2 :
_root.sfx.block_popH1.start();
break;
case 3 :
_root.sfx.block_popH2.start();
break;
case 4 :
_root.sfx.block_popH3.start();
break;
case 5 :
_root.sfx.block_popH4.start();
break;
case 6 :
if (spc_gauge.box._yscale < 100) {
spcAccPts = pts2SpcBlock;
} else {
_root.sfx.block_popH4.start();
}
break;
case 7 :
_root.sfx.block_popH4.start();
}
playPop_sfx = 0;
}
if (playLand_sfx > 0) {
playLand_sfx = 0;
_root.sfx.block_land.start();
} else if (playLand_sfx == -1) {
playLand_sfx = 1;
}
}
Frame 22
gotoAndPlay(_currentframe - 1);
Frame 24
gotoAndPlay(_currentframe - 1);
Frame 26
gotoAndPlay(_currentframe - 1);
Frame 28
gotoAndPlay(_currentframe - 1);
Symbol 45 MovieClip [pauseMenu] Frame 1
stat_txt = (((((_root.convertSec(_root.playingTime) + newline) + _root.stat.bestCombo) + newline) + _root.stat.totalCombos) + newline) + _root.stat.clearedblocks;
if (_root.curSong == 0) {
songState.gotoAndStop(7);
} else {
songState.gotoAndStop(_root.curSong);
}
Symbol 54 MovieClip [getreadyPopUp] Frame 1
if (_root.curMode == "action") {
_root.staticText.panicState.gotoAndStop(1);
linkNum._visible = false;
} else {
if (!linkNum._visible) {
linkNum._visible = true;
}
linkNum.linkTxt = _root.minBlockGoal;
}
if ((_root.curMode == "slide") || (_root.curMode == "shift")) {
_root.staticText.panicState.gotoAndStop(2);
_root.staticText.panicState2.gotoAndStop(2);
}
Symbol 54 MovieClip [getreadyPopUp] Frame 2
_root.block_set._visible = false;
Symbol 54 MovieClip [getreadyPopUp] Frame 44
if (_root.sfxEnabled) {
_root.sfx.go.start();
}
Symbol 54 MovieClip [getreadyPopUp] Frame 58
_root.gotoAndStop("frame_" + _root.curMode);
_root.block_set._visible = true;
_root.enableGameInput(true);
_root.staticText.btn_Panic.btn.enabled = true;
_root.play();
this.removeMovieClip();
Symbol 64 MovieClip Frame 1
Symbol 67 MovieClip Frame 1
stop();
Symbol 69 MovieClip Frame 1
stop();
Symbol 71 MovieClip [confirmPopUp] Frame 1
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
if (_root.statPopUp) {
_root.statPopUp.btn_inGameMenu.btn.enabled = false;
}
Instance of Symbol 64 MovieClip "btn_inGameMenu" in Symbol 71 MovieClip [confirmPopUp] Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
if (_root.statPopUp) {
_root.statPopUp.btn_inGameMenu.btn.enabled = true;
}
_root.block_set.xplodeBlocks_set._visible = true;
_root.btn_inGameMenu.btn.enabled = true;
if (!_root.noGamePause) {
_root.pauseGame();
}
if (_root.pauseMenu) {
_root.pauseMenu.removeMovieClip();
}
if (_root.getreadyPopUp) {
_root.getreadyPopUp.play();
} else if (!_root.statPopUp) {
_root.enableGameInput(true);
}
_parent.removeMovieClip();
};
btn.onRollOver = function () {
_parent.no_state.gotoAndStop(2);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.no_state.gotoAndStop(1);
});
}
Instance of Symbol 64 MovieClip "btn_inGameMenu" in Symbol 71 MovieClip [confirmPopUp] Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
if (_root.statPopUp) {
_root.statPopUp.btn_inGameMenu.btn.enabled = true;
}
_root.block_set._visible = false;
_root.piece_set._visible = false;
_root.genCircle._visible = false;
_root.spc_gauge._visible = false;
_root.btn_inGameMenu.btn.enabled = false;
_root.inGamePanel.play();
if (_root.pauseMenu) {
_root.pauseMenu.removeMovieClip();
}
if (_root.statPopUp) {
_root.statPopUp.removeMovieClip();
}
if (_root.getreadyPopUp) {
_root.getreadyPopUp.removeMovieClip();
}
_root.gotoAndStop("frame_empty");
_parent.removeMovieClip();
};
btn.onRollOver = function () {
_parent.yes_state.gotoAndStop(2);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.yes_state.gotoAndStop(1);
});
}
Symbol 73 MovieClip Frame 1
stop();
Symbol 82 MovieClip [statPopUp] Frame 1
if (_root.curLevel > _root.maxLvl) {
gotoAndStop (2);
} else {
stat_txt = (((((_root.convertSec(_root.playingTime) + newline) + _root.stat.bestCombo) + newline) + _root.stat.totalCombos) + newline) + _root.stat.clearedblocks;
stop();
}
Instance of Symbol 64 MovieClip "btn_inGameMenu" in Symbol 82 MovieClip [statPopUp] Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.confirmPopUp) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_root.newGame(_root.curMode, _root.curDiff);
_root.grid.updateDisplay();
_parent.removeMovieClip();
};
btn.onRollOver = function () {
_parent.retry_state.gotoAndStop(2);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.retry_state.gotoAndStop(1);
});
}
Symbol 82 MovieClip [statPopUp] Frame 2
demoTxt = ("This Webgame contains only " + _root.maxLvl) + " levels for this mode.";
Instance of Symbol 64 MovieClip "btn_inGameMenu" in Symbol 82 MovieClip [statPopUp] Frame 2
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue || (_root.confirmPopUp)) {
return(undefined);
}
_root.block_set._visible = false;
_root.piece_set._visible = false;
_root.inGame_menuState._visible = false;
_root.staticText._visible = false;
_root.genCircle._visible = false;
_root.spc_gauge._visible = false;
_root.btn_inGameMenu.btn.enabled = false;
_root.points_txt = "";
_root.level_txt = "";
_root.blocksCleared_txt = "";
_root.inGamePanel.play();
if (_root.pauseMenu) {
_root.pauseMenu.removeMovieClip();
}
if (_root.statPopUp) {
_root.statPopUp.removeMovieClip();
}
if (_root.getreadyPopUp) {
_root.getreadyPopUp.removeMovieClip();
}
_root.gotoAndStop("frame_empty");
};
}
Symbol 87 MovieClip Frame 1
stop();
Symbol 87 MovieClip Frame 2
stop();
var tmp = _root.attachMovie("getreadyPopUp", "getreadyPopUp", 950);
tmp._x = 0;
tmp._y = 0;
var oldBCleared = _root.blocksCleared_txt;
var old_pieceVis = _root.piece_set._visible;
var old_genCircleVis = _root.genCircle._visible;
var old_spcGaugeVis = _root.spc_gauge._visible;
_root.block_set._visible = false;
_root.piece_set._visible = false;
_root.inGame_menuState._visible = false;
_root.staticText._visible = false;
_root.genCircle._visible = false;
_root.spc_gauge._visible = false;
_root.btn_inGameMenu.btn.enabled = false;
_root.points_txt = "";
_root.level_txt = "";
_root.blocksCleared_txt = "";
_root.piece_set._visible = old_pieceVis;
_root.inGame_menuState._visible = true;
_root.staticText._visible = true;
_root.genCircle._visible = old_genCircleVis;
_root.spc_gauge._visible = old_spcGaugeVis;
_root.btn_inGameMenu.btn.enabled = true;
_root.points_txt = _root.points;
_root.level_txt = _root.curLevel;
_root.blocksCleared_txt = oldBCleared;
_root.btn_inGameMenu.btn.enabled = true;
Symbol 87 MovieClip Frame 3
_root.gotoAndStop("frame_park");
Symbol 87 MovieClip Frame 4
stop();
Symbol 96 MovieClip Frame 9
_root.grid.value[_parent.gridX][_parent.gridY] = 0;
_root.grid.changed = true;
Symbol 146 MovieClip Frame 1
stop();
Symbol 160 MovieClip Frame 1
stop();
Symbol 164 MovieClip Frame 20
stop();
Symbol 172 MovieClip Frame 1
stop();
Symbol 176 MovieClip Frame 1
stop();
Symbol 183 MovieClip Frame 1
stop();
Instance of Symbol 64 MovieClip "btn_Panic" in Symbol 188 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if ((!_root.noGamePause) || (loser)) {
return(undefined);
}
this.enabled = false;
_parent.panicState.gotoAndStop(2);
if ((_root.curMode == "drop") || (_root.curMode == "replace")) {
if (_root.sfxEnabled) {
_root.sfx.special.start();
}
_root.spcAccPts = 0;
var _local5 = 0;
while (_local5 < _root.pGrid.height) {
_root.pGrid.value[_local5] = ((_local5 < 2) ? 30 : 9);
_local5++;
}
_root.pGrid.updateDisplay();
_root.block_set.light.gotoAndStop(_root.pGrid.value[0]);
_root.spc_gauge.box._yscale = 0;
} else if ((_root.curMode == "swap") || (_root.curMode == "drag")) {
_root.spcAccPts = _root.pts2SpcBlock;
} else if (_root.curMode == "action") {
var _local5 = 0;
while (_local5 < _root.grid.width) {
var _local4 = _root.grid.height - 1;
while (_local4 > (_root.action_wallLine - 2)) {
_root.grid.value[_local5][_local4] = _root.wildcard;
_local4--;
}
_local5++;
}
}
};
}
Symbol 229 MovieClip Frame 1
play();
Symbol 229 MovieClip Frame 45
_root.play();
Instance of Symbol 64 MovieClip in Symbol 234 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_root.mainMenu.tmpMode = "shift";
_parent._parent.tmpFrame = "frame_diff";
_parent._parent.play();
};
btn.onRollOver = function () {
_parent.shift_ani.gotoAndPlay(2);
};
}
Instance of Symbol 64 MovieClip in Symbol 234 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_root.mainMenu.tmpMode = "swap";
_parent._parent.tmpFrame = "frame_diff";
_parent._parent.play();
};
btn.onRollOver = function () {
_parent.swap_ani.gotoAndPlay(2);
};
}
Instance of Symbol 64 MovieClip in Symbol 236 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_root.mainMenu.tmpMode = "drop";
_parent._parent.tmpFrame = "frame_diff";
_parent._parent.play();
};
btn.onRollOver = function () {
_parent.drop_ani.gotoAndPlay(2);
};
}
Symbol 239 MovieClip Frame 1
var tmpFrame = 0;
stop();
Symbol 239 MovieClip Frame 2
stop();
if ((((_root.mainMenu.tmpMode != "drop") && (_root.mainMenu.tmpMode != "shift")) && (_root.mainMenu.tmpMode != "swap")) && (tmpFrame != "frame_hs")) {
_root.gotoAndStop("frame_badMode");
} else {
_root.mainMenu.gotoAndStop(tmpFrame);
}
Symbol 244 MovieClip Frame 1
stop();
Symbol 248 MovieClip Frame 1
stop();
Symbol 294 MovieClip Frame 1
stop();
Symbol 340 MovieClip Frame 1
stop();
Symbol 341 MovieClip Frame 1
stop();
_parent.showAndTell.gotoAndStop("frame_drop");
Symbol 341 MovieClip Frame 2
_parent.showAndTell.gotoAndStop("frame_pushup");
Symbol 341 MovieClip Frame 3
_parent.showAndTell.gotoAndStop("frame_powergauge");
Symbol 341 MovieClip Frame 4
_parent.showAndTell.gotoAndStop("frame_static");
Symbol 341 MovieClip Frame 5
special_info.gotoAndStop(1);
Symbol 341 MovieClip Frame 6
special_info.gotoAndStop(2);
Symbol 341 MovieClip Frame 7
special_info.gotoAndStop(3);
Symbol 341 MovieClip Frame 8
special_info.gotoAndStop(4);
Symbol 341 MovieClip Frame 9
special_info.gotoAndStop(5);
Symbol 346 MovieClip Frame 1
stop();
_parent.showAndTell.gotoAndStop("frame_shift");
Symbol 346 MovieClip Frame 2
_parent.showAndTell.gotoAndStop("frame_static");
Symbol 349 MovieClip Frame 1
stop();
_parent.showAndTell.gotoAndStop("frame_swap");
Symbol 349 MovieClip Frame 2
_parent.showAndTell.gotoAndStop("frame_pushup");
Symbol 349 MovieClip Frame 3
_parent.showAndTell.gotoAndStop("frame_static");
Symbol 349 MovieClip Frame 4
_parent.showAndTell.gotoAndStop("frame_static");
Symbol 353 MovieClip Frame 1
function updateProgress() {
progressClip = (tutorClip.lesson._currentframe + " of ") + tutorClip.lesson._totalframes;
}
modeTxt_state.gotoAndStop(_root.mainMenu.tmpMode);
tutorClip.gotoAndStop(("frame_" + _root.mainMenu.tmpMode) + "_lesson");
updateProgress();
Instance of Symbol 64 MovieClip "btnR" in Symbol 353 MovieClip Frame 1
onClipEvent (load) {
btn.onRollOver = function () {
_parent.next_state.gotoAndStop(2);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.next_state.gotoAndStop(1);
});
btn.onPress = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_parent.tutorClip.lesson.nextFrame();
_parent.updateProgress();
_parent.next_state.gotoAndStop(3);
};
btn.onRelease = function () {
_parent.next_state.gotoAndStop(2);
};
}
Instance of Symbol 64 MovieClip "btnL" in Symbol 353 MovieClip Frame 1
onClipEvent (load) {
btn.onRollOver = function () {
_parent.prev_state.gotoAndStop(2);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.prev_state.gotoAndStop(1);
});
btn.onPress = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_parent.tutorClip.lesson.prevFrame();
_parent.updateProgress();
_parent.prev_state.gotoAndStop(3);
};
btn.onRelease = function () {
_parent.prev_state.gotoAndStop(2);
};
}
Symbol 360 MovieClip Frame 1
stop();
Instance of Symbol 64 MovieClip in Symbol 362 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_root.mainMenu.tmpDiff = 0;
_parent._parent.play();
};
btn.onRollOver = function () {
_parent.diff_state.gotoAndStop(2);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.diff_state.gotoAndStop(1);
});
}
Instance of Symbol 64 MovieClip in Symbol 362 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_root.mainMenu.tmpDiff = 1;
_parent._parent.play();
};
btn.onRollOver = function () {
_parent.diff_state.gotoAndStop(3);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.diff_state.gotoAndStop(1);
});
}
Instance of Symbol 64 MovieClip in Symbol 362 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_parent._parent.gotoMenu = true;
_parent._parent.play();
};
btn.onRollOver = function () {
_parent.diff_state.gotoAndStop(6);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.diff_state.gotoAndStop(1);
});
}
Symbol 367 MovieClip Frame 1
var tmpDiff = 0;
var gotoMenu = false;
stop();
Symbol 367 MovieClip Frame 2
stop();
if (gotoMenu) {
_parent.gotoAndStop("frame_mode");
} else {
_root.newGame(_root.mainMenu.tmpMode, _root.mainMenu.tmpDiff);
}
Symbol 397 MovieClip Frame 1
stop();
Instance of Symbol 64 MovieClip in Symbol 398 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_parent._parent.populateHS("drop");
_parent._parent.ptr._y = _y + _parent._y;
};
btn.onRollOver = function () {
_parent.menu_state.gotoAndStop(2);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.menu_state.gotoAndStop(1);
});
}
Instance of Symbol 64 MovieClip in Symbol 398 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_parent._parent.populateHS("shift");
_parent._parent.ptr._y = _y + _parent._y;
};
btn.onRollOver = function () {
_parent.menu_state.gotoAndStop(6);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.menu_state.gotoAndStop(1);
});
}
Instance of Symbol 64 MovieClip in Symbol 398 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
if (_root.sfxEnabled) {
_root.sfx.btn_rollover.start();
}
_parent._parent.populateHS("swap");
_parent._parent.ptr._y = _y + _parent._y;
};
btn.onRollOver = function () {
_parent.menu_state.gotoAndStop(7);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.menu_state.gotoAndStop(1);
});
}
Instance of Symbol 64 MovieClip in Symbol 398 MovieClip Frame 1
onClipEvent (load) {
btn.onRelease = function () {
if (_root.fsContinue) {
return(undefined);
}
_parent._parent.play();
};
btn.onRollOver = function () {
_parent.menu_state.gotoAndStop(9);
};
btn.onDragOut = (btn.onRollOut = function () {
_parent.menu_state.gotoAndStop(1);
});
}
Symbol 401 MovieClip Frame 1
function clearHS() {
var _local2;
var _local3 = 0;
while (_local3 < 4) {
_local2 = this["panel" + _local3];
_local2.name_txt = "";
_local2.points_txt = "";
_local2.level_txt = "";
_local2.bCleared_txt = "";
_local2.combos_txt = "";
_local3++;
}
}
function populateHS(gmode) {
tmp = _root["highScore_" + gmode];
var _local3;
clearHS();
var _local5 = 1;
while (_local5 < 6) {
var _local4 = 0;
while (_local4 < 4) {
_local3 = this["panel" + _local4];
_local3.name_txt = _local3.name_txt + tmp["rank" + _local5]["name_" + _local4];
_local3.points_txt = _local3.points_txt + tmp["rank" + _local5]["points_" + _local4];
_local3.level_txt = _local3.level_txt + tmp["rank" + _local5]["level_" + _local4];
_local3.bCleared_txt = _local3.bCleared_txt + tmp["rank" + _local5]["blocksCleared_" + _local4];
_local3.combos_txt = _local3.combos_txt + ((tmp["rank" + _local5]["bestCombo_" + _local4] + " / ") + tmp["rank" + _local5]["totalCombo_" + _local4]);
if (_local5 < 10) {
_local3.name_txt = _local3.name_txt + newline;
_local3.points_txt = _local3.points_txt + newline;
_local3.level_txt = _local3.level_txt + newline;
_local3.bCleared_txt = _local3.bCleared_txt + newline;
_local3.combos_txt = _local3.combos_txt + newline;
}
_local4++;
}
_local5++;
}
}
panel0.gotoAndStop(2);
panel1.gotoAndStop(2);
panel2.gotoAndStop(2);
panel3.gotoAndStop(2);
ptr._y = -50;
clearHS();
stop();
Symbol 401 MovieClip Frame 2
stop();
_root.mainMenu.gotoAndStop("frame_mode");
Symbol 402 MovieClip Frame 1
var tmpMode = 0;
var tmpDiff = 0;
stop();
Symbol 402 MovieClip Frame 2