Frame 2
if (loadperc == 100) {
gotoAndPlay (4);
}
loadperc = int((_framesloaded / _totalframes) * 100);
perc = loadperc add "%";
Frame 3
gotoAndPlay (2);
Frame 4
stop();
Frame 5
removeMovieClip("gameover2");
f = 1;
while (2000 >= f) {
removeMovieClip("block" add f);
f++;
}
level = 1;
stop();
Frame 93
ifFrameLoaded (114) {
gotoAndPlay (100);
}
Frame 94
gotoAndPlay (93);
Frame 99
stop();
Frame 100
removeMovieClip("gameover2");
removeMovieClip("nextlevel2");
f = 1;
while (2000 >= f) {
removeMovieClip("block" add f);
f++;
}
if (level == 1) {
sb_score = 0;
maxcolour = 3;
sb_lines = 10;
addspeed = 200;
startrows = 10;
_root.GameBG.gotoAndStop(1);
}
if (level == 2) {
maxcolour = 3;
sb_lines = 10;
addspeed = 200;
startrows = 10;
_root.GameBG.gotoAndStop(2);
}
if (level == 3) {
maxcolour = 3;
sb_lines = 15;
addspeed = 150;
startrows = 10;
_root.GameBG.gotoAndStop(3);
}
if (level == 4) {
maxcolour = 4;
sb_lines = 15;
addspeed = 100;
startrows = 11;
_root.GameBG.gotoAndStop(4);
}
if (level == 5) {
maxcolour = 4;
sb_lines = 25;
addspeed = 250;
startrows = 14;
_root.GameBG.gotoAndStop(5);
}
if (level == 6) {
maxcolour = 4;
sb_lines = 30;
addspeed = 200;
startrows = 12;
_root.GameBG.gotoAndStop(6);
}
if (level == 7) {
maxcolour = 5;
sb_lines = 30;
addspeed = 150;
startrows = 10;
_root.GameBG.gotoAndStop(7);
}
if (level == 8) {
maxcolour = 5;
sb_lines = 45;
addspeed = 100;
startrows = 12;
_root.GameBG.gotoAndStop(8);
}
if (level == 9) {
maxcolour = 5;
sb_lines = 180;
addspeed = 50;
startrows = 16;
_root.GameBG.gotoAndStop(9);
}
sb_level = level;
sfx4.gotoAndPlay(2);
grid = new Array();
gridy = 21;
gridx = 15;
gridsize = gridy * gridx;
f = 0;
while (gridsize >= f) {
grid[f] = 0;
f++;
}
colourgrid = new Array();
match = new Array();
addblocks = new Array();
search = false;
foundmin = 3;
startx = 31;
starty = 487;
xpos = startx;
ypos = starty;
xdif = 24;
ydif = 24;
blockcount = 1;
startcolumns = gridx;
y = 1;
while (startrows >= y) {
xpos = startx;
x = 1;
while (startcolumns >= x) {
duplicateMovieClip ("blocks", "block" add blockcount, blockcount);
blockname = eval ("block" add blockcount);
blockname._x = xpos;
blockname._y = ypos;
colour = random(maxcolour) + 1;
blockname.gotoAndStop(colour);
grid[blockcount] = blockcount;
xpos = xpos + xdif;
blockcount = blockcount + 1;
x++;
}
ypos = ypos - ydif;
y++;
}
addnum = 0;
addx = startx;
addy = (starty + ydif) + 19;
speedchange = 50;
leveltime = 10;
addstart = getTimer();
levelstart = getTimer();
Frame 101
if (search == true) {
gotoAndPlay (109);
}
delay = getTimer() - addstart;
if (addspeed < delay) {
addnum = addnum + 1;
newcount = 1000 + addnum;
duplicateMovieClip ("blocks", "block" add newcount, newcount);
blockname = eval ("block" add newcount);
blockname._x = addx;
blockname._y = addy;
colour = random(maxcolour) + 1;
addblocks[addnum] = colour;
blockname.gotoAndStop(colour);
addx = addx + xdif;
addstart = getTimer();
if (addnum == gridx) {
f = gridx + 1;
while (gridsize >= f) {
tempf = (gridsize - f) + 1;
grid[tempf] = grid[tempf - gridx];
blocknum = eval ("block" add grid[tempf - gridx]);
blocknum._y = blocknum._y - ydif;
f++;
}
xpos = startx;
ypos = starty;
f = 1;
while (gridx >= f) {
newcount = 1000 + f;
removeMovieClip("block" add newcount);
duplicateMovieClip ("blocks", "block" add blockcount, blockcount);
blockname = eval ("block" add blockcount);
blockname._x = xpos;
blockname._y = ypos;
colour = addblocks[f];
blockname.gotoAndStop(colour);
grid[f] = blockcount;
xpos = xpos + xdif;
blockcount = blockcount + 1;
f++;
}
addnum = 0;
addx = startx;
sb_lines = sb_lines - 1;
if (sb_lines == 3) {
sfx8.gotoAndPlay(2);
}
}
}
gridcheck = (gridsize - (gridx * 2)) + 1;
gameover = false;
f = gridcheck;
while (gridsize >= f) {
check = grid[f];
if (check != 0) {
gameover = true;
}
f++;
}
if (sb_lines < 0) {
gotoAndPlay (103);
}
Frame 102
if (gameover == false) {
gotoAndPlay (101);
} else {
gotoAndPlay (104);
}
Frame 103
gameovertime = getTimer();
sfx4.gotoAndStop(1);
stopAllSounds();
sb_lines = 0;
duplicateMovieClip ("nextlevel", "nextlevel2", 10000);
nextlevel2._x = 205;
nextlevel2._y = 230;
sfx7.gotoAndPlay(2);
level = level + 1;
stop();
Frame 104
gameovertime = getTimer();
stopAllSounds();
duplicateMovieClip ("gameover", "gameover2", 10000);
gameover2._x = 197;
gameover2._y = 251;
sfx5.gotoAndPlay(2);
stop();
Frame 109
blocknum = grid[gridpos];
blockcolour = _root["block" add blocknum]._currentframe;
f = 1;
while (gridsize >= f) {
blocknum = grid[f];
tempcolour = _root["block" add blocknum]._currentframe;
if (tempcolour == blockcolour) {
newval = blockcolour;
} else {
newval = 0;
}
colourgrid[f] = newval;
match[f] = 0;
f++;
}
Frame 110
currentpos = gridpos;
found = 1;
foundptr = 1;
repeat = true;
while (repeat == true) {
if (found == foundptr) {
match[found] = currentpos;
colourgrid[currentpos] = 0;
}
xpos = ((currentpos - 1) % gridx) + 1;
ypos = int((currentpos - 1) / gridx);
nextpos = -1;
repeat = false;
check = 0;
if (1 < xpos) {
check = colourgrid[currentpos - 1];
}
if (check != 0) {
nextpos = currentpos - 1;
}
check = 0;
if (xpos < gridx) {
check = colourgrid[currentpos + 1];
}
if (check != 0) {
nextpos = currentpos + 1;
}
check = 0;
if (ypos < gridy) {
check = colourgrid[currentpos + gridx];
}
if (check != 0) {
nextpos = currentpos + gridx;
}
check = 0;
if (0 < ypos) {
check = colourgrid[currentpos - gridx];
}
if (check != 0) {
nextpos = currentpos - gridx;
}
if (0 < nextpos) {
found = found + 1;
foundptr = found;
currentpos = nextpos;
repeat = true;
} else if (1 < foundptr) {
foundptr = foundptr - 1;
currentpos = match[foundptr];
repeat = true;
}
}
if (found >= foundmin) {
f = 1;
while (found >= f) {
num = match[f];
removeMovieClip("block" add grid[num]);
grid[num] = 0;
f++;
}
sfx3.gotoAndPlay(2);
newscore = (found - 2) * found;
if (found >= 10) {
newscore = newscore * 20;
}
sb_score = sb_score + newscore;
} else {
sfx2.gotoAndPlay(2);
}
Frame 111
fall = false;
f = 1;
while ((gridsize - gridx) >= f) {
temp = grid[f];
temp2 = grid[f + gridx];
if (temp == 0) {
if (temp2 != 0) {
fall = true;
}
blocknum = eval ("block" add temp2);
blocknum._y = blocknum._y + ydif;
grid[f] = temp2;
grid[f + gridx] = 0;
}
f++;
}
Frame 112
if (fall == true) {
gotoAndPlay (111);
} else {
side = false;
fall = false;
mid = gridx / 2;
f = 2;
while (f < gridx) {
check = grid[f];
if (check == 0) {
if (mid >= f) {
y = 0;
while (y < gridy) {
newf = f + (y * gridx);
fcount = f;
while (1 < fcount) {
check2 = grid[newf - 1];
if (check2 != 0) {
side = true;
}
blocknum = eval ("block" add grid[newf - 1]);
blocknum._x = blocknum._x + xdif;
grid[newf] = grid[newf - 1];
newf = newf - 1;
fcount = fcount - 1;
}
grid[newf] = 0;
y++;
}
} else {
y = 0;
while (y < gridy) {
newf = f + (y * gridx);
fcount = f;
while (fcount < gridx) {
check2 = grid[newf + 1];
if (check2 != 0) {
side = true;
}
blocknum = eval ("block" add grid[newf + 1]);
blocknum._x = blocknum._x - xdif;
grid[newf] = grid[newf + 1];
newf = newf + 1;
fcount = fcount + 1;
}
grid[newf] = 0;
y++;
}
}
}
f++;
}
}
Frame 113
if (side == false) {
search = false;
gotoAndPlay (101);
} else {
gotoAndPlay (112);
}
Symbol 17 Button
on (release) {
getURL ("http://pornoigry.net", "_self");
}
Symbol 35 Button
on (press) {
fscommand ("quit");
}
Symbol 36 Button
on (release) {
gotoAndPlay (5);
}
Symbol 46 Button
on (release) {
gotoAndPlay (100);
}
Symbol 47 Button
on (release) {
getURL ("http://pornoigry.net", "_blank");
}
Symbol 48 Button
on (release) {
getURL ("http://pornoigry.net/", "_blank");
}
Symbol 49 Button
on (release) {
gotoAndPlay (99);
}
Symbol 51 Button
on (release) {
getURL ("http://pornoigry.net");
}
Symbol 55 Button
on (release) {
gotoAndStop (5);
}
Symbol 74 MovieClip Frame 1
stop();
Symbol 74 MovieClip Frame 2
stop();
Symbol 74 MovieClip Frame 3
stop();
Symbol 74 MovieClip Frame 4
stop();
Symbol 74 MovieClip Frame 5
stop();
Symbol 74 MovieClip Frame 6
stop();
Symbol 74 MovieClip Frame 7
stop();
Symbol 74 MovieClip Frame 8
stop();
Symbol 74 MovieClip Frame 9
stop();
Symbol 96 Button
on (press) {
blockname = substring(_name, 6, 3);
thiscolour = _currentframe;
xpos = ((_x - /:startx) / /:xdif) + 1;
ypos = (-(_y - /:starty)) / /:ydif;
gridpos = (ypos * /:gridx) + xpos;
Set("/:search", true);
Set("/:gridpos", gridpos);
}
Symbol 109 MovieClip Frame 1
stop();
Symbol 111 Button
on (press) {
delay = getTimer() - /:gameovertime;
if (1000 < delay) {
tellTarget ("/") {
gotoAndPlay ("intro");
};
}
}
Symbol 118 Button
on (press) {
delay = getTimer() - /:gameovertime;
if (3000 < delay) {
tellTarget ("/") {
gotoAndPlay ("gamestart");
};
}
}
Symbol 127 MovieClip Frame 1
stop();
Symbol 129 MovieClip Frame 1
stop();
Symbol 131 MovieClip Frame 1
stop();
Symbol 133 MovieClip Frame 1
stop();
Symbol 135 MovieClip Frame 1
stop();
Symbol 137 MovieClip Frame 1
stop();
Symbol 139 MovieClip Frame 1
stop();
Symbol 140 Button
on (release) {
gotoAndPlay (208);
}